Return std::string from gdb_bfd_errmsg
[external/binutils.git] / gdb / ChangeLog
1 2018-09-13  Tom Tromey  <tom@tromey.com>
2
3         * utils.h (gdb_bfd_errmsg): Return std::string.
4         * exec.c (exec_file_attach): Update.
5         * compile/compile-object-load.c (compile_object_load): Update.
6         * utils.c (gdb_bfd_errmsg): Return std::string.
7
8 2018-09-13  Tom Tromey  <tom@tromey.com>
9
10         * procfs.c (struct procinfo_deleter): New.
11         (procinfo_up): New typedef.
12         (do_destroy_procinfo_cleanup): Remove.
13         (procfs_target::info_proc): Use procinfo_up.  Remove cleanups.
14
15 2018-09-13  Tom Tromey  <tom@tromey.com>
16
17         * source.c (add_path): Use gdb::unique_xmalloc_ptr.
18
19 2018-09-13  Simon Marchi  <simon.marchi@ericsson.com>
20 2018-09-13  Tom Tromey  <tom@tromey.com>
21
22         * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
23         (pspy_get_objfiles): New function.
24         (progspace_object_methods): New.
25         (pspace_object_type): Add tp_methods callback.
26         * python/python-internal.h (build_objfiles_list): New
27         declaration.
28         * python/python.c (build_objfiles_list): New function.
29         (gdbpy_objfiles): Implement using build_objfiles_list.
30         * NEWS: Mention the Progspace.objfiles method.
31
32 2018-09-13  Simon Marchi  <simon.marchi@ericsson.com>
33
34         * python/py-inferior.c (infpy_get_progspace): New function.
35         (inferior_object_getset): Add progspace property.
36         * NEWS: Mention the new property.
37
38 2018-09-13  Tom Tromey  <tom@tromey.com>
39
40         PR rust/23650:
41         * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
42
43 2018-09-13  Tom Tromey  <tom@tromey.com>
44
45         PR rust/23626:
46         * rust-lang.c (rust_enum_variant): Now static.
47         (rust_empty_enum_p): New function.
48         (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
49         Handle empty enum.
50
51 2018-09-13  Simon Marchi  <simon.marchi@ericsson.com>
52
53         * python/py-inferior.c (infpy_repr): New.
54         (inferior_object_type): Register infpy_repr.
55         * python/py-objfile.c (objfpy_repr): New.
56         (objfile_object_type): Register objfpy_repr.
57
58 2018-09-12  John Baldwin  <jhb@FreeBSD.org>
59
60         * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
61
62 2018-09-12  John Baldwin  <jhb@FreeBSD.org>
63
64         * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
65         typo.
66
67 2018-09-12  Sergio Durigan Junior  <sergiodj@redhat.com>
68
69         * common/common-utils.c: Don't include '<sys/stat.h>'.
70         (is_regular_file): Move to...
71         * common/filestuff.c (is_regular_file): ... here.
72         * common/common-utils.h (is_regular_file): Move to...
73         * common/filestuff.h (is_regular_file): ... here.
74
75 2018-09-12  Simon Marchi  <simon.marchi@ericsson.com>
76
77         * skip.c (debug_skip): New variable.
78         (skiplist_entry::do_skip_file_p): Add debug output.
79         (skiplist_entry::do_skip_gfile_p): Likewise.
80         (skiplist_entry::skip_function_p): Likewise.
81         (_initialize_step_skip): Create debug command.
82         * NEWS: Mention set/show debug skip.
83
84 2018-09-11  Xavier Roirand  <roirand@adacore.com>
85
86         * darwin-nat.c (should_disable_startup_with_shell):
87         New function.
88         (darwin_nat_target::create_inferior): Add call.
89
90 2018-09-11  Xavier Roirand  <roirand@adacore.com>
91
92         * darwin-nat.h (struct darwin_thread_info) <gdb_port,
93         inf_port, msg_state>: Initialize.
94         (struct darwin_thread_info) <signaled, single_step>: Change
95         type and initialize.
96         (struct darwin_thread_info) <event>: Initialize.
97
98 2018-09-10  Sergio Durigan Junior  <sergiodj@redhat.com>
99
100         PR gdb/23555
101         PR gdb/23558
102         * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
103         guesses.
104
105 2018-09-10  Sergio Durigan Junior  <sergiodj@redhat.com>
106
107         Revert:
108         2018-08-29  Sergio Durigan Junior  <sergiodj@redhat.com>
109
110         PR gdb/23555
111         PR gdb/23558
112         * gnulib/aclocal.m4: Regenerate.
113         * gnulib/config.in: Regenerate.
114         * gnulib/configure: Regenerate.
115         * gnulib/import/Makefile.am: Update.
116         * gnulib/import/Makefile.in: Update.
117         * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
118         * gnulib/import/_Noreturn.h: ... this.
119         * gnulib/import/alloca.in.h: Update.
120         * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
121         * gnulib/import/arg-nonnull.h: ... this.
122         * gnulib/import/assure.h: Update.
123         * gnulib/import/at-func.c: Update.
124         * gnulib/import/basename-lgpl.c: Update.
125         * gnulib/import/extra/snippet/c++defs.h: Rename to...
126         * gnulib/import/c++defs.h: ... this.
127         * gnulib/import/canonicalize-lgpl.c: Update.
128         * gnulib/import/cdefs.h: Update.
129         * gnulib/import/chdir-long.c: Update.
130         * gnulib/import/chdir-long.h: Update.
131         * gnulib/import/cloexec.c: Update.
132         * gnulib/import/cloexec.h: Update.
133         * gnulib/import/close.c: Update.
134         * gnulib/import/closedir.c: Update.
135         * gnulib/import/config.charset: Update.
136         * gnulib/import/dirent-private.h: Update.
137         * gnulib/import/dirent.in.h: Update.
138         * gnulib/import/dirfd.c: Update.
139         * gnulib/import/dirname-lgpl.c: Update.
140         * gnulib/import/dirname.h: Update.
141         * gnulib/import/dosname.h: Update.
142         * gnulib/import/dup-safer-flag.c: Update.
143         * gnulib/import/dup-safer.c: Update.
144         * gnulib/import/dup.c: Update.
145         * gnulib/import/dup2.c: Update.
146         * gnulib/import/errno.in.h: Update.
147         * gnulib/import/error.c: Update.
148         * gnulib/import/error.h: Update.
149         * gnulib/import/exitfail.c: Update.
150         * gnulib/import/exitfail.h: Update.
151         * gnulib/import/extra/update-copyright: Update.
152         * gnulib/import/fchdir.c: Update.
153         * gnulib/import/fcntl.c: Update.
154         * gnulib/import/fcntl.in.h: Update.
155         * gnulib/import/fd-hook.c: Update.
156         * gnulib/import/fd-hook.h: Update.
157         * gnulib/import/fd-safer-flag.c: Update.
158         * gnulib/import/fd-safer.c: Update.
159         * gnulib/import/fdopendir.c: Update.
160         * gnulib/import/filename.h: Update.
161         * gnulib/import/filenamecat-lgpl.c: Update.
162         * gnulib/import/filenamecat.h: Update.
163         * gnulib/import/flexmember.h: Update.
164         * gnulib/import/float+.h: Update.
165         * gnulib/import/float.c: Update.
166         * gnulib/import/float.in.h: Update.
167         * gnulib/import/fnmatch.c: Update.
168         * gnulib/import/fnmatch.in.h: Update.
169         * gnulib/import/fnmatch_loop.c: Update.
170         * gnulib/import/fpucw.h: Update.
171         * gnulib/import/frexp.c: Update.
172         * gnulib/import/frexpl.c: Update.
173         * gnulib/import/fstat.c: Update.
174         * gnulib/import/fstatat.c: Update.
175         * gnulib/import/getcwd-lgpl.c: Update.
176         * gnulib/import/getcwd.c: Update.
177         * gnulib/import/getdtablesize.c: Update.
178         * gnulib/import/getlogin_r.c: Update.
179         * gnulib/import/getprogname.c: Update.
180         * gnulib/import/getprogname.h: Update.
181         * gnulib/import/gettext.h: Update.
182         * gnulib/import/gettimeofday.c: Update.
183         * gnulib/import/glob-libc.h: Update.
184         * gnulib/import/glob.c: Update.
185         * gnulib/import/glob.in.h: Update.
186         * gnulib/import/glob_internal.h: Update.
187         * gnulib/import/glob_pattern_p.c: Update.
188         * gnulib/import/globfree.c: Update.
189         * gnulib/import/hard-locale.c: Update.
190         * gnulib/import/hard-locale.h: Update.
191         * gnulib/import/intprops.h: Update.
192         * gnulib/import/inttypes.in.h: Update.
193         * gnulib/import/isnan.c: Update.
194         * gnulib/import/isnand-nolibm.h: Update.
195         * gnulib/import/isnand.c: Update.
196         * gnulib/import/isnanl-nolibm.h: Update.
197         * gnulib/import/isnanl.c: Update.
198         * gnulib/import/itold.c: Update.
199         * gnulib/import/libc-config.h: Update.
200         * gnulib/import/limits.in.h: Update.
201         * gnulib/import/localcharset.c: Update.
202         * gnulib/import/localcharset.h: Update.
203         * gnulib/import/localtime-buffer.c: Update.
204         * gnulib/import/localtime-buffer.h: Update.
205         * gnulib/import/lstat.c: Update.
206         * gnulib/import/m4/00gnulib.m4: Update.
207         * gnulib/import/m4/__inline.m4: Update.
208         * gnulib/import/m4/absolute-header.m4: Update.
209         * gnulib/import/m4/alloca.m4: Update.
210         * gnulib/import/m4/builtin-expect.m4: Update.
211         * gnulib/import/m4/canonicalize.m4: Update.
212         * gnulib/import/m4/chdir-long.m4: Update.
213         * gnulib/import/m4/close.m4: Update.
214         * gnulib/import/m4/closedir.m4: Update.
215         * gnulib/import/m4/configmake.m4: Update.
216         * gnulib/import/m4/d-ino.m4: Update.
217         * gnulib/import/m4/d-type.m4: Update.
218         * gnulib/import/m4/dirent_h.m4: Update.
219         * gnulib/import/m4/dirfd.m4: Update.
220         * gnulib/import/m4/dirname.m4: Update.
221         * gnulib/import/m4/double-slash-root.m4: Update.
222         * gnulib/import/m4/dup.m4: Update.
223         * gnulib/import/m4/dup2.m4: Update.
224         * gnulib/import/m4/eealloc.m4: Update.
225         * gnulib/import/m4/environ.m4: Update.
226         * gnulib/import/m4/errno_h.m4: Update.
227         * gnulib/import/m4/error.m4: Update.
228         * gnulib/import/m4/exponentd.m4: Update.
229         * gnulib/import/m4/exponentl.m4: Update.
230         * gnulib/import/m4/extensions.m4: Update.
231         * gnulib/import/m4/extern-inline.m4: Update.
232         * gnulib/import/m4/fchdir.m4: Update.
233         * gnulib/import/m4/fcntl-o.m4: Update.
234         * gnulib/import/m4/fcntl.m4: Update.
235         * gnulib/import/m4/fcntl_h.m4: Update.
236         * gnulib/import/m4/fdopendir.m4: Update.
237         * gnulib/import/m4/filenamecat.m4: Update.
238         * gnulib/import/m4/flexmember.m4: Update.
239         * gnulib/import/m4/float_h.m4: Update.
240         * gnulib/import/m4/fnmatch.m4: Update.
241         * gnulib/import/m4/fnmatch_h.m4: Update.
242         * gnulib/import/m4/fpieee.m4: Update.
243         * gnulib/import/m4/frexp.m4: Update.
244         * gnulib/import/m4/frexpl.m4: Update.
245         * gnulib/import/m4/fstat.m4: Update.
246         * gnulib/import/m4/fstatat.m4: Update.
247         * gnulib/import/m4/getcwd-abort-bug.m4: Update.
248         * gnulib/import/m4/getcwd-path-max.m4: Update.
249         * gnulib/import/m4/getcwd.m4: Update.
250         * gnulib/import/m4/getdtablesize.m4: Update.
251         * gnulib/import/m4/getlogin.m4: Update.
252         * gnulib/import/m4/getlogin_r.m4: Update.
253         * gnulib/import/m4/getpagesize.m4: Update.
254         * gnulib/import/m4/getprogname.m4: Update.
255         * gnulib/import/m4/gettimeofday.m4: Update.
256         * gnulib/import/m4/glibc21.m4: Update.
257         * gnulib/import/m4/glob.m4: Update.
258         * gnulib/import/m4/glob_h.m4: Update.
259         * gnulib/import/m4/gnulib-cache.m4: Update.
260         * gnulib/import/m4/gnulib-common.m4: Update.
261         * gnulib/import/m4/gnulib-comp.m4: Update.
262         * gnulib/import/m4/gnulib-tool.m4: Update.
263         * gnulib/import/m4/hard-locale.m4: Update.
264         * gnulib/import/m4/include_next.m4: Update.
265         * gnulib/import/m4/inttypes-pri.m4: Update.
266         * gnulib/import/m4/inttypes.m4: Update.
267         * gnulib/import/m4/isnand.m4: Update.
268         * gnulib/import/m4/isnanl.m4: Update.
269         * gnulib/import/m4/largefile.m4: Update.
270         * gnulib/import/m4/limits-h.m4: Update.
271         * gnulib/import/m4/localcharset.m4: Update.
272         * gnulib/import/m4/locale-fr.m4: Update.
273         * gnulib/import/m4/locale-ja.m4: Update.
274         * gnulib/import/m4/locale-zh.m4: Update.
275         * gnulib/import/m4/localtime-buffer.m4: Update.
276         * gnulib/import/m4/longlong.m4: Update.
277         * gnulib/import/m4/lstat.m4: Update.
278         * gnulib/import/m4/malloc.m4: Update.
279         * gnulib/import/m4/malloca.m4: Update.
280         * gnulib/import/m4/math_h.m4: Update.
281         * gnulib/import/m4/mbrtowc.m4: Update.
282         * gnulib/import/m4/mbsinit.m4: Update.
283         * gnulib/import/m4/mbsrtowcs.m4: Update.
284         * gnulib/import/m4/mbstate_t.m4: Update.
285         * gnulib/import/m4/memchr.m4: Update.
286         * gnulib/import/m4/memmem.m4: Update.
287         * gnulib/import/m4/mempcpy.m4: Update.
288         * gnulib/import/m4/memrchr.m4: Update.
289         * gnulib/import/m4/mkdir.m4: Update.
290         * gnulib/import/m4/mkstemp.m4: Update.
291         * gnulib/import/m4/mmap-anon.m4: Update.
292         * gnulib/import/m4/mode_t.m4: Update.
293         * gnulib/import/m4/msvc-inval.m4: Update.
294         * gnulib/import/m4/msvc-nothrow.m4: Update.
295         * gnulib/import/m4/multiarch.m4: Update.
296         * gnulib/import/m4/nocrash.m4: Update.
297         * gnulib/import/m4/off_t.m4: Update.
298         * gnulib/import/m4/onceonly.m4: Update.
299         * gnulib/import/m4/open-cloexec.m4: Update.
300         * gnulib/import/m4/open.m4: Update.
301         * gnulib/import/m4/openat.m4: Update.
302         * gnulib/import/m4/opendir.m4: Update.
303         * gnulib/import/m4/pathmax.m4: Update.
304         * gnulib/import/m4/rawmemchr.m4: Update.
305         * gnulib/import/m4/readdir.m4: Update.
306         * gnulib/import/m4/readlink.m4: Update.
307         * gnulib/import/m4/realloc.m4: Update.
308         * gnulib/import/m4/rename.m4: Update.
309         * gnulib/import/m4/rewinddir.m4: Update.
310         * gnulib/import/m4/rmdir.m4: Update.
311         * gnulib/import/m4/save-cwd.m4: Update.
312         * gnulib/import/m4/secure_getenv.m4: Update.
313         * gnulib/import/m4/setenv.m4: Update.
314         * gnulib/import/m4/signal_h.m4: Update.
315         * gnulib/import/m4/ssize_t.m4: Update.
316         * gnulib/import/m4/stat-time.m4: Update.
317         * gnulib/import/m4/stat.m4: Update.
318         * gnulib/import/m4/std-gnu11.m4: Update.
319         * gnulib/import/m4/stdbool.m4: Update.
320         * gnulib/import/m4/stddef_h.m4: Update.
321         * gnulib/import/m4/stdint.m4: Update.
322         * gnulib/import/m4/stdio_h.m4: Update.
323         * gnulib/import/m4/stdlib_h.m4: Update.
324         * gnulib/import/m4/strchrnul.m4: Update.
325         * gnulib/import/m4/strdup.m4: Update.
326         * gnulib/import/m4/strerror.m4: Update.
327         * gnulib/import/m4/string_h.m4: Update.
328         * gnulib/import/m4/strstr.m4: Update.
329         * gnulib/import/m4/strtok_r.m4: Update.
330         * gnulib/import/m4/sys_socket_h.m4: Update.
331         * gnulib/import/m4/sys_stat_h.m4: Update.
332         * gnulib/import/m4/sys_time_h.m4: Update.
333         * gnulib/import/m4/sys_types_h.m4: Update.
334         * gnulib/import/m4/tempname.m4: Update.
335         * gnulib/import/m4/time_h.m4: Update.
336         * gnulib/import/m4/unistd-safer.m4: Update.
337         * gnulib/import/m4/unistd_h.m4: Update.
338         * gnulib/import/m4/warn-on-use.m4: Update.
339         * gnulib/import/m4/wchar_h.m4: Update.
340         * gnulib/import/m4/wchar_t.m4: Update.
341         * gnulib/import/m4/wctype_h.m4: Update.
342         * gnulib/import/m4/wint_t.m4: Update.
343         * gnulib/import/malloc.c: Update.
344         * gnulib/import/malloc/scratch_buffer.h: Update.
345         * gnulib/import/malloc/scratch_buffer_grow.c: Update.
346         * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
347         * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
348         * gnulib/import/malloca.c: Update.
349         * gnulib/import/malloca.h: Update.
350         * gnulib/import/malloca.valgrind: Update.
351         * gnulib/import/math.in.h: Update.
352         * gnulib/import/mbrtowc.c: Update.
353         * gnulib/import/mbsinit.c: Update.
354         * gnulib/import/mbsrtowcs-impl.h: Update.
355         * gnulib/import/mbsrtowcs-state.c: Update.
356         * gnulib/import/mbsrtowcs.c: Update.
357         * gnulib/import/memchr.c: Update.
358         * gnulib/import/memmem.c: Update.
359         * gnulib/import/mempcpy.c: Update.
360         * gnulib/import/memrchr.c: Update.
361         * gnulib/import/mkdir.c: Update.
362         * gnulib/import/mkstemp.c: Update.
363         * gnulib/import/msvc-inval.c: Update.
364         * gnulib/import/msvc-inval.h: Update.
365         * gnulib/import/msvc-nothrow.c: Update.
366         * gnulib/import/msvc-nothrow.h: Update.
367         * gnulib/import/open.c: Update.
368         * gnulib/import/openat-die.c: Update.
369         * gnulib/import/openat-priv.h: Update.
370         * gnulib/import/openat-proc.c: Update.
371         * gnulib/import/openat.c: Update.
372         * gnulib/import/openat.h: Update.
373         * gnulib/import/opendir.c: Update.
374         * gnulib/import/pathmax.h: Update.
375         * gnulib/import/pipe-safer.c: Update.
376         * gnulib/import/rawmemchr.c: Update.
377         * gnulib/import/readdir.c: Update.
378         * gnulib/import/readlink.c: Update.
379         * gnulib/import/realloc.c: Update.
380         * gnulib/import/ref-add.sin: Update.
381         * gnulib/import/ref-del.sin: Update.
382         * gnulib/import/rename.c: Update.
383         * gnulib/import/rewinddir.c: Update.
384         * gnulib/import/rmdir.c: Update.
385         * gnulib/import/same-inode.h: Update.
386         * gnulib/import/save-cwd.c: Update.
387         * gnulib/import/save-cwd.h: Update.
388         * gnulib/import/scratch_buffer.h: Update.
389         * gnulib/import/secure_getenv.c: Update.
390         * gnulib/import/setenv.c: Update.
391         * gnulib/import/signal.in.h: Update.
392         * gnulib/import/stat-time.c: Update.
393         * gnulib/import/stat-time.h: Update.
394         * gnulib/import/stat-w32.c: Update.
395         * gnulib/import/stat-w32.h: Update.
396         * gnulib/import/stat.c: Update.
397         * gnulib/import/stdbool.in.h: Update.
398         * gnulib/import/stddef.in.h: Update.
399         * gnulib/import/stdint.in.h: Update.
400         * gnulib/import/stdio.in.h: Update.
401         * gnulib/import/stdlib.in.h: Update.
402         * gnulib/import/str-two-way.h: Update.
403         * gnulib/import/strchrnul.c: Update.
404         * gnulib/import/strdup.c: Update.
405         * gnulib/import/streq.h: Update.
406         * gnulib/import/strerror-override.c: Update.
407         * gnulib/import/strerror-override.h: Update.
408         * gnulib/import/strerror.c: Update.
409         * gnulib/import/string.in.h: Update.
410         * gnulib/import/stripslash.c: Update.
411         * gnulib/import/strnlen1.c: Update.
412         * gnulib/import/strnlen1.h: Update.
413         * gnulib/import/strstr.c: Update.
414         * gnulib/import/strtok_r.c: Update.
415         * gnulib/import/sys_stat.in.h: Update.
416         * gnulib/import/sys_time.in.h: Update.
417         * gnulib/import/sys_types.in.h: Update.
418         * gnulib/import/tempname.c: Update.
419         * gnulib/import/tempname.h: Update.
420         * gnulib/import/time.in.h: Update.
421         * gnulib/import/unistd--.h: Update.
422         * gnulib/import/unistd-safer.h: Update.
423         * gnulib/import/unistd.in.h: Update.
424         * gnulib/import/unsetenv.c: Update.
425         * gnulib/import/verify.h: Update.
426         * gnulib/import/extra/snippet/warn-on-use.h: Update.
427         * gnulib/import/wchar.in.h: Update.
428         * gnulib/import/wctype.in.h: Update.
429         * gnulib/import/xalloc-oversized.h: Update.
430         * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
431         "53e2c179f26a890fa6685af4b6c1397ee370433b".
432
433 2018-09-10  Simon Marchi  <simon.marchi@ericsson.com>
434
435         * record-btrace.c (get_thread_current_frame): Remove
436         old_inferior_ptid.
437
438 2018-09-10  Jerome Guitton  <guitton@adacore.com>
439
440         * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
441         with check_tag to 1 if and only if the type is tagged and the
442         component being searched cannot been found in the current
443         view. Otherwise, always call ada_to_fixed_type with
444         check_tag to 0.
445
446 2018-09-10  Xavier Roirand  <roirand@adacore.com>
447
448         * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
449         declaration.
450         * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
451         * ada-varobj.c (ada_varobj_get_number_of_children,
452         ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
453
454 2018-09-10  Xavier Roirand  <roirand@adacore.com>
455
456         * ada-valprint.c (ada_value_print): Use type instead of
457         enclosing type.
458
459 2018-09-10  Xavier Roirand  <roirand@adacore.com>
460
461         * ada-lang.c (ada_value_subscript): Handle case when parameter is
462         an array of access to unconstrained array.
463
464 2018-09-10  Xavier Roirand  <roirand@adacore.com>
465
466         * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
467         (ada_check_typedef): Use it.
468
469 2018-09-10  Xavier Roirand  <roirand@adacore.com>
470
471         * ada-varobj.c (ada_varobj_describe_struct_child)
472         (ada_varobj_describe_child): Handle union case like struct one.
473
474 2018-09-10  Tom Tromey  <tom@tromey.com>
475
476         PR python/18380:
477         * python/python.c (_initialize_python): Make example in "python"
478         help work in Python 3.
479
480 2018-09-10  Eli Zaretskii  <eliz@gnu.org>
481
482         * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
483         INSTALL_PROGRAM to install gdb-add-index.sh.  Don't append
484         $(EXEEXT) to the script, as it is not a program.
485
486 2018-09-09  Simon Marchi  <simon.marchi@ericsson.com>
487
488         * python/py-prettyprint.c (pretty_print_one_value): Return
489         gdbpy_ref<>.
490         (print_string_repr): Adjust.
491         (apply_varobj_pretty_printer): Return gdbpy_ref<>.
492         * python/python-internal.h (apply_varobj_pretty_printer): Return
493         gdbpy_ref<>.
494         * varobj.c (varobj_value_get_print_value): Adjust.
495
496 2018-09-08  Tom Tromey  <tom@tromey.com>
497
498         PR python/16047:
499         * python/py-prettyprint.c (pretty_print_one_value): Check for
500         to_string method.
501
502 2018-09-08  Joel Brobecker  <brobecker@adacore.com>
503
504         * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
505         replace_operator_with_call.
506
507 2018-09-08  Joel Brobecker  <brobecker@adacore.com>
508
509         * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
510
511 2018-09-08  Joel Brobecker  <brobecker@adacore.com>
512
513         * ada-typeprint.c (print_range): Print the bounds using TYPE
514         rather than its TYPE_TARGET_TYPE.
515
516 2018-09-08  Joel Brobecker  <brobecker@adacore.com>
517
518         * ada-lang.c (ada_to_fixed_value): Minor reformatting in
519         call to ada_to_fixed_value_create.
520
521 2018-09-08  Jerome Guitton  <guitton@adacore.com>
522
523         * ada-lang.c (ada_decode): strip dot prefix in symbol name.
524
525 2018-09-08  Joel Brobecker  <brobecker@adacore.com>
526
527         * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
528         by calls to error.
529
530 2018-09-08  Joel Brobecker  <brobecker@adacore.com>
531
532         * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
533         Move update of loop variable "fi".
534
535 2018-09-08  Joel Brobecker  <brobecker@adacore.com>
536
537         * ada-lang.c (value_assign_to_component): In the case of
538         big-endian targets, extract the bits of the given VAL
539         using an src_offset of zero if container is not a scalar.
540
541 2018-09-06  Simon Ser  <contact@emersion.fr>
542
543         PR gdb/23105
544         * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
545         TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
546         * fbsd-tdep.c (fbsd_make_note_desc): New.
547         (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
548         NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
549         * target.h (enum target_object) Add FreeBSD-specific
550         TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
551
552 2018-09-06  Simon Marchi  <simon.marchi@ericsson.com>
553
554         * compile/compile-c.h (generate_c_for_variable_locations):
555         Change reference to pointer.
556         * compile/compile-c-support.c (compile_program) <compute>:
557         Likewise.
558         * compile/compile-c-symbols.c (generate_vla_size): Likewise.
559         (generate_c_for_for_one_variable): Likewise
560         (generate_c_for_variable_locations): Likewise
561         * compile/compile-c-types.c (compile_c_instance::convert_type):
562         Likewise
563         * compile/compile-cplus-symbols.c (convert_one_symbol):
564         std::move the scope passed to enter_scope.
565         * compile/compile-cplus-types.c
566         (compile_cplus_instance::enter_scope): Make parameter
567         rvalue-reference.
568         (compile_cplus_instance::new_scope): Change reference to
569         pointer.
570         (compile_cplus_instance::convert_type): Likewise
571         (compile_cplus_convert_typedef): std::move the scope passed to
572         enter_scope.
573         (compile_cplus_convert_struct_or_union): Likewise.
574         (compile_cplus_convert_enum): Likewise.
575         (compile_cplus_convert_namespace): Likewise.
576         * compile/compile-cplus.h (compile_cplus_instance)
577         <enter_scope>: Make parameter rvalue-reference.
578         * compile/compile-internal.h (compile_instance)
579         <get_cached_type>: Likewise
580         * compile/compile-loc2c.c (push): Likewise
581         (pushf): Likewise
582         (unary): Likewise
583         (binary): Likewise
584         (print_label): Likewise
585         (pushf_register_address): Likewise
586         (pushf_register): Likewise
587         (do_compile_dwarf_expr_to_c): Likewise
588         (compile_dwarf_expr_to_c): Likewise
589         (compile_dwarf_bounds_to_c): Likewise
590         * compile/compile.c (compile_instance::get_cached_type):
591         Likewise
592         * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
593         (compile_dwarf_bounds_to_c): Likewise
594         * dwarf2loc.c (locexpr_generate_c_location): Likewise.
595         (dwarf2_compile_property_to_c): Likewise
596         * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
597         * symtab.h (struct symbol_computed_ops) <generate_c_location>:
598         Likewise
599
600 2018-09-06  Simon Marchi  <simon.marchi@ericsson.com>
601
602         * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
603         * tui/tui-data.c (init_content_element): Don't initialize it.
604
605 2018-09-06  Simon Marchi  <simon.marchi@ericsson.com>
606
607         * tui/tui-data.h (struct tui_win_info)
608         <detail::opaque>: Remove.
609         * tui/tui-data.c (init_win_info): Remove assignment.
610
611 2018-09-05  Tom Tromey  <tom@tromey.com>
612
613         * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
614         -Wformat-nonliteral.
615         * target-float.c (host_float_ops<T>::to_string)
616         (host_float_ops<T>::from_string): Use
617         DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
618         * configure: Rebuild.
619
620 2018-09-05  Simon Marchi  <simon.marchi@ericsson.com>
621
622         * printcmd.c (printf_c_string): Use
623         DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
624         (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
625
626 2018-09-05  Tom Tromey  <tom@tromey.com>
627
628         * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
629
630 2018-09-05  Tom de Vries  <tdevries@suse.de>
631
632         * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
633         with resolve_abstract_p == true.
634         (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
635         defaulting to false. Propagate resolve_abstract_p to
636         dwarf2_fetch_die_loc_sect_off.
637         * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
638         parameter, defaulting to false.
639         * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
640         (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
641         parameter.
642         * dwarf2read.h (struct die_info): Forward-declare.
643         (die_info_ptr): New typedef.
644         (struct dwarf2_per_objfile): Add abstract_to_concrete field.
645
646 2018-09-05  Joel Brobecker  <brobecker@adacore.com>
647
648         GDB 8.2 released.
649
650 2018-09-04  Sergio Durigan Junior  <sergiodj@redhat.com>
651             Pedro Alves  <palves@redhat.com>
652
653         * gnulib/Makefile.in (aclocal_m4_deps): Move to
654         "aclocal-m4-deps.mk".  Include file here.
655         $(srcdir)/aclocal.m4: Add "configure.ac".
656         * gnulib/aclocal-m4-deps.mk: New file.
657         * gnulib/update-gnulib.sh: Automatically update
658         "aclocal-m4-deps.mk".
659
660 2018-09-04  Tom Tromey  <tom@tromey.com>
661
662         * configure: Rebuild.
663         * configure.ac: Remove multi-ice code.
664
665 2018-09-04  Tom Tromey  <tom@tromey.com>
666
667         * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
668         (ada-exp.o): Update.
669
670 2018-09-04  Tom Tromey  <tom@tromey.com>
671
672         * Makefile.in (printcmd.o, target-float.o): Remove.
673         (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
674
675 2018-09-04  Tom Tromey  <tom@tromey.com>
676
677         * gnulib/Makefile.in: Remove obsolete comment.
678         * Makefile.in: Remove obsolete comment.
679
680 2018-09-04  Andrew Burgess  <andrew.burgess@embecosm.com>
681
682         * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
683         line with '+'.
684
685 2018-09-03  Andrew Burgess  <andrew.burgess@embecosm.com>
686
687         * riscv-tdep.c: Add 'prologue-value.h' include.
688         (struct riscv_unwind_cache): New struct.
689         (riscv_debug_unwinder): New global.
690         (riscv_scan_prologue): Update arguments, capture register details
691         from prologue scan.
692         (riscv_skip_prologue): Reformat arguments line, move end of
693         prologue calculation into riscv_scan_prologue.
694         (riscv_frame_cache): Update return type, create
695         riscv_unwind_cache, scan the prologue, and fill in remaining cache
696         details.
697         (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
698         (riscv_frame_prev_register): Use the trad_frame within the
699         riscv_unwind_cache.
700         (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
701         flag.
702
703 2018-09-03  Andrew Burgess  <andrew.burgess@embecosm.com>
704
705         * trad-frame.h (trad_frame_set_realreg): Declare.
706         (trad_frame_set_addr): Declare.
707         * trad-frame.c (trad_frame_set_realreg): Define new function.
708         (trad_frame_set_addr): Define new function.
709         (trad_frame_set_reg_realreg): Use new function.
710         (trad_frame_set_reg_addr): Use new function.
711
712 2018-09-01  Keith Seitz  <keiths@redhat.com>
713
714         * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
715         pulongest instead of "%lld".
716         * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
717         ATTRIBUTE_UNUSED.
718
719 2018-08-31  Tom Tromey  <tom@tromey.com>
720
721         * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
722         variant part type.
723
724 2018-08-31  Pedro Alves  <palves@redhat.com>
725
726         * gdbarch.h: Regenerate.
727
728 2018-08-31  Pedro Alves  <palves@redhat.com>
729
730         * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
731         * target.h (Hardware watchpoint interfaces): Describe
732         continuable/steppable/non-steppable watchpoints.
733         * gdbarch.h, gdbarch.c: Regenerate.
734
735 2018-08-31  Pedro Alves  <palves@redhat.com>
736
737         * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
738         Delete.
739         * s390-linux-nat.c
740         (s390_linux_nat_target::have_continuable_watchpoint): Delete.
741         * target.h (target_ops::have_continuable_watchpoint): Delete.
742         (target_have_continuable_watchpoint): Delete.
743         * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
744         * target-delegates.c: Regenerate.
745
746 2018-08-31  Sergio Durigan Junior  <sergiodj@redhat.com>
747
748         * gnulib/Makefile.in (aclocal_m4_deps): Update according to
749         the files present in "gnulib/import/m4/".
750
751 2018-08-30  Andrew Burgess  <andrew.burgess@embecosm.com>
752
753         * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
754         c.sw, c.swsp, and c.sdsp.
755
756 2018-08-30  Andrew Burgess  <andrew.burgess@embecosm.com>
757
758         * riscv-tdep.c (struct riscv_inferior_data): Delete.
759         (riscv_read_misa_reg): Don't cache value read into inferior data.
760         (riscv_new_inferior_data): Delete.
761         (riscv_inferior_data_cleanup): Delete.
762         (riscv_inferior_data): Delete.
763         (riscv_invalidate_inferior_data): Delete.
764         (_initialize_riscv_tdep): Remove initialisation of inferior data.
765
766 2018-08-30  Simon Marchi  <simon.marchi@ericsson.com>
767
768         * compile/compile-cplus-types.c
769         (compile_cplus_instance::leave_scope): Take the address of scope
770         object.
771         (compile_cplus_instance::convert_qualified_base): Compare quals
772         to 0.
773
774 2018-08-30  Keith Seitz  <keiths@redhat.com>
775
776         * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
777         Use "%s" and host_address_to_string instead of "%p" in printf.
778
779 2018-08-29  Keith Seitz  <keiths@redhat.com>
780
781         * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
782         and compile-cplus-types.c.
783         (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
784         * c-lang.c (cplus_language_defn): Set C++ compile functions.
785         * c-lang.h (cplus_get_compile_context, cplus_compute_program):
786         Declare.
787         * compile/compile-c-support.c: Include compile-cplus.h.
788         (load_libcompile): Templatize.
789         (get_compile_context): "New" function.
790         (c_get_compile_context): Use get_compile_context.
791         (cplus_get_compile_context): New function.
792         (cplus_push_user_expression, cplus_pop_user_expression)
793         (cplus_add_code_header, cplus_add_input, cplus_compile_program)
794         (cplus_compute_program): Define new structs/functions.
795         * compile/compile-cplus-symmbols.c: New file.
796         * compile/compile-cplus-types.c: New file.
797         * compile/compile-cplus.h: New file.
798         * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
799         Declare.
800         * compile/compile-object-load.c (get_out_value_type): Use
801         strncmp_iw when comparing symbol names.
802         (compile_object_load): Add mst_bss and mst_data.
803         * compile/compile.c (_initialize_compile): Remove
804         -Wno-implicit-function-declaration from `compile_args'.
805         * compile/gcc-cp-plugin.h: New file.
806         * NEWS: Mention C++ compile support and new debug options.
807
808 2018-08-29  Keith Seitz  <keiths@redhat.com>
809
810         * linespec.c (collect_info::add_symbol): Make virtual.
811         (struct symbol_searcher_collect_info): New struct.
812         (symbol_searcher::find_all_symbols): New method.
813         * symtab.h (class symbol_searcher): New class.
814
815 2018-08-29  Keith Seitz  <keiths@redhat.com>
816
817         * linespec.c (struct linespec) <function_symbols, label_symbols>:
818         Change to vector of block_symbol.  Update all users.
819         (struct collect_info) <symbols>: Likewise.
820         (collect_info::add_symbol): Take block_symbol as argument.
821         Update all callers.
822         (decode_compound_collector) <m_symbols>: Change type to vector
823         of block_symbol.  Update all users.
824         (decode_compound_collector::operator ()): Change parameter type
825         to block_symbol.
826         (find_method, find_function_symbols, find_linespec_symbols)
827         (find_label_symbols_in_block, find_label_symbols): Change symbol
828         vectors to block_symbol vectors.
829         * symtab.h (symbol_found_callback_ftype): Change parameter type to
830         block_symbol.
831
832 2018-08-29  Keith Seitz  <keiths@redhat.com>
833
834         * linespec.c (symbolp): Remove typedef and VEC definitions.
835         (bound_minimal_symbol_d): Likewise.
836
837 2018-08-29  Keith Seitz  <keiths@redhat.com>
838
839         * linespec.c (decode_compound_collector::decode_compound_collector):
840         Remove initialization for `m_symtabs'.
841         (decode_compound_collector::release_symbols): Change return type
842         to std::vector.  Update all callers.
843         (class decode_compound_collector) <m_symbols>: Change type to
844         std::vector.
845         (lookup_prefix_sym): Change return type to std::vector.  Update all
846         callers.
847         (compare_symbols): Remove.
848         (std_compare_symbols): Rename to `compare_symbols'.
849         (find_method): Change `sym_classes' parameter to std::vector.
850         Update all callers.  Use std::sort to sort sym_classes.
851         (find_linespec_symbols): Remove cleanup.
852
853 2018-08-29  Keith Seitz  <keiths@redhat.com>
854
855         * linespec.c (struct linespec) <minimal_symbols>: Change type to
856         std::vector.  Update all users.
857         (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
858         (struct collect_info) <minimal_symbols>: Likewise.
859         (compare_msymbols): Return bool.  Change parameters to const
860         bound_minimal_symbol references.
861         (find_method, find_function_symbols, find_linespec_symbols): Change
862         `minsyms' parameter to std::vector.  Update all callers.
863
864 2018-08-29  Keith Seitz  <keiths@redhat.com>
865
866         * linespec.c (struct linespec) <label_symbols>: Change type to
867         std::vector.  Update all users.
868         (find_label_symbols_in_block): Change `result' parameter to
869         std::vector.  Update all callers.
870         (find_label_symbols): Return std::vector.  Update all callers.
871
872 2018-08-29  Keith Seitz  <keiths@redhat.com>
873
874         * linespec.c (struct linespec) <function_symbols>: Change type to
875         std::vector.  Update all users.
876         (struct collect_info) <function_symbols>: Likewise.
877         (convert_linespec_to_sals): Use std::sort to sort function_symbols.
878         (std_compare_symbols): New function.
879         (find_method, find_function_symbols, find_linespec_symbols)
880         (find_label_symbols_in_block): Change `symbols' parameter to
881         std::vector.  Update all callers.
882         (find_label_symbols): Likewise for `function_symbols' and
883         `label_funcs_ret'.
884
885 2018-08-29  Keith Seitz  <keiths@redhat.com>
886
887         * linespec.c (symtab_vector_up): Define.
888         (struct linespec) <file_symtabs>: Change type to std::vector *.
889         Update all uses.
890         (struct collect_info) <file_symtabs>: Likewise.
891         (collect_symtabs_from_filename): Return symtab_vector_up.
892         Update all callers.
893         (decode_objc): Remove cleanup.
894         (symtab_collector::symtab_collector): Initialize `m_symtabs'.
895         (symtab_collector::release_symtabs): Return symtab_vector_up.
896         Update all callers.
897         (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
898         Update all users.
899         (collect_symtabs_from_filename, symtabs_from_filename): Return
900         symtab_vector_up.  Update all callers.
901
902 2018-08-29  Tom Tromey  <tom@tromey.com>
903
904         * csky-tdep.c (csky_analyze_prologue): Use
905         core_addr_to_string_nz.
906
907 2018-08-29  Tom Tromey  <tom@tromey.com>
908
909         * windows-nat.c (struct xlate_exception) <them>: Change type to
910         DWORD.
911         (xlate): Fix formatting.  Remove last entry.
912         (struct xlate_exception, xlate): Comment out.
913         (windows_nat_target::resume): Use ranged for.
914
915 2018-08-29  Jim Wilson  <jimw@sifive.com>
916
917         * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
918         (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
919         of NT_PRFPREG.
920         (riscv_linux_nat_target::store_registers): Likewise.
921
922 2018-08-29  Sergio Durigan Junior  <sergiodj@redhat.com>
923
924         PR gdb/23555
925         PR gdb/23558
926         * gnulib/aclocal.m4: Regenerate.
927         * gnulib/config.in: Regenerate.
928         * gnulib/configure: Regenerate.
929         * gnulib/import/Makefile.am: Update.
930         * gnulib/import/Makefile.in: Update.
931         * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
932         * gnulib/import/_Noreturn.h: ... this.
933         * gnulib/import/alloca.in.h: Update.
934         * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
935         * gnulib/import/arg-nonnull.h: ... this.
936         * gnulib/import/assure.h: Update.
937         * gnulib/import/at-func.c: Update.
938         * gnulib/import/basename-lgpl.c: Update.
939         * gnulib/import/extra/snippet/c++defs.h: Rename to...
940         * gnulib/import/c++defs.h: ... this.
941         * gnulib/import/canonicalize-lgpl.c: Update.
942         * gnulib/import/cdefs.h: Update.
943         * gnulib/import/chdir-long.c: Update.
944         * gnulib/import/chdir-long.h: Update.
945         * gnulib/import/cloexec.c: Update.
946         * gnulib/import/cloexec.h: Update.
947         * gnulib/import/close.c: Update.
948         * gnulib/import/closedir.c: Update.
949         * gnulib/import/config.charset: Update.
950         * gnulib/import/dirent-private.h: Update.
951         * gnulib/import/dirent.in.h: Update.
952         * gnulib/import/dirfd.c: Update.
953         * gnulib/import/dirname-lgpl.c: Update.
954         * gnulib/import/dirname.h: Update.
955         * gnulib/import/dosname.h: Update.
956         * gnulib/import/dup-safer-flag.c: Update.
957         * gnulib/import/dup-safer.c: Update.
958         * gnulib/import/dup.c: Update.
959         * gnulib/import/dup2.c: Update.
960         * gnulib/import/errno.in.h: Update.
961         * gnulib/import/error.c: Update.
962         * gnulib/import/error.h: Update.
963         * gnulib/import/exitfail.c: Update.
964         * gnulib/import/exitfail.h: Update.
965         * gnulib/import/extra/update-copyright: Update.
966         * gnulib/import/fchdir.c: Update.
967         * gnulib/import/fcntl.c: Update.
968         * gnulib/import/fcntl.in.h: Update.
969         * gnulib/import/fd-hook.c: Update.
970         * gnulib/import/fd-hook.h: Update.
971         * gnulib/import/fd-safer-flag.c: Update.
972         * gnulib/import/fd-safer.c: Update.
973         * gnulib/import/fdopendir.c: Update.
974         * gnulib/import/filename.h: Update.
975         * gnulib/import/filenamecat-lgpl.c: Update.
976         * gnulib/import/filenamecat.h: Update.
977         * gnulib/import/flexmember.h: Update.
978         * gnulib/import/float+.h: Update.
979         * gnulib/import/float.c: Update.
980         * gnulib/import/float.in.h: Update.
981         * gnulib/import/fnmatch.c: Update.
982         * gnulib/import/fnmatch.in.h: Update.
983         * gnulib/import/fnmatch_loop.c: Update.
984         * gnulib/import/fpucw.h: Update.
985         * gnulib/import/frexp.c: Update.
986         * gnulib/import/frexpl.c: Update.
987         * gnulib/import/fstat.c: Update.
988         * gnulib/import/fstatat.c: Update.
989         * gnulib/import/getcwd-lgpl.c: Update.
990         * gnulib/import/getcwd.c: Update.
991         * gnulib/import/getdtablesize.c: Update.
992         * gnulib/import/getlogin_r.c: Update.
993         * gnulib/import/getprogname.c: Update.
994         * gnulib/import/getprogname.h: Update.
995         * gnulib/import/gettext.h: Update.
996         * gnulib/import/gettimeofday.c: Update.
997         * gnulib/import/glob-libc.h: Update.
998         * gnulib/import/glob.c: Update.
999         * gnulib/import/glob.in.h: Update.
1000         * gnulib/import/glob_internal.h: Update.
1001         * gnulib/import/glob_pattern_p.c: Update.
1002         * gnulib/import/globfree.c: Update.
1003         * gnulib/import/hard-locale.c: Update.
1004         * gnulib/import/hard-locale.h: Update.
1005         * gnulib/import/intprops.h: Update.
1006         * gnulib/import/inttypes.in.h: Update.
1007         * gnulib/import/isnan.c: Update.
1008         * gnulib/import/isnand-nolibm.h: Update.
1009         * gnulib/import/isnand.c: Update.
1010         * gnulib/import/isnanl-nolibm.h: Update.
1011         * gnulib/import/isnanl.c: Update.
1012         * gnulib/import/itold.c: Update.
1013         * gnulib/import/libc-config.h: Update.
1014         * gnulib/import/limits.in.h: Update.
1015         * gnulib/import/localcharset.c: Update.
1016         * gnulib/import/localcharset.h: Update.
1017         * gnulib/import/localtime-buffer.c: Update.
1018         * gnulib/import/localtime-buffer.h: Update.
1019         * gnulib/import/lstat.c: Update.
1020         * gnulib/import/m4/00gnulib.m4: Update.
1021         * gnulib/import/m4/__inline.m4: Update.
1022         * gnulib/import/m4/absolute-header.m4: Update.
1023         * gnulib/import/m4/alloca.m4: Update.
1024         * gnulib/import/m4/builtin-expect.m4: Update.
1025         * gnulib/import/m4/canonicalize.m4: Update.
1026         * gnulib/import/m4/chdir-long.m4: Update.
1027         * gnulib/import/m4/close.m4: Update.
1028         * gnulib/import/m4/closedir.m4: Update.
1029         * gnulib/import/m4/configmake.m4: Update.
1030         * gnulib/import/m4/d-ino.m4: Update.
1031         * gnulib/import/m4/d-type.m4: Update.
1032         * gnulib/import/m4/dirent_h.m4: Update.
1033         * gnulib/import/m4/dirfd.m4: Update.
1034         * gnulib/import/m4/dirname.m4: Update.
1035         * gnulib/import/m4/double-slash-root.m4: Update.
1036         * gnulib/import/m4/dup.m4: Update.
1037         * gnulib/import/m4/dup2.m4: Update.
1038         * gnulib/import/m4/eealloc.m4: Update.
1039         * gnulib/import/m4/environ.m4: Update.
1040         * gnulib/import/m4/errno_h.m4: Update.
1041         * gnulib/import/m4/error.m4: Update.
1042         * gnulib/import/m4/exponentd.m4: Update.
1043         * gnulib/import/m4/exponentl.m4: Update.
1044         * gnulib/import/m4/extensions.m4: Update.
1045         * gnulib/import/m4/extern-inline.m4: Update.
1046         * gnulib/import/m4/fchdir.m4: Update.
1047         * gnulib/import/m4/fcntl-o.m4: Update.
1048         * gnulib/import/m4/fcntl.m4: Update.
1049         * gnulib/import/m4/fcntl_h.m4: Update.
1050         * gnulib/import/m4/fdopendir.m4: Update.
1051         * gnulib/import/m4/filenamecat.m4: Update.
1052         * gnulib/import/m4/flexmember.m4: Update.
1053         * gnulib/import/m4/float_h.m4: Update.
1054         * gnulib/import/m4/fnmatch.m4: Update.
1055         * gnulib/import/m4/fnmatch_h.m4: Update.
1056         * gnulib/import/m4/fpieee.m4: Update.
1057         * gnulib/import/m4/frexp.m4: Update.
1058         * gnulib/import/m4/frexpl.m4: Update.
1059         * gnulib/import/m4/fstat.m4: Update.
1060         * gnulib/import/m4/fstatat.m4: Update.
1061         * gnulib/import/m4/getcwd-abort-bug.m4: Update.
1062         * gnulib/import/m4/getcwd-path-max.m4: Update.
1063         * gnulib/import/m4/getcwd.m4: Update.
1064         * gnulib/import/m4/getdtablesize.m4: Update.
1065         * gnulib/import/m4/getlogin.m4: Update.
1066         * gnulib/import/m4/getlogin_r.m4: Update.
1067         * gnulib/import/m4/getpagesize.m4: Update.
1068         * gnulib/import/m4/getprogname.m4: Update.
1069         * gnulib/import/m4/gettimeofday.m4: Update.
1070         * gnulib/import/m4/glibc21.m4: Update.
1071         * gnulib/import/m4/glob.m4: Update.
1072         * gnulib/import/m4/glob_h.m4: Update.
1073         * gnulib/import/m4/gnulib-cache.m4: Update.
1074         * gnulib/import/m4/gnulib-common.m4: Update.
1075         * gnulib/import/m4/gnulib-comp.m4: Update.
1076         * gnulib/import/m4/gnulib-tool.m4: Update.
1077         * gnulib/import/m4/hard-locale.m4: Update.
1078         * gnulib/import/m4/include_next.m4: Update.
1079         * gnulib/import/m4/inttypes-pri.m4: Update.
1080         * gnulib/import/m4/inttypes.m4: Update.
1081         * gnulib/import/m4/isnand.m4: Update.
1082         * gnulib/import/m4/isnanl.m4: Update.
1083         * gnulib/import/m4/largefile.m4: Update.
1084         * gnulib/import/m4/limits-h.m4: Update.
1085         * gnulib/import/m4/localcharset.m4: Update.
1086         * gnulib/import/m4/locale-fr.m4: Update.
1087         * gnulib/import/m4/locale-ja.m4: Update.
1088         * gnulib/import/m4/locale-zh.m4: Update.
1089         * gnulib/import/m4/localtime-buffer.m4: Update.
1090         * gnulib/import/m4/longlong.m4: Update.
1091         * gnulib/import/m4/lstat.m4: Update.
1092         * gnulib/import/m4/malloc.m4: Update.
1093         * gnulib/import/m4/malloca.m4: Update.
1094         * gnulib/import/m4/math_h.m4: Update.
1095         * gnulib/import/m4/mbrtowc.m4: Update.
1096         * gnulib/import/m4/mbsinit.m4: Update.
1097         * gnulib/import/m4/mbsrtowcs.m4: Update.
1098         * gnulib/import/m4/mbstate_t.m4: Update.
1099         * gnulib/import/m4/memchr.m4: Update.
1100         * gnulib/import/m4/memmem.m4: Update.
1101         * gnulib/import/m4/mempcpy.m4: Update.
1102         * gnulib/import/m4/memrchr.m4: Update.
1103         * gnulib/import/m4/mkdir.m4: Update.
1104         * gnulib/import/m4/mkstemp.m4: Update.
1105         * gnulib/import/m4/mmap-anon.m4: Update.
1106         * gnulib/import/m4/mode_t.m4: Update.
1107         * gnulib/import/m4/msvc-inval.m4: Update.
1108         * gnulib/import/m4/msvc-nothrow.m4: Update.
1109         * gnulib/import/m4/multiarch.m4: Update.
1110         * gnulib/import/m4/nocrash.m4: Update.
1111         * gnulib/import/m4/off_t.m4: Update.
1112         * gnulib/import/m4/onceonly.m4: Update.
1113         * gnulib/import/m4/open-cloexec.m4: Update.
1114         * gnulib/import/m4/open.m4: Update.
1115         * gnulib/import/m4/openat.m4: Update.
1116         * gnulib/import/m4/opendir.m4: Update.
1117         * gnulib/import/m4/pathmax.m4: Update.
1118         * gnulib/import/m4/rawmemchr.m4: Update.
1119         * gnulib/import/m4/readdir.m4: Update.
1120         * gnulib/import/m4/readlink.m4: Update.
1121         * gnulib/import/m4/realloc.m4: Update.
1122         * gnulib/import/m4/rename.m4: Update.
1123         * gnulib/import/m4/rewinddir.m4: Update.
1124         * gnulib/import/m4/rmdir.m4: Update.
1125         * gnulib/import/m4/save-cwd.m4: Update.
1126         * gnulib/import/m4/secure_getenv.m4: Update.
1127         * gnulib/import/m4/setenv.m4: Update.
1128         * gnulib/import/m4/signal_h.m4: Update.
1129         * gnulib/import/m4/ssize_t.m4: Update.
1130         * gnulib/import/m4/stat-time.m4: Update.
1131         * gnulib/import/m4/stat.m4: Update.
1132         * gnulib/import/m4/std-gnu11.m4: Update.
1133         * gnulib/import/m4/stdbool.m4: Update.
1134         * gnulib/import/m4/stddef_h.m4: Update.
1135         * gnulib/import/m4/stdint.m4: Update.
1136         * gnulib/import/m4/stdio_h.m4: Update.
1137         * gnulib/import/m4/stdlib_h.m4: Update.
1138         * gnulib/import/m4/strchrnul.m4: Update.
1139         * gnulib/import/m4/strdup.m4: Update.
1140         * gnulib/import/m4/strerror.m4: Update.
1141         * gnulib/import/m4/string_h.m4: Update.
1142         * gnulib/import/m4/strstr.m4: Update.
1143         * gnulib/import/m4/strtok_r.m4: Update.
1144         * gnulib/import/m4/sys_socket_h.m4: Update.
1145         * gnulib/import/m4/sys_stat_h.m4: Update.
1146         * gnulib/import/m4/sys_time_h.m4: Update.
1147         * gnulib/import/m4/sys_types_h.m4: Update.
1148         * gnulib/import/m4/tempname.m4: Update.
1149         * gnulib/import/m4/time_h.m4: Update.
1150         * gnulib/import/m4/unistd-safer.m4: Update.
1151         * gnulib/import/m4/unistd_h.m4: Update.
1152         * gnulib/import/m4/warn-on-use.m4: Update.
1153         * gnulib/import/m4/wchar_h.m4: Update.
1154         * gnulib/import/m4/wchar_t.m4: Update.
1155         * gnulib/import/m4/wctype_h.m4: Update.
1156         * gnulib/import/m4/wint_t.m4: Update.
1157         * gnulib/import/malloc.c: Update.
1158         * gnulib/import/malloc/scratch_buffer.h: Update.
1159         * gnulib/import/malloc/scratch_buffer_grow.c: Update.
1160         * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
1161         * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
1162         * gnulib/import/malloca.c: Update.
1163         * gnulib/import/malloca.h: Update.
1164         * gnulib/import/malloca.valgrind: Update.
1165         * gnulib/import/math.in.h: Update.
1166         * gnulib/import/mbrtowc.c: Update.
1167         * gnulib/import/mbsinit.c: Update.
1168         * gnulib/import/mbsrtowcs-impl.h: Update.
1169         * gnulib/import/mbsrtowcs-state.c: Update.
1170         * gnulib/import/mbsrtowcs.c: Update.
1171         * gnulib/import/memchr.c: Update.
1172         * gnulib/import/memmem.c: Update.
1173         * gnulib/import/mempcpy.c: Update.
1174         * gnulib/import/memrchr.c: Update.
1175         * gnulib/import/mkdir.c: Update.
1176         * gnulib/import/mkstemp.c: Update.
1177         * gnulib/import/msvc-inval.c: Update.
1178         * gnulib/import/msvc-inval.h: Update.
1179         * gnulib/import/msvc-nothrow.c: Update.
1180         * gnulib/import/msvc-nothrow.h: Update.
1181         * gnulib/import/open.c: Update.
1182         * gnulib/import/openat-die.c: Update.
1183         * gnulib/import/openat-priv.h: Update.
1184         * gnulib/import/openat-proc.c: Update.
1185         * gnulib/import/openat.c: Update.
1186         * gnulib/import/openat.h: Update.
1187         * gnulib/import/opendir.c: Update.
1188         * gnulib/import/pathmax.h: Update.
1189         * gnulib/import/pipe-safer.c: Update.
1190         * gnulib/import/rawmemchr.c: Update.
1191         * gnulib/import/readdir.c: Update.
1192         * gnulib/import/readlink.c: Update.
1193         * gnulib/import/realloc.c: Update.
1194         * gnulib/import/ref-add.sin: Update.
1195         * gnulib/import/ref-del.sin: Update.
1196         * gnulib/import/rename.c: Update.
1197         * gnulib/import/rewinddir.c: Update.
1198         * gnulib/import/rmdir.c: Update.
1199         * gnulib/import/same-inode.h: Update.
1200         * gnulib/import/save-cwd.c: Update.
1201         * gnulib/import/save-cwd.h: Update.
1202         * gnulib/import/scratch_buffer.h: Update.
1203         * gnulib/import/secure_getenv.c: Update.
1204         * gnulib/import/setenv.c: Update.
1205         * gnulib/import/signal.in.h: Update.
1206         * gnulib/import/stat-time.c: Update.
1207         * gnulib/import/stat-time.h: Update.
1208         * gnulib/import/stat-w32.c: Update.
1209         * gnulib/import/stat-w32.h: Update.
1210         * gnulib/import/stat.c: Update.
1211         * gnulib/import/stdbool.in.h: Update.
1212         * gnulib/import/stddef.in.h: Update.
1213         * gnulib/import/stdint.in.h: Update.
1214         * gnulib/import/stdio.in.h: Update.
1215         * gnulib/import/stdlib.in.h: Update.
1216         * gnulib/import/str-two-way.h: Update.
1217         * gnulib/import/strchrnul.c: Update.
1218         * gnulib/import/strdup.c: Update.
1219         * gnulib/import/streq.h: Update.
1220         * gnulib/import/strerror-override.c: Update.
1221         * gnulib/import/strerror-override.h: Update.
1222         * gnulib/import/strerror.c: Update.
1223         * gnulib/import/string.in.h: Update.
1224         * gnulib/import/stripslash.c: Update.
1225         * gnulib/import/strnlen1.c: Update.
1226         * gnulib/import/strnlen1.h: Update.
1227         * gnulib/import/strstr.c: Update.
1228         * gnulib/import/strtok_r.c: Update.
1229         * gnulib/import/sys_stat.in.h: Update.
1230         * gnulib/import/sys_time.in.h: Update.
1231         * gnulib/import/sys_types.in.h: Update.
1232         * gnulib/import/tempname.c: Update.
1233         * gnulib/import/tempname.h: Update.
1234         * gnulib/import/time.in.h: Update.
1235         * gnulib/import/unistd--.h: Update.
1236         * gnulib/import/unistd-safer.h: Update.
1237         * gnulib/import/unistd.in.h: Update.
1238         * gnulib/import/unsetenv.c: Update.
1239         * gnulib/import/verify.h: Update.
1240         * gnulib/import/extra/snippet/warn-on-use.h: Update.
1241         * gnulib/import/wchar.in.h: Update.
1242         * gnulib/import/wctype.in.h: Update.
1243         * gnulib/import/xalloc-oversized.h: Update.
1244         * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
1245         "53e2c179f26a890fa6685af4b6c1397ee370433b".
1246
1247 2018-08-16  Gary Benson <gbenson@redhat.com>
1248
1249         PR gdb/13000:
1250         * gdb/main.c (captured_main_1): Exit with nonzero status
1251         in batch mode if the last command to be executed failed.
1252         * NEWS: Mention the above.
1253
1254 2018-08-29  Simon Marchi  <simon.marchi@ericsson.com>
1255
1256         * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
1257         end of warning message.
1258
1259 2018-08-29  Alan Hayward  <alan.hayward@arm.com>
1260
1261         PR gdb/22943:
1262         * aarch64-tdep.c (is_hfa_or_hva): Remove function.
1263         (aarch64_extract_return_value): Use
1264         aapcs_is_vfp_call_or_return_candidate.
1265         (aarch64_return_in_memory): Likewise.
1266         (aarch64_store_return_value): Likewise.
1267
1268 2018-08-29  Alan Hayward  <alan.hayward@arm.com>
1269
1270         * aarch64-tdep.c
1271         (aapcs_is_vfp_call_or_return_candidate): Make static
1272         (pass_in_v_or_stack): Remove function.
1273         (pass_in_v_vfp_candidate): New function.
1274         (aarch64_push_dummy_call): Check for float register candidates.
1275
1276 2018-08-29  Alan Hayward  <alan.hayward@arm.com>
1277
1278         * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
1279         (aapcs_is_vfp_call_or_return_candidate_1): New function.
1280         (aapcs_is_vfp_call_or_return_candidate): Likewise.
1281
1282 2018-08-28  Simon Marchi  <simon.marchi@polymtl.ca>
1283
1284         PR build/23399
1285         * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
1286         (struct ipa_sym_addresses): Rename to...
1287         (struct ipa_sym_addresses_common): ... this.
1288         * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
1289
1290 2018-08-28  Tom Tromey  <tom@tromey.com>
1291
1292         * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1293         (token_fifo): Now a std::vector.
1294         (yylex, c_parse): Update.
1295         * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1296         (token_fifo): Now a std::vector.
1297         (yylex, d_parse): Update.
1298         * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1299         (token_fifo): Now a std::vector.
1300         (yylex, go_parse): Update.
1301
1302 2018-08-28  Simon Marchi  <simon.marchi@ericsson.com>
1303
1304         * parser-defs.h (struct type_stack) <elements>: Change type to
1305         std::vector<union type_stack_elt>.
1306         <depth, size>: Remove.
1307         * parse.c (parse_exp_in_context_1): Adjust.
1308         (type_stack_reserve): Remove.
1309         (check_type_stack_depth): Remove.
1310         (insert_into_type_stack): Adjust to std::vector.
1311         (insert_type): Likewise.
1312         (push_type): Likewise.
1313         (push_type_int): Likewise.
1314         (insert_type_address_space): Likewise.
1315         (pop_type): Likewise.
1316         (pop_type_int): Likewise.
1317         (pop_typelist): Likewise.
1318         (pop_type_stack): Likewise.
1319         (append_type_stack): Likewise.
1320         (push_type_stack): Likewise.
1321         (get_type_stack): Likewise.
1322         (type_stack_cleanup): Likewise.
1323         (push_typelist): Likewise.
1324         (follow_types): Likewise.
1325         (_initialize_parse): Likewise.
1326
1327 2018-08-28  Hafiz Abid Qadeer  <abidh@codesourcery.com>
1328
1329         * NEWS: Mention csky target.
1330
1331 2018-08-28  Jiangshuai Li  <jiangshuai_li@c-sky.com>
1332             Hafiz Abid Qadeer  <abidh@codesourcery.com>
1333             Don Breazeal  <donb@codesourcery.com>
1334
1335         * csky-linux-tdep.c: New file.
1336         * csky-tdep.c: Likewise.
1337         * csky-tdep.h: Likewise.
1338         * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
1339         csky-tdep.o.
1340         (HFILES_NO_SRCDIR): Add csky-tdep.h.
1341         (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
1342         * configure.tgt: Add csky support.
1343
1344 2018-08-27  Jan Vrany  <jan.vrany@fit.cvut.cz>
1345
1346         * python/py-framefilter.c (py_print_frame): Print frame architecture
1347         when printing on an MI output.
1348
1349 2018-08-27  Tom Tromey  <tom@tromey.com>
1350
1351         PR build/23087:
1352         * configure: Rebuild.
1353         * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
1354
1355 2018-08-27  Tom Tromey  <tom@tromey.com>
1356
1357         * aarch64-linux-tdep.c
1358         (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
1359         casts to int.
1360
1361 2018-08-27  Tom Tromey  <tom@tromey.com>
1362
1363         * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
1364         unsigned.
1365         (ppc64_standard_linkage1, ppc64_standard_linkage2)
1366         (ppc64_standard_linkage3, ppc64_standard_linkage4)
1367         (ppc64_standard_linkage5, ppc64_standard_linkage6)
1368         (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
1369         unsigned.
1370
1371 2018-08-27  Tom Tromey  <tom@tromey.com>
1372
1373         * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
1374         (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
1375
1376 2018-08-27  Tom Tromey  <tom@tromey.com>
1377
1378         * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
1379         * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
1380         ULONGEST_MAX.
1381         * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
1382         ULONGEST_MAX.
1383         * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
1384         ULONGEST_MAX.
1385         * sparc-linux-tdep.c (sparc32_linux_sigframe)
1386         (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
1387         * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
1388         ULONGEST_MAX.
1389         * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
1390         (ppc64_linux_sigaction_tramp_frame)
1391         (ppc32_linux_sighandler_tramp_frame)
1392         (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1393         * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
1394         (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
1395         * mn10300-linux-tdep.c (am33_linux_sigframe)
1396         (am33_linux_rt_sigframe): Use ULONGEST_MAX.
1397         * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
1398         * mips-linux-tdep.c (mips_linux_o32_sigframe)
1399         (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
1400         (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
1401         (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
1402         (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
1403         * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
1404         (mips64_fbsd_sigframe): Use ULONGEST_MAX.
1405         * microblaze-linux-tdep.c
1406         (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1407         * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
1408         (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
1409         (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
1410         * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
1411         * common/common-types.h (ULONGEST_MAX): New define.
1412         (CORE_ADDR_MAX): Fix formatting.
1413         * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
1414         * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
1415         * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
1416         (arm_linux_rt_sigreturn_tramp_frame)
1417         (arm_eabi_linux_sigreturn_tramp_frame)
1418         (arm_eabi_linux_rt_sigreturn_tramp_frame)
1419         (thumb2_eabi_linux_sigreturn_tramp_frame)
1420         (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
1421         (arm_linux_restart_syscall_tramp_frame)
1422         (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
1423         * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
1424         * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
1425         ULONGEST_MAX.
1426         * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
1427
1428 2018-08-27  Tom Tromey  <tom@tromey.com>
1429
1430         * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
1431         CORE_ADDR_MAX.
1432         * mips-tdep.c (mips_deal_with_atomic_sequence)
1433         (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
1434         * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
1435         (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
1436         * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
1437         CORE_ADDR_MAX.
1438         * aarch64-tdep.c (aarch64_software_single_step): Use
1439         CORE_ADDR_MAX.
1440
1441 2018-08-27  Tom Tromey  <tom@tromey.com>
1442
1443         * linespec.c (complete_linespec_component): Add cast to "char".
1444         * completer.c (completion_tracker::build_completion_result): Add
1445         cast to "char".
1446
1447 2018-08-26  Simon Marchi  <simon.marchi@polymtl.ca>
1448
1449         * solist.h (struct solist, struct target_so_ops): Fix
1450         indentation.
1451
1452 2018-08-26  Simon Marchi  <simon.marchi@polymtl.ca>
1453
1454         * ada-tasks.c (ada_task_info_s): Remove typedef.
1455         (DEF_VEC_O(ada_task_info_s)): Remove.
1456         (struct ada_tasks_inferior_data): Initialize fields.
1457         <task_list>: Make an std::vector.
1458         (get_ada_tasks_inferior_data): Allocate with new.
1459         (ada_get_task_number): Adjust.
1460         (get_task_number_from_id): Likewise.
1461         (valid_task_id): Likewise.
1462         (ada_get_task_info_from_ptid): Likewise.
1463         (iterate_over_live_ada_tasks): Likewise.
1464         (add_ada_task): Likewise.
1465         (read_known_tasks): Likewise.
1466         (ada_build_task_list): Likewise.
1467         (print_ada_task_info): Likewise.
1468         (info_task): Likewise.
1469         (task_command_1): Likewise.
1470
1471 2018-08-26  Simon Marchi  <simon.marchi@polymtl.ca>
1472
1473         * ada-lang.c (add_angle_brackets): Return std::string.
1474
1475 2018-08-25  Simon Marchi  <simon.marchi@polymtl.ca>
1476
1477         * python/py-threadevent.c (py_get_event_thread): Initialize
1478         pythread.
1479
1480 2018-08-24  Pedro Alves  <palves@redhat.com>
1481
1482         * python/py-bpevent.c (create_breakpoint_event_object): Use
1483         copy-initialization.
1484         * python/py-continueevent.c (emit_continue_event): Use
1485         copy-initialization.
1486         * python/py-exitedevent.c (create_exited_event_object): Return a
1487         gdbpy_ref<>.
1488         (emit_exited_event): Use copy-initialization.
1489         * python/py-inferior.c (python_new_inferior)
1490         (python_inferior_deleted, add_thread_object): Use
1491         copy-initialization.
1492         * python/py-infevents.c (create_inferior_call_event_object)
1493         (create_register_changed_event_object)
1494         (create_memory_changed_event_object): Return a gdbpy_ref<>.
1495         (emit_inferior_call_event, emit_memory_changed_event)
1496         (emit_register_changed_event): Use copy-initialization.
1497         * python/py-newobjfileevent.c (create_new_objfile_event_object):
1498         Return a gdbpy_ref<>.
1499         (emit_new_objfile_event): Use copy-initialization.
1500         (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
1501         (emit_clear_objfiles_event): Use copy-initialization.
1502         * python/py-signalevent.c (create_signal_event_object): Use
1503         copy-initialization.
1504         * python/py-threadevent.c (create_thread_event_object): Use
1505         copy-initialization.
1506
1507 2018-08-24  Pedro Alves  <palves@redhat.com>
1508             Simon Marchi  <simon.marchi@ericsson.com>
1509
1510         PR gdb/23379
1511         * python/py-continueevent.c: Include "gdbthread.h".
1512         (create_continue_event_object): Add intro comment.  Add 'ptid'
1513         parameter.  Use it to find thread to pass to
1514         create_thread_event_object.
1515         (emit_continue_event): Pass PTID down to
1516         create_continue_event_object.
1517         * python/py-event.h (py_get_event_thread): Declare.
1518         (create_thread_event_object): Remove default from 'thread'
1519         parameter.
1520         * python/py-stopevent.c (create_stop_event_object): Use
1521         py_get_event_thread.
1522         * python/py-threadevent.c (get_event_thread): Rename to ...
1523         (py_get_event_thread): ... this, make extern, add 'ptid' parameter
1524         and use it to find the thread.
1525         (create_thread_event_object): Assert that THREAD isn't null.
1526         Don't find the event thread here.
1527
1528 2018-08-23  Kevin Buettner  <kevinb@redhat.com>
1529
1530         * block.h (blockrange, blockranges): New struct declarations.
1531         (struct block): Add new field named `ranges'.
1532         (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
1533         (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
1534         macros for accessing ranges in struct block.
1535         (make_blockranges): New declaration.
1536         block.c (make_blockranges): New function.
1537         * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
1538         for block.
1539         * symtab.h (find_pc_partial_function): Add new parameter `block'.
1540         * blockframe.c (cache_pc_function_block): New static global.
1541         (clear_pc_function_cache): Clear cache_pc_function_block.
1542         (find_pc_partial_function): Move comment to symtab.h.  Add
1543         support for non-contiguous blocks.
1544         * cli/cli-cmds.c (block.h): Include.
1545         (print_disassembly): Handle printing of non-contiguous blocks.
1546         (disassemble_current_function): Likewise.
1547         (disassemble_command): Likewise.
1548
1549         * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
1550         BLOCK_START.
1551         * blockframe.c (get_pc_function_start): Likewise.
1552         * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
1553         (gcc_symbol_address): Likewise.
1554         * compile/compile-object-run.c (compile_object_run): Likewise.
1555         * compile/compile.c (get_expr_block_and_pc): Likewise.
1556         * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
1557         (func_addr_to_tail_call_list): Likewise.
1558         * findvar.c (default_read_var_value): Likewise.
1559         * inline-frame.c (inline_frame_this_id): Likewise.
1560         (skip-inline_frames): Likewise.
1561         * infcmd.c (until_next_command): Likewise.
1562         * linespec.c (convert_linespec_to_sals): Likewise.
1563         * parse.c (parse_exp_in_context_1): Likewise.
1564         * printcmd.c (build_address_symbolic): likewise.
1565         (info_address_command): Likewise.
1566         symtab.c (find_function_start_sal): Likewise.
1567         (skip_prologue_sal): Likewise.
1568         (find_function_alias_target): Likewise.
1569         (find_gnu_ifunc): Likewise.
1570         * stack.c (find_frame_funname): Likewise.
1571         * symtab.c (fixup_symbol_section): Likewise.
1572         (find_function_start_sal): Likewise.
1573         (skip_prologue_sal): Likewsie.
1574         (find_function_alias_target): Likewise.
1575         (find_gnu_ifunc): Likewise.
1576         * tracepoint.c (info_scope_command): Likewise.
1577         * value.c (value_fn_field): Likewise.
1578
1579         * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
1580         in place of find_pc_partial_function.
1581         * blockframe.c (find_function_entry_range_from_pc): New function.
1582         * symtab.h (find_function_entry_range_from_pc): Declare and document.
1583         * objfiles.c (objfile_relocate1): Relocate start and end addresses
1584         for each range in a block.
1585
1586
1587 2018-08-23  Xavier Roirand  <roirand@adacore.com>
1588
1589         * machoread.c (macho_symfile_read_all_oso): Remove uneeded
1590         incrementation.
1591
1592 2018-08-22  Simon Marchi  <simon.marchi@polymtl.ca>
1593
1594         * solib-svr4.c (read_program_headers_from_bfd): Return
1595         gdb::optional<gdb::byte_vector>.
1596         (svr4_exec_displacement): Adjust.
1597
1598 2018-08-22  Simon Marchi  <simon.marchi@polymtl.ca>
1599
1600         * solib-svr4.c (read_program_header): Return
1601         gdb::optional<gdb::byte_vector>, remove p_sect_size param.
1602         (find_program_interpreter): Return
1603         gdb::optional<gdb::byte_vector>.
1604         (scan_dyntag_auxv): Adjust.
1605         (enable_break): Adjust.
1606         (svr4_exec_displacement): Adjust.
1607
1608 2018-08-22  Simon Marchi  <simon.marchi@polymtl.ca>
1609
1610         * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
1611         * inf-child.c (inf_child_target::terminal_save_inferior): New.
1612
1613 2018-08-22  Simon Marchi  <simon.marchi@polymtl.ca>
1614
1615         * guile/scm-string.c (gdbscm_scm_from_printf): Use
1616         string_vprintf.
1617         * guile/scm-utils.c (gdbscm_printf): Likewise.
1618         * serial.c (serial_printf): Likewise.
1619         * xml-support.c (gdb_xml_parser::vdebug): Likewise.
1620
1621 2018-08-22  Jan Vrany  <jan.vrany@fit.cvut.cz>
1622
1623         * stack.c (print_frame): Print frame architecture when printing on
1624         an MI output.
1625         * NEWS: Mention new "arch" attribute in frame output.
1626
1627 2018-08-21  Alan Hayward  <alan.hayward@arm.com>
1628
1629         * arch/aarch64.h (aarch64_regnum): Update comment.
1630
1631 2018-08-21  Alan Hayward  <alan.hayward@arm.com>
1632
1633         * NEWS: Add SVE to 8.2 section.
1634
1635 2018-08-21  Pedro Alves  <palves@redhat.com>
1636
1637         * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
1638         out from gdbscm_parse_function_args.
1639         (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
1640         gdbscm_parse_function_args_1.
1641
1642 2018-08-21  Simon Marchi  <simon.marchi@ericsson.com>
1643
1644         PR gdb/17816
1645         * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
1646         operator.
1647
1648 2018-08-19  Simon Marchi  <simon.marchi@polymtl.ca>
1649
1650         * solib-svr4.c (svr4_exec_displacement): Fix formatting.
1651
1652 2018-08-19  Michael Spang  <spang@google.com>
1653
1654         PR gdb/11786
1655         * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
1656         for PT_TLS segments.
1657
1658 2018-08-18  Kevin Buettner  <kevinb@redhat.com>
1659
1660         * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
1661         dwarf_variable_value.
1662         * dwarf2-frame.c (class dwarf_expr_executor):
1663         Add override for dwarf_variable_value.
1664         * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
1665         (class symbol_needs_eval_context): Likewise.
1666         (indirect_synthetic_pointer): Add forward declaration.
1667         (sect_variable_value): New function.
1668         (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
1669         * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
1670         for DW_OP_GNU_variable_value.
1671
1672 2018-08-16  Tom Tromey  <tom@tromey.com>
1673
1674         * top.c (read_command_file): Update.
1675         (command_line_input): Remove "repeat" argument.
1676         * ada-lang.c (get_selections): Update.
1677         * linespec.c (decode_line_2): Update.
1678         * defs.h (command_line_input): Remove argument.
1679         * cli/cli-script.c (read_next_line): Update.
1680         * python/py-gdb-readline.c: Update.
1681
1682 2018-08-17  Tom Tromey  <tom@tromey.com>
1683
1684         * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
1685         command_line_input.
1686
1687 2018-08-15  Tom Tromey  <tom@tromey.com>
1688
1689         * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
1690
1691 2018-08-14  Jan Vrany  <jan.vrany@fit.cvut.cz>
1692
1693         * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
1694         If used, use find_pc_partial_function to find address range
1695         to disassemble.
1696         * mi/mi-main.c (mi_cmd_list_features): Report
1697         "data-disassemble-a-option" feature.
1698         * NEWS: Mention new -data-disassemble option -a.
1699
1700 2018-08-13  Tom Tromey  <tom@tromey.com>
1701
1702         * common/common-defs.h (_FORTIFY_SOURCE): Define.
1703
1704 2018-08-13  Alan Hayward  <alan.hayward@arm.com>
1705
1706         * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
1707         (aarch64_linux_collect_sve_regset): Likewise.
1708         (aarch64_linux_iterate_over_regset_sections): Check for SVE.
1709         * regcache.h (regcache_map_entry_size): New function.
1710
1711 2018-08-13  Alan Hayward  <alan.hayward@arm.com>
1712
1713         * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
1714         (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
1715         (SVE_HEADER_VL_LENGTH): Likewise.
1716         (SVE_HEADER_MAX_VL_LENGTH): Likewise.
1717         (SVE_HEADER_FLAGS_LENGTH): Likewise.
1718         (SVE_HEADER_RESERVED_LENGTH): Likewise.
1719         (SVE_HEADER_SIZE_OFFSET): Likewise.
1720         (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
1721         (SVE_HEADER_VL_OFFSET): Likewise.
1722         (SVE_HEADER_MAX_VL_OFFSET): Likewise.
1723         (SVE_HEADER_FLAGS_OFFSET): Likewise.
1724         (SVE_HEADER_RESERVED_OFFSET): Likewise.
1725         (SVE_HEADER_SIZE): Likewise.
1726         (aarch64_linux_core_read_vq): Add function.
1727         (aarch64_linux_core_read_description): Check for SVE section.
1728
1729 2018-08-13  Alan Hayward  <alan.hayward@arm.com>
1730
1731         * aarch64-fbsd-tdep.c
1732         (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
1733         collect_size.
1734         * aarch64-linux-tdep.c
1735         (aarch64_linux_iterate_over_regset_sections): Likewise.
1736         * alpha-linux-tdep.c
1737         (alpha_linux_iterate_over_regset_sections):
1738         * alpha-nbsd-tdep.c
1739         (alphanbsd_iterate_over_regset_sections): Likewise.
1740         * amd64-fbsd-tdep.c
1741         (amd64fbsd_iterate_over_regset_sections): Likewise.
1742         * amd64-linux-tdep.c
1743         (amd64_linux_iterate_over_regset_sections): Likewise.
1744         * arm-bsd-tdep.c
1745         (armbsd_iterate_over_regset_sections): Likewise.
1746         * arm-fbsd-tdep.c
1747         (arm_fbsd_iterate_over_regset_sections): Likewise.
1748         * arm-linux-tdep.c
1749         (arm_linux_iterate_over_regset_sections): Likewise.
1750         * corelow.c (get_core_registers_cb): Likewise.
1751         (core_target::fetch_registers): Likewise.
1752         * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
1753         * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
1754         * gdbarch.h (void): Regenerate.
1755         * gdbarch.sh: Add supply_size and collect_size.
1756         * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
1757         * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
1758         * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
1759         * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
1760         * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
1761         * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
1762         * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
1763         * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
1764         * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
1765         * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
1766         * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
1767         * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
1768         * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
1769         * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
1770         * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
1771         * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
1772         * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
1773         * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
1774         * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
1775         * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
1776         * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
1777         * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
1778         * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
1779         * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
1780         * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
1781         * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
1782         * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
1783         * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
1784         * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
1785         * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
1786
1787 2018-08-10  Simon Marchi  <simon.marchi@ericsson.com>
1788
1789         * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
1790         with string_printf.
1791
1792 2018-08-10  Keith Seitz  <keiths@redhat.com>
1793
1794         * compile/compile-c-support.c (add_code_header, add_code_footer):
1795         Move into policy class.
1796         (c_push_user_expression, pop_user_expression_nop)
1797         (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
1798         (compile_program): New host class.
1799         (c_compile_program): New typedef.
1800         (c_compute_porgram): Use c_compile_program.
1801
1802 2018-08-10  Keith Seitz  <keiths@redhat.com>
1803
1804         * compile/compile-internal.h (compile_instance::~compile_instance):
1805         Remove calls to htab_delete.
1806         <m_type_map, m_symbol_err_map>: Switch type to htab_up.
1807         * compile.c (compile_instance::compile_instance): Initialize
1808         htab unique pointers.
1809         (compile_instance::get_cached_type, compile_instance::insert_type)
1810         (compile_instance::error_symbol_once): Update for unique_ptr.
1811
1812 2018-08-10  Keith Seitz  <keiths@redhat.com>
1813
1814         * compile/compile-c-symbols.c (struct symbol_error)
1815         (hash_symbol_error, eq_symbol_error, del_symbol_error)
1816         (compile_instance::insert_symbol_error)
1817         (compile_instance::error_symbol_once): Move to ...
1818         * compile/compile.c: ... here.
1819
1820 2018-08-10  Keith Seitz  <keiths@redhat.com>
1821
1822         * compile/compile-c-support.c (c_get_compile_context): Use `new'
1823         instead of `new_compile_instance'.
1824         * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
1825         Update description.
1826         If the symbol error map is not initialized, create it.
1827         (generate_c_for_for_one_symbol): Do not check/initialize
1828         the symbol error map.
1829         * compile/compile-c-types.c (compile_c_instance): Make a class.
1830         Update all callers.
1831         (compile_instance::compile_instance): Initialize the type cache.
1832         (get_cached_type): New function.
1833         (insert_type): Update description.
1834         (compile_c_instance::m_default_cflags): Define.
1835         (convert_type): Update description.  Use get_cached_type.
1836         (delete_instance): Moved to destructor.
1837         (new_compile_instance): Moved to constructor.
1838         * compile/compile-c.h (compile_c_instance): Make class inheriting
1839         from compile_instance.
1840         <base>: Remove field.
1841         <type_map, symbol_err_map>: Move to base class.
1842         <c_plugin>: Rename to `m_plugin' and remove pointer type.
1843         * compile/compile-internal.h (compile_instance): Make class.
1844         <type_map_t, symbol_err_map_t>: Define.
1845         <fe>: Rename to `m_gcc_fe'.
1846         <scope, block, gcc_target_options>: Add `m_' prefix.
1847         <m_type_map, m_symbol_err_map>: New fields, moved from
1848         compile_c_instance.
1849         <destroy>: Remove.
1850         (convert_type, new_compile_instance): Remove.
1851         * compile/compile.c (cleanup_compile_instance): Remove.
1852         (compile_to_object): Use unique_ptr to eliminate cleanups.
1853         (compile_instance::set_print_callback, compile_instance::version)
1854         (compile_instance::set_verbose)
1855         (compile_instance::set_driver_filename)
1856         (compile_instance::set_triplet_regexp)
1857         (compile_instance::set_arguments)
1858         (compile_instance::set_source_file)
1859         (compile_instance::compile): Define.
1860
1861 2018-08-10  Keith Seitz  <keiths@redhat.com>
1862
1863         * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
1864         * compile/compile-c-types.c: Define GCC_METHODN macros and include
1865         gcc-c-fe.def to define C plugin.
1866         (delete_instance): Delete `c_plugin'.
1867         (new_compile_instance): Initialize `c_plugin'.
1868         * compile/compile-c.h: Include gcc_c_plugin.h.
1869         (struct compile_c_instance) <c_plugin>: New member.
1870         * gcc-c-plugin.h: New file.
1871         Update all callers with API change.
1872
1873 2018-08-10  Keith Seitz  <keiths@redhat.com>
1874
1875         * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
1876         (HFILES_NO_SRCDIR): ... to here.
1877         Add compile-internal.h and compile-c.h.
1878         * compile/compile-c-support.c: Include compile-c.h.
1879         * compile/compile-c-symbols.c: Include compile-c.h.
1880         (generate_c_for_variable_locations): Update comment.
1881         * compile/compile-c-types.c: Include compile-c.h.
1882         * compile/compile-c.h: New file -- moved C language declarations
1883         from other files here.
1884         * compile/compile-internal.h: Do not include hashtab.h or
1885         common/enum-flags.h.
1886         (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
1887         (gcc_convert_symbol, gcc_symbol_address)
1888         (generate_c_for_variable_locations, c_get_mode_for_size)
1889         (c_get_range_decl_name): Definitions moved to compile-c.h.
1890         * compile/compile-loc2c.c: Include compile-c.h.
1891
1892 2018-08-10  Keith Seitz  <keiths@redhat.com>
1893
1894         * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
1895         (c_symbol_substitution_name): ... this.
1896         Update all callers.
1897
1898 2018-08-10  Keith Seitz  <keiths@redhat.com>
1899
1900         * compile/compile-c-support.c (c_compute_program): Use
1901         unique_xmalloc_ptr to eliminate cleanup.
1902         * compile/compile-c-symbols.c (generate_c_for_variable_locations):
1903         Return a unique_xmalloc_ptr and eliminate cleanup.
1904         * compile/compile-internal.h (generate_c_for_variable_locations):
1905         Return unique_xmalloc_ptr and update description.
1906
1907 2018-08-10  Alan Hayward  <alan.hayward@arm.com>
1908
1909         * corelow.c (core_target::get_core_register_section): Rename
1910         min_size to section_min_size.
1911
1912 2018-08-09  Jim Wilson  <jimw@sifive.com>
1913
1914         * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
1915         (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
1916         * NEWS: Mention new GNU/Linux RISC-V target.
1917         * configure.host: Add riscv*-*-linux*.
1918         * configure.nat: Add riscv*.
1919         * configure.tgt: Add riscv*-*-linux*.
1920         * riscv-linux-nat.c: New file.
1921         * riscv-linux-tdep.c: New file.
1922
1923 2018-08-09  Andrew Burgess  <andrew.burgess@embecosm.com>
1924
1925         * infrun.c (resume): Make static, add forward declaration.
1926         (proceed): Update header comment.
1927         * infrun.h (resume): Delete declaration.
1928
1929 2018-08-09  Tom Tromey  <tom@tromey.com>
1930
1931         * riscv-tdep.h: Minor formatting fixes.
1932
1933 2018-08-09  Simon Marchi  <simon.marchi@ericsson.com>
1934
1935         * common/scoped_mmap.c (mmap_file): Silence ARI warning.
1936         * dwarf-index-cache.c (create_dir_and_check): Likewise.
1937         (test_mkdir_recursive): Likewise.
1938         * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
1939
1940 2018-08-09  Andrew Burgess  <andrew.burgess@embecosm.com>
1941
1942         * valarith.c (value_subscripted_rvalue): If an array is not in
1943         memory, and we don't know the upper bound, then we can't know that
1944         the requested element exists or not.
1945
1946 2018-08-08  Simon Marchi  <simon.marchi@ericsson.com>
1947
1948         * target.c (str_comma_list_concat_elem): Fix typo in comment.
1949         (target_options_to_string): Add comment.
1950
1951 2018-08-08  Tom Tromey  <tom@tromey.com>
1952
1953         * unittests/scoped_mmap-selftests.c: Check result of "write".
1954
1955 2018-08-08  Jim Wilson  <jimw@sifive.com>
1956
1957         * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
1958         (decode_register_index_short): New.
1959         (decode_j_type_insn, decode_cj_type_insn): New.
1960         (decode_b_type_insn, decode_cb_type_insn): New.
1961         (riscv_insn::decode): Add support for jumps, branches, lr, and sc.  New
1962         local xlen.  Check xlen when decoding ambiguous compressed insns.  In
1963         compressed decode, use is_c_lui_insn instead of is_lui_insn, and
1964         is_c_sw_insn instead of is_sw_insn.
1965         (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
1966         (riscv_software_single_step): New.
1967         * riscv-tdep.h (riscv_software_single_step): Declare.
1968
1969         * riscv-tdep.c (riscv_isa_xlen): Drop static.
1970         * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
1971
1972 2018-08-08  Andrew Burgess  <andrew.burgess@embecosm.com>
1973
1974         PR gdb/18050:
1975         * target.c (dispose_inferior): Don't dispose of inferiors that are
1976         already killed.
1977
1978 2018-08-08  Szabolcs Nagy  <szabolcs.nagy@arm.com>
1979
1980         * remote.c (remote_target::download_tracepoint): Change char* to
1981         const char*.
1982
1983 2018-08-07  Simon Marchi  <simon.marchi@polymtl.ca>
1984
1985         * target.h (target_options_to_string): Return an std::string.
1986         * target.c (str_comma_list_concat_elem): Return void, use
1987         std::string.
1988         (do_option): Likewise.
1989         (target_options_to_string): Return an std::string.
1990         * linux-nat.c (linux_nat_target::wait): Adjust.
1991         * target-debug.h (target_debug_print_options): Adjust.
1992
1993 2018-08-07  Tom Tromey  <tom@tromey.com>
1994
1995         * Makefile.in (CPPFLAGS): New variable.
1996         (INTERNAL_CPPFLAGS): Use it.
1997
1998 2018-08-07  Simon Marchi  <simon.marchi@ericsson.com>
1999
2000         * NEWS: Mention the index cache.
2001
2002 2018-08-07  Simon Marchi  <simon.marchi@ericsson.com>
2003
2004         * common/pathstuff.h (get_standard_cache_dir): New.
2005         * common/pathstuff.c (get_standard_cache_dir): New.
2006         * build-id.h (build_id_to_string): New.
2007         * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
2008         DEBUG_STR_SUFFIX): Move to here.
2009         * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
2010         DEBUG_STR_SUFFIX): Move from there.
2011         (write_psymtabs_to_index): Make non-static, add basename
2012         parameter.  Write to temporary files, rename when done.
2013         (save_gdb_index_command): Adjust call to
2014         write_psymtabs_to_index.
2015         * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
2016         field.
2017         * dwarf2read.c (dwz_file) <index_cache_res>: New field.
2018         (get_gdb_index_contents_from_cache): New.
2019         (get_gdb_index_contents_from_cache_dwz): New.
2020         (dwarf2_initialize_objfile): Read index from cache.
2021         (dwarf2_build_psymtabs): Save to index.
2022         * dwarf-index-cache.h: New file.
2023         * dwarf-index-cache.c: New file.
2024         * dwarf-index-write.h: New file.
2025
2026 2018-08-07  Simon Marchi  <simon.marchi@ericsson.com>
2027
2028         * gnulib/aclocal.m4: Re-generate.
2029         * gnulib/config.in: Re-generate.
2030         * gnulib/configure: Re-generate.
2031         * gnulib/import/Makefile.am: Re-generate.
2032         * gnulib/import/Makefile.in: Re-generate.
2033         * gnulib/import/m4/gnulib-cache.m4: Re-generate.
2034         * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2035         * gnulib/import/m4/mkdir.m4: New file.
2036         * gnulib/import/mkdir.c: New file.
2037         * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
2038         module.
2039
2040 2018-08-07  Simon Marchi  <simon.marchi@ericsson.com>
2041
2042         * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
2043         * common/scoped_mmap.c: New file.
2044         * common/scoped_mmap.h (destroy): New method.
2045         (~scoped_mmap, reset): Use destroy.
2046         (scoped_mmap): New move constructor.
2047         (mmap_file): New declaration.
2048         * unittests/scoped_mmap-selftests.c (test_normal,
2049         test_invalid_filename, run_tests): New functions.
2050         (_initialize_scoped_mmap_selftests): Register selftest.
2051
2052 2018-08-07  Simon Marchi  <simon.marchi@ericsson.com>
2053
2054         * dwarf2read.c (read_gdb_index_from_section): Rename to...
2055         (read_gdb_index_from_buffer): ... this.  Remove section
2056         parameter, add buffer parameter.
2057         (get_gdb_index_contents_ftype,
2058         get_gdb_index_contents_dwz_ftype): New typedefs.
2059         (dwarf2_read_gdb_index): Add callback parameters to get the
2060         index contents.
2061         (get_gdb_index_contents_from_section): New.
2062         (dwarf2_initialize_objfile): Update call to
2063         dwarf2_read_gdb_index.
2064
2065 2018-08-07  Simon Marchi  <simon.marchi@ericsson.com>
2066
2067         * common/filestuff.h (gdb_fopen_cloexec): New overload.
2068         (gdb_open_cloexec): Likewise.
2069         * nat/linux-osdata.c (command_from_pid): Use string_printf.
2070         (commandline_from_pid): Likewise.
2071         (linux_xfer_osdata_threads): Likewise.
2072         (linux_xfer_osdata_fds): Likewise.
2073         * ada-lang.c (is_package_name): Likewise.
2074         * auxv.c (procfs_xfer_auxv): Likewise.
2075         * breakpoint.c (print_one_breakpoint_location): Use
2076         uiout::field_fmt.
2077         (print_one_catch_solib): Use string_printf.
2078         * coff-pe-read.c (add_pe_exported_sym): Likewise.
2079         (add_pe_forwarded_sym): Likewise.
2080         * dwarf2read.c (create_type_unit_group): Likewise.
2081         (build_error_marker_type): Likewise.
2082         * infcall.c (get_function_name): Likewise.
2083         * valprint.c (print_converted_chars_to_obstack): Likewise.
2084         * xtensa-tdep.c (xtensa_register_type): Likewise.
2085
2086 2018-08-06  Simon Marchi  <simon.marchi@ericsson.com>
2087
2088         * remote.c (remote_target::download_tracepoint): Fix format
2089         string errors.
2090
2091 2018-08-06  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
2092
2093         * tracefile.c: Include common/byte-vector.h.
2094         (trace_save): Change type of buf to gdb::byte_vector.  Initialize
2095         with trace_regblock_size if needed.  Update uses of buf.
2096
2097 2018-08-06  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
2098
2099         * tracepoint.h (collection_list) <m_regs_mask>: Change type to
2100         std::vector<unsigned char>.
2101         * tracepoint.c (collection_list::collection_list): Remove
2102         m_regs_mask initializer from initializer list.  Resize
2103         m_regs_mask using the largest remote register number.
2104         (collection_list::add_remote_register): Remove size check on
2105         m_regs_mask.  Use at to access element.
2106         (collection_list::stringify): Change type of temp_buf to
2107         gdb::char_vector.  Update uses of temp_buf.  Resize if needed to
2108         stringify the register mask.  Use pack_hex_byte for the register
2109         mask.
2110
2111 2018-08-06  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
2112
2113         * tracepoint.h (class collection_list) <add_register>: Remove.
2114         <add_remote_register, add_ax_registers, add_local_register>:
2115         Declare.
2116         <add_memrange>: Add scope parameter.
2117         * tracepoint.c (encode_actions_1): Likewise.
2118         (collection_list::add_register): Rename to ...
2119         (collection_list::add_remote_register): ... this.  Update
2120         comment.
2121         (collection_list::add_ax_registers, add_local_register): New
2122         methods.
2123         (collection_list::add_memrange): Add scope parameter.  Call
2124         add_local_register instead of add_register.
2125         (finalize_tracepoint_aexpr): New function.
2126         (collection_list::collect_symbol): Update calls to add_memrange.
2127         Call add_local_register instead of add_register.  Call
2128         add_ax_registers.  Call finalize_tracepoint_aexpr.
2129         (encode_actions_1): Get remote regnos for $reg action.  Call
2130         add_remote_register, add_ax_registers, and add_local_register.
2131         Update call to add_memrange.  Call finalize_tracepoint_aexpr.
2132         (validate_actionline): Call finalize_tracepoint_aexpr.
2133
2134 2018-08-06  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
2135
2136         * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
2137         Replace array buf with gdb::char_vector buf, of size
2138         get_remote_packet_size ().  Replace references to buf and
2139         BUF_SIZE to buf.data () and buf.size ().  Replace strcpy, strcat
2140         and xsnprintf with snprintf.  Raise errors if the buffer is too
2141         small.
2142
2143 2018-08-06  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
2144
2145         * remote.c (remote_target::download_tracepoint): Fix the has_more
2146         predicate in the QTDP action list iteration.
2147
2148 2018-08-06  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
2149
2150         * remote.c (remote_target::download_tracepoint): Fix indentation
2151         in for block.
2152
2153 2018-08-06  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
2154
2155         * proc-api.c (_initialize_proc_api): Remove c, unused.
2156         * procfs.c (procfs_init_inferior): Remove signals, unused.
2157         (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
2158         unused.
2159
2160 2018-08-06  Sergey Korolev  <s.korolev@ndmsystems.com>
2161             Andrew Burgess  <andrew.burgess@embecosm.com>
2162
2163         * linux-nat.c (linux_nat_target::follow_fork): Avoid using
2164         'W_STOPCODE (0)' as this could be ambiguous.
2165
2166 2018-08-03  Sergio Durigan Junior  <sergiodj@redhat.com>
2167
2168         * ser-tcp.c (net_open): Fix thinko when deciding whether to
2169         disable TCP's Nagle algorithm (use "ai_protocol" instead of
2170         "ai_socktype").
2171
2172 2018-08-02  Tom Tromey  <tom@tromey.com>
2173
2174         PR symtab/16842.
2175         * dwarf2read.c (read_func_scope): Set symtab on template parameter
2176         symbols.
2177         (process_structure_scope): Likewise.
2178
2179 2018-08-02  Xavier Roirand  <roirand@adacore.com>
2180
2181         PR gdb/22629:
2182         * darwin-nat.c (darwin_kill_inferior): Fix handling of
2183         kill inferior.
2184
2185 2018-08-02  Tom Tromey  <tom@tromey.com>
2186
2187         * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
2188         (darwin_suspend_inferior, darwin_resume_inferior)
2189         (darwin_decode_notify_message, darwin_resume_inferior_threads)
2190         (darwin_check_new_threads): Check result of get_darwin_inferior.
2191
2192 2018-07-31  Joel Brobecker  <brobecker@adacore.com>
2193
2194         GDB 8.1.1 released.
2195
2196 2018-07-31  Jan Vrany  <jan.vrany@fit.cvut.cz>
2197
2198         * varobj.c (varobj_get_path_expr_parent): Report an error if
2199         parent is a dynamic varobj.
2200
2201 2018-07-31  Simon Marchi  <simon.marchi@ericsson.com>
2202
2203         * gnulib/aclocal.m4: Re-generate.
2204         * gnulib/config.in: Re-generate.
2205         * gnulib/configure: Re-generate.
2206         * gnulib/import/Makefile.in: Re-generate.
2207         * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2208         * gnulib/import/m4/onceonly.m4: Re-generate.
2209
2210 2018-07-31  Simon Marchi  <simon.marchi@ericsson.com>
2211
2212         * target-descriptions.c (struct xml_test_tdesc): New.
2213         (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
2214         (record_xml_tdesc): Update.
2215         (maintenance_check_xml_descriptions): Update.
2216         * target-descriptions.h (record_xml_tdesc): Update comment.
2217
2218 2018-07-30  Andrew Burgess  <andrew.burgess@embecosm.com>
2219
2220         * eval.c (evaluate_subexp_for_sizeof): Check for array type before
2221         checking array bounds are defined.
2222
2223 2018-07-30  Tom Tromey  <tom@tromey.com>
2224
2225         * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
2226         irreflexivity violation.
2227
2228 2018-07-30  Tom Tromey  <tom@tromey.com>
2229
2230         * cli/cli-decode.c (lookup_cmd): Remove lint code.
2231         * value.c (unpack_long): Remove lint code.
2232         * valops.c (value_ind): Remove lint code.
2233         * valarith.c (value_x_binop, value_x_unop, value_equal)
2234         (value_pos): Remove lint code.
2235
2236 2018-07-28  Tom de Vries  <tdevries@suse.de>
2237
2238         * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
2239         with undefined upper bound as <optimized out>.
2240
2241 2018-07-27  Sergio Durigan Junior  <sergiodj@redhat.com>
2242
2243         * gcore.in: Rename variable "name" to "prefix".  Expand
2244         "usage" text.
2245
2246 2018-07-14  Jon Turney  <jon.turney@dronecode.org.uk>
2247
2248         * windows-nat.c (windows_nat_target::create_inferior): Update to
2249         call close() in global namespace.
2250
2251 2018-07-26  Tom Tromey  <tom@tromey.com>
2252
2253         * dwarf-index-write.c (add_address_entry): Don't add objfile
2254         offsets.
2255         * dbxread.c (find_stab_function): Rename from
2256         find_stab_function_addr.  Return a bound_minimal_symbol.
2257         (read_dbx_symtab): Use raw_text_low, raw_text_high.
2258         Don't add objfile offsets.
2259         (end_psymtab): Use raw_text_low, raw_text_high,
2260         MSYMBOL_VALUE_RAW_ADDRESS.
2261         (read_ofile_symtab): Update.
2262         (process_one_symbol): Update.
2263         * dwarf2read.c (create_addrmap_from_index): Don't add objfile
2264         offsets.
2265         (dw2_relocate): Remove.
2266         (dw2_find_pc_sect_symtab): Bias PC by the text offset before
2267         searching addrmap.
2268         (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
2269         Update.
2270         (process_psymtab_comp_unit_reader, add_partial_symbol)
2271         (add_partial_subprogram, dwarf2_ranges_read): Update.
2272         (load_partial_dies): Update.
2273         (add_address_entry): Don't add objfile offsets.
2274         (dwarf2_build_include_psymtabs): Update.
2275         (create_addrmap_from_aranges): Don't add objfile offsets.
2276         (dw2_find_pc_sect_compunit_symtab): Update.
2277         * mdebugread.c (parse_symbol): Don't add objfile offsets.
2278         (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
2279         Update.
2280         (parse_partial_symbols): Don't add objfile offsets.  Use
2281         raw_text_low, raw_text_high.  Update.
2282         (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
2283         * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
2284         or call 'relocate' quick function.  Clear psymbol_map.
2285         * psympriv.h (struct partial_symbol) <address>: Add section
2286         offset.
2287         <set_unrelocated_address>: Rename from set_address.
2288         <raw_text_low, raw_text_high>: New methods.
2289         <text_low, text_high>: Add objfile parameter.
2290         (add_psymbol_to_bcache): Add 'section' parameter.  Call
2291         set_unrelocated_address.
2292         * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2293         (find_pc_psymbol): Update.
2294         (fixup_psymbol_section, relocate_psymtabs): Remove.
2295         (dump_psymtab, psym_functions): Update.
2296         (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
2297         parameter.
2298         (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
2299         (start_psymtab_common): Update.
2300         * symfile-debug.c (debug_qf_relocate): Remove.
2301         (debug_sym_quick_functions): Update.
2302         * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
2303         * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
2304         Update.
2305
2306 2018-07-26  Tom Tromey  <tromey@redhat.com>
2307
2308         * dbxread.c (end_psymtab): Use text_high_valid and
2309         text_low_valid.
2310         * mdebugread.c (parse_partial_symbols): Use text_low_valid.
2311         (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
2312         * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2313         Update comment.
2314         <text_low_valid, text_high_valid>: New fields.
2315         <set_text_low, set_text_high>: Update.
2316         * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
2317
2318 2018-07-26  Tom Tromey  <tom@tromey.com>
2319
2320         * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
2321         Update.
2322         * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
2323         textlow and texthigh fields.
2324         (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
2325         Update.
2326         * mdebugread.c (parse_lines, parse_partial_symbols)
2327         (psymtab_to_symtab_1): Update.
2328         * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2329         Rename fields.  Update comment.  Now private.
2330         <text_low, text_high, set_text_low, set_text_high>: New methods.
2331         * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2332         (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
2333         (start_psymtab_common, maintenance_info_psymtabs)
2334         (maintenance_check_psymtabs): Update.
2335         * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
2336         texthigh fields.
2337         (scan_xcoff_symtab): Update.
2338
2339 2018-07-26  Tom Tromey  <tromey@redhat.com>
2340
2341         * psympriv.h (struct partial_symbol) <unrelocated_address,
2342         address, set_address>: New methods.
2343         * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
2344         (fixup_psymbol_section, relocate_psymtabs): Update.
2345         (print_partial_symbols): Add 'objfile' parameter.  Update.
2346         (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
2347         Update.
2348
2349 2018-07-26  Tom Tromey  <tom@tromey.com>
2350
2351         * dwarf-index-write.c (write_psymbols, debug_names::insert)
2352         (debug_names::write_psymbols): Update.
2353         * psympriv.h (struct partial_symbol): Derive from
2354         general_symbol_info.
2355         <obj_section>: New method.
2356         (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
2357         * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2358         (find_pc_sect_psymbol, fixup_psymbol_section)
2359         (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
2360         (print_partial_symbols, recursively_search_psymtabs)
2361         (compare_psymbols, psymbol_hash, psymbol_compare)
2362         (add_psymbol_to_bcache, maintenance_check_psymtabs)
2363         (psymbol_name_matches, psym_fill_psymbol_map): Update.
2364
2365 2018-07-26  Tom Tromey  <tromey@redhat.com>
2366
2367         * dbxread.c (end_psymtab): Remove dead code.
2368
2369 2018-07-26  Andrew Burgess  <andrew.burgess@embecosm.com>
2370
2371         * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
2372         DWARF unwinders are disabled.
2373         * dwarf2-frame.c: Add dwarf2read.h include.
2374         (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
2375         disabled.
2376         (dwarf2_frame_unwinders_enabled_p): Define.
2377         (show_dwarf_unwinders_enabled_p): New function.
2378         (_initialize_dwarf2_frame): Register switch to control DWARF
2379         unwinder use.
2380         * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
2381         * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
2382         (show_dwarf_cmdlist): Remove static keyword.
2383         * dwarf2read.h (set_dwarf_cmdlist): Declare.
2384         (show_dwarf_cmdlist): Declare.
2385         * NEWS: Document new feature.
2386
2387 2018-07-26  Tom de Vries  <tdevries@suse.de>
2388
2389         PR breakpoints/23366
2390         * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
2391
2392 2018-07-26  Tom de Vries  <tdevries@suse.de>
2393
2394         * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
2395         DW_AT_count can't be translated to a dynamic prop.
2396
2397 2018-07-25  Tom de Vries  <tdevries@suse.de>
2398
2399         * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
2400         try/catch.
2401
2402 2018-07-25  Jan Vrany  <jan.vrany@fit.cvut.cz>
2403
2404         * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
2405
2406 2018-07-25  Joel Brobecker  <brobecker@adacore.com>
2407
2408         * MAINTAINERS (Global Maintainers): Add Tom Tromey.
2409
2410 2018-07-24  Keith Seitz  <keiths@redhat.comt
2411
2412         PR symtab/23010
2413         * dwarf2read.c (dw2_add_symbol_to_list): New function.
2414         (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
2415         instead of add_symbol_to_list.
2416         (read_file_scope): Call prepare_one_comp_unit before reading
2417         any other DIEs.
2418
2419 2018-07-24  Simon Marchi  <simon.marchi@ericsson.com>
2420
2421         * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
2422
2423 2018-07-24  Tom Tromey  <tom@tromey.com>
2424
2425         * utils.c (malloc, realloc, free): Don't declare.
2426         * configure, config.in: Rebuild.
2427         * configure.ac: Don't check for declarations of free, malloc, or
2428         realloc.
2429
2430 2018-07-22  Simon Marchi  <simon.marchi@polymtl.ca>
2431
2432         * aarch64-linux-nat.c
2433         (aarch64_linux_nat_target::stopped_data_address): Remove unused
2434         variable.
2435         * arm-linux-nat.c (fetch_regs): Likewise.
2436         (store_regs): Likewise.
2437         (fetch_vfp_regs): Likewise.
2438         (store_vfp_regs): Likewise.
2439         (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
2440         (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
2441         (arm_linux_nat_target::insert_watchpoint): Likewise.
2442         (arm_linux_nat_target::remove_watchpoint): Likewise.
2443         * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
2444         Likewise.
2445         * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
2446         Likewise.
2447         * ppc-linux-nat.c (fetch_register): Likewise.
2448         (fetch_all_gp_regs): Likewise.
2449         (fetch_ppc_registers): Likewise.
2450         (store_all_gp_regs): Likewise.
2451         (store_ppc_registers): Likewise.
2452         (hwdebug_insert_point): Likewise.
2453         (can_use_watchpoint_cond_accel): Likewise.
2454         * remote-sim.c (gdb_os_write_stdout): Likewise.
2455
2456 2018-07-22  Simon Marchi  <simon.marchi@polymtl.ca>
2457             Tom Tromey  <tom@tromey.com>
2458
2459         * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
2460         test for it.
2461         * configure: Rebuild.
2462
2463 2018-07-22  Tom Tromey  <tom@tromey.com>
2464
2465         * regformats/regdat.sh: Define xmltarget_${name} inside
2466         #ifndef IN_PROCESS_AGENT.
2467
2468 2018-07-22  Tom Tromey  <tom@tromey.com>
2469
2470         * value.c (value_fetch_lazy_bitfield): Remove unused variable.
2471
2472 2018-07-22  Tom Tromey  <tom@tromey.com>
2473
2474         * symfile.c (reread_symbols): Notify iter, not objfile.
2475
2476 2018-07-22  Tom Tromey  <tom@tromey.com>
2477
2478         * ravenscar-thread.c (ravenscar_thread_target::store_registers):
2479         Use arch_ops.
2480         (ravenscar_thread_target::prepare_to_store): Likewise.
2481
2482 2018-07-22  Tom Tromey  <tom@tromey.com>
2483
2484         * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
2485         unused variable.  Call value_fetch_lazy when needed.
2486         * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
2487         Remove unused variable.  Call value_fetch_lazy when needed.
2488
2489 2018-07-22  Tom Tromey  <tom@tromey.com>
2490
2491         * m32c-tdep.c (mark_dma): Return void.
2492         (make_regs): Remove unused declarations.
2493
2494 2018-07-22  Tom Tromey  <tom@tromey.com>
2495
2496         * guile/scm-cmd.c (gdbscm_dont_repeat): Call
2497         cmdscm_get_valid_command_smob_arg_unsafe for effect.
2498         * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
2499         bkscm_get_valid_block_smob_arg_unsafe for effect.
2500
2501 2018-07-22  Tom Tromey  <tom@tromey.com>
2502
2503         * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
2504         value_type.
2505
2506 2018-07-22  Tom Tromey  <tom@tromey.com>
2507
2508         * windows-nat.c (saved_context): Conditionally define.
2509         * remote.c (remote_target::remote_btrace_maybe_reopen):
2510         Conditionally declare "warned".
2511         * inflow.c (sigquit_ours): Conditionally define.
2512         (new_tty): Move "tty" declaration inside #if.
2513         * guile/guile.c (guile_datadir): Conditionally define.
2514         * charset.c (set_be_le_names): Move some declarations inside #if.
2515         * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
2516         #if.
2517         (parse_xml_btrace_conf): Likewise.
2518
2519 2018-07-22  Tom Tromey  <tom@tromey.com>
2520
2521         * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
2522
2523 2018-07-22  Tom Tromey  <tom@tromey.com>
2524
2525         * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
2526         * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
2527         (vlscm_convert_typed_value_from_scheme): Remove unused variable.
2528         * buildsym-legacy.c (get_macro_table): Remove unused variable.
2529         * stack.c (frame_apply_level_command): Remove unused variable.
2530         * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
2531         * sparc64-tdep.c (adi_examine_command): Remove unused variable.
2532         * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
2533         unused variable.
2534         * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
2535         * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
2536         * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
2537         variable.
2538         * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
2539         * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
2540         variable.
2541         * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
2542         Remove unused variable.
2543         * cli/cli-script.c (recurse_read_control_structure): Remove unused
2544         variable.
2545         * common/tdesc.c (print_xml_feature::visit): Remove unused
2546         variable.
2547         * compile/compile-object-load.c (store_regs): Remove unused
2548         variables.
2549         * complaints.c (clear_complaints): Remove unused variable.
2550         * corelow.c (core_target_open): Remove unused variable.
2551         * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
2552         variable.
2553         * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
2554         variable.
2555         * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
2556         variable.
2557         * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
2558         variable.
2559         * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
2560         variable.
2561         * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
2562         variable.
2563         * ia64-tdep.c (examine_prologue): Remove unused variable.
2564         * infcall.c (run_inferior_call): Remove unused variable.
2565         * inferior.c (exit_inferior): Remove unused variable.
2566         * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
2567         * linespec.c (decode_line_2): Remove unused variable.
2568         * linux-nat.c (super_close): Remove.
2569         * linux-tdep.c (linux_info_proc): Remove unused variable.
2570         * mi/mi-main.c (mi_execute_command): Remove unused variable.
2571         * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
2572         Remove unused variable.
2573         * parse.c (find_minsym_type_and_address): Remove unused variable.
2574         * printcmd.c (info_symbol_command, printf_floating): Remove unused
2575         variable.
2576         * python/py-breakpoint.c (bppy_set_commands): Remove unused
2577         variable.
2578         * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
2579         variables.
2580         * record-btrace.c (record_btrace_target::store_registers): Remove
2581         unused variable.
2582         (cmd_show_record_btrace_cpu): Remove unused variable.
2583         * riscv-tdep.c (riscv_register_reggroup_p)
2584         (riscv_push_dummy_call, riscv_return_value): Remove unused
2585         variable.
2586         * rust-exp.y (literal): Remove unused variable.
2587         * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
2588         unused variable.
2589         <STRUCTOP_ANONYMOUS>: Likewise.
2590         * s390-linux-tdep.c (s390_linux_init_abi_31)
2591         (s390_linux_init_abi_64): Remove unused variable.
2592         * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
2593         (file_select_thread, net_windows_open, _initialize_ser_windows):
2594         Remove unused variables.
2595         * symtab.c (find_pc_sect_line): Remove unused variable.
2596         * target-memory.c (compute_garbled_blocks): Remove unused
2597         variable.
2598         (target_write_memory_blocks): Remove unused variable.
2599         * target.c (target_stack::unpush): Remove unused variables.
2600         * tracepoint.c (start_tracing, all_tracepoint_actions)
2601         (merge_uploaded_trace_state_variables)
2602         (print_one_static_tracepoint_marker): Remove unused variable.
2603         * unittests/basic_string_view/element_access/char/1.cc (test01):
2604         Remove unused variable.
2605         * windows-nat.c (windows_continue, windows_add_all_dlls)
2606         (do_initial_windows_stuff, windows_nat_target::create_inferior):
2607         Remove unused variables.
2608
2609 2018-07-21  Simon Marchi  <simon.marchi@polymtl.ca>
2610
2611         * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
2612         attr_profile in HAVE_ELF.
2613         * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
2614         HAVE_ELF.
2615
2616 2018-07-20  Simon Marchi  <simon.marchi@polymtl.ca>
2617
2618         * frame.c (frame_register_unwind): Change parameter name.
2619         (frame_unwind_register): Likewise.
2620         (frame_unwind_register_value): Likewise.
2621         (frame_unwind_register_signed): Likewise.
2622         (frame_unwind_register_unsigned): Likewise.
2623         * frame.h (frame_register_unwind): Likewise.
2624         (frame_unwind_register): Likewise.
2625         (frame_unwind_register_value): Likewise.
2626         (frame_unwind_register_signed): Likewise.
2627         (frame_unwind_register_unsigned): Likewise.
2628         (frame_unwind_arch): Likewise.
2629
2630 2018-07-20  Maciej W. Rozycki  <macro@mips.com>
2631
2632         * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
2633         ISA maintenance.
2634
2635 2018-07-20  Maciej W. Rozycki  <macro@mips.com>
2636
2637         * mips-linux-nat.c (mips_linux_nat_target::read_description):
2638         Call `get_ptrace_pid' rather than extracting the ptrace PID by
2639         hand.
2640
2641 2018-07-20  Keith Seitz  <keiths@redhat.com>
2642
2643         * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
2644         m_main_subfile, m_comp_dir, m_producer, m_debugformat,
2645         m_compunit_symtab, m_language>: Add "m_" prefix.
2646         Update all uses.
2647         * buildsym.c: Update all uses.
2648
2649 2018-07-20  Tom Tromey  <tom@tromey.com>
2650
2651         * buildsym-legacy.h (record_line): Don't use record_line_ftype.
2652         * buildsym.h (record_line_ftype): Remove typedef.
2653
2654 2018-07-20  Tom Tromey  <tom@tromey.com>
2655
2656         * buildsym-legacy.h (augment_type_symtab): Don't declare.
2657         (end_expandable_symtab): Likewise.
2658         (end_symtab_get_static_block): Likewise.
2659         (end_symtab_from_static_block): Likewise.
2660         * buildsym-legacy.c (augment_type_symtab): Remove.
2661         (end_expandable_symtab): Remove.
2662         (end_symtab_get_static_block): Remove.
2663         (end_symtab_from_static_block): Remove.
2664
2665 2018-07-20  Tom Tromey  <tom@tromey.com>
2666
2667         * dwarf2read.c: Include buildsym.h.
2668         (struct dwarf2_cu) <builder>: New method.
2669         (fixup_go_packaging): Update.
2670         (process_full_comp_unit, process_full_type_unit): Update.  Don't
2671         use scoped_free_pendings.
2672         (using_directives): Add "cu" parameter, remove "language".
2673         (read_import_statement, setup_type_unit_groups, )
2674         (read_func_scope, read_lexical_block_scope)
2675         (dwarf2_record_block_ranges, read_namespace): Update.
2676         (lnp_state_machine::lnp_state_machine): Add cu parameter.
2677         (lnp_state_machine::handle_end_sequence): Update.
2678         (class lnp_state_machine) <m_cu>: New member.
2679         <m_record_line_callback>: Remove.
2680         <m_currently_recording_lines>: New member.
2681         (lnp_state_machine::handle_set_file): Update.
2682         (noop_record_line): Remove.
2683         (dwarf_record_line_p): Add cu parameter.
2684         (dwarf_record_line_1, dwarf_finish_line): Likewise.
2685         (lnp_state_machine::record_line)
2686         (lnp_state_machine::lnp_state_machine)
2687         (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
2688         (dwarf_decode_lines): Update.
2689         (dwarf2_start_subfile): Add cu parameter.
2690         (dwarf2_start_symtab, new_symbol): Update.
2691         (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
2692         Remove dwarf2_per_objfile parameter.
2693         (dwarf_decode_macros): Update.
2694
2695 2018-07-20  Tom Tromey  <tom@tromey.com>
2696
2697         * stabsread.c (define_symbol): Update.
2698         * buildsym-legacy.h (get_buildsym_compunit): Declare.
2699         * dwarf2read.c (new_symbol): Update.
2700         * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
2701         * cp-namespace.c: Include buildsym.h.
2702         (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
2703         * buildsym-legacy.c (get_buildsym_compunit): New function.
2704
2705 2018-07-20  Tom Tromey  <tom@tromey.com>
2706
2707         * xcoffread.c: Include buildsym-legacy.h.
2708         * windows-nat.c: Include buildsym-legacy.h.
2709         * stabsread.c: Include buildsym-legacy.h.
2710         * mdebugread.c: Include buildsym-legacy.h.
2711         * buildsym-legacy.h: New file.
2712         * buildsym-legacy.c: New file, from buildsym.c.
2713         * go32-nat.c: Include buildsym-legacy.h.
2714         * dwarf2read.c: Include buildsym-legacy.h.
2715         * dbxread.c: Include buildsym-legacy.h.
2716         * cp-namespace.c: Include buildsym-legacy.h.
2717         * coffread.c: Include buildsym-legacy.h.
2718         * buildsym.h: Move some contents to buildsym-legacy.h.
2719         * buildsym.c: Include buildsym-legacy.h.  Move many functions to
2720         buildsym-legacy.c.
2721         * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
2722
2723 2018-07-20  Tom Tromey  <tom@tromey.com>
2724
2725         * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
2726         * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
2727         (buildsym_compunit::buildsym_compunit)
2728         (buildsym_compunit::~buildsym_compunit)
2729         (buildsym_compunit::get_macro_table): Define.
2730
2731 2018-07-20  Tom Tromey  <tom@tromey.com>
2732
2733         * buildsym.c (reset_symtab_globals): Remove.
2734         (buildsym_compunit::end_symtab_from_static_block): Update.
2735         (buildsym_compunit::augment_type_symtab): Update.
2736         (end_symtab_from_static_block): Call free_buildsym_compunit.
2737         (augment_type_symtab, end_symtab, end_expandable_symtab):
2738         Likewise.
2739
2740 2018-07-20  Tom Tromey  <tom@tromey.com>
2741
2742         * arch-utils.c: Do not include buildsym.h.
2743         * mipsread.c: Do not include buildsym.h.
2744         * machoread.c: Do not include buildsym.h.
2745         * elfread.c: Do not include buildsym.h.
2746
2747 2018-07-20  Tom Tromey  <tom@tromey.com>
2748
2749         * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
2750         initialization.
2751         (buildsym_compunit): Add new constructor.
2752         (struct buildsym_compunit) <get_last_source_file, finish_block,
2753         record_block_range, start_subfile, patch_subfile_names,
2754         push_subfile, pop_subfile, record_line, get_compunit_symtab,
2755         set_last_source_start_addr, get_last_source_start_addr,
2756         get_local_using_directives, set_local_using_directives,
2757         get_global_using_directives, outermost_context_p,
2758         get_current_context_stack, get_context_stack_depth,
2759         get_current_subfile, get_local_symbols, get_file_symbols,
2760         get_global_symbols, record_debugformat, record_producer,
2761         push_context, pop_context, end_symtab_get_static_block,
2762         end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
2763         New public methods.
2764         <record_pending_block, finish_block_internal, make_blockvector,
2765         watch_main_source_file_lossage, end_symtab_with_blockvector>: New
2766         private methods.
2767         Update all users.
2768
2769 2018-05-22  Tom Tromey  <tom@tromey.com>
2770
2771         * buildsym.c (record_pending_block): Move earlier.  Remove objfile
2772         parameter.
2773         (finish_block_internal): Update.
2774
2775 2018-07-20  Tom Tromey  <tom@tromey.com>
2776
2777         * buildsym.c (record_pending_block): Move earlier.  Remove objfile
2778         parameter.
2779         (finish_block_internal): Update.
2780
2781 2018-07-20  Tom Tromey  <tom@tromey.com>
2782
2783         * buildsym.h (EXTERN): Don't define or undef.
2784         * buildsym.c (EXTERN): Don't define.
2785
2786 2018-07-20  Tom Tromey  <tom@tromey.com>
2787
2788         * buildsym.c: Remove TODO comment.
2789
2790 2018-07-20  Tom Tromey  <tom@tromey.com>
2791
2792         * coffread.c (coff_symtab_read): Update.
2793         * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
2794         (xcoff_new_init): Update.
2795         * mipsread.c (mipscoff_new_init): Update.
2796         * mdebugread.c (mdebug_build_psymtabs): Update.
2797         * elfread.c (elf_new_init): Update.
2798         * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
2799         Update.
2800         * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
2801         (coffstab_build_psymtabs, elfstab_build_psymtabs)
2802         (stabsect_build_psymtabs): Update.
2803         * buildsym.h (buildsym_init): Don't declare.
2804         * buildsym.c: Update comment.
2805         (prepare_for_building): Remove.
2806         (start_symtab, restart_symtab): Update.
2807         (reset_symtab_globals): Update comment.
2808         (buildsym_init): Remove.
2809
2810 2018-07-20  Tom Tromey  <tom@tromey.com>
2811
2812         * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
2813         * stabsread.c (patch_block_stabs, define_symbol, read_type)
2814         (read_enum_type, common_block_start, common_block_end)
2815         (cleanup_undefined_types_1, finish_global_stabs): Update.
2816         * mdebugread.c (psymtab_to_symtab_1): Update.
2817         * dwarf2read.c (fixup_go_packaging, read_func_scope)
2818         (read_lexical_block_scope, new_symbol): Update.
2819         * dbxread.c (process_one_symbol): Update.
2820         * coffread.c (coff_symtab_read, process_coff_symbol)
2821         (coff_read_enum_type): Update.
2822         * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
2823         declare.
2824         (get_local_symbols, get_file_symbols, get_global_symbols): New
2825         functions.
2826         * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
2827         m_global_symbols.
2828         <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
2829         (~scoped_free_pendings): Update.
2830         (finish_block, prepare_for_building, reset_symtab_globals)
2831         (end_symtab_get_static_block, end_symtab_with_blockvector)
2832         (augment_type_symtab, push_context): Update.
2833         (get_local_symbols, get_file_symbols, get_global_symbols): New
2834         functions.
2835         (buildsym_init): Update.
2836
2837 2018-07-20  Tom Tromey  <tom@tromey.com>
2838
2839         * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
2840         (process_full_type_unit): Likewise.
2841         (dwarf2_start_symtab): Set list_in_scope.
2842
2843 2018-07-20  Tom Tromey  <tom@tromey.com>
2844
2845         * dwarf2read.c (process_psymtab_comp_unit_reader)
2846         (build_type_psymtabs_reader): Do not set list_in_scope.
2847
2848 2018-07-20  Tom Tromey  <tom@tromey.com>
2849
2850         * buildsym.c (free_pendings): Remove.
2851         (add_symbol_to_list, scoped_free_pendings)
2852         (finish_block_internal, buildsym_init): Update.
2853
2854 2018-07-20  Tom Tromey  <tom@tromey.com>
2855
2856         * xcoffread.c (read_xcoff_symtab): Update.
2857         * dwarf2read.c (read_func_scope, read_lexical_block_scope):
2858         Update.
2859         * dbxread.c (process_one_symbol): Update.
2860         * coffread.c (coff_symtab_read): Update.
2861         * buildsym.h (finish_block): Update.
2862         * buildsym.c (finish_block): Remove "listhead" argument.
2863         (end_symtab_get_static_block): Update.
2864
2865 2018-07-20  Tom Tromey  <tom@tromey.com>
2866
2867         * buildsym.h (class scoped_free_pendings): Remove constructor.
2868         * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
2869         method.
2870         <m_pending_block_obstack, m_pending_blocks>: New members.
2871         (pending_block_obstack, pending_blocks): Remove.
2872         (scoped_free_pendings::scoped_free_pendings): Default.
2873         (~scoped_free_pendings): Update.
2874         (free_pending_blocks): Remove.
2875         (finish_block_internal, record_pending_block, make_blockvector)
2876         (end_symtab_get_static_block, augment_type_symtab, push_context)
2877         (buildsym_init): Update.
2878
2879 2018-07-20  Tom Tromey  <tom@tromey.com>
2880
2881         * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
2882         m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
2883         members.
2884         (pending_addrmap, pending_addrmap_obstack)
2885         (pending_addrmap_interesting): Remove.
2886         (scoped_free_pendings, record_block_range, make_blockvector)
2887         (prepare_for_building, reset_symtab_globals, buildsym_init):
2888         Update.
2889
2890 2018-07-20  Tom Tromey  <tom@tromey.com>
2891
2892         * xcoffread.c (process_linenos): Update.
2893         * stabsread.c (define_symbol, read_type, read_enum_type): Update.
2894         * mdebugread.c (psymtab_to_symtab_1): Update.
2895         * dwarf2read.c (setup_type_unit_groups)
2896         (lnp_state_machine::handle_set_file, dwarf_record_line_p)
2897         (lnp_state_machine::record_line, dwarf_decode_lines): Update.
2898         * dbxread.c (process_one_symbol): Update.
2899         * coffread.c (coff_symtab_read, enter_linenos)
2900         (process_coff_symbol): Update.
2901         * buildsym.h (current_subfile): Don't declare.
2902         (get_current_subfile): Declare.
2903         * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
2904         member.
2905         (start_subfile, free_buildsym_compunit, push_subfile)
2906         (prepare_for_building, start_symtab): Update.
2907         (get_current_subfile): New function.
2908
2909 2018-07-20  Tom Tromey  <tom@tromey.com>
2910
2911         * coffread.c (coff_symtab_read): Update.
2912         * xcoffread.c (read_xcoff_symtab): Update.
2913         * dwarf2read.c (new_symbol): Update.
2914         (read_func_scope, read_lexical_block_scope): Update.
2915         * dbxread.c (process_one_symbol): Update.
2916         * buildsym.h (context_stack, context_stack_depth): Don't declare.
2917         (outermost_context_p): Remove macro.
2918         (outermost_context_p, get_current_context_stack)
2919         (get_context_stack_depth): Declare.
2920         (pop_context): Return struct context_stack.
2921         * buildsym.c (struct buildsym_compunit) <m_context_stack: New
2922         member.
2923         (context_stack_size): Remove.
2924         (INITIAL_CONTEXT_STACK_SIZE): Remove.
2925         (prepare_for_building, end_symtab_get_static_block)
2926         (augment_type_symtab, push_context): Update.
2927         (pop_context): Return struct context_stack.
2928         (outermost_context_p, get_current_context_stack)
2929         (get_context_stack_depth): New functions.
2930         (buildsym_init): Update.
2931
2932 2018-07-20  Tom Tromey  <tom@tromey.com>
2933
2934         * rust-exp.y: Now a pure parser.  Update all rules.
2935         (%union): Move earlier.
2936         (current_parser, work_obstack): Remove globals.
2937         (rust_parser, ~rust_parser): Update.
2938         (class rust_parser) <copy_name, concat3, crate_name, super_name,
2939         lex_character, lex_number, lex_string, lex_identifier,
2940         rust_lookup_type, convert_params_to_types, convert_ast_to_type,
2941         convert_name, convert_params_to_expression,
2942         convert_ast_to_expression, ast_basic_type, ast_operation,
2943         ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
2944         ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
2945         ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
2946         ast_array_type, ast_slice_type, ast_reference_type,
2947         ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
2948         (rust_parse): Update.
2949         (rustyyerror, rustyylex): Add parser parameter.
2950         (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
2951         (rust_lex_stringish_test, rust_lex_test_sequence)
2952         (rust_lex_test_trailing_dot, rust_lex_test_completion)
2953         (rust_lex_test_push_back, rust_lex_tests): Update.
2954
2955 2018-07-19  Pedro Alves  <palves@redhat.com>
2956
2957         * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
2958         gdb::unique_xmalloc_ptr.
2959         * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
2960         Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
2961         * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
2962         copy-initialization.
2963         * guile/scm-pretty-print.c (ppscm_print_children): Use
2964         gdb::unique_xmalloc_ptr instead of cleanups.
2965         (gdbscm_apply_val_pretty_printer): Remove cleanups.
2966         * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
2967         gdb::unique_xmalloc_ptr.
2968         * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
2969         Adjust to use gdb::unique_xmalloc_ptr.
2970         * guile/scm-utils.c (extract_arg): Adjust.
2971         * guile/scm-value.c (gdbscm_value_field): Adjust to use
2972         gdb::unique_xmalloc_ptr instead of a cleanup.
2973
2974 2018-07-19  Tom Tromey  <tom@tromey.com>
2975
2976         * utils.c (do_value_free_to_mark)
2977         (make_cleanup_value_free_to_mark): Remove.
2978         * utils.h (make_cleanup_value_free_to_mark): Remove.
2979
2980 2018-07-19  Pedro Alves  <palves@redhat.com>
2981
2982         * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
2983         forwarding reference.
2984
2985 2018-07-18  Pedro Alves  <palves@redhat.com>
2986
2987         * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
2988         gdbscm_wrap.  Use gdb::unique_xmalloc_ptr<char> instead of a
2989         cleanup.
2990
2991 2018-07-18  Pedro Alves  <palves@redhat.com>
2992
2993         * guile/guile-internal.h: Add comment about mixing GDB and Scheme
2994         exceptions.
2995         (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
2996         (gdbscm_wrap): New.
2997         * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
2998         directly instead of a cleanup.
2999         * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
3000         (vlscm_unop): ... this.  Reimplement using gdbscm_wrap.
3001         (vlscm_binop_gdbthrow): New, factored out from ...
3002         (vlscm_binop): ... this.  Reimplement using gdbscm_wrap.
3003         (vlscm_rich_compare): Use gdbscm_wrap.
3004         * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
3005         instead of a cleanup.
3006         (gdbscm_lookup_global_symbol): Use xfree directly instead of a
3007         cleanup.
3008         * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3009         Use xfree directly instead of a cleanup.
3010         * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
3011         Adjust to use gdbscm_wrap and scoped_value_mark.
3012         (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
3013         (gdbscm_value_address, gdbscm_value_dereference)
3014         (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
3015         scoped_value_mark.
3016         (gdbscm_value_dynamic_type): Use scoped_value_mark.
3017         (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
3018         scoped_value_mark.
3019         (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
3020         gdbscm_wrap and scoped_value_mark.
3021         (gdbscm_value_to_string): Use xfree directly instead of a
3022         cleanup.  Move 'buffer' unique_ptr to TRY scope.
3023         (gdbscm_value_to_lazy_string): Use xfree directly instead of a
3024         cleanup.  Move 'buffer' unique_ptr to TRY scope.  Use
3025         scoped_value_mark.
3026         (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
3027         (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
3028         scoped_value_mark.
3029         (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
3030         gdbscm_wrap.
3031
3032 2018-07-18  Tom de Vries  <tdevries@suse.de>
3033
3034         * findvar.c (default_read_var_value): Also resolve dynamic type for
3035         LOC_OPTIMIZED_OUT vars.
3036
3037 2018-07-18  Maciej W. Rozycki  <macro@mips.com>
3038
3039         * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
3040         decoding.
3041
3042 2018-07-17  Tom Tromey  <tom@tromey.com>
3043
3044         * guile/scm-param.c (pascm_set_func, pascm_show_func)
3045         (compute_enum_list, pascm_set_param_value_x)
3046         (gdbscm_parameter_value): Update.
3047         * guile/guile-internal.h (gdbscm_scm_to_string): Update.
3048         (gdbscm_scm_to_host_string): Update.
3049         * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
3050         Update.
3051         * guile/scm-cmd.c (cmdscm_add_completion): Update.
3052         * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
3053         * guile/scm-string.c (gdbscm_scm_to_string): Return
3054         unique_xmalloc_ptr.
3055         (gdbscm_scm_to_host_string): Likewise.
3056
3057 2018-07-17  Tom Tromey  <tom@tromey.com>
3058
3059         * guile/guile.c (gdbscm_eval_from_control_command): Update.
3060         * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
3061         * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
3062         * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
3063         unique_xmalloc_ptr.
3064
3065 2018-07-17  Tom Tromey  <tom@tromey.com>
3066
3067         * guile/scm-param.c (pascm_signal_setshow_error): Update.
3068         * guile/guile-internal.h (gdbscm_exception_message_to_string):
3069         Update.
3070         * guile/scm-cmd.c (cmdscm_function): Update.
3071         * guile/scm-pretty-print.c
3072         (ppscm_print_exception_unless_memory_error): Update.
3073         * guile/scm-exception.c (gdbscm_exception_message_to_string):
3074         Return unique_xmalloc_ptr.
3075
3076 2018-07-17  Tom Tromey  <tom@tromey.com>
3077
3078         * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
3079         Use string_printf.
3080
3081 2018-07-17  Jim Wilson  <jimw@sifive.com>
3082
3083         * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
3084         set_gdbarch_decr_pc_after_break.  Call riscv_read_misa_reg always.
3085         (riscv_gdbarch_init): Delete local has_compressed_isa.  Delete now
3086         unecessary braces after EF_RISCV_RVC test.  Delete call to
3087         set_gdbarch_decr_pc_after_break.
3088
3089         * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
3090         RISCV_LAST_FP_REGNUM + 1.
3091         (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
3092
3093 2018-07-17  Tom Tromey  <tom@tromey.com>
3094
3095         * configure.ac: Remove --disable-gdbcli.
3096         * configure: Rebuild.
3097         * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
3098         (SUBDIR_CLI_CFLAGS): Remove.
3099         (SFILES): Use SUBDIR_CLI_SRCS.
3100         (COMMON_OBS): Use SUBDIR_CLI_OBS.
3101
3102 2018-07-17  Tom Tromey  <tom@tromey.com>
3103
3104         PR gdb/18624:
3105         * coffread.c (coff_symtab_read): Use scoped_free_pendings.
3106
3107 2018-07-16  Jim Wilson  <jimw@sifive.com>
3108
3109         * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
3110
3111 2018-07-16  Simon Marchi  <simon.marchi@ericsson.com>
3112
3113         * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
3114         variable.
3115         (libunwind_frame_sniffer): Likewise.
3116         (libunwind_frame_prev_register): Likewise.
3117         (libunwind_sigtramp_frame_sniffer): Likewise.
3118         * ia64-tdep.c (ia64_access_reg): Likewise.
3119         (ia64_access_rse_reg): Likewise.
3120         (ia64_libunwind_sigtramp_frame_this_id): Likewise.
3121         * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
3122
3123 2018-07-16  Simon Marchi  <simon.marchi@ericsson.com>
3124
3125         * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
3126
3127 2018-07-16  Simon Marchi  <simon.marchi@ericsson.com>
3128
3129         * remote-sim.c (gdbsim_target::close,
3130         gdbsim_target::mourn_inferior): Remove unused variables.
3131
3132 2018-07-16  Simon Marchi  <simon.marchi@polymtl.ca>
3133
3134         * ia64-tdep.c (ktab_buf): New global.
3135         (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
3136         (get_kernel_table): Adjust.
3137
3138 2018-07-16  Tom Tromey  <tom@tromey.com>
3139
3140         * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
3141         * dwarf2read.c (using_directives, new_symbol): Use
3142         outermost_context_p.
3143         * dbxread.c (process_one_symbol): Use outermost_context_p.
3144         * coffread.c (coff_symtab_read): Use outermost_context_p.
3145
3146 2018-07-16  Tom Tromey  <tom@tromey.com>
3147
3148         * dwarf2read.c (using_directives, read_func_scope)
3149         (read_lexical_block_scope): Update.
3150         * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
3151         * buildsym.h (local_using_directives, global_using_directives):
3152         Don't declare.
3153         (get_local_using_directives, set_local_using_directives)
3154         (get_global_using_directives): Declare.
3155         * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
3156         m_global_using_directives>: New members.
3157         (finish_block_internal, prepare_for_building)
3158         (reset_symtab_globals, end_symtab_get_static_block)
3159         (push_context): Update.
3160         (get_local_using_directives, set_local_using_directives)
3161         (get_global_using_directives): New functions.
3162         (buildsym_init): Update.
3163
3164 2018-07-16  Tom Tromey  <tom@tromey.com>
3165
3166         * xcoffread.c (xcoff_initial_scan): Don't call
3167         free_pending_blocks.
3168         * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
3169         * buildsym.h (class scoped_free_pendings): Add constructor.
3170         (free_pending_blocks): Don't declare.
3171         * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
3172         (free_pending_blocks): Now static.
3173
3174 2018-07-16  Tom Tromey  <tom@tromey.com>
3175
3176         * buildsym.h (push_subfile, pop_subfile): Update declarations.
3177         * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
3178         member.
3179         (struct subfile_stack): Remove.
3180         (subfile_stack): Remove.
3181         (push_subfile, pop_subfile, buildsym_init): Update.
3182
3183 2018-07-16  Tom Tromey  <tom@tromey.com>
3184
3185         * buildsym.c (push_subfile): Use gdb_assert.
3186         (pop_subfile): Use gdb_assert.
3187
3188 2018-07-16  Tom Tromey  <tom@tromey.com>
3189
3190         * buildsym.h (merge_symbol_lists): Remove.
3191         * buildsym.c (merge_symbol_lists): Remove.
3192
3193 2018-07-16  Tom Tromey  <tom@tromey.com>
3194
3195         * stabsread.c (scan_file_globals): Update comment.
3196         * stabsread.h (scan_file_globals): Move from buildsym.h.
3197         * buildsym.h (scan_file_globals): Move to stabsread.h.
3198
3199 2018-07-16  Tom Tromey  <tom@tromey.com>
3200
3201         * xcoffread.c (xcoff_new_init): Update.
3202         * mipsread.c (mipscoff_new_init): Update.
3203         * mdebugread.c (mdebug_build_psymtabs): Update.
3204         * elfread.c (elf_new_init): Update.
3205         * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
3206         (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
3207         * buildsym.h (buildsym_new_init): Don't declare.
3208         * buildsym.c (buildsym_new_init): Remove.
3209
3210 2018-07-16  Tom Tromey  <tom@tromey.com>
3211
3212         * stabsread.h (within_function): Move from buildsym.h.
3213         * stabsread.c (start_stabs): Clear within_function.
3214         * coffread.c (coff_start_symtab): Clear within_function.
3215         * buildsym.h (within_function): Move to stabsread.h.
3216         * buildsym.c (prepare_for_building): Update.
3217
3218 2018-07-16  Tom Tromey  <tom@tromey.com>
3219
3220         * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
3221         * dwarf2read.c (dwarf2_start_symtab): Don't set
3222         processing_gcc_compilation.
3223         * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
3224
3225 2018-07-16  Tom Tromey  <tom@tromey.com>
3226
3227         * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
3228         (next_symbol_text_func): Move from buildsym.h.
3229         * stabsread.c (hashname): Move from buildsym.c.
3230         * buildsym.h (HASHSIZE, symnum, next_symbol_text)
3231         (next_symbol_text_func, hashname): Move to stabsread.h.
3232         * buildsym.c: Don't include bcache.h
3233         (hashname): Move to stasbread.c.
3234
3235 2018-07-16  Tom Tromey  <tom@tromey.com>
3236
3237         * buildsym.h (context_stack_size): Don't declare.
3238         * buildsym.c (context_stack_size): New global.
3239
3240 2018-07-16  Tom Tromey  <tom@tromey.com>
3241
3242         * dbxread.c (processing_acc_compilation): New global.
3243         * buildsym.h (processing_acc_compilation): Don't declare.
3244
3245 2018-07-16  Tom Tromey  <tom@tromey.com>
3246
3247         * xcoffread.c (aix_process_linenos, complete_symtab): Update.
3248         * dbxread.c (read_ofile_symtab): Update.
3249         * coffread.c (coff_start_symtab, coff_end_symtab): Update.
3250         * buildsym.h (last_source_start_addr): Remove.
3251         (set_last_source_start_addr, get_last_source_start_addr):
3252         Declare.
3253         * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
3254         parameter.
3255         (struct buildsym_compunit) <m_last_source_start_addr>: New
3256         member.
3257         (prepare_for_building): Remove start_addr parameter.
3258         (start_symtab, restart_symtab, end_symtab_get_static_block)
3259         (end_symtab_with_blockvector): Update.
3260         (set_last_source_start_addr, get_last_source_start_addr): New
3261         functions.
3262
3263 2018-07-16  Tom Tromey  <tom@tromey.com>
3264
3265         * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
3266         member.
3267         (have_line_numbers): Remove.
3268         (record_line, prepare_for_building, end_symtab_get_static_block)
3269         (augment_type_symtab): Update.
3270
3271 2018-07-16  Tom Tromey  <tom@tromey.com>
3272
3273         * buildsym.c (~buildsym_compunit): Free the macro table.
3274         (struct buildsym_compunit) <get_macro_table, release_macros>: New
3275         methods.
3276         <m_pending_macros>: New member.
3277         (pending_macros): Remove.
3278         (~scoped_free_pendings, get_macro_table, prepare_for_building)
3279         (reset_symtab_globals, end_symtab_get_static_block)
3280         (end_symtab_with_blockvector, augment_type_symtab)
3281         (buildsym_init): Update.
3282
3283 2018-07-16  Tom Tromey  <tom@tromey.com>
3284
3285         * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
3286         parameter.
3287         (buildsym_compunit::set_last_source_file): New method.
3288         <m_last_source_file>: New member.
3289         (prepare_for_building): Remove "name" parameter.
3290         (start_symtab, restart_symtab, reset_symtab_globals): Update.
3291         (last_source_file): Remove.
3292         (set_last_source_file, get_last_source_file): Update.
3293
3294 2018-07-16  Tom Tromey  <tom@tromey.com>
3295
3296         * buildsym.c (prepare_for_building): Add assert.
3297
3298 2018-07-16  Tom Tromey  <tom@tromey.com>
3299
3300         * buildsym.c (~buildsym_compunit): Update.
3301         (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
3302         (start_subfile, patch_subfile_names)
3303         (end_symtab_with_blockvector): Update.
3304
3305 2018-07-16  Tom Tromey  <tom@tromey.com>
3306
3307         * buildsym.c (struct buildsym_compunit): Add constructor,
3308         destructor, initializers.
3309         (start_buildsym_compunit): Remove.
3310         (free_buildsym_compunit): Use "delete".
3311         (start_symtab, restart_symtab): Use "new".
3312
3313 2018-07-13  Simon Marchi  <simon.marchi@polymtl.ca>
3314
3315         * symfile.c (set_objfile_default_section_offset): Remove struct
3316         keyword.
3317
3318 2018-07-14  Stafford Horne  <shorne@gmail.com>
3319
3320         * (Responsible Maintainers): Add myself as or1k maintainer.
3321
3322 2018-07-13  Tom Tromey  <tom@tromey.com>
3323
3324         * symfile.c (set_objfile_default_section_offset): Use extra braces
3325         around initializer.
3326
3327 2018-07-13  Andreas Arnez  <arnez@linux.vnet.ibm.com>
3328
3329         * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
3330         non-branching basr.
3331
3332 2018-07-12  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
3333
3334         * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3335         unittests/cli-utils-selftests.c
3336         * unittests/cli-utils-selftests.c: New file.
3337
3338 2018-07-12  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
3339
3340         * NEWS: Mention new commands. Mention change to 'thread apply'.
3341
3342 2018-07-12  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
3343
3344         * thread.c (thr_try_catch_cmd): New function.
3345         (thread_apply_all_command): Handle qcs flags.
3346         (thread_apply_command): Handle qcs flags.
3347         (taas_command): New function.
3348         (tfaas_command): New function.
3349         (_initialize_thread): Update to setup the new commands 'taas
3350         and 'tfaas'. Change doc string for 'thread apply'.
3351
3352 2018-07-12  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
3353
3354         * stack.c: (trailing_outermost_frame): New function, mostly
3355         extracted from backtrace_command_1.
3356         (leading_innermost_frame): New function.
3357         (backtrace_command_1): Update to call trailing_outermost_frame.
3358         (frame_apply_command_count): New function.
3359         (frame_apply_level_command): New function.
3360         (frame_apply_all_command): New function.
3361         (frame_apply_command): New function.
3362         (faas_command): New function.
3363         (frame_cmd_list): New variable.
3364         (_initialize_stack): Update to setup the new commands 'frame apply'
3365         and 'faas'.
3366
3367 2018-07-12  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
3368
3369         * cli-utils.c (number_or_range_parser::get_number): Only handle
3370         numbers or convenience var as numbers.
3371         (parse_flags): New function.
3372         (parse_flags_qcs): New function.
3373         (number_or_range_parser::finished): Ensure parsing end is detected
3374         before end of string.
3375         * cli-utils.h (parse_flags): New function.
3376         (parse_flags_qcs): New function.
3377         (number_or_range_parser): Remove m_finished bool.
3378         (number_or_range_parser::skip_range): Set m_in_range to false.
3379
3380 2018-07-12  Sergio Durigan Junior  <sergiodj@redhat.com>
3381
3382         * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
3383         on Windows.
3384
3385 2018-07-11  Sergio Durigan Junior  <sergiodj@redhat.com>
3386             Jan Kratochvil  <jan.kratochvil@redhat.com>
3387             Paul Fertser  <fercerpav@gmail.com>
3388             Tsutomu Seki  <sekiriki@gmail.com>
3389             Pedro Alves  <palves@redhat.com>
3390
3391         * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3392         'unittests/parse-connection-spec-selftests.c'.
3393         (COMMON_SFILES): Add 'common/netstuff.c'.
3394         (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
3395         * NEWS (Changes since GDB 8.2): Mention IPv6 support.
3396         * common/netstuff.c: New file.
3397         * common/netstuff.h: New file.
3398         * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
3399         (wait_for_connect): Update comment.  New parameter
3400         'gdb::optional<int> sock' instead of 'struct serial *scb'.
3401         Use 'sock' directly instead of 'scb->fd'.
3402         (try_connect): New function, with code from 'net_open'.
3403         (net_open): Rewrite main loop to deal with multiple
3404         sockets/addresses.  Handle IPv6-style hostnames; implement
3405         support for IPv6 connections.
3406         * unittests/parse-connection-spec-selftests.c: New file.
3407
3408 2018-07-11  Pedro Alves  <palves@redhat.com>
3409
3410         PR gdb/23377
3411         * remote.c (remote_target::remote_detach_pid): Call
3412         set_current_process.
3413
3414 2018-07-11  Pedro Alves  <palves@redhat.com>
3415
3416         * h8300-tdep.c (h8300_gdbarch_init): Remove
3417         set_gdbarch_ecoff_reg_to_regnum calls.
3418
3419 2018-07-11  Sergio Durigan Junior  <sergiodj@redhat.com>
3420
3421         PR c++/23373
3422         * c-typeprint.c (c_type_print_base_struct_union): Don't print
3423         offsets/sizes for static members of a class/struct.
3424
3425 2018-07-11  Alan Hayward  <alan.hayward@arm.com>
3426
3427         * target-descriptions.c (tdesc_register_bitsize): Rename.
3428         * target-descriptions.h (tdesc_register_bitsize): Likewise.
3429         * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
3430         * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
3431
3432 2018-07-10  Tom Tromey  <tom@tromey.com>
3433
3434         * breakpoint.c (moribund_locations): Now static and a
3435         std::vector.
3436         (breakpoint_init_inferior, moribund_breakpoint_here_p)
3437         (build_bpstat_chain, update_global_location_list)
3438         (breakpoint_retire_moribund): Update.
3439         * breakpoint.h (bp_location_p): Remove typedef.  Don't declare
3440         VEC.
3441
3442 2018-07-10  Andrew Burgess  <andrew.burgess@embecosm.com>
3443
3444         * riscv-tdep.c (riscv_is_fp_regno_p): New function.
3445         (riscv_register_reggroup_p): Use new function, remove unneeded
3446         parenthesis.
3447         (riscv_push_dummy_call): Extend assert to compare against xlen or
3448         flen based on register type.
3449
3450 2018-07-10  Andrew Burgess  <andrew.burgess@embecosm.com>
3451
3452         * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
3453
3454 2018-07-09  Andrew Burgess  <andrew.burgess@embecosm.com>
3455
3456         * remote.c (show_hardware_watchpoint_limit): New function.
3457         (show_hardware_watchpoint_length_limit): New function.
3458         (show_hardware_breakpoint_limit): New function.
3459         (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
3460         where appropriate, update help text.
3461
3462 2018-07-09  Tom Tromey  <tom@tromey.com>
3463
3464         * Makefile.in (CDEPS): Don't mention XM_CDEPS.
3465         (CLIBS): Don't mention NAT_CLIBS.
3466
3467 2018-07-09  Tom Tromey  <tom@tromey.com>
3468
3469         * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
3470         (LIBGDB_OBS, clean mostlyclean): Update.
3471         (gdb$(EXEEXT), insight$(EXEEXT)): Update.
3472
3473 2018-07-09  Tom Tromey  <tom@tromey.com>
3474
3475         * Makefile.in (%.c: %.y): Use ECHO_YACC.
3476         (%.c: %.l): Use ECHO_LEX.  Just fail if flex not available.
3477         * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
3478
3479 2018-07-09  Tom Tromey  <tom@tromey.com>
3480
3481         * Makefile.in (ALLDEPFILES): Remove exec.c.
3482         (COMMON_OBS): Remove exec.o.
3483         (COMMON_SFILES): Add exec.c.
3484
3485 2018-07-09  Tom Tromey  <tom@tromey.com>
3486
3487         * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
3488
3489 2018-07-09  Tom Tromey  <tom@tromey.com>
3490
3491         * Makefile.in (clean mostlyclean): Remove stamp-version.
3492         (version.c): Depend on stamp-version.
3493         (stamp-version): New rule, from version.c rule.
3494
3495 2018-07-09  Tom Tromey  <tom@tromey.com>
3496
3497         * Makefile.in (init.c): Depend on stamp-init.
3498         (stamp-init): New rule, from init.c rule.
3499         (clean mostlyclean): Remove stamp-init.
3500
3501 2018-07-09  Tom Tromey  <tom@tromey.com>
3502
3503         * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
3504         SUBDIR_GCC_COMPILE_SRCS.
3505
3506 2018-07-09  Tom Tromey  <tom@tromey.com>
3507
3508         * Makefile.in (init.c): Remove some unused sed rules.
3509
3510 2018-07-09  Tom Tromey  <tom@tromey.com>
3511
3512         * Makefile.in (TSOBS): Remove.
3513         (INIT_FILES): Update.
3514         (LIBGDB_OBS): Update.
3515         (COMMON_SFILES): Add inflow.c.
3516         (SFILES): Remove inflow.c.
3517
3518 2018-07-07  Jan Kratochvil  <jan.kratochvil@redhat.com>
3519
3520         * contrib/gdb-add-index.sh ($dwarf5): New, use it.
3521
3522 2018-07-07  Simon Marchi  <simon.marchi@polymtl.ca>
3523
3524         * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
3525         get_saveloc_name, is_signal_frame_name, step_name,
3526         init_remote_name, create_addr_space_name,
3527         destroy_addr_space_name, search_unwind_table_name,
3528         find_dyn_list_name): Constify.
3529
3530 2018-07-05  Simon Marchi  <simon.marchi@polymtl.ca>
3531
3532         * darwin-nat.c (darwin_pthread_kill): New function.
3533         (darwin_resume_thread): Use darwin_pthread_kill.
3534
3535 2018-07-05  Tom de Vries  <tdevries@suse.de>
3536
3537         * macroexp.c (macro_buffer) <operator=>: New member function.
3538
3539 2018-07-04  Tom Tromey  <tom@tromey.com>
3540
3541         * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
3542
3543 2018-07-04  Simon Marchi  <simon.marchi@polymtl.ca>
3544
3545         * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
3546         * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
3547         * maint.c: Likewise.
3548         * top.c: Likewise.
3549
3550 2018-07-04  Joel Brobecker  <brobecker@adacore.com>
3551
3552         * NEWS: Create a new section for the next release branch.
3553         Rename the section of the current branch, now that it has
3554         been cut.
3555
3556 2018-07-04  Joel Brobecker  <brobecker@adacore.com>
3557
3558         GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
3559         * version.in: Bump version to 8.2.50.DATE-git.
3560
3561 2018-07-04  Vyacheslav Barinov  <v.barinov@samsung.com>
3562             Pedro Alves  <palves@redhat.com>
3563
3564         * linux-nat.c (linux_init_ptrace): Rename to ...
3565         (linux_init_ptrace_procfs): ... this.  Call
3566         linux_proc_init_warnings.
3567         (linux_nat_target::post_attach)
3568         (linux_nat_target::post_startup_inferior): Adjust.
3569         * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
3570         * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
3571
3572 2018-07-04  Tom de Vries  <tdevries@suse.de>
3573
3574         * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
3575         check ...
3576         (read_comp_unit_head): ... here.
3577
3578 2018-07-03  Tom Tromey  <tom@tromey.com>
3579
3580         * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
3581         (stop_tracing, tstatus_command)
3582         (find_matching_tracepoint_location, merge_uploaded_tracepoints)
3583         (print_one_static_tracepoint_marker): Update.
3584         * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
3585         std::vector.
3586         * breakpoint.h (breakpoint_p): Remove typedef.  Don't declare
3587         VEC.
3588         (all_tracepoints, static_tracepoints_here): Return std::vector.
3589
3590 2018-07-03  Tom Tromey  <tom@tromey.com>
3591
3592         * common/ptid.c (ptid_equal): Remove.
3593         * common/ptid.h (ptid_equal): Don't declare.
3594         * ada-tasks.c: Update.
3595         * breakpoint.c: Update.
3596         * common/agent.c: Update.
3597         * corelow.c: Update.
3598         * darwin-nat-info.c: Update.
3599         * darwin-nat.c: Update.
3600         * dcache.c: Update.
3601         * dtrace-probe.c: Update.
3602         * dummy-frame.c: Update.
3603         * fbsd-nat.c: Update.
3604         * frame.c: Update.
3605         * gdbthread.h: Update.
3606         * gnu-nat.c: Update.
3607         * go32-nat.c: Update.
3608         * inf-loop.c: Update.
3609         * inf-ptrace.c: Update.
3610         * infcall.c: Update.
3611         * infcmd.c: Update.
3612         * inflow.c: Update.
3613         * infrun.c: Update.
3614         * linux-fork.c: Update.
3615         * linux-nat.c: Update.
3616         * linux-thread-db.c: Update.
3617         * mi/mi-cmd-var.c: Update.
3618         * mi/mi-interp.c: Update.
3619         * mi/mi-main.c: Update.
3620         * nto-procfs.c: Update.
3621         * ppc-linux-tdep.c: Update.
3622         * procfs.c: Update.
3623         * python/py-inferior.c: Update.
3624         * python/py-record-btrace.c: Update.
3625         * python/py-record.c: Update.
3626         * ravenscar-thread.c: Update.
3627         * regcache.c: Update.
3628         * remote-sim.c: Update.
3629         * remote.c: Update.
3630         * sol-thread.c: Update.
3631         * solib.c: Update.
3632         * target.c: Update.
3633         * tui/tui-stack.c: Update.
3634         * varobj.c: Update.
3635         * windows-nat.c: Update.
3636         * windows-tdep.c: Update.
3637
3638 2018-07-03  Tom Tromey  <tom@tromey.com>
3639
3640         * common/ptid.c (ptid_match): Remove.
3641         * common/ptid.h (ptid_match): Don't declare.
3642         * fbsd-nat.c: Update.
3643         * infcmd.c: Update.
3644         * infrun.c: Update.
3645         * linux-nat.c: Update.
3646         * record-btrace.c: Update.
3647         * regcache.c: Update.
3648         * remote.c: Update.
3649
3650 2018-07-03  Tom Tromey  <tom@tromey.com>
3651
3652         * common/ptid.c (ptid_tid_p): Remove.
3653         * common/ptid.h (ptid_tid_p): Don't declare.
3654         * sol-thread.c: Update.
3655
3656 2018-07-03  Tom Tromey  <tom@tromey.com>
3657
3658         * common/ptid.c (ptid_lwp_p): Remove.
3659         * common/ptid.h (ptid_lwp_p): Don't declare.
3660         * fbsd-nat.c: Update.
3661         * linux-nat.c: Update.
3662         * nat/linux-procfs.c: Update.
3663         * nat/x86-linux-dregs.c: Update.
3664         * sol-thread.c: Update.
3665
3666 2018-07-03  Tom Tromey  <tom@tromey.com>
3667
3668         * common/ptid.c (ptid_is_pid): Remove.
3669         * common/ptid.h (ptid_is_pid): Don't declare.
3670         * infrun.c: Update.
3671         * linux-nat.c: Update.
3672         * mi/mi-interp.c: Update.
3673         * remote.c: Update.
3674         * thread.c: Update.
3675
3676 2018-07-03  Tom Tromey  <tom@tromey.com>
3677
3678         * common/ptid.c (ptid_get_tid): Remove.
3679         * common/ptid.h (ptid_get_tid): Don't declare.
3680         * ada-tasks.c: Update.
3681         * aix-thread.c: Update.
3682         * bsd-uthread.c: Update.
3683         * darwin-nat.c: Update.
3684         * fbsd-nat.c: Update.
3685         * i386-darwin-nat.c: Update.
3686         * infrun.c: Update.
3687         * linux-tdep.c: Update.
3688         * nto-procfs.c: Update.
3689         * ppc-ravenscar-thread.c: Update.
3690         * python/py-infthread.c: Update.
3691         * ravenscar-thread.c: Update.
3692         * sol-thread.c: Update.
3693         * sparc-ravenscar-thread.c: Update.
3694         * windows-nat.c: Update.
3695
3696 2018-07-03  Tom Tromey  <tom@tromey.com>
3697
3698         * common/ptid.c (ptid_get_lwp): Remove.
3699         * common/ptid.h (ptid_get_lwp): Don't declare.
3700         * aarch64-linux-nat.c: Update.
3701         * ada-tasks.c: Update.
3702         * aix-thread.c: Update.
3703         * amd64-linux-nat.c: Update.
3704         * arm-linux-nat.c: Update.
3705         * corelow.c: Update.
3706         * fbsd-nat.c: Update.
3707         * fbsd-tdep.c: Update.
3708         * gnu-nat.c: Update.
3709         * i386-cygwin-tdep.c: Update.
3710         * i386-gnu-nat.c: Update.
3711         * i386-linux-nat.c: Update.
3712         * ia64-linux-nat.c: Update.
3713         * inf-ptrace.c: Update.
3714         * infrun.c: Update.
3715         * linux-fork.c: Update.
3716         * linux-nat.c: Update.
3717         * linux-tdep.c: Update.
3718         * linux-thread-db.c: Update.
3719         * mips-linux-nat.c: Update.
3720         * nat/aarch64-linux-hw-point.c: Update.
3721         * nat/aarch64-linux.c: Update.
3722         * nat/linux-btrace.c: Update.
3723         * nat/linux-osdata.c: Update.
3724         * nat/linux-procfs.c: Update.
3725         * nat/x86-linux-dregs.c: Update.
3726         * obsd-nat.c: Update.
3727         * ppc-fbsd-nat.c: Update.
3728         * ppc-linux-nat.c: Update.
3729         * procfs.c: Update.
3730         * python/py-infthread.c: Update.
3731         * ravenscar-thread.c: Update.
3732         * remote.c: Update.
3733         * s390-linux-nat.c: Update.
3734         * sol-thread.c: Update.
3735         * sol2-tdep.c: Update.
3736         * spu-linux-nat.c: Update.
3737         * x86-linux-nat.c: Update.
3738         * xtensa-linux-nat.c: Update.
3739
3740 2018-07-03  Tom Tromey  <tom@tromey.com>
3741
3742         * common/ptid.c (ptid_get_pid): Remove.
3743         * common/ptid.h (ptid_get_pid): Don't declare.
3744         * aarch64-linux-nat.c: Update.
3745         * ada-lang.c: Update.
3746         * aix-thread.c: Update.
3747         * alpha-bsd-nat.c: Update.
3748         * amd64-fbsd-nat.c: Update.
3749         * amd64-linux-nat.c: Update.
3750         * arm-linux-nat.c: Update.
3751         * arm-nbsd-nat.c: Update.
3752         * auxv.c: Update.
3753         * break-catch-syscall.c: Update.
3754         * breakpoint.c: Update.
3755         * bsd-uthread.c: Update.
3756         * corelow.c: Update.
3757         * ctf.c: Update.
3758         * darwin-nat.c: Update.
3759         * fbsd-nat.c: Update.
3760         * fbsd-tdep.c: Update.
3761         * gcore.c: Update.
3762         * gnu-nat.c: Update.
3763         * hppa-nbsd-nat.c: Update.
3764         * hppa-obsd-nat.c: Update.
3765         * i386-fbsd-nat.c: Update.
3766         * ia64-linux-nat.c: Update.
3767         * inf-ptrace.c: Update.
3768         * infcmd.c: Update.
3769         * inferior.c: Update.
3770         * inferior.h: Update.
3771         * inflow.c: Update.
3772         * infrun.c: Update.
3773         * linux-fork.c: Update.
3774         * linux-nat.c: Update.
3775         * linux-tdep.c: Update.
3776         * linux-thread-db.c: Update.
3777         * m68k-bsd-nat.c: Update.
3778         * mi/mi-interp.c: Update.
3779         * mi/mi-main.c: Update.
3780         * mips-linux-nat.c: Update.
3781         * mips-nbsd-nat.c: Update.
3782         * mips64-obsd-nat.c: Update.
3783         * nat/aarch64-linux-hw-point.c: Update.
3784         * nat/aarch64-linux.c: Update.
3785         * nat/linux-btrace.c: Update.
3786         * nat/linux-osdata.c: Update.
3787         * nat/linux-procfs.c: Update.
3788         * nat/x86-linux-dregs.c: Update.
3789         * nto-procfs.c: Update.
3790         * obsd-nat.c: Update.
3791         * ppc-linux-nat.c: Update.
3792         * ppc-nbsd-nat.c: Update.
3793         * ppc-obsd-nat.c: Update.
3794         * proc-service.c: Update.
3795         * procfs.c: Update.
3796         * python/py-inferior.c: Update.
3797         * python/py-infthread.c: Update.
3798         * ravenscar-thread.c: Update.
3799         * record.c: Update.
3800         * remote-sim.c: Update.
3801         * remote.c: Update.
3802         * rs6000-nat.c: Update.
3803         * s390-linux-nat.c: Update.
3804         * sh-nbsd-nat.c: Update.
3805         * sol-thread.c: Update.
3806         * sparc-nat.c: Update.
3807         * sparc64-tdep.c: Update.
3808         * spu-linux-nat.c: Update.
3809         * spu-tdep.c: Update.
3810         * target-debug.h: Update.
3811         * target.c: Update.
3812         * thread.c: Update.
3813         * tid-parse.c: Update.
3814         * tracefile-tfile.c: Update.
3815         * vax-bsd-nat.c: Update.
3816         * windows-nat.c: Update.
3817         * x86-linux-nat.c: Update.
3818         * x86-nat.c: Update.
3819
3820 2018-07-03  Tom Tromey  <tom@tromey.com>
3821
3822         * common/ptid.c (pid_to_ptid): Remove.
3823         * common/ptid.h (pid_to_ptid): Don't declare.
3824         * aix-thread.c: Update.
3825         * arm-linux-nat.c: Update.
3826         * common/ptid.c: Update.
3827         * common/ptid.h: Update.
3828         * corelow.c: Update.
3829         * ctf.c: Update.
3830         * darwin-nat.c: Update.
3831         * fbsd-nat.c: Update.
3832         * fork-child.c: Update.
3833         * gnu-nat.c: Update.
3834         * go32-nat.c: Update.
3835         * inf-ptrace.c: Update.
3836         * infcmd.c: Update.
3837         * inferior.c: Update.
3838         * infrun.c: Update.
3839         * linux-fork.c: Update.
3840         * linux-nat.c: Update.
3841         * nat/aarch64-linux-hw-point.c: Update.
3842         * nat/fork-inferior.c: Update.
3843         * nat/x86-linux-dregs.c: Update.
3844         * nto-procfs.c: Update.
3845         * obsd-nat.c: Update.
3846         * procfs.c: Update.
3847         * progspace.c: Update.
3848         * remote.c: Update.
3849         * rs6000-nat.c: Update.
3850         * s390-linux-nat.c: Update.
3851         * sol-thread.c: Update.
3852         * spu-linux-nat.c: Update.
3853         * target.c: Update.
3854         * top.c: Update.
3855         * tracefile-tfile.c: Update.
3856         * windows-nat.c: Update.
3857
3858 2018-07-03  Tom Tromey  <tom@tromey.com>
3859
3860         * common/ptid.h (ptid_build): Don't declare.
3861         * common/ptid.c (ptid_build): Remove.
3862         * aix-thread.c: Update.
3863         * bsd-kvm.c: Update.
3864         * bsd-uthread.c: Update.
3865         * common/agent.c: Update.
3866         * common/ptid.c: Update.
3867         * common/ptid.h: Update.
3868         * corelow.c: Update.
3869         * darwin-nat.c: Update.
3870         * fbsd-nat.c: Update.
3871         * gnu-nat.c: Update.
3872         * linux-fork.c: Update.
3873         * linux-nat.c: Update.
3874         * linux-thread-db.c: Update.
3875         * nat/linux-osdata.c: Update.
3876         * nat/linux-procfs.c: Update.
3877         * nto-procfs.c: Update.
3878         * obsd-nat.c: Update.
3879         * proc-service.c: Update.
3880         * procfs.c: Update.
3881         * ravenscar-thread.c: Update.
3882         * remote-sim.c: Update.
3883         * remote.c: Update.
3884         * sol-thread.c: Update.
3885         * target.c: Update.
3886         * windows-nat.c: Update.
3887
3888 2018-07-03  Tom Tromey  <tom@tromey.com>
3889
3890         * infrun.c (follow_exec): Use exit_inferior_silent.
3891         * inferior.c (exit_inferior_num_silent): Remove.
3892         * inferior.h (exit_inferior_num_silent): Don't declare.
3893
3894 2018-07-03  Tom Tromey  <tom@tromey.com>
3895
3896         PR cli/23340:
3897         * darwin-nat.c (darwin_attach_pid): Reset inferior and
3898         inferior_ptid on error.
3899
3900 2018-07-02  Maciej W. Rozycki  <macro@mips.com>
3901             Simon Marchi  <simon.marchi@polymtl.ca>
3902
3903         PR tdep/8282
3904         * disasm.h (gdb_disassembler): Add
3905         `m_disassembler_options_holder'. member
3906         * disasm.c (get_all_disassembler_options): New function.
3907         (gdb_disassembler::gdb_disassembler): Use it.
3908         (gdb_buffered_insn_length_init_dis): Likewise.
3909         (gdb_buffered_insn_length): Adjust accordingly.
3910         (set_disassembler_options): Handle options with arguments.
3911         (show_disassembler_options_sfunc): Likewise.  Add a leading new
3912         line if showing options with descriptions.
3913         (disassembler_options_completer): Adapt to using the
3914         `disasm_options_and_args_t' structure.
3915         * mips-tdep.c (mips_disassembler_options): New variable.
3916         (mips_disassembler_options_o32): Likewise.
3917         (mips_disassembler_options_n32): Likewise.
3918         (mips_disassembler_options_n64): Likewise.
3919         (gdb_print_insn_mips): Don't set `disassembler_options'.
3920         (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
3921         functions.
3922         (mips_gdbarch_init): Always set `gdbarch_print_insn' to
3923         `gdb_print_insn_mips'.  Set `gdbarch_disassembler_options',
3924         `gdbarch_disassembler_options_implicit' and
3925         `gdbarch_valid_disassembler_options'.
3926         * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
3927         `disasm_options_and_args_t' structure.
3928         * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
3929         method.
3930         (valid_disassembler_options): Switch from `disasm_options_t' to
3931         the `disasm_options_and_args_t' structure.
3932         * NEWS: Document `set disassembler-options' support for the MIPS
3933         target.
3934         * gdbarch.h: Regenerate.
3935         * gdbarch.c: Regenerate.
3936
3937 2018-07-02  Sebastian Huber  <sebastian.huber@embedded-brains.de>
3938
3939         * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
3940
3941 2018-06-29  Joel Brobecker  <brobecker@adacore.com>
3942
3943         * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
3944         parameter in call to amd64_target_description.
3945         * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
3946         * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
3947         (amd64fbsd_init_abi): Likewise.
3948         * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
3949         * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
3950         * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
3951         * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
3952
3953 2018-06-29  Pedro Alves  <palves@redhat.com>
3954
3955         * gdb/amd64-tdep.h (amd64_create_target_description): Add
3956         "segments" parameter.
3957         * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
3958         (_initialize_amd64_tdep): Update call to
3959         amd64_create_target_description.
3960         (amd64_target_description): Add "segments" parameter.  Adjust
3961         the implementation to use it.
3962         * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
3963         call to amd64_create_target_description.
3964         * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
3965         * gdb/arch/amd64.h (amd64_create_target_description): Add
3966         "segments" register.
3967         * gdb/arch/amd64.c (amd64_create_target_description): Add
3968         "segments" parameter.  Call create_feature_i386_64bit_segments
3969         only if SEGMENTS is true.
3970         * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
3971         call to amd64_create_target_description.
3972
3973 2018-06-29  Pedro Alves  <palves@redhat.com>
3974
3975         * thread.c (thread_target_id_str): New, factored out from ...
3976         (print_thread_info_1): ... here.  Use it to compute the max
3977         "Target Id" column width.
3978
3979 2018-06-29  Pedro Alves  <palves@redhat.com>
3980
3981         * remote.c (remote_target::extra_thread_info): Delete
3982         'display_buf' and 'n' locals.  from the cache, regardless of
3983         packet mechanims is in use.  Use cache for qThreadExtra and qP
3984         methods too.
3985
3986 2018-06-29  Pedro Alves  <palves@redhat.com>
3987
3988         * blockframe.c (find_pc_sect_containing_function): New function.
3989         * breakpoint.c (print_breakpoint_location): Don't call
3990         find_pc_sect_function.
3991         * linespec.c (create_sals_line_offset): Record the location's
3992         symbol in the sal.
3993         * linespec.c (convert_address_location_to_sals): Fill in sal's
3994         symbol with find_pc_sect_containing_function.
3995         * symtab.c (find_function_start_sal): Rename to ...
3996         (find_function_start_sal_1): ... this.
3997         (find_function_start_sal): Reimplement as wrapper around
3998         find_function_start_sal_1, and use
3999         find_pc_sect_containing_function to fill in the sal's symbol.
4000         (find_function_start_sal(symbol*, bool)): Adjust.
4001         * symtab.h (find_pc_function, find_pc_sect_function): Adjust
4002         comments.
4003         (find_pc_sect_containing_function): Declare.
4004
4005 2018-06-29  Pedro Alves  <palves@redhat.com>
4006
4007         * inline-frame.c (stopped_by_user_bp_inline_frame): Return
4008         true if the the location has no symbol.
4009
4010 2018-06-28  Tom Tromey  <tom@tromey.com>
4011
4012         * NEWS: Mention --enable-codesign.
4013         * silent-rules.mk (ECHO_SIGN): New variable.
4014         * configure.ac: Add --enable-codesign.
4015         * configure: Rebuild.
4016         * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
4017         (gdb$(EXEEXT)): Optionally invoke codesign.
4018
4019 2018-06-28  Pedro Alves  <palves@redhat.com>
4020
4021         * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
4022         comments.
4023         (switch_to_thread_no_regs): Adjust comment.
4024         * infcmd.c (stop_pc): Delete.
4025         (post_create_inferior, info_program_command): Replace references
4026         to stop_pc with references to thread_info->suspend.stop_pc.
4027         * inferior.h (stop_pc): Delete declaration.
4028         * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
4029         (handle_inferior_event_1, handle_signal_stop)
4030         (process_event_stop_test, keep_going_stepped_thread)
4031         (handle_step_into_function, handle_step_into_function_backward)
4032         (print_stop_location): Replace references to stop_pc with
4033         references to thread_info->suspend.stop_pc.
4034         (struct infcall_suspend_state) <stop_pc>: Delete field.
4035         (save_infcall_suspend_state, restore_infcall_suspend_state):
4036         Remove references to inf_stat->stop_pc.
4037         * linux-fork.c (fork_load_infrun_state): Likewise.
4038         * record-btrace.c (record_btrace_set_replay): Likewise.
4039         * record-full.c (record_full_goto_entry): Likewise.
4040         * remote.c (print_one_stopped_thread): Likewise.
4041         * target.c (target_resume): Extend comment.
4042         * thread.c (set_executing_thread): New.
4043         (set_executing): Use it.
4044         (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
4045         Remove references to stop_pc.
4046
4047 2018-06-28  Pedro Alves  <palves@redhat.com>
4048
4049         * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
4050         Moving fetching stop_pc until after ecs->event_thread is refreshed.
4051
4052 2018-06-28  Tom Tromey  <tom@tromey.com>
4053
4054         * coffread.c (coff_symfile_finish): Update.
4055         * xcoffread.c (xcoff_symfile_finish): Update.
4056         * elfread.c (elf_symfile_finish): Update.
4057         * symfile.h (dwarf2_free_objfile): Don't declare.
4058         * dwarf2read.c (_initialize_dwarf2_read): Use
4059         register_objfile_data_with_cleanup.
4060         (dwarf2_free_objfile): Now static.  Change signature.
4061
4062 2018-06-28  Petr Tesarik  <ptesarik@suse.cz>
4063
4064         * symfile.c (add_symbol_file_command, _initialize_symfile): Add
4065         option "-o" to add-symbol-file-load to add an offset to each
4066         section's load address.
4067         * symfile.c (set_objfile_default_section_offset): New function.
4068
4069 2018-06-28  Petr Tesarik  <ptesarik@suse.cz>
4070
4071         * symfile.c (add_symbol_file_command): Make sure that sections
4072         with the same name are sorted in the same order.
4073
4074 2018-06-28  Petr Tesarik  <ptesarik@suse.cz>
4075
4076         * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
4077         require the second argument.  If omitted, load sections at the
4078         addresses specified in the file.
4079
4080 2018-06-28  Petr Tesarik  <ptesarik@suse.cz>
4081
4082         * symfile.c (symbol_file_command, symbol_file_add_main_1)
4083         (_initialize_symfile): Add option "-o" to symbol-file to add an
4084         offset to each section of the symbol file.
4085
4086 2018-06-28  Petr Tesarik  <ptesarik@suse.cz>
4087
4088         * MAINTAINERS (Write After Approval): Add Petr Tesarik.
4089
4090 2018-06-27  Tom Tromey  <tom@tromey.com>
4091
4092         * stack.c (_initialize_stack): Update "func" help text.
4093
4094 2018-06-27  Tom Tromey  <tom@tromey.com>
4095
4096         * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
4097         std::vector.
4098         (unwind_infopy_str, pyuw_create_unwind_info)
4099         (unwind_infopy_add_saved_register, pyuw_sniffer)
4100         (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
4101         Update.
4102         (struct saved_reg): Add constructor.
4103         <value>: Now a gdbpy_ref<>.
4104
4105 2018-06-27  Tom Tromey  <tom@tromey.com>
4106
4107         * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
4108
4109 2018-06-27  Simon Marchi  <simon.marchi@ericsson.com>
4110
4111         * gdb-gdb.py.in: Format using autopep8.
4112
4113 2018-06-27  Simon Marchi  <simon.marchi@ericsson.com>
4114
4115         * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
4116         (type_lookup_function): Recognize CORE_ADDR values.
4117
4118 2018-06-27  Simon Marchi  <simon.marchi@ericsson.com>
4119
4120         * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
4121         print tag_name.
4122
4123 2018-06-27  Simon Marchi  <simon.marchi@ericsson.com>
4124
4125         * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
4126         <__lt__>: Add.
4127
4128 2018-06-27  Simon Marchi  <simon.marchi@ericsson.com>
4129
4130         * gdb-gdb.py: Move to...
4131         * gdb-gdb.py.in: ... here.
4132         * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
4133         * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
4134         dependencies.
4135         (distclean): Remove gdb-gdb.py when cleaning.
4136         (gdb-gdb.py, gdb-gdb.gdb): New rules.
4137         * configure: Re-generate.
4138
4139 2018-06-27  Pedro Alves  <palves@redhat.com>
4140
4141         * proc-service.c (get_ps_regcache): New.
4142         (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
4143         (ps_lsetfpregs): Use it.
4144
4145 2018-06-27  Omair Javaid  <omair.javaid@linaro.org>
4146
4147         PR gdb/21695
4148         * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
4149         (dwarf_decode_lines_1): Adjust.
4150
4151 2018-06-27  Simon Marchi  <simon.marchi@ericsson.com>
4152
4153         * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
4154         override.
4155         <info_proc>: Likewise.
4156
4157 2018-06-26  Joel Brobecker  <brobecker@adacore.com>
4158
4159         * windows-nat.c (do_windows_fetch_inferior_registers): Rename
4160         to windows_fetch_one_register, and only handle the case of
4161         fetching one register.  Move the code that reloads the context
4162         and iterates over all registers if R is negative to...
4163         (windows_nat_target::fetch_registers): ... here.
4164         (do_windows_store_inferior_registers): Rename to
4165         windows_store_one_register, and only handle the case of storing
4166         one register.  Move the code that handles the case where r is
4167         negative to...
4168         (windows_nat_target::store_registers) ... here.
4169
4170 2018-06-26  Tom Tromey  <tom@tromey.com>
4171
4172         PR rust/22574:
4173         * typeprint.c (whatis_exp): Allow ptype/o for Rust.
4174         * rust-lang.c (rust_print_struct_def): Add podata parameter.
4175         Update.
4176         (rust_internal_print_type): Add podata parameter.
4177         (rust_print_type): Update.
4178
4179 2018-06-26  Tom Tromey  <tom@tromey.com>
4180
4181         * typeprint.h (struct print_offset_data) <update, finish,
4182         maybe_print_hole>: New methods.
4183         <indentation>: New constant.
4184         * typeprint.c (print_offset_data::indentation): Define.
4185         (print_offset_data::maybe_print_hole, print_offset_data::update)
4186         (print_offset_data::finish): Move from c-typeprint.c and rename.
4187         * c-typeprint.c (OFFSET_SPC_LEN): Remove.
4188         (print_spaces_filtered_with_print_options): Update.
4189         (c_print_type_union_field_offset, maybe_print_hole)
4190         (c_print_type_struct_field_offset): Move to typeprint.c and
4191         rename.
4192         (c_type_print_base_struct_union): Update.
4193
4194 2018-06-25  Pedro Alves  <palves@redhat.com>
4195
4196         * gdbthread.h (thread_info_ref, delete_thread)
4197         (delete_thread_silent, first_thread_of_inferior)
4198         (any_thread_of_inferior, switch_to_thread)
4199         (enable_thread_stack_temporaries)
4200         (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4201         (get_last_thread_stack_temporary)
4202         (value_in_thread_stack_temporaries, can_access_registers_thread):
4203         Spell out "struct thread_info" instead of just "thread_info".
4204         * inferior.h (notice_new_inferior): Likewise.
4205
4206 2018-06-25  Pedro Alves  <palves@redhat.com>
4207
4208         * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4209         pass thread_info pointer to delete_thread.
4210         (windows_nat_target::detach): Pass inferior pointer to
4211         detach_inferior.
4212         * aix-thread.c (sync_threadlists): Pass thread_info pointer to
4213         delete_thread.
4214         * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
4215         * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
4216         and pass a thread_info pointer to delete_thread.
4217         * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
4218         pass thread_info pointer to delete_thread.
4219         * go32-nat.c (go32_nat_target::mourn_inferior): Remove
4220         delete_thread_silent call.
4221         * procfs.c (procfs_target::detach): Pass inferior pointer to
4222         detach_inferior.
4223         (procfs_target::wait): Pass thread_info pointer to delete_thread.
4224         * remote-sim.c (gdbsim_target::mourn_inferior): Remove
4225         delete_thread_silent call.
4226         * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4227         pass thread_info pointer to delete_thread.
4228         (windows_nat_target::detach): Pass inferior pointer to
4229         delete_inferior.
4230
4231 2018-06-22  Alan Hayward  <alan.hayward@arm.com>
4232
4233         * regcache.c (readable_regcache::read_part): Fix asserts.
4234         (reg_buffer::raw_collect_part): New function.
4235         (regcache::write_part): Fix asserts.
4236         (reg_buffer::raw_supply_part): New function.
4237         (regcache::transfer_regset_register): New helper function.
4238         (regcache::transfer_regset): Call new functions.
4239         (regcache_supply_regset): Use gdb_byte*.
4240         (regcache::supply_regset): Likewise.
4241         (regcache_collect_regset): Likewise.
4242         (regcache::collect_regset): Likewise.
4243         * regcache.h (reg_buffer::raw_collect_part): New declaration.
4244         (reg_buffer::raw_supply_part): Likewise.
4245         (regcache::transfer_regset_register): Likewise.
4246         (regcache::transfer_regset): Use gdb_byte*.
4247
4248 2018-06-22  Alan Hayward  <alan.hayward@arm.com>
4249
4250         * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
4251
4252 2018-06-21  Pedro Alves  <palves@redhat.com>
4253
4254         * ada-lang.h (ada_get_task_number): Take a thread_info pointer
4255         instead of a ptid_t.  All callers adjusted.
4256         * ada-tasks.c (ada_get_task_number): Likewise.  All callers
4257         adjusted.
4258         (print_ada_task_info, display_current_task_id, task_command_1):
4259         Adjust.
4260         * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
4261         inferior_thread.
4262         (breakpoint_kind): Adjust.
4263         (remove_breakpoints_pid): Rename to ...
4264         (remove_breakpoints_inf): ... this.  Adjust to take an inferior
4265         pointer.  All callers adjusted.
4266         (bpstat_clear_actions): Use inferior_thread.
4267         (get_bpstat_thread): New.
4268         (bpstat_do_actions): Use it.
4269         (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
4270         to take a thread_info pointer.  All callers adjusted.
4271         (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
4272         (breakpoint_re_set_thread): Use inferior_thread.
4273         * breakpoint.h (struct inferior): Forward declare.
4274         (bpstat_stop_status): Update.
4275         (remove_breakpoints_pid): Delete.
4276         (remove_breakpoints_inf): New.
4277         * bsd-uthread.c (bsd_uthread_target::wait)
4278         (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
4279         * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
4280         (maint_btrace_packet_history_cmd)
4281         (maint_btrace_clear_packet_history_cmd): Adjust.
4282         (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
4283         inferior_thread.
4284         * cli/cli-interp.c: Include "inferior.h".
4285         * common/refcounted-object.h (struct
4286         refcounted_object_ref_policy): New.
4287         * compile/compile-object-load.c: Include gdbthread.h.
4288         (store_regs): Use inferior_thread.
4289         * corelow.c (core_target::close): Use current_inferior.
4290         (core_target_open): Adjust to use first_thread_of_inferior and use
4291         the current inferior.
4292         * ctf.c (ctf_target::close): Adjust to use current_inferior.
4293         * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
4294         <thread>: ... this new field.  All references adjusted.
4295         (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
4296         Take a thread_info pointer instead of a ptid_t.
4297         * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
4298         (dummy_frame_discard, register_dummy_frame_dtor): Take a
4299         thread_info pointer instead of a ptid_t.
4300         * elfread.c: Include "inferior.h".
4301         (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
4302         Use inferior_thread.
4303         * eval.c (evaluate_subexp): Likewise.
4304         * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
4305         inferior_thread.
4306         * gdb_proc_service.h (struct thread_info): Forward declare.
4307         (struct ps_prochandle) <ptid>: Delete, replaced by ...
4308         <thread>: ... this new field.  All references adjusted.
4309         * gdbarch.h, gdbarch.c: Regenerate.
4310         * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
4311         'thread' parameter.  All implementations and callers adjusted.
4312         * gdbthread.h (thread_info) <set_running>: New method.
4313         (delete_thread, delete_thread_silent): Take a thread_info pointer
4314         instead of a ptid.
4315         (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
4316         (first_thread_of_process): Delete, replaced by ...
4317         (first_thread_of_inferior): ... this new function.  All callers
4318         adjusted.
4319         (any_live_thread_of_process): Delete, replaced by ...
4320         (any_live_thread_of_inferior): ... this new function.  All callers
4321         adjusted.
4322         (switch_to_thread, switch_to_no_thread): Declare.
4323         (is_executing): Delete.
4324         (enable_thread_stack_temporaries): Update comment.
4325         <enable_thread_stack_temporaries>: Take a thread_info pointer
4326         instead of a ptid_t.  Incref the thread.
4327         <~enable_thread_stack_temporaries>: Decref the thread.
4328         <m_ptid>: Delete
4329         <m_thr>: New.
4330         (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4331         (get_last_thread_stack_temporary)
4332         (value_in_thread_stack_temporaries, can_access_registers_thread):
4333         Take a thread_info pointer instead of a ptid_t.  All callers
4334         adjusted.
4335         * infcall.c (get_call_return_value): Use inferior_thread.
4336         (run_inferior_call): Work with thread pointers instead of ptid_t.
4337         (call_function_by_hand_dummy): Work with thread pointers instead
4338         of ptid_t.  Use thread_info_ref.
4339         * infcmd.c (proceed_thread_callback): Access thread's state
4340         directly.
4341         (ensure_valid_thread, ensure_not_running): Use inferior_thread,
4342         access thread's state directly.
4343         (continue_command): Use inferior_thread.
4344         (info_program_command): Use find_thread_ptid and access thread
4345         state directly.
4346         (proceed_after_attach_callback): Use thread state directly.
4347         (notice_new_inferior): Take a thread_info pointer instead of a
4348         ptid_t.  All callers adjusted.
4349         (exit_inferior): Take an inferior pointer instead of a pid.  All
4350         callers adjusted.
4351         (exit_inferior_silent): New.
4352         (detach_inferior): Delete.
4353         (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
4354         (gdb_inferior_id_to_pid, in_inferior_list): Delete.
4355         (detach_inferior_command, kill_inferior_command): Use
4356         find_inferior_id instead of valid_gdb_inferior_id and
4357         gdb_inferior_id_to_pid.
4358         (inferior_command): Use inferior and thread pointers.
4359         * inferior.h (struct thread_info): Forward declare.
4360         (notice_new_inferior): Take a thread_info pointer instead of a
4361         ptid_t.  All callers adjusted.
4362         (detach_inferior): Delete declaration.
4363         (exit_inferior, exit_inferior_silent): Take an inferior pointer
4364         instead of a pid.  All callers adjusted.
4365         (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
4366         (valid_gdb_inferior_id): Delete.
4367         * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
4368         (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
4369         (struct displaced_step_inferior_state) <pid>: Delete, replaced by
4370         ...
4371         <inf>: ... this new field.
4372         <step_ptid>: Delete, replaced by ...
4373         <step_thread>: ... this new field.
4374         (get_displaced_stepping_state): Take an inferior pointer instead
4375         of a pid.  All callers adjusted.
4376         (displaced_step_in_progress_any_inferior): Adjust.
4377         (displaced_step_in_progress_thread): Take a thread pointer instead
4378         of a ptid_t.  All callers adjusted.
4379         (displaced_step_in_progress, add_displaced_stepping_state): Take
4380         an inferior pointer instead of a pid.  All callers adjusted.
4381         (get_displaced_step_closure_by_addr): Adjust.
4382         (remove_displaced_stepping_state): Take an inferior pointer
4383         instead of a pid.  All callers adjusted.
4384         (displaced_step_prepare_throw, displaced_step_prepare)
4385         (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
4386         All callers adjusted.
4387         (start_step_over): Adjust.
4388         (infrun_thread_ptid_changed): Remove bit updating ptids in the
4389         displaced step queue.
4390         (do_target_resume): Adjust.
4391         (fetch_inferior_event): Use inferior_thread.
4392         (context_switch, get_inferior_stop_soon): Take an
4393         execution_control_state pointer instead of a ptid_t.  All callers
4394         adjusted.
4395         (switch_to_thread_cleanup): Delete.
4396         (stop_all_threads): Use scoped_restore_current_thread.
4397         * inline-frame.c: Include "gdbthread.h".
4398         (inline_state) <inline_state>: Take a thread pointer instead of a
4399         ptid_t.  All callers adjusted.
4400         <ptid>: Delete, replaced by ...
4401         <thread>: ... this new field.
4402         (find_inline_frame_state): Take a thread pointer instead of a
4403         ptid_t.  All callers adjusted.
4404         (skip_inline_frames, step_into_inline_frame)
4405         (inline_skipped_frames, inline_skipped_symbol): Take a thread
4406         pointer instead of a ptid_t.  All callers adjusted.
4407         * inline-frame.h (skip_inline_frames, step_into_inline_frame)
4408         (inline_skipped_frames, inline_skipped_symbol): Likewise.
4409         * linux-fork.c (delete_checkpoint_command): Adjust to use thread
4410         pointers directly.
4411         * linux-nat.c (get_detach_signal): Likewise.
4412         * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
4413         (thread_db_notice_clone): Adjust.
4414         (thread_db_find_new_threads_silently)
4415         (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
4416         a thread pointer instead of a ptid_t.  All callers adjusted.
4417         * mi/mi-cmd-var.c: Include "inferior.h".
4418         (mi_cmd_var_update_iter): Update to use thread pointers.
4419         * mi/mi-interp.c (mi_new_thread): Update to use the thread's
4420         inferior directly.
4421         (mi_output_running_pid, mi_inferior_count): Delete, bits factored
4422         out to ...
4423         (mi_output_running): ... this new function.
4424         (mi_on_resume_1): Adjust to use it.
4425         (mi_user_selected_context_changed): Adjust to use inferior_thread.
4426         * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
4427         directly.
4428         (interrupt_thread_callback): : Adjust to use thread and inferior
4429         pointers.
4430         * proc-service.c: Include "gdbthread.h".
4431         (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
4432         * progspace-and-thread.c: Include "inferior.h".
4433         * progspace.c: Include "inferior.h".
4434         * python/py-exitedevent.c (create_exited_event_object): Adjust to
4435         hold a reference to an inferior_object.
4436         * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
4437         inferior_thread.
4438         * python/py-inferior.c (struct inferior_object): Give the type a
4439         tag name instead of a typedef.
4440         (python_on_normal_stop): No need to check if the current thread is
4441         listed.
4442         (inferior_to_inferior_object): Change return type to
4443         inferior_object.  All callers adjusted.
4444         (find_thread_object): Delete, bits factored out to ...
4445         (thread_to_thread_object): ... this new function.
4446         * python/py-infthread.c (create_thread_object): Use
4447         inferior_to_inferior_object.
4448         (thpy_is_stopped): Use thread pointer directly.
4449         (gdbpy_selected_thread): Use inferior_thread.
4450         * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
4451         field, replaced with ...
4452         <thread>: ... this new field.  All users adjusted.
4453         (btpy_insn_or_gap_new): Drop const.
4454         (btpy_list_new): Take a thread pointer instead of a ptid_t.  All
4455         callers adjusted.
4456         * python/py-record.c: Include "gdbthread.h".
4457         (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4458         a ptid_t.  All callers adjusted.
4459         (gdbpy_current_recording): Use inferior_thread.
4460         * python/py-record.h (recpy_record_object) <ptid>: Delete
4461         field, replaced with ...
4462         <thread>: ... this new field.  All users adjusted.
4463         (recpy_element_object) <ptid>: Delete
4464         field, replaced with ...
4465         <thread>: ... this new field.  All users adjusted.
4466         (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4467         a ptid_t.  All callers adjusted.
4468         * python/py-threadevent.c: Include "gdbthread.h".
4469         (get_event_thread): Use thread_to_thread_object.
4470         * python/python-internal.h (struct inferior_object): Forward
4471         declare.
4472         (find_thread_object, find_inferior_object): Delete declarations.
4473         (thread_to_thread_object, inferior_to_inferior_object): New
4474         declarations.
4475         * record-btrace.c: Include "inferior.h".
4476         (require_btrace_thread): Use inferior_thread.
4477         (record_btrace_frame_sniffer)
4478         (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
4479         (get_thread_current_frame): Use scoped_restore_current_thread and
4480         switch_to_thread.
4481         (get_thread_current_frame): Use thread pointer directly.
4482         (record_btrace_replay_at_breakpoint): Use thread's inferior
4483         pointer directly.
4484         * record-full.c: Include "inferior.h".
4485         * regcache.c: Include "gdbthread.h".
4486         (get_thread_arch_regcache): Use the inferior's address space
4487         directly.
4488         (get_thread_regcache, registers_changed_thread): New.
4489         * regcache.h (get_thread_regcache(thread_info *thread)): New
4490         overload.
4491         (registers_changed_thread): New.
4492         (remote_target) <remote_detach_1>: Swap order of parameters.
4493         (remote_add_thread): <remote_add_thread>: Return the new thread.
4494         (get_remote_thread_info(ptid_t)): New overload.
4495         (remote_target::remote_notice_new_inferior): Use thread pointers
4496         directly.
4497         (remote_target::process_initial_stop_replies): Use
4498         thread_info::set_running.
4499         (remote_target::remote_detach_1, remote_target::detach)
4500         (extended_remote_target::detach): Adjust.
4501         * stack.c (frame_show_address): Use inferior_thread.
4502         * target-debug.h (target_debug_print_thread_info_pp): New.
4503         * target-delegates.c: Regenerate.
4504         * target.c (default_thread_address_space): Delete.
4505         (memory_xfer_partial_1): Use current_inferior.
4506         (target_detach): Use current_inferior.
4507         (target_thread_address_space): Delete.
4508         (generic_mourn_inferior): Use current_inferior.
4509         * target.h (struct target_ops) <thread_address_space>: Delete.
4510         (target_thread_address_space): Delete.
4511         * thread.c (init_thread_list): Use ALL_THREADS_SAFE.  Use thread
4512         pointers directly.
4513         (delete_thread_1, delete_thread, delete_thread_silent): Take a
4514         thread pointer instead of a ptid_t.  Adjust all callers.
4515         (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
4516         (first_thread_of_process): Delete, replaced by ...
4517         (first_thread_of_inferior): ... this new function.  All callers
4518         adjusted.
4519         (any_thread_of_process): Rename to ...
4520         (any_thread_of_inferior): ... this, and take an inferior pointer.
4521         (any_live_thread_of_process): Rename to ...
4522         (any_live_thread_of_inferior): ... this, and take an inferior
4523         pointer.
4524         (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4525         (value_in_thread_stack_temporaries)
4526         (get_last_thread_stack_temporary): Take a thread pointer instead
4527         of a ptid_t.  Adjust all callers.
4528         (thread_info::set_running): New.
4529         (validate_registers_access): Use inferior_thread.
4530         (can_access_registers_ptid): Rename to ...
4531         (can_access_registers_thread): ... this, and take a thread
4532         pointer.
4533         (print_thread_info_1): Adjust to compare thread pointers instead
4534         of ptids.
4535         (switch_to_no_thread, switch_to_thread): Make extern.
4536         (scoped_restore_current_thread::~scoped_restore_current_thread):
4537         Use m_thread pointer directly.
4538         (scoped_restore_current_thread::scoped_restore_current_thread):
4539         Use inferior_thread.
4540         (thread_command): Use thread pointer directly.
4541         (thread_num_make_value_helper): Use inferior_thread.
4542         * top.c (execute_command): Use inferior_thread.
4543         * tui/tui-interp.c: Include "inferior.h".
4544         * varobj.c (varobj_create): Use inferior_thread.
4545         (value_of_root_1): Use find_thread_global_id instead of
4546         global_thread_id_to_ptid.
4547
4548 2018-06-21  Alan Hayward  <alan.hayward@arm.com>
4549
4550         * regcache.c (readable_regcache::read_part): Avoid memcpy when
4551         possible.
4552         (regcache::write_part): Likewise.
4553         (readable_regcache::cooked_read_part): Update comment.
4554         (readable_regcache::cooked_write_part): Likewise.
4555         * regcache.h: (readable_regcache::read_part): Likewise.
4556         (regcache::write_part): Likewise.
4557
4558 2018-06-21  Richard Bunt  <richard.bunt@arm.com>
4559             Dirk Schubert  <dirk.schubert@arm.com>
4560
4561         * aarch64-linux-nat.c (post_attach): New.
4562         (aarch64_linux_nat_target::post_attach): Override post_attach to
4563         record the number of hardware debug registers.
4564
4565 2018-06-20  Tom Tromey  <tom@tromey.com>
4566
4567         * python/py-param.c (add_setshow_generic): Make parameters const.
4568         (parmpy_init): Update.
4569
4570 2018-06-20  Simon Marchi  <simon.marchi@polymtl.ca>
4571
4572         * regcache.h (regcache_cooked_read_ftype): Rename to...
4573         (register_read_ftype): ...this, change type to function_view.
4574         (class reg_buffer) <save>: Remove src parameter.
4575         (readonly_detached_regcache) <readonly_detached_regcache>: Make
4576         parameter non-const in first overload.  Remove src parameter in
4577         second overload.
4578         * regcache.c (do_cooked_read): Remove.
4579         (readonly_detached_regcache::readonly_detached_regcache): Make
4580         parameter non-const, adjust call to other constructor.
4581         (reg_buffer::save): Remove src parameter.
4582         * frame.c (do_frame_register_read): Remove.
4583         (frame_save_as_regcache): Use lambda function.
4584         * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
4585         parameter to ppu2spu_data *.
4586         (ppu2spu_sniffer): Use lambda function.
4587
4588 2018-06-20  Simon Marchi  <simon.marchi@polymtl.ca>
4589
4590         * record-full.c (record_full_target::insert_breakpoint): Remove
4591         "struct" keyword, add const.
4592
4593 2018-06-19  Simon Marchi  <simon.marchi@ericsson.com>
4594
4595         * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
4596         PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
4597         * configure.ac: Remove AC_PREREQ, add missing quoting.
4598         * gnulib/configure.ac: Modernize usage of
4599         AC_INIT/AM_INIT_AUTOMAKE.  Remove AC_PREREQ.
4600         * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
4601         (AUTOMAKE_VERSION): Bump to 1.15.1.
4602         * configure: Re-generate.
4603         * config.in: Re-generate.
4604         * aclocal.m4: Re-generate.
4605         * gnulib/aclocal.m4: Re-generate.
4606         * gnulib/config.in: Re-generate.
4607         * gnulib/configure: Re-generate.
4608         * gnulib/import/Makefile.in: Re-generate.
4609
4610 2018-06-19  Pedro Alves  <palves@redhat.com>
4611
4612         * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
4613         (lookup_minimal_symbol_by_pc_section): ... here with
4614         gdb_assert_not_reached added.
4615
4616 2018-06-19  Pedro Alves  <palves@redhat.com>
4617
4618         * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
4619         parameter with a block parameter.  Compare location's block symbol
4620         with the frame's block instead of addresses.
4621         (skip_inline_frames): Pass the current block instead of the
4622         frame's address.  Break out as soon as we determine the frame
4623         should not be skipped.
4624
4625 2018-06-18  Tom Tromey  <tom@tromey.com>
4626
4627         * solib-aix.c (solib_aix_get_section_offsets): Return
4628         unique_xmalloc_ptr.
4629         (solib_aix_solib_create_inferior_hook): Update.
4630
4631 2018-06-18  Tom Tromey  <tom@tromey.com>
4632
4633         * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
4634
4635 2018-06-18  Tom Tromey  <tom@tromey.com>
4636
4637         * solib-frv.c (frv_relocate_main_executable): Use
4638         unique_xmalloc_ptr.
4639         * solib-dsbt.c (dsbt_relocate_main_executable): Use
4640         unique_xmalloc_ptr.
4641
4642 2018-06-18  Tom Tromey  <tom@tromey.com>
4643
4644         * objfiles.h (inhibit_section_map_updates): Update.
4645         (resume_section_map_updates, resume_section_map_updates_cleanup):
4646         Remove.
4647         * solib-svr4.c (svr4_handle_solib_event): Update.
4648         * objfiles.c (inhibit_section_map_updates): Return
4649         scoped_restore_tmpl<int>.
4650         (resume_section_map_updates, resume_section_map_updates_cleanup):
4651         Remove.
4652
4653 2018-06-18  Tom Tromey  <tom@tromey.com>
4654
4655         * valprint.h (read_string): Update.
4656         * valprint.c (read_string): Change type of "buffer".
4657         (val_print_string): Update.
4658         * python/py-value.c (valpy_string): Update.
4659         * language.h (struct language_defn) <la_get_string>: Change
4660         type of "buffer".
4661         (default_get_string, c_get_string): Update.
4662         * language.c (default_get_string): Change type of "buffer".
4663         * guile/scm-value.c (gdbscm_value_to_string): Update.
4664         * c-lang.c (c_get_string): Change type of "buffer".
4665
4666 2018-06-18  Tom Tromey  <tom@tromey.com>
4667
4668         * ser-mingw.c (struct pipe_state_destroyer): New.
4669         (pipe_state_up): New typedef.
4670         (cleanup_pipe_state): Remove.
4671         (pipe_windows_open): Use pipe_state_up.  Don't release argv.
4672
4673 2018-06-18  Tom Tromey  <tom@tromey.com>
4674
4675         * rust-lang.h (rust_yyerror): Don't declare.
4676         * rust-lang.c (rust_language_defn): Update.
4677         * rust-exp.y (yyerror): Now static.
4678         * parse.c (parse_exp_in_context_1): Update.
4679         * p-lang.h (p_yyerror): Don't declare.
4680         * p-lang.c (p_language_defn): Update.
4681         * p-exp.y (yyerror): Now static.
4682         * opencl-lang.c (opencl_language_defn): Update.
4683         * objc-lang.c (objc_language_defn): Update.
4684         * m2-lang.h (m2_yyerror): Don't declare.
4685         * m2-lang.c (m2_language_defn): Update.
4686         * m2-exp.y (yyerror): Now static.
4687         * language.h (struct language_defn) <la_error>: Remove.
4688         * language.c (unk_lang_error): Remove.
4689         (unknown_language_defn, auto_language_defn): Remove.
4690         * go-lang.h (go_yyerror): Don't declare.
4691         * go-lang.c (go_language_defn): Update.
4692         * go-exp.y (yyerror): Now static.
4693         * f-lang.h (f_yyerror): Don't declare.
4694         * f-lang.c (f_language_defn): Update.
4695         * f-exp.y (yyerror): Now static.
4696         * d-lang.h (d_yyerror): Don't declare.
4697         * d-lang.c (d_language_defn): Update.
4698         * d-exp.y (yyerror): Now static.
4699         * c-lang.h (c_yyerror): Don't declare.
4700         * c-lang.c (c_language_defn, cplus_language_defn)
4701         (asm_language_defn, minimal_language_defn): Update.
4702         * c-exp.y (yyerror): Now static.
4703         * ada-lang.h (ada_yyerror): Don't declare.
4704         * ada-lang.c (ada_language_defn): Update.
4705         * ada-exp.y (yyerror): Now static.
4706
4707 2018-06-18  Alan Hayward  <alan.hayward@arm.com>
4708
4709         * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
4710         (store_sveregs_to_thread): Likewise.
4711         (aarch64_linux_fetch_inferior_registers): Check for SVE.
4712         (aarch64_linux_store_inferior_registers): Likewise.
4713         * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
4714         function.
4715         (aarch64_sve_regs_copy_to_regcache): Likewise.
4716         (aarch64_sve_regs_copy_from_regcache): Likewise.
4717         * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
4718         declaration.
4719         (aarch64_sve_regs_copy_to_regcache): Likewise.
4720         (aarch64_sve_regs_copy_from_regcache): Likewise.
4721         (sve_context): Structure from Linux headers.
4722         (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
4723         (SVE_SIG_ZREG_SIZE): Likewise.
4724         (SVE_SIG_PREG_SIZE): Likewise.
4725         (SVE_SIG_FFR_SIZE): Likewise.
4726         (SVE_SIG_REGS_OFFSET): Likewise.
4727         (SVE_SIG_ZREGS_OFFSET): Likewise.
4728         (SVE_SIG_ZREG_OFFSET): Likewise.
4729         (SVE_SIG_ZREGS_SIZE): Likewise.
4730         (SVE_SIG_PREGS_OFFSET): Likewise.
4731         (SVE_SIG_PREG_OFFSET): Likewise.
4732         (SVE_SIG_PREGS_SIZE): Likewise.
4733         (SVE_SIG_FFR_OFFSET): Likewise.
4734         (SVE_SIG_REGS_SIZE): Likewise.
4735         (SVE_SIG_CONTEXT_SIZE): Likewise.
4736         (SVE_PT_REGS_MASK): Likewise.
4737         (SVE_PT_REGS_FPSIMD): Likewise.
4738         (SVE_PT_REGS_SVE): Likewise.
4739         (SVE_PT_VL_INHERIT): Likewise.
4740         (SVE_PT_VL_ONEXEC): Likewise.
4741         (SVE_PT_REGS_OFFSET): Likewise.
4742         (SVE_PT_FPSIMD_OFFSET): Likewise.
4743         (SVE_PT_FPSIMD_SIZE): Likewise.
4744         (SVE_PT_SVE_ZREG_SIZE): Likewise.
4745         (SVE_PT_SVE_PREG_SIZE): Likewise.
4746         (SVE_PT_SVE_FFR_SIZE): Likewise.
4747         (SVE_PT_SVE_FPSR_SIZE): Likewise.
4748         (SVE_PT_SVE_FPCR_SIZE): Likewise.
4749         (__SVE_SIG_TO_PT): Likewise.
4750         (SVE_PT_SVE_OFFSET): Likewise.
4751         (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
4752         (SVE_PT_SVE_ZREG_OFFSET): Likewise.
4753         (SVE_PT_SVE_ZREGS_SIZE): Likewise.
4754         (SVE_PT_SVE_PREGS_OFFSET): Likewise.
4755         (SVE_PT_SVE_PREG_OFFSET): Likewise.
4756         (SVE_PT_SVE_PREGS_SIZE): Likewise.
4757         (SVE_PT_SVE_FFR_OFFSET): Likewise.
4758         (SVE_PT_SVE_FPSR_OFFSET): Likewise.
4759         (SVE_PT_SVE_FPCR_OFFSET): Likewise.
4760         (SVE_PT_SVE_SIZE): Likewise.
4761         (SVE_PT_SIZE): Likewise.
4762         (HAS_SVE_STATE): New define.
4763
4764 2018-06-18  Alan Hayward  <alan.hayward@arm.com>
4765
4766         * nat/aarch64-sve-linux-sigcontext.h: New file.
4767         * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
4768         new files.
4769         (SVE_VQ_MIN): Likewise.
4770         (SVE_VQ_MAX): Likewise.
4771         (SVE_VL_MIN): Likewise.
4772         (SVE_VL_MAX): Likewise.
4773         (SVE_NUM_ZREGS): Likewise.
4774         (SVE_NUM_PREGS): Likewise.
4775         (sve_vl_valid): Likewise.
4776         (struct user_sve_header): Likewise.
4777
4778 2018-06-16  Andrew Burgess  <andrew.burgess@embecosm.com>
4779             Richard Bunt <Richard.Bunt@arm.com>
4780
4781         * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
4782         was requested by GDB.
4783
4784 2018-06-15  Tom de Vries  <tdevries@suse.de>
4785
4786         * MAINTAINERS (Write After Approval): Add Tom de Vries.
4787
4788 2018-06-14  Simon Marchi  <simon.marchi@polymtl.ca>
4789
4790         * gnulib/update-gnulib.sh: Print expected versions of
4791         autoconf/aclocal.
4792
4793 2018-06-14  Simon Marchi  <simon.marchi@ericsson.com>
4794
4795         * arch-utils.c (default_type_align): Use type_length_units.
4796         * gdbtypes.c (type_align): Use type_length_units.
4797
4798 2018-06-14  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
4799
4800         * cli/cli-script.c (_initialize_cli_script): Fix online documentation
4801         of 'define' command.
4802
4803 2018-06-14  Tom de Vries  <tdevries@suse.de>
4804
4805         PR cli/22573
4806         * infcmd.c (print_return_value_1): Use get_user_print_options instead of
4807         get_no_prettyformat_print_options.
4808
4809 2018-06-13  Simon Marchi  <simon.marchi@ericsson.com>
4810
4811         * sparc-nat.h: Include target.h.
4812         * sparc64-linux-nat.c (class sparc64_linux_nat_target)
4813         <fetch_registers>: Remove this argument in function call.
4814         <store_registers>: Remove this argument in function call, remove
4815         extra semicolon.
4816         <low_forget_process>: Call sparc64_forget_process instead of
4817         sparc_forget_process.
4818
4819 2018-06-13  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
4820
4821         * procfs.c (_initialize_procfs): Use add_inf_child_target.
4822         (procfs_target::make_corefile_notes): Adjust to new
4823         target_read_alloc return type.
4824
4825 2018-06-12  Andrew Burgess  <andrew.burgess@embecosm.com>
4826             Stephen Roberts  <stephen.roberts@arm.com>
4827
4828         PR gdb/22882
4829         * infrun.c (fetch_inferior_event): If GDB is not proceeding then
4830         run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
4831         Move should_notify_stop local into more inner scope.
4832
4833 2018-06-12  Andrew Burgess  <andrew.burgess@embecosm.com>
4834             Stephen Roberts  <stephen.roberts@arm.com>
4835
4836         PR gdb/22882
4837         * infrun.c (resume_1): Add call to mark_async_event_handler.
4838
4839 2018-06-12  Andrew Burgess  <andrew.burgess@embecosm.com>
4840
4841         * infrun.c (do_target_wait): Change old version of $pc printed.
4842
4843 2018-06-11  Simon Marchi  <simon.marchi@ericsson.com>
4844
4845         * dwarf2read.c (read_index_from_section): Rename to...
4846         (read_gdb_index_from_section): ... this, update all callers.
4847         (dwarf2_read_index): Rename to...
4848         (dwarf2_read_gdb_index): ... this, update all callers.
4849
4850 2018-06-11  John David Anglin  <danglin@gcc.gnu.org>
4851
4852         * gdb/hppa-linux-nat.c
4853         (hppa_linux_nat_target::fetch_inferior_registers): Rename to
4854         hppa_linux_nat_target::fetch_registers.
4855
4856 2018-06-11  Alan Hayward  <alan.hayward@arm.com>
4857
4858         * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
4859         * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
4860         (AARCH64_DWARF_SVE_FFR): Likewise.
4861         (AARCH64_DWARF_SVE_P0): Likewise.
4862         (AARCH64_DWARF_SVE_Z0): Likewise.
4863
4864 2018-06-11  Alan Hayward  <alan.hayward@arm.com>
4865
4866         * common/common-regcache.h (raw_compare): New function.
4867         * regcache.c (regcache::raw_compare): Likewise.
4868         * regcache.h (regcache::raw_compare): New declaration.
4869
4870 2018-06-11  Alan Hayward  <alan.hayward@arm.com>
4871
4872         * common/common-regcache.h (reg_buffer_common): New structure.
4873         * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
4874         (reg_buffer::raw_supply): Likewise.
4875         (reg_buffer::raw_supply_integer): Likewise.
4876         (reg_buffer::raw_supply_zeroed): Likewise.
4877         (reg_buffer::raw_collect): Likewise.
4878         (reg_buffer::raw_collect_integer): Likewise.
4879         * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
4880         (reg_buffer::raw_supply): Likewise.
4881         (reg_buffer::raw_supply_integer): Likewise.
4882         (reg_buffer::raw_supply_zeroed): Likewise.
4883         (reg_buffer::raw_collect): Likewise.
4884         (reg_buffer::raw_collect_integer): Likewise.
4885
4886 2018-06-10  Tom Tromey  <tom@tromey.com>
4887
4888         * remote.c (stop_reply_p): Remove typedef.  Don't declare queue.
4889         (class remote_state) <stop_reply_queue>: Now std::vector.
4890         (remote_state::~remote_state)
4891         (remote_target::stop_reply_queue_length): Update.
4892         (struct queue_iter_param, remove_child_of_pending_fork)
4893         (struct check_pending_event_prevents_wildcard_vcont_callback_data)
4894         (check_pending_event_prevents_wildcard_vcont_callback)
4895         (remove_stop_reply_for_inferior)
4896         (remove_stop_reply_of_remote_state)
4897         (remote_notif_remove_once_on_match)
4898         (stop_reply_match_ptid_and_ws)
4899         (remote_kill_child_of_pending_fork): Remove.
4900         (remote_target::remove_new_fork_children)
4901         (remote_target::check_pending_events_prevent_wildcard_vcont)
4902         (remote_target::discard_pending_stop_replies)
4903         (remote_target::discard_pending_stop_replies_in_queue)
4904         (remote_target::remote_notif_remove_queued_reply)
4905         (remote_target::queued_stop_reply)
4906         (remote_target::push_stop_reply, remote_target::peek_stop_reply)
4907         (remote_target::wait, remote_target::kill_new_fork_children)
4908         (remote_target::async): Update.
4909
4910 2018-06-10  Tom Tromey  <tom@tromey.com>
4911
4912         * record-full.c (record_full_arch_list_cleanups): Remove.
4913         (record_full_message): Use try/catch.
4914         (record_full_wait_cleanups): Remove.
4915         (record_full_wait_1): Use try/catch.
4916         (record_full_restore): Likewise.
4917
4918 2018-06-10  Tom Tromey  <tom@tromey.com>
4919
4920         * record-full.c (record_full_breakpoint_p): Remove typedef.  Don't
4921         declare VEC.  Add constructor.
4922         <in_target_beneath>: Now bool.
4923         (record_full_breakpoints): Now a std::vector, static.
4924         (record_full_sync_record_breakpoints)
4925         (record_full_init_record_breakpoints)
4926         (record_full_target::insert_breakpoint)
4927         (record_full_target::remove_breakpoint): Update.  Don't use XNEW.
4928
4929 2018-06-10  Simon Marchi  <simon.marchi@polymtl.ca>
4930
4931         * dwarf2read.c (process_cu_includes): Remove struct keyword.
4932         * serial.c (serial_interface_lookup): Remove struct keyword.
4933
4934 2018-06-10  Tom Tromey  <tom@tromey.com>
4935
4936         * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
4937         method.
4938         * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
4939         a method.
4940         * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
4941         method.
4942         * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
4943         "beneath" as a method.
4944         * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
4945         Use "beneath" as a method.
4946
4947 2018-06-10  Tom Tromey  <tom@tromey.com>
4948
4949         * tracefile.c (struct trace_file_writer_deleter): New.
4950         <operator()>: Rename from trace_file_writer_xfree.
4951         (trace_file_writer_up): New typedef.
4952         (tsave_command, trace_save_tfile, trace_save_ctf): Update.
4953
4954 2018-06-09  Simon Marchi  <simon.marchi@ericsson.com>
4955
4956         * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
4957         <m_registers, m_register_status>: Change type to
4958         std::unique_ptr.
4959         * regcache.c (reg_buffer::reg_buffer): Use new instead of
4960         XCNEWVEC.
4961
4962 2018-06-09  Simon Marchi  <simon.marchi@ericsson.com>
4963
4964         * common/common-regcache.h (enum register_status): Add
4965         underlying type "signed char".
4966         * regcache.h (reg_buffer) <m_register_status>: Change type to
4967         register_status *.
4968         * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
4969         register_status instead of signed char.
4970         (reg_buffer::save): Use REG_UNKNOWN instead of 0.
4971         (reg_buffer::get_register_status): Remove cast.
4972         (readable_regcache::raw_read): Remove cast.
4973         (readable_regcache::cooked_read): Remove cast.
4974
4975 2018-06-09  Tom Tromey  <tom@tromey.com>
4976
4977         * source.c (reverse_search_command, forward_search_command): Use
4978         scoped_fd.
4979
4980 2018-06-09  Tom Tromey  <tom@tromey.com>
4981
4982         * serial.c (serial_ops_p): Remove typedef.  Don't declare VEC.
4983         (serial_ops_list): Now static, std::vector.
4984         (serial_interface_lookup, serial_add_interface): Update.
4985
4986 2018-06-09  Tom Tromey  <tom@tromey.com>
4987
4988         * dwarf2read.c (process_cu_includes): Update.
4989         (process_full_comp_unit): Update.
4990         * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
4991         std::vector.
4992
4993 2018-06-08  Paul Koning  <paul_koning@dell.com>
4994
4995         PR gdb/23252
4996
4997         * python/python.c (do_start_initialization):
4998         Avoid call to internal Python API.
4999         (init__gdb_module): New function.
5000
5001 2018-06-08  Gary Benson <gbenson@redhat.com>
5002
5003         * linux-thread-db.c (valprint.h): New include.
5004         (struct check_thread_db_info): New structure.
5005         (check_thread_db_on_load, tdb_testinfo): New static globals.
5006         (check_thread_db, check_thread_db_callback): New functions.
5007         (try_thread_db_load_1): Run integrity checks if requested.
5008         (maintenance_check_libthread_db): New function.
5009         (_initialize_thread_db): Register "maint check libthread-db"
5010         and "maint set/show check-libthread-db".
5011         * NEWS: Mention the above new commands.
5012
5013 2018-06-08  Tom Tromey  <tom@tromey.com>
5014
5015         * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
5016         now a method.
5017
5018 2018-06-08  Tom Tromey  <tom@tromey.com>
5019
5020         * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
5021
5022 2018-06-08  Tom Tromey  <tom@tromey.com>
5023
5024         * common/btrace-common.h (struct btrace_data): Add constructor,
5025         destructor, move assignment operator.
5026         <empty, clear, fini>: New methods.
5027         <format>: Initialize.
5028         (btrace_data_init, btrace_data_fini, btrace_data_clear)
5029         (btrace_data_empty): Don't declare.
5030         * common/btrace-common.c (btrace_data_init): Remove.
5031         (btrace_data::fini): Rename from btrace_data_fini.
5032         (btrace_data::empty): Rename from btrace_data_empty.
5033         (btrace_data::clear): Rename from btrace_data_clear.  Return
5034         bool.
5035         * btrace.h (make_cleanup_btrace_data): Don't declare.
5036         * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
5037         (parse_xml_btrace): Update.
5038         (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
5039         (maint_btrace_clear_packet_history_cmd): Update.
5040
5041 2018-06-07  Pedro Alves  <palves@redhat.com>
5042
5043         * target.h (target_ops) <beneath>: Now a method.  All references
5044         updated.
5045         (class target_stack): New.
5046         * target.c (g_target_stack): New.
5047         (g_current_top_target): Delete.
5048         (current_top_target): Get the top target out of g_target_stack.
5049         (target_stack::push, target_stack::unpush): New.
5050         (push_target, unpush_target): Reimplement.
5051         (target_is_pushed): Reimplement in terms of g_target_stack.
5052         (target_ops::beneath, target_stack::find_beneath): New.
5053
5054 2018-06-07  Pedro Alves  <palves@redhat.com>
5055
5056         * target.h (find_target_beneath): Delete declaration.
5057         * target.c (find_target_beneath): Delete definition.
5058         * aix-thread.c: All callers of find_target_beneath adjusted to
5059         call target_ops::beneath instead.
5060         * bsd-uthread.c: Likewise.
5061         * linux-thread-db.c: Likewise.
5062         * ravenscar-thread.c: Likewise.
5063         * sol-thread.c: Likewise.
5064         * spu-multiarch.c: Likewise.
5065
5066 2018-06-07  Pedro Alves  <palves@redhat.com>
5067
5068         * target.h (target_ops) <beneath>: Now a method.  All references
5069         updated.
5070         (target_ops) <m_beneath>: New.
5071         * target.c (target_ops::beneath): New.
5072         * corelow.c: Adjust all references to target_ops::beneath.
5073         * linux-thread-db.c: Likewise.
5074         * make-target-delegates: Likewise.
5075         * record-btrace.c: Likewise.
5076         * record-full.c: Likewise.
5077         * remote.c: Likewise.
5078         * target.c: Likewise.
5079         * target-delegates.c: Regenerate.
5080
5081 2018-06-07  Pedro Alves  <palves@redhat.com>
5082
5083         * target.h (target_stack): Delete.
5084         (current_top_target): Declare function.
5085         * target.c (target_stack): Delete.
5086         (g_current_top_target): New.
5087         (current_top_target): New function.
5088         * auxv.c: Use current_top_target instead of target_stack
5089         throughout.
5090         * avr-tdep.c: Likewise.
5091         * breakpoint.c: Likewise.
5092         * corefile.c: Likewise.
5093         * elfread.c: Likewise.
5094         * eval.c: Likewise.
5095         * exceptions.c: Likewise.
5096         * frame.c: Likewise.
5097         * gdbarch-selftests.c: Likewise.
5098         * gnu-v3-abi.c: Likewise.
5099         * ia64-tdep.c: Likewise.
5100         * ia64-vms-tdep.c: Likewise.
5101         * infcall.c: Likewise.
5102         * infcmd.c: Likewise.
5103         * infrun.c: Likewise.
5104         * linespec.c: Likewise.
5105         * linux-tdep.c: Likewise.
5106         * minsyms.c: Likewise.
5107         * ppc-linux-nat.c: Likewise.
5108         * ppc-linux-tdep.c: Likewise.
5109         * procfs.c: Likewise.
5110         * regcache.c: Likewise.
5111         * remote.c: Likewise.
5112         * rs6000-tdep.c: Likewise.
5113         * s390-linux-nat.c: Likewise.
5114         * s390-tdep.c: Likewise.
5115         * solib-aix.c: Likewise.
5116         * solib-darwin.c: Likewise.
5117         * solib-dsbt.c: Likewise.
5118         * solib-spu.c: Likewise.
5119         * solib-svr4.c: Likewise.
5120         * solib-target.c: Likewise.
5121         * sparc-tdep.c: Likewise.
5122         * sparc64-tdep.c: Likewise.
5123         * spu-tdep.c: Likewise.
5124         * symfile.c: Likewise.
5125         * symtab.c: Likewise.
5126         * target-descriptions.c: Likewise.
5127         * target-memory.c: Likewise.
5128         * target.c: Likewise.
5129         * target.h: Likewise.
5130         * tracefile-tfile.c: Likewise.
5131         * tracepoint.c: Likewise.
5132         * valops.c: Likewise.
5133         * valprint.c: Likewise.
5134         * value.c: Likewise.
5135         * windows-tdep.c: Likewise.
5136         * mi/mi-main.c: Likewise.
5137
5138 2018-06-07  Tom Tromey  <tom@tromey.com>
5139
5140         * valprint.h (build_address_symbolic): Declare.
5141         * printcmd.c (print_address_symbolic): Update.
5142         (build_address_symbolic): Change "name" and "filename" to
5143         std::string.
5144         * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
5145         Update.
5146         * defs.h (build_address_symbolic): Remove declaration.
5147
5148 2018-06-07  Alan Hayward  <alan.hayward@arm.com>
5149
5150         * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
5151         (aarch64_vnv_type): Add function.
5152         (aarch64_pseudo_register_name): Add V regs for SVE.
5153         (aarch64_pseudo_register_type): Likewise.
5154         (aarch64_pseudo_register_reggroup_p): Likewise.
5155         (aarch64_pseudo_read_value_2): Use V0 offset for SVE
5156         (aarch64_pseudo_read_value): Add V regs for SVE.
5157         (aarch64_pseudo_write_2): Use V0 offset for SVE
5158         (aarch64_pseudo_write): Add V regs for SVE.
5159         * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
5160
5161 2018-06-06  Sergio Durigan Junior  <sergiodj@redhat.com>
5162
5163         * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
5164         (sve_vl_from_vq): Likewise.
5165
5166 2018-06-05  Tom Tromey  <tom@tromey.com>
5167
5168         * cli/cli-cmds.c (show_version): Update.
5169         * top.c (print_gdb_version): Add "interactive" parameter.
5170         Update.
5171         * main.c (captured_main_1): Update.
5172         * top.h (print_gdb_version): Add "interactive" parameter and a
5173         comment.
5174
5175 2018-06-05  David Malcolm  <dmalcolm@redhat.com>
5176
5177         * common/enum-flags.h: Add trailing semicolon to example in
5178         comment.
5179
5180 2018-06-05  Tom Tromey  <tom@tromey.com>
5181
5182         PR cli/12326:
5183         * NEWS: Add entry about pager.
5184         * utils.c (pagination_disabled_for_command): New global.
5185         (prompt_for_continue): Allow "c" response to prompt.
5186         (reinitialize_more_filter): Clear
5187         pagination_disabled_for_command.
5188         (fputs_maybe_filtered): Check pagination_disabled_for_command.
5189
5190 2018-06-04  Tom Tromey  <tom@tromey.com>
5191
5192         * ada-lang.h (ada_lookup_symbol_list): Update.
5193         * ada-lang.c (resolve_subexp): Update.
5194         (symbols_are_identical_enums): Change type of syms.  Remove nsyms
5195         parameter.
5196         (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
5197         (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
5198         results parameter to std::vector.
5199         (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
5200         Update.
5201         * ada-exp.y (block_lookup): Update.
5202         (select_possible_type_sym): Change type of syms.  Remove nsyms
5203         parameter.
5204         (write_var_or_type, write_name_assoc): Update.
5205
5206 2018-06-04  Joel Brobecker  <brobecker@adacore.com>
5207
5208         * windows-nat.c (windows_nat_target::xfer_partial): Return
5209         TARGET_XFER_E_IO if we need to delegate to the target beneath
5210         but BENEATH is NULL.
5211
5212 2018-06-04  Simon Marchi  <simon.marchi@ericsson.com>
5213
5214         * Makefile.in (config.status): Add configure.nat as a
5215         dependency.
5216
5217 2018-06-04  Tom Tromey  <tom@tromey.com>
5218
5219         * cp-name-parser.y (cpname_state): Add method declarations.
5220         (HANDLE_QUAL): Update.
5221         (cpname_state::d_grab, cpname_state::fill_comp)
5222         (cpname_state::make_operator, cpname_state::make_dtor)
5223         (cpname_state::make_builtin_type, cpname_state::make_name)
5224         (cpname_state::d_qualify, cpname_state::d_int_type)
5225         (cpname_state::d_unary, cpname_state::d_binary): Now methods.
5226         (%union): Move earlier.
5227
5228 2018-06-04  Alan Hayward  <alan.hayward@arm.com>
5229
5230         * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
5231
5232 2018-06-04  Alan Hayward  <alan.hayward@arm.com>
5233
5234         * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
5235         (aarch64_pseudo_write_1): Likewise.
5236         (aarch64_pseudo_read_value): Use helper.
5237         (aarch64_pseudo_write): Likewise.
5238
5239 2018-06-04  Pedro Alves  <palves@redhat.com>
5240
5241         * darwin-nat.c (darwin_ops): Delete.
5242         (darwin_attach_pid): Use get_native_target.
5243
5244 2018-06-04  Alan Hayward  <alan.hayward@arm.com>
5245
5246         * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
5247         * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
5248
5249 2018-06-04  Alan Hayward  <alan.hayward@arm.com>
5250
5251         * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
5252         * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
5253         (aarch64_gdbarch_init): Check for SVE.
5254         * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
5255
5256 2018-06-04  Alan Hayward  <alan.hayward@arm.com>
5257
5258         * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
5259         * aarch64-tdep.h (aarch64_read_description): Likewise.
5260         * arch/aarch64.c (aarch64_create_target_description): Likewise.
5261         * arch/aarch64.h (aarch64_create_target_description): Likewise.
5262         * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
5263         * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
5264         * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
5265
5266 2018-06-02  Simon Marchi  <simon.marchi@ericsson.com>
5267
5268         * value.c (value_fetch_lazy_bitfield): New.
5269         (value_fetch_lazy_memory): New.
5270         (value_fetch_lazy_register): New.
5271         (value_fetch_lazy): Factor out to smaller functions.
5272
5273 2018-06-01  Tom Tromey  <tom@tromey.com>
5274
5275         * cp-name-parser.y (backslashable, represented): Now const.
5276
5277 2018-06-01  Tom Tromey  <tom@tromey.com>
5278
5279         * cp-name-parser.y: Include parser-defs.h.
5280         (parser_fprintf): Remove declaration.
5281
5282 2018-06-01  Tom Tromey  <tom@tromey.com>
5283
5284         * cp-name-parser.y: Use %pure-parser, %lex-param, and
5285         %parse-param.
5286         (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
5287         (global_result): Remove globals.
5288         (struct cpname_state): New.
5289         (yyparse): Don't declare.
5290         (yylex, yyerror): Move declarations after %union.
5291         (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
5292         (make_name): Add state parameter.
5293         Update all callers.
5294         (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
5295         parameter.
5296         (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
5297         Update.
5298         (yylex): Add lvalp, state parameters.
5299         (yyerror): Add state parameter.
5300         (cp_demangled_name_to_comp): Update.
5301
5302 2018-06-01  Tom Tromey  <tom@tromey.com>
5303
5304         * cp-name-parser.y (parser_fprintf): Declare.
5305         (GDB_YY_REMAP_PREFIX): Define.
5306         Include yy-remap.h.  Don't redefine yy* identifiers.
5307
5308 2018-06-01  Tom Tromey  <tom@tromey.com>
5309
5310         * python/py-type.c (typy_legacy_template_argument): Update.
5311         * cp-support.h (cp_demangled_name_to_comp): Update.
5312         * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
5313         parameter to be a "std::string *".
5314         (main): Update.
5315
5316 2018-06-01  H.J. Lu  <hongjiu.lu@intel.com>
5317
5318         * ada-lex.l: Include "diagnostics.h" instead of
5319         "common/diagnostics.h".
5320         * unittests/environ-selftests.c: Likewise.
5321         * common/diagnostics.h: Moved to ../include.
5322
5323 2018-06-01  Joel Brobecker  <brobecker@adacore.com>
5324
5325         * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
5326         to language_mode_manual while calling breakpoint_re_set_one.
5327
5328 2018-06-01  Tom Tromey  <tom@tromey.com>
5329
5330         * valops.c (value_cast_structs, destructor_name_p): Update.
5331         * symtab.c (gdb_mangle_name): Update.
5332         * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
5333         Update.
5334         * p-valprint.c (pascal_object_is_vtbl_ptr_type)
5335         (pascal_object_print_value_fields, pascal_object_print_value):
5336         Update.
5337         * p-typeprint.c (pascal_type_print_derivation_info): Update.
5338         * linespec.c (find_methods): Update.
5339         * gdbtypes.h (type_name_no_tag): Remove.
5340         (type_name_or_error): Rename from type_name_no_tag_or_error.
5341         * gdbtypes.c (type_name_no_tag): Remove.
5342         (type_name_or_error): Rename from type_name_no_tag_or_error.
5343         (lookup_struct_elt_type, check_typedef): Update.
5344         * expprint.c (print_subexp_standard): Update.
5345         * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
5346         * d-namespace.c (d_lookup_nested_symbol): Update.
5347         * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
5348         (cp_print_class_member): Update.
5349         * cp-namespace.c (cp_lookup_nested_symbol): Update.
5350         * completer.c (add_struct_fields): Update.
5351         * c-typeprint.c (cp_type_print_derivation_info)
5352         (c_type_print_varspec_prefix, c_type_print_base_struct_union):
5353         Update.
5354         * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
5355         (ada_prefer_type, ada_is_exception_sym): Update.
5356
5357 2018-06-01  Tom Tromey  <tom@tromey.com>
5358
5359         * valops.c (enum_constant_from_type, value_namespace_elt)
5360         (value_maybe_namespace_elt): Update.
5361         * valarith.c (find_size_for_pointer_math): Update.
5362         * target-descriptions.c (make_gdb_type): Update.
5363         * symmisc.c (print_symbol): Update.
5364         * stabsread.c (define_symbol, read_type)
5365         (complain_about_struct_wipeout, add_undefined_type)
5366         (cleanup_undefined_types_1): Update.
5367         * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
5368         (rust_range_type_p, val_print_struct, rust_print_struct_def)
5369         (rust_internal_print_type, rust_composite_type)
5370         (rust_evaluate_funcall, rust_evaluate_subexp)
5371         (rust_inclusive_range_type_p): Update.
5372         * python/py-type.c (typy_get_tag): Update.
5373         * p-typeprint.c (pascal_type_print_base): Update.
5374         * mdebugread.c (parse_symbol, parse_type): Update.
5375         * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
5376         Update.
5377         * guile/scm-type.c (gdbscm_type_tag): Update.
5378         * go-lang.c (sixg_string_p): Update.
5379         * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
5380         Update.
5381         * gdbtypes.h (struct main_type) <tag_name>: Remove.
5382         (TYPE_TAG_NAME): Remove.
5383         * gdbtypes.c (type_name_no_tag): Simplify.
5384         (check_typedef, check_types_equal, recursive_dump_type)
5385         (copy_type_recursive, arch_composite_type): Update.
5386         * f-typeprint.c (f_type_print_base): Update.  Print "Type" prefix
5387         in summary mode when needed.
5388         * eval.c (evaluate_funcall): Update.
5389         * dwarf2read.c (fixup_go_packaging, read_structure_type)
5390         (process_structure_scope, read_enumeration_type)
5391         (read_namespace_type, read_module_type, determine_prefix): Update.
5392         * cp-support.c (inspect_type): Update.
5393         * coffread.c (process_coff_symbol, decode_base_type): Update.
5394         * c-varobj.c (c_is_path_expr_parent): Update.
5395         * c-typeprint.c (c_type_print_base_struct_union): Update.
5396         (c_type_print_base_1): Update.  Print struct/class/union/enum in
5397         summary when using C language.
5398         * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
5399         (gen_maybe_namespace_elt): Update.
5400         * ada-lang.c (ada_type_name): Simplify.
5401         (empty_record, ada_template_to_fixed_record_type_1)
5402         (template_to_static_fixed_type)
5403         (to_record_with_fixed_variant_part, ada_check_typedef): Update.
5404
5405 2018-06-01  Tom Tromey  <tom@tromey.com>
5406
5407         * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
5408         c_print_type.
5409         * c-typeprint.c (c_print_type_1): Add "language" parameter.
5410         (c_print_type): Update.
5411         (c_print_type): New overload.
5412         (c_type_print_varspec_prefix, c_type_print_args)
5413         (c_type_print_varspec_suffix, c_print_type_no_offsets)
5414         (c_type_print_base_struct_union, c_type_print_base_1)
5415         (cp_type_print_method_args): Add "language" parameter.
5416         (c_type_print_base): Update.
5417         * c-lang.h (c_print_type): Add new overload.
5418
5419 2018-06-01  Tom Tromey  <tom@tromey.com>
5420
5421         * typeprint.h (c_type_print_varspec_suffix): Don't declare.
5422         * c-typeprint.c (c_type_print_varspec_suffix): Now static.
5423
5424 2018-06-01  Alan Hayward  <alan.hayward@arm.com>
5425
5426         * aarch64-tdep.c (aarch64_sve_register_names): New const
5427         var.
5428         * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
5429         (AARCH64_SVE_Z_REGS_NUM): New define.
5430         (AARCH64_SVE_P_REGS_NUM): Likewise.
5431         (AARCH64_SVE_NUM_REGS): Likewise.
5432
5433 2018-05-31  Uros Bizjak  <ubizjak@gmail.com>
5434
5435         * nat/linux-ptrace.h [__alpha__]
5436         (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
5437         definitions.
5438
5439 2018-05-31  Maciej W. Rozycki  <macro@mips.com>
5440
5441         * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
5442         the endianness selected.
5443         * NEWS: Document `set endian auto' mode operation update.
5444
5445 2018-05-31  Alan Hayward  <alan.hayward@arm.com>
5446
5447         * Makefile.in: Add new header.
5448         * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
5449         (sve_vl_from_vg): Likewise.
5450         (sve_vq_from_vl): Likewise.
5451         (sve_vl_from_vq): Likewise.
5452         (sve_vq_from_vg): Likewise.
5453         (sve_vg_from_vq): Likewise.
5454         * configure.nat: Add new c file.
5455         * nat/aarch64-sve-linux-ptrace.c: New file.
5456         * nat/aarch64-sve-linux-ptrace.h: New file.
5457
5458 2018-05-31  Alan Hayward  <alan.hayward@arm.com>
5459
5460         * aarch64-linux-nat.c (aarch64_linux_read_description):
5461         Add parmeter zero.
5462         * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
5463         Likewise.
5464         * aarch64-tdep.c (tdesc_aarch64_list): Add.
5465         (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
5466         (aarch64_gdbarch_init): Add parmeter zero.
5467         * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
5468         * arch/aarch64.c (aarch64_create_target_description): Check VQ.
5469         * arch/aarch64.h (aarch64_create_target_description): Add VQ.
5470         parmeter.
5471         * doc/gdb.texinfo: Describe SVE feature
5472         * features/aarch64-sve.c: New file.
5473
5474 2018-05-31  Omair Javaid  <omair.javaid@linaro.org>
5475
5476         PR gdb/23210
5477         * gdbarch.sh (significant_addr_bit): Default to zero when
5478         not set by target architecture.
5479         * gdbarch.c: Re-generated.
5480         * utils.c (address_significant): Update.
5481
5482 2018-05-30  Joel Brobecker  <brobecker@adacore.com>
5483
5484         * stack.c (func_command): Remove trailing newline in call to error.
5485
5486 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5487
5488         * regcache.h (regcache_raw_collect): Remove, update callers to
5489         use regcache::raw_collect.
5490         * regcache.c (regcache_raw_collect): Remove.
5491
5492 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5493
5494         * regcache.h (regcache_raw_supply): Remove, update callers to
5495         use detached_regcache::raw_supply.
5496         * regcache.c (regcache_raw_supply): Remove.
5497
5498 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5499
5500         * regcache.h (regcache_cooked_write_part): Remove, update
5501         callers to use regcache::cooked_write_part.
5502         * regcache.c (regcache_cooked_write_part): Remove.
5503
5504 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5505
5506         * regcache.h (regcache_cooked_read_part): Remove, update callers
5507         to use readable_regcache::cooked_read_part.
5508         * regcache.c (regcache_cooked_read_part): Remove.
5509
5510 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5511
5512         * regcache.h (regcache_cooked_read_value): Remove, update
5513         callers to use readable_regcache::cooked_read_value.
5514         * regcache.c (regcache_cooked_read_value): Remove.
5515
5516 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5517
5518         * regcache.h (regcache_cooked_write): Remove, update callers to
5519         use regcache::cooked_write.
5520         * regcache.c (regcache_cooked_write): Remove.
5521
5522 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5523
5524         * regcache.h (regcache_invalidate): Remove, update callers to
5525         use detached_regcache::invalidate instead.
5526         * regcache.c (regcache_invalidate): Remove.
5527
5528 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5529
5530         * regcache.h (regcache_raw_write_part): Remove, update callers
5531         to use regcache::raw_write_part instead.
5532         * regcache.c (regcache_raw_write_part): Remove.
5533
5534 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5535
5536         * regcache.h (regcache_raw_read_part): Remove, update callers to
5537         use readable_regcache::raw_read_part instead.
5538         * regcache.c (regcache_raw_read_part): Remove.
5539
5540 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5541
5542         * regcache.h (regcache_cooked_read): Remove, update callers to
5543         use readable_regcache::cooked_read instead.
5544         * regcache.c (regcache_cooked_read): Remove.
5545
5546 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5547
5548         * regcache.h (regcache_raw_write): Remove, update callers to use
5549         regcache::raw_write instead.
5550         * regcache.c (regcache_raw_write): Remove.
5551
5552 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5553
5554         * regcache.h (regcache_raw_read): Remove, update callers to use
5555         readable_regcache::raw_read instead.
5556         * regcache.c (regcache_raw_read): Remove.
5557
5558 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5559
5560         * regcache.h (regcache_raw_update): Remove, update callers to
5561         use readable_regcache::raw_update instead.
5562         * regcache.c (regcache_raw_update): Remove.
5563
5564 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5565
5566         * regcache.h (regcache_register_status): Remove, update callers
5567         to use reg_buffer::get_register_status directly instead.
5568         * regcache.c (regcache_register_status): Remove.
5569
5570 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5571
5572         * regcache.h (regcache_get_ptid): Remove, update all callers to
5573         call regcache::ptid instead.
5574         * regcache.c (regcache_get_ptid): Remove.
5575
5576 2018-05-30  Simon Marchi  <simon.marchi@ericsson.com>
5577
5578         * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
5579
5580 2018-05-30  Pedro Alves  <palves@redhat.com>
5581
5582         * common/common-exceptions.h (exception_rethrow): Use
5583         ATTRIBUTE_NORETURN.
5584
5585 2018-05-29  Simon Marchi  <simon.marchi@polymtl.ca>
5586
5587         * breakpoint.c (print_solib_event, check_status_catch_solib):
5588         Remove struct keyword in range-based for loops.
5589         * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
5590         * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
5591         Likewise.
5592         * linespec.c (find_superclass_methods, search_minsyms_for_name):
5593         Likewise.
5594         * symfile.c (addr_info_make_relative): Likewise.
5595         * thread.c (value_in_thread_stack_temporaries): Likewise.
5596
5597 2018-06-12  Weimin Pan  <weimin.pan@oracle.com>
5598
5599         PR gdb/16841
5600         * valops.c (value_struct_elt_for_reference): Call check_typedef on
5601         aggregate type to get its real type before accessing it.
5602
5603 2018-05-29  Weimin Pan  <weimin.pan@oracle.com>
5604
5605         * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
5606         * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
5607         * coff-pe-read.c (add_pe_forwarded_sym): Replace
5608         lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
5609         * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
5610         * jit.c (jit_breakpoint_re_set_internal): Likewise.
5611         * printcmd.c (info_address_command): Likewise.
5612
5613 2018-05-29  Tom Tromey  <tom@tromey.com>
5614
5615         * windows-nat.c (handle_exception): Update fall-through comment.
5616
5617 2018-05-29  Tom Tromey  <tom@tromey.com>
5618
5619         * progspace.h (so_list_ptr): Remove typedef.  Don't declare VEC.
5620         (struct program_space) <added_solibs>: Now a std::vector.
5621         * breakpoint.c (print_solib_event): Update.
5622         (check_status_catch_solib): Update.
5623         * progspace.c (clear_program_space_solib_cache): Update.
5624         * solib.c (update_solib_list): Update.
5625
5626 2018-05-29  Tom Tromey  <tom@tromey.com>
5627
5628         * python/py-type.c (typy_richcompare): Update.
5629         * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
5630         * gdbtypes.h (types_deeply_equal): Return bool.
5631         (types_equal): Likewise.
5632         * gdbtypes.c (type_equality_entry_d): Remove typedef.  Don't
5633         declare VEC.
5634         (check_types_equal): Change worklist to std::vector.  Return
5635         bool.
5636         (struct type_equality_entry): Add constructor.
5637         (compare_maybe_null_strings): Return bool.
5638         (check_types_worklist): Return bool.  Change worklist to
5639         std::vector.
5640         (types_deeply_equal): Use std::vector.
5641         (types_equal): Return bool.
5642         (compare_maybe_null_strings): Simplify.
5643
5644 2018-05-29  Tom Tromey  <tom@tromey.com>
5645
5646         * record-btrace.c (tp_t): Remove typedef.  Don't declare VEC.
5647
5648 2018-05-29  Tom Tromey  <tom@tromey.com>
5649
5650         * objc-lang.h: Don't include cp-support.h.
5651         * common/gdb_vecs.h (const_char_ptr): Remove typedef.  Don't
5652         declare VEC.
5653
5654 2018-05-27  Tom Tromey  <tom@tromey.com>
5655
5656         * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
5657
5658 2018-05-25  Tom Tromey  <tom@tromey.com>
5659
5660         * value.c (value::location): Initialize.
5661
5662 2018-05-25  Tom Tromey  <tom@tromey.com>
5663
5664         * dbxread.c (init_bincl_list): Remove.
5665         (bincl_list): Now a std::vector.
5666         (bincls_allocated, next_bincl): Remove.
5667         (free_bincl_list, do_free_bincl_list_cleanup)
5668         (make_cleanup_free_bincl_list): Remove.
5669         (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
5670         unique_xmalloc_ptr.
5671         (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
5672         (struct header_file_location): Add constructor.
5673         (add_bincl_to_list): Remove.
5674
5675 2018-05-25  Tom Tromey  <tom@tromey.com>
5676
5677         * tui/tui.c (tui_enable): Update.
5678         * mi/mi-interp.c (mi_interp::init): Update.
5679         * interps.h (class interp) <name>: New method.
5680         <m_name>: Rename from name.
5681         (~scoped_restore_interp): Update.
5682         * interps.c (interp::interp): Update.
5683         (interp_add, interp_set, interp_lookup_existing)
5684         (current_interp_named_p): Update.
5685
5686 2018-05-25  Tom Tromey  <tom@tromey.com>
5687
5688         * interps.c (interp_name): Remove.
5689         * mi/mi-interp.c (mi_interp::init): Update.
5690         * interps.h (interp_name): Remove.
5691         (~scoped_restore_interp): Update.
5692         * tui/tui.c (tui_enable): Update.
5693
5694 2018-05-25  Tom Tromey  <tom@tromey.com>
5695
5696         * utils.c (fputs_maybe_filtered): Update.
5697         * linespec.c (decode_line_full): Update.
5698         * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
5699         (mi_print_breakpoint_for_event, mi_solib_loaded)
5700         (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
5701         (mi_user_selected_context_changed): Update.
5702         * mi/mi-main.c (mi_execute_command): Update.
5703         * cli/cli-script.c (execute_control_command): Update.
5704         * python/python.c (execute_gdb_command): Update.
5705         * solib.c (info_sharedlibrary_command): Update.
5706         * interps.c (interp_ui_out): Remove.
5707         * interps.h (interp_ui_out): Remove.
5708
5709 2018-05-25  Tom Tromey  <tom@tromey.com>
5710
5711         * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
5712         * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
5713         * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
5714
5715 2018-05-25  Tom Tromey  <tom@tromey.com>
5716
5717         * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
5718         * interps.c (interp_exec): Use scoped_restore.
5719
5720 2018-05-25  Tom Tromey  <tom@tromey.com>
5721
5722         * remote.c (remote_target::remote_file_get): Use
5723         gdb::byte_vector.
5724         (remote_target::remote_file_put): Likewise.
5725
5726 2018-05-25  Tom Tromey  <tom@tromey.com>
5727
5728         * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
5729         a std::string.
5730         (get_pe_section_index, add_pe_exported_sym): Update.
5731         (read_pe_exported_syms): Use gdb::def_vector.
5732
5733 2018-05-25  Tom Tromey  <tom@tromey.com>
5734
5735         * frame.c (remove_prev_frame): Remove.
5736         (get_prev_frame_if_no_cycle): Use TRY/CATCH.
5737
5738 2018-05-25  Maciej W. Rozycki  <macro@mips.com>
5739
5740         * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
5741         Remove prototypes.
5742         * mips-linux-nat.c (supply_fpregset): Always call
5743         `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
5744         (fill_fpregset): Always call `mips64_fill_fpregset' rather than
5745         `mips_fill_fpregset'.
5746         * mips-linux-tdep.c (mips_supply_fpregset)
5747         (mips_supply_fpregset_wrapper, mips_fill_fpregset)
5748         (mips_fill_fpregset_wrapper): Remove functions.
5749         (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
5750         (mips_linux_fpregset): Remove variable.
5751         (mips_linux_iterate_over_regset_sections): Use
5752         `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
5753         (mips_linux_o32_sigframe_init): Remove comment.
5754
5755 2018-05-25  Pedro Alves  <palves@redhat.com>
5756
5757         * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
5758         (struct readahead_cache, struct packet_reg, struct
5759         remote_arch_state, class remote_state): Move higher up in the
5760         file.
5761         (remote_target::m_remote_state): Now an object instead of a pointer.
5762         (remote_target::get_remote_state): Adjust.
5763
5764 2018-05-24  Andrew Burgess  <andrew.burgess@embecosm.com>
5765
5766         * stack.c (select_and_print_frame): Delete.
5767         (struct function_bounds): Move struct within function.
5768         (func_command): Most content moved into new function
5769         find_frame_for_function, use new function, print result, add
5770         function comment.
5771         (find_frame_for_function): New function, now returns a result.
5772
5773 2018-05-24  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
5774
5775         * stack.c (iterate_over_block_arg_vars): Fix comment.
5776         (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
5777
5778 2018-05-24  Andrew Burgess  <andrew.burgess@embecosm.com>
5779
5780         PR gdb/23203
5781         * frame.c
5782         (scoped_restore_selected_frame::scoped_restore_selected_frame):
5783         Define.
5784         (scoped_restore_selected_frame::~scoped_restore_selected_frame):
5785         Define.
5786         * frame.h (class scoped_restore_selected_frame): New class.
5787         * stack.c (print_frame_local_vars): Remove catching and rethrowing
5788         of any exception, use scoped_restore_selected_frame to restore the
5789         frame instead.
5790
5791 2018-05-24  Pedro Alves  <palves@redhat.com>
5792
5793         * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
5794         override.
5795
5796 2018-05-23  Tom Tromey  <tom@tromey.com>
5797
5798         * complaints.c (struct complaints): Remove.
5799         (symfile_complaint_book): Remove.
5800         (series): New global.
5801         (complaint_internal): Update.
5802         (clear_complaints): Update.
5803
5804 2018-05-23  Tom Tromey  <tom@tromey.com>
5805
5806         * complaints.c (counters): New global.
5807         (struct complain): Remove.
5808         (struct complaints) <root>: Remove.
5809         (complaint_sentinel): Remove.
5810         (symfile_complaint_book): Update.
5811         (find_complaint) Remove.
5812         (complaint_internal, clear_complaints): Update.
5813
5814 2018-05-23  Tom Tromey  <tom@tromey.com>
5815
5816         * complaints.c (struct complain) <file, line>: Remove.
5817         (find_complaint): Remove file, line parameters.
5818         (complaint_internal): Update.
5819
5820 2018-05-23  Tom Tromey  <tom@tromey.com>
5821
5822         * complaints.c (vcomplaint): Remove.
5823         (complaint_internal) Merge in contents of vcomplaint.
5824
5825 2018-05-23  Tom Tromey  <tom@tromey.com>
5826
5827         * complaints.c (struct complaints) <explanation>: Remove.
5828         (symfile_explanations): Remove.
5829         (symfile_complaint_book): Update.
5830         (vcomplaint): Update.
5831         (struct explanation): Remove.
5832
5833 2018-05-23  Tom Tromey  <tom@tromey.com>
5834
5835         * complaints.c (symfile_complaints): Remove.
5836         (complaint_internal): Remove "complaints" parameter.
5837         (clear_complaints, vcomplaint): Remove "c" parameter.
5838         (get_complaints): Remove.
5839         * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
5840         (dwarf2_debug_line_missing_file_complaint)
5841         (dwarf2_debug_line_missing_end_sequence_complaint)
5842         (dwarf2_complex_location_expr_complaint)
5843         (dwarf2_const_value_length_mismatch_complaint)
5844         (dwarf2_section_buffer_overflow_complaint)
5845         (dwarf2_macro_malformed_definition_complaint)
5846         (dwarf2_invalid_attrib_class_complaint)
5847         (create_addrmap_from_index, dw2_symtab_iter_next)
5848         (dw2_expand_marked_cus)
5849         (dw2_debug_names_iterator::find_vec_in_debug_names)
5850         (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
5851         (create_debug_type_hash_table, init_cutu_and_read_dies)
5852         (partial_die_parent_scope, add_partial_enumeration)
5853         (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
5854         (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
5855         (read_import_statement, read_file_scope, create_dwo_cu_reader)
5856         (create_cus_hash_table, create_dwp_hash_table)
5857         (inherit_abstract_dies, read_func_scope, read_call_site_scope)
5858         (dwarf2_rnglists_process, dwarf2_ranges_process)
5859         (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
5860         (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
5861         (handle_struct_member_die, process_structure_scope)
5862         (read_array_type, read_common_block, read_module_type)
5863         (read_tag_pointer_type, read_typedef, read_base_type)
5864         (read_subrange_type, load_partial_dies, partial_die_info::read)
5865         (partial_die_info::read, partial_die_info::read)
5866         (partial_die_info::read, read_checked_initial_length_and_offset)
5867         (dwarf2_string_attr, read_formatted_entries)
5868         (dwarf_decode_line_header)
5869         (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
5870         (new_symbol, dwarf2_const_value_attr, lookup_die_type)
5871         (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
5872         (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
5873         (get_signatured_type, get_DW_AT_signature_type)
5874         (decode_locdesc, file_file_name, consume_improper_spaces)
5875         (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
5876         (dwarf_decode_macro_bytes, dwarf_decode_macros)
5877         (dwarf2_symbol_mark_computed, set_die_type)
5878         (read_attribute_value): Update.
5879         * stap-probe.c (handle_stap_probe, get_stap_base_address):
5880         Update.
5881         * dbxread.c (unknown_symtype_complaint)
5882         (lbrac_mismatch_complaint, repeated_header_complaint)
5883         (set_namestring, function_outside_compilation_unit_complaint)
5884         (read_dbx_symtab, process_one_symbol): Update.
5885         * gdbtypes.c (stub_noname_complaint): Update.
5886         * windows-nat.c (handle_unload_dll): Update.
5887         * coffread.c (coff_symtab_read, enter_linenos, decode_type)
5888         (decode_base_type): Update.
5889         * xcoffread.c (bf_notfound_complaint, ef_complaint)
5890         (eb_complaint, record_include_begin, record_include_end)
5891         (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
5892         (process_xcoff_symbol, read_symbol)
5893         (function_outside_compilation_unit_complaint)
5894         (scan_xcoff_symtab): Update.
5895         * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
5896         * buildsym.c (finish_block_internal, make_blockvector)
5897         (end_symtab_get_static_block, augment_type_symtab): Update.
5898         * dtrace-probe.c (dtrace_process_dof)
5899         (dtrace_static_probe_ops::get_probes): Update.
5900         * complaints.h (struct complaint): Don't declare.
5901         (symfile_complaints): Remove.
5902         (complaint_internal): Remove "complaints" parameter.
5903         (complaint): Likewise.
5904         (clear_complaints): Likewise.
5905         * symfile.c (syms_from_objfile_1, finish_new_objfile)
5906         (reread_symbols): Update.
5907         * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
5908         (dwarf2_frame_cache, decode_frame_entry): Update.
5909         * dwarf2loc.c (dwarf_reg_to_regnum): Update.
5910         * objc-lang.c (lookup_objc_class, lookup_child_selector)
5911         (info_selectors_command): Update.
5912         * macrotab.c (macro_include, check_for_redefinition)
5913         (macro_undef): Update.
5914         * objfiles.c (filter_overlapping_sections): Update.
5915         * stabsread.c (invalid_cpp_abbrev_complaint)
5916         (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
5917         (define_symbol, error_type, read_type, rs6000_builtin_type)
5918         (stabs_method_name_from_physname, read_member_functions)
5919         (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
5920         (attach_fields_to_type, complain_about_struct_wipeout)
5921         (read_range_type, read_args, common_block_start)
5922         (common_block_end, cleanup_undefined_types_1, scan_file_globals):
5923         Update.
5924         * mdebugread.c (index_complaint, unknown_ext_complaint)
5925         (basic_type_complaint, bad_tag_guess_complaint)
5926         (bad_rfd_entry_complaint, unexpected_type_code_complaint)
5927         (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
5928         (parse_procedure, parse_lines)
5929         (function_outside_compilation_unit_complaint)
5930         (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
5931         (bad_tag_guess_complaint, reg_value_complaint): Update.
5932         * cp-support.c (demangled_name_complaint): Update.
5933         * macroscope.c (sal_macro_scope): Update.
5934         * dwarf-index-write.c (class debug_names): Update.
5935
5936 2018-05-23  Tom Tromey  <tom@tromey.com>
5937
5938         * complaints.c (clear_complaints): Remove "noisy" parameter.
5939         * complaints.h (clear_complaints): Update.
5940         * symfile.c (syms_from_objfile_1, finish_new_objfile)
5941         (reread_symbols): Update.
5942
5943 2018-05-23  Tom Tromey  <tom@tromey.com>
5944
5945         * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
5946         SUBSEQUENT_MESSAGE.
5947         (vcomplaint, clear_complaints): Update.
5948         (symfile_explanations): Remove some messages.
5949
5950 2018-05-23  Tom Tromey  <tom@tromey.com>
5951
5952         * complaints.c (internal_complaint): Remove.
5953         * complaints.h (internal_complaint): Remove.
5954
5955 2018-05-22  Maciej W. Rozycki  <macro@mips.com>
5956
5957         * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
5958
5959 2018-05-22  Pedro Alves  <palves@redhat.com>
5960
5961         * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
5962         (remote_fileio_badfd, remote_fileio_return_errno)
5963         (remote_fileio_return_success, remote_fileio_func_open)
5964         (remote_fileio_func_open, remote_fileio_func_close)
5965         (remote_fileio_func_read, remote_fileio_func_write)
5966         (remote_fileio_func_lseek, remote_fileio_func_rename)
5967         (remote_fileio_func_unlink, remote_fileio_func_stat)
5968         (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
5969         (remote_fileio_func_isatty, remote_fileio_func_system): Add
5970         remote_target parameter.
5971         (remote_fio_func_map) <func>: Add remote_target parameter.
5972         (do_remote_fileio_request, remote_fileio_request):
5973         * remote-fileio.h (remote_fileio_request):
5974         * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
5975         remote_target parameter.
5976         (remote_notif_process, handle_notification): Adjust to pass down
5977         the remote.
5978         (remote_notif_state_allocate): Add remote_target parameter.  Save
5979         it.
5980         * remote-notif.h (struct remote_target): Forward declare.
5981         (struct notif_client) <parse, ack, can_get_pending_events>: Add
5982         remote_target parameter.
5983         (struct remote_notif_state) <remote>: New field.
5984         (remote_notif_ack, remote_notif_parse): Add remote_target
5985         parameter.
5986         (remote_notif_state_allocate, remote_notif_state_allocate): Add
5987         remote_target parameter.
5988         * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
5989         (threads_listing_context, rmt_thread_action, protocol_feature)
5990         (packet_reg, stop_reply, stop_reply_p, enum packet_support)
5991         (packet_result, struct threads_listing_context, remote_state):
5992         Move definitions and declarations higher up.
5993         (remote_target) <~remote_target>: Declare.
5994         (remote_download_command_source, remote_file_put, remote_file_get)
5995         (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
5996         (remote_hostio_pread_vFile, remote_hostio_send_command)
5997         (remote_hostio_set_filesystem, remote_hostio_open)
5998         (remote_hostio_close, remote_hostio_unlink, remote_state)
5999         (get_remote_state, get_remote_packet_size, get_memory_packet_size)
6000         (get_memory_write_packet_size, get_memory_read_packet_size)
6001         (append_pending_thread_resumptions, remote_detach_1)
6002         (append_resumption, remote_resume_with_vcont)
6003         (add_current_inferior_and_thread, wait_ns, wait_as)
6004         (process_stop_reply, remote_notice_new_inferior)
6005         (process_initial_stop_replies, remote_add_thread)
6006         (btrace_sync_conf, remote_btrace_maybe_reopen)
6007         (remove_new_fork_children, kill_new_fork_children)
6008         (discard_pending_stop_replies, stop_reply_queue_length)
6009         (check_pending_events_prevent_wildcard_vcont)
6010         (discard_pending_stop_replies_in_queue, stop_reply)
6011         (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
6012         (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
6013         (remote_interrupt_as, remote_interrupt_ns)
6014         (remote_get_noisy_reply, remote_query_attached)
6015         (remote_add_inferior, remote_current_thread, get_current_thread)
6016         (set_thread, set_general_thread, set_continue_thread)
6017         (set_general_process, write_ptid)
6018         (remote_unpack_thread_info_response, remote_get_threadinfo)
6019         (parse_threadlist_response, remote_get_threadlist)
6020         (remote_threadlist_iterator, remote_get_threads_with_ql)
6021         (remote_get_threads_with_qxfer)
6022         (remote_get_threads_with_qthreadinfo, extended_remote_restart)
6023         (get_offsets, remote_check_symbols, remote_supported_packet)
6024         (remote_query_supported, remote_packet_size)
6025         (remote_serial_quit_handler, remote_detach_pid)
6026         (remote_vcont_probe, remote_resume_with_hc)
6027         (send_interrupt_sequence, interrupt_query)
6028         (remote_notif_get_pending_events, fetch_register_using_p)
6029         (send_g_packet, process_g_packet, fetch_registers_using_g)
6030         (store_register_using_P, store_registers_using_G)
6031         (set_remote_traceframe, check_binary_download)
6032         (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
6033         (remote_xfer_live_readonly_partial, remote_read_bytes)
6034         (remote_send_printf, remote_flash_write, readchar)
6035         (remote_serial_write, putpkt, putpkt_binary, skip_frame)
6036         (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
6037         (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
6038         (extended_remote_disable_randomization, extended_remote_run)
6039         (send_environment_packet, extended_remote_environment_support)
6040         (extended_remote_set_inferior_cwd, remote_write_qxfer)
6041         (remote_read_qxfer, push_stop_reply, vcont_r_supported)
6042         (packet_command): Now methods of ...
6043         (remote_target): ... this class.
6044         (m_remote_state) <remote_target>: New field.
6045         (struct remote_state) <stop_reply_queue,
6046         remote_async_inferior_event_token, wait_forever_enabled_p>: New
6047         fields.
6048         (remote_state::remote_state): Allocate stop_reply_queue.
6049         (remote_state): Delete global.
6050         (get_remote_state_raw): Delete.
6051         (remote_target::get_remote_state): Allocate m_remote_state on
6052         demand.
6053         (get_current_remote_target): New.
6054         (remote_ops, extended_remote_ops): Delete.
6055         (wait_forever_enabled_p, remote_async_inferior_event_token):
6056         Delete, moved to struct remote_state.
6057         (remote_target::close): Delete self.  Destruction bits split to
6058         ...
6059         (remote_target::~remote_target): ... this.
6060         (show_memory_packet_size): Adjust to use
6061         get_current_remote_target.
6062         (struct protocol_feature) <func>: Add remote_target parameter.
6063         All callers adjusted.
6064         (curr_quit_handler_target): New.
6065         (remote_serial_quit_handler): Reimplement.
6066         (remote_target::open_1): Adjust to use get_current_remote_target.
6067         Heap-allocate remote_target/extended_remote_target instances.
6068         (vcont_builder::vcont_builder): Add remote_target parameter, and
6069         save it in m_remote.  All callers adjusted.
6070         (vcont_builder::m_remote): New field.
6071         (vcont_builder::restart, vcont_builder::flush)
6072         (vcont_builder::push_action): Use it.
6073         (remote_target::commit_resume): Use it.
6074         (struct queue_iter_param) <remote>: New field.
6075         (remote_target::remove_new_fork_children): Fill in 'remote' field.
6076         (check_pending_event_prevents_wildcard_vcont_callback_data): New.
6077         (check_pending_event_prevents_wildcard_vcont_callback)
6078         (remote_target::check_pending_events_prevent_wildcard_vcont)
6079         (remote_target::discard_pending_stop_replies)
6080         (remote_target::discard_pending_stop_replies_in_queue)
6081         (remote_target::remote_notif_remove_queued_reply): Fill in
6082         'remote' field.
6083         (remote_notif_get_pending_events): New.
6084         (remote_target::readchar, remote_target::remote_serial_write):
6085         Save/restore curr_quit_handler_target.
6086         (putpkt): New.
6087         (kill_new_fork_children): Fill in 'remote' field.
6088         (packet_command): Use get_current_remote_target, defer to
6089         remote_target method of same name.
6090         (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
6091         parameter, and save it in m_remote.  All callers adjusted.
6092         (scoped_remote_fd::release): Use m_remote.
6093         (scoped_remote_fd::m_remote): New field.
6094         (remote_file_put, remote_file_get, remote_file_delete): Use
6095         get_current_remote_target, defer to remote_target method of same
6096         name.
6097         (remote_btrace_reset): Add remote_state paremeter.  Update all
6098         callers.
6099         (remote_async_inferior_event_handler). Pass down 'data'.
6100         (remote_new_objfile): Use get_current_remote_target.
6101         (remote_target::vcont_r_supported): New.
6102         (set_range_stepping): Use get_current_remote_target and
6103         remote_target::vcont_r_supported.
6104         (_initialize_remote): Don't allocate 'remote_state' and
6105         'stop_reply_queue' globals.
6106         * remote.h (struct remote_target): Forward declare.
6107         (getpkt, putpkt, remote_notif_get_pending_events): Add
6108         'remote_target' parameter.
6109
6110 2018-05-22  Pedro Alves  <palves@redhat.com>
6111
6112         * remote.c (vcont_builder): Now a class.  Make all data members
6113         private.
6114         (vcont_builder) <vcont_builder, restart, flush, push_action>:
6115         Declare methods.
6116         (vcont_builder_restart): Rename to ...
6117         (vcont_builder::restart): ... this.
6118         (vcont_builder_flush): Rename to ...
6119         (vcont_builder::flush): ... this.
6120         (vcont_builder_push_action): Rename to ...
6121         (vcont_builder::push_action): ... this.
6122         (remote_target::commit_resume): Adjust.
6123
6124 2018-05-22  Pedro Alves  <palves@redhat.com>
6125
6126         * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
6127         (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
6128         (get_fixed_memory_packet_size): New.
6129         (get_memory_packet_size): Use it.
6130         (set_memory_packet_size): Don't override the config size with
6131         DEFAULT_MAX_MEMORY_PACKET_SIZE.
6132         (show_memory_packet_size): Use get_fixed_memory_packet_size.
6133         Don't refer to get_memory_packet_size if not connected to a remote
6134         target.  Show "(default)" if configured size is 0.
6135
6136 2018-05-22  Pedro Alves  <palves@redhat.com>
6137
6138         * remote.c (remote_target::mourn_inferior): Move
6139         discard_pending_stop_replies call here from ...
6140         (_initialize_remote): ... here.
6141
6142 2018-05-22  Pedro Alves  <palves@redhat.com>
6143
6144         * remote.c (compare_section_command): Remove set_general_process
6145         call.
6146
6147 2018-05-22  Pedro Alves  <palves@redhat.com>
6148
6149         * remote.c (struct packet_reg, struct remote_arch_state):
6150         Move higher up in the file.
6151         (remote_state) <m_arch_states>: Store remote_arch_state values
6152         instead of remote_arch_state pointers.
6153         (remote_state::get_remote_arch_state): Adjust.
6154
6155 2018-05-22  Pedro Alves  <palves@redhat.com>
6156
6157         * remote.c: Include <unordered_map>.
6158         (remote_state): Now a class.
6159         (remote_state) <get_remote_arch_state>: Declare method.
6160         <get_remote_arch_state>: New field.
6161         (remote_arch_state) <remote_arch_state>: Declare ctor.
6162         <regs>: Now a unique_ptr.
6163         (remote_gdbarch_data_handle): Delete.
6164         (get_remote_arch_state): Delete.
6165         (remote_state::get_remote_arch_state): New.
6166         (get_remote_state): Adjust to call remote_state's
6167         get_remote_arch_state method.
6168         (init_remote_state): Delete, bits factored out to ...
6169         (remote_arch_state::remote_arch_state): ... this new method.
6170         (get_remote_packet_size, get_memory_packet_size)
6171         (process_g_packet, remote_target::fetch_registers)
6172         (remote_target::prepare_to_store, store_registers_using_G)
6173         (remote_target::store_registers, remote_target::get_trace_status):
6174         Adjust to call remote_state's method.
6175         (_initialize_remote): Remove reference to
6176         remote_gdbarch_data_handle.
6177
6178 2018-05-22  Pedro Alves  <palves@redhat.com>
6179
6180         * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
6181         pread>: New method declarations.
6182         (remote_target::open_1): Adjust.
6183         (readahead_cache_invalidate): Rename to ...
6184         (readahead_cache::invalidate): ... this, and adjust to be a class
6185         method.
6186         (readahead_cache_invalidate_fd): Rename to ...
6187         (readahead_cache::invalidate_fd): ... this, and adjust to be a
6188         class method.
6189         (remote_hostio_pwrite): Adjust.
6190         (remote_hostio_pread_from_cache): Rename to ...
6191         (readahead_cache::pread): ... this, and adjust to be a class
6192         method.
6193         (remote_hostio_close): Adjust.
6194
6195 2018-05-22  Pedro Alves  <palves@redhat.com>
6196
6197         * remote.c (remote_hostio_close_cleanup): Delete.
6198         (class scoped_remote_fd): New.
6199         (remote_file_put, remote_file_get): Use it.
6200
6201 2018-05-22  Pedro Alves  <palves@redhat.com>
6202
6203         (struct vCont_action_support): Use bool and initialize all fields.
6204         (struct readahead_cache): Initialize all fields.
6205         (remote_state): Use bool and initialize all fields.
6206         (remote_state::remote_state, remote_state::~remote_state): New.
6207         (new_remote_state): Delete.
6208         (_initialize_remote): Use new to allocate remote_state.
6209
6210 2018-05-22  Pedro Alves  <palves@redhat.com>
6211             張俊芝  <zjz@zjz.name>
6212
6213         PR gdb/22973
6214         * c-exp.y: Include "c-support.h".
6215         (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
6216         of tolower.  Use c_ident_is_alpha to scan names.
6217         * c-lang.c: Include "c-support.h".
6218         (convert_ucn, convert_octal, convert_hex, convert_escape): Use
6219         ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
6220         * c-support.h: New file, with bits factored out from ...
6221         * cp-name-parser.y: ... this file.
6222         Include "c-support.h".
6223         (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
6224         c-support.h and renamed.
6225         (symbol_end, yylex): Adjust.
6226
6227 2018-05-22  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
6228
6229         * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
6230         parameter type to CORE_ADDR.
6231         * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
6232         parameter type in declaration to CORE_ADDR.
6233         * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
6234         target_auxv_search to get AT_HWCAP and use the result to get the
6235         target description.
6236         * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
6237         to CORE_ADDR. Remove the cast of the return value to unsigned
6238         long. Fix error predicate of target_auxv_search.
6239         (ppc_linux_nat_target::read_description): Change the type of the
6240         hwcap variable to CORE_ADDR.
6241
6242 2018-05-22  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
6243
6244         * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
6245         if the size of fpscr is larger than 32 bits.
6246
6247 2018-05-22  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
6248
6249         * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
6250         (ppc32_linux_vsxregmap): New global.
6251         (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
6252         regcache_supply_regset, and regcache_collect_regset.
6253         * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
6254         * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
6255         (fetch_vsx_register, store_vsx_register): Remove.
6256         (fetch_vsx_registers): Add regno parameter. Get regset using
6257         ppc_linux_vsxregset. Use regset to supply registers.
6258         (store_vsx_registers): Add regno parameter. Get regset using
6259         ppc_linux_vsxregset. Use regset to collect registers.
6260         (fetch_register): Call fetch_vsx_registers instead of
6261         fetch_vsx_register.
6262         (store_register): Call store_vsx_registers instead of
6263         store_vsx_register.
6264         (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
6265         new regno parameter.
6266         (store_ppc_registers): Call store_vsx_registers with -1 for the
6267         new regno parameter.
6268         * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
6269         (ppc_collect_vsxregset): Remove.
6270
6271 2018-05-22  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
6272
6273         * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
6274         offset fields.
6275         * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
6276         for vector register offset fields.
6277         (ppc64_fbsd_reg_offsets): Likewise.
6278         * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6279         to vector register offset fields.
6280         * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6281         to vector register offset fields.
6282         * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
6283         vector register offset fields.
6284         * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
6285         initializers for vector register offset fields.
6286         (rs6000_aix64_reg_offsets): Likewise.
6287         * rs6000-tdep.c (ppc_vrreg_offset): Remove.
6288         (ppc_supply_vrregset): Remove.
6289         (ppc_collect_vrregset): Remove.
6290         * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
6291         (ppc_linux_vrregset) : New function.
6292         (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
6293         (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
6294         (ppc32_linux_vrregset): Remove.
6295         (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
6296         and use result instead of ppc32_linux_vrregset.
6297         (ppc32_linux_reg_offsets): Remove initializers for vector register
6298         offset fields.
6299         (ppc64_linux_reg_offsets): Likewise.
6300         * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
6301         * ppc-linux-nat.c: Include regset.h.
6302         (gdb_vrregset_t): Adjust comment to account for little-endian
6303         mode.
6304         (supply_vrregset, fill_vrregset): Remove.
6305         (fetch_altivec_register, store_altivec_register): Remove.
6306         (fetch_altivec_registers): Add regno parameter. Get regset using
6307         ppc_linux_vrregset. Use regset to supply registers.
6308         (store_altivec_registers): Add regno parameter. Get regset using
6309         ppc_linux_vrregset. Use regset to collect registers.
6310         (fetch_register): Call fetch_altivec_registers instead of
6311         fetch_altivec_register.
6312         (store_register): Call store_altivec_registers instead of
6313         store_altivec_register.
6314         (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
6315         the new regno parameter.
6316         (store_ppc_registers): Call store_altivec_registers with -1 for
6317         the new regno parameter.
6318
6319 2018-05-22  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
6320
6321         * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
6322         (PPC_LINUX_SIZEOF_VSXREGSET): Define.
6323         * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
6324         (gdb_vrregset_t): Change array type size to
6325         PPC_LINUX_SIZEOF_VRREGSET.
6326         (gdb_vsxregset_t): Change array type size to
6327         PPC_LINUX_SIZEOF_VSXREGSET.
6328         * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
6329         Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
6330         PPC_LINUX_SIZEOF_VSXREGSET.
6331
6332 2018-05-22  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
6333
6334         * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
6335         * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
6336         nat/ppc-linux.c.
6337         (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
6338         ppc_linux_target_wordsize with tid.
6339         (ppc_linux_nat_target::read_description): Call ppc_linux_target
6340         wordsize with tid.
6341         * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
6342         (ppc64_64bit_inferior_p): Add static and inline specifiers.
6343         (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
6344         tid parameter. Remove static specifier.
6345         * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
6346         (ppc_linux_target_wordsize): New declaration.
6347
6348 2018-05-22  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
6349
6350         * arch/ppc-linux-common.c: New file.
6351         * arch/ppc-linux-common.h: New file.
6352         * arch/ppc-linux-tdesc.h: New file.
6353         * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
6354         * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
6355         (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
6356         arch/ppc-linux-tdesc.h.
6357         * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
6358         arch/ppc-linux-tdesc.h.
6359         (ppc_linux_nat_target::read_description): Remove target
6360         description matching code. Fill a ppc_linux_features struct and
6361         call ppc_linux_match_description with it. Move comment about ISA
6362         2.05 to ppc-linux-common.c.
6363         * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
6364         arch/ppc-linux-tdesc.h.
6365         (ppc_linux_core_read_description): Remove target description
6366         matching code. Fill a ppc_linux_features struct and call
6367         ppc_linux_match_description with it.
6368         * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
6369         (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
6370         (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
6371         (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
6372         (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
6373         (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
6374         (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
6375         (tdesc_powerpc_e500l): Remove.
6376
6377 2018-05-22  Joel Brobecker  <brobecker@adacore.com>
6378
6379         * ada-lang.c (catch_assert_command): Pass empty string instead
6380         of NULL for excep_string argument.
6381
6382 2018-05-22  Maciej W. Rozycki  <macro@mips.com>
6383
6384         * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
6385         the width of the requested register exceeds the width of the
6386         `ptrace' data type.
6387
6388 2018-05-21  Tom Tromey  <tom@tromey.com>
6389
6390         * printcmd.c (output_command): Remove.
6391         (output_command_const): Rename to output_command.
6392         * valprint.h (output_command): Rename from output_command_const.
6393         * tracepoint.c (trace_dump_actions): Call output_command.
6394
6395 2018-05-21  Tom Tromey  <tom@tromey.com>
6396
6397         * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
6398         (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
6399         * ada-lang.h (create_ada_exception_catchpoint): Update.
6400         * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
6401         std::string.
6402         (create_excep_cond_exprs, ~ada_catchpoint)
6403         (should_stop_exception, print_one_exception)
6404         (print_mention_exception, print_recreate_exception): Update.
6405         (ada_get_next_arg): Remove.
6406         (catch_ada_exception_command_split): Use std::string.  Change type
6407         of "excep_string", "cond_string".
6408         (catch_ada_exception_command): Update.
6409         (create_ada_exception_catchpoint): Change type of excep_string.
6410         (ada_exception_sal): Remove excep_string parameter.
6411         (~ada_catchpoint): Remove.
6412
6413 2018-05-21  Tom Tromey  <tom@tromey.com>
6414
6415         * ada-lang.c (ada_collect_symbol_completion_matches): Remove
6416         cleanup.
6417
6418 2018-05-21  Tom Tromey  <tom@tromey.com>
6419
6420         * ada-lang.c (ada_exception_message_1, ada_exception_message):
6421         Return unique_xmalloc_ptr.
6422         (print_it_exception): Update.
6423
6424 2018-05-21  Tom Tromey  <tom@tromey.com>
6425
6426         * tracepoint.c (trace_dump_actions): Use std::string.
6427
6428 2018-05-21  Tom Tromey  <tom@tromey.com>
6429
6430         * symfile.c (reread_symbols): Use std::string for original_name.
6431
6432 2018-05-21  Tom Tromey  <tom@tromey.com>
6433
6434         * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
6435         (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN.  Default
6436         constructor.
6437
6438 2018-05-20  Simon Marchi  <simon.marchi@polymtl.ca>
6439
6440         * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
6441         instance to...
6442         (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
6443         * objfiles.c (get_objfile_bfd_data): Allocate
6444         objfile_per_bfd_storage with obstack_new when allocating on
6445         obstack.
6446
6447 2018-05-20  Simon Marchi  <simon.marchi@ericsson.com>
6448
6449         * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
6450         OBSTACK_ZALLOC.
6451         * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
6452         * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
6453         * mdebugread.c (mdebug_build_psymtabs): Likewise.
6454         (add_pending): Likewise.
6455         (parse_symbol): Likewise.
6456         (parse_partial_symbols): Likewise.
6457         (psymtab_to_symtab_1): Likewise.
6458         (new_psymtab): Likewise.
6459         (elfmdebug_build_psymtabs): Likewise.
6460         * minsyms.c (terminate_minimal_symbol_table): Likewise.
6461         * objfiles.c (get_objfile_bfd_data): Likewise.
6462         (objfile_register_static_link): Likewise.
6463         * psymtab.c (allocate_psymtab): Likewise.
6464         * stabsread.c (read_member_functions): Likewise.
6465         * xcoffread.c (xcoff_end_psymtab): Likewise.
6466
6467 2018-05-20  Simon Marchi  <simon.marchi@ericsson.com>
6468
6469         * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
6470         compiler supports std::is_trivially_constructible.
6471         * common/poison.h: Include obstack.h.
6472         (IsMallocable): Define to is_trivially_constructible if the
6473         compiler supports it, define to true_type otherwise.
6474         (xobnew): New.
6475         (XOBNEW): Redefine.
6476         (xobnewvec): New.
6477         (XOBNEWVEC): Redefine.
6478         * gdb_obstack.h (obstack_zalloc): New.
6479         (OBSTACK_ZALLOC): Redefine.
6480         (obstack_calloc): New.
6481         (OBSTACK_CALLOC): Redefine.
6482         (obstack_new): New.
6483         * gdbarch.sh: Include gdb_obstack in gdbarch.h.
6484         (gdbarch_obstack): New declaration in gdbarch.h, definition in
6485         gdbarch.c.
6486         (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
6487         obstack_calloc/obstack_zalloc.
6488         (gdbarch_obstack_zalloc): Remove.
6489         * target-descriptions.c (tdesc_data_init): Use obstack_new.
6490
6491 2018-05-19  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
6492
6493         * stack.c (backtrace_command_1): Remove useless variable int i.
6494
6495 2018-05-19  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
6496
6497         * stack.c (print_frame_info): Fix comment.
6498
6499 2018-05-18  Tom Tromey  <tom@tromey.com>
6500
6501         * dwarf2read.c (struct dwz_file): Add constructor, initializers.
6502         <dwz_bfd>: Now a gdb_bfd_ref_ptr.
6503         (~dwarf2_per_objfile): Update
6504         (dwarf2_get_dwz_file): Use new.
6505         * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
6506         unique_ptr.
6507
6508 2018-05-18  Tom Tromey  <tom@tromey.com>
6509
6510         * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
6511         unique_ptr.
6512         * dwarf2read.c (struct dwp_file): Add constructor and
6513         initializers.
6514         (open_and_init_dwp_file): Return a unique_ptr.
6515         (dwarf2_per_objfile, create_dwp_hash_table)
6516         (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
6517         (lookup_dwo_unit_in_dwp): Update.
6518         (open_and_init_dwp_file, get_dwp_file): Update.
6519
6520 2018-05-18  Tom Tromey  <tom@tromey.com>
6521
6522         * dwarf2read.c (dwarf2_per_objfile): Update.
6523         (struct mapped_index): Add initializers.
6524         (dwarf2_read_index): Use new.
6525         (dw2_symtab_iter_init): Update.
6526         * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
6527         unique_ptr.
6528
6529 2018-05-18  Simon Marchi  <simon.marchi@ericsson.com>
6530
6531         * dwarf2read.c (mapped_index) <total_size>: Remove.
6532
6533 2018-05-18  Simon Marchi  <simon.marchi@ericsson.com>
6534
6535         * unittests/format_pieces-selftests.c (test_format_specifier):
6536         Add ARI comments.
6537
6538 2018-05-18  Tom Tromey  <tom@tromey.com>
6539
6540         * c-typeprint.c (maybe_print_hole): New function.
6541         (c_print_type_struct_field_offset): Update.
6542         (c_type_print_base_struct_union): Call maybe_print_hole.
6543
6544 2018-05-17  Keith Seitz  <keiths@redhat.com>
6545
6546         * breakpoint.c (build_bpstat_chain): New function, moved from
6547         bpstat_stop_status.
6548         (bpstat_stop_status): Add optional parameter, `stop_chain'.
6549         If no stop chain is passed, call build_bpstat_chain to build it.
6550         * breakpoint.h (build_bpstat_chain): Declare.
6551         (bpstat_stop_status): Move documentation here from breakpoint.c.
6552         * infrun.c (handle_signal_stop): Before eliding inlined frames,
6553         build the stop chain and pass it to skip_inline_frames.
6554         Pass this stop chain to bpstat_stop_status.
6555         * inline-frame.c: Include breakpoint.h.
6556         (stopped_by_user_bp_inline_frame): New function.
6557         (skip_inline_frames): Add parameter `stop_chain'.
6558         Move documention to inline-frame.h.
6559         If non-NULL, use stopped_by_user_bp_inline_frame to determine
6560         whether the frame should be elided.
6561         * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
6562         Add moved documentation and update for new parameter.
6563
6564 2018-05-17  Simon Marchi  <simon.marchi@ericsson.com>
6565
6566         PR cli/14975
6567         * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6568         unittests/format_pieces-selftests.c.
6569         * common/format.h (format_piece) <operator==>: New.
6570         (format_pieces) <operator[]>: Remove.
6571         * common/format.c (format_pieces::format_pieces): Handle \e.
6572         * unittests/format_pieces-selftests.c: New.
6573
6574 2018-05-17  Tom Tromey  <tom@tromey.com>
6575
6576         PR symtab/23010:
6577         * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
6578         (dw2_instantiate_symtab): Add skip_partial parameter.
6579         (dw2_find_last_source_symtab, dw2_map_expand_apply)
6580         (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
6581         (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
6582         (dw2_expand_symtabs_matching_one)
6583         (dw2_find_pc_sect_compunit_symtab)
6584         (dw2_debug_names_lookup_symbol)
6585         (dw2_debug_names_expand_symtabs_for_function): Update.
6586         (init_cutu_and_read_dies): Add skip_partial parameter.
6587         (process_psymtab_comp_unit, build_type_psymtabs_1)
6588         (process_skeletonless_type_unit, load_partial_comp_unit)
6589         (psymtab_to_symtab_1): Update.
6590         (load_full_comp_unit): Add skip_partial parameter.
6591         (process_imported_unit_die, dwarf2_read_addr_index)
6592         (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
6593         (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
6594         (read_signatured_type): Update.
6595
6596 2018-05-17  Simon Marchi  <simon.marchi@ericsson.com>
6597
6598         * value.c (release_value): Remove unused variable.
6599         (record_latest_value): Likewise.
6600         (access_value_history): Likewise.
6601         (preserve_values): Likewise.
6602
6603 2018-05-17  Tom Tromey  <tom@tromey.com>
6604
6605         * extension.h (struct ext_lang_type_printers) <py_type_printers>:
6606         Initialize.
6607
6608 2018-05-16  Maciej W. Rozycki  <macro@mips.com>
6609
6610         PR gdb/22286
6611         * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
6612         Also handle registers whose width is not a multiple of
6613         PTRACE_TYPE_RET.
6614         (linux_nat_trad_target::store_register): Likewise.
6615
6616 2018-05-16  Tom Tromey  <tom@tromey.com>
6617
6618         * gdbcore.h (core_bfd): Redefine.
6619         * corelow.c (core_target::close): Update.
6620         (core_target_open): Update.
6621         * progspace.h (struct program_space) <cbfd>: Now a
6622         gdb_bfd_ref_ptr.
6623
6624 2018-05-16  Tom Tromey  <tom@tromey.com>
6625
6626         PR cli/19551:
6627         * symfile-add-flags.h (enum symfile_add_flags)
6628         <SYMFILE_NOT_FILENAME>: New constant.
6629         * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME.  Get
6630         objfile name from BFD.
6631         (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
6632         * minidebug.c (find_separate_debug_file_in_section): Put
6633         ".gnu_debugdata" into BFD's file name.
6634
6635 2018-05-16  Simon Marchi  <simon.marchi@ericsson.com>
6636
6637         * regcache.c (regcache_read_ftype, regcache_write_ftype):
6638         Remove.
6639
6640 2018-05-15  Tamar Christina  <tamar.christina@arm.com>
6641
6642         PR binutils/21446
6643         * aarch64-tdep.c (aarch64_analyze_prologue,
6644         aarch64_software_single_step, aarch64_displaced_step_copy_insn):
6645         Indicate not interested in errors.
6646
6647 2018-05-15  Maciej W. Rozycki  <macro@mips.com>
6648
6649         * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
6650         Supply the MIPS_ZERO_REGNUM register.
6651
6652 2018-05-15  Maciej W. Rozycki  <macro@mips.com>
6653
6654         * mips-tdep.c (mask_address_var): Make variable static.
6655
6656 2018-05-14  Tom Tromey  <tom@tromey.com>
6657
6658         * dwarf2read.c (rust_union_quirks): Clear rust_unions.
6659
6660 2018-05-11  Andrew Burgess  <andrew.burgess@embecosm.com>
6661
6662         * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
6663         FXSAVE_ADDR for the mxcsr register.
6664
6665 2018-05-11  Max Filippov  <jcmvbkbc@gmail.com>
6666
6667         * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
6668
6669 2018-05-11  Pedro Alves  <palves@redhat.com>
6670
6671         * corelow.c (core_target) <core_target>: No longer inline.
6672         Initialize m_core_gdbarch, m_core_vec and build the section table
6673         here.
6674         <~core_target>: New.
6675         <core_gdbarch, get_core_register_section>: New methods.
6676         <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
6677         factored out from ...
6678         <core_data, core_vec, core_gdbarch>: ... these deleted globals.
6679         (core_ops): Delete.
6680         (sniff_core_bfd): Add gdbarch parameter.
6681         (core_close): Delete, merged into ...
6682         (core_target::close): ... here.  Delete self.
6683         (core_close_cleanup): Delete.
6684         (core_target_open): Allocate a core_target on the heap.  Use a
6685         unique_ptr instead of a cleanup.  Bits moved into the core_target
6686         ctor.  Adjust to use core_target methods instead of globals.
6687         (get_core_register_section): Rename to ...
6688         (core_target::get_core_register_section): ... this and adjust.
6689         (struct get_core_registers_cb_data): New.
6690         (get_core_registers_cb): Use it.  Use bool.
6691         (core_target::fetch_registers, core_target::files_info)
6692         (core_target::xfer_partial, core_target::read_description)
6693         (core_target::pid_to, core_target::thread_name): Adjust to
6694         reference class fields instead of globals.
6695         * target.h (struct target_ops_deleter, target_ops_up): New.
6696
6697 2018-05-11  Pedro Alves  <palves@redhat.com>
6698
6699         * corefile.c (core_file_command): Move to corelow.c.
6700         * corelow.c (the_core_target): Delete.
6701         (core_file_command): Moved from corefile.c.  Check exec_bfd
6702         instead of the_core_target.  Use target_detach instead of calling
6703         into the_core_target directly.
6704         (maybe_say_no_core_file_now): New.
6705         (core_target::detach): Use it.
6706         (_initialize_corelow): Remove references to the_core_target.
6707         * gdbcore.h (the_core_target): Delete.
6708
6709 2018-05-11  Tom Tromey  <tromey@redhat.com>
6710             Pedro Alves  <palves@redhat.com>
6711
6712         * corefile.c (core_bfd): Remove.
6713         * gdbcore.h (core_bfd): Now a macro.
6714         * progspace.h (struct program_space) <cbfd>: New field.
6715
6716 2018-05-11  Tom Tromey  <tom@tromey.com>
6717
6718         * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
6719         gdb::def_vector.
6720
6721 2018-05-10  Tom Tromey  <tom@tromey.com>
6722
6723         * configure: Rebuild.
6724         * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
6725
6726 2018-05-10  Joel Brobecker  <brobecker@adacore.com>
6727
6728         PR server/23158:
6729         * regformats/regdat.sh: Adjust script, following the addition
6730         of the new expedite_regs parameter to init_target_desc.
6731
6732 2018-05-10  Omair Javaid  <omair.javaid@linaro.org>
6733     
6734         PR gdb/23127
6735         * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
6736         set_gdbarch_significant_addr_bit.
6737         * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
6738         set_gdbarch_significant_addr_bit.
6739         * utils.c (address_significant): Update to sign extend addr.
6740
6741 2018-05-09  Max Filippov  <jcmvbkbc@gmail.com>
6742
6743         * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
6744         (xtensa_linux_init_abi): Limit tdep->num_regs by
6745         tdep->num_nopriv_regs.
6746         * xtensa-tdep.c (xtensa_derive_tdep): Calculate
6747         tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
6748         not initialized.
6749
6750 2018-05-08  Simon Marchi  <simon.marchi@ericsson.com>
6751
6752         * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
6753
6754 2018-05-08  Andrew Burgess  <andrew.burgess@embecosm.com>
6755
6756         * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
6757         (I387_MXCSR_INIT_VAL): New constant.
6758         * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
6759         buffer if it was supplied by the inferior.
6760         * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
6761         (i387_xsave_get_clear_bv): New function.
6762         (i387_supply_xsave): Only read x87 control registers from the
6763         xsave buffer if the feature is enabled, and the state will have
6764         been written, otherwise, provide a suitable default.
6765         (i387_collect_xsave): Pre-clear all registers in xsave buffer,
6766         including x87 control registers.  Update control registers if they
6767         have changed from the default value, and mark features as enabled
6768         as required.
6769         * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
6770
6771 2018-05-08  Ulrich Weigand  <uweigand@de.ibm.com>
6772
6773         * spu-tdep.c (info_spu_event_command): Fix output formatting.
6774
6775 2018-05-07  Tom Tromey  <tom@tromey.com>
6776
6777         * configure: Rebuild.
6778         * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
6779
6780 2018-05-07  Tom Tromey  <tom@tromey.com>
6781
6782         PR tdep/20362:
6783         * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
6784         bit.  Use correct value for VDIV.
6785
6786 2018-05-04  Tom Tromey  <tom@tromey.com>
6787
6788         * configure: Rebuild.
6789         * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
6790
6791 2018-05-04  Tom Tromey  <tom@tromey.com>
6792
6793         * linux-record.c (record_linux_system_call) <case
6794         RECORD_SYS_RECVFROM>: Add "break".
6795
6796 2018-05-04  Tom Tromey  <tom@tromey.com>
6797
6798         * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
6799         Add missing "break".
6800         * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
6801         Add missing "break".
6802
6803 2018-05-04  Tom Tromey  <tom@tromey.com>
6804
6805         * rs6000-tdep.c (ppc_process_record_op4)
6806         (ppc_process_record_op63): Add fall-through comment.
6807
6808 2018-05-04  Tom Tromey  <tom@tromey.com>
6809
6810         * i386-tdep.c (i386_process_record): Add fall-through comment.
6811
6812 2018-05-04  Tom Tromey  <tom@tromey.com>
6813
6814         * stabsread.c (define_symbol) <case 'p'>: Add fall-through
6815         comment.
6816
6817 2018-05-04  Tom Tromey  <tom@tromey.com>
6818
6819         * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
6820         * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
6821         * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
6822         comment.
6823         * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
6824         comment.
6825         * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
6826         comment.
6827
6828 2018-05-04  Tom Tromey  <tom@tromey.com>
6829
6830         * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
6831
6832 2018-05-04  Tom Tromey  <tom@tromey.com>
6833
6834         * s390-tdep.c (s390_process_record): Fix fall-through comments.
6835         * xcoffread.c (scan_xcoff_symtab): Move comment later.
6836         * symfile.c (section_is_mapped): Fix fall-through comment.
6837         * stabsread.c (define_symbol, read_member_functions): Fix
6838         fall-through comment.
6839         * s390-linux-tdep.c (s390_process_record): Fix fall-through
6840         comment.
6841         * remote.c (remote_wait_as): Fix fall-through comment.
6842         * p-exp.y (yylex): Fix fall-through comment.
6843         * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
6844         comment.
6845         * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
6846         * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
6847         * jv-exp.y (yylex): Fix fall-through comment.
6848         * go-exp.y (lex_one_token): Fix fall-through comment.
6849         * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
6850         fall-through comment.
6851         * f-exp.y (yylex): Fix fall-through comment.
6852         * dwarf2read.c (process_die): Fix fall-through comments.
6853         * dbxread.c (process_one_symbol): Fix fall-through comment.
6854         * d-exp.y (lex_one_token): Fix fall-through comment.
6855         * cp-name-parser.y (yylex): Fix fall-through comment.
6856         * coffread.c (coff_symtab_read): Fix fall-through comment.
6857         * c-exp.y (lex_one_token): Fix fall-through comment.
6858         * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
6859         comment.
6860         * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
6861         comment.
6862
6863 2018-05-04  Tom Tromey  <tom@tromey.com>
6864
6865         PR python/22730:
6866         * NEWS: Mention gdb.execute change.
6867         * gdbcmd.h (execute_control_command): Don't declare.
6868         * python/python.c (execute_gdb_command): Use read_command_lines_1,
6869         execute_control_commands, execute_control_commands_to_string.
6870         * cli/cli-script.h (execute_control_commands)
6871         (execute_control_commands_to_string): Declare.
6872         (execute_control_command): Add from_tty parameter.
6873         * cli/cli-script.c (execute_control_commands)
6874         (execute_control_commands_to_string): New functions.
6875         (execute_user_command): Use execute_control_commands.
6876         (execute_control_command_1): Add "from_tty" parameter.  Update.
6877         (execute_control_command): Likewise.
6878
6879 2018-05-04  Tom Tromey  <tom@tromey.com>
6880
6881         PR python/22731:
6882         * NEWS: Mention that breakpoint commands are writable.
6883         * python/py-breakpoint.c (bppy_set_commands): New function.
6884         (breakpoint_object_getset) <"commands">: Use it.
6885
6886 2018-05-04  Tom Tromey  <tom@tromey.com>
6887
6888         * tracepoint.c (actions_command): Update.
6889         * mi/mi-cmd-break.c (mi_command_line_array)
6890         (mi_command_line_array_cnt, mi_command_line_array_ptr)
6891         (mi_read_next_line): Remove.
6892         (mi_cmd_break_commands): Update.
6893         * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
6894         function_view.
6895         * cli/cli-script.c (get_command_line): Update.
6896         (process_next_line): Use function_view.  Constify.
6897         (recurse_read_control_structure, read_command_lines)
6898         (read_command_lines_1): Change argument types to function_view.
6899         (do_define_command, document_command): Update.
6900         * breakpoint.h (check_tracepoint_command): Don't declare.
6901         * breakpoint.c (check_tracepoint_command): Remove.
6902         (commands_command_1, create_tracepoint_from_upload): Update.
6903
6904 2018-05-04  Tom Tromey  <tom@tromey.com>
6905
6906         PR gdb/11750:
6907         * cli/cli-script.h (enum command_control_type) <define_control>:
6908         New constant.
6909         * cli/cli-script.c (multi_line_command_p): Handle define_control.
6910         (build_command_line, execute_control_command_1)
6911         (process_next_line): Likewise.
6912         (do_define_command): New function, extracted from define_command.
6913         (define_command): Use it.
6914
6915 2018-05-04  Tom Tromey  <tom@tromey.com>
6916
6917         * tracepoint.c (actions_command): Update.
6918         * cli/cli-script.h (read_command_lines): Update.
6919         * cli/cli-script.c (read_command_lines): Constify prompt_arg.
6920         (MAX_TMPBUF): Remove define.
6921         (define_command): Use string_printf.
6922         (document_command): Likewise.
6923         * breakpoint.c (commands_command_1): Update.
6924
6925 2018-05-04  Tom Tromey  <tom@tromey.com>
6926
6927         * top.c (execute_command): Update.
6928         * cli/cli-script.h (print_command_lines): Now varargs.
6929         * cli/cli-script.c (print_command_lines): Now varargs.
6930         (execute_control_command_1) <case while_control, case if_control>:
6931         Update.
6932
6933 2018-05-04  Tom Tromey  <tom@tromey.com>
6934
6935         * tracepoint.c (all_tracepoint_actions): Rename from
6936         all_tracepoint_actions_and_cleanup.  Change return type.
6937         (actions_command, encode_actions_1, encode_actions)
6938         (trace_dump_actions, tdump_command): Update.
6939         * remote.c (remote_download_command_source): Update.
6940         * python/python.c (gdbpy_eval_from_control_command)
6941         (python_command, python_interactive_command): Update.
6942         * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
6943         * guile/guile.c (guile_command)
6944         (gdbscm_eval_from_control_command, guile_command): Update.
6945         * compile/compile.c (compile_code_command)
6946         (compile_print_command, compile_to_object): Update.
6947         * cli/cli-script.h (struct command_lines_deleter): New.
6948         (counted_command_line): New typedef.
6949         (struct command_line): Add constructor, destructor.
6950         <body_list>: Remove.
6951         <body_list_0, body_list_1>: New members.
6952         (command_line_up): Remove typedef.
6953         (read_command_lines, read_command_lines_1, get_command_line):
6954         Update.
6955         (copy_command_lines): Don't declare.
6956         * cli/cli-script.c (build_command_line): Use "new".
6957         (get_command_line): Return counted_command_line.
6958         (print_command_lines, execute_user_command)
6959         (execute_control_command_1, while_command, if_command): Update.
6960         (realloc_body_list): Remove.
6961         (process_next_line, recurse_read_control_structure): Update.
6962         (read_command_lines, read_command_lines_1): Return counted_command_line.
6963         (free_command_lines): Use "delete".
6964         (copy_command_lines): Remove.
6965         (define_command, document_command, show_user_1): Update.
6966         * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
6967         a counted_command_line.
6968         * breakpoint.h (counted_command_line): Remove typedef.
6969         (breakpoint_set_commands): Update.
6970         * breakpoint.c (check_no_tracepoint_commands)
6971         (validate_commands_for_breakpoint): Update.
6972         (breakpoint_set_commands): Change commands to be a
6973         counted_command_line.
6974         (commands_command_1, update_dprintf_command_list)
6975         (create_tracepoint_from_upload): Update.
6976
6977 2018-05-04  Tom Tromey  <tom@tromey.com>
6978
6979         * cli/cli-decode.h (cmd_list_element): New constructor.
6980         (~cmd_list_element): New destructor.
6981         (struct cmd_list_element): Add initializers.
6982         * cli/cli-decode.c (do_add_cmd): Use "new".
6983         (delete_cmd): Use "delete".
6984
6985 2018-05-04  Jan Kratochvil  <jan.kratochvil@redhat.com>
6986             Pedro Alves <palves@redhat.com>
6987
6988         PR breakpoints/19806 and support for PR external/20207.
6989         * NEWS: Mention Aarch64 watchpoint improvements.
6990         * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
6991         watchpoints and PR external/20207 watchpoints.
6992         * nat/aarch64-linux-hw-point.c
6993         (kernel_supports_any_contiguous_range): New.
6994         (aarch64_watchpoint_offset): New.
6995         (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
6996         (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
6997         (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
6998         (aarch64_align_watchpoint): New parameters aligned_offset_p and
6999         next_addr_orig_p.  Support PR external/20207 watchpoints.
7000         (aarch64_downgrade_regs): New.
7001         (aarch64_dr_state_insert_one_point): New parameters offset and
7002         addr_orig.
7003         (aarch64_dr_state_remove_one_point): Likewise.
7004         (aarch64_handle_breakpoint): Update caller.
7005         (aarch64_handle_aligned_watchpoint): Likewise.
7006         (aarch64_handle_unaligned_watchpoint): Support addr_orig and
7007         aligned_offset.
7008         (aarch64_linux_set_debug_regs): Remove const from state.  Call
7009         aarch64_downgrade_regs.
7010         (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
7011         * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
7012         (DR_CONTROL_MASK): ... this.
7013         (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
7014         (unsigned int aarch64_watchpoint_offset): New prototype.
7015         (aarch64_linux_set_debug_regs): Remove const from state.
7016         * utils.c (align_up, align_down): Move to ...
7017         * common/common-utils.c (align_up, align_down): ... here.
7018         * utils.h (align_up, align_down): Move to ...
7019         * common/common-utils.h (align_up, align_down): ... here.
7020
7021 2018-05-04  Joel Brobecker  <brobecker@adacore.com>
7022
7023         * sparc-tdep.c (sparc_structure_return_p): Re-implement to
7024         match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
7025         (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
7026         Re-implement to match the ABI as summarized in GCC's
7027         gcc/config/sparc/sparc.c.  All callers updated.
7028         (sparc32_store_arguments): Remove assertion.
7029
7030 2018-05-04  Tom Tromey  <tom@tromey.com>
7031
7032         * printcmd.c: Don't include tui.h.
7033         (decode_format): Use skip_spaces.
7034
7035 2018-05-04  Tom Tromey  <tom@tromey.com>
7036
7037         PR gdb/22619:
7038         * printcmd.c (last_count): New global.
7039         (x_command): Use saved count when repeating.
7040
7041 2018-05-04  Tom Tromey  <tom@tromey.com>
7042
7043         * nto-procfs.c (do_closedir_cleanup): Remove.
7044         (procfs_pidlist): Use gdb_dir_up.
7045         * procfs.c (do_closedir_cleanup): Remove.
7046         (proc_update_threads): Use gdb_dir_up.
7047         * common/filestuff.h (struct gdb_dir_deleter): New.
7048         (gdb_dir_up): New typedef.
7049
7050 2018-05-04  Tom Tromey  <tom@tromey.com>
7051
7052         * ada-lang.c (print_mention_exception): Use std::string.
7053
7054 2018-05-04  Tom Tromey  <tom@tromey.com>
7055
7056         * ada-lang.c (create_excep_cond_exprs): Update.
7057         (ada_exception_catchpoint_cond_string): Use std::string.
7058
7059 2018-05-04  Tom Tromey  <tom@tromey.com>
7060
7061         * ada-lang.c (xget_renaming_scope): Return std::string.
7062         (old_renaming_is_invisible): Update.
7063
7064 2018-05-04  Tom Tromey  <tom@tromey.com>
7065
7066         * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
7067         (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
7068
7069 2018-05-04  Ulrich Weigand  <uweigand@de.ibm.com>
7070
7071         * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
7072
7073 2018-05-04  Tom Tromey  <tom@tromey.com>
7074
7075         * remote.c (remote_query_supported_append): Change type.
7076         (remote_check_symbols): Update.
7077
7078 2018-05-04  Paul Pluzhnikov  <ppluzhnikov@google.com>
7079
7080         PR gdb/11420
7081         * configure.ac: Prepend libpython.
7082         * python/python-config.py: Likewise.
7083         * configure: Regenerate.
7084
7085 2018-05-03  Simon Marchi  <simon.marchi@ericsson.com>
7086
7087         * Makefile.in (%.c: %.l): Use -t instead of --stdout.
7088
7089 2018-05-03  Pedro Alves  <palves@redhat.com>
7090
7091         * s390-linux-nat.c
7092         (s390_linux_nat_target::have_continuable_watchpoint): Mark with
7093         override.  Write 'true' instead of '1'.
7094         (s390_linux_nat_target::watchpoint_addr_within_range): Remove
7095         declaration.
7096
7097 2018-05-02  Pedro Alves  <palves@redhat.com>
7098
7099         * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
7100         add_inf_child_target.
7101         * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
7102         add_inf_child_target.
7103         * aix-thread.c (aix_thread_target_info): New.
7104         (aix_thread_target) <shortname, longname, doc>: Delete.
7105         <info>: New.
7106         * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
7107         add_inf_child_target.
7108         * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
7109         add_inf_child_target.
7110         * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
7111         add_inf_child_target.
7112         * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
7113         add_inf_child_target.
7114         * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
7115         add_inf_child_target.
7116         * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
7117         add_inf_child_target.
7118         * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
7119         add_inf_child_target.
7120         * arm-linux-nat.c (_initialize_arm_linux_nat): Use
7121         add_inf_child_target.
7122         * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
7123         add_inf_child_target.
7124         * bfd-target.c (target_bfd_target_info): New.
7125         (target_bfd) <shortname, longname, doc>: Delete.
7126         <info>: New.
7127         * bsd-kvm.c (bsd_kvm_target_info): New.
7128         (bsd_kvm_target) <shortname, longname, doc>: Delete.
7129         <info>: New.
7130         (bsd_kvm_target::open): Rename to ...
7131         (bsd_kvm_target_open): ... this.  Adjust.
7132         * bsd-uthread.c (bsd_uthread_target_info): New.
7133         (bsd_uthread_target) <shortname, longname, doc>: Delete.
7134         <info>: New.
7135         * corefile.c (core_file_command): Adjust.
7136         * corelow.c (core_target_info): New.
7137         (core_target) <shortname, longname, doc>: Delete.
7138         <info>: New.
7139         (core_target::open): Rename to ...
7140         (core_target_open): ... this.  Adjust.
7141         * ctf.c (ctf_target_info): New.
7142         (ctf_target) <shortname, longname, doc>: Delete.
7143         <info>: New.
7144         (ctf_target::open): Rename to ...
7145         (ctf_target_open): ... this.
7146         (_initialize_ctf): Adjust.
7147         * exec.c (exec_target_info): New.
7148         (exec_target) <shortname, longname, doc>: Delete.
7149         <info>: New.
7150         (exec_target::open): Rename to ...
7151         (exec_target_open): ... this.
7152         * gdbcore.h (core_target_open): Declare.
7153         * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
7154         * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
7155         add_inf_child_target.
7156         * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
7157         add_inf_child_target.
7158         * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
7159         add_inf_child_target.
7160         * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
7161         add_inf_child_target.
7162         * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
7163         add_inf_child_target.
7164         * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
7165         add_inf_child_target.
7166         * i386-linux-nat.c (_initialize_i386_linux_nat): Use
7167         add_inf_child_target.
7168         * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
7169         add_inf_child_target.
7170         * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
7171         add_inf_child_target.
7172         * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
7173         add_inf_child_target.
7174         * inf-child.c (inf_child_target_info): New.
7175         (inf_child_target::info): New.
7176         (inf_child_open_target): Remove 'target' parameter.  Use
7177         get_native_target instead.
7178         (inf_child_target::open): Delete.
7179         (add_inf_child_target): New.
7180         * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
7181         Delete.
7182         <info>: New.
7183         (add_inf_child_target): Declare.
7184         (inf_child_open_target): Declare.
7185         * linux-thread-db.c (thread_db_target_info): New.
7186         (thread_db_target) <shortname, longname, doc>: Delete.
7187         <info>: New.
7188         * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
7189         add_inf_child_target.
7190         * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
7191         add_inf_child_target.
7192         * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
7193         add_inf_child_target.
7194         * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
7195         add_inf_child_target.
7196         * make-target-delegates (print_class): Adjust.
7197         * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
7198         add_inf_child_target.
7199         * mips-linux-nat.c (_initialize_mips_linux_nat): Use
7200         add_inf_child_target.
7201         * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
7202         add_inf_child_target.
7203         * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
7204         add_inf_child_target.
7205         * nto-procfs.c (nto_native_target_info): New.
7206         (nto_procfs_target_native) <shortname, longname, doc>:
7207         Delete.
7208         <info>: New.
7209         (nto_procfs_target_info): New.
7210         (nto_procfs_target_procfs) <shortname, longname, doc>:
7211         Delete.
7212         <info>: New.
7213         (init_procfs_targets): Adjust.
7214         * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
7215         add_inf_child_target.
7216         * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
7217         add_inf_child_target.
7218         * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
7219         add_inf_child_target.
7220         * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
7221         add_inf_child_target.
7222         * ravenscar-thread.c (ravenscar_target_info): New.
7223         (ravenscar_thread_target) <shortname, longname, doc>:
7224         Delete.
7225         <info>: New.
7226         * record-btrace.c (record_btrace_target_info):
7227         (record_btrace_target) <shortname, longname, doc>: Delete.
7228         <info>: New.
7229         (record_btrace_target::open): Rename to ...
7230         (record_btrace_target_open): ... this.  Adjust.
7231         * record-full.c (record_longname, record_doc): New.
7232         (record_full_base_target) <shortname, longname, doc>: Delete.
7233         <info>: New.
7234         (record_full_target_info): New.
7235         (record_full_target): <shortname>: Delete.
7236         <info>: New.
7237         (record_full_core_open_1, record_full_open_1): Update comments.
7238         (record_full_base_target::open): Rename to ...
7239         (record_full_open): ... this.
7240         (cmd_record_full_restore): Update.
7241         (_initialize_record_full): Update.
7242         * remote-sim.c (remote_sim_target_info): New.
7243         (gdbsim_target) <shortname, longname, doc>: Delete.
7244         <info>: New.
7245         (gdbsim_target::open): Rename to ...
7246         (gdbsim_target_open): ... this.
7247         (_initialize_remote_sim): Adjust.
7248         * remote.c (remote_doc): New.
7249         (remote_target_info): New.
7250         (remote_target) <shortname, longname, doc>: Delete.
7251         <info>: New.
7252         (extended_remote_target_info): New.
7253         (extended_remote_target) <shortname, longname, doc>: Delete.
7254         <info>: New.
7255         (remote_target::open_1): Make static.  Adjust.
7256         * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
7257         * s390-linux-nat.c (_initialize_s390_nat): Use
7258         add_inf_child_target.
7259         * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
7260         add_inf_child_target.
7261         * sol-thread.c (thread_db_target_info): New.
7262         (sol_thread_target) <shortname, longname, doc>: Delete.
7263         <info>: New.
7264         * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
7265         add_inf_child_target.
7266         * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
7267         add_inf_child_target.
7268         * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
7269         add_inf_child_target.
7270         * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
7271         add_inf_child_target.
7272         * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
7273         add_inf_child_target.
7274         * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
7275         add_inf_child_target.
7276         * spu-linux-nat.c (_initialize_spu_nat): Use
7277         add_inf_child_target.
7278         * spu-multiarch.c (spu_multiarch_target_info): New.
7279         (spu_multiarch_target) <shortname, longname, doc>: Delete.
7280         <info>: New.
7281         * target-delegates.c: Regenerate.
7282         * target.c: Include <unordered_map>.
7283         (target_ops_p): Delete.
7284         (DEF_VEC_P(target_ops_p)): Delete.
7285         (target_factories): New.
7286         (test_target_info): New.
7287         (test_target_ops::info): New.
7288         (open_target): Adjust to use target_factories.
7289         (add_target_with_completer): Rename to ...
7290         (add_target): ... this.  Change prototype.  Register target_info
7291         and open callback in target_factories.  Register target_info in
7292         command context instead of target_ops.
7293         (add_target): Delete old implementation.
7294         (add_deprecated_target_alias): Change prototype.  Adjust.
7295         (the_native_target): New.
7296         (set_native_target, get_native_target): New.
7297         (find_default_run_target): Use the_native_target.
7298         (find_attach_target, find_run_target): Simplify.
7299         (target_ops::open): Delete.
7300         (dummy_target_info): New.
7301         (dummy_target::shortname, dummy_target::longname)
7302         (dummy_target::doc): Delete.
7303         (dummy_target::info): New.
7304         (debug_target::shortname, debug_target::longname)
7305         (debug_target::doc): Delete.
7306         (debug_target::info): New.
7307         * target.h (struct target_info): New.
7308         (target_ops::~target_ops): Add comment.
7309         (target_ops::info): New.
7310         (target_ops::shortname, target_ops::longname, target_ops::doc): No
7311         longer virtual.  Implement in terms of target_info.
7312         (set_native_target, get_native_target): Declare.
7313         (target_open_ftype): New.
7314         (add_target, add_target_with_completer)
7315         (add_deprecated_target_alias): Change prototype.
7316         (test_target) <shortname, longname, doc>: Delete.
7317         <info>: New.
7318         * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
7319         add_inf_child_target.
7320         * tracefile-tfile.c (tfile_target_info): New.
7321         (tfile_target) <shortname, longname, doc>: Delete.
7322         <info>: New.
7323         (tfile_target::open): Rename to ...
7324         (tfile_target_open): ... this.
7325         (_initialize_tracefile_tfile): Adjust.
7326         * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
7327         add_inf_child_target.
7328         * windows-nat.c (_initialize_windows_nat): Use
7329         add_inf_child_target.
7330         * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
7331         add_inf_child_target.
7332
7333 2018-05-02  Pedro Alves  <palves@redhat.com>
7334
7335         * linux-nat.h (linux_nat_target) <low_new_thread,
7336         low_delete_thread, low_new_fork, low_forget_process,
7337         low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
7338         New virtual methods.
7339         (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7340         (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
7341         (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
7342         (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7343         (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
7344         Delete.
7345         * linux-fork.c (delete_fork): Adjust to call low method.
7346         * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
7347         (linux_nat_new_fork, linux_nat_forget_process_hook)
7348         (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
7349         (linux_nat_status_is_event):
7350         (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
7351         (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
7352         to call low method.
7353         (sigtrap_is_event): Rename to ...
7354         (linux_nat_target::low_status_is_event): ... this.
7355         (linux_nat_set_status_is_event): Delete.
7356         (save_stop_reason, linux_nat_wait_1)
7357         (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
7358         low methods.
7359         (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7360         (linux_nat_set_new_fork, linux_nat_set_forget_process)
7361         (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7362         (linux_nat_set_prepare_to_resume): Delete.
7363         * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
7364         low virtual methods.
7365         * amd64-linux-nat.c: Likewise.
7366         * arm-linux-nat.c: Likewise.
7367         * i386-linux-nat.c: Likewise.
7368         * ia64-linux-nat.c: Likewise.
7369         * mips-linux-nat.c: Likewise.
7370         * ppc-linux-nat.c: Likewise.
7371         * s390-linux-nat.c: Likewise.
7372         * sparc64-linux-nat.c: Likewise.
7373         * x86-linux-nat.c: Likewise.
7374         * x86-linux-nat.h: Include "nat/x86-linux.h".
7375         (x86_linux_nat_target) <low_new_fork, low_forget_process,
7376         low_prepare_to_resume, low_new_thread, low_delete_thread>:
7377         Override methods.
7378
7379 2018-05-02  Pedro Alves  <palves@redhat.com>
7380
7381         * target.h (target_ops)
7382         <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
7383         stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
7384         stopped_by_watchpoint, have_continuable_watchpoint,
7385         stopped_data_address, watchpoint_addr_within_range,
7386         can_accel_watchpoint_condition, can_run, thread_alive,
7387         has_all_memory, has_memory, has_stack, has_registers,
7388         has_execution, can_async_p, is_async_p, supports_non_stop,
7389         always_non_stop_p, can_execute_reverse, supports_multi_process,
7390         supports_enable_disable_tracepoint,
7391         supports_disable_randomization, supports_string_tracing,
7392         supports_evaluation_of_breakpoint_conditions,
7393         can_run_breakpoint_commands, filesystem_is_local,
7394         can_download_tracepoint, get_trace_state_variable_value,
7395         set_trace_notes, get_tib_address, use_agent, can_use_agent,
7396         record_is_replaying, record_will_replay,
7397         augmented_libraries_svr4_read>: Adjust to return bool.
7398         * aarch64-linux-nat.c: All implementations adjusted.
7399         * aix-thread.c: All implementations adjusted.
7400         * arm-linux-nat.c: All implementations adjusted.
7401         * breakpoint.c: All implementations adjusted.
7402         * bsd-kvm.c: All implementations adjusted.
7403         * bsd-uthread.c: All implementations adjusted.
7404         * corelow.c: All implementations adjusted.
7405         * ctf.c: All implementations adjusted.
7406         * darwin-nat.c: All implementations adjusted.
7407         * darwin-nat.h: All implementations adjusted.
7408         * exec.c: All implementations adjusted.
7409         * fbsd-nat.c: All implementations adjusted.
7410         * fbsd-nat.h: All implementations adjusted.
7411         * gnu-nat.c: All implementations adjusted.
7412         * gnu-nat.h: All implementations adjusted.
7413         * go32-nat.c: All implementations adjusted.
7414         * ia64-linux-nat.c: All implementations adjusted.
7415         * inf-child.c: All implementations adjusted.
7416         * inf-child.h: All implementations adjusted.
7417         * inf-ptrace.c: All implementations adjusted.
7418         * inf-ptrace.h: All implementations adjusted.
7419         * linux-nat.c: All implementations adjusted.
7420         * linux-nat.h: All implementations adjusted.
7421         * mips-linux-nat.c: All implementations adjusted.
7422         * nto-procfs.c: All implementations adjusted.
7423         * ppc-linux-nat.c: All implementations adjusted.
7424         * procfs.c: All implementations adjusted.
7425         * ravenscar-thread.c: All implementations adjusted.
7426         * record-btrace.c: All implementations adjusted.
7427         * record-full.c: All implementations adjusted.
7428         * remote-sim.c: All implementations adjusted.
7429         * remote.c: All implementations adjusted.
7430         * s390-linux-nat.c: All implementations adjusted.
7431         * sol-thread.c: All implementations adjusted.
7432         * spu-multiarch.c: All implementations adjusted.
7433         * target-delegates.c: All implementations adjusted.
7434         * target.c: All implementations adjusted.
7435         * target.h: All implementations adjusted.
7436         * tracefile-tfile.c: All implementations adjusted.
7437         * tracefile.c: All implementations adjusted.
7438         * tracefile.h: All implementations adjusted.
7439         * windows-nat.c: All implementations adjusted.
7440         * x86-linux-nat.h: All implementations adjusted.
7441         * x86-nat.h: All implementations adjusted.
7442
7443 2018-05-02  Pedro Alves  <palves@redhat.com>
7444
7445         * make-target-delegates (scan_target_h): Don't trim lines here.
7446         Replace sequences of tabs and/or whitespace with a single
7447         whitespace.
7448         (top level, parsing methods): Trim each line before processing it
7449         here.
7450
7451 2018-05-02  Pedro Alves  <palves@redhat.com>
7452             John Baldwin  <jhb@freebsd.org>
7453
7454         * target.h (enum strata) <debug_stratum>: New.
7455         (struct target_ops) <all delegation methods>: Replace by C++
7456         virtual methods, and drop "to_" prefix.  All references updated
7457         throughout.
7458         <to_shortname, to_longname, to_doc, to_data,
7459         to_have_steppable_watchpoint, to_have_continuable_watchpoint,
7460         to_has_thread_control, to_attach_no_wait>: Delete, replaced by
7461         virtual methods.  All references updated throughout.
7462         <can_attach, supports_terminal_ours, can_create_inferior,
7463         get_thread_control_capabilities, attach_no_wait>: New
7464         virtual methods.
7465         <insert_breakpoint, remove_breakpoint>: Now
7466         TARGET_DEFAULT_NORETURN methods.
7467         <info_proc>: Now returns bool.
7468         <to_magic>: Delete.
7469         (OPS_MAGIC): Delete.
7470         (current_target): Delete.  All references replaced by references
7471         to ...
7472         (target_stack): ... this.  New.
7473         (target_shortname, target_longname): Adjust.
7474         (target_can_run): Now a function declaration.
7475         (default_child_has_all_memory, default_child_has_memory)
7476         (default_child_has_stack, default_child_has_registers)
7477         (default_child_has_execution): Remove target_ops parameter.
7478         (complete_target_initialization): Delete.
7479         (memory_breakpoint_target): New template class.
7480         (test_target_ops): Refactor as a C++ class with virtual methods.
7481         * make-target-delegates (NAME_PART): Tighten.
7482         (POINTER_PART, CP_SYMBOL): New.
7483         (SIMPLE_RETURN_PART): Reimplement.
7484         (VEC_RETURN_PART): Expect less.
7485         (RETURN_PART, VIRTUAL_PART): New.
7486         (METHOD): Adjust to C++ virtual methods.
7487         (scan_target_h): Remove reference to C99.
7488         (dname): Output "target_ops::" prefix.
7489         (write_function_header): Adjust to output a C++ class method.
7490         (write_declaration): New.
7491         (write_delegator): Adjust to output a C++ class method.
7492         (tdname): Output "dummy_target::" prefix.
7493         (write_tdefault, write_debugmethod): Adjust to output a C++ class
7494         method.
7495         (tdefault_names, debug_names): Delete.
7496         (return_types, tdefaults, styles, argtypes_array): New.
7497         (top level): All methods are delegators.
7498         (print_class): New.
7499         (top level): Print dummy_target and debug_target classes.
7500         * target-delegates.c: Regenerate.
7501         * target-debug.h (target_debug_print_enum_info_proc_what)
7502         (target_debug_print_thread_control_capabilities)
7503         (target_debug_print_thread_info_p): New.
7504         * target.c (dummy_target): Delete.
7505         (the_dummy_target, the_debug_target): New.
7506         (target_stack): Now extern.
7507         (set_targetdebug): Push/unpush debug target.
7508         (default_child_has_all_memory, default_child_has_memory)
7509         (default_child_has_stack, default_child_has_registers)
7510         (default_child_has_execution): Remove target_ops parameter.
7511         (complete_target_initialization): Delete.
7512         (add_target_with_completer): No longer call
7513         complete_target_initialization.
7514         (target_supports_terminal_ours): Use regular delegation.
7515         (update_current_target): Delete.
7516         (push_target): No longer check magic number.  Don't call
7517         update_current_target.
7518         (unpush_target): Don't call update_current_target.
7519         (target_is_pushed): No longer check magic number.
7520         (target_require_runnable): Skip for all stratums over
7521         process_stratum.
7522         (target_ops::info_proc): New.
7523         (target_info_proc): Use find_target_at and
7524         find_default_run_target.
7525         (target_supports_disable_randomization): Use regular delegation.
7526         (target_get_osdata): Use find_target_at.
7527         (target_ops::open, target_ops::close, target_ops::can_attach)
7528         (target_ops::attach, target_ops::can_create_inferior)
7529         (target_ops::create_inferior, target_ops::can_run)
7530         (target_can_run): New.
7531         (default_fileio_target): Use regular delegation.
7532         (target_ops::fileio_open, target_ops::fileio_pwrite)
7533         (target_ops::fileio_pread, target_ops::fileio_fstat)
7534         (target_ops::fileio_close, target_ops::fileio_unlink)
7535         (target_ops::fileio_readlink): New.
7536         (target_fileio_open_1, target_fileio_unlink)
7537         (target_fileio_readlink): Always call the target method.  Handle
7538         FILEIO_ENOSYS.
7539         (return_zero, return_zero_has_execution): Delete.
7540         (init_dummy_target): Delete.
7541         (dummy_target::dummy_target, dummy_target::shortname)
7542         (dummy_target::longname, dummy_target::doc)
7543         (debug_target::debug_target, debug_target::shortname)
7544         (debug_target::longname, debug_target::doc): New.
7545         (target_supports_delete_record): Use regular delegation.
7546         (setup_target_debug): Delete.
7547         (maintenance_print_target_stack): Skip debug_stratum.
7548         (initialize_targets): Instantiate the_dummy_target and
7549         the_debug_target.
7550         * auxv.c (target_auxv_parse): Remove 'ops' parameter.  Adjust to
7551         use target_stack.
7552         (target_auxv_search, fprint_target_auxv): Adjust.
7553         (info_auxv_command): Adjust to use target_stack.
7554         * auxv.h (target_auxv_parse): Remove 'ops' parameter.
7555         * exceptions.c (print_flush): Handle a NULL target_stack.
7556         * regcache.c (target_ops_no_register): Refactor as class with
7557         virtual methods.
7558
7559         * exec.c (exec_target): New class.
7560         (exec_ops): Now an exec_target.
7561         (exec_open, exec_close_1, exec_get_section_table)
7562         (exec_xfer_partial, exec_files_info, exec_has_memory)
7563         (exec_make_note_section): Refactor as exec_target methods.
7564         (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
7565         Delete.
7566         (exec_target::find_memory_regions): New.
7567         (_initialize_exec): Don't call init_exec_ops.
7568         * gdbcore.h (exec_file_clear): Delete.
7569
7570         * corefile.c (core_target): Delete.
7571         (core_file_command): Adjust.
7572         * corelow.c (core_target): New class.
7573         (the_core_target): New.
7574         (core_close): Remove target_ops parameter.
7575         (core_close_cleanup): Adjust.
7576         (core_target::close): New.
7577         (core_open, core_detach, get_core_registers, core_files_info)
7578         (core_xfer_partial, core_thread_alive, core_read_description)
7579         (core_pid_to_str, core_thread_name, core_has_memory)
7580         (core_has_stack, core_has_registers, core_info_proc): Rework as
7581         core_target methods.
7582         (ignore, core_remove_breakpoint, init_core_ops): Delete.
7583         (_initialize_corelow): Initialize the_core_target.
7584         * gdbcore.h (core_target): Delete.
7585         (the_core_target): New.
7586
7587         * ctf.c: (ctf_target): New class.
7588         (ctf_ops): Now a ctf_target.
7589         (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
7590         (ctf_xfer_partial, ctf_get_trace_state_variable_value)
7591         (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
7592         methods.
7593         (init_ctf_ops): Delete.
7594         (_initialize_ctf): Don't call it.
7595         * tracefile-tfile.c (tfile_target): New class.
7596         (tfile_ops): Now a tfile_target.
7597         (tfile_open, tfile_close, tfile_files_info)
7598         (tfile_get_tracepoint_status, tfile_trace_find)
7599         (tfile_fetch_registers, tfile_xfer_partial)
7600         (tfile_get_trace_state_variable_value, tfile_traceframe_info):
7601         Refactor as tfile_target methods.
7602         (tfile_xfer_partial_features): Remove target_ops parameter.
7603         (init_tfile_ops): Delete.
7604         (_initialize_tracefile_tfile): Don't call it.
7605         * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
7606         (tracefile_has_stack, tracefile_has_registers)
7607         (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
7608         tracefile_target methods.
7609         (init_tracefile_ops): Delete.
7610         (tracefile_target::tracefile_target): New.
7611         * tracefile.h: Include "target.h".
7612         (tracefile_target): New class.
7613         (init_tracefile_ops): Delete.
7614
7615         * spu-multiarch.c (spu_multiarch_target): New class.
7616         (spu_ops): Now a spu_multiarch_target.
7617         (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
7618         (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
7619         (spu_search_memory, spu_mourn_inferior): Refactor as
7620         spu_multiarch_target methods.
7621         (init_spu_ops): Delete.
7622         (_initialize_spu_multiarch): Remove references to init_spu_ops,
7623         complete_target_initialization.
7624
7625         * ravenscar-thread.c (ravenscar_thread_target): New class.
7626         (ravenscar_ops): Now a ravenscar_thread_target.
7627         (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
7628         (ravenscar_thread_alive, ravenscar_pid_to_str)
7629         (ravenscar_fetch_registers, ravenscar_store_registers)
7630         (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
7631         (ravenscar_stopped_by_hw_breakpoint)
7632         (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
7633         (ravenscar_mourn_inferior, ravenscar_core_of_thread)
7634         (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
7635         methods.
7636         (init_ravenscar_thread_ops): Delete.
7637         (_initialize_ravenscar): Remove references to
7638         init_ravenscar_thread_ops and complete_target_initialization.
7639
7640         * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
7641         (bsd_uthread_target): New class.
7642         (bsd_uthread_ops): Now a bsd_uthread_target.
7643         (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
7644         (bsd_uthread_close, bsd_uthread_mourn_inferior)
7645         (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
7646         (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
7647         (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
7648         (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
7649         (bsd_uthread_target): Delete function.
7650         (_initialize_bsd_uthread): Remove reference to
7651         complete_target_initialization.
7652
7653         * bfd-target.c (target_bfd_data): Delete.  Fields folded into ...
7654         (target_bfd): ... this new class.
7655         (target_bfd_xfer_partial, target_bfd_get_section_table)
7656         (target_bfd_close): Refactor as target_bfd methods.
7657         (target_bfd::~target_bfd): New.
7658         (target_bfd_reopen): Adjust.
7659         (target_bfd::close): New.
7660
7661         * record-btrace.c (record_btrace_target): New class.
7662         (record_btrace_ops): Now a record_btrace_target.
7663         (record_btrace_open, record_btrace_stop_recording)
7664         (record_btrace_disconnect, record_btrace_close)
7665         (record_btrace_async, record_btrace_info)
7666         (record_btrace_insn_history, record_btrace_insn_history_range)
7667         (record_btrace_insn_history_from, record_btrace_call_history)
7668         (record_btrace_call_history_range)
7669         (record_btrace_call_history_from, record_btrace_record_method)
7670         (record_btrace_is_replaying, record_btrace_will_replay)
7671         (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
7672         (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
7673         (record_btrace_store_registers, record_btrace_prepare_to_store)
7674         (record_btrace_to_get_unwinder)
7675         (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
7676         (record_btrace_commit_resume, record_btrace_wait)
7677         (record_btrace_stop, record_btrace_can_execute_reverse)
7678         (record_btrace_stopped_by_sw_breakpoint)
7679         (record_btrace_supports_stopped_by_sw_breakpoint)
7680         (record_btrace_stopped_by_hw_breakpoint)
7681         (record_btrace_supports_stopped_by_hw_breakpoint)
7682         (record_btrace_update_thread_list, record_btrace_thread_alive)
7683         (record_btrace_goto_begin, record_btrace_goto_end)
7684         (record_btrace_goto, record_btrace_stop_replaying_all)
7685         (record_btrace_execution_direction)
7686         (record_btrace_prepare_to_generate_core)
7687         (record_btrace_done_generating_core): Refactor as
7688         record_btrace_target methods.
7689         (init_record_btrace_ops): Delete.
7690         (_initialize_record_btrace): Remove reference to
7691         init_record_btrace_ops.
7692         * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
7693         the execution_direction global.
7694         (record_full_base_target, record_full_target)
7695         (record_full_core_target): New classes.
7696         (record_full_ops): Now a record_full_target.
7697         (record_full_core_ops): Now a record_full_core_target.
7698         (record_full_target::detach, record_full_target::disconnect)
7699         (record_full_core_target::disconnect)
7700         (record_full_target::mourn_inferior, record_full_target::kill):
7701         New.
7702         (record_full_open, record_full_close, record_full_async): Refactor
7703         as methods of the record_full_base_target class.
7704         (record_full_resume, record_full_commit_resume): Refactor
7705         as methods of the record_full_target class.
7706         (record_full_wait, record_full_stopped_by_watchpoint)
7707         (record_full_stopped_data_address)
7708         (record_full_stopped_by_sw_breakpoint)
7709         (record_full_supports_stopped_by_sw_breakpoint)
7710         (record_full_stopped_by_hw_breakpoint)
7711         (record_full_supports_stopped_by_hw_breakpoint): Refactor as
7712         methods of the record_full_base_target class.
7713         (record_full_store_registers, record_full_xfer_partial)
7714         (record_full_insert_breakpoint, record_full_remove_breakpoint):
7715         Refactor as methods of the record_full_target class.
7716         (record_full_can_execute_reverse, record_full_get_bookmark)
7717         (record_full_goto_bookmark, record_full_execution_direction)
7718         (record_full_record_method, record_full_info, record_full_delete)
7719         (record_full_is_replaying, record_full_will_replay)
7720         (record_full_goto_begin, record_full_goto_end, record_full_goto)
7721         (record_full_stop_replaying): Refactor as methods of the
7722         record_full_base_target class.
7723         (record_full_core_resume, record_full_core_kill)
7724         (record_full_core_fetch_registers)
7725         (record_full_core_prepare_to_store)
7726         (record_full_core_store_registers, record_full_core_xfer_partial)
7727         (record_full_core_insert_breakpoint)
7728         (record_full_core_remove_breakpoint)
7729         (record_full_core_has_execution): Refactor
7730         as methods of the record_full_core_target class.
7731         (record_full_base_target::supports_delete_record): New.
7732         (init_record_full_ops): Delete.
7733         (init_record_full_core_ops): Delete.
7734         (record_full_save): Refactor as method of the
7735         record_full_base_target class.
7736         (_initialize_record_full): Remove references to
7737         init_record_full_ops and init_record_full_core_ops.
7738
7739         * remote.c (remote_target, extended_remote_target): New classes.
7740         (remote_ops): Now a remote_target.
7741         (extended_remote_ops): Now an extended_remote_target.
7742         (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
7743         (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
7744         (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
7745         (remote_pass_signals, remote_set_syscall_catchpoint)
7746         (remote_program_signals, )
7747         (remote_thread_always_alive): Remove target_ops parameter.
7748         (remote_thread_alive, remote_thread_name)
7749         (remote_update_thread_list, remote_threads_extra_info)
7750         (remote_static_tracepoint_marker_at)
7751         (remote_static_tracepoint_markers_by_strid)
7752         (remote_get_ada_task_ptid, remote_close, remote_start_remote)
7753         (remote_open): Refactor as methods of remote_target.
7754         (extended_remote_open, extended_remote_detach)
7755         (extended_remote_attach, extended_remote_post_attach):
7756         (extended_remote_supports_disable_randomization)
7757         (extended_remote_create_inferior): : Refactor as method of
7758         extended_remote_target.
7759         (remote_set_permissions, remote_open_1, remote_detach)
7760         (remote_follow_fork, remote_follow_exec, remote_disconnect)
7761         (remote_resume, remote_commit_resume, remote_stop)
7762         (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
7763         (remote_terminal_ours, remote_wait, remote_fetch_registers)
7764         (remote_prepare_to_store, remote_store_registers)
7765         (remote_flash_erase, remote_flash_done, remote_files_info)
7766         (remote_kill, remote_mourn, remote_insert_breakpoint)
7767         (remote_remove_breakpoint, remote_insert_watchpoint)
7768         (remote_watchpoint_addr_within_range)
7769         (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
7770         (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
7771         (remote_supports_stopped_by_sw_breakpoint)
7772         (remote_stopped_by_hw_breakpoint)
7773         (remote_supports_stopped_by_hw_breakpoint)
7774         (remote_stopped_by_watchpoint, remote_stopped_data_address)
7775         (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
7776         (remote_verify_memory): Refactor as methods of remote_target.
7777         (remote_write_qxfer, remote_read_qxfer): Remove target_ops
7778         parameter.
7779         (remote_xfer_partial, remote_get_memory_xfer_limit)
7780         (remote_search_memory, remote_rcmd, remote_memory_map)
7781         (remote_pid_to_str, remote_get_thread_local_address)
7782         (remote_get_tib_address, remote_read_description): Refactor as
7783         methods of remote_target.
7784         (remote_target::fileio_open, remote_target::fileio_pwrite)
7785         (remote_target::fileio_pread, remote_target::fileio_close): New.
7786         (remote_hostio_readlink, remote_hostio_fstat)
7787         (remote_filesystem_is_local, remote_can_execute_reverse)
7788         (remote_supports_non_stop, remote_supports_disable_randomization)
7789         (remote_supports_multi_process, remote_supports_cond_breakpoints)
7790         (remote_supports_enable_disable_tracepoint)
7791         (remote_supports_string_tracing)
7792         (remote_can_run_breakpoint_commands, remote_trace_init)
7793         (remote_download_tracepoint, remote_can_download_tracepoint)
7794         (remote_download_trace_state_variable, remote_enable_tracepoint)
7795         (remote_disable_tracepoint, remote_trace_set_readonly_regions)
7796         (remote_trace_start, remote_get_trace_status)
7797         (remote_get_tracepoint_status, remote_trace_stop)
7798         (remote_trace_find, remote_get_trace_state_variable_value)
7799         (remote_save_trace_data, remote_get_raw_trace_data)
7800         (remote_set_disconnected_tracing, remote_core_of_thread)
7801         (remote_set_circular_trace_buffer, remote_traceframe_info)
7802         (remote_get_min_fast_tracepoint_insn_len)
7803         (remote_set_trace_buffer_size, remote_set_trace_notes)
7804         (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
7805         (remote_disable_btrace, remote_teardown_btrace)
7806         (remote_read_btrace, remote_btrace_conf)
7807         (remote_augmented_libraries_svr4_read, remote_load)
7808         (remote_pid_to_exec_file, remote_can_do_single_step)
7809         (remote_execution_direction, remote_thread_handle_to_thread_info):
7810         Refactor as methods of remote_target.
7811         (init_remote_ops, init_extended_remote_ops): Delete.
7812         (remote_can_async_p, remote_is_async_p, remote_async)
7813         (remote_thread_events, remote_upload_tracepoints)
7814         (remote_upload_trace_state_variables): Refactor as methods of
7815         remote_target.
7816         (_initialize_remote): Remove references to init_remote_ops and
7817         init_extended_remote_ops.
7818
7819         * remote-sim.c (gdbsim_target): New class.
7820         (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
7821         (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
7822         (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
7823         (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
7824         (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
7825         (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
7826         Refactor as methods of gdbsim_target.
7827         (gdbsim_ops): Now a gdbsim_target.
7828         (init_gdbsim_ops): Delete.
7829         (gdbsim_cntrl_c): Adjust.
7830         (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
7831
7832         * amd64-linux-nat.c (amd64_linux_nat_target): New class.
7833         (the_amd64_linux_nat_target): New.
7834         (amd64_linux_fetch_inferior_registers)
7835         (amd64_linux_store_inferior_registers): Refactor as methods of
7836         amd64_linux_nat_target.
7837         (_initialize_amd64_linux_nat): Adjust.  Set linux_target.
7838         * i386-linux-nat.c: Don't include "linux-nat.h".
7839         (i386_linux_nat_target): New class.
7840         (the_i386_linux_nat_target): New.
7841         (i386_linux_fetch_inferior_registers)
7842         (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
7843         as methods of i386_linux_nat_target.
7844         (_initialize_i386_linux_nat): Adjust.  Set linux_target.
7845         * inf-child.c (inf_child_ops): Delete.
7846         (inf_child_fetch_inferior_registers)
7847         (inf_child_store_inferior_registers): Delete.
7848         (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
7849         methods of inf_child_target.
7850         (inf_child_target::supports_terminal_ours)
7851         (inf_child_target::terminal_init)
7852         (inf_child_target::terminal_inferior)
7853         (inf_child_target::terminal_ours_for_output)
7854         (inf_child_target::terminal_ours, inf_child_target::interrupt)
7855         (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
7856         New.
7857         (inf_child_open, inf_child_disconnect, inf_child_close)
7858         (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
7859         (inf_child_post_startup_inferior, inf_child_can_run)
7860         (inf_child_pid_to_exec_file): Refactor as methods of
7861         inf_child_target.
7862         (inf_child_follow_fork): Delete.
7863         (inf_child_target::can_create_inferior)
7864         (inf_child_target::can_attach): New.
7865         (inf_child_target::has_all_memory, inf_child_target::has_memory)
7866         (inf_child_target::has_stack, inf_child_target::has_registers)
7867         (inf_child_target::has_execution): New.
7868         (inf_child_fileio_open, inf_child_fileio_pwrite)
7869         (inf_child_fileio_pread, inf_child_fileio_fstat)
7870         (inf_child_fileio_close, inf_child_fileio_unlink)
7871         (inf_child_fileio_readlink, inf_child_use_agent)
7872         (inf_child_can_use_agent): Refactor as methods of
7873         inf_child_target.
7874         (return_zero, inf_child_target): Delete.
7875         (inf_child_target::inf_child_target): New.
7876         * inf-child.h: Include "target.h".
7877         (inf_child_target): Delete function prototype.
7878         (inf_child_target): New class.
7879         (inf_child_open_target, inf_child_mourn_inferior)
7880         (inf_child_maybe_unpush_target): Delete.
7881         * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
7882         (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
7883         (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
7884         (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
7885         (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
7886         (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
7887         (inf_ptrace_wait, inf_ptrace_xfer_partial)
7888         (inf_ptrace_thread_alive, inf_ptrace_files_info)
7889         (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
7890         methods of inf_ptrace_target.
7891         (inf_ptrace_target): Delete function.
7892         * inf-ptrace.h: Include "inf-child.h".
7893         (inf_ptrace_target): Delete function declaration.
7894         (inf_ptrace_target): New class.
7895         (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
7896         * linux-nat.c (linux_target): New.
7897         (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
7898         (linux_nat_target::~linux_nat_target): New.
7899         (linux_child_post_attach, linux_child_post_startup_inferior)
7900         (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
7901         (linux_child_remove_fork_catchpoint)
7902         (linux_child_insert_vfork_catchpoint)
7903         (linux_child_remove_vfork_catchpoint)
7904         (linux_child_insert_exec_catchpoint)
7905         (linux_child_remove_exec_catchpoint)
7906         (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
7907         (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
7908         (linux_nat_resume, linux_nat_stopped_by_watchpoint)
7909         (linux_nat_stopped_data_address)
7910         (linux_nat_stopped_by_sw_breakpoint)
7911         (linux_nat_supports_stopped_by_sw_breakpoint)
7912         (linux_nat_stopped_by_hw_breakpoint)
7913         (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
7914         (linux_nat_kill, linux_nat_mourn_inferior)
7915         (linux_nat_xfer_partial, linux_nat_thread_alive)
7916         (linux_nat_update_thread_list, linux_nat_pid_to_str)
7917         (linux_nat_thread_name, linux_child_pid_to_exec_file)
7918         (linux_child_static_tracepoint_markers_by_strid)
7919         (linux_nat_is_async_p, linux_nat_can_async_p)
7920         (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
7921         (linux_nat_supports_multi_process)
7922         (linux_nat_supports_disable_randomization, linux_nat_async)
7923         (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
7924         (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
7925         (linux_nat_fileio_open, linux_nat_fileio_readlink)
7926         (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
7927         methods of linux_nat_target.
7928         (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
7929         (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
7930         parameter.
7931         (check_stopped_by_watchpoint): Adjust.
7932         (linux_xfer_partial): Delete.
7933         (linux_target_install_ops, linux_target, linux_nat_add_target):
7934         Delete.
7935         (linux_nat_target::linux_nat_target): New.
7936         * linux-nat.h: Include "inf-ptrace.h".
7937         (linux_nat_target): New.
7938         (linux_target, linux_target_install_ops, linux_nat_add_target):
7939         Delete function declarations.
7940         (linux_target): Declare global.
7941         * linux-thread-db.c (thread_db_target): New.
7942         (thread_db_target::thread_db_target): New.
7943         (thread_db_ops): Delete.
7944         (the_thread_db_target): New.
7945         (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
7946         (thread_db_update_thread_list, thread_db_pid_to_str)
7947         (thread_db_extra_thread_info)
7948         (thread_db_thread_handle_to_thread_info)
7949         (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
7950         (thread_db_resume): Refactor as methods of thread_db_target.
7951         (init_thread_db_ops): Delete.
7952         (_initialize_thread_db): Remove reference to init_thread_db_ops.
7953         * x86-linux-nat.c: Don't include "linux-nat.h".
7954         (super_post_startup_inferior): Delete.
7955         (x86_linux_nat_target::~x86_linux_nat_target): New.
7956         (x86_linux_child_post_startup_inferior)
7957         (x86_linux_read_description, x86_linux_enable_btrace)
7958         (x86_linux_disable_btrace, x86_linux_teardown_btrace)
7959         (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
7960         methods of x86_linux_nat_target.
7961         (x86_linux_create_target): Delete.  Bits folded ...
7962         (x86_linux_add_target): ... here.  Now takes a linux_nat_target
7963         pointer.
7964         * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
7965         (x86_linux_nat_target): New class.
7966         (x86_linux_create_target): Delete.
7967         (x86_linux_add_target): Now takes a linux_nat_target pointer.
7968         * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
7969         (x86_region_ok_for_watchpoint, x86_stopped_data_address)
7970         (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
7971         (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
7972         (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
7973         make extern.
7974         (x86_use_watchpoints): Delete.
7975         * x86-nat.h: Include "breakpoint.h" and "target.h".
7976         (x86_use_watchpoints): Delete.
7977         (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
7978         (x86_stopped_by_watchpoint, x86_stopped_data_address)
7979         (x86_insert_watchpoint, x86_remove_watchpoint)
7980         (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
7981         (x86_stopped_by_hw_breakpoint): New declarations.
7982         (x86_nat_target): New template class.
7983
7984         * ppc-linux-nat.c (ppc_linux_nat_target): New class.
7985         (the_ppc_linux_nat_target): New.
7986         (ppc_linux_fetch_inferior_registers)
7987         (ppc_linux_can_use_hw_breakpoint)
7988         (ppc_linux_region_ok_for_hw_watchpoint)
7989         (ppc_linux_ranged_break_num_registers)
7990         (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
7991         (ppc_linux_insert_mask_watchpoint)
7992         (ppc_linux_remove_mask_watchpoint)
7993         (ppc_linux_can_accel_watchpoint_condition)
7994         (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
7995         (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
7996         (ppc_linux_watchpoint_addr_within_range)
7997         (ppc_linux_masked_watch_num_registers)
7998         (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
7999         (ppc_linux_read_description): Refactor as methods of
8000         ppc_linux_nat_target.
8001         (_initialize_ppc_linux_nat): Adjust.  Set linux_target.
8002
8003         * procfs.c (procfs_xfer_partial): Delete forward declaration.
8004         (procfs_target): New class.
8005         (the_procfs_target): New.
8006         (procfs_target): Delete function.
8007         (procfs_auxv_parse, procfs_attach, procfs_detach)
8008         (procfs_fetch_registers, procfs_store_registers, procfs_wait)
8009         (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
8010         (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
8011         (procfs_create_inferior, procfs_update_thread_list)
8012         (procfs_thread_alive, procfs_pid_to_str)
8013         (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
8014         (procfs_stopped_data_address, procfs_insert_watchpoint)
8015         (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
8016         (proc_find_memory_regions, procfs_info_proc)
8017         (procfs_make_note_section): Refactor as methods of procfs_target.
8018         (_initialize_procfs): Adjust.
8019         * sol-thread.c (sol_thread_target): New class.
8020         (sol_thread_ops): Now a sol_thread_target.
8021         (sol_thread_detach, sol_thread_resume, sol_thread_wait)
8022         (sol_thread_fetch_registers, sol_thread_store_registers)
8023         (sol_thread_xfer_partial, sol_thread_mourn_inferior)
8024         (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
8025         (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
8026         (init_sol_thread_ops): Delete.
8027         (_initialize_sol_thread): Adjust.  Remove references to
8028         init_sol_thread_ops and complete_target_initialization.
8029
8030         * windows-nat.c (windows_nat_target): New class.
8031         (windows_fetch_inferior_registers)
8032         (windows_store_inferior_registers, windows_resume, windows_wait)
8033         (windows_attach, windows_detach, windows_pid_to_exec_file)
8034         (windows_files_info, windows_create_inferior)
8035         (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
8036         (windows_close, windows_pid_to_str, windows_xfer_partial)
8037         (windows_get_tib_address, windows_get_ada_task_ptid)
8038         (windows_thread_name, windows_thread_alive): Refactor as
8039         windows_nat_target methods.
8040         (do_initial_windows_stuff): Adjust.
8041         (windows_target): Delete function.
8042         (_initialize_windows_nat): Adjust.
8043
8044         * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
8045         (darwin_mourn_inferior, darwin_kill_inferior)
8046         (darwin_create_inferior, darwin_attach, darwin_detach)
8047         (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
8048         (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
8049         (darwin_supports_multi_process): Refactor as darwin_nat_target
8050         methods.
8051         (darwin_resume_to, darwin_files_info): Delete.
8052         (_initialize_darwin_inferior): Rename to ...
8053         (_initialize_darwin_nat): ... this.  Adjust to C++ification.
8054         * darwin-nat.h: Include "inf-child.h".
8055         (darwin_nat_target): New class.
8056         (darwin_complete_target): Delete.
8057         * i386-darwin-nat.c (i386_darwin_nat_target): New class.
8058         (darwin_target): New.
8059         (i386_darwin_fetch_inferior_registers)
8060         (i386_darwin_store_inferior_registers): Refactor as methods of
8061         darwin_nat_target.
8062         (darwin_complete_target): Delete, with ...
8063         (_initialize_i386_darwin_nat): ... bits factored out here.
8064
8065         * alpha-linux-nat.c (alpha_linux_nat_target): New class.
8066         (the_alpha_linux_nat_target): New.
8067         (alpha_linux_register_u_offset): Refactor as
8068         alpha_linux_nat_target method.
8069         (_initialize_alpha_linux_nat): Adjust.
8070         * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
8071         (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8072         (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
8073         methods of linux_nat_trad_target.
8074         (linux_trad_target): Delete.
8075         * linux-nat-trad.h (linux_trad_target): Delete function.
8076         (linux_nat_trad_target): New class.
8077         * mips-linux-nat.c (mips_linux_nat_target): New class.
8078         (super_fetch_registers, super_store_registers, super_close):
8079         Delete.
8080         (the_mips_linux_nat_target): New.
8081         (mips64_linux_regsets_fetch_registers)
8082         (mips64_linux_regsets_store_registers)
8083         (mips64_linux_fetch_registers, mips64_linux_store_registers)
8084         (mips_linux_register_u_offset, mips_linux_read_description)
8085         (mips_linux_can_use_hw_breakpoint)
8086         (mips_linux_stopped_by_watchpoint)
8087         (mips_linux_stopped_data_address)
8088         (mips_linux_region_ok_for_hw_watchpoint)
8089         (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
8090         (mips_linux_close): Refactor as methods of mips_linux_nat.
8091         (_initialize_mips_linux_nat): Adjust to C++ification.
8092
8093         * aix-thread.c (aix_thread_target): New class.
8094         (aix_thread_ops): Now an aix_thread_target.
8095         (aix_thread_detach, aix_thread_resume, aix_thread_wait)
8096         (aix_thread_fetch_registers, aix_thread_store_registers)
8097         (aix_thread_xfer_partial, aix_thread_mourn_inferior)
8098         (aix_thread_thread_alive, aix_thread_pid_to_str)
8099         (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
8100         Refactor as methods of aix_thread_target.
8101         (init_aix_thread_ops): Delete.
8102         (_initialize_aix_thread): Remove references to init_aix_thread_ops
8103         and complete_target_initialization.
8104         * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
8105         (rs6000_nat_target): New class.
8106         (the_rs6000_nat_target): New.
8107         (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
8108         (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
8109         (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
8110         (super_create_inferior): Delete.
8111         (_initialize_rs6000_nat): Adjust to C++ification.
8112
8113         * arm-linux-nat.c (arm_linux_nat_target): New class.
8114         (the_arm_linux_nat_target): New.
8115         (arm_linux_fetch_inferior_registers)
8116         (arm_linux_store_inferior_registers, arm_linux_read_description)
8117         (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
8118         (arm_linux_remove_hw_breakpoint)
8119         (arm_linux_region_ok_for_hw_watchpoint)
8120         (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
8121         (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
8122         (arm_linux_watchpoint_addr_within_range): Refactor as methods of
8123         arm_linux_nat_target.
8124         (_initialize_arm_linux_nat): Adjust to C++ification.
8125
8126         * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
8127         (the_aarch64_linux_nat_target): New.
8128         (aarch64_linux_fetch_inferior_registers)
8129         (aarch64_linux_store_inferior_registers)
8130         (aarch64_linux_child_post_startup_inferior)
8131         (aarch64_linux_read_description)
8132         (aarch64_linux_can_use_hw_breakpoint)
8133         (aarch64_linux_insert_hw_breakpoint)
8134         (aarch64_linux_remove_hw_breakpoint)
8135         (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
8136         (aarch64_linux_region_ok_for_hw_watchpoint)
8137         (aarch64_linux_stopped_data_address)
8138         (aarch64_linux_stopped_by_watchpoint)
8139         (aarch64_linux_watchpoint_addr_within_range)
8140         (aarch64_linux_can_do_single_step): Refactor as methods of
8141         aarch64_linux_nat_target.
8142         (super_post_startup_inferior): Delete.
8143         (_initialize_aarch64_linux_nat): Adjust to C++ification.
8144
8145         * hppa-linux-nat.c (hppa_linux_nat_target): New class.
8146         (the_hppa_linux_nat_target): New.
8147         (hppa_linux_fetch_inferior_registers)
8148         (hppa_linux_store_inferior_registers): Refactor as methods of
8149         hppa_linux_nat_target.
8150         (_initialize_hppa_linux_nat): Adjust to C++ification.
8151
8152         * ia64-linux-nat.c (ia64_linux_nat_target): New class.
8153         (the_ia64_linux_nat_target): New.
8154         (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
8155         (ia64_linux_stopped_data_address)
8156         (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
8157         (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
8158         ia64_linux_nat_target methods.
8159         (super_xfer_partial): Delete.
8160         (_initialize_ia64_linux_nat): Adjust to C++ification.
8161
8162         * m32r-linux-nat.c (m32r_linux_nat_target): New class.
8163         (the_m32r_linux_nat_target): New.
8164         (m32r_linux_fetch_inferior_registers)
8165         (m32r_linux_store_inferior_registers): Refactor as
8166         m32r_linux_nat_target methods.
8167         (_initialize_m32r_linux_nat): Adjust to C++ification.
8168
8169         * m68k-linux-nat.c (m68k_linux_nat_target): New class.
8170         (the_m68k_linux_nat_target): New.
8171         (m68k_linux_fetch_inferior_registers)
8172         (m68k_linux_store_inferior_registers): Refactor as
8173         m68k_linux_nat_target methods.
8174         (_initialize_m68k_linux_nat): Adjust to C++ification.
8175
8176         * s390-linux-nat.c (s390_linux_nat_target): New class.
8177         (the_s390_linux_nat_target): New.
8178         (s390_linux_fetch_inferior_registers)
8179         (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
8180         (s390_insert_watchpoint, s390_remove_watchpoint)
8181         (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
8182         (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
8183         (s390_auxv_parse, s390_read_description): Refactor as methods of
8184         s390_linux_nat_target.
8185         (_initialize_s390_nat): Adjust to C++ification.
8186
8187         * sparc-linux-nat.c (sparc_linux_nat_target): New class.
8188         (the_sparc_linux_nat_target): New.
8189         (_initialize_sparc_linux_nat): Adjust to C++ification.
8190         * sparc-nat.c (sparc_fetch_inferior_registers)
8191         (sparc_store_inferior_registers): Remove target_ops parameter.
8192         * sparc-nat.h (sparc_fetch_inferior_registers)
8193         (sparc_store_inferior_registers): Remove target_ops parameter.
8194         * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
8195         (the_sparc64_linux_nat_target): New.
8196         (_initialize_sparc64_linux_nat): Adjust to C++ification.
8197
8198         * spu-linux-nat.c (spu_linux_nat_target): New class.
8199         (the_spu_linux_nat_target): New.
8200         (spu_child_post_startup_inferior, spu_child_post_attach)
8201         (spu_child_wait, spu_fetch_inferior_registers)
8202         (spu_store_inferior_registers, spu_xfer_partial)
8203         (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
8204         methods.
8205         (_initialize_spu_nat): Adjust to C++ification.
8206
8207         * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
8208         (the_tilegx_linux_nat_target): New.
8209         (fetch_inferior_registers, store_inferior_registers):
8210         Refactor as methods.
8211         (_initialize_tile_linux_nat): Adjust to C++ification.
8212
8213         * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
8214         (the_xtensa_linux_nat_target): New.
8215         (xtensa_linux_fetch_inferior_registers)
8216         (xtensa_linux_store_inferior_registers): Refactor as
8217         xtensa_linux_nat_target methods.
8218         (_initialize_xtensa_linux_nat): Adjust to C++ification.
8219
8220         * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
8221         (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
8222         (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
8223         (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
8224         (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
8225         (fbsd_stopped_by_sw_breakpoint)
8226         (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
8227         (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
8228         (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
8229         (fbsd_post_startup_inferior, fbsd_post_attach)
8230         (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
8231         (fbsd_set_syscall_catchpoint)
8232         (super_xfer_partial, super_resume, super_wait)
8233         (fbsd_supports_stopped_by_hw_breakpoint): Delete.
8234         (fbsd_handle_debug_trap): Remove target_ops parameter.
8235         (fbsd_nat_add_target): Delete.
8236         * fbsd-nat.h: Include "inf-ptrace.h".
8237         (fbsd_nat_add_target): Delete.
8238         (USE_SIGTRAP_SIGINFO): Define.
8239         (fbsd_nat_target): New class.
8240
8241         * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
8242         (amd64bsd_store_inferior_registers): Remove target_ops parameter.
8243         (amd64bsd_target): Delete.
8244         * amd64-bsd-nat.h: New file.
8245         * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
8246         "x86-bsd-nat.h".
8247         (amd64_fbsd_nat_target): New class.
8248         (the_amd64_fbsd_nat_target): New.
8249         (amd64fbsd_read_description): Refactor as method of
8250         amd64_fbsd_nat_target.
8251         (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8252         (_initialize_amd64fbsd_nat): Adjust to C++ification.
8253         * amd64-nat.h (amd64bsd_target): Delete function declaration.
8254         * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
8255         (i386bsd_store_inferior_registers): Remove target_ops parameter.
8256         (i386bsd_target): Delete.
8257         * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
8258         (i386bsd_fetch_inferior_registers)
8259         (i386bsd_store_inferior_registers): Declare.
8260         (i386_bsd_nat_target): New class.
8261         * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
8262         (the_i386_fbsd_nat_target): New.
8263         (i386fbsd_resume, i386fbsd_read_description): Refactor as
8264         i386_fbsd_nat_target methods.
8265         (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8266         (_initialize_i386fbsd_nat): Adjust to C++ification.
8267         * x86-bsd-nat.c (super_mourn_inferior): Delete.
8268         (x86bsd_mourn_inferior, x86bsd_target): Delete.
8269         (_initialize_x86_bsd_nat): Adjust to C++ification.
8270         * x86-bsd-nat.h: Include "x86-nat.h".
8271         (x86bsd_target): Delete declaration.
8272         (x86bsd_nat_target): New class.
8273
8274         * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
8275         (the_aarch64_fbsd_nat_target): New.
8276         (aarch64_fbsd_fetch_inferior_registers)
8277         (aarch64_fbsd_store_inferior_registers): Refactor as methods of
8278         aarch64_fbsd_nat_target.
8279         (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
8280         * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
8281         (the_alpha_bsd_nat_target): New.
8282         (alphabsd_fetch_inferior_registers)
8283         (alphabsd_store_inferior_registers): Refactor as
8284         alpha_bsd_nat_target methods.
8285         (_initialize_alphabsd_nat): Refactor as methods of
8286         alpha_bsd_nat_target.
8287         * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
8288         (the_amd64_nbsd_nat_target): New.
8289         (_initialize_amd64nbsd_nat): Adjust to C++ification.
8290         * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
8291         (the_amd64_obsd_nat_target): New.
8292         (_initialize_amd64obsd_nat): Adjust to C++ification.
8293         * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
8294         (the_arm_fbsd_nat_target): New.
8295         (arm_fbsd_fetch_inferior_registers)
8296         (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
8297         (_initialize_arm_fbsd_nat): Refactor as methods of
8298         arm_fbsd_nat_target.
8299         (_initialize_arm_fbsd_nat): Adjust to C++ification.
8300         * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
8301         (the_arm_netbsd_nat_target): New.
8302         (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
8303         arm_netbsd_nat_target.
8304         (_initialize_arm_netbsd_nat): Adjust to C++ification.
8305         * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
8306         (the_hppa_nbsd_nat_target): New.
8307         (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
8308         hppa_nbsd_nat_target methods.
8309         (_initialize_hppanbsd_nat): Adjust to C++ification.
8310         * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
8311         (the_hppa_obsd_nat_target): New.
8312         (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
8313         methods of hppa_obsd_nat_target.
8314         (_initialize_hppaobsd_nat): Adjust to C++ification.  Use
8315         add_target.
8316         * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
8317         (_initialize_i386nbsd_nat): Adjust to C++ification.  Use
8318         add_target.
8319         * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
8320         (_initialize_i386obsd_nat): Use add_target.
8321         * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
8322         (the_m68k_bsd_nat_target): New.
8323         (m68kbsd_fetch_inferior_registers)
8324         (m68kbsd_store_inferior_registers): Refactor as methods of
8325         m68k_bsd_nat_target.
8326         (_initialize_m68kbsd_nat): Adjust to C++ification.
8327         * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
8328         (the_mips_fbsd_nat_target): New.
8329         (mips_fbsd_fetch_inferior_registers)
8330         (mips_fbsd_store_inferior_registers): Refactor as methods of
8331         mips_fbsd_nat_target.
8332         (_initialize_mips_fbsd_nat): Adjust to C++ification.  Use
8333         add_target.
8334         * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
8335         (the_mips_nbsd_nat_target): New.
8336         (mipsnbsd_fetch_inferior_registers)
8337         (mipsnbsd_store_inferior_registers): Refactor as methods of
8338         mips_nbsd_nat_target.
8339         (_initialize_mipsnbsd_nat): Adjust to C++ification.
8340         * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
8341         (the_mips64_obsd_nat_target): New.
8342         (mips64obsd_fetch_inferior_registers)
8343         (mips64obsd_store_inferior_registers): Refactor as methods of
8344         mips64_obsd_nat_target.
8345         (_initialize_mips64obsd_nat): Adjust to C++ification.  Use
8346         add_target.
8347         * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
8348         nbsd_nat_target.
8349         * nbsd-nat.h: Include "inf-ptrace.h".
8350         (nbsd_nat_target): New class.
8351         * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
8352         (obsd_wait): Refactor as methods of obsd_nat_target.
8353         (obsd_add_target): Delete.
8354         * obsd-nat.h: Include "inf-ptrace.h".
8355         (obsd_nat_target): New class.
8356         * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
8357         (the_ppc_fbsd_nat_target): New.
8358         (ppcfbsd_fetch_inferior_registers)
8359         (ppcfbsd_store_inferior_registers): Refactor as methods of
8360         ppc_fbsd_nat_target.
8361         (_initialize_ppcfbsd_nat): Adjust to C++ification.  Use
8362         add_target.
8363         * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
8364         (the_ppc_nbsd_nat_target): New.
8365         (ppcnbsd_fetch_inferior_registers)
8366         (ppcnbsd_store_inferior_registers): Refactor as methods of
8367         ppc_nbsd_nat_target.
8368         (_initialize_ppcnbsd_nat): Adjust to C++ification.
8369         * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
8370         (the_ppc_obsd_nat_target): New.
8371         (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
8372         methods of ppc_obsd_nat_target.
8373         (_initialize_ppcobsd_nat): Adjust to C++ification.  Use
8374         add_target.
8375         * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
8376         (the_sh_nbsd_nat_target): New.
8377         (shnbsd_fetch_inferior_registers)
8378         (shnbsd_store_inferior_registers): Refactor as methods of
8379         sh_nbsd_nat_target.
8380         (_initialize_shnbsd_nat): Adjust to C++ification.
8381         * sparc-nat.c (sparc_xfer_wcookie): Make extern.
8382         (inf_ptrace_xfer_partial): Delete.
8383         (sparc_xfer_partial, sparc_target): Delete.
8384         * sparc-nat.h (sparc_fetch_inferior_registers)
8385         (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
8386         (sparc_target): Delete function declaration.
8387         (sparc_target): New template class.
8388         * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
8389         (_initialize_sparcnbsd_nat): Adjust to C++ification.
8390         * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
8391         (_initialize_sparc64fbsd_nat): Adjust to C++ification.  Use
8392         add_target.
8393         * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
8394         (_initialize_sparc64nbsd_nat): Adjust to C++ification.
8395         * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
8396         (_initialize_sparc64obsd_nat): Adjust to C++ification.  Use
8397         add_target.
8398         * vax-bsd-nat.c (vax_bsd_nat_target): New class.
8399         (the_vax_bsd_nat_target): New.
8400         (vaxbsd_fetch_inferior_registers)
8401         (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
8402         methods.
8403         (_initialize_vaxbsd_nat): Adjust to C++ification.
8404
8405         * bsd-kvm.c (bsd_kvm_target): New class.
8406         (bsd_kvm_ops): Now a bsd_kvm_target.
8407         (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
8408         (bsd_kvm_files_info, bsd_kvm_fetch_registers)
8409         (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
8410         bsd_kvm_target.
8411         (bsd_kvm_return_one): Delete.
8412         (bsd_kvm_add_target): Adjust to C++ification.
8413
8414         * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
8415         (nto_procfs_target_procfs): New classes.
8416         (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
8417         (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
8418         (procfs_post_attach, procfs_wait, procfs_fetch_registers)
8419         (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
8420         (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
8421         (procfs_remove_hw_breakpoint, procfs_resume)
8422         (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
8423         (procfs_kill_inferior, procfs_store_registers)
8424         (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
8425         as methods of nto_procfs_target.
8426         (nto_procfs_ops): Now an nto_procfs_target_procfs.
8427         (nto_native_ops): Delete.
8428         (procfs_open, procfs_native_open): Delete.
8429         (nto_native_ops): Now an nto_procfs_target_native.
8430         (init_procfs_targets): Adjust to C++ification.
8431         (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
8432         (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
8433         Refactor as methods of nto_procfs_target.
8434
8435         * go32-nat.c (go32_nat_target): New class.
8436         (the_go32_nat_target): New.
8437         (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
8438         (go32_store_registers, go32_xfer_partial, go32_files_info)
8439         (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
8440         (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
8441         (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
8442         (go32_pid_to_str): Refactor as methods of go32_nat_target.
8443         (go32_target): Delete.
8444         (_initialize_go32_nat): Adjust to C++ification.
8445
8446         * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
8447         (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
8448         (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
8449         (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
8450         gnu_nat_target.
8451         (gnu_target): Delete.
8452         * gnu-nat.h (gnu_target): Delete.
8453         (gnu_nat_target): New class.
8454         * i386-gnu-nat.c (gnu_base_target): New.
8455         (i386_gnu_nat_target): New class.
8456         (the_i386_gnu_nat_target): New.
8457         (_initialize_i386gnu_nat): Adjust to C++ification.
8458
8459 2018-05-02  Pedro Alves  <palves@redhat.com>
8460
8461         * bfd-target.c (target_bfd_xclose): Rename to ...
8462         (target_bfd_close): ... this.
8463         (target_bfd_reopen): Adjust.
8464         * target.c (target_close): Remove references to to_xclose.
8465         * target.h (target_ops::to_xclose): Delete.
8466         (target_ops::to_close): Update comments.
8467
8468 2018-05-02  Pedro Alves  <palves@redhat.com>
8469
8470         * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
8471         "linux-nat.h".
8472         * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
8473         * inf-ptrace.c (inf_ptrace_register_u_offset)
8474         (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8475         (inf_ptrace_store_register, inf_ptrace_store_registers)
8476         (inf_ptrace_trad_target): Move to ...
8477         * linux-nat-trad.c: ... this new file.
8478         * linux-nat-trad.h: New file.
8479         * linux-nat.c (linux_target_install_ops): Make extern.
8480         (linux_trad_target): Delete.
8481         * linux-nat.h (linux_trad_target): Delete declaration.
8482         (linux_target_install_ops): Declare.
8483         * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
8484         "linux-nat.h".
8485
8486 2018-05-02  Pedro Alves  <palves@redhat.com>
8487
8488         * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8489         procfs_target/add_target here.
8490         * procfs.c (procfs_target): Make static.
8491         (_initialize_procfs): Call add_target here.
8492         * procfs.h (struct target_ops): Remove forward declaration.
8493         (procfs_target): Remove declaration.
8494         * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
8495
8496 2018-05-02  Pedro Alves  <palves@redhat.com>
8497
8498         * procfs.c (procfs_stopped_by_watchpoint)
8499         (procfs_insert_watchpoint, procfs_remove_watchpoint)
8500         (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
8501         Forward declare.
8502         (procfs_use_watchpoints): Delete, move contents...
8503         (procfs_target): ... here.
8504         * procfs.h (procfs_use_watchpoints): Delete declaration.
8505         * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8506         procfs_use_watchpoints.
8507         * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
8508         procfs_use_watchpoints.
8509
8510 2018-05-02  Tom Tromey  <tom@tromey.com>
8511
8512         PR python/20084:
8513         * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
8514         and var_zuinteger_unlimited.
8515         * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
8516         and PARAM_ZUINTEGER_UNLIMITED.
8517         (set_parameter_value): Handle var_zuinteger and
8518         var_zuinteger_unlimited.
8519         (add_setshow_generic): Likewise.
8520         (parmpy_init): Likewise.
8521
8522 2018-04-28  Dan Robertson  <danlrobertson89@gmail.com>
8523
8524         PR rust/23124
8525         * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
8526         pointer is not null before dereferencing it.
8527
8528 2018-04-30  Tom Tromey  <tom@tromey.com>
8529
8530         * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
8531         is_mi_like_p.
8532
8533 2018-04-30  Tom Tromey  <tom@tromey.com>
8534
8535         * breakpoint.c (mention): Remove use of is_mi_like_p.
8536         (print_mention_ranged_breakpoint): Likewise.
8537         * break-catch-throw.c (print_it_exception_catchpoint): Remove use
8538         of is_mi_like_p.
8539
8540 2018-04-30  Tom Tromey  <tom@tromey.com>
8541
8542         * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
8543
8544 2018-04-30  Tom Tromey  <tom@tromey.com>
8545
8546         * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
8547         (info_spu_event_command): Remove some uses of is_mi_like_p.
8548
8549 2018-04-30  Tom Tromey  <tom@tromey.com>
8550
8551         * python/py-framefilter.c (py_print_single_arg)
8552         (enumerate_locals, py_print_args, py_print_frame): Remove some
8553         uses of is_mi_like_p.
8554
8555 2018-04-30  Tom Tromey  <tom@tromey.com>
8556
8557         * ui-out.c: Update.
8558         * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
8559         * ui-out.h (ui_out::is_mi_like_p): Now const.
8560         (ui_out::do_is_mi_like_p): Now const.
8561         * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
8562
8563 2018-04-30  Tom Tromey  <tom@tromey.com>
8564
8565         * varobj.c (varobj_set_visualizer): Use new_reference.
8566         * python/python.c (gdbpy_decode_line): Use new_reference.
8567         * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
8568         new_reference.
8569
8570 2018-04-30  Tom Tromey  <tom@tromey.com>
8571
8572         * varobj.c (install_new_value): Use new_reference.
8573         * value.h (value_incref): Return void.  Swap intro comment with
8574         value_decref.
8575         * value.c (set_value_parent): Use new_reference.
8576         (value_incref): Return void.  Update intro comment.
8577         (release_value): Use new_reference.
8578         * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
8579
8580 2018-04-30  Tom Tromey  <tom@tromey.com>
8581
8582         * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
8583         * gdb_bfd.h (new_bfd_ref): Remove.
8584         (gdb_bfd_open): Update comment.
8585         * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
8586         (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
8587         (gdb_bfd_fdopenr): Use new_reference.
8588         * exec.c (exec_file_attach): Use new_reference.
8589
8590 2018-04-30  Tom Tromey  <tom@tromey.com>
8591
8592         * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
8593         method.
8594
8595 2018-04-30  Tom Tromey  <tom@tromey.com>
8596
8597         * jit.c (jit_read_code_entry): Use type_align.
8598         * i386-tdep.c (i386_gdbarch_init): Don't call
8599         set_gdbarch_long_long_align_bit.
8600         * gdbarch.sh: Remove long_long_align_bit.
8601         * gdbarch.c, gdbarch.h: Rebuild.
8602         * arc-tdep.c (arc_type_align): New function.
8603         (arc_gdbarch_init): Use arc_type_align.  Don't call
8604         set_gdbarch_long_long_align_bit.
8605
8606 2018-04-30  Tom Tromey  <tom@tromey.com>
8607
8608         * rust-lang.c (rust_type_alignment): Remove.
8609         (rust_composite_type): Use type_align.
8610
8611 2018-04-30  Tom Tromey  <tom@tromey.com>
8612
8613         * NEWS: Mention Type.align.
8614         * python/py-type.c (typy_get_alignof): New function.
8615         (type_object_getset): Add "alignof".
8616
8617 2018-04-30  Tom Tromey  <tom@tromey.com>
8618
8619         PR exp/17095:
8620         * NEWS: Update.
8621         * std-operator.def (UNOP_ALIGNOF): New operator.
8622         * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
8623         New.
8624         * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
8625         * c-lang.c (c_op_print_tab): Add alignof.
8626         * c-exp.y (ALIGNOF): New token.
8627         (exp): Add "ALIGNOF" production.
8628         (ident_tokens): Add _Alignof and alignof.
8629
8630 2018-04-30  Tom Tromey  <tom@tromey.com>
8631
8632         * i386-tdep.c (i386_type_align): New function.
8633         (i386_gdbarch_init): Update.
8634         * gdbarch.sh (type_align): New method.
8635         * gdbarch.c, gdbarch.h: Rebuild.
8636         * arch-utils.h (default_type_align): Declare.
8637         * arch-utils.c (default_type_align): New function.
8638         * gdbtypes.h (TYPE_ALIGN_BITS): New define.
8639         (struct type) <align_log2>: New field.
8640         <instance_flags>: Now a bitfield.
8641         (TYPE_RAW_ALIGN): New macro.
8642         (type_align, type_raw_align, set_type_align): Declare.
8643         * gdbtypes.c (type_align, type_raw_align, set_type_align): New
8644         functions.
8645         * dwarf2read.c (quirk_rust_enum): Set type alignment.
8646         (get_alignment, maybe_set_alignment): New functions.
8647         (read_structure_type, read_enumeration_type, read_array_type)
8648         (read_set_type, read_tag_pointer_type, read_tag_reference_type)
8649         (read_subrange_type, read_base_type): Set type alignment.
8650
8651 2018-04-30  Simon Marchi  <simon.marchi@ericsson.com>
8652
8653         * dwarf2read.c (read_index_from_section): Use bool.
8654
8655 2018-04-29  Fabian Groffen  <grobian@gentoo.org>
8656
8657         PR gdb/22950
8658         * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
8659         with #ifdef.
8660
8661 2018-04-29  John Reiser  <jreiser@BitWagon.com>
8662
8663         PR build/22873
8664         * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
8665         last step, and do it atomically.
8666
8667 2018-04-27  Alexandre Oliva  <aoliva@redhat.com>
8668
8669         * compile/compile-c-types.c (convert_int, convert_float):
8670         Update for C FE v1.
8671
8672 2018-04-27  Tom Tromey  <tom@tromey.com>
8673
8674         PR rust/22545:
8675         * rust-lang.c (rust_inclusive_range_type_p): New function.
8676         (rust_range): Handle inclusive ranges.
8677         (rust_compute_range): Likewise.
8678         * rust-exp.y (struct rust_op) <inclusive>: New field.
8679         (DOTDOTEQ): New constant.
8680         (range_expr): Add "..=" productions.
8681         (operator_tokens): Add "..=" token.
8682         (ast_range): Add "inclusive" parameter.
8683         (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
8684         ranges.
8685         * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
8686         bounds values.
8687         * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
8688         LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
8689         Update comments.
8690         * expprint.c (print_subexp_standard): Handle new bounds values.
8691         (dump_subexp_body_standard): Likewise.
8692
8693 2018-04-27  Tom Tromey  <tom@tromey.com>
8694
8695         * configure: Rebuild.
8696         * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
8697         * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
8698         "OVERRIDE".
8699         (class symbol_needs_eval_context): Likewise.
8700         * dwarf2read.c (mock_mapped_index::symbol_name_count)
8701         (mock_mapped_index::symbol_name_at): Use "override".  Remove
8702         "virtual".
8703         * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
8704         "override".
8705         (class dwarf_expr_executor): Use "override", not "OVERRIDE".
8706         * aarch64-tdep.c (instruction_reader::read): Use "override".
8707         (instruction_reader_test::read): Likewise.
8708         * arm-tdep.c (instruction_reader::read): Use "override".
8709         (instruction_reader_thumb::read): Likewise.
8710
8711 2018-04-26  Andrzej Kaczmarek  <andrzej.kaczmarek@codecoup.pl>
8712
8713         PR remote/9665
8714         * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
8715         instead of remote_send.
8716         (remote_send): Remove.
8717
8718 2018-04-26  Pedro Alves  <palves@redhat.com>
8719
8720         * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
8721         find_function_start_sal instead of find_pc_line.
8722
8723 2018-04-26  Pedro Alves  <palves@redhat.com>
8724
8725         * breakpoint.c (set_breakpoint_location_function): Handle
8726         mst_data_gnu_ifunc.
8727         * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
8728         * elfread.c (elf_symtab_read): Give data symbols with
8729         BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
8730         (elf_rel_plt_read): Update comment.
8731         * linespec.c (convert_linespec_to_sals): Handle
8732         mst_data_gnu_ifunc.
8733         (minsym_found): Handle mst_data_gnu_ifunc.
8734         * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
8735         (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
8736         * parse.c (find_minsym_type_and_address): Handle
8737         mst_data_gnu_ifunc.
8738         * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
8739         * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
8740         * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
8741         comment.
8742         <mst_data_gnu_ifunc>: New enumerator.
8743
8744 2018-04-26  Pedro Alves  <palves@redhat.com>
8745
8746         * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
8747         (lookup_minimal_symbol_by_pc_section): ... this.  Replace
8748         'want_trampoline' parameter by a lookup_msym_prefer parameter.
8749         Handle it.
8750         (lookup_minimal_symbol_by_pc_section): Delete old implementation.
8751         (lookup_minimal_symbol_by_pc): Adjust.
8752         (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
8753         (lookup_solib_trampoline_symbol_by_pc): Adjust.
8754         * minsyms.h (lookup_msym_prefer): New enum.
8755         (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
8756         parameter by a lookup_msym_prefer parameter.
8757
8758 2018-04-26  Pedro Alves  <palves@redhat.com>
8759
8760         * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
8761         ends in "@plt" instead of looking at the symbol's section.
8762
8763 2018-04-26  Pedro Alves  <palves@redhat.com>
8764
8765         * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete.  Remove
8766         all references.
8767         (find_pc_partial_function_gnu_ifunc): Rename to ...
8768         (find_pc_partial_function): ... this, and remove references to
8769         'is_gnu_ifunc_p'.
8770         (find_pc_partial_function): Delete old implementation.
8771         * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
8772
8773 2018-04-26  Pedro Alves  <palves@redhat.com>
8774
8775         * linespec.c (struct bound_minimal_symbol_search_key): New.
8776         (convert_linespec_to_sals): Sort minimal symbols earlier.  Don't
8777         skip first line if we found a GNU ifunc minimal symbol by name.
8778         (compare_msymbols): Change parameters to work with a destructured
8779         lhs minsym.
8780         (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
8781         functions.
8782
8783 2018-04-26  Pedro Alves  <palves@redhat.com>
8784
8785         * breakpoint.c (set_breakpoint_location_function): Don't resolve
8786         ifunc targets here.  Instead, if we have an ifunc minsym, use its
8787         address/name.
8788         (add_location_to_breakpoint): Store the minsym and the objfile in
8789         the breakpoint location.
8790         * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
8791         * linespec.c (minsym_found): Resolve GNU ifunc targets here.
8792         Record the minsym in the sal.
8793         * symtab.h (symtab_and_line) <msymbol>: New field.
8794
8795 2018-04-26  Pedro Alves  <palves@redhat.com>
8796
8797         * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
8798         unless we actually resolved the ifunc.
8799
8800 2018-04-26  Pedro Alves  <palves@redhat.com>
8801
8802         * c-exp.y (variable production): Prefer ifunc minsyms over
8803         regular function symbols.
8804         * symtab.c (find_gnu_ifunc): New function.
8805         * minsyms.h (lookup_msym_prefer): New enum.
8806         (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
8807         parameter by a lookup_msym_prefer parameter.
8808         * symtab.h (find_gnu_ifunc): New declaration.
8809
8810 2018-04-26  Pedro Alves  <palves@redhat.com>
8811
8812         * blockframe.c (find_gnu_ifunc_target_type): New function.
8813         (find_function_type): New.
8814         * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
8815         return a value with a memory address.
8816         (eval_call): For calls to GNU ifunc functions, try to find the
8817         type of the target function from the type that the resolver
8818         returns.
8819         * gdbtypes.c (objfile_type): Don't install a return type for ifunc
8820         symbols.
8821         * infcall.c (find_function_return_type): Delete.
8822         (find_function_addr): Add 'function_type' parameter.  For calls to
8823         GNU ifunc functions, try to find the type of the target function
8824         from the type that the resolver returns, and return it via
8825         FUNCTION_TYPE.
8826         (call_function_by_hand_dummy): Adjust to use the function type
8827         returned by find_function_addr.
8828         (find_function_addr): Add 'function_type' parameter and move
8829         description here.
8830         * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
8831         declarations.
8832
8833 2018-04-26  Pedro Alves  <palves@redhat.com>
8834
8835         * c-exp.y (variable production): Skip finding an alias for ifunc
8836         symbols.
8837
8838 2018-04-26  Pedro Alves  <palves@redhat.com>
8839
8840         * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
8841
8842 2018-04-25  Pedro Alves  <palves@redhat.com>
8843
8844         * infcmd.c (kill_command): Print the pid as string, not the whole
8845         thread's ptid.  Add comment.  s/has been killed/killed/ in output
8846         message.
8847         * remote.c (remote_detach_1): Print the pid as string, not the
8848         whole thread's ptid.
8849
8850 2018-04-24  Jan Kratochvil  <jan.kratochvil@redhat.com>
8851             Sergio Durigan Junior  <sergiodj@redhat.com>
8852             Pedro Alves  <palves@redhat.com>
8853
8854         * infcmd.c (kill_command): Print message when inferior has
8855         been killed.
8856         * inferior.c (print_inferior_events): Remove 'static'.  Set as
8857         '1'.
8858         (add_inferior): Improve message printed when
8859         'print_inferior_events' is on.
8860         (exit_inferior): Remove message printed when
8861         'print_inferior_events' is on.
8862         (detach_inferior): Improve message printed when
8863         'print_inferior_events' is on.
8864         (initialize_inferiors): Use 'add_inferior_silent' to set
8865         'current_inferior_'.
8866         * inferior.h (print_inferior_events): Declare here as
8867         'extern'.
8868         * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
8869         '[Detaching...]' messages when 'print_inferior_events' is on.
8870         Use 'add_thread_silent' instead of 'add_thread'.  Add '[' and ']'
8871         as prefix/suffix for messages.  Remove periods.  Fix erroneous
8872         'Detaching after fork from child...', replace it by '... from
8873         parent...'.
8874         (handle_vfork_child_exec_or_exit): Add '[' and ']' as
8875         prefix/suffix when printing 'Detaching...' messages.  Print
8876         them when 'print_inferior_events' is on.
8877         * remote.c (remote_detach_1): Print message when detaching
8878         from inferior and '!is_fork_parent'.
8879
8880 2018-04-24  Tom Tromey  <tom@tromey.com>
8881
8882         * cli-out.h: Reindent.
8883
8884 2018-04-24  Tom Tromey  <tom@tromey.com>
8885
8886         * cli-out.c (cli_ui_out::out_field_fmt): Remove.
8887         (cli_ui_out::do_field_string): Use fputs_filtered.
8888         * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
8889
8890 2018-04-23  Tom Tromey  <tom@tromey.com>
8891
8892         * guile/scm-frame.c (gdbscm_frame_read_var): Use
8893         gdb::unique_xmalloc_ptr.
8894
8895 2018-04-23  Tom Tromey  <tom@tromey.com>
8896
8897         * configure: Rebuild.
8898
8899 2018-04-22  Rajendra SY  <rajendra.sy@gmail.com>
8900
8901         PR gdb/23095
8902         * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
8903         prepare_for_testing.  Set normal_bp to r_debug_state if target
8904         is bsd.
8905
8906 2018-04-21  Pedro Alves  <palves@redhat.com>
8907             Rajendra SY  <rajendra.sy@gmail.com>
8908
8909         * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
8910         * remote.c (extended_remote_attach): In all-stop mode, mark the
8911         thread as executing.
8912
8913 2018-04-19  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
8914
8915         * thread.c (thread_apply_all_command): Fix comment.
8916         (thread_command): Fix comment.
8917
8918 2018-04-10  Alan Hayward  <alan.hayward@arm.com>
8919
8920         * common/tdesc.h (tdesc_create_feature): Remove xml filename
8921         parameter.
8922         * features/aarch64-core.c (create_feature_aarch64_core):
8923         Regenerate.
8924         * features/aarch64-fpu.c (create_feature_aarch64_fpu):
8925         Likewise.
8926         * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
8927         Likewise.
8928         * features/i386/32bit-avx512.c
8929         (create_feature_i386_32bit_avx512): Likewise.
8930         * features/i386/32bit-core.c (create_feature_i386_32bit_core):
8931         Likewise.
8932         * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
8933         Likewise.
8934         * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
8935         Likewise.
8936         * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
8937         Likewise.
8938         * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
8939         Likewise.
8940         * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
8941         Likewise.
8942         * features/i386/64bit-avx512.c
8943         (create_feature_i386_64bit_avx512): Likewise.
8944         * features/i386/64bit-core.c (create_feature_i386_64bit_core):
8945         Likewise.
8946         * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
8947         Likewise.
8948         * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
8949         Likewise.
8950         * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
8951         Likewise.
8952         * features/i386/64bit-segments.c
8953         (create_feature_i386_64bit_segments): Likewise.
8954         * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
8955         Likewise.
8956         * features/i386/x32-core.c
8957         (create_feature_i386_x32_core): Likewise.
8958         * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
8959         * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
8960         * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
8961         * target-descriptions.c: In generated code, don't pass xml
8962         filename.
8963
8964 2018-04-18  Alan Hayward  <alan.hayward@arm.com>
8965
8966         * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
8967         (print_xml_feature::visit_post): Likewise.
8968         (print_xml_feature::visit): Likewise.
8969         * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
8970         (print_xml_feature): Add new class.
8971         * regformats/regdat.sh: Null xmltarget on feature targets.
8972         * target-descriptions.c (struct target_desc): Add xmltarget.
8973         (maintenance_check_tdesc_xml_convert): Add unittest function.
8974         (tdesc_get_features_xml): Add function to get xml.
8975         (maintenance_check_xml_descriptions): Test xml generation.
8976         * xml-tdesc.c (string_read_description_xml): Add function.
8977         * xml-tdesc.h (string_read_description_xml): Add declaration.
8978
8979 2018-04-18  Alan Hayward  <alan.hayward@arm.com>
8980
8981         * features/Makefile: Add feature marker to targets with new style
8982         target descriptions.
8983         * regformats/aarch64.dat: Regenerate.
8984         * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
8985         * regformats/i386/amd64-avx-linux.dat: Likewise.
8986         * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
8987         * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
8988         * regformats/i386/amd64-linux.dat: Likewise.
8989         * regformats/i386/amd64-mpx-linux.dat: Likewise.
8990         * regformats/i386/amd64.dat: Likewise.
8991         * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
8992         * regformats/i386/i386-avx-linux.dat: Likewise.
8993         * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
8994         * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
8995         * regformats/i386/i386-linux.dat: Likewise.
8996         * regformats/i386/i386-mmx-linux.dat: Likewise.
8997         * regformats/i386/i386-mpx-linux.dat: Likewise.
8998         * regformats/i386/i386.dat: Likewise.
8999         * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
9000         * regformats/i386/x32-avx-linux.dat: Likewise.
9001         * regformats/i386/x32-linux.dat: Likewise.
9002         * regformats/tic6x-c62x-linux.dat: Likewise.
9003         * regformats/tic6x-c64x-linux.dat: Likewise.
9004         * regformats/tic6x-c64xp-linux.dat: Likewise.
9005         * regformats/regdat.sh: Parse feature marker.
9006
9007 2018-04-18  Alan Hayward  <alan.hayward@arm.com>
9008
9009         * common/tdesc.h (tdesc_architecture_name): Add new declaration.
9010         (tdesc_osabi_name): Likewise.
9011         * target-descriptions.c (tdesc_architecture_name): Add new
9012         function.
9013         (tdesc_osabi_name): Likewise.
9014
9015 2018-04-18  Alan Hayward  <alan.hayward@arm.com>
9016
9017         * common/tdesc.c (tdesc_predefined_type): Move to here.
9018         (tdesc_named_type): Likewise.
9019         (tdesc_create_vector): Likewise.
9020         (tdesc_create_struct): Likewise.
9021         (tdesc_set_struct_size): Likewise.
9022         (tdesc_create_union): Likewise.
9023         (tdesc_create_flags): Likewise.
9024         (tdesc_create_enum): Likewise.
9025         (tdesc_add_field): Likewise.
9026         (tdesc_add_typed_bitfield): Likewise.
9027         (tdesc_add_bitfield): Likewise.
9028         (tdesc_add_flag): Likewise.
9029         (tdesc_add_enum_value): Likewise.
9030         * common/tdesc.h (struct tdesc_type_builtin): Likewise.
9031         (struct tdesc_type_vector): Likewise.
9032         (struct tdesc_type_field): Likewise.
9033         (struct tdesc_type_with_fields): Likewise.
9034         (tdesc_create_enum): Add declaration.
9035         (tdesc_add_typed_bitfield): Likewise.
9036         (tdesc_add_enum_value): Likewise.
9037         * target-descriptions.c (tdesc_type_field): Move from here.
9038         (tdesc_type_builtin): Likewise.
9039         (tdesc_type_vector): Likewise.
9040         (tdesc_type_with_fields): Likewise.
9041         (tdesc_predefined_types): Likewise.
9042         (tdesc_named_type): Likewise.
9043         (tdesc_create_vector): Likewise.
9044         (tdesc_create_struct): Likewise.
9045         (tdesc_set_struct_size): Likewise.
9046         (tdesc_create_union): Likewise.
9047         (tdesc_create_flags): Likewise.
9048         (tdesc_create_enum): Likewise.
9049         (tdesc_add_field): Likewise.
9050         (tdesc_add_typed_bitfield): Likewise.
9051         (tdesc_add_bitfield): Likewise.
9052         (tdesc_add_flag): Likewise.
9053         (tdesc_add_enum_value): Likewise.
9054         * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
9055         (tdesc_add_typed_bitfield): Likewise.
9056         (tdesc_add_enum_value): Likewise.
9057
9058 2018-04-18  Alan Hayward  <alan.hayward@arm.com>
9059
9060         * common/tdesc.c (tdesc_feature::accept): Move to here.
9061         (tdesc_feature::operator==): Likewise.
9062         (tdesc_create_reg): Likewise.
9063         * common/tdesc.h (tdesc_type_kind): Likewise.
9064         (struct tdesc_type): Likewise.
9065         (struct tdesc_feature): Likewise.
9066         * regformats/regdat.sh: Create a feature.
9067         * target-descriptions.c (tdesc_type_kind): Move from here.
9068         (tdesc_type): Likewise.
9069         (tdesc_type_up): Likewise.
9070         (tdesc_feature): Likewise.
9071         (tdesc_create_reg): Likewise.
9072
9073 2018-04-18  Alan Hayward  <alan.hayward@arm.com>
9074
9075         * Makefile.in: Add arch/tdesc.c
9076         * common/tdesc.c: New file.
9077         * common/tdesc.h (tdesc_element_visitor): Move to here.
9078         (tdesc_element): Likewise.
9079         (tdesc_reg): Likewise.
9080         (tdesc_reg_up): Likewise.
9081         * regformats/regdef.h (reg): Add offset to constructors.
9082         * target-descriptions.c (tdesc_element_visitor): Move from here.
9083         (tdesc_element): Likewise.
9084         (tdesc_reg): Likewise.
9085         (tdesc_reg_up): Likewise.
9086
9087 2018-04-17  Tom Tromey  <tom@tromey.com>
9088
9089         * dwarf2read.c (quirk_rust_enum): Conditionally drop the
9090         discriminant field.
9091
9092 2018-04-17  Tom Tromey  <tom@tromey.com>
9093
9094         * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
9095
9096 2018-04-17  Andreas Arnez  <arnez@linux.vnet.ibm.com>
9097
9098         * symtab.c (print_symbol_info): Skip printing filename and line
9099         number when `last' is NULL.
9100         (symtab_symbol_info): Use empty string instead of NULL for first
9101         invocation of print_symbol_info.
9102         (rbreak_command): Pass NULL to `last' parameter of
9103         print_symbol_info.
9104
9105 2018-04-16  Simon Marchi  <simon.marchi@ericsson.com>
9106
9107         * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
9108         instead of nullptr.
9109
9110 2018-04-16  Pedro Alves  <palves@redhat.com>
9111
9112         * MAINTAINERS (sh): Remove.
9113         * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
9114         (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
9115         (ALLDEPFILES): Remove sh64-tdep.c.
9116         * NEWS: Mentions that support for SH-5/SH64 is removed.
9117         * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
9118         (sh*-*-openbsd*): Ditto.
9119         (sh64-*-elf*): Remove.
9120         (sh*): Remove.
9121         * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
9122         * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
9123         * sh-tdep.c: No longer include "sh64-tdep.h".
9124         (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
9125         * sh64-tdep.c, sh64-tdep.h: Remove files.
9126
9127 2018-04-16  Pedro Alves  <palves@redhat.com>
9128
9129         * MAINTAINERS: Remove m88k.
9130         * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
9131         (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
9132         (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
9133         * NEWS: Mention that support for m88k was removed.
9134         * configure.host (m88*-*-*): Remove support.
9135         * configure.nat (m88k-*-*): Remove support.
9136         * configure.tgt (m88*-*-openbsd*): Remove.
9137         * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
9138
9139 2018-04-15  Simon Marchi  <simon.marchi@polymtl.ca>
9140
9141         * configure.tgt (x86_tobjs): New variable.
9142         (amd64_tobjs, i386_tobjs): Use it.
9143
9144 2018-04-13  Andreas Arnez  <arnez@linux.vnet.ibm.com>
9145
9146         * symtab.c (print_symbol_info): Precede the symbol definition by
9147         the line number when available.
9148         * NEWS: Advertise this enhancement.
9149
9150 2018-04-13  Markus Metzger  <markus.t.metzger@intel.com>
9151
9152         * NEWS (New options): announce set/show record btrace cpu.
9153         * btrace.c: Include record-btrace.h.
9154         (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
9155         the vendor is unknown.
9156         (btrace_compute_ftrace_1): Add cpu parameter.  Update callers.
9157         Maybe overwrite the btrace configuration's cpu.
9158         (btrace_compute_ftrace): Add cpu parameter.  Update callers.
9159         (btrace_fetch): Add cpu parameter.  Update callers.
9160         (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
9161         Maybe overwrite the btrace configuration's cpu.  Skip enabling
9162         errata workarounds if the vendor is unknown.
9163         * python/py-record-btrace.c: Include record-btrace.h.
9164         (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
9165         (recpy_bt_function_call_history): Call record_btrace_get_cpu.
9166         * record-btrace.c (record_btrace_cpu_state_kind): New.
9167         (record_btrace_cpu): New.
9168         (set_record_btrace_cpu_cmdlist): New.
9169         (record_btrace_get_cpu): New.
9170         (require_btrace_thread, record_btrace_info)
9171         (record_btrace_resume_thread): Call record_btrace_get_cpu.
9172         (cmd_set_record_btrace_cpu_none): New.
9173         (cmd_set_record_btrace_cpu_auto): New.
9174         (cmd_set_record_btrace_cpu): New.
9175         (cmd_show_record_btrace_cpu): New.
9176         (_initialize_record_btrace): Initialize set/show record btrace cpu
9177         commands.
9178         * record-btrace.h (record_btrace_get_cpu): New.
9179
9180 2018-04-13  Markus Metzger  <markus.t.metzger@intel.com>
9181
9182         * record.c (set_record_command): Fix typo in message.
9183
9184 2018-04-13  Markus Metzger  <markus.t.metzger@intel.com>
9185
9186         * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
9187
9188 2018-04-13  Markus Metzger  <markus.t.metzger@intel.com>
9189
9190         * infrun.c (process_event_stop_test): Call
9191         gdbarch_in_indirect_branch_thunk.
9192         * gdbarch.sh (in_indirect_branch_thunk): New.
9193         * gdbarch.c: Regenerated.
9194         * gdbarch.h: Regenerated.
9195         * x86-tdep.h: New.
9196         * x86-tdep.c: New.
9197         * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
9198         (HFILES_NO_SRCDIR): Add x86-tdep.h.
9199         (ALLDEPFILES): Add x86-tdep.c.
9200         * arch-utils.h (default_in_indirect_branch_thunk): New.
9201         * arch-utils.c (default_in_indirect_branch_thunk): New.
9202         * i386-tdep: Include x86-tdep.h.
9203         (i386_in_indirect_branch_thunk): New.
9204         (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
9205         function.
9206         * amd64-tdep: Include x86-tdep.h.
9207         (amd64_in_indirect_branch_thunk): New.
9208         (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
9209
9210 2018-04-12  Jan Kratochvil  <jan.kratochvil@redhat.com>
9211
9212         PR gdb/23053
9213         * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
9214         (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
9215         (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
9216         regression.
9217
9218 2018-04-12  Tom Tromey  <tom@tromey.com>
9219
9220         * rust-lang.c (rust_print_struct_def): Remove univariant code.
9221         (rust_evaluate_subexp): Likewise.
9222
9223 2018-04-12  Pedro Alves  <palves@redhat.com>
9224
9225         * procfs.c (procfs_detach): Make forward declaration's prototype
9226         match definition's protototype.
9227         (proc_get_LDT_entry): Remove stale do_cleanups call.
9228
9229 2018-04-12  Pedro Alves  <palves@redhat.com>
9230
9231         * target.h (target_ops::to_has_exited): Delete.
9232         (target_has_exited): Delete.
9233         * target-delegates.c: Regenerate.
9234
9235 2018-04-11  Pedro Alves  <palves@redhat.com>
9236
9237         * target.c (fileio_fh_t::t): Add comment.
9238         (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9239         (target_fileio_close): Handle a NULL target.
9240         (invalidate_fileio_fh): New.
9241         (target_close): Call it.
9242         * remote.c (remote_hostio_send_command): No longer check whether
9243         remote_desc is open.
9244
9245 2018-04-11  Pedro Alves  <palves@redhat.com>
9246
9247         * target.c (fileio_fh_t): Make it a named struct instead of a
9248         typedef.
9249         (fileio_fh_t::is_closed): New method.
9250         (DEF_VEC_O (fileio_fh_t)): Remove.
9251         (fileio_fhandles): Now a std::vector.
9252         (is_closed_fileio_fh): Delete.
9253         (acquire_fileio_fd): Adjust.  Rename parameters.
9254         (release_fileio_fd): Adjust.
9255         (fileio_fd_to_fh): Reimplement as a function instead of a macro.
9256         (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9257         (target_fileio_close): Adjust.
9258
9259 2018-04-10  Simon Marchi  <simon.marchi@ericsson.com>
9260
9261         * auto-load.c (auto_load_safe_path_vec_update): Iterate by
9262         index.
9263
9264 2018-04-10  Pedro Alves  <palves@redhat.com>
9265
9266         * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
9267         (scoped_finish_thread_state): New class.
9268         * infcmd.c (run_command_1): Use it instead of finish_thread_state
9269         cleanup.
9270         * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
9271         (fetch_inferior_event, normal_stop): Likewise.
9272         * thread.c (finish_thread_state_cleanup): Delete.
9273
9274 2018-04-09  Simon Marchi  <simon.marchi@polymtl.ca>
9275             Pedro Alves  <palves@redhat.com>
9276
9277         * value.c: Include "selftest.h" and "common/array-view.h".
9278         (struct range) <operator ==>: New.
9279         (test_ranges_contain): New.
9280         (check_ranges_vector): New.
9281         (test_insert_into_bit_range_vector): New.
9282         (_initialize_values): Register selftests.
9283         * common/array-view.h (operator==, operator!=): New.
9284
9285 2018-04-09  Simon Marchi  <simon.marchi@polymtl.ca>
9286
9287         * common/gdb_vecs.h (unordered_remove): Add overload that takes
9288         an iterator.
9289         * inline-frame.c: Include <algorithm>.
9290         (struct inline_state): Add constructor.
9291         (inline_state_s): Remove.
9292         (DEF_VEC_O(inline_state_s)): Remove.
9293         (inline_states): Change type to std::vector.
9294         (find_inline_frame_state): Adjust to std::vector.
9295         (allocate_inline_frame_state): Remove.
9296         (clear_inline_frame_state): Adjust to std::vector.
9297         (skip_inline_frames): Adjust to std::vector.
9298
9299 2018-04-09  Simon Marchi  <simon.marchi@polymtl.ca>
9300
9301         * tracepoint.h (struct trace_state_variable): Add constructor.
9302         <name>: Change type to std::string.
9303         * tracepoint.c (tsv_s): Remove.
9304         (DEF_VEC_O(tsv_s)): Remove.
9305         (tvariables): Change to std::vector.
9306         (create_trace_state_variable): Adjust to std::vector.
9307         (find_trace_state_variable): Likewise.
9308         (find_trace_state_variable_by_number): Likewise.
9309         (delete_trace_state_variable): Likewise.
9310         (trace_variable_command): Adjust to std::string.
9311         (delete_trace_variable_command): Likewise.
9312         (tvariables_info_1): Adjust to std::vector.
9313         (save_trace_state_variables): Likewise.
9314         (start_tracing): Likewise.
9315         (merge_uploaded_trace_state_variables): Adjust to std::vector
9316         and std::string.
9317         * target.h (struct target_ops)
9318         <to_download_trace_state_variable>: Pass reference to
9319         trace_state_variable.
9320         * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
9321         * target-delegates.c: Re-generate.
9322         * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
9323         (mi_tsv_deleted): Likewise.
9324         * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
9325         * remote.c (remote_download_trace_state_variable): Change
9326         pointer to reference and adjust.
9327         * make-target-delegates (parse_argtypes): Handle references.
9328         (write_function_header): Likewise.
9329         (munge_type): Likewise.
9330
9331 2018-04-09  Simon Marchi  <simon.marchi@polymtl.ca>
9332
9333         * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9334         string_view-selftests.c.
9335         * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
9336         testsuite.
9337         * unittests/basic_string_view/cons/char/1.cc: Likewise.
9338         * unittests/basic_string_view/cons/char/2.cc: Likewise.
9339         * unittests/basic_string_view/cons/char/3.cc: Likewise.
9340         * unittests/basic_string_view/element_access/char/1.cc:
9341         Likewise.
9342         * unittests/basic_string_view/element_access/char/empty.cc:
9343         Likewise.
9344         * unittests/basic_string_view/element_access/char/front_back.cc:
9345         Likewise.
9346         * unittests/basic_string_view/inserters/char/2.cc: Likewise.
9347         * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
9348         Likewise.
9349         * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
9350         Likewise.
9351         * unittests/basic_string_view/modifiers/swap/char/1.cc:
9352         Likewise.
9353         * unittests/basic_string_view/operations/compare/char/1.cc:
9354         Likewise.
9355         * unittests/basic_string_view/operations/compare/char/13650.cc:
9356         Likewise.
9357         * unittests/basic_string_view/operations/copy/char/1.cc:
9358         Likewise.
9359         * unittests/basic_string_view/operations/data/char/1.cc:
9360         Likewise.
9361         * unittests/basic_string_view/operations/find/char/1.cc:
9362         Likewise.
9363         * unittests/basic_string_view/operations/find/char/2.cc:
9364         Likewise.
9365         * unittests/basic_string_view/operations/find/char/3.cc:
9366         Likewise.
9367         * unittests/basic_string_view/operations/find/char/4.cc:
9368         Likewise.
9369         * unittests/basic_string_view/operations/rfind/char/1.cc:
9370         Likewise.
9371         * unittests/basic_string_view/operations/rfind/char/2.cc:
9372         Likewise.
9373         * unittests/basic_string_view/operations/rfind/char/3.cc:
9374         Likewise.
9375         * unittests/basic_string_view/operations/substr/char/1.cc:
9376         Likewise.
9377         * unittests/basic_string_view/operators/char/2.cc: Likewise.
9378         * unittests/string_view-selftests.c: New file.
9379
9380 2018-04-09  Simon Marchi  <simon.marchi@polymtl.ca>
9381
9382         * unittests/basic_string_view/capacity/1.cc: New file.
9383         * unittests/basic_string_view/capacity/empty_neg.cc: New file.
9384         * unittests/basic_string_view/cons/char/1.cc: New file.
9385         * unittests/basic_string_view/cons/char/2.cc: New file.
9386         * unittests/basic_string_view/cons/char/3.cc: New file.
9387         * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
9388         * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
9389         * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
9390         * unittests/basic_string_view/element_access/char/1.cc: New file.
9391         * unittests/basic_string_view/element_access/char/2.cc: New file.
9392         * unittests/basic_string_view/element_access/char/empty.cc: New file.
9393         * unittests/basic_string_view/element_access/char/front_back.cc: New file.
9394         * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
9395         * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
9396         * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
9397         * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
9398         * unittests/basic_string_view/include.cc: New file.
9399         * unittests/basic_string_view/inserters/char/1.cc: New file.
9400         * unittests/basic_string_view/inserters/char/2.cc: New file.
9401         * unittests/basic_string_view/inserters/char/3.cc: New file.
9402         * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
9403         * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
9404         * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
9405         * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
9406         * unittests/basic_string_view/literals/types.cc: New file.
9407         * unittests/basic_string_view/literals/values.cc: New file.
9408         * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
9409         * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
9410         * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
9411         * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
9412         * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
9413         * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
9414         * unittests/basic_string_view/operations/compare/char/1.cc: New file.
9415         * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
9416         * unittests/basic_string_view/operations/compare/char/2.cc: New file.
9417         * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
9418         * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
9419         * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
9420         * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
9421         * unittests/basic_string_view/operations/copy/char/1.cc: New file.
9422         * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
9423         * unittests/basic_string_view/operations/data/char/1.cc: New file.
9424         * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
9425         * unittests/basic_string_view/operations/find/char/1.cc: New file.
9426         * unittests/basic_string_view/operations/find/char/2.cc: New file.
9427         * unittests/basic_string_view/operations/find/char/3.cc: New file.
9428         * unittests/basic_string_view/operations/find/char/4.cc: New file.
9429         * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
9430         * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
9431         * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
9432         * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
9433         * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
9434         * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
9435         * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
9436         * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
9437         * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
9438         * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
9439         * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
9440         * unittests/basic_string_view/operations/substr/char/1.cc: New file.
9441         * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
9442         * unittests/basic_string_view/operators/char/2.cc: New file.
9443         * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
9444         * unittests/basic_string_view/range_access/char/1.cc: New file.
9445         * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
9446         * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
9447         * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
9448         * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
9449         * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
9450         * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
9451         * unittests/basic_string_view/requirements/typedefs.cc: New file.
9452         * unittests/basic_string_view/typedefs.cc: New file.
9453         * unittests/basic_string_view/types/1.cc: New file.
9454
9455 2018-04-09  Simon Marchi  <simon.marchi@polymtl.ca>
9456
9457         * common/gdb_string_view.h: Remove libstdc++ implementation
9458         details, adjust to gdb reality.
9459         * common/gdb_string_view.tcc: Likewise.
9460         * cli/cli-script.c (struct string_view): Remove.
9461         (user_args) <m_args>: Change element type to gdb::string_view.
9462         (user_args::insert_args): Adjust.
9463
9464 2018-04-09  Simon Marchi  <simon.marchi@polymtl.ca>
9465
9466         * common/gdb_string_view.h: New file.
9467         * common/gdb_string_view.tcc: New file.
9468
9469 2018-04-09  Simon Marchi  <simon.marchi@polymtl.ca>
9470
9471         * ax_cxx_compile_stdcxx.m4: Sync with upstream.
9472         * configure: Re-generate.
9473
9474 2018-04-09  Pedro Alves  <palves@redhat.com>
9475
9476         * gdbarch.sh: Include "observable.h" instead of "observer.h".
9477         (set_target_gdbarch): Call
9478         gdb::observers::architecture_changed.notify instead of
9479         observer_notify_architecture_changed.
9480
9481 2018-04-07  Simon Marchi  <simon.marchi@polymtl.ca>
9482
9483         * tracepoint.c (struct current_traceframe_cleanup): Remove.
9484         (do_restore_current_traceframe_cleanup): Remove.
9485         (restore_current_traceframe_cleanup_dtor): Remove.
9486         (make_cleanup_restore_current_traceframe): Remove.
9487         (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
9488         New.
9489         * tracepoint.h (struct scoped_restore_current_traceframe): New.
9490         * infrun.c (fetch_inferior_event): Use
9491         scoped_restore_current_traceframe.
9492
9493 2018-04-07  Simon Marchi  <simon.marchi@polymtl.ca>
9494
9495         * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
9496         Remove.
9497         <n_allocated_type_units>: Remove.
9498         <all_type_units>: Change to std::vector.
9499         * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9500         to std::vector change.
9501         (dwarf2_per_objfile::get_cutu): Likewise.
9502         (dwarf2_per_objfile::get_tu): Likewise.
9503         (create_signatured_type_table_from_index): Likewise.
9504         (create_signatured_type_table_from_debug_names): Likewise.
9505         (dw2_symtab_iter_next): Likewise.
9506         (dw2_print_stats): Likewise.
9507         (dw2_expand_all_symtabs): Likewise.
9508         (dw2_expand_marked_cus): Likewise.
9509         (dw2_debug_names_iterator::next): Likewise.
9510         (dwarf2_initialize_objfile): Likewise.
9511         (add_signatured_type_cu_to_table): Likewise.
9512         (create_all_type_units): Likewise.
9513         (add_type_unit): Likewise.
9514         (struct tu_abbrev_offset): Add constructor.
9515         (build_type_psymtabs_1): Adjust to std::vector change.
9516         (print_tu_stats): Likewise.
9517         * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9518         (write_debug_names): Likewise.
9519
9520 2018-04-07  Simon Marchi  <simon.marchi@polymtl.ca>
9521
9522         * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
9523         Make an std::vector.
9524         <n_comp_units>: Remove.
9525         * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9526         to std::vector change.
9527         (dwarf2_per_objfile::get_cutu): Likewise.
9528         (dwarf2_per_objfile::get_cu): Likewise.
9529         (create_cus_from_index): Likewise.
9530         (create_addrmap_from_index): Likewise.
9531         (create_addrmap_from_aranges): Likewise.
9532         (dwarf2_read_index): Likewise.
9533         (dw2_find_last_source_symtab): Likewise.
9534         (dw2_map_symtabs_matching_filename): Likewise.
9535         (dw2_symtab_iter_next): Likewise.
9536         (dw2_print_stats): Likewise.
9537         (dw2_expand_all_symtabs): Likewise.
9538         (dw2_expand_symtabs_with_fullname): Likewise.
9539         (dw2_expand_marked_cus): Likewise.
9540         (dw2_map_symbol_filenames): Likewise.
9541         (create_cus_from_debug_names): Likewise.
9542         (dwarf2_read_debug_names): Likewise.
9543         (dw2_debug_names_iterator::next): Likewise.
9544         (dwarf2_initialize_objfile): Likewise.
9545         (set_partial_user): Likewise.
9546         (dwarf2_build_psymtabs_hard): Likewise.
9547         (read_comp_units_from_section): Remove arguments, adjust to
9548         std::vector change.
9549         (create_all_comp_units): Adjust to std::vector and
9550         read_comp_units_from_section changes.
9551         (dwarf2_find_containing_comp_unit): Adjust to std::vector
9552         change.
9553         * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9554         (psyms_seen_size): Likewise.
9555         (write_gdbindex): Likewise.
9556         (write_debug_names): Likewise.
9557
9558 2018-04-07  Simon Marchi  <simon.marchi@polymtl.ca>
9559
9560         * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
9561         with dwarf2_per_objfile.
9562         (create_cus_from_index): Likewise.
9563         (create_signatured_type_table_from_index): Likewise.
9564         (dwarf2_read_index): Likewise.
9565         (dwarf2_initialize_objfile): Likewise.
9566         (dwarf2_fetch_die_loc_sect_off):  Get dwarf2_per_objfile from
9567         per_cu rather than get_dwarf2_per_objfile.
9568
9569 2018-04-07  Simon Marchi  <simon.marchi@polymtl.ca>
9570
9571         * dwarf2read.h (struct signatured_type): Forward declare.
9572         (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
9573         New methods.
9574         * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
9575         (dw2_get_cutu): ...this.
9576         (dwarf2_per_objfile::get_cu): Rename from...
9577         (dw2_get_cu): ...this.
9578         (dwarf2_per_objfile::get_tu): New.
9579         (create_addrmap_from_index): Adjust.
9580         (create_addrmap_from_aranges): Adjust.
9581         (dw2_find_last_source_symtab): Adjust.
9582         (dw2_map_symtabs_matching_filename): Adjust.
9583         (dw2_symtab_iter_next): Adjust.
9584         (dw2_print_stats): Adjust.
9585         (dw2_expand_all_symtabs): Adjust.
9586         (dw2_expand_symtabs_with_fullname): Adjust.
9587         (dw2_expand_marked_cus): Adjust.
9588         (dw_expand_symtabs_matching_file_matcher): Adjust.
9589         (dw2_map_symbol_filenames): Adjust.
9590         (dw2_debug_names_iterator::next): Adjust.
9591         (dwarf2_initialize_objfile): Adjust.
9592         (set_partial_user): Adjust.
9593         (dwarf2_build_psymtabs_hard): Adjust.
9594
9595 2018-04-07  Simon Marchi  <simon.marchi@polymtl.ca>
9596
9597         * dwarf2read.c (create_signatured_type_table_from_debug_names):
9598         Remove unused variables.
9599         (dw2_map_symtabs_matching_filename): Likewise.
9600         (dwarf2_record_block_ranges): Likewise.
9601         (dwarf2_read_addr_index): Likewise.
9602         (follow_die_offset): Likewise.
9603
9604 2018-04-07  Simon Marchi  <simon.marchi@polymtl.ca>
9605
9606         * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
9607         to symbol_file_add_main.
9608
9609 2018-04-07  Simon Marchi  <simon.marchi@polymtl.ca>
9610
9611         PR mi/22299
9612         * mi/mi-console.c (do_fputc_async_safe): New.
9613         (mi_console_file::write_async_safe): New.
9614         (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
9615         * mi/mi-console.h (class mi_console_file) <write_async_safe>:
9616         New.
9617         * ui-file.c (ui_file::putstrn): Adjust call to
9618         fputstrn_unfiltered.
9619         * utils.c (printchar): Replace do_fputs and do_fprintf
9620         parameters by do_fputc.
9621         (fputstr_filtered): Adjust call to printchar.
9622         (fputstr_unfiltered): Likewise.
9623         (fputstrn_filtered): Likewise.
9624         (fputstrn_unfiltered): Add do_fputc parameter, pass to
9625         printchar.
9626         * utils.h (do_fputc_ftype): New typedef.
9627         (fputstrn_unfiltered): Add do_fputc parameter.
9628
9629 2018-04-07  Simon Marchi  <simon.marchi@polymtl.ca>
9630
9631         * regformats/i386/i386-avx.dat: Remove.
9632
9633 2018-04-07  Simon Marchi  <simon.marchi@ericsson.com>
9634
9635         PR gdb/22979
9636         * amd64-tdep.c (amd64_none_init_abi): New function.
9637         (amd64_x32_none_init_abi): New function.
9638         (_initialize_amd64_tdep): Register handlers for x86-64 and
9639         x64_32 with GDB_OSABI_NONE.
9640         * osabi.c (gdbarch_init_osabi): Allow running handlers for the
9641         GDB_OSABI_NONE osabi.
9642
9643 2018-04-07  Simon Marchi  <simon.marchi@ericsson.com>
9644
9645         PR gdb/22980
9646         * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
9647         GDB_OSABI_NONE.
9648         * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
9649         * osabi.c (gdb_osabi_names): Add "unknown" entry.
9650
9651 2018-04-07  Simon Marchi  <simon.marchi@ericsson.com>
9652
9653         * common/byte-vector.h (char_vector): New type.
9654         * target.h (target_read_alloc): Return
9655         gdb::optional<byte_vector>.
9656         (target_read_stralloc): Return gdb::optional<char_vector>.
9657         (target_get_osdata): Return gdb::optional<char_vector>.
9658         * target.c (target_read_alloc_1): Templatize.  Replacement
9659         manual memory management with vector.
9660         (target_read_alloc): Change return type, adjust.
9661         (target_read_stralloc): Change return type, adjust.
9662         (target_get_osdata): Change return type, adjust.
9663         * auxv.c (struct auxv_info) <length>: Remove.
9664         <data>: Change type to gdb::optional<byte_vector>.
9665         (auxv_inferior_data_cleanup): Free auxv_info with delete.
9666         (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
9667         (target_auxv_search): Adjust.
9668         (fprint_target_auxv): Adjust.
9669         * avr-tdep.c (avr_io_reg_read_command): Adjust.
9670         * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
9671         (linux_make_corefile_notes): Adjust.
9672         * osdata.c (get_osdata): Adjust.
9673         * remote.c (remote_get_threads_with_qxfer): Adjust.
9674         (remote_memory_map): Adjust.
9675         (remote_traceframe_info): Adjust.
9676         (btrace_read_config): Adjust.
9677         (remote_read_btrace): Adjust.
9678         (remote_pid_to_exec_file): Adjust.
9679         * solib-aix.c (solib_aix_get_library_list): Adjust.
9680         * solib-dsbt.c (decode_loadmap): Don't free buf.
9681         (dsbt_get_initial_loadmaps): Adjust.
9682         * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
9683         * solib-target.c (solib_target_current_sos): Adjust.
9684         * tracepoint.c (sdata_make_value): Adjust.
9685         * xml-support.c (xinclude_start_include): Adjust.
9686         (xml_fetch_content_from_file): Adjust.
9687         * xml-support.h (xml_fetch_another): Change return type.
9688         (xml_fetch_content_from_file): Change return type.
9689         * xml-syscall.c (xml_init_syscalls_info): Adjust.
9690         * xml-tdesc.c (file_read_description_xml): Adjust.
9691         (fetch_available_features_from_target): Change return type.
9692         (target_fetch_description_xml): Adjust.
9693         (target_read_description_xml): Adjust.
9694
9695 2018-04-06  Tom Tromey  <tom@tromey.com>
9696
9697         * value.c (~value): Update.
9698         (struct value) <contents>: Now unique_xmalloc_ptr.
9699         (value_contents_bits_eq, allocate_value_contents)
9700         (value_contents_raw, value_contents_all_raw)
9701         (value_contents_for_printing, value_contents_for_printing_const)
9702         (set_value_enclosing_type): Update.
9703
9704 2018-04-06  Tom Tromey  <tom@tromey.com>
9705
9706         * value.c (range_s): Remove typedef, VEC.
9707         (struct range): Add operator<.
9708         (range_lessthan): Remove.
9709         (ranges_contain): Change type.
9710         (~value): Update.
9711         (struct value) <unavailable, optimized_out>: Now std::vector.
9712         (value_entirely_available)
9713         (value_entirely_covered_by_range_vector)
9714         (value_entirely_unavailable, value_entirely_optimized_out):
9715         Update.
9716         (insert_into_bit_range_vector): Change argument type.
9717         (find_first_range_overlap): Likewise.
9718         (struct ranges_and_idx, value_contents_bits_eq)
9719         (require_not_optimized_out, require_available): Update.
9720         (ranges_copy_adjusted): Change argument types.
9721         (value_optimized_out, value_copy, value_fetch_lazy): Update.
9722
9723 2018-04-06  Tom Tromey  <tom@tromey.com>
9724
9725         * value.c (~value): Update.
9726         (struct value) <parent>: Now a value_ref_ptr.
9727         (value_parent, set_value_parent, value_address, value_copy):
9728         Update.
9729
9730 2018-04-06  Tom Tromey  <tom@tromey.com>
9731
9732         * value.c (struct value): Add constructor, destructor, and member
9733         initializers.
9734         (allocate_value_lazy, value_decref): Update.
9735
9736 2018-04-06  Tom Tromey  <tom@tromey.com>
9737
9738         * value.c (struct value) <released, next>: Remove.
9739         (all_values): Now a std::vector.
9740         (allocate_value_lazy): Update.
9741         (value_next): Remove.
9742         (value_mark, value_free_to_mark, release_value)
9743         (value_release_to_mark): Update.
9744
9745 2018-04-06  Tom Tromey  <tom@tromey.com>
9746
9747         * value.h (fetch_subexp_value, value_release_to_mark): Update.
9748         (free_value_chain): Remove.
9749         * value.c (free_value_chain): Remove.
9750         (value_release_to_mark): Return a std::vector.
9751         * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
9752         std::vector.
9753         (check_condition): Update.
9754         * eval.c (fetch_subexp_value): Change "val_chain" to a
9755         std::vector.
9756         * breakpoint.c (update_watchpoint): Update.
9757         (can_use_hardware_watchpoint): Change "vals" to a std::vector.
9758
9759 2018-04-06  Tom Tromey  <tom@tromey.com>
9760
9761         * value.h (free_all_values): Remove.
9762         * value.c (free_all_values): Remove.
9763
9764 2018-04-06  Tom Tromey  <tom@tromey.com>
9765
9766         * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
9767         (value_history_chain, value_history_count): Remove.
9768         (value_history): New global.
9769         (record_latest_value, access_value_history, show_values)
9770         (preserve_values): Update.
9771
9772 2018-04-06  Tom Tromey  <tom@tromey.com>
9773
9774         * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
9775         * varobj.c (varobj_set_display_format, varobj_set_value)
9776         (install_default_visualizer, construct_visualizer)
9777         (install_new_value, ~varobj, varobj_get_value_type)
9778         (my_value_of_variable, varobj_editable_p): Update.
9779         * c-varobj.c (c_describe_child, c_value_of_variable)
9780         (cplus_number_of_children, cplus_describe_child): Update.
9781         * ada-varobj.c (ada_number_of_children, ada_name_of_child)
9782         (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
9783         (ada_value_of_variable, ada_value_is_changeable_p): Update.
9784
9785 2018-04-06  Tom Tromey  <tom@tromey.com>
9786
9787         * printcmd.c (last_examine_address): Change type to
9788         value_ref_ptr.
9789         (do_examine, x_command): Update.
9790
9791 2018-04-06  Tom Tromey  <tom@tromey.com>
9792
9793         * value.c (release_value): Update.
9794         * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
9795         (struct bpstats) <val>: Now a value_ref_ptr.
9796         * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
9797         (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
9798         (~watchpoint, print_it_watchpoint, watch_command_1)
9799         (invalidate_bp_value_on_memory_change): Update.
9800
9801 2018-04-06  Tom Tromey  <tom@tromey.com>
9802
9803         * varobj.c (varobj_clear_saved_item)
9804         (update_dynamic_varobj_children, install_new_value, ~varobj):
9805         Update.
9806         * value.h (value_incref): Move declaration earlier.
9807         (value_decref): Rename from value_free.
9808         (struct value_ref_policy): New.
9809         (value_ref_ptr): New typedef.
9810         (struct value_deleter): Remove.
9811         (gdb_value_up): Remove typedef.
9812         (release_value): Change return type.
9813         (release_value_or_incref): Remove.
9814         * value.c (set_value_parent): Update.
9815         (value_incref): Change return type.
9816         (value_decref): Rename from value_free.
9817         (value_free_to_mark, free_all_values, free_value_chain): Update.
9818         (release_value): Return value_ref_ptr.
9819         (release_value_or_incref): Remove.
9820         (record_latest_value, set_internalvar, clear_internalvar):
9821         Update.
9822         * stack.c (info_frame_command): Don't call value_free.
9823         * python/py-value.c (valpy_dealloc, valpy_new)
9824         (value_to_value_object): Update.
9825         * printcmd.c (do_examine): Update.
9826         * opencl-lang.c (lval_func_free_closure): Update.
9827         * mi/mi-main.c (register_changed_p): Don't call value_free.
9828         * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
9829         * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
9830         * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
9831         value_free.
9832         * guile/scm-value.c (vlscm_free_value_smob)
9833         (vlscm_scm_from_value): Update.
9834         * frame.c (frame_register_unwind, frame_unwind_register_signed)
9835         (frame_unwind_register_unsigned, get_frame_register_bytes)
9836         (put_frame_register_bytes): Don't call value_free.
9837         * findvar.c (address_from_register): Don't call value_free.
9838         * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
9839         * dwarf2loc.c (entry_data_value_free_closure)
9840         (value_of_dwarf_reg_entry, free_pieced_value_closure)
9841         (dwarf2_evaluate_loc_desc_full): Update.
9842         * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
9843         (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
9844         (~watchpoint, watch_command_1)
9845         (invalidate_bp_value_on_memory_change): Update.
9846         * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
9847
9848 2018-04-06  Simon Marchi  <simon.marchi@polymtl.ca>
9849
9850         PR gdb/23022
9851         * warning.m4: Add -Wno-error=deprecated-register.
9852         * configure: Re-generate.
9853
9854 2018-04-05  Tom Tromey  <tom@tromey.com>
9855
9856         * linespec.h: Remove include of "vec.h".
9857
9858 2018-04-05  Tom Tromey  <tom@tromey.com>
9859
9860         * linespec.c (typep): Remove typedef.
9861         (find_methods, find_superclass_methods): Take a std::vector.
9862         (find_method): Use std::vector.
9863
9864 2018-04-05  Tom Tromey  <tom@tromey.com>
9865
9866         * utils.c (compare_strings): Remove.
9867         * utils.h (compare_strings): Remove.
9868         * objc-lang.h (find_imps): Update.
9869         * objc-lang.c (find_methods): Take a std::vector.
9870         (uniquify_strings, find_imps): Likewise.
9871         * linespec.c (find_methods): Take a std::vector.
9872         (decode_objc): Use std::vector.
9873         (add_all_symbol_names_from_pspace, find_superclass_methods): Take
9874         a std::vector.
9875         (find_method, find_function_symbols): Use std::vector.
9876
9877 2018-04-05  Tom Tromey  <tom@tromey.com>
9878
9879         * completer.c (completion_tracker::completion_tracker): Remove
9880         cast.
9881         (completion_tracker::discard_completions): Likewise.
9882         * breakpoint.c (ambiguous_names_p): Remove cast.
9883         * ada-lang.c (_initialize_ada_language): Remove cast.
9884         * utils.h (streq): Update.
9885         (streq_hash): Add new declaration.
9886         * utils.c (streq): Return bool.
9887         (streq_hash): New function.
9888
9889 2018-04-05  Tom Tromey  <tom@tromey.com>
9890
9891         * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
9892         Remove a string copy.
9893
9894 2018-04-05  Tom Tromey  <tom@tromey.com>
9895
9896         * linespec.c (filter_results): Use std::vector.
9897         (decode_line_2, decode_line_full): Update.
9898
9899 2018-04-05  Tom Tromey  <tom@tromey.com>
9900
9901         * linespec.c (canonical_to_fullform): Return std::string.
9902         (filter_results): Update.
9903         (struct decode_line_2_item): Add constructor.
9904         <fullform, displayform>: Now std::string.
9905         (decode_line_2_compare_items): Now a std::sort comparator.
9906         (decode_line_2): Update.
9907
9908 2018-04-05  Tom Tromey  <tom@tromey.com>
9909
9910         * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
9911         (unexpected_linespec_error): Update.
9912         (linespec_parse_basic, parse_linespec): Update.
9913
9914 2018-04-05  Tom Tromey  <tom@tromey.com>
9915
9916         * linespec.c (linespec_parse_basic): Reindent.
9917
9918 2018-04-05  Tom Tromey  <tom@tromey.com>
9919
9920         * minsyms.h (iterate_over_minimal_symbols): Update.
9921         * minsyms.c (iterate_over_minimal_symbols): Take a
9922         gdb::function_view.
9923         * linespec.c (struct collect_minsyms): Remove.
9924         (compare_msyms): Now a std::sort comparator.
9925         (add_minsym): Add parameters.
9926         (search_minsyms_for_name): Update.  Use std::vector.
9927
9928 2018-04-03  Tom Tromey  <tom@tromey.com>
9929
9930         * mipsread.c (read_alphacoff_dynamic_symtab): Use
9931         gdb::byte_vector.
9932
9933 2018-04-02  Weimin Pan  <weimin.pan@oracle.com>
9934
9935         * MAINTAINERS (Write After Approval): Add Weimin Pan.
9936
9937 2018-04-02  Weimin Pan  <weimin.pan@oracle.com>
9938
9939         PR gdb/16959
9940         * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when 
9941         printing static type.
9942
9943 2018-04-01  Tom Tromey  <tom@tromey.com>
9944
9945         * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
9946         (rs6000_xfer_shared_libraries): Update.
9947
9948 2018-04-01  Simon Marchi  <simon.marchi@polymtl.ca>
9949
9950         * common/gdb_vecs.h (char_ptr): Remove.
9951         * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
9952
9953 2018-03-30  Simon Marchi  <simon.marchi@polymtl.ca>
9954
9955         * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
9956         with std::vector.
9957         * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
9958
9959 2018-03-30  Simon Marchi  <simon.marchi@polymtl.ca>
9960
9961         * tracepoint.h (struct uploaded_tp): Initialize fields.
9962         <actions, step_actions, cmd_strings>: Change type to
9963         std::vector<char *>.
9964         * tracepoint.c (get_uploaded_tp): Allocate with new.
9965         (free_uploaded_tps): Free with delete.
9966         (parse_tracepoint_definition): Adjust to std::vector change.
9967         * breakpoint.c (read_uploaded_action): Likewise.
9968         (create_tracepoint_from_upload): Likewise.
9969         * ctf.c (ctf_write_uploaded_tp): Likewise.
9970         (SET_ARRAY_FIELD): Likewise.
9971         * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
9972
9973 2018-03-30  Tom Tromey  <tom@tromey.com>
9974
9975         * solib-svr4.c (lm_info_read): Use gdb::byte_vector.  Return
9976         std::unique_ptr.
9977         (svr4_keep_data_in_core): Update.
9978         (svr4_read_so_list): Update.
9979
9980 2018-03-30  Tom Tromey  <tom@tromey.com>
9981
9982         * windows-nat.c (handle_output_debug_string, handle_exception):
9983         Update.
9984         * target.h (target_read_string): Update.
9985         * target.c (target_read_string): Change "string" to
9986         unique_xmalloc_ptr.
9987         * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
9988         Update.
9989         * solib-frv.c (frv_current_sos): Update.
9990         * solib-dsbt.c (dsbt_current_sos): Update.
9991         * solib-darwin.c (darwin_current_sos): Update.
9992         * linux-thread-db.c (inferior_has_bug): Update.
9993         * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
9994         Update.  Remove alloca.
9995         * ada-lang.c (ada_main_name): Update.
9996
9997 2018-03-30  Tom Tromey  <tom@tromey.com>
9998
9999         * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
10000         (struct dwo_file_deleter): New.
10001         (dwo_file_up): New typedef.
10002         (open_and_init_dwo_file): Use dwo_file_up.
10003         (free_dwo_file_cleanup): Remove.
10004
10005 2018-03-30  Tom Tromey  <tom@tromey.com>
10006
10007         * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
10008         (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
10009
10010 2018-03-30  Tom Tromey  <tom@tromey.com>
10011
10012         * dwarf2read.c (class free_cached_comp_units): New class.
10013         (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
10014         (free_cached_comp_units): Remove function.
10015
10016 2018-03-30  Tom Tromey  <tom@tromey.com>
10017
10018         * utils.h (make_cleanup_unpush_target): Remove.
10019         * inf-ptrace.c (struct target_unpusher): New.
10020         (target_unpush_up) New typedef.
10021         (inf_ptrace_create_inferior, inf_ptrace_attach): Use
10022         target_unpush_up.
10023         * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
10024
10025 2018-03-27  Tom Tromey  <tom@tromey.com>
10026
10027         * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
10028
10029 2018-03-27  Pedro Alves  <palves@redhat.com>
10030             Tom Tromey  <tom@tromey.com>
10031
10032         * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
10033         destructor.  Now a class.
10034         (gdb_readline_wrapper_cleanup): Remove function.
10035         (gdb_readline_wrapper): Remove cleanups.
10036
10037 2018-03-27  Tom Tromey  <tom@tromey.com>
10038
10039         * typeprint.h (struct type_print_options) <local_typedefs,
10040         global_typedefs>: Remove "struct" keyword.
10041         (class typedef_hash_table): New class.
10042         (recursively_update_typedef_hash, add_template_parameters)
10043         (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
10044         (find_typedef_in_hash): Don't declare.
10045         * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
10046         (typedef_hash_table::recursively_update): Rename from
10047         recursively_update_typedef_hash.  Now a member.
10048         (typedef_hash_table::add_template_parameters): Rename from
10049         add_template_parameters.  Now a member.
10050         (typedef_hash_table::typedef_hash_table): Now a constructor;
10051         rename from create_typedef_hash.
10052         (typedef_hash_table::~typedef_hash_table): Now a destructor;
10053         rename from free_typedef_hash.
10054         (do_free_typedef_hash, make_cleanup_free_typedef_hash)
10055         (do_free_global_table): Remove.
10056         (typedef_hash_table::typedef_hash_table): New constructor; renamed
10057         from copy_type_recursive.
10058         (create_global_typedef_table): Remove.
10059         (typedef_hash_table::find_global_typedef): Now a member of
10060         typedef_hash_table.
10061         (typedef_hash_table::find_typedef): Rename from
10062         find_typedef_in_hash; now a member.
10063         (whatis_exp): Update.
10064         * extension.h (struct ext_lang_type_printers): Add constructor and
10065         destructor.
10066         (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
10067         declare.
10068         * extension.c (ext_lang_type_printers::ext_lang_type_printers):
10069         Now a constructor; rename from start_ext_lang_type_printers.
10070         (ext_lang_type_printers): Now a destructor; rename from
10071         free_ext_lang_type_printers.
10072         * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
10073         Update.
10074         (c_type_print_base_struct_union): Update.  Remove cleanups.
10075
10076 2018-03-27  Tom Tromey  <tom@tromey.com>
10077
10078         * dwarf-index-write.c: Include <cmath>.
10079
10080 2018-03-27  Joel Brobecker  <brobecker@adacore.com>
10081
10082         * NEWS: Add entry describing new "set|show varsize-limit" command.
10083         * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
10084         command.
10085         * printcmd.c (_initialize_printcmd): Add "set var" alias of
10086         "set variable".
10087
10088 2018-03-27  Simon Marchi  <simon.marchi@ericsson.com>
10089
10090         * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
10091         dwarf-index-write.c
10092         (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
10093         * dwarf-index-common.c: New file.
10094         * dwarf-index-common.h: New file.
10095         * dwarf-index-write.c: New file.
10096         * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
10097         (struct dwarf2_section_info): Move from here.
10098         (dwarf2_section_info_def): Likewise.
10099         (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
10100         (offset_type): Likewise.
10101         (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
10102         (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
10103         (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
10104         (byte_swap): Likewise.
10105         (MAYBE_SWAP): Likewise.
10106         (dwarf2_per_cu_ptr): Likewise.
10107         (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
10108         (struct tu_stats): Likewise.
10109         (struct dwarf2_per_objfile): Likewise.
10110         (struct dwarf2_per_cu_data): Likewise.
10111         (struct signatured_type): Likewise.
10112         (sig_type_ptr): Likewise.
10113         (DEF_VEC_P (sig_type_ptr)): Likewise.
10114         (INDEX4_SUFFIX): Likewise.
10115         (INDEX5_SUFFIX): Likewise.
10116         (DEBUG_STR_SUFFIX): Likewise.
10117         (dwarf2_read_section): Make non-static.
10118         (mapped_index_string_hash): Move from here.
10119         (dwarf5_djb_hash): Likewise.
10120         (file_write): Likewise.
10121         (class data_buf): Likewise.
10122         (struct symtab_index_entry): Likewise.
10123         (struct mapped_symtab): Likewise.
10124         (find_slot): Likewise.
10125         (hash_expand): Likewise.
10126         (add_index_entry): Likewise.
10127         (uniquify_cu_indices): Likewise.
10128         (class c_str_view): Likewise.
10129         (class c_str_view_hasher): Likewise.
10130         (class vector_hasher): Likewise.
10131         (write_hash_table): Likewise.
10132         (psym_index_map): Likewise.
10133         (struct addrmap_index_data): Likewise.
10134         (add_address_entry): Likewise.
10135         (add_address_entry_worker): Likewise.
10136         (write_address_map): Likewise.
10137         (symbol_kind): Likewise.
10138         (write_psymbols): Likewise.
10139         (struct signatured_type_index_data): Likewise.
10140         (write_one_signatured_type): Likewise.
10141         (recursively_count_psymbols): Likewise.
10142         (recursively_write_psymbols): Likewise.
10143         (class debug_names): Likewise.
10144         (check_dwarf64_offsets): Likewise.
10145         (psyms_seen_size): Likewise.
10146         (write_gdbindex): Likewise.
10147         (write_debug_names): Likewise.
10148         (assert_file_size): Likewise.
10149         (write_psymtabs_to_index): Likewise.
10150         (save_gdb_index_command): Likewise.
10151         (_initialize_dwarf2_read): Don't register the "save gdb-index"
10152         command.
10153         * dwarf2read.h: New file.
10154
10155 2018-03-27  Joel Brobecker  <brobecker@adacore.com>
10156
10157         PR gdb/22670
10158         * dwarf2read.c (dwarf2_physname): Do not return the demangled
10159         symbol name if the CU's language stores symbol names in linkage
10160         format.
10161         * language.h (struct language_defn)
10162         <la_store_sym_names_in_linkage_form_p>: New field.  Adjust
10163         all instances of this struct.
10164
10165 2018-03-26  Tom Tromey  <tom@tromey.com>
10166
10167         * stack.c (backtrace_command_1): Remove verbose code.
10168
10169 2018-03-26  Tom Tromey  <tom@tromey.com>
10170
10171         * python/py-framefilter.c (py_print_type): Don't catch
10172         exceptions.  Return void.
10173         (py_print_value): Likewise.
10174         (py_print_single_arg): Likewise.
10175         (enumerate_args): Don't catch exceptions.
10176         (py_print_args): Likewise.
10177         (py_print_frame): Likewise.
10178         (gdbpy_apply_frame_filter): Catch exceptions here.
10179
10180 2018-03-26  Tom Tromey  <tom@tromey.com>
10181
10182         * stack.c (_initialize_stack): Remove trailing newlines from help
10183         text.  Add "Usage" line to "backtrace" help.
10184
10185 2018-03-26  Tom Tromey  <tom@tromey.com>
10186
10187         PR python/16486:
10188         * python/py-framefilter.c (py_print_args): Call wrap_hint.
10189
10190 2018-03-26  Tom Tromey  <tom@tromey.com>
10191
10192         * python/py-framefilter.c (py_print_single_arg): Return
10193         EXT_LANG_BT_ERROR from catch.
10194
10195 2018-03-26  Tom Tromey  <tom@tromey.com>
10196
10197         PR backtrace/15584:
10198         * stack.c (backtrace_command_1): Move some code into no-filters
10199         "if".
10200
10201 2018-03-26  Tom Tromey  <tom@tromey.com>
10202
10203         * python/py-framefilter.c (throw_quit_or_print_exception): New
10204         function.
10205         (gdbpy_apply_frame_filter): Use it.
10206
10207 2018-03-26  Tom Tromey  <tom@tromey.com>
10208
10209         PR cli/17716:
10210         * python/py-framefilter.c (py_print_type, py_print_value)
10211         (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
10212         RETURN_MASK_ERROR.
10213
10214 2018-03-26  Tom Tromey  <tom@tromey.com>
10215
10216         * python/py-framefilter.c (enumerate_args): Use
10217         gdb::unique_xmalloc_ptr.
10218
10219 2018-03-26  Tom Tromey  <tom@tromey.com>
10220
10221         * python/py-framefilter.c (py_print_frame): Return
10222         EXT_LANG_BT_OK.
10223         (gdbpy_apply_frame_filter): Update comment.
10224         * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
10225         Remove.
10226         <EXT_LANG_BT_NO_FILTERS>: Change value.
10227
10228 2018-03-26  Tom Tromey  <tom@tromey.com>
10229
10230         PR backtrace/15582:
10231         * stack.c (backtrace_command): Parse "hide" argument.
10232         * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
10233         * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
10234         constant.
10235
10236 2018-03-26  Tom Tromey  <tom@tromey.com>
10237
10238         * stack.c (backtrace_command_1): Remove "show_locals" parameter,
10239         add "flags".
10240         (backtrace_command): Remove "fulltrace", add "flags".
10241
10242 2018-03-26  Tom Tromey  <tom@tromey.com>
10243
10244         * stack.c (backtrace_command): Rewrite command line parsing.
10245
10246 2018-03-26  Simon Marchi  <simon.marchi@ericsson.com>
10247
10248         * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
10249
10250 2018-03-26  Simon Marchi  <simon.marchi@ericsson.com>
10251
10252         * filename-seen-cache.h: Add include guard.
10253
10254 2018-03-26  Keith Seitz  <keiths@redhat.com>
10255
10256         * symfile.c (place_section): Remove "struct" from section_addr_info
10257         in comment.
10258         * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
10259         "struct" keyword from section_addr_info.
10260
10261 2018-03-26  Alan Hayward  <alan.hayward@arm.com>
10262
10263         * regformats/regdef.h (reg): Add constructors.
10264
10265 2018-03-25  Pedro Alves  <palves@redhat.com>
10266
10267         * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
10268         if then/else bodies in var_func_name extraction.
10269
10270 2018-03-23  Weimin Pan  <weimin.pan@oracle.com>
10271
10272         * minsyms.c (lookup_minimal_symbol_and_objfile): Use
10273         lookup_minimal_symbol() to find symbol entry.
10274         * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
10275
10276 2018-03-23  Keith Seitz  <keiths@redhat.com>
10277
10278         PR c++/22968
10279         * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
10280         nested type definitions for C++, too.
10281
10282 2018-03-23  Tom Tromey  <tom@tromey.com>
10283
10284         * machoread.c (struct oso_el): Add a constructor.  Don't define as
10285         a typedef.
10286         (macho_register_oso): Remove.
10287         (macho_symtab_read): Take a std::vector.
10288         (oso_el_compare_name): Now a std::sort comparator.
10289         (macho_symfile_read_all_oso): Take a std::vector.
10290         (macho_symfile_read): Use std::vector.  Remove cleanups.
10291
10292 2018-03-22  Tom Tromey  <tom@tromey.com>
10293
10294         * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
10295         (record_full_goto_bookmark): Use std::string.
10296
10297 2018-03-22  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
10298
10299         PR tdep/18295
10300         * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
10301         a single mask.
10302
10303 2018-03-22  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
10304
10305         * rs6000-tdep.c (store_insn_p): New function.
10306         (skip_prologue): New variable alloca_reg_offset. Set lr_reg
10307         and cr_reg to their unshifted values. Use store_insn_p to
10308         match LR saves using either R1 or fdata->alloca_reg. Use
10309         store_insn_p to match CR saves. Set alloca_reg_offset
10310         when alloca_reg and framep are set. Remove lr_reg shift
10311         when assigning to fdata->lr_register.
10312
10313 2018-03-22  Andreas Arnez  <arnez@linux.vnet.ibm.com>
10314
10315         * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
10316         command line args instead of emitting a warning.
10317
10318 2018-03-22  Simon Marchi  <simon.marchi@polymtl.ca>
10319
10320         * tracepoint.h (struct static_tracepoint_marker): Initialize
10321         fields, define default constructor, move constructor and move
10322         assignment, disable the rest.
10323         <str_id, extra>: Make std::string.
10324         (release_static_tracepoint_marker): Remove.
10325         (free_current_marker): Remove.
10326         * tracepoint.c (free_current_marker): Remove.
10327         (parse_static_tracepoint_marker_definition): Adjust to
10328         std::string, use new hex2str overload.
10329         (release_static_tracepoint_marker): Remove.
10330         (print_one_static_tracepoint_marker): Get marker by reference
10331         and adjust to std::string.
10332         (info_static_tracepoint_markers_command): Adjust to std::vector
10333         changes
10334         * target.h (static_tracepoint_marker_p): Remove typedef.
10335         (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
10336         (struct target_ops) <to_static_tracepoint_marker_at>: Return
10337         bool.
10338         <to_static_tracepoint_markers_by_strid>: Return std::vector.
10339         * target-debug.h
10340         (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
10341         (target_debug_print_std_vector_static_tracepoint_marker): New.
10342         (target_debug_print_struct_static_tracepoint_marker_p): Rename
10343         to...
10344         (target_debug_print_static_tracepoint_marker_p): ... this.
10345         * target-delegates.c: Re-generate.
10346         * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
10347         Make std::string.
10348         * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
10349         (decode_static_tracepoint_spec): Adjust to std::vector.
10350         (tracepoint_print_one_detail): Adjust to std::string.
10351         (strace_marker_decode_location): Adjust to std::string.
10352         (update_static_tracepoint): Adjust to std::string, remove call
10353         to release_static_tracepoint_marker.
10354         * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
10355         Adjust to std::vector.
10356         * remote.c (remote_static_tracepoint_marker_at): Return bool.
10357         (remote_static_tracepoint_markers_by_strid): Adjust to
10358         std::vector.
10359         * common/rsp-low.h (hex2str): New overload with explicit count
10360         of bytes.
10361         * common/rsp-low.c (hex2str): New overload with explicit count
10362         of bytes.
10363         * unittests/rsp-low-selftests.c (test_hex2str): New function.
10364         (_initialize_rsp_low_selftests): Add test_hex2str test.
10365         * unittests/tracepoint-selftests.c
10366         (test_parse_static_tracepoint_marker_definition): Adjust to
10367         std::string.
10368
10369 2018-03-22  Simon Marchi  <simon.marchi@polymtl.ca>
10370
10371         * tracepoint.c (parse_static_tracepoint_marker_definition):
10372         Consider case where the definition is followed by more
10373         definitions.
10374         * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10375         tracepoint-selftests.c.
10376         * unittests/tracepoint-selftests.c: New.
10377
10378 2018-03-21  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
10379
10380         * MAINTAINERS (Write After Approval): Add Pedro Franco de
10381         Carvalho.
10382
10383 2018-03-20  Stephen Roberts  <stephen.roberts@arm.com>
10384
10385         * symtab.c (find_pc_sect_line): fixed indentation.
10386
10387 2018-03-20  Stephen Roberts  <stephen.roberts@arm.com>
10388
10389         * symtab.c (find_pc_sect_line): now uses binary search.
10390
10391 2018-03-19  Tom Tromey  <tom@tromey.com>
10392
10393         * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
10394         "IDENT" production.
10395
10396 2018-03-19  Pedro Alves  <palves@redhat.com>
10397             Tom Tromey  <tom@tromey.com>
10398
10399         * unittests/observable-selftests.c: New file.
10400         * common/observable.h: New file.
10401         * observable.h: New file.
10402         * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
10403         arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
10404         breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
10405         corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
10406         extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
10407         infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
10408         linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
10409         mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
10410         ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
10411         python/py-breakpoint.c, python/py-finishbreakpoint.c,
10412         python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
10413         record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
10414         riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
10415         spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
10416         symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
10417         tui/tui-interp.c, valops.c: Update all users.
10418         * tui/tui-hooks.c (tui_bp_created_observer)
10419         (tui_bp_deleted_observer, tui_bp_modified_observer)
10420         (tui_inferior_exit_observer, tui_before_prompt_observer)
10421         (tui_normal_stop_observer, tui_register_changed_observer):
10422         Remove.
10423         (tui_observers_token): New global.
10424         (attach_or_detach, tui_attach_detach_observers): New functions.
10425         (tui_install_hooks, tui_remove_hooks): Use
10426         tui_attach_detach_observers.
10427         * record-btrace.c (record_btrace_thread_observer): Remove.
10428         (record_btrace_thread_observer_token): New global.
10429         * observer.sh: Remove.
10430         * observer.c: Rename to observable.c.
10431         * observable.c (namespace gdb_observers): Define new objects.
10432         (observer_debug): Move into gdb_observers namespace.
10433         (struct observer, struct observer_list, xalloc_observer_list_node)
10434         (xfree_observer_list_node, generic_observer_attach)
10435         (generic_observer_detach, generic_observer_notify): Remove.
10436         (_initialize_observer): Update.
10437         Don't include observer.inc.
10438         * Makefile.in (generated_files): Remove observer.h, observer.inc.
10439         (clean mostlyclean): Likewise.
10440         (observer.h, observer.inc): Remove targets.
10441         (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
10442         (COMMON_SFILES): Use observable.c, not observer.c.
10443         * .gitignore: Remove observer.h.
10444
10445 2018-03-18  Tom Tromey  <tom@tromey.com>
10446
10447         * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
10448         gdb::def_vector.
10449         (bfd_lookup_symbol_from_dyn_symtab): Likewise.
10450
10451 2018-03-17  Tom Tromey  <tom@tromey.com>
10452
10453         * auto-load.c (auto_load_objfile_script_1): Use std::string.
10454
10455 2018-03-17  Tom Tromey  <tom@tromey.com>
10456
10457         * target.c (class scoped_target_fd): New.
10458         (target_fileio_close_cleanup): Remove.
10459         (target_fileio_read_alloc_1): Use scoped_target_fd.
10460
10461 2018-03-16  Simon Marchi  <simon.marchi@polymtl.ca>
10462
10463         * silent-rules.mk: New.
10464         * Makefile.in: Include silent-rules.mk
10465         (srcdir, VPATH, top_srcdir): Move up.
10466         (COMPILE): Add ECHO_CXX.
10467         (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
10468         (init.c): Add ECHO_INIT_C.
10469         (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
10470         (version.c): Add ECHO_GEN.
10471         (printcmd.o): Add ECHO_CXX.
10472         (target-float.o): Add ECHO_CXX.
10473         (ada-exp.o): Add ECHO_CXX.
10474         (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
10475         (insight$(EXEEXT)): Add ECHO_CXXLD.
10476         * gnulib/configure.ac: Add AM_SILENT_RULES.
10477         * gnulib/aclocal.m4: Re-generate.
10478         * gnulib/configure: Re-generate.
10479         * gnulib/import/Makefile.in: Re-generate.
10480
10481 2018-03-16  Tom Tromey  <tom@tromey.com>
10482
10483         * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
10484         * utils.h (make_cleanup_free_section_addr_info): Don't declare.
10485         * utils.c (do_free_section_addr_info)
10486         (make_cleanup_free_section_addr_info): Remove.
10487         * symfile.h (struct other_sections): Add constructor.
10488         (struct section_addr_info): Remove.
10489         (section_addr_info): New typedef.
10490         (struct sym_fns) <sym_offsets>: Change type of parameter.
10491         (build_section_addr_info_from_objfile)
10492         (relative_addr_info_to_section_offsets, addr_info_make_relative)
10493         (default_symfile_offsets, symbol_file_add)
10494         (symbol_file_add_from_bfd)
10495         (build_section_addr_info_from_section_table): Update.
10496         (alloc_section_addr_info, free_section_addr_info): Don't declare.
10497         * symfile.c (alloc_section_addr_info): Remove.
10498         (build_section_addr_info_from_section_table): Change return type.
10499         Update.
10500         (build_section_addr_info_from_bfd)
10501         (build_section_addr_info_from_objfile): Likewise.
10502         (free_section_addr_info): Remove.
10503         (relative_addr_info_to_section_offsets): Change type of "addrs".
10504         (addrs_section_compar): Now a std::sort comparator.
10505         (addrs_section_sort): Change return type.
10506         (addr_info_make_relative): Change type of "addrs".  Update.
10507         (default_symfile_offsets, syms_from_objfile_1)
10508         (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
10509         (symbol_file_add_separate): Update.
10510         (symbol_file_add): Change type of "addrs".  Update.
10511         (add_symbol_file_command): Update.  Remove cleanups.
10512         * symfile-mem.c (symbol_file_add_from_memory): Update.  Remove
10513         cleanups.
10514         * symfile-debug.c (debug_sym_offsets): Change type of "info".
10515         * solib.c (solib_read_symbols): Update.
10516         * objfiles.c (objfile_relocate): Update.  Remove cleanups.
10517         * machoread.c (macho_symfile_offsets): Update.
10518         * jit.c (jit_bfd_try_read_symtab): Update.
10519
10520 2018-03-15  Simon Marchi  <simon.marchi@polymtl.ca>
10521
10522         * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10523         unittests/utils-selftests.c.
10524         * unittests/utils-selftests.c: New file.
10525
10526 2018-03-14  Tom Tromey  <tom@tromey.com>
10527
10528         PR cli/14977:
10529         * printcmd.c (printf_c_string, printf_wide_c_string): Special case
10530         for NULL.
10531
10532 2018-03-14  Tom Tromey  <tom@tromey.com>
10533
10534         PR cli/19918:
10535         * printcmd.c (printf_pointer): Allow "-" in format.
10536
10537 2018-03-14  Tom Tromey  <tom@tromey.com>
10538
10539         * printcmd.c (_initialize_printcmd): Add usage to printf.
10540
10541 2018-03-14  Yao Qi  <qiyao@sourceware.org>
10542
10543         * MAINTAINERS: Update my email address.
10544
10545 2018-03-13  Tom Tromey  <tom@tromey.com>
10546
10547         * machoread.c (macho_check_dsym): Change filenamep to a
10548         std::string*.
10549         (macho_symfile_read): Update.
10550         * symfile.c (load_command): Use std::string.
10551
10552 2018-03-12  Andrew Burgess  <andrew.burgess@embecosm.com>
10553
10554         * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
10555         to error message string.
10556         (riscv_register_name): Use xsnprintf instead of sprintf.
10557         (riscv_insn::fetch_instruction): Use gdb_assert instead of
10558         internal_error.
10559         (riscv_print_arg_location): Use gdb_assert_not_reached instead of
10560         error.
10561         (riscv_push_dummy_call): Likewise.
10562
10563 2018-03-12  Tom Tromey  <tom@tromey.com>
10564
10565         * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
10566         Use gdb::byte_vector.
10567         * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
10568
10569 2018-03-12  Yao Qi  <yao.qi@linaro.org>
10570
10571         * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
10572         parameter type to readable_regcache.
10573         * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
10574         the declaration.
10575
10576 2018-03-11  Tom Tromey  <tom@tromey.com>
10577
10578         * dwarf2read.c (struct nextfield): Add initializers.
10579         (struct nextfnfield): Remove.
10580         (struct fnfieldlist): Add initializers.  Remove "length" and
10581         "head", use std::vector.
10582         (struct decl_field_list): Remove.
10583         (struct field_info): Add initializers.
10584         <fields, baseclasses>: Now std::vector.
10585         <nbaseclasses, nfnfields, typedef_field_list_count,
10586         nested_types_list_count>: Remove.
10587         (dwarf2_add_field, dwarf2_add_type_defn)
10588         (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
10589         (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
10590         (process_structure_scope): Update.
10591
10592 2018-03-11  Tom Tromey  <tom@tromey.com>
10593
10594         * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
10595         for use by std::sort.
10596         (build_type_psymtabs_1): Use std::vector.
10597
10598 2018-03-09  Eli Zaretskii  <eliz@gnu.org>
10599
10600         * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
10601         and LIBMPFR in the printed configuration.
10602
10603 2018-03-08  Tom Tromey  <tom@tromey.com>
10604
10605         * source.c (get_filename_and_charpos): Use scoped_fd.
10606         * nto-procfs.c (procfs_open_1): Use scoped_fd.
10607         (procfs_pidlist): Likewise.
10608         * procfs.c (proc_get_LDT_entry): Use scoped_fd.
10609         (iterate_over_mappings): Likewise.
10610
10611 2018-03-08  Tom Tromey  <tom@tromey.com>
10612
10613         * infcall.c (struct call_return_meta_info)
10614         <stack_temporaries_enabled>: Remove.
10615         (get_call_return_value, call_function_by_hand_dummy): Update.
10616         * thread.c (disable_thread_stack_temporaries): Remove.
10617         (enable_thread_stack_temporaries): Remove.
10618         (thread_stack_temporaries_enabled_p): Return bool.
10619         (push_thread_stack_temporary, value_in_thread_stack_temporaries)
10620         (get_last_thread_stack_temporary): Update.
10621         * eval.c (evaluate_subexp): Update.
10622         * gdbthread.h (class enable_thread_stack_temporaries): Now a
10623         class, not a function.
10624         (value_ptr, value_vec): Remove typedefs.
10625         (class thread_info) <stack_temporaries_enabled>: Now bool.
10626         <stack_temporaries>: Now a std::vector.
10627         (thread_stack_temporaries_enabled_p)
10628         (value_in_thread_stack_temporaries): Return bool.
10629
10630 2018-03-08  Simon Marchi  <simon.marchi@ericsson.com>
10631
10632         * remote.c (putpkt_binary): Fix omitted bytes reporting.
10633         (getpkt_or_notif_sane_1): Likewise.
10634
10635 2018-03-08  Simon Marchi  <simon.marchi@polymtl.ca>
10636
10637         * build-id.c (build_id_to_debug_bfd): Use std::string.
10638
10639 2018-03-08  Simon Marchi  <simon.marchi@polymtl.ca>
10640
10641         * build-id.c (find_separate_debug_file_by_buildid): Return
10642         std::string.
10643         * build-id.h (find_separate_debug_file_by_buildid): Return
10644         std::string.
10645         * coffread.c (coff_symfile_read): Adjust to std::string.
10646         * elfread.c (elf_symfile_read): Adjust to std::string.
10647         * symfile.c (separate_debug_file_exists): Change parameter to
10648         std::string.
10649         (find_separate_debug_file): Return std::string.
10650         (find_separate_debug_file_by_debuglink): Return std::string.
10651         * symfile.h (find_separate_debug_file_by_debuglink): Return
10652         std::string.
10653
10654 2018-03-08  Simon Marchi  <simon.marchi@polymtl.ca>
10655
10656         * common/xml-utils.c (xml_escape_text): Move code to...
10657         (xml_escape_text_append): ... this new function.
10658         * common/xml-utils.h (xml_escape_text_append): New declaration.
10659         * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
10660         New function.
10661         (_initialize_xml_utils): register test_xml_escape_text_append as
10662         a selftest.
10663
10664 2018-03-07  Alan Hayward  <alan.hayward@arm.com>
10665
10666         * defs.h: Remove MAX_REGISTER_SIZE.
10667         * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
10668         asserts.
10669         * python/py-unwind.c (pyuw_sniffer): Likewise.
10670
10671 2018-03-07  Tom Tromey  <tom@tromey.com>
10672
10673         * linux-tdep.c (linux_info_proc): Update.
10674         * target.h (struct target_ops) <to_fileio_readlink>: Return
10675         optional<string>.
10676         (target_fileio_readlink): Return optional<string>.
10677         * remote.c (remote_hostio_readlink): Return optional<string>.
10678         * inf-child.c (inf_child_fileio_readlink): Return
10679         optional<string>.
10680         * target.c (target_fileio_readlink): Return optional<string>.
10681
10682 2018-03-07  Andrew Burgess  <andrew.burgess@embecosm.com>
10683
10684         * regcache.c (cooked_read_test): Add riscv to the list of
10685         architectures that have a save_reggroup.
10686
10687 2018-03-07  Andreas Arnez  <arnez@linux.vnet.ibm.com>
10688
10689         * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
10690         value is not a dynamic class object.
10691
10692 2018-03-06  Tom Tromey  <tom@tromey.com>
10693
10694         * rust-exp.y: Formatting fixes.
10695
10696 2018-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
10697
10698         * riscv-tdep.c (riscv_register_name): Remove target description
10699         support.
10700         (riscv_gdbarch_init): Remove target description check.
10701
10702 2018-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
10703
10704         * riscv-tdep.c: Remove 'Contributed by ...' lines from header
10705         comment.
10706         * riscv-tdep.h: Likewise.
10707
10708 2018-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
10709
10710         * riscv-tdep.c (riscv_pseudo_register_read): Delete.
10711         (riscv_pseudo_register_write): Delete.
10712         (riscv_gdbarch_init): Remove all use of pseudo registers.
10713
10714 2018-03-06  Simon Marchi  <simon.marchi@polymtl.ca>
10715
10716         * record-btrace.c (btrace_print_lines): Replace cleanup
10717         parameter with RAII equivalents.
10718         (btrace_insn_history): Replace cleanup with RAII equivalents.
10719         * ui-out.h (make_cleanup_ui_out_list_begin_end,
10720         make_cleanup_ui_out_tuple_begin_end): Remove.
10721         * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
10722         make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
10723         make_cleanup_ui_out_list_begin_end): Remove.
10724
10725 2018-03-06  Simon Marchi  <simon.marchi@polymtl.ca>
10726
10727         * record-btrace.c (record_btrace_maybe_mark_async_event): Change
10728         parameter types to std::vector.  Use bool.
10729         (record_btrace_wait): Replace VEC(tp_t) with
10730         std::vector<thread_info *>.
10731         * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
10732
10733 2018-03-06  Simon Marchi  <simon.marchi@polymtl.ca>
10734
10735         * record-btrace.c (record_btrace_disable_callback): Remove.
10736         (struct scoped_btrace_disable): New.
10737         (record_btrace_open): Use scoped_btrace_disable.
10738
10739 2018-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
10740
10741         * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
10742         reading values from registers.
10743
10744 2018-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
10745
10746         * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
10747         where appropriate.
10748
10749 2018-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
10750
10751         * riscv-tdep.c (riscv_print_arg_location): Add header comment,
10752         change parameter type.  Use GDB's print functions, and use
10753         core_addr_to_string where appropriate.
10754         (riscv_push_dummy_call): Use core_addr_to_string where
10755         appropriate, update call to riscv_print_arg_location, and reindent
10756         a few lines.
10757         (riscv_return_value): Update call to riscv_print_arg_location.
10758
10759 2018-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
10760             Tim Newsome <tim@sifive.com>
10761             Albert Ou <a0u@eecs.berkeley.edu>
10762             Darius Rad <darius@bluespec.com>
10763
10764         * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
10765         (HFILES_NO_SRCDIR): Add riscv-tdep.h.
10766         (ALLDEPFILES): Add riscv-tdep.c
10767         * configure.tgt: Add riscv support.
10768         * riscv-tdep.c: New file.
10769         * riscv-tdep.h: New file.
10770         * NEWS: Mention new target.
10771         * MAINTAINERS: Add entry for riscv.
10772
10773 2018-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
10774
10775         * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
10776         fields within aggregates.
10777
10778 2018-03-04  Simon Marchi  <simon.marchi@polymtl.ca>
10779
10780         * record-btrace.c (btrace_print_lines): Change type of flags to
10781         gdb_disassembly_flags.
10782
10783 2018-03-04  John Baldwin  <jhb@FreeBSD.org>
10784
10785         * fbsd-nat.c: Include "inf-ptrace.h".
10786         (USE_SIGTRAP_SIGINFO): Conditionally define.
10787         [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
10788         (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
10789         [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
10790         function.
10791         [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
10792         Likewise.
10793         [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
10794         Likewise.
10795         (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
10796         "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
10797         "supports_stopped_by_hw_breakpoint" target methods.
10798
10799 2018-03-04  John Baldwin  <jhb@FreeBSD.org>
10800
10801         * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
10802         * fbsd-nat.c (debug_fbsd_nat): New variable.
10803         (show_fbsd_nat_debug): New function.
10804         (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
10805         (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
10806
10807 2018-03-04  John Baldwin  <jhb@FreeBSD.org>
10808
10809         * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
10810         * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
10811         prototype.
10812         * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
10813         (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
10814         method.
10815
10816 2018-03-02  Simon Marchi  <simon.marchi@polymtl.ca>
10817
10818         * common/gdb_vecs.c (free_char_ptr_vec): Remove.
10819         * common/gdb_vecs.h (free_char_ptr_vec): Remove.
10820
10821 2018-03-02  Simon Marchi  <simon.marchi@polymtl.ca>
10822
10823         * charset.c (struct charset_vector): New.
10824         (charsets): Change type to charset_vector.
10825         (find_charset_names): Adjust.
10826         (add_one): Adjust.
10827         (_initialize_charset): Adjust.
10828
10829 2018-03-02  Simon Marchi  <simon.marchi@polymtl.ca>
10830
10831         * progspace.h (struct program_space) <deleted_solibs>: Change
10832         type to std::vector<std::string>.
10833         * progspace.c (clear_program_space_solib_cache): Adjust.
10834         * breakpoint.c (print_solib_event): Adjust.
10835         (check_status_catch_solib): Adjust.
10836         * solib.c (update_solib_list): Adjust.
10837         * ui-out.h (class ui_out) <field_string>: New overload.
10838         * ui-out.c (ui_out::field_string): New overload.
10839
10840 2018-03-02  Simon Marchi  <simon.marchi@polymtl.ca>
10841
10842         * progspace.h (struct program_space): Add constructor and
10843         destructor, initialize fields.
10844         (add_program_space): Remove.
10845         * progspace.c (add_program_space): Rename to...
10846         (program_space::program_space): ... this.
10847         (release_program_space): Rename to...
10848         (program_space::~program_space): ... this.
10849         (delete_program_space): Use delete to delete program_space.
10850         (initialize_progspace): Use new to allocate program_space.
10851         * inferior.c (add_inferior_with_spaces): Likewise.
10852         (clone_inferior_command): Likewise.
10853         * infrun.c (follow_fork_inferior): Likewise.
10854         (handle_vfork_child_exec_or_exit): Likewise.
10855
10856 2018-03-02  Simon Marchi  <simon.marchi@polymtl.ca>
10857
10858         * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
10859         (delim_string_to_char_ptr_vec): Return std::vector of
10860         gdb::unique_xmalloc_ptr.
10861         (dirnames_to_char_ptr_vec_append): Take std::vector of
10862         gdb::unique_xmalloc_ptr.
10863         (dirnames_to_char_ptr_vec): Return std::vector of
10864         gdb::unique_xmalloc_ptr.
10865         * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
10866         Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
10867         (delim_string_to_char_ptr_vec): Return an std::vector of
10868         gdb::unique_xmalloc_ptr, adjust the code.
10869         (dirnames_to_char_ptr_vec_append): Take an std::vector of
10870         gdb::unique_xmalloc_ptr, adjust the code.
10871         (dirnames_to_char_ptr_vec): Return an std::vector of
10872         gdb::unique_xmalloc_ptr, adjust the code.
10873         * auto-load.c (auto_load_safe_path_vec): Change type to
10874         std::vector of gdb::unique_xmalloc_ptr.
10875         (auto_load_expand_dir_vars): Return an std::vector of
10876         gdb::unique_xmalloc_ptr, adjust the code.
10877         (auto_load_safe_path_vec_update): Adjust.
10878         (filename_is_in_auto_load_safe_path_vec): Adjust.
10879         (auto_load_objfile_script_1): Adjust.
10880         * build-id.c (build_id_to_debug_bfd): Adjust.
10881         * linux-thread-db.c (thread_db_load_search): Adjust.
10882         * source.c (add_path): Adjust.
10883         (openp): Adjust.
10884         * symfile.c (find_separate_debug_file): Adjust.
10885         * utils.c (do_free_char_ptr_vec): Remove.
10886         (make_cleanup_free_char_ptr_vec): Remove.
10887
10888 2018-03-01  Sergio Durigan Junior  <sergiodj@redhat.com>
10889
10890         PR gdb/22907
10891         * common/pathstuff.c: Conditionally include "<windows.h>".
10892
10893 2018-03-01  Georg Sauthoff  <mail@georg.so>
10894
10895         PR gdb/22888
10896         * gcore.in: Quote variables and switch interpreter to bash.
10897
10898 2018-03-01  Tom Tromey  <tom@tromey.com>
10899
10900         * dwarf2read.c (alloc_discriminant_info): Fix default_index
10901         assertion.  Add assertion for discriminant_index.
10902         (quirk_rust_enum): Use correct base type name in univariant case.
10903
10904 2018-03-01  Simon Marchi  <simon.marchi@ericsson.com>
10905
10906         * record.c (get_call_history_modifiers): Return a
10907         record_print_flags.
10908         (cmd_record_call_history): Adjust.
10909         * record-btrace.c (record_btrace_call_history): Adjust.
10910         (record_btrace_call_history_range): Adjust.
10911         (record_btrace_call_history_from): Adjust.
10912         * target-debug.h (target_debug_print_record_print_flags): New.
10913         * target-delegates.c: Re-generate.
10914         * target.c (target_call_history): Change flags type.
10915         (target_call_history_from): Likewise.
10916         (target_call_history_range): Likewise.
10917         * target.h (struct target_ops) <target_call_history>: Likewise.
10918         (target_call_history_from): Likewise.
10919         (target_call_history_range): Likewise.
10920
10921 2018-02-28  Sergio Durigan Junior  <sergiodj@redhat.com>
10922             Simon Marchi  <simon.marchi@polymtl.ca>
10923
10924         * common/common-utils.c: Include "sys/stat.h".
10925         (is_regular_file): Move here from "source.c"; change return
10926         type to "bool".
10927         * common/common-utils.h (is_regular_file): New prototype.
10928         * common/pathstuff.c (contains_dir_separator): New function.
10929         * common/pathstuff.h (contains_dir_separator): New prototype.
10930         * source.c: Don't include "sys/stat.h".
10931         (is_regular_file): Move to "common/common-utils.c".
10932
10933 2018-02-28  Sergio Durigan Junior  <sergiodj@redhat.com>
10934
10935         * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
10936         (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
10937         * auto-load.c: Include "common/pathstuff.h".
10938         * common/common-def.h (current_directory): Move here.
10939         * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
10940         function.
10941         * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
10942         prototype.
10943         * common/pathstuff.c: New file.
10944         * common/pathstuff.h: New file.
10945         * compile/compile.c: Include "common/pathstuff.h".
10946         * defs.h (current_directory): Move to "common/common-defs.h".
10947         * dwarf2read.c: Include "common/pathstuff.h".
10948         * exec.c: Likewise.
10949         * guile/scm-safe-call.c: Likewise.
10950         * linux-thread-db.c: Likewise.
10951         * main.c: Likewise.
10952         * nto-tdep.c: Likewise.
10953         * objfiles.c: Likewise.
10954         * source.c: Likewise.
10955         * symtab.c: Likewise.
10956         * utils.c: Include "common/pathstuff.h".
10957         (gdb_realpath): Move to "common/pathstuff.c".
10958         (gdb_realpath_keepfile): Likewise.
10959         (gdb_abspath): Likewise.
10960         * utils.h (gdb_realpath): Move to "common/pathstuff.h".
10961         (gdb_realpath_keepfile): Likewise.
10962         (gdb_abspath): Likewise.
10963
10964 2018-02-28  John Baldwin  <jhb@FreeBSD.org>
10965
10966         * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
10967         wildcard process pid for super_resume for kernels with a
10968         specific bug.
10969
10970 2018-02-27  Phil Muldoon  <pmuldoon@redhat.com>
10971
10972         * compile/compile.c (get_args): Add additional comments
10973         explaining function.
10974
10975 2018-02-27  Simon Marchi  <simon.marchi@polymtl.ca>
10976             Tom Tromey  <tom@tromey.com>
10977
10978         * target.h (memory_write_request_s): Remove typedef.  Don't define
10979         VEC.
10980         (target_write_memory_blocks): Change argument to std::vector.
10981         (struct memory_write_request): Add constructor.
10982         * target-memory.c (compare_block_starting_address): Return bool.
10983         Change argument types.
10984         (claim_memory): Change arguments to use std::vector.
10985         (split_regular_and_flash_blocks, blocks_to_erase)
10986         (compute_garbled_blocks): Likewise.
10987         (cleanup_request_data, cleanup_write_requests_vector): Remove.
10988         (target_write_memory_blocks): Change argument to std::vector.
10989         * symfile.c (struct load_section_data): Add constructor and
10990         destructor.  Use std::vector for "requests".
10991         (struct load_progress_data): Add initializers.
10992         (load_section_callback): Update.  Use "new".
10993         (clear_memory_write_data): Remove.
10994         (generic_load): Update.
10995
10996 2018-02-27  Alan Hayward  <alan.hayward@arm.com>
10997
10998         * arch/aarch64.h: Use common/tdesc.h.
10999
11000 2018-02-26  Maciej W. Rozycki  <macro@mips.com>
11001
11002         * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
11003         architecture with a 64-bit ABI.
11004
11005 2018-02-26  Maciej W. Rozycki  <macro@mips.com>
11006
11007         * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
11008         ahead of target description loading.
11009
11010 2018-02-26  Tom Tromey  <tom@tromey.com>
11011
11012         * stack.c (backtrace_command_1): Update.
11013         * python/python-internal.h (gdbpy_apply_frame_filter): Change type
11014         of "flags".
11015         * python/py-framefilter.c (py_print_frame)
11016         (gdbpy_apply_frame_filter): Change type of "flags".
11017         * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
11018         of "flags".
11019         (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
11020         (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
11021         * extension.h (enum frame_filter_flag): Rename from
11022         frame_filter_flags.
11023         (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
11024         (apply_ext_lang_frame_filter): Change type of "flags".
11025         * extension.c (apply_ext_lang_frame_filter): Change type of
11026         "flags".
11027         * extension-priv.h (struct extension_language_ops)
11028         <apply_frame_filter>: Change type of "flags".
11029
11030 2018-02-26  Tom Tromey  <tom@tromey.com>
11031
11032         PR python/16497:
11033         * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag.  Fix
11034         off-by-one in py_end computation.
11035         * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
11036         PRINT_MORE_FRAMES.
11037         * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
11038         constant.
11039
11040 2018-02-26  Tom Tromey  <tom@tromey.com>
11041
11042         * dwarf2read.c (struct variant_field): New.
11043         (struct nextfield) <variant>: New field.
11044         (dwarf2_add_field): Handle DW_TAG_variant_part.
11045         (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
11046         discriminated union.
11047         (read_structure_type): Handle DW_TAG_variant_part.
11048         (handle_struct_member_die): New function, extracted from
11049         process_structure_scope.  Handle DW_TAG_variant.
11050         (process_structure_scope): Handle discriminated unions.  Call
11051         handle_struct_member_die.
11052
11053 2018-02-26  Tom Tromey  <tom@tromey.com>
11054
11055         * rust-lang.h (rust_last_path_segment): Declare.
11056         * rust-lang.c (rust_last_path_segment): Now public.  Change
11057         contract.
11058         (struct disr_info): Remove.
11059         (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
11060         (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
11061         (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
11062         (rust_enum_p, rust_enum_variant): New function.
11063         (rust_underscore_fields): Remove "offset" parameter.
11064         (rust_print_enum): New function.
11065         (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
11066         <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
11067         (rust_print_struct_def): Add "for_rust_enum" parameter.  Handle
11068         enums.
11069         (rust_internal_print_type): New function, from rust_print_type.
11070         Remove enum code.
11071         (rust_print_type): Call rust_internal_print_type.
11072         (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
11073         Update enum handling.
11074         * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
11075         (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
11076         (rust_union_quirks): New functions.
11077         (process_full_comp_unit, process_full_type_unit): Call
11078         rust_union_quirks.
11079         (process_structure_scope): Update rust_unions if necessary.
11080
11081 2018-02-26  Tom Tromey  <tom@tromey.com>
11082
11083         * value.h (value_union_variant): Declare.
11084         * valops.c (value_union_variant): New function.
11085         * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
11086         (struct discriminant_info): New.
11087         (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
11088         enumerator.
11089         (struct main_type) <flag_discriminated_union>: New field.
11090
11091 2018-02-26  Tom Tromey  <tom@tromey.com>
11092
11093         * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11094         unittests/unpack-selftests.c.
11095         * unittests/unpack-selftests.c: New file.
11096         * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
11097
11098 2018-02-26  Yao Qi  <yao.qi@linaro.org>
11099
11100         * dwarf2read.c (struct partial_die_info) <read>: New method.
11101         (read_partial_die): Remove the declaration.
11102         (load_partial_dies): Update.
11103         (partial_die_info::partial_die_info):
11104         (read_partial_die): Change it to partial_die_info::read.
11105
11106 2018-02-26  Yao Qi  <yao.qi@linaro.org>
11107
11108         * dwarf2read.c (struct partial_die_info) <fixup>: New method.
11109         (fixup_partial_die): Remove declaration.
11110         (scan_partial_symbols): Update.
11111         (partial_die_parent_scope): Likewise.
11112         (partial_die_full_name): Likewise.
11113         (fixup_partial_die): Change it to partial_die_info::fixup.
11114
11115 2018-02-26  Yao Qi  <yao.qi@linaro.org>
11116
11117         * dwarf2read.c (read_partial_die): Update the declaration.
11118         (load_partial_dies): Caller update.
11119         (read_partial_die): Remove one argument abbrev_len.
11120
11121 2018-02-26  Yao Qi  <yao.qi@linaro.org>
11122
11123         * dwarf2read.c (struct partial_die_info): Add ctor, delete
11124         assignment operator.
11125         (load_partial_dies): Use ctor and copy ctor.
11126         (read_partial_die): Update.
11127         (dwarf2_cu::find_partial_die): Use ctor.
11128
11129 2018-02-26  Yao Qi  <yao.qi@linaro.org>
11130
11131         * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
11132         (find_partial_die_in_comp_unit): Change it to
11133         dwarf2_cu::find_partial_die.
11134         (find_partial_die): Update.
11135
11136 2018-02-26  Yao Qi  <yao.qi@linaro.org>
11137
11138         * dwarf2read.c (read_partial_die): Remove the code checking abbrev
11139         is NULL.
11140
11141 2018-02-26  Yao Qi  <yao.qi@linaro.org>
11142
11143         * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
11144
11145 2018-02-26  Alan Hayward  <alan.hayward@arm.com>
11146
11147         * arch/amd64.h: Use common/tdesc.h.
11148         * arch/i386.c: Likewise.
11149         * arch/i386.h: Likewise.
11150         * arch/tic6x.c: Likewise.
11151         * arch/tdesc.h: Move file from here...
11152         * common/tdesc.h: ...to here.
11153         * features/aarch64-core.c: Regenerate.
11154         * features/aarch64-fpu.c: Regenerate.
11155         * features/i386/32bit-avx.c: Regenerate.
11156         * features/i386/32bit-avx512.c: Regenerate.
11157         * features/i386/32bit-core.c: Regenerate.
11158         * features/i386/32bit-linux.c: Regenerate.
11159         * features/i386/32bit-mpx.c: Regenerate.
11160         * features/i386/32bit-pkeys.c: Regenerate.
11161         * features/i386/32bit-sse.c: Regenerate.
11162         * features/i386/64bit-avx.c: Regenerate.
11163         * features/i386/64bit-avx512.c: Regenerate.
11164         * features/i386/64bit-core.c: Regenerate.
11165         * features/i386/64bit-linux.c: Regenerate.
11166         * features/i386/64bit-mpx.c: Regenerate.
11167         * features/i386/64bit-pkeys.c: Regenerate.
11168         * features/i386/64bit-segments.c: Regenerate.
11169         * features/i386/64bit-sse.c: Regenerate.
11170         * features/i386/x32-core.c: Regenerate.
11171         * features/tic6x-c6xp.c: Regenerate.
11172         * features/tic6x-core.c: Regenerate.
11173         * features/tic6x-gp.c: Regenerate.
11174         * target-descriptions.c: Use common/tdesc.h.
11175         * target-descriptions.h: Likewise.
11176
11177 2018-02-24  Tom Tromey  <tom@tromey.com>
11178
11179         * linux-thread-db.c (try_thread_db_load_from_pdir_1)
11180         (try_thread_db_load_from_dir, thread_db_load_search): Use
11181         std::string.
11182         (info_auto_load_libthread_db_compare): Return bool.  Change
11183         argument types.
11184         (info_auto_load_libthread_db): Use std::vector, std::string.
11185         Remove cleanups.
11186
11187 2018-02-24  Tom Tromey  <tom@tromey.com>
11188
11189         * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
11190         std::string.
11191         * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
11192         std::string*.
11193         * gdbarch.c: Rebuild.
11194         * gdbarch.h: Rebuild.
11195         * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
11196         * arch-utils.h (default_fast_tracepoint_valid_at): Update.
11197         * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
11198         std::string*.
11199
11200 2018-02-23  Simon Marchi  <simon.marchi@polymtl.ca>
11201
11202         * gdbtypes.h (sect_offset): Change type to uint64_t.
11203         (sect_offset_str): New function.
11204         * dwarf2read.c (create_addrmap_from_aranges): Use
11205         sect_offset_str.
11206         (error_check_comp_unit_head): Likewise.
11207         (create_debug_type_hash_table): Likewise.
11208         (read_cutu_die_from_dwo): Likewise.
11209         (init_cutu_and_read_dies): Likewise.
11210         (init_cutu_and_read_dies_no_follow): Likewise.
11211         (process_psymtab_comp_unit_reader): Likewise.
11212         (partial_die_parent_scope): Likewise.
11213         (peek_die_abbrev): Likewise.
11214         (process_queue): Likewise.
11215         (dwarf2_physname): Likewise.
11216         (read_namespace_alias): Likewise.
11217         (read_import_statement): Likewise.
11218         (create_dwo_cu_reader): Likewise.
11219         (create_cus_hash_table): Likewise.
11220         (lookup_dwo_cutu): Likewise.
11221         (inherit_abstract_dies): Likewise.
11222         (read_func_scope): Likewise.
11223         (read_call_site_scope): Likewise.
11224         (dwarf2_add_member_fn): Likewise.
11225         (read_common_block): Likewise.
11226         (read_module_type): Likewise.
11227         (read_typedef): Likewise.
11228         (read_subrange_type): Likewise.
11229         (load_partial_dies): Likewise.
11230         (read_partial_die): Likewise.
11231         (find_partial_die): Likewise.
11232         (read_str_index): Likewise.
11233         (dwarf2_string_attr): Likewise.
11234         (build_error_marker_type): Likewise.
11235         (lookup_die_type): Likewise.
11236         (dump_die_shallow): Likewise.
11237         (follow_die_ref): Likewise.
11238         (dwarf2_fetch_die_loc_sect_off): Likewise.
11239         (dwarf2_fetch_constant_bytes): Likewise.
11240         (follow_die_sig): Likewise.
11241         (get_signatured_type): Likewise.
11242         (get_DW_AT_signature_type): Likewise.
11243         (dwarf2_find_containing_comp_unit): Likewise.
11244         (set_die_type): Likewise.
11245
11246 2018-02-21  John Baldwin  <jhb@FreeBSD.org>
11247
11248         * arch/aarch64.c: Include "common-defs.h".
11249         * arch/amd64.c: Likewise.
11250         * arch/i386.c: Likewise.
11251
11252 2018-02-21  Tom Tromey  <tom@tromey.com>
11253
11254         * value.h: (extract_field_op): Update.
11255         * eval.c (extract_field_op): Return a const char *.
11256         * expression.h (parse_expression_for_completion): Update.
11257         * completer.c (complete_expression): Update.
11258         (add_struct_fields): Make fieldname const.
11259         * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
11260         (mark_completion_tag, parse_exp_in_context_1): Update.
11261         (parse_expression_for_completion): Change "name" to
11262         unique_xmalloc_ptr*.
11263
11264 2018-02-21  Tom Tromey  <tom@tromey.com>
11265
11266         * infcall.c (call_function_by_hand_dummy): Use std::vector.
11267
11268 2018-02-21  Yao Qi  <yao.qi@linaro.org>
11269
11270         * avr-tdep.c (avr_read_pc): Change parameter type to
11271         readable_regcache.
11272         * gdbarch.sh (read_pc): Likewise.
11273         * gdbarch.c: Re-generated.
11274         * gdbarch.h: Re-generated.
11275         * hppa-tdep.c (hppa_read_pc): Change parameter type to
11276         readable_regcache.
11277         * ia64-tdep.c (ia64_read_pc): Likewise.
11278         * mips-tdep.c (mips_read_pc): Likewise.
11279         * spu-tdep.c (spu_read_pc): Likewise.
11280
11281 2018-02-21  Yao Qi  <yao.qi@linaro.org>
11282
11283         * Makefile.in (COMMON_SFILES): Add regcache-dump.c
11284         * regcache-dump.c: New file.
11285         * regcache.c: Move register_dump to regcache-dump.c.
11286         (maintenance_print_registers): Likewise.
11287         (maintenance_print_raw_registers): Likewise.
11288         (maintenance_print_cooked_registers): Likewise.
11289         (maintenance_print_register_groups): Likewise.
11290         (maintenance_print_remote_registers): Likewise.
11291         (_initialize_regcache): Likewise.
11292         * regcache.h (register_dump): Moved from regcache.c.
11293
11294 2018-02-21  Yao Qi  <yao.qi@linaro.org>
11295
11296         * regcache.c (regcache::regcache): Update.
11297         (regcache::invalidate): Move it to detached_regcache::invalidate.
11298         (get_thread_arch_aspace_regcache): Update.
11299         (regcache::raw_update): Update.
11300         (regcache::cooked_read): Remove some code.
11301         (regcache::cooked_read_value): Likewise.
11302         (regcache::raw_write): Remove assert on m_readonly_p.
11303         (regcache::raw_supply_integer): Move it to
11304         detached_regcache::raw_supply_integer.
11305         (regcache::raw_supply_zeroed): Likewise.
11306         * regcache.h (detached_regcache) <raw_supply_integer>: New
11307         declaration.
11308         <raw_supply_zeroed, invalidate>: Likewise.
11309         (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
11310         <invalidate>: Likewise.
11311         <m_readonly_p>: Removed.
11312
11313 2018-02-21  Yao Qi  <yao.qi@linaro.org>
11314
11315         * infcmd.c (get_return_value): Let stop_regs point to
11316         get_current_regcache.
11317         * regcache.c (regcache::regcache): Remove.
11318         (register_dump_reg_buffer): New class.
11319         (regcache_print): Adjust.
11320         * regcache.h (regcache): Remove constructors.
11321
11322 2018-02-21  Yao Qi  <yao.qi@linaro.org>
11323
11324         * regcache.c (class register_dump): New class.
11325         (register_dump_regcache, register_dump_none): New class.
11326         (register_dump_remote, register_dump_groups): New class.
11327         (regcache_print): Update.
11328         * regcache.h (regcache_dump_what): Move it to regcache.c.
11329         (regcache) <dump>: Remove.
11330
11331 2018-02-21  Yao Qi  <yao.qi@linaro.org>
11332
11333         * jit.c (struct jit_unwind_private) <regcache>: Change its type to
11334          reg_buffer_rw *.
11335         (jit_unwind_reg_set_impl): Call raw_supply.
11336         (jit_frame_sniffer): Use reg_buffer_rw.
11337         * record-full.c (record_full_core_regbuf): Change its type.
11338         (record_full_core_open_1): Use reg_buffer_rw.
11339         (record_full_close): Likewise.
11340         (record_full_core_fetch_registers): Use regcache->raw_supply.
11341         (record_full_core_store_registers): Likewise.
11342         * regcache.c (regcache::get_register_status): Move it to
11343         reg_buffer.
11344         (regcache_raw_set_cached_value): Remove.
11345         (regcache::raw_set_cached_value): Remove.
11346         (regcache::raw_write): Call raw_supply.
11347         (regcache::raw_supply): Move it to reg_buffer_rw.
11348         * regcache.h (regcache_raw_set_cached_value): Remove.
11349         (reg_buffer_rw): New class.
11350
11351 2018-02-21  Yao Qi  <yao.qi@linaro.org>
11352
11353         * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
11354         readonly_detached_regcache.
11355         (dummy_frame_prev_register): Use regcache->cooked_read.
11356         * frame.c (frame_save_as_regcache): Change return type.
11357         (frame_pop): Update.
11358         * frame.h (frame_save_as_regcache): Update declaration.
11359         * inferior.h (get_infcall_suspend_state_regcache): Update
11360         declaration.
11361         * infrun.c (infcall_suspend_state) <registers>: use
11362         readonly_detached_regcache.
11363         (save_infcall_suspend_state): Don't use regcache_dup.
11364         (get_infcall_suspend_state_regcache): Change return type.
11365         * linux-fork.c (struct fork_info) <savedregs>: Change to
11366         readonly_detached_regcache.
11367         <pc>: New field.
11368         (fork_save_infrun_state): Don't use regcache_dup.
11369         (info_checkpoints_command): Adjust.
11370         * mi/mi-main.c (register_changed_p): Update declaration.
11371         (mi_cmd_data_list_changed_registers): Use
11372         readonly_detached_regcache.
11373         (register_changed_p): Change parameter type to
11374         readonly_detached_regcache.
11375         * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
11376         readonly_detached_regcache.
11377         (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
11378         * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
11379         New.
11380         (regcache::save): Move it to reg_buffer.
11381         (regcache::restore): Change parameter type.
11382         (regcache_dup): Remove.
11383         * regcache.h (reg_buffer) <save>: New method.
11384         (readonly_detached_regcache): New class.
11385         * spu-tdep.c (spu2ppu_cache) <regcache>: Use
11386         readonly_detached_regcache.
11387         (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
11388
11389 2018-02-21  Yao Qi  <yao.qi@linaro.org>
11390
11391         * frame.c (frame_save_as_regcache): Use regcache method save.
11392         (frame_pop): Use regcache method restore.
11393         * infrun.c (restore_infcall_suspend_state): Likewise.
11394         * linux-fork.c (fork_load_infrun_state): Likewise.
11395         * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
11396         save.
11397         * regcache.c (regcache_save): Remove.
11398         (regcache::restore): More asserts.
11399         (regcache_cpy): Remove.
11400         * regcache.h (regcache_save): Remove the declaration.
11401         (regcache::restore): Move from private to public.
11402         Remove the friend declaration of regcache_cpy.
11403         (regcache_cpy): Remove declaration.
11404
11405 2018-02-21  Yao Qi  <yao.qi@linaro.org>
11406
11407         * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
11408         parameter type to 'readable_regcache *'.
11409         * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
11410         * arm-tdep.c (arm_neon_quad_read): Likewise.
11411         (arm_pseudo_read): Likewise.
11412         * avr-tdep.c (avr_pseudo_register_read): Likewise.
11413         * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
11414         * frv-tdep.c (frv_pseudo_register_read): Likewise.
11415         * gdbarch.c: Re-generated.
11416         * gdbarch.h: Re-generated.
11417         * gdbarch.sh (pseudo_register_read): Change parameter type to
11418         'readable_regcache *'.
11419         (pseudo_register_read_value): Likewise.
11420         * h8300-tdep.c (pseudo_from_raw_register): Likewise.
11421         (h8300_pseudo_register_read): Likewise.
11422         * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
11423         * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
11424         (i386_pseudo_register_read_into_value): Likewise.
11425         (i386_pseudo_register_read_value): Likewise.
11426         * i386-tdep.h (i386_pseudo_register_read_into_value): Update
11427         declaration.
11428         * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
11429         * m32c-tdep.c (m32c_raw_read): Likewise.
11430         (m32c_read_flg): Likewise.
11431         (m32c_banked_register): Likewise.
11432         (m32c_banked_read): Likewise.
11433         (m32c_sb_read): Likewise.
11434         (m32c_part_read): Likewise.
11435         (m32c_cat_read): Likewise.
11436         (m32c_r3r2r1r0_read): Likewise.
11437         (m32c_pseudo_register_read): Likewise.
11438         * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
11439         * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
11440         (mep_pseudo_cr64_read): Likewise.
11441         (mep_pseudo_register_read): Likewise.
11442         * mips-tdep.c (mips_pseudo_register_read): Likewise.
11443         * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
11444         * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
11445         * regcache.c (regcache::raw_read): Move it to readable_regcache.
11446         (regcache::cooked_read): Likewise.
11447         (regcache::cooked_read_value): Likewise.
11448         (regcache_cooked_read_signed):
11449         (regcache::cooked_read): Likewise.
11450         * regcache.h (readable_regcache): New class.
11451         (regcache): Inherit readable_regcache.  Move some methods to
11452         readable_regcache.
11453         * rl78-tdep.c (rl78_pseudo_register_read): Change
11454         parameter type to 'readable_regcache *'.
11455         * rs6000-tdep.c (do_regcache_raw_read): Remove.
11456         (e500_pseudo_register_read): Change parameter type to
11457         'readable_regcache *'.
11458         (dfp_pseudo_register_read): Likewise.
11459         (vsx_pseudo_register_read): Likewise.
11460         (efpr_pseudo_register_read): Likewise.
11461         * s390-tdep.c (s390_pseudo_register_read): Likewise.
11462         * sh-tdep.c (sh_pseudo_register_read): Likewise.
11463         * sh64-tdep.c (pseudo_register_read_portions): Likewise.
11464         (sh64_pseudo_register_read): Likewise.
11465         * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
11466         * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
11467         * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
11468         (spu_pseudo_register_read): Likewise.
11469         * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
11470         (xtensa_pseudo_register_read): Likewise.
11471
11472 2018-02-21  Yao Qi  <yao.qi@linaro.org>
11473
11474         * regcache.c (regcache::regcache): Call reg_buffer ctor.
11475         (regcache::arch): Move it to reg_buffer::arch.
11476         (regcache::register_buffer): Likewise.
11477         (regcache::assert_regnum): Likewise.
11478         (regcache::num_raw_registers): Likewise.
11479         * regcache.h (reg_buffer): New class.
11480         (regcache): Inherit reg_buffer.
11481
11482 2018-02-20  Simon Marchi  <simon.marchi@ericsson.com>
11483
11484         * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
11485         gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
11486
11487 2018-02-20  Markus Metzger  <markus.t.metzger@intel.com>
11488
11489         * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
11490
11491 2018-02-19  Alan Hayward  <alan.hayward@arm.com>
11492
11493         * Makefile.in: (COMMON_SFILES): Add common/*.c files.
11494         (SFILES): Remove common/*.c files.
11495         (COMMON_OBS): Remove some *.o files built from common/*.c files.
11496         * common/common.host: Add common reference.
11497         * configure.ac: Likewise.
11498         * configure: Regenerate.
11499
11500 2018-02-16  Yao Qi  <yao.qi@linaro.org>
11501
11502         * block.c (block_namespace_info): Inherit allocate_on_obstack.
11503         (block_initialize_namespace): Use new.
11504         * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
11505         (dwarf2_free_objfile): Use delete.
11506         * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
11507         (copy_type_recursive): Use new.
11508         * gdb_obstack.h (allocate_on_obstack): New.
11509
11510 2018-02-15  Yao Qi  <yao.qi@linaro.org>
11511
11512         PR gdb/22849
11513         * inferior.c (exit_inferior_1): Reset inf->control.
11514
11515 2018-02-15  Joel Brobecker  <brobecker@adacore.com>
11516
11517         * ada-lang.c (ada_to_fixed_value_create): Delete advance
11518         declaration.
11519
11520 2018-02-14  Pedro Alves  <palves@redhat.com>
11521
11522         * frame-unwind.c (frame_unwind_try_unwinder): Always call
11523         frame_cleanup_after_sniffer on exception.
11524
11525 2018-02-14  Tom Tromey  <tom@tromey.com>
11526
11527         * solist.h (struct target_so_ops) <bfd_open>: Make pathname
11528         const.
11529         (solib_bfd_open): Make pathname const.
11530         * solib.c (solib_bfd_open): Make pathname const.
11531         * solib-spu.c (spu_bfd_fopen): Make name const.
11532         (spu_bfd_open): Make pathname const.
11533         * solib-darwin.c (darwin_bfd_open): Make pathname const.
11534         * solib-aix.c (solib_aix_bfd_open): Make pathname const.
11535
11536 2018-02-14  Tom Tromey  <tom@tromey.com>
11537
11538         * symfile.c (symfile_bfd_open): Update.
11539         * source.h (openp, source_full_path_of, find_and_open_source):
11540         Change argument type to unique_xmalloc_ptr.
11541         * source.c (openp): Take a unique_xmalloc_ptr.
11542         (source_full_path_of, find_and_open_source): Likewise.
11543         (open_source_file, symtab_to_fullname): Update.
11544         * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
11545         unique_xmalloc_ptr.
11546         * solib.c (solib_find_1): Use unique_xmalloc_ptr.
11547         (exec_file_find): Update.
11548         * psymtab.c (psymtab_to_fullname): Update.
11549         * nto-tdep.h (nto_find_and_open_solib): Update.
11550         * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
11551         unique_xmalloc_ptr.
11552         * exec.c (exec_file_attach): Update.
11553         * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
11554         * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
11555
11556 2018-02-14  Tom Tromey  <tom@tromey.com>
11557
11558         * solib.c: Include source.h.
11559         * nto-tdep.c: Include source.h.
11560         * mi/mi-cmd-env.c: Include source.h.
11561         * infcmd.c: Include source.h.
11562         * exec.c: Include source.h.
11563         * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
11564         (add_path, directory_switch, source_path, init_source_path): Move
11565         declarations...
11566         * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
11567         (add_path, directory_switch, source_path, init_source_path):
11568         ...here.
11569
11570 2018-02-14  Tom Tromey  <tom@tromey.com>
11571
11572         * solist.h (exec_file_find, solib_find): Return
11573         unique_xmalloc_ptr.
11574         (solib_bfd_fopen): Take a const char *.
11575         * solib.c (solib_find_1): Return unique_xmalloc_ptr.
11576         (exec_file_find, solib_find): Likewise.
11577         (solib_bfd_fopen): Do not take ownership of "pathname".
11578         (solib_bfd_open): Use unique_xmalloc_ptr.
11579         * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
11580         * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
11581         * infrun.c (follow_exec): Use unique_xmalloc_ptr.
11582         * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
11583
11584 2018-02-14  Joel Brobecker  <brobecker@adacore.com>
11585
11586         * ada-lang.c (name_match_type_from_name): Remove reference to
11587         ada_name_for_lookup in function's documentation.
11588         * ada-lang.h (ada_name_for_lookup): Delete declaration.
11589
11590 2018-02-13  Simon Marchi  <simon.marchi@polymtl.ca>
11591
11592         * defs.h (enum openp_flags): New enum.
11593         (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
11594         Move to enum openp_flags.
11595         (openp_flags): New enum flags.
11596         (openp): Change parameter type to openp_flags.
11597         * source.c (openp): Change parameter type to openp_flags.
11598         * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
11599         * dwarf2read.c (try_open_dwop_file): Use openp_flags.
11600
11601 2018-02-13  Simon Marchi  <simon.marchi@polymtl.ca>
11602
11603         * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
11604         per-command.
11605
11606 2018-02-12  Andrew Burgess  <andrew.burgess@embecosm.com>
11607
11608         * dwarf2read.c (dwarf2_release_queue): Delete function, move body
11609         into...
11610         (class dwarf2_queue_guard): ...the destructor of this new class.
11611         (dw2_do_instantiate_symtab): Create instance of the new class
11612         dwarf2_queue_guard, remove cleanup.
11613
11614 2018-02-09  Tom Tromey  <tom@tromey.com>
11615
11616         * source.c (find_source_lines): Don't reference past the end of
11617         the vector.
11618
11619 2018-02-09  Markus Metzger  <markus.t.metzger@intel.com>
11620
11621         * remote.c (remote_btrace_maybe_reopen): Change error message.
11622         * btrace.c (btrace_enable): Likewise.
11623         (parse_xml_btrace): Likewise.
11624         (parse_xml_btrace_conf): Likewise.
11625
11626 2018-02-09  Markus Metzger  <markus.t.metzger@intel.com>
11627
11628         * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
11629         (linux_enable_pt, linux_enable_bts): Call
11630         diagnose_perf_event_open_fail.
11631
11632 2018-02-09  Markus Metzger  <markus.t.metzger@intel.com>
11633
11634         * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
11635         Remove parameter and change return type.  Update callers.  Move it.
11636         (linux_enable_bts, linux_enable_pt): Improve error message.
11637         (linux_enable_pt): Remove zero buffer size check.
11638         (linux_enable_btrace): Improve error messages.  Remove NULL return
11639         check.
11640
11641 2018-02-09  Markus Metzger  <markus.t.metzger@intel.com>
11642
11643         * btrace.c (btrace_enable): Remove target_supports_btrace call.
11644         * nat/linux-btrace.c (perf_event_pt_event_type): Move.
11645         (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
11646         (linux_supports_pt, linux_supports_btrace): Remove.
11647         (linux_enable_bts): Call cpu_supports_bts.
11648         * nat/linux-btrace.h (linux_supports_btrace): Remove.
11649         * remote.c (remote_supports_btrace): Remove.
11650         (init_remote_ops): Remove remote_supports_btrace.
11651         * target-delegates.c: Regenerated.
11652         * target.c (target_supports_btrace): Remove.
11653         * target.h (target_ops) <to_supports_btrace>: Remove
11654         (target_supports_btrace): Remove.
11655         * x86-linux-nat.c (x86_linux_create_target): Remove
11656         linux_supports_btrace.
11657
11658 2018-02-09  Markus Metzger  <markus.t.metzger@intel.com>
11659
11660         * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
11661         btrace failed.
11662         * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
11663         exception and use message in own exception.
11664
11665 2018-02-09  Markus Metzger  <markus.t.metzger@intel.com>
11666
11667         * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
11668         (perf_event_pt_event_type): Use gdb_file_up.
11669         (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
11670         scoped_fd, and scoped_mmap.
11671
11672 2018-02-09  Markus Metzger  <markus.t.metzger@intel.com>
11673
11674         * common/scoped_mmap.h: New.
11675         * unittests/scoped_mmap-selftest.c: New.
11676         * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11677         unittests/scoped_mmap-selftest.c.
11678
11679 2018-02-09  Markus Metzger  <markus.t.metzger@intel.com>
11680
11681         * common/scoped_fd.h: New.
11682         * unittests/scoped_fd-selftest.c: New.
11683         * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11684         unittests/scoped_fd-selftest.c.
11685
11686 2018-02-09  Tom Tromey  <tom@tromey.com>
11687
11688         * auto-load.c (auto_load_section_scripts): Use
11689         gdb::unique_xmalloc_ptr.
11690
11691 2018-02-09  Tom Tromey  <tom@tromey.com>
11692
11693         * auto-load.c (execute_script_contents): Use std::string.
11694
11695 2018-02-09  Joel Brobecker  <brobecker@adacore.com>
11696
11697         * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
11698         Python function, rather than a new command.
11699
11700 2018-02-08  Tom Tromey  <tom@tromey.com>
11701
11702         * solib.c (solib_find_1): Use std::string.
11703         (solib_bfd_fopen): Use unique_xmalloc_ptr.
11704
11705 2018-02-08  Tom Tromey  <tom@tromey.com>
11706
11707         * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
11708
11709 2018-02-08  Tom Tromey  <tom@tromey.com>
11710
11711         * source.c (find_source_lines): Use gdb::def_vector.
11712
11713 2018-02-08  Tom Tromey  <tom@tromey.com>
11714
11715         * macrocmd.c (struct temporary_macro_definition): New.
11716         (macro_define_command): Use temporary_macro_definition.  Remove
11717         cleanups.
11718         (free_macro_definition_ptr): Remove.
11719
11720 2018-02-08  Tom Tromey  <tom@tromey.com>
11721
11722         * macroexp.c (maybe_expand): Use std::string.
11723
11724 2018-02-08  Tom Tromey  <tom@tromey.com>
11725
11726         * macroexp.c (struct macro_buffer): Add initializers for some
11727         members.
11728         (init_buffer, init_shared_buffer, free_buffer)
11729         (free_buffer_return_text): Remove.
11730         (macro_buffer): New constructors.
11731         (~macro_buffer): New destructor.
11732         (macro_buffer::set_shared): New method.
11733         (macro_buffer::resize_buffer, macro_buffer::appendc)
11734         (macro_buffer::appendmem): Now methods, not free functions.
11735         (set_token, append_tokens_without_splicing, stringify)
11736         (macro_stringify): Update.
11737         (gather_arguments): Change return type.  Remove argc_p argument,
11738         add args_ptr argument.  Use std::vector.
11739         (substitute_args): Remove argc argument.  Accept std::vector.
11740         (expand): Update.  Use std::vector.
11741         (scan, macro_expand, macro_expand_next): Update.
11742
11743 2018-02-08  Tom Tromey  <tom@tromey.com>
11744
11745         * symtab.c (default_collect_symbol_completion_matches_break_on):
11746         Use unique_xmalloc_ptr.
11747         * macroscope.h: (sal_macro_scope, user_macro_scope)
11748         (default_macro_scope): Return unique_xmalloc_ptr.
11749         * macroscope.c (sal_macro_scope, user_macro_scope)
11750         (default_macro_scope): Return unique_xmalloc_ptr.
11751         * macroexp.h (macro_expand, macro_expand_once): Return
11752         unique_xmalloc_ptr.
11753         * macroexp.c (macro_expand, macro_expand_once): Return
11754         unique_xmalloc_ptr.
11755         * macrocmd.c (macro_expand_command, macro_expand_once_command)
11756         (info_macro_command, info_macros_command): Use
11757         unique_xmalloc_ptr.
11758         * compile/compile-c-support.c (write_macro_definitions): Use
11759         unique_xmalloc_ptr.
11760         * c-exp.y (c_parse): Use unique_xmalloc_ptr.
11761
11762 2018-02-07  Simon Marchi  <simon.marchi@ericsson.com>
11763
11764         * value.c (value_static_field): Assign field type instead of
11765         containing type when returning an optimized out value.
11766
11767 2018-02-06  Yao Qi  <yao.qi@linaro.org>
11768
11769         * ft32-tdep.c (ft32_read_pc): Remove.
11770         (ft32_write_pc): Remove.
11771         (ft32_gdbarch_init): Update.
11772         * m32r-tdep.c (m32r_read_pc): Remove.
11773         (m32r_gdbarch_init): Update.
11774         * mep-tdep.c (mep_read_pc): Remove.
11775         (mep_gdbarch_init): Update.
11776         * microblaze-tdep.c (microblaze_write_pc): Remove.
11777         (microblaze_gdbarch_init): Update.
11778         * mn10300-tdep.c (mn10300_read_pc): Remove.
11779         (mn10300_write_pc): Remove.
11780         (mn10300_gdbarch_init): Update.
11781         * moxie-tdep.c (moxie_read_pc): Remove.
11782         (moxie_write_pc): Remove.
11783         (moxie_gdbarch_init): Update.
11784
11785 2018-02-06  Yao Qi  <yao.qi@linaro.org>
11786
11787         * expprint.c (print_subexp_standard): Handle
11788         OP_F77_UNDETERMINED_ARGLIST.
11789         (dump_subexp_body_standard): Likewise.
11790
11791 2018-02-05  Alan Hayward  <alan.hayward@arm.com>
11792
11793         * target-descriptions.c (tdesc_element_visitor) Add empty
11794         implementations.
11795         (tdesc_type): Move make_gdb_type from here.
11796         (tdesc_type_builtin): Likewise.
11797         (tdesc_type_vector): Likewise.
11798         (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
11799         (make_gdb_type_struct): Move from tdesc_type_with_fields.
11800         (make_gdb_type_union): Likewise.
11801         (make_gdb_type_flags): Likewise.
11802         (make_gdb_type_enum): Likewise.
11803         (make_gdb_type): New function.
11804         (tdesc_register_type): Use static make_gdb_type.
11805
11806 2018-02-05  Ruslan Kabatsayev <b7.10110111@gmail.com>
11807
11808         * infcmd.c (default_print_one_register_info): Align natural-format
11809         column values consistently one under another.
11810         (pad_to_column): New function.
11811
11812 2018-02-05  Joel Brobecker  <brobecker@adacore.com>
11813
11814         * dwarf2read.c (dwarf2_physname): Move commment.
11815
11816 2018-02-01  Leszek Swirski  <leszeks@google.com>
11817
11818         * varobj.c (varobj_formatted_print_options): Allow recursive
11819         pretty printing if pretty printing is enabled.
11820
11821 2018-02-01  Leszek Swirski  <leszeks@google.com>
11822
11823         * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
11824         names after a structop as a filename.
11825
11826 2018-02-01  Yao Qi  <yao.qi@linaro.org>
11827
11828         * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
11829         (arm_record_coproc_data_proc): Likewise.
11830
11831 2018-02-01  Yao Qi  <yao.qi@linaro.org>
11832
11833         * arm-tdep.c (arm_record_extension_space): Change ret to signed.
11834
11835 2018-01-31  Nikola Prica  <nikola.prica@rt-rk.com>
11836
11837         * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
11838         assign shifted lr_reg to fdata->lr_register when lr_reg is set.
11839
11840 2018-01-31  Pedro Alves  <palves@redhat.com>
11841
11842         * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
11843         * inflow.c (child_terminal_save_inferior): Wrap reference to
11844         tcgetpgrp in HAVE_TERMIOS_H.
11845         (child_interrupt, child_pass_ctrlc): Wrap references to signal in
11846         _WIN32.
11847         * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
11848         always iterate over all inferiors.
11849         (gdbsim_cntrl_c): Adjust.
11850         * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
11851
11852 2018-01-31  Joel Brobecker  <brobecker@adacore.com>
11853
11854         * gdbtypes.c (lookup_array_range_type): Make sure the array's
11855         index type is objfile-owned if the element type is as well.
11856
11857 2018-01-31  Joel Brobecker  <brobecker@adacore.com>
11858
11859         GDB 8.1 released.
11860
11861 2018-01-30  Philipp Rudo  <prudo@linux.vnet.ibm.com>
11862
11863         * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
11864         "features/s390x-linux64.c".
11865         (_initialize_s390_linux_tdep): Remove initialization of tdescs
11866         s390_linux32 and s390x_linux64.
11867         (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
11868         default tdesc.
11869         * s390-tdep.c: Include "features/s390-linux32.c" and
11870         "features/s390x-linux64.c".
11871         (s390_tdesc_valid): Add check for tdesc_has_registers.
11872         (s390_gdbarch_init): Make sure there is always a valid tdesc.
11873         (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
11874         tdesc_s390x_linux64.
11875         * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
11876         tdesc_s390x_linux64 to...
11877         * s390-tdep.h: ...here.
11878
11879 2018-01-30  Pedro Alves  <palves@redhat.com>
11880
11881         PR gdb/13211
11882         * config.in, configure: Regenerate.
11883         * configure.ac: Check for getpgid.
11884         * go32-nat.c (go32_pass_ctrlc): New.
11885         (go32_target): Install it.
11886         * inf-child.c (inf_child_target): Install
11887         child_terminal_save_inferior, child_pass_ctrlc and
11888         child_interrupt.
11889         * inf-ptrace.c (inf_ptrace_interrupt): Delete.
11890         (inf_ptrace_target): No longer install it.
11891         * infcmd.c (interrupt_target_1): Adjust.
11892         * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
11893         (child_interrupt): Declare.
11894         (inferior::terminal_state): New.
11895         * inflow.c (struct terminal_info): Update comments.
11896         (inferior_process_group): Delete.
11897         (terminal_is_ours): Delete.
11898         (gdb_tty_state): New.
11899         (child_terminal_init): Adjust.
11900         (is_gdb_terminal, sharing_input_terminal_1)
11901         (sharing_input_terminal): New functions.
11902         (child_terminal_inferior): Adjust.  Use sharing_input_terminal.
11903         Set the process's actual process group in the foreground if
11904         possible.  Handle is_ours_for_output/is_ours distinction.  Don't
11905         mark terminal as the inferior's if not sharing GDB's terminal.
11906         Don't check attach_flag.
11907         (child_terminal_ours_for_output, child_terminal_ours): Adjust to
11908         pass down a target_terminal_state.
11909         (child_terminal_save_inferior): New, factored out from ...
11910         (child_terminal_ours_1): ... this.  Handle
11911         target_terminal_state::is_ours_for_output.
11912         (child_interrupt, child_pass_ctrlc): New.
11913         (inflow_inferior_exit): Clear the inferior's terminal_state.
11914         (copy_terminal_info): Copy the inferior's terminal state.
11915         (_initialize_inflow): Remove reference to terminal_is_ours.
11916         * inflow.h (inferior_process_group): Delete.
11917         * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
11918         * procfs.c (procfs_target): Don't install procfs_interrupt.
11919         (procfs_interrupt): Delete.
11920         * remote.c (remote_serial_quit_handler): Adjust.
11921         (remote_interrupt): Remove ptid parameter.  Adjust.
11922         * target-delegates.c: Regenerate.
11923         * target.c: Include "terminal.h".
11924         (target_terminal::terminal_state): Rename to ...
11925         (target_terminal::m_terminal_state): ... this.
11926         (target_terminal::init): Adjust.
11927         (target_terminal::inferior): Adjust to per-inferior
11928         terminal_state.
11929         (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
11930         (target_terminal::ours, target_terminal::ours_for_output): Use
11931         target_terminal_is_ours_kind.
11932         (target_interrupt): Remove ptid parameter.  Adjust.
11933         (default_target_pass_ctrlc): Adjust.
11934         * target.h (target_ops::to_terminal_save_inferior): New field.
11935         (target_ops::to_interrupt): Remove ptid_t parameter.
11936         (target_interrupt): Remove ptid_t parameter.  Update comment.
11937         (target_pass_ctrlc): Update comment.
11938         * target/target.h (target_terminal_state): New scoped enum,
11939         factored out of ...
11940         (target_terminal::terminal_state): ... here.
11941         (target_terminal::inferior): Update comments.
11942         (target_terminal::restore_inferior): New.
11943         (target_terminal::is_inferior, target_terminal::is_ours)
11944         (target_terminal::is_ours_for_output): Adjust.
11945         (target_terminal::scoped_restore_terminal_state): Adjust to
11946         rename, and call restore_inferior() instead of inferior().
11947         (target_terminal::scoped_restore_terminal_state::m_state): Change
11948         type.
11949         (target_terminal::terminal_state): Rename to ...
11950         (target_terminal::m_terminal_state): ... this and change type.
11951
11952 2018-01-30  Pedro Alves  <palves@redhat.com>
11953
11954         * linux-nat.c (wait_for_signal): New function.
11955         (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
11956         directly.
11957         (async_terminal_is_ours)
11958         (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
11959         (linux_nat_add_target): Don't override
11960         to_terminal_inferior/to_terminal_ours.
11961
11962 2018-01-29  Sergio Durigan Junior  <sergiodj@redhat.com>
11963
11964         * remote.c (remote_follow_fork): Don't call "detach_inferior".
11965
11966 2018-01-28  Simon Marchi  <simon.marchi@ericsson.com>
11967
11968         * dwarf2read.c (free_dwo_files): Add forward-declaration.
11969         (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
11970         dwarf2_per_objfile_free here.
11971         (dwarf2_per_objfile_free): Remove.
11972         (_initialize_dwarf2_read): Don't register
11973         dwarf2_per_objfile_free as a registry cleanup.
11974
11975 2018-01-27  Eli Zaretskii  <eliz@gnu.org>
11976
11977         Avoid compilation errors in MinGW native builds
11978
11979         The error is triggered by including python-internal.h, and the
11980         error message is:
11981
11982              In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
11983                       from build-gnulib/import/math.h:27,
11984                       from d:/usr/Python26/include/pyport.h:235,
11985                       from d:/usr/Python26/include/Python.h:58,
11986                       from python/python-internal.h:94,
11987                       from python/py-arch.c:24:
11988              d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
11989         using ::hypot;
11990                 ^~~~~
11991
11992         This happens because Python headers define 'hypot' to expand t
11993         '_hypot' in the Windows builds.
11994         * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
11995         'hypoth'.  This avoids a compilation error.
11996
11997 2018-01-26  Alan Hayward  <alan.hayward@arm.com>
11998
11999         * MAINTAINERS (Write After Approval): Fix ordering.
12000
12001 2018-01-26  Alan Hayward  <alan.hayward@arm.com>
12002
12003         * MAINTAINERS (Write After Approval): Add Alan Hayward.
12004
12005 2018-01-26  Alan Modra  <amodra@gmail.com>
12006
12007         * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
12008         (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
12009         Remove nop.  Make const.  Comment.
12010         (powerpc32_plt_stub_so_2): New.
12011         (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
12012         Correct count.  Update uses.
12013         (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
12014         Move common code reading PLT entry word.  Correct
12015         powerpc32_plt_stub PLT address calculation.
12016         * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
12017         (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
12018         (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
12019         (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
12020         (ppc64_standard_linkage8): Likewise.
12021         * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
12022         Correct insns description.
12023         * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
12024
12025 2018-01-24  Pedro Alves  <palves@redhat.com>
12026
12027         GCC PR libstdc++/83906
12028         * gdbtypes.c (operator==(const dynamic_prop &,
12029         const dynamic_prop &)): New.
12030         (operator==(const range_bounds &, const range_bounds &)): New.
12031         (check_types_equal): Use them instead of memcmp.
12032         * gdbtypes.h (operator==(const dynamic_prop &,
12033         const dynamic_prop &)): Declare.
12034         (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
12035         (operator==(const range_bounds &, const range_bounds &)): Declare.
12036         (operator!=(const range_bounds &, const range_bounds &)): Declare.
12037
12038 2018-01-23  Philipp Rudo  <prudo@linux.vnet.ibm.com>
12039
12040         * s390-linux-tdep.c (s390_record_address_mask)
12041         (s390_record_calc_disp_common, s390_record_calc_disp)
12042         (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12043         (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12044         (s390_process_record): Move to s390-tdep.c.
12045         (s390_linux_init_abi_any): Adjust.
12046         * s390-tdep.c (s390_record_address_mask)
12047         (s390_record_calc_disp_common, s390_record_calc_disp)
12048         (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12049         (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12050         (s390_process_record): Moved from s390-linux-tdep.c
12051         (s390_gdbarch_init): Adjust.
12052
12053 2018-01-23  Philipp Rudo  <prudo@linux.vnet.ibm.com>
12054
12055         * s390-linux-nat.c (s390-tdep.h): New include.
12056         * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
12057         (HFILES_NO_SRCDIR): Add s390-tdep.h.
12058         (ALLDEPFILES): Add s390-tdep.c.
12059         * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
12060         * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
12061         * s390-tdep.h: ...this.  New file.
12062         * s390-linux-tdep.c (s390-tdep.h): New include.
12063         (_initialize_s390_tdep): Rename to...
12064         (_initialize_s390_linux_tdep): ...this and adjust.
12065         (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
12066         (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
12067         s390-tdep.h.
12068         (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
12069         (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
12070         (s390_is_partial_instruction, s390_software_single_step)
12071         (is_non_branch_ril, s390_displaced_step_copy_insn)
12072         (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
12073         (s390_prologue_data, s390_addr, s390_store, s390_load)
12074         (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
12075         (s390_register_call_saved, s390_guess_tracepoint_registers)
12076         (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
12077         (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
12078         (s390_pseudo_register_name, s390_pseudo_register_type)
12079         (s390_pseudo_register_read, s390_pseudo_register_write)
12080         (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
12081         (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
12082         (s390_addr_bits_remove, s390_address_class_type_flags)
12083         (s390_address_class_type_flags_to_name)
12084         (s390_address_class_name_to_type_flags, s390_effective_inner_type)
12085         (s390_function_arg_float, s390_function_arg_vector)
12086         (is_power_of_two, s390_function_arg_integer, s390_arg_state)
12087         (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
12088         (s390_frame_align, s390_register_return_value, s390_return_value)
12089         (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
12090         (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
12091         (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
12092         (s390_trad_frame_prev_register, s390_unwind_cache)
12093         (s390_prologue_frame_unwind_cache)
12094         (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
12095         (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
12096         (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
12097         (s390_stub_frame_this_id, s390_stub_frame_prev_register)
12098         (s390_stub_frame_sniffer, s390_stub_frame_unwind)
12099         (s390_frame_base_address, s390_local_base_address)
12100         (s390_frame_base, s390_gcc_target_options)
12101         (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
12102         (s390_validate_reg_range, s390_tdesc_valid)
12103         (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
12104         * s390-tdep.c: ...this.  New file.
12105
12106 2018-01-23  Philipp Rudo  <prudo@linux.vnet.ibm.com>
12107
12108         * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
12109         (s390_process_record, s390_gdbarch_tdep_alloc)
12110         (s390_linux_init_abi_any): Use/set new hook.
12111
12112 2018-01-23  Philipp Rudo  <prudo@linux.vnet.ibm.com>
12113
12114         * s390-linux-tdep.c (osabi.h): New include.
12115         (s390_linux_init_abi_31, s390_linux_init_abi_64)
12116         (s390_linux_init_abi_any): New functions.
12117         (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
12118
12119 2018-01-23  Philipp Rudo  <prudo@linux.vnet.ibm.com>
12120
12121         * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
12122         tdesc_has_registers check
12123
12124 2018-01-23  Philipp Rudo  <prudo@linux.vnet.ibm.com>
12125
12126         * s390-linux-tdep.c (s390_tdesc_valid): New function.
12127         (s390_validate_reg_range): New macro.
12128         (s390_gdbarch_init): Adjust.
12129
12130 2018-01-23  Philipp Rudo  <prudo@linux.vnet.ibm.com>
12131
12132         * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
12133         (s390_gdbarch_tdep_alloc): Adjust.
12134         (s390_gdbarch_init): Adjust.
12135
12136 2018-01-23  Philipp Rudo  <prudo@linux.vnet.ibm.com>
12137
12138         * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
12139         <have_tdb>: Change type to bool.
12140         (s390_gdbarch_tdep_alloc): Adjust.
12141         (s390_gdbarch_init): Adjust.
12142
12143 2018-01-23  Philipp Rudo  <prudo@linux.vnet.ibm.com>
12144
12145         * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
12146         (gdbarch_tdep) <have_upper, have_vx>: New fields.
12147         (s390_gdbarch_tdep_alloc): New function.
12148         (s390_gdbarch_init): Allocate tdep at start and use its fields
12149         instead of separate variables.
12150
12151 2018-01-23  Philipp Rudo  <prudo@linux.vnet.ibm.com>
12152
12153         * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
12154         when looking for cached gdbarch and add comment for remaining.
12155
12156 2018-01-22  Pedro Alves  <palves@redhat.com>
12157             Sergio Durigan Junior  <sergiodj@redhat.com>
12158
12159         * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
12160         case.
12161
12162 2018-01-22  Maciej W. Rozycki  <macro@mips.com>
12163
12164         * MAINTAINERS: Update my company e-mail address.
12165
12166 2018-01-22  Yao Qi  <yao.qi@linaro.org>
12167
12168         * regcache.c (cooked_write_test): New function.
12169         (_initialize_regcache): Register the test.
12170
12171 2018-01-22  Yao Qi  <yao.qi@linaro.org>
12172
12173         * ia64-tdep.c (ia64_pseudo_register_read): Call
12174         regcache->cooked_read instead of regcache_cooked_read_unsigned.
12175         * m32c-tdep.c (m32c_cat_read): Likewise.
12176         (m32c_r3r2r1r0_read): Likewise.
12177         * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
12178         * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
12179
12180 2018-01-22  Yao Qi  <yao.qi@linaro.org>
12181
12182         * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
12183         method raw_read instead of regcache_raw_read.
12184         * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
12185         * arm-tdep.c (arm_neon_quad_read): Likewise.
12186         * avr-tdep.c (avr_pseudo_register_read): Likewise.
12187         * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
12188         * frv-tdep.c (frv_pseudo_register_read): Likewise.
12189         * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
12190         * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
12191         (i386_pseudo_register_read_into_value): Likewise.
12192         * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
12193         * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
12194         * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
12195         * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
12196         * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
12197         * sparc-tdep.c (sparc32_pseudo_register_read):  Likewise.
12198         * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
12199         * spu-tdep.c (spu_pseudo_register_read_spu):  Likewise.
12200         * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
12201
12202 2018-01-22  Yao Qi  <yao.qi@linaro.org>
12203
12204         * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
12205         * configure.tgt: Remove target mt.
12206         * mt-tdep.c: Remove.
12207         * regcache.c (cooked_read_test): Remove the check for mt.
12208
12209 2018-01-22  Yao Qi  <yao.qi@linaro.org>
12210
12211         * jit.c (jit_frame_prev_register): Call regcache::cooked_read
12212         instead of gdbarch_pseudo_register_read_value.
12213
12214 2018-01-22  Joel Brobecker  <brobecker@adacore.com>
12215
12216         * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
12217         language is Ada.
12218
12219 2018-01-22  Joel Brobecker  <brobecker@adacore.com>
12220
12221         * linespec.c (create_sals_line_offset): Remove code that preserved
12222         the symtab_and_line's line number.
12223
12224 2018-01-21  Andrew Burgess  <andrew.burgess@embecosm.com>
12225
12226         * varobj.c (varobj_create): Don't set valid_block when creating a
12227         floating varobj.
12228
12229 2018-01-21  Andrew Burgess  <andrew.burgess@embecosm.com>
12230
12231         * varobj.c (varobj_create): Remove out of date comment.
12232
12233 2018-01-21  Andrew Burgess  <andrew.burgess@embecosm.com>
12234
12235         PR mi/20395
12236         * ada-exp.y (write_var_from_sym): Pass extra parameter when
12237         updating innermost block.
12238         * parse.c (innermost_block_tracker::update): Take extra type
12239         parameter, and check types match before updating innermost block.
12240         (write_dollar_variable): Update innermost block for registers.
12241         * parser-defs.h (enum innermost_block_tracker_type): New enum.
12242         (innermost_block_tracker::innermost_block_tracker): Initialise
12243         m_types member.
12244         (innermost_block_tracker::reset): Take type parameter.
12245         (innermost_block_tracker::update): Take type parameter, and pass
12246         type through as needed.
12247         (innermost_block_tracker::m_types): New member.
12248         * varobj.c (varobj_create): Pass type when reseting innermost
12249         block.
12250
12251 2018-01-21  Andrew Burgess  <andrew.burgess@embecosm.com>
12252
12253         * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
12254         * ada-lang.c (resolve_subexp): Likewise.
12255         * breakpoint.c (set_breakpoint_condition) Likewise.
12256         (watch_command_1) Likewise.
12257         * c-exp.y (variable): Likewise.
12258         * d-exp.y (PrimaryExpression): Likewise.
12259         * f-exp.y (variable): Likewise.
12260         * go-exp.y (variable): Likewise.
12261         * m2-exp.y (variable): Likewise.
12262         * objfiles.c (objfile::~objfile): Likewise.
12263         * p-exp.y (variable): Likewise.
12264         * parse.c (innermost_block): Change type.
12265         * parser-defs.h (class innermost_block_tracker): New.
12266         (innermost_block): Change to innermost_block_tracker.
12267         * printcmd.c (display_command): Switch to innermost_block API.
12268         (do_one_display): Likewise.
12269         * rust-exp.y (do_one_display): Likewise.
12270         * symfile.c (clear_symtab_users): Likewise.
12271         * varobj.c (varobj_create): Switch to innermost_block API, replace
12272         use of innermost_block with block stored on varobj object.
12273
12274 2018-01-21  Andrew Burgess  <andrew.burgess@embecosm.com>
12275
12276         * expression.h (innermost_block): Remove declaration.
12277         * varobj.c: Add 'parser-defs.h' include.
12278
12279 2018-01-19  Tom Tromey  <tom@tromey.com>
12280
12281         * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
12282         symbols in the static and global blocks.
12283
12284 2018-01-19  James Clarke  <jrtc27@jrtc27.com>
12285
12286         * nat/linux-ptrace.c: Remove unnecessary reinclusion of
12287         gdb_ptrace.h, and move including gdb_wait.h ...
12288         * nat/linux-ptrace.h: ... to here.
12289
12290 2018-01-19  Simon Marchi  <simon.marchi@ericsson.com>
12291
12292         * inf-ptrace.c (inf_ptrace_detach): Adjust call to
12293         inf_ptrace_detach_success.
12294         (inf_ptrace_detach_success): Add inferior parameter, use it
12295         instead of inferior_ptid, pass it to detach_inferior.
12296         * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
12297         parameter.
12298         * inferior.c (detach_inferior): Add overload that takes an
12299         inferior object.
12300         * inferior.h (detach_inferior): Likewise.
12301         * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
12302         use inferior_ptid, adjust call to inf_ptrace_detach_success.
12303         * linux-thread-db.c (thread_db_detach): Use inf parameter.
12304
12305 2018-01-19  Simon Marchi  <simon.marchi@ericsson.com>
12306
12307         * target.h (struct target_ops) <to_detach>: Add inferior
12308         parameter.
12309         (target_detach): Likewise.
12310         * target.c (dispose_inferior): Pass inferior down.
12311         (target_detach): Pass inferior down.  Assert that it is equal to
12312         the current inferior.
12313         * aix-thread.c (aix_thread_detach): Pass inferior down.
12314         * corefile.c (core_file_command): Pass current_inferior() down.
12315         * corelow.c (core_detach): Add inferior parameter.
12316         * darwin-nat.c (darwin_detach): Likewise.
12317         * gnu-nat.c (gnu_detach): Likewise.
12318         * inf-ptrace.c (inf_ptrace_detach): Likewise.
12319         * infcmd.c (detach_command): Pass current_inferior() down to
12320         target_detach.
12321         * infrun.c (follow_fork_inferior): Pass parent_inf to
12322         target_detach.
12323         (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
12324         target_detach.
12325         * linux-nat.c (linux_nat_detach): Add inferior parameter.
12326         * linux-thread-db.c (thread_db_detach): Likewise.
12327         * nto-procfs.c (procfs_detach): Likewise.
12328         * procfs.c (procfs_detach): Likewise.
12329         * record.c (record_detach): Likewise.
12330         * record.h (struct inferior): Forward-declare.
12331         (record_detach): Add inferior parameter.
12332         * remote-sim.c (gdbsim_detach): Likewise.
12333         * remote.c (remote_detach_1): Likewise.
12334         (remote_detach): Likewise.
12335         (extended_remote_detach): Likewise.
12336         * sol-thread.c (sol_thread_detach): Likewise.
12337         * target-debug.h (target_debug_print_inferior_p): New macro.
12338         * target-delegates.c: Re-generate.
12339         * top.c (kill_or_detach): Pass inferior down to target_detach.
12340         * windows-nat.c (windows_detach): Add inferior parameter.
12341
12342 2018-01-19  Simon Marchi  <simon.marchi@ericsson.com>
12343
12344         * target.h (struct target_ops) <to_detach>: Remove args
12345         parameter.
12346         (target_detach): Likewise.
12347         * target.c (dispose_inferior): Adjust.
12348         (target_detach): Remove args parameter, adjust.
12349         * aix-thread.c (aix_thread_detach): Adjust.
12350         * corefile.c (core_file_command): Adjust.
12351         * corelow.c (core_detach): Adjust.
12352         * darwin-nat.c (darwin_detach): Adjust.
12353         * gnu-nat.c (gnu_detach): Adjust.
12354         * inf-ptrace.c (inf_ptrace_detach): Adjust.
12355         * infcmd.c (detach_command): Adjust
12356         * infrun.c (follow_fork_inferior): Adjust.
12357         (handle_vfork_child_exec_or_exit): Adjust.
12358         * linux-fork.c (linux_fork_detach): Remove args parameter.
12359         * linux-fork.h (linux_fork_detach): Likewise.
12360         * linux-nat.c (linux_nat_detach): Likewise, and adjust.
12361         * linux-thread-db.c (thread_db_detach): Likewise.
12362         * nto-procfs.c (procfs_detach): Likewise.
12363         * procfs.c (procfs_detach): Likewise.
12364         (do_detach): Remove signo parameter.
12365         * record.c (record_detach): Remove args parameter.
12366         * record.h (record_detach): Likewise.
12367         * remote-sim.c (gdbsim_detach): Likewise.
12368         * remote.c (remote_detach_1): Likewise.
12369         (remote_detach): Likewise.
12370         (extended_remote_detach): Likewise.
12371         * sol-thread.c (sol_thread_detach): Likewise.
12372         * target-delegates.c: Re-generate.
12373         * top.c (struct qt_args) <args>: Remove field.
12374         (kill_or_detach): Don't pass args.
12375         (quit_force): Don't set args.
12376         * windows-nat.c (windows_detach): Remove args parameter.
12377
12378 2018-01-19  Yao Qi  <yao.qi@linaro.org>
12379
12380         * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
12381         (arm_linux_init_abi): Install it.
12382
12383 2018-01-19  Yao Qi  <yao.qi@linaro.org>
12384
12385         * osabi.c (gdb_osabi_names): Extend the regexp for
12386         arm-linux-gnueabihf.
12387
12388 2018-01-18  Yao Qi  <yao.qi@linaro.org>
12389
12390         * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
12391         m_abbrevs.
12392         (abbrev_table::add_abbrev): Update.
12393         (abbrev_table::lookup_abbrev): Update.
12394
12395 2018-01-18  Yao Qi  <yao.qi@linaro.org>
12396
12397         * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
12398
12399 2018-01-17  Sergio Durigan Junior  <sergiodj@redhat.com>
12400
12401         * compile/compile.c (compile_to_object): Convert "triplet_rx"
12402         to "std::string".
12403
12404 2018-01-17  Tom Tromey  <tom@tromey.com>
12405
12406         * dwarf2read.c (symbolp): Remove typedef.  Don't instantiate VEC.
12407
12408 2018-01-17  Tom Tromey  <tom@tromey.com>
12409
12410         * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
12411         * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
12412         (create_array_type_with_stride): Update.
12413         * dwarf2read.c (set_die_type): Update.
12414
12415 2018-01-17  Tom Tromey  <tom@tromey.com>
12416
12417         * dwarf2read.c (delayed_method_info): Remove typedef.
12418         (dwarf2_cu::method_info): Now a std::vector.
12419         (add_to_method_list): Update.
12420         (free_delayed_list): Remove.
12421         (compute_delayed_physnames): Update.
12422         (process_full_comp_unit, process_full_type_unit): Clear the method
12423         list.  Remove cleanups.
12424         (psymtab_include_file_name): Add name_holder parameter.  Use
12425         unique_xmalloc_ptr.
12426         (dwarf_decode_lines): Update.
12427
12428 2018-01-17  Tom Tromey  <tom@tromey.com>
12429             Simon Marchi  <simon.marchi@ericsson.com>
12430
12431         * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
12432         (dwarf2_per_objfile::free_cached_comp_units)
12433         (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12434         (init_cutu_and_read_dies_no_follow): Update.
12435         (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
12436         (dwarf2_cu::~dwarf2_cu): New.
12437         (free_heap_comp_unit, free_stack_comp_unit): Remove.
12438         (age_cached_comp_units, free_one_cached_comp_unit): Update.
12439
12440 2018-01-17  Tom Tromey  <tom@tromey.com>
12441             Simon Marchi  <simon.marchi@ericsson.com>
12442
12443         * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
12444         (struct die_reader_specs) <abbrev_table>: New member.
12445         (struct abbrev_table): Add constructor.
12446         <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
12447         <abbrev_obstack>: Now an auto_obstack.
12448         (abbrev_table_up): New typedef.
12449         (init_cu_die_reader): Add abbrev_table parameter.
12450         (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
12451         Add result_dwo_abbrev_table.
12452         (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12453         (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
12454         Update.
12455         (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
12456         parameter.
12457         (skip_children): Update.
12458         (abbrev_table::alloc_abbrev): Rename from
12459         abbrev_table_alloc_abbrev.
12460         (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
12461         (abbrev_table::lookup_abbrev): Rename from
12462         abbrev_table_lookup_abbrev.
12463         (abbrev_table_read_table): Return abbrev_table_up.
12464         (abbrev_table_free, abbrev_table_free_cleanup)
12465         (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
12466         (load_partial_dies): Update.
12467
12468 2018-01-17  Tom Tromey  <tom@tromey.com>
12469
12470         * dwarf2read.c (dwarf2_compute_name): Update comment.
12471         (read_func_scope, read_variable): Update.
12472         (new_symbol): Remove.
12473         (new_symbol_full): Rename to new_symbol.
12474
12475 2018-01-17  Mike Gulick  <mgulick@mathworks.com>
12476
12477         PR gdb/16577
12478         * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
12479         a warning instead of throwing an error, set section size to 0 and return
12480         NULL.
12481         * gdb_bfd.h (gdb_bfd_map_section): Update description.
12482
12483 2018-01-17  Simon Marchi  <simon.marchi@ericsson.com>
12484
12485         * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
12486         std::string.
12487         (linux_ptrace_attach_fail_reason_string): Likewise.
12488         * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
12489         Likewise.
12490         (linux_ptrace_attach_fail_reason_string): Likewise.
12491         * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
12492
12493 2018-01-17  Simon Marchi  <simon.marchi@ericsson.com>
12494
12495         * linux-nat.c (linux_nat_attach): Remove xstrdup.
12496
12497 2018-01-17  Eldar Abusalimov  <eldar.abusalimov@jetbrains.com>
12498
12499         PR gdb/21559
12500         * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
12501         checking for fs_base/gs_base fields in struct user_regs_struct.
12502         * configure: Regenerate.
12503
12504 2018-01-17  Yao Qi  <yao.qi@linaro.org>
12505
12506         * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
12507         function.
12508         (aarch64_linux_init_abi): Install it to gdbarch hook
12509         gcc_target_options.
12510
12511 2018-01-15  Pedro Alves  <palves@redhat.com>
12512
12513         * common/signals-state-save-restore.c
12514         (save_original_signals_state): Fix typos.
12515
12516 2017-01-12  Tom Tromey  <tom@tromey.com>
12517             Sergio Durigan Junior  <sergiodj@redhat.com>
12518
12519         * Makefile.in (install-only): Install gdb-add-index.
12520
12521 2018-01-12  John Baldwin  <jhb@FreeBSD.org>
12522
12523         * fbsd-tdep.c (KVE_PROTECTION): Correct value.
12524
12525 2018-01-12  Andreas Arnez  <arnez@linux.vnet.ibm.com>
12526
12527         * infrun.c (keep_going_pass_signal): Clear step-over info when
12528         insert_breakpoints fails.
12529
12530 2018-01-11  Pedro Alves  <palves@redhat.com>
12531
12532         PR gdb/22583
12533         * infrun.c (resume): Rename to ...
12534         (resume_1): ... this.
12535         (resume): Reimplement as wrapper around resume_1.
12536
12537 2018-01-11  Pedro Alves  <palves@redhat.com>
12538
12539         PR remote/22597
12540         * remote.c (remote_parse_stop_reply): Default to the last-set
12541         general thread instead of to 'magic_null_ptid'.
12542
12543 2018-01-10  Pedro Alves  <palves@redhat.com>
12544
12545         * language.h (language_get_symbol_name_matcher): Rename ...
12546         (get_symbol_name_matcher): ... this.
12547         * language.c (language_get_symbol_name_matcher): Ditto.
12548         * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
12549         callers adjusted.
12550
12551 2018-01-10  Pedro Alves  <palves@redhat.com>
12552
12553         PR gdb/22670
12554         * dwarf2read.c
12555         (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
12556         Adjust to use language_get_symbol_name_matcher instead of
12557         language_defn::la_get_symbol_name_matcher.
12558         * language.c (language_get_symbol_name_matcher): If in Ada mode
12559         and the lookup name is a verbatim match, return Ada's matcher.
12560         * language.h (language_get_symbol_name_matcher): Adjust comment.
12561         (ada_lookup_name_info::verbatim_p):: New method.
12562
12563 2018-01-10  Pedro Alves  <palves@redhat.com>
12564
12565         PR gdb/22670
12566         * ada-lang.c (ada_collect_symbol_completion_matches): If the
12567         minsym's language is language_auto or language_cplus, pass down
12568         language_ada instead.
12569         * symtab.c (compare_symbol_name): Don't frob symbol language here.
12570
12571 2018-01-10  Pedro Alves  <palves@redhat.com>
12572
12573         PR gdb/22670
12574         * minsyms.c (linkage_name_str): New function.
12575         (iterate_over_minimal_symbols): Use it.
12576
12577 2018-01-09  John Baldwin  <jhb@FreeBSD.org>
12578
12579         * NEWS: Document that 'info proc' now works on FreeBSD.
12580
12581 2018-01-09  John Baldwin  <jhb@FreeBSD.org>
12582
12583         * configure.ac: Check for kinfo_getfile in libutil.
12584         * configure: Regenerate.
12585         * config.in: Regenerate.
12586         * fbsd-nat.c: Include "fbsd-tdep.h".
12587         (fbsd_fetch_cmdline): New.
12588         (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
12589         rather than calling error.
12590         (fbsd_info_proc): New.
12591         (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
12592         (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
12593         (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
12594
12595 2018-01-09  John Baldwin  <jhb@FreeBSD.org>
12596
12597         * fbsd-nat.c (struct free_deleter): Remove.
12598         (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
12599
12600 2018-01-09  John Baldwin  <jhb@FreeBSD.org>
12601
12602         * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
12603         NULL for an empty pathname.
12604
12605 2018-01-09  John Baldwin  <jhb@FreeBSD.org>
12606
12607         * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
12608         (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
12609         (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
12610         (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
12611         (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
12612         (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
12613         (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
12614         (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
12615         (kinfo_proc_layout_32, kinfo_proc_layout_i386)
12616         (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
12617         (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
12618         (fbsd_core_fetch_timeval, fbsd_print_sigset)
12619         (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
12620         (fbsd_init_abi):  Install gdbarch "core_info_proc" method.
12621         * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
12622
12623 2018-01-08  Samuel Thibault  <samuel.thibault@ens-lyon.org>
12624
12625         * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
12626         (gnu_xfer_auxv): New function.
12627         (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
12628         TARGET_OBJECT_AUXV.
12629
12630 2018-01-08  Yao Qi  <yao.qi@linaro.org>
12631             Simon Marchi  <simon.marchi@ericsson.com>
12632
12633         * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
12634         common/selftest.c.
12635         (COMMON_OBS): Remove selftest.o.
12636         * configure.ac: Append selftest-arch.c and common/selftest.c to
12637         CONFIG_SRCS.  Append selftest-arch.o and selftest.o to COMMON_OBS.
12638         * configure: Re-generated.
12639         * maint.c (maintenance_selftest): Wrap selftests::run_tests with
12640         GDB_SELF_TEST.
12641         (maintenance_info_selftests): Likewise.
12642
12643 2018-01-08  Xavier Roirand  <roirand@adacore.com>
12644
12645         * ada-valprint.c (val_print_packed_array_elements): Use
12646         proper number of elements when printing an array indexed
12647         by an enumeration type.
12648
12649 2018-01-07  Simon Marchi  <simon.marchi@polymtl.ca>
12650
12651         * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
12652         (dw2_get_file_names_reader): Adjust.
12653         (lookup_dwo_signatured_type): Adjust.
12654         (lookup_dwp_signatured_type): Adjust.
12655         (lookup_signatured_type): Adjust.
12656         (create_type_unit_group): Adjust.
12657         (get_type_unit_group): Adjust.
12658         (process_psymtab_comp_unit_reader): Adjust.
12659         (build_type_psymtabs_reader): Adjust.
12660         (scan_partial_symbols): Adjust.
12661         (add_partial_symbol): Adjust.
12662         (add_partial_subprogram): Adjust.
12663         (peek_die_abbrev): Adjust.
12664         (fixup_go_packaging): Adjust.
12665         (process_imported_unit_die): Adjust.
12666         (dwarf2_compute_name): Adjust.
12667         (dwarf2_physname): Adjust.
12668         (read_import_statement): Adjust.
12669         (handle_DW_AT_stmt_list): Adjust.
12670         (read_file_scope): Adjust.
12671         (read_func_scope): Adjust.
12672         (read_lexical_block_scope): Adjust.
12673         (read_call_site_scope): Adjust.
12674         (read_variable): Adjust.
12675         (dwarf2_rnglists_process): Adjust.
12676         (dwarf2_ranges_process): Adjust.
12677         (dwarf2_ranges_read): Adjust.
12678         (dwarf2_get_pc_bounds): Adjust.
12679         (dwarf2_record_block_ranges): Adjust.
12680         (dwarf2_add_field): Adjust.
12681         (dwarf2_add_member_fn): Adjust.
12682         (read_structure_type): Adjust.
12683         (process_structure_scope): Adjust.
12684         (read_enumeration_type): Adjust.
12685         (read_array_type): Adjust.
12686         (mark_common_block_symbol_computed): Adjust.
12687         (read_common_block): Adjust.
12688         (read_namespace_type): Adjust.
12689         (read_namespace): Adjust.
12690         (read_module_type): Adjust.
12691         (read_tag_pointer_type): Adjust.
12692         (read_tag_ptr_to_member_type): Adjust.
12693         (read_tag_string_type): Adjust.
12694         (read_subroutine_type): Adjust.
12695         (read_typedef): Adjust.
12696         (read_base_type): Adjust.
12697         (attr_to_dynamic_prop): Adjust.
12698         (read_subrange_type): Adjust.
12699         (read_unspecified_type): Adjust.
12700         (dwarf2_read_abbrevs): Adjust.
12701         (load_partial_dies): Adjust.
12702         (read_partial_die): Adjust.
12703         (find_partial_die): Adjust.
12704         (guess_partial_die_structure_name): Adjust.
12705         (fixup_partial_die): Adjust.
12706         (read_attribute_value): Adjust.
12707         (read_addr_index): Adjust.
12708         (read_addr_index_from_leb128): Adjust.
12709         (read_str_index): Adjust.
12710         (dwarf2_string_attr): Adjust.
12711         (get_debug_line_section): Adjust.
12712         (dwarf_decode_line_header): Adjust.
12713         (lnp_state_machine::check_line_address): Adjust.
12714         (dwarf_decode_lines_1): Adjust.
12715         (dwarf_decode_lines): Adjust.
12716         (dwarf2_start_symtab): Adjust.
12717         (var_decode_location): Adjust.
12718         (new_symbol_full): Adjust.
12719         (dwarf2_const_value_data): Adjust.
12720         (dwarf2_const_value_attr): Adjust.
12721         (dwarf2_const_value): Adjust.
12722         (die_type): Adjust.
12723         (die_containing_type): Adjust.
12724         (build_error_marker_type): Adjust.
12725         (lookup_die_type): Adjust.
12726         (guess_full_die_structure_name): Adjust.
12727         (anonymous_struct_prefix): Adjust.
12728         (determine_prefix): Adjust.
12729         (dwarf2_name): Adjust.
12730         (follow_die_ref_or_sig): Adjust.
12731         (follow_die_offset): Adjust.
12732         (follow_die_ref): Adjust.
12733         (follow_die_sig_1): Adjust.
12734         (follow_die_sig): Adjust.
12735         (get_signatured_type): Adjust.
12736         (get_DW_AT_signature_type): Adjust.
12737         (decode_locdesc): Adjust.
12738         (dwarf_decode_macros): Adjust.
12739         (cu_debug_loc_section): Adjust.
12740         (fill_in_loclist_baton): Adjust.
12741         (dwarf2_symbol_mark_computed): Adjust.
12742         (init_one_comp_unit): Don't assign
12743         dwarf2_cu::dwarf2_per_objfile.
12744         (set_die_type): Adjust.
12745
12746 2018-01-07  Simon Marchi  <simon.marchi@ericsson.com>
12747
12748         * dwarf2read.c (struct mapped_debug_names): Add constructor.
12749         <dwarf2_per_objfile>: New field.
12750         (dwarf2_per_objfile): Remove global.
12751         (get_dwarf2_per_objfile): New function.
12752         (set_dwarf2_per_objfile): New function.
12753         (dwarf2_build_psymtabs_hard): Change objfile parameter to
12754         dwarf2_per_objfile.
12755         (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
12756         (read_abbrev_offset): Likewise.
12757         (read_indirect_string): Likewise.
12758         (read_indirect_line_string): Likewise.
12759         (read_indirect_string_at_offset): Likewise.
12760         (read_indirect_string_from_dwz): Likewise.
12761         (dwarf2_find_containing_comp_unit): Change objfile parameter to
12762         dwarf2_per_objfile.
12763         (age_cached_comp_units): Add dwarf2_per_objfile parameter.
12764         (create_all_comp_units): Change objfile parameter to
12765         dwarf2_per_objfile.
12766         (create_all_type_units): Likewise.
12767         (process_queue): Add dwarf2_per_objfile parameter.
12768         (read_and_check_comp_unit_head): Likewise.
12769         (lookup_dwo_unit_in_dwp): Likewise.
12770         (get_dwp_file): Likewise.
12771         (process_cu_includes): Likewise.
12772         (struct free_dwo_file_cleanup_data): New struct.
12773         (dwarf2_has_info): Use get_dwarf2_per_objfile and
12774         set_dwarf2_per_objfile.
12775         (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
12776         (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
12777         context, adjust calls.
12778         (dw2_instantiate_symtab): Likewise.
12779         (dw2_get_cutu): Add dwarf2_per_objfile parameter.
12780         (dw2_get_cu): Likewise.
12781         (create_cu_from_index_list): Change objfile parameter to
12782         dwarf2_per_objfile.
12783         (create_cus_from_index_list): Get dwarf2_per_objfile from
12784         context, adjust calls.
12785         (create_cus_from_index): Likewise.
12786         (create_signatured_type_table_from_index): Change objfile
12787         parameter to dwarf2_per_objfile.
12788         (create_signatured_type_table_from_debug_names): Change objfile
12789         parameter to dwarf2_per_objfile.
12790         (create_addrmap_from_index): Likewise.
12791         (create_addrmap_from_aranges): Likewise.
12792         (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
12793         (dw2_setup): Remove.
12794         (dw2_get_file_names_reader): Get dwarf2_per_objfile from
12795         context.
12796         (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
12797         get_dwarf2_per_objfile.
12798         (dw2_forget_cached_source_info): Likewise.
12799         (dw2_map_symtabs_matching_filename): Likewise.
12800         (struct dw2_symtab_iterator) <index>: Remove.
12801         <dwarf2_per_objfile>: New field.
12802         (dw2_symtab_iter_init): Replace index parameter with
12803         dwarf2_per_objfile.
12804         (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
12805         (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
12806         (dw2_print_stats): Likewise.
12807         (dw2_dump): Likewise.
12808         (dw2_expand_symtabs_for_function): Likewise.
12809         (dw2_expand_all_symtabs): Likewise.
12810         (dw2_expand_symtabs_with_fullname): Likewise.
12811         (dw2_expand_marked_cus): Replace index and objfile parameters
12812         with dwarf2_per_objfile.
12813         (dw_expand_symtabs_matching_file_matcher): Add
12814         dwarf2_per_objfile parameter and adjust calls.
12815         (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
12816         adjust calls.
12817         (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
12818         (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
12819         adjust calls.
12820         (create_cus_from_debug_names_list): Replace objfile parameter
12821         with dwarf2_per_objfile and adjust calls.
12822         (create_cus_from_debug_names): Likewise.
12823         (dwarf2_read_debug_names): Likewise.
12824         (mapped_debug_names::namei_to_name): Adjust call.
12825         (dw2_debug_names_iterator::next): Likewise.
12826         (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
12827         (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
12828         (dw2_debug_names_dump): Likewise.
12829         (dw2_debug_names_expand_symtabs_for_function): Likewise.
12830         (dw2_debug_names_expand_symtabs_matching): Likewise.
12831         (dwarf2_initialize_objfile): Likewise.
12832         (dwarf2_build_psymtabs): Likewise.
12833         (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
12834         this_cu.
12835         (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
12836         (read_and_check_comp_unit_head): Likewise.
12837         (read_abbrev_offset): Likewise.
12838         (create_debug_type_hash_table): Likewise.
12839         (create_debug_types_hash_table): Likewise.
12840         (create_all_type_units): Replace objfile parameter with
12841         dwarf2_per_objfile.
12842         (add_type_unit): Add dwarf2_per_objfile parameter.
12843         (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
12844         with dwarf2_per_objfile.
12845         (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
12846         (lookup_dwp_signatured_type): Likewise.
12847         (lookup_signatured_type): Likewise.
12848         (read_cutu_die_from_dwo): Likewise.
12849         (init_tu_and_read_dwo_dies): Likewise.
12850         (init_cutu_and_read_dies): Likewise.
12851         (init_cutu_and_read_dies_no_follow): Likewise.
12852         (allocate_type_unit_groups_table): Add objfile parameter.
12853         (create_type_unit_group): Use dwarf2_per_objfile from cu.
12854         (get_type_unit_group): Likewise.
12855         (process_psymtab_comp_unit): Update call.
12856         (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
12857         (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
12858         (print_tu_stats): Likewise.
12859         (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
12860         in void* parameter.
12861         (build_type_psymtabs): Change objfile parameter to
12862         dwarf2_per_objfile.
12863         (process_skeletonless_type_unit): Use dwarf2_per_objfile
12864         passed in void* parameter.
12865         (process_skeletonless_type_units): Change objfile parameter to
12866         dwarf2_per_objfile.
12867         (set_partial_user): Likewise.
12868         (dwarf2_build_psymtabs_hard): Likewise.
12869         (read_comp_units_from_section): Likewise.
12870         (create_all_comp_units): Likewise.
12871         (scan_partial_symbols): Update calls.
12872         (add_partial_symbol): Likewise.
12873         (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
12874         (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
12875         (process_queue): Add dwarf2_per_objfile parameter.
12876         (get_compunit_symtab): Use dwarf2_per_objfile from cu.
12877         (compute_compunit_symtab_includes): Likewise.
12878         (process_cu_includes): Add dwarf2_per_objfile parameter.
12879         (process_full_comp_unit): Use dwarf2_per_objfile from cu.
12880         (process_full_type_unit): Likewise.
12881         (process_imported_unit_die): Update call.
12882         (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
12883         (read_file_scope): Likewise.
12884         (allocate_dwo_file_hash_table): Add objfile parameter.
12885         (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
12886         (create_cus_hash_table): Likewise.
12887         (create_dwp_hash_table): Likewise.
12888         (create_dwo_unit_in_dwp_v1): Likewise.
12889         (create_dwp_v2_section): Likewise.
12890         (create_dwo_unit_in_dwp_v2): Likewise.
12891         (lookup_dwo_unit_in_dwp): Likewise.
12892         (try_open_dwop_file): Likewise.
12893         (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
12894         (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
12895         cleanup to include a reference to dwarf2_per_objfile.
12896         (open_dwp_file): Add dwarf2_per_objfile parameter.
12897         (open_and_init_dwp_file): Likewise.
12898         (get_dwp_file): Likewise.
12899         (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
12900         (queue_and_load_all_dwo_tus): Update call.
12901         (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
12902         data.
12903         (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
12904         (dwarf2_ranges_process): Likewise.
12905         (dwarf2_get_pc_bounds): Likewise.
12906         (mark_common_block_symbol_computed): Likewise.
12907         (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
12908         (dwarf2_read_abbrevs): Update call.
12909         (read_partial_die): Use dwarf2_per_objfile from cu.
12910         (find_partial_die): Likewise.
12911         (fixup_partial_die): Likewise.
12912         (read_attribute_value): Likewise.
12913         (read_indirect_string_at_offset_from): Add objfile parameter.
12914         (read_indirect_string_at_offset): Add dwarf2_per_objfile
12915         parameter.
12916         (read_indirect_string_from_dwz): Add objfile parameter.
12917         (read_indirect_string): Add objfile parameter.
12918         (read_addr_index_1): Add dwarf2_per_objfile parameter.
12919         (read_addr_index): Use dwarf2_per_objfile from cu.
12920         (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
12921         call dw2_setup.
12922         (read_str_index): Use dwarf2_per_objfile from cu.
12923         (get_debug_line_section): Likewise.
12924         (read_formatted_entries): Add dwarf2_per_objfile parameter.
12925         (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
12926         (new_symbol_full): Use dwarf2_per_objfile from cu.
12927         (build_error_marker_type): Likewise.
12928         (lookup_die_type): Likewise.
12929         (determine_prefix): Likewise.
12930         (follow_die_offset): Likewise.
12931         (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
12932         (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
12933         (dwarf2_fetch_die_type_sect_off): Likewise.
12934         (dwarf2_get_die_type): Likewise.
12935         (follow_die_sig_1): Use dwarf2_per_objfile from cu.
12936         (get_signatured_type): Likewise.
12937         (get_DW_AT_signature_type): Likewise.
12938         (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
12939         (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
12940         (cu_debug_loc_section): Likewise.
12941         (fill_in_loclist_baton): Likewise.
12942         (dwarf2_symbol_mark_computed): Likewise.
12943         (dwarf2_find_containing_comp_unit): Change objfile parameter to
12944         dwarf2_per_objfile.
12945         (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
12946         parameter.
12947         (age_cached_comp_units): Add dwarf2_per_objfile parameter.
12948         (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
12949         (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
12950         (set_die_type): Use dwarf2_free_objfile from cu.
12951         (get_die_type_at_offset): Likewise.
12952         (dwarf2_per_objfile_free): Don't assign global variable.
12953         (debug_names) <constructor>: Add dwarf2_per_objfile
12954         parameter, update m_debugstrlookup construction.
12955         (debug_names::debug_str_lookup): Add dwarf2_per_objfile
12956         parameter.
12957         <m_dwarf2_per_objfile>: New field.
12958         <lookup>: Use m_dwarf2_per_objfile.
12959         (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
12960         (psyms_seen_size): Likewise.
12961         (write_gdbindex): Replace objfile parameter with
12962         dwarf2_per_objfile.
12963         (write_debug_names): Likewise.
12964         (write_psymtabs_to_index): Likewise.
12965         (save_gdb_index_command): Use get_dwarf2_per_objfile, update
12966         calls.
12967
12968 2018-01-07  Simon Marchi  <simon.marchi@ericsson.com>
12969
12970         * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
12971         <dwarf2_per_objfile>: New field.
12972         (struct dwarf2_per_cu_data) <objfile>: Remove.
12973         <dwarf2_per_objfile>: New field.
12974         (create_cu_from_index_list): Assign dwarf2_per_objfile instead
12975         of objfile.
12976         (create_signatured_type_table_from_index): Likewise.
12977         (create_debug_type_hash_table): Likewise.
12978         (fill_in_sig_entry_from_dwo_entry): Likewise.
12979         (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
12980         (create_type_unit_group): Assign dwarf2_per_objfile instead of
12981         objfile.
12982         (create_partial_symtab): Access objfile through
12983         dwarf2_per_objfile.
12984         (process_psymtab_comp_unit_reader): Likewise.
12985         (read_comp_units_from_section): Likewise.
12986         (scan_partial_symbols): Likewise.
12987         (add_partial_symbol): Likewise.
12988         (add_partial_subprogram): Likewise.
12989         (peek_die_abbrev): Likewise.
12990         (fixup_go_packaging): Likewise.
12991         (process_full_comp_unit): Likewise.
12992         (process_full_type_unit): Likewise.
12993         (process_imported_unit_die): Likewise.
12994         (dwarf2_compute_name): Likewise.
12995         (dwarf2_physname): Likewise.
12996         (read_import_statement): Likewise.
12997         (create_cus_hash_table): Assign dwarf2_physname instead of
12998         objfile.
12999         (read_func_scope): Access objfile through dwarf2_per_objfile.
13000         (read_lexical_block_scope): Likewise.
13001         (read_call_site_scope): Likewise.
13002         (read_variable): Likewise.
13003         (dwarf2_rnglists_process): Likewise.
13004         (dwarf2_ranges_process): Likewise.
13005         (dwarf2_ranges_read): Likewise.
13006         (dwarf2_record_block_ranges): Likewise.
13007         (dwarf2_add_field): Likewise.
13008         (dwarf2_add_member_fn): Likewise.
13009         (read_structure_type): Likewise.
13010         (process_structure_scope): Likewise.
13011         (read_enumeration_type): Likewise.
13012         (read_array_type): Likewise.
13013         (read_common_block): Likewise.
13014         (read_namespace_type): Likewise.
13015         (read_namespace): Likewise.
13016         (read_module_type): Likewise.
13017         (read_tag_pointer_type): Likewise.
13018         (read_tag_ptr_to_member_type): Likewise.
13019         (read_tag_string_type): Likewise.
13020         (read_subroutine_type): Likewise.
13021         (read_typedef): Likewise.
13022         (read_base_type): Likewise.
13023         (attr_to_dynamic_prop): Likewise.
13024         (read_subrange_type): Likewise.
13025         (read_unspecified_type): Likewise.
13026         (load_partial_dies): Likewise.
13027         (read_partial_die): Likewise.
13028         (find_partial_die): Likewise.
13029         (guess_partial_die_structure_name): Likewise.
13030         (fixup_partial_die): Likewise.
13031         (read_attribute_value): Likewise.
13032         (read_addr_index_from_leb128): Likewise.
13033         (dwarf2_read_addr_index): Likewise.
13034         (dwarf2_string_attr): Likewise.
13035         (lnp_state_machine::check_line_address): Likewise.
13036         (dwarf_decode_lines_1): Likewise.
13037         (dwarf_decode_lines): Likewise.
13038         (dwarf2_start_symtab): Likewise.
13039         (var_decode_location): Likewise.
13040         (new_symbol_full): Likewise.
13041         (dwarf2_const_value_data): Likewise.
13042         (dwarf2_const_value_attr): Likewise.
13043         (dwarf2_const_value): Likewise.
13044         (die_type): Likewise.
13045         (die_containing_type): Likewise.
13046         (lookup_die_type): Likewise.
13047         (guess_full_die_structure_name): Likewise.
13048         (anonymous_struct_prefix): Likewise.
13049         (dwarf2_name): Likewise.
13050         (follow_die_ref_or_sig): Likewise.
13051         (follow_die_offset): Likewise.
13052         (follow_die_ref): Likewise.
13053         (dwarf2_fetch_die_loc_sect_off): Likewise.
13054         (dwarf2_fetch_constant_bytes): Likewise.
13055         (dwarf2_fetch_die_type_sect_off): Likewise.
13056         (dwarf2_get_die_type): Likewise.
13057         (follow_die_sig): Likewise.
13058         (decode_locdesc): Likewise.
13059         (dwarf2_per_cu_objfile): Likewise.
13060         (dwarf2_per_cu_text_offset): Likewise.
13061         (init_one_comp_unit): Assign dwarf2_per_objfile instead of
13062         objfile.
13063         (set_die_type): Access objfile through
13064         dwarf2_per_objfile.
13065
13066 2018-01-07  Simon Marchi  <simon.marchi@ericsson.com>
13067
13068         * valprint.c (converted_character_d): Remove typedef.
13069         (DEF_VEC_O (converted_character_d)): Remove.
13070         (count_next_character): Use std::vector.
13071         (print_converted_chars_to_obstack): Likewise.
13072         (generic_printstr): Likewise.
13073
13074 2018-01-07  Simon Marchi  <simon.marchi@polymtl.ca>
13075
13076         * xml-support.h (struct gdb_xml_value): Add constructor.
13077         <value>: Change type to unique_xmalloc_ptr.
13078         (gdb_xml_value_s): Remove typedef.
13079         (DEF_VEC_O (gdb_xml_value_s)): Remove.
13080         (gdb_xml_element_start_handler): Change parameter type to
13081         std::vector.
13082         (xml_find_attribute): Likewise.
13083         * xml-support.c (xml_find_attribute): Change parameter type to
13084         std::vector and adjust.
13085         (gdb_xml_values_cleanup): Remove.
13086         (gdb_xml_parser::start_element): Adjust to std::vector.
13087         (xinclude_start_include): Change paraeter type to std::vector
13088         and adjust.
13089         * btrace.c (check_xml_btrace_version): Likewise.
13090         (parse_xml_btrace_block): Likewise.
13091         (parse_xml_btrace_pt_config_cpu): Likewise.
13092         (parse_xml_btrace_pt): Likewise.
13093         (parse_xml_btrace_conf_bts): Likewise.
13094         (parse_xml_btrace_conf_pt): Likewise.
13095         * memory-map.c (memory_map_start_memory): Likewise.
13096         (memory_map_start_property): Likewise.
13097         * osdata.c (osdata_start_osdata): Likewise.
13098         (osdata_start_item): Likewise.
13099         (osdata_start_column): Likewise.
13100         * remote.c (start_thread): Likewise.
13101         * solib-aix.c (library_list_start_library): Likewise.
13102         (library_list_start_list): Likewise.
13103         * solib-svr4.c (library_list_start_library): Likewise.
13104         (svr4_library_list_start_list): Likewise.
13105         * solib-target.c (library_list_start_segment): Likewise.
13106         (library_list_start_section): Likewise.
13107         (library_list_start_library): Likewise.
13108         (library_list_start_list): Likewise.
13109         * tracepoint.c (traceframe_info_start_memory): Likewise.
13110         (traceframe_info_start_tvar): Likewise.
13111         * xml-syscall.c (syscall_start_syscall): Likewise.
13112         * xml-tdesc.c (tdesc_start_target): Likewise.
13113         (tdesc_start_feature): Likewise.
13114         (tdesc_start_reg): Likewise.
13115         (tdesc_start_union): Likewise.
13116         (tdesc_start_struct): Likewise.
13117         (tdesc_start_flags): Likewise.
13118         (tdesc_start_enum): Likewise.
13119         (tdesc_start_field): Likewise.
13120         (tdesc_start_enum_value): Likewise.
13121         (tdesc_start_vector): Likewise.
13122
13123 2018-01-07  Simon Marchi  <simon.marchi@polymtl.ca>
13124
13125         * extension.h (struct xmethod_worker) <clone>: Remove.
13126         * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
13127         Remove.
13128         (python_xmethod_worker::clone): Remove.
13129         * valops.c (find_overload_match): Use std::move instead of
13130         clone.
13131
13132 2018-01-07  Simon Marchi  <simon.marchi@polymtl.ca>
13133
13134         * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
13135         (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
13136         <free_xmethod_worker_data>: Remove.
13137         <get_matching_xmethod_workers>: Chance VEC to std::vector.
13138         <get_xmethod_arg_types>: Remove.
13139         <get_xmethod_result_type>: Remove.
13140         <invoke_xmethod>: Remove.
13141         * extension.c (new_xmethod_worker): Remove.
13142         (clone_xmethod_worker): Remove.
13143         (get_matching_xmethod_workers): Return void, pass std::vector by
13144         pointer.
13145         (get_xmethod_arg_types): Rename to...
13146         (xmethod_worker::get_arg_types): ... this, and adjust.
13147         (get_xmethod_result_type): Rename to...
13148         (xmethod_worker::get_result_type): ... this, and adjust.
13149         (invoke_xmethod): Remove.
13150         (free_xmethod_worker): Remove.
13151         (free_xmethod_worker_vec): Remove.
13152         * extension.h (enum ext_lang_rc): Move here from
13153         extension-priv.h.
13154         (struct xmethod_worker): Add constructor and destructor.
13155         <data>: Remove.
13156         <value>: Remove.
13157         <invoke, clone, do_get_result_type, do_get_arg_types>: New
13158         virtual pure methods.
13159         <get_arg_types, get_result_type>: New methods.
13160         (xmethod_worker_ptr): Remove typedef.
13161         (DEF_VEC_P (xmethod_worker_ptr)): Remove.
13162         (xmethod_worker_vec): Remove typedef.
13163         (xmethod_worker_up): New typedef.
13164         (invoke_xmethod): Remove.
13165         (clone_xmethod_worker): Remove.
13166         (free_xmethod_worker): Remove.
13167         (free_xmethod_worker_vec): Remove.
13168         (get_xmethod_arg_types): Remove.
13169         (get_xmethod_result_type): Remove.
13170         * valops.c (find_method_list): Use std::vector, don't use
13171         intermediate vector.
13172         (value_find_oload_method_list): Use std::vector.
13173         (find_overload_match): Use std::vector.
13174         (find_oload_champ): Use std::vector.
13175         * value.c (value_free): Use operator delete.
13176         (value_of_xmethod): Rename to...
13177         (value_from_xmethod): ... this.  Don't assign
13178         xmethod_worker::value, take rvalue-reference.
13179         (result_type_of_xmethod): Adjust.
13180         (call_xmethod): Adjust.
13181         * value.h: Include extension.h.
13182         (struct xmethod_worker): Don't forward-declare.
13183         (value_of_xmethod): Rename to...
13184         (value_from_xmethod): ... this, take rvalue-reference.
13185         * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
13186         (struct python_xmethod_worker): ... this, add constructor and
13187         destructor.
13188         <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
13189         (gdbpy_free_xmethod_worker_data): Rename to...
13190         (python_xmethod_worker::~python_xmethod_worker): ... this and
13191         adjust.
13192         (gdbpy_clone_xmethod_worker_data): Rename to...
13193         (python_xmethod_worker::clone): ... this and adjust.
13194         (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
13195         temporary vector.
13196         (gdbpy_get_xmethod_arg_types): Rename to...
13197         (python_xmethod_worker::do_get_arg_types): ... this and adjust.
13198         (gdbpy_get_xmethod_result_type): Rename to...
13199         (python_xmethod_worker::do_get_result_type): ... this and
13200         adjust.
13201         (gdbpy_invoke_xmethod): Rename to...
13202         (python_xmethod_worker::invoke): ... this and adjust.
13203         (new_python_xmethod_worker): Rename to...
13204         (python_xmethod_worker::python_xmethod_worker): ... this and
13205         adjust.
13206         * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
13207         Remove.
13208         (gdbpy_free_xmethod_worker_data): Remove.
13209         (gdbpy_get_matching_xmethod_workers): Use std::vector.
13210         (gdbpy_get_xmethod_arg_types): Remove.
13211         (gdbpy_get_xmethod_result_type): Remove.
13212         (gdbpy_invoke_xmethod): Remove.
13213         * python/python.c (python_extension_ops): Remove obsolete
13214         callbacks.
13215
13216 2018-01-05  Pedro Alves  <palves@redhat.com>
13217
13218         PR gdb/18653
13219         * common/signals-state-save-restore.c
13220         (save_original_signals_state): New parameter 'quiet'.  Warn if we
13221         find a custom handler preinstalled, instead of internal erroring.
13222         But only warn if !quiet.
13223         * common/signals-state-save-restore.h
13224         (save_original_signals_state): New parameter 'quiet'.
13225         * main.c (captured_main_1): Move save_original_signals_state call
13226         after option handling, and pass QUIET.
13227
13228 2018-01-05  Pedro Alves  <palves@redhat.com>
13229
13230         * spu-tdep.c (spu_catch_start): Pass
13231         symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
13232
13233 2018-01-05  Pedro Alves  <palves@redhat.com>
13234
13235         PR gdb/22670
13236         * ada-lang.c (literal_symbol_name_matcher): New function.
13237         (ada_get_symbol_name_matcher): Use it for
13238         symbol_name_match_type::SEARCH_NAME.
13239         * block.c (block_lookup_symbol): New parameter 'match_type'.  Pass
13240         it down instead of assuming symbol_name_match_type::FULL.
13241         * block.h (block_lookup_symbol): New parameter 'match_type'.
13242         * c-valprint.c (print_unpacked_pointer): Use
13243         lookup_symbol_search_name instead of lookup_symbol.
13244         * compile/compile-object-load.c (get_out_value_type): Pass down
13245         symbol_name_match_type::SEARCH_NAME.
13246         * cp-namespace.c (cp_basic_lookup_symbol): Pass down
13247         symbol_name_match_type::FULL.
13248         * cp-support.c (cp_get_symbol_name_matcher): Handle
13249         symbol_name_match_type::SEARCH_NAME.
13250         * infrun.c (insert_exception_resume_breakpoint): Use
13251         lookup_symbol_search_name.
13252         * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
13253         * psymtab.c (maintenance_check_psymtabs): Use
13254         symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
13255         * stack.c (print_frame_args): Use lookup_symbol_search_name and
13256         SYMBOL_SEARCH_NAME.
13257         * symtab.c (lookup_local_symbol): Don't demangle the lookup name
13258         if symbol_name_match_type::SEARCH_NAME.
13259         (lookup_symbol_in_language): Pass down
13260         symbol_name_match_type::FULL.
13261         (lookup_symbol_search_name): New.
13262         (lookup_language_this): Pass down
13263         symbol_name_match_type::SEARCH_NAME.
13264         (lookup_symbol_aux, lookup_local_symbol): New parameter
13265         'match_type'.  Pass it down.
13266         * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
13267         (lookup_symbol_search_name): New declaration.
13268         (lookup_symbol_in_block): New 'match_type' parameter.
13269
13270 2018-01-05  Pedro Alves  <palves@redhat.com>
13271
13272         PR gdb/22670
13273         * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
13274         ada_lookup_symbol.
13275         (ada_lookup_symbol): Reimplement in terms of
13276         ada_lookup_symbol_list, bits factored out from
13277         ada_lookup_encoded_symbol.
13278
13279 2018-01-05  Joel Brobecker  <brobecker@adacore.com>
13280
13281         * ada-exp.y (write_object_renaming): When subscripting an array
13282         using a symbol as the index, pass the block in call to
13283         ada_lookup_encoded_symbol when looking that symbol up.
13284
13285 2018-01-05  Jerome Guitton  <guitton@adacore.com>
13286
13287         * ada-lang.c (ada_array_length): Use ada_index_type instead of
13288         TYPE_INDEX_TYPE.
13289
13290 2018-01-05  Joel Brobecker  <brobecker@adacore.com>
13291
13292         * ada-lang.c (ada_to_fixed_value_create): Add handling of
13293         the case where VALUE_LVAL (val0) is not lval_memory.
13294
13295 2018-01-05  Xavier Roirand  <roirand@adacore.com>
13296
13297         * ada-valprint.c (print_optional_low_bound): Handle
13298         character-indexed array printing like boolean-indexed array
13299         printing.
13300
13301 2018-01-05  Joel Brobecker  <brobecker@adacore.com>
13302
13303         * NEWS: Create a new section for the next release branch.
13304         Rename the section of the current branch, now that it has
13305         been cut.
13306
13307 2018-01-05  Joel Brobecker  <brobecker@adacore.com>
13308
13309         GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
13310         * version.in: Bump version to 8.1.50.DATE-git.
13311
13312 2018-01-03  Xavier Roirand  <roirand@adacore.com>
13313
13314         * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
13315         Add field.
13316         * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
13317         Add field.
13318         (default_exception_support_info) <catch_handlers_sym>: Add field.
13319         (exception_support_info_fallback) <catch_handlers_sym>: Add field.
13320         (ada_exception_name_addr_1): Add "catch handlers" handling.
13321         (ada_exception_catchpoint_cond_string) <ex>: New parameter.
13322         Update all callers.
13323         (create_excep_cond_exprs) <ex>: Add parameter.
13324         (re_set_exception): Update create_excep_cond_exprs call.
13325         (print_it_exception, print_one_exception, print_mention_exception)
13326         (print_recreate_exception): Add "catch handler" handling.
13327         (allocate_location_catch_handlers, re_set_catch_handlers)
13328         (check_status_catch_handlers, print_it_catch_handlers)
13329         (print_one_catch_handlers, print_mention_catch_handlers)
13330         (print_recreate_catch_handlers): New function.
13331         (catch_handlers_breakpoint_ops): New variable.
13332         (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
13333         Add parameter.  Add "catch handler" handling.
13334         (ada_exception_sym_name, ada_exception_breakpoint_ops):
13335         Add "catch handler" handling.
13336         (ada_exception_catchpoint_cond_string): Add "catch handler"
13337         handling.
13338         (create_ada_exception_catchpoint): Update create_excep_cond_exprs
13339         call.
13340         (catch_ada_handlers_command): New function.
13341         (initialize_ada_catchpoint_ops): Initialize "catch handlers"
13342         operations structure.
13343         (_initialize_ada_language): Add "catch handlers" command entry.
13344         * NEWS: Document "catch handlers" feature.
13345
13346 2018-01-02  Joel Brobecker  <brobecker@adacore.com>
13347
13348         * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
13349         account when creating the array type of the slice.
13350         (ada_value_slice): Likewise.
13351
13352 2018-01-02  Joel Brobecker  <brobecker@adacore.com>
13353
13354         * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
13355         New enum value.
13356         (create_array_type_with_stride): Add byte_stride_prop parameter.
13357         * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
13358         New parameter.  Update all callers in this file.
13359         (array_type_has_dynamic_stride): New function.
13360         (is_dynamic_type_internal, resolve_dynamic_array): Add handling
13361         of arrays with dynamic byte strides.
13362         * dwarf2read.c (read_array_type): Add support for dynamic
13363         DW_AT_byte_stride attributes.
13364
13365 2018-01-02  Joel Brobecker  <brobecker@adacore.com>
13366
13367         * dwarf2read.c (read_unspecified_type): Treat
13368         DW_TAG_enumeration_type DIEs from Ada units as stubs.
13369
13370 2018-01-01  Joel Brobecker  <brobecker@adacore.com>
13371
13372         Update copyright year range in all GDB files.
13373
13374 2018-01-01  Joel Brobecker  <brobecker@adacore.com>
13375
13376         * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
13377         and gdb/testsuite/gdb.base/step-line.c.
13378
13379 2018-01-01  Joel Brobecker  <brobecker@adacore.com>
13380
13381         * copyright.py (main): Dump the contents of
13382         MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
13383         even if BY_HAND is empty.
13384
13385 2018-01-01  Joel Brobecker  <brobecker@adacore.com>
13386
13387         * top.c (print_gdb_version): Update Copyright year in version
13388         message.
13389
13390 2018-01-01  Joel Brobecker  <brobecker@adacore.com>
13391
13392         * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
13393
13394 For older changes see ChangeLog-2017.
13395 \f
13396 Local Variables:
13397 mode: change-log
13398 left-margin: 8
13399 fill-column: 74
13400 version-control: never
13401 coding: utf-8
13402 End: