1 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
5 * gnulib/aclocal.m4: Regenerate.
6 * gnulib/config.in: Regenerate.
7 * gnulib/configure: Regenerate.
8 * gnulib/import/Makefile.am: Update.
9 * gnulib/import/Makefile.in: Update.
10 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
11 * gnulib/import/_Noreturn.h: ... this.
12 * gnulib/import/alloca.in.h: Update.
13 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
14 * gnulib/import/arg-nonnull.h: ... this.
15 * gnulib/import/assure.h: Update.
16 * gnulib/import/at-func.c: Update.
17 * gnulib/import/basename-lgpl.c: Update.
18 * gnulib/import/extra/snippet/c++defs.h: Rename to...
19 * gnulib/import/c++defs.h: ... this.
20 * gnulib/import/canonicalize-lgpl.c: Update.
21 * gnulib/import/cdefs.h: Update.
22 * gnulib/import/chdir-long.c: Update.
23 * gnulib/import/chdir-long.h: Update.
24 * gnulib/import/cloexec.c: Update.
25 * gnulib/import/cloexec.h: Update.
26 * gnulib/import/close.c: Update.
27 * gnulib/import/closedir.c: Update.
28 * gnulib/import/config.charset: Update.
29 * gnulib/import/dirent-private.h: Update.
30 * gnulib/import/dirent.in.h: Update.
31 * gnulib/import/dirfd.c: Update.
32 * gnulib/import/dirname-lgpl.c: Update.
33 * gnulib/import/dirname.h: Update.
34 * gnulib/import/dosname.h: Update.
35 * gnulib/import/dup-safer-flag.c: Update.
36 * gnulib/import/dup-safer.c: Update.
37 * gnulib/import/dup.c: Update.
38 * gnulib/import/dup2.c: Update.
39 * gnulib/import/errno.in.h: Update.
40 * gnulib/import/error.c: Update.
41 * gnulib/import/error.h: Update.
42 * gnulib/import/exitfail.c: Update.
43 * gnulib/import/exitfail.h: Update.
44 * gnulib/import/extra/update-copyright: Update.
45 * gnulib/import/fchdir.c: Update.
46 * gnulib/import/fcntl.c: Update.
47 * gnulib/import/fcntl.in.h: Update.
48 * gnulib/import/fd-hook.c: Update.
49 * gnulib/import/fd-hook.h: Update.
50 * gnulib/import/fd-safer-flag.c: Update.
51 * gnulib/import/fd-safer.c: Update.
52 * gnulib/import/fdopendir.c: Update.
53 * gnulib/import/filename.h: Update.
54 * gnulib/import/filenamecat-lgpl.c: Update.
55 * gnulib/import/filenamecat.h: Update.
56 * gnulib/import/flexmember.h: Update.
57 * gnulib/import/float+.h: Update.
58 * gnulib/import/float.c: Update.
59 * gnulib/import/float.in.h: Update.
60 * gnulib/import/fnmatch.c: Update.
61 * gnulib/import/fnmatch.in.h: Update.
62 * gnulib/import/fnmatch_loop.c: Update.
63 * gnulib/import/fpucw.h: Update.
64 * gnulib/import/frexp.c: Update.
65 * gnulib/import/frexpl.c: Update.
66 * gnulib/import/fstat.c: Update.
67 * gnulib/import/fstatat.c: Update.
68 * gnulib/import/getcwd-lgpl.c: Update.
69 * gnulib/import/getcwd.c: Update.
70 * gnulib/import/getdtablesize.c: Update.
71 * gnulib/import/getlogin_r.c: Update.
72 * gnulib/import/getprogname.c: Update.
73 * gnulib/import/getprogname.h: Update.
74 * gnulib/import/gettext.h: Update.
75 * gnulib/import/gettimeofday.c: Update.
76 * gnulib/import/glob-libc.h: Update.
77 * gnulib/import/glob.c: Update.
78 * gnulib/import/glob.in.h: Update.
79 * gnulib/import/glob_internal.h: Update.
80 * gnulib/import/glob_pattern_p.c: Update.
81 * gnulib/import/globfree.c: Update.
82 * gnulib/import/hard-locale.c: Update.
83 * gnulib/import/hard-locale.h: Update.
84 * gnulib/import/intprops.h: Update.
85 * gnulib/import/inttypes.in.h: Update.
86 * gnulib/import/isnan.c: Update.
87 * gnulib/import/isnand-nolibm.h: Update.
88 * gnulib/import/isnand.c: Update.
89 * gnulib/import/isnanl-nolibm.h: Update.
90 * gnulib/import/isnanl.c: Update.
91 * gnulib/import/itold.c: Update.
92 * gnulib/import/libc-config.h: Update.
93 * gnulib/import/limits.in.h: Update.
94 * gnulib/import/localcharset.c: Update.
95 * gnulib/import/localcharset.h: Update.
96 * gnulib/import/localtime-buffer.c: Update.
97 * gnulib/import/localtime-buffer.h: Update.
98 * gnulib/import/lstat.c: Update.
99 * gnulib/import/m4/00gnulib.m4: Update.
100 * gnulib/import/m4/__inline.m4: Update.
101 * gnulib/import/m4/absolute-header.m4: Update.
102 * gnulib/import/m4/alloca.m4: Update.
103 * gnulib/import/m4/builtin-expect.m4: Update.
104 * gnulib/import/m4/canonicalize.m4: Update.
105 * gnulib/import/m4/chdir-long.m4: Update.
106 * gnulib/import/m4/close.m4: Update.
107 * gnulib/import/m4/closedir.m4: Update.
108 * gnulib/import/m4/configmake.m4: Update.
109 * gnulib/import/m4/d-ino.m4: Update.
110 * gnulib/import/m4/d-type.m4: Update.
111 * gnulib/import/m4/dirent_h.m4: Update.
112 * gnulib/import/m4/dirfd.m4: Update.
113 * gnulib/import/m4/dirname.m4: Update.
114 * gnulib/import/m4/double-slash-root.m4: Update.
115 * gnulib/import/m4/dup.m4: Update.
116 * gnulib/import/m4/dup2.m4: Update.
117 * gnulib/import/m4/eealloc.m4: Update.
118 * gnulib/import/m4/environ.m4: Update.
119 * gnulib/import/m4/errno_h.m4: Update.
120 * gnulib/import/m4/error.m4: Update.
121 * gnulib/import/m4/exponentd.m4: Update.
122 * gnulib/import/m4/exponentl.m4: Update.
123 * gnulib/import/m4/extensions.m4: Update.
124 * gnulib/import/m4/extern-inline.m4: Update.
125 * gnulib/import/m4/fchdir.m4: Update.
126 * gnulib/import/m4/fcntl-o.m4: Update.
127 * gnulib/import/m4/fcntl.m4: Update.
128 * gnulib/import/m4/fcntl_h.m4: Update.
129 * gnulib/import/m4/fdopendir.m4: Update.
130 * gnulib/import/m4/filenamecat.m4: Update.
131 * gnulib/import/m4/flexmember.m4: Update.
132 * gnulib/import/m4/float_h.m4: Update.
133 * gnulib/import/m4/fnmatch.m4: Update.
134 * gnulib/import/m4/fnmatch_h.m4: Update.
135 * gnulib/import/m4/fpieee.m4: Update.
136 * gnulib/import/m4/frexp.m4: Update.
137 * gnulib/import/m4/frexpl.m4: Update.
138 * gnulib/import/m4/fstat.m4: Update.
139 * gnulib/import/m4/fstatat.m4: Update.
140 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
141 * gnulib/import/m4/getcwd-path-max.m4: Update.
142 * gnulib/import/m4/getcwd.m4: Update.
143 * gnulib/import/m4/getdtablesize.m4: Update.
144 * gnulib/import/m4/getlogin.m4: Update.
145 * gnulib/import/m4/getlogin_r.m4: Update.
146 * gnulib/import/m4/getpagesize.m4: Update.
147 * gnulib/import/m4/getprogname.m4: Update.
148 * gnulib/import/m4/gettimeofday.m4: Update.
149 * gnulib/import/m4/glibc21.m4: Update.
150 * gnulib/import/m4/glob.m4: Update.
151 * gnulib/import/m4/glob_h.m4: Update.
152 * gnulib/import/m4/gnulib-cache.m4: Update.
153 * gnulib/import/m4/gnulib-common.m4: Update.
154 * gnulib/import/m4/gnulib-comp.m4: Update.
155 * gnulib/import/m4/gnulib-tool.m4: Update.
156 * gnulib/import/m4/hard-locale.m4: Update.
157 * gnulib/import/m4/include_next.m4: Update.
158 * gnulib/import/m4/inttypes-pri.m4: Update.
159 * gnulib/import/m4/inttypes.m4: Update.
160 * gnulib/import/m4/isnand.m4: Update.
161 * gnulib/import/m4/isnanl.m4: Update.
162 * gnulib/import/m4/largefile.m4: Update.
163 * gnulib/import/m4/limits-h.m4: Update.
164 * gnulib/import/m4/localcharset.m4: Update.
165 * gnulib/import/m4/locale-fr.m4: Update.
166 * gnulib/import/m4/locale-ja.m4: Update.
167 * gnulib/import/m4/locale-zh.m4: Update.
168 * gnulib/import/m4/localtime-buffer.m4: Update.
169 * gnulib/import/m4/longlong.m4: Update.
170 * gnulib/import/m4/lstat.m4: Update.
171 * gnulib/import/m4/malloc.m4: Update.
172 * gnulib/import/m4/malloca.m4: Update.
173 * gnulib/import/m4/math_h.m4: Update.
174 * gnulib/import/m4/mbrtowc.m4: Update.
175 * gnulib/import/m4/mbsinit.m4: Update.
176 * gnulib/import/m4/mbsrtowcs.m4: Update.
177 * gnulib/import/m4/mbstate_t.m4: Update.
178 * gnulib/import/m4/memchr.m4: Update.
179 * gnulib/import/m4/memmem.m4: Update.
180 * gnulib/import/m4/mempcpy.m4: Update.
181 * gnulib/import/m4/memrchr.m4: Update.
182 * gnulib/import/m4/mkdir.m4: Update.
183 * gnulib/import/m4/mkstemp.m4: Update.
184 * gnulib/import/m4/mmap-anon.m4: Update.
185 * gnulib/import/m4/mode_t.m4: Update.
186 * gnulib/import/m4/msvc-inval.m4: Update.
187 * gnulib/import/m4/msvc-nothrow.m4: Update.
188 * gnulib/import/m4/multiarch.m4: Update.
189 * gnulib/import/m4/nocrash.m4: Update.
190 * gnulib/import/m4/off_t.m4: Update.
191 * gnulib/import/m4/onceonly.m4: Update.
192 * gnulib/import/m4/open-cloexec.m4: Update.
193 * gnulib/import/m4/open.m4: Update.
194 * gnulib/import/m4/openat.m4: Update.
195 * gnulib/import/m4/opendir.m4: Update.
196 * gnulib/import/m4/pathmax.m4: Update.
197 * gnulib/import/m4/rawmemchr.m4: Update.
198 * gnulib/import/m4/readdir.m4: Update.
199 * gnulib/import/m4/readlink.m4: Update.
200 * gnulib/import/m4/realloc.m4: Update.
201 * gnulib/import/m4/rename.m4: Update.
202 * gnulib/import/m4/rewinddir.m4: Update.
203 * gnulib/import/m4/rmdir.m4: Update.
204 * gnulib/import/m4/save-cwd.m4: Update.
205 * gnulib/import/m4/secure_getenv.m4: Update.
206 * gnulib/import/m4/setenv.m4: Update.
207 * gnulib/import/m4/signal_h.m4: Update.
208 * gnulib/import/m4/ssize_t.m4: Update.
209 * gnulib/import/m4/stat-time.m4: Update.
210 * gnulib/import/m4/stat.m4: Update.
211 * gnulib/import/m4/std-gnu11.m4: Update.
212 * gnulib/import/m4/stdbool.m4: Update.
213 * gnulib/import/m4/stddef_h.m4: Update.
214 * gnulib/import/m4/stdint.m4: Update.
215 * gnulib/import/m4/stdio_h.m4: Update.
216 * gnulib/import/m4/stdlib_h.m4: Update.
217 * gnulib/import/m4/strchrnul.m4: Update.
218 * gnulib/import/m4/strdup.m4: Update.
219 * gnulib/import/m4/strerror.m4: Update.
220 * gnulib/import/m4/string_h.m4: Update.
221 * gnulib/import/m4/strstr.m4: Update.
222 * gnulib/import/m4/strtok_r.m4: Update.
223 * gnulib/import/m4/sys_socket_h.m4: Update.
224 * gnulib/import/m4/sys_stat_h.m4: Update.
225 * gnulib/import/m4/sys_time_h.m4: Update.
226 * gnulib/import/m4/sys_types_h.m4: Update.
227 * gnulib/import/m4/tempname.m4: Update.
228 * gnulib/import/m4/time_h.m4: Update.
229 * gnulib/import/m4/unistd-safer.m4: Update.
230 * gnulib/import/m4/unistd_h.m4: Update.
231 * gnulib/import/m4/warn-on-use.m4: Update.
232 * gnulib/import/m4/wchar_h.m4: Update.
233 * gnulib/import/m4/wchar_t.m4: Update.
234 * gnulib/import/m4/wctype_h.m4: Update.
235 * gnulib/import/m4/wint_t.m4: Update.
236 * gnulib/import/malloc.c: Update.
237 * gnulib/import/malloc/scratch_buffer.h: Update.
238 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
239 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
240 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
241 * gnulib/import/malloca.c: Update.
242 * gnulib/import/malloca.h: Update.
243 * gnulib/import/malloca.valgrind: Update.
244 * gnulib/import/math.in.h: Update.
245 * gnulib/import/mbrtowc.c: Update.
246 * gnulib/import/mbsinit.c: Update.
247 * gnulib/import/mbsrtowcs-impl.h: Update.
248 * gnulib/import/mbsrtowcs-state.c: Update.
249 * gnulib/import/mbsrtowcs.c: Update.
250 * gnulib/import/memchr.c: Update.
251 * gnulib/import/memmem.c: Update.
252 * gnulib/import/mempcpy.c: Update.
253 * gnulib/import/memrchr.c: Update.
254 * gnulib/import/mkdir.c: Update.
255 * gnulib/import/mkstemp.c: Update.
256 * gnulib/import/msvc-inval.c: Update.
257 * gnulib/import/msvc-inval.h: Update.
258 * gnulib/import/msvc-nothrow.c: Update.
259 * gnulib/import/msvc-nothrow.h: Update.
260 * gnulib/import/open.c: Update.
261 * gnulib/import/openat-die.c: Update.
262 * gnulib/import/openat-priv.h: Update.
263 * gnulib/import/openat-proc.c: Update.
264 * gnulib/import/openat.c: Update.
265 * gnulib/import/openat.h: Update.
266 * gnulib/import/opendir.c: Update.
267 * gnulib/import/pathmax.h: Update.
268 * gnulib/import/pipe-safer.c: Update.
269 * gnulib/import/rawmemchr.c: Update.
270 * gnulib/import/readdir.c: Update.
271 * gnulib/import/readlink.c: Update.
272 * gnulib/import/realloc.c: Update.
273 * gnulib/import/ref-add.sin: Update.
274 * gnulib/import/ref-del.sin: Update.
275 * gnulib/import/rename.c: Update.
276 * gnulib/import/rewinddir.c: Update.
277 * gnulib/import/rmdir.c: Update.
278 * gnulib/import/same-inode.h: Update.
279 * gnulib/import/save-cwd.c: Update.
280 * gnulib/import/save-cwd.h: Update.
281 * gnulib/import/scratch_buffer.h: Update.
282 * gnulib/import/secure_getenv.c: Update.
283 * gnulib/import/setenv.c: Update.
284 * gnulib/import/signal.in.h: Update.
285 * gnulib/import/stat-time.c: Update.
286 * gnulib/import/stat-time.h: Update.
287 * gnulib/import/stat-w32.c: Update.
288 * gnulib/import/stat-w32.h: Update.
289 * gnulib/import/stat.c: Update.
290 * gnulib/import/stdbool.in.h: Update.
291 * gnulib/import/stddef.in.h: Update.
292 * gnulib/import/stdint.in.h: Update.
293 * gnulib/import/stdio.in.h: Update.
294 * gnulib/import/stdlib.in.h: Update.
295 * gnulib/import/str-two-way.h: Update.
296 * gnulib/import/strchrnul.c: Update.
297 * gnulib/import/strdup.c: Update.
298 * gnulib/import/streq.h: Update.
299 * gnulib/import/strerror-override.c: Update.
300 * gnulib/import/strerror-override.h: Update.
301 * gnulib/import/strerror.c: Update.
302 * gnulib/import/string.in.h: Update.
303 * gnulib/import/stripslash.c: Update.
304 * gnulib/import/strnlen1.c: Update.
305 * gnulib/import/strnlen1.h: Update.
306 * gnulib/import/strstr.c: Update.
307 * gnulib/import/strtok_r.c: Update.
308 * gnulib/import/sys_stat.in.h: Update.
309 * gnulib/import/sys_time.in.h: Update.
310 * gnulib/import/sys_types.in.h: Update.
311 * gnulib/import/tempname.c: Update.
312 * gnulib/import/tempname.h: Update.
313 * gnulib/import/time.in.h: Update.
314 * gnulib/import/unistd--.h: Update.
315 * gnulib/import/unistd-safer.h: Update.
316 * gnulib/import/unistd.in.h: Update.
317 * gnulib/import/unsetenv.c: Update.
318 * gnulib/import/verify.h: Update.
319 * gnulib/import/extra/snippet/warn-on-use.h: Update.
320 * gnulib/import/wchar.in.h: Update.
321 * gnulib/import/wctype.in.h: Update.
322 * gnulib/import/xalloc-oversized.h: Update.
323 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
324 "53e2c179f26a890fa6685af4b6c1397ee370433b".
326 2018-08-16 Gary Benson <gbenson@redhat.com>
329 * gdb/main.c (captured_main_1): Exit with nonzero status
330 in batch mode if the last command to be executed failed.
331 * NEWS: Mention the above.
333 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
335 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
336 end of warning message.
338 2018-08-29 Alan Hayward <alan.hayward@arm.com>
341 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
342 (aarch64_extract_return_value): Use
343 aapcs_is_vfp_call_or_return_candidate.
344 (aarch64_return_in_memory): Likewise.
345 (aarch64_store_return_value): Likewise.
347 2018-08-29 Alan Hayward <alan.hayward@arm.com>
350 (aapcs_is_vfp_call_or_return_candidate): Make static
351 (pass_in_v_or_stack): Remove function.
352 (pass_in_v_vfp_candidate): New function.
353 (aarch64_push_dummy_call): Check for float register candidates.
355 2018-08-29 Alan Hayward <alan.hayward@arm.com>
357 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
358 (aapcs_is_vfp_call_or_return_candidate_1): New function.
359 (aapcs_is_vfp_call_or_return_candidate): Likewise.
361 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
364 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
365 (struct ipa_sym_addresses): Rename to...
366 (struct ipa_sym_addresses_common): ... this.
367 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
369 2018-08-28 Tom Tromey <tom@tromey.com>
371 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
372 (token_fifo): Now a std::vector.
373 (yylex, c_parse): Update.
374 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
375 (token_fifo): Now a std::vector.
376 (yylex, d_parse): Update.
377 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
378 (token_fifo): Now a std::vector.
379 (yylex, go_parse): Update.
381 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
383 * parser-defs.h (struct type_stack) <elements>: Change type to
384 std::vector<union type_stack_elt>.
385 <depth, size>: Remove.
386 * parse.c (parse_exp_in_context_1): Adjust.
387 (type_stack_reserve): Remove.
388 (check_type_stack_depth): Remove.
389 (insert_into_type_stack): Adjust to std::vector.
390 (insert_type): Likewise.
391 (push_type): Likewise.
392 (push_type_int): Likewise.
393 (insert_type_address_space): Likewise.
394 (pop_type): Likewise.
395 (pop_type_int): Likewise.
396 (pop_typelist): Likewise.
397 (pop_type_stack): Likewise.
398 (append_type_stack): Likewise.
399 (push_type_stack): Likewise.
400 (get_type_stack): Likewise.
401 (type_stack_cleanup): Likewise.
402 (push_typelist): Likewise.
403 (follow_types): Likewise.
404 (_initialize_parse): Likewise.
406 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
408 * NEWS: Mention csky target.
410 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
411 Hafiz Abid Qadeer <abidh@codesourcery.com>
412 Don Breazeal <donb@codesourcery.com>
414 * csky-linux-tdep.c: New file.
415 * csky-tdep.c: Likewise.
416 * csky-tdep.h: Likewise.
417 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
419 (HFILES_NO_SRCDIR): Add csky-tdep.h.
420 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
421 * configure.tgt: Add csky support.
423 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
425 * python/py-framefilter.c (py_print_frame): Print frame architecture
426 when printing on an MI output.
428 2018-08-27 Tom Tromey <tom@tromey.com>
431 * configure: Rebuild.
432 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
434 2018-08-27 Tom Tromey <tom@tromey.com>
436 * aarch64-linux-tdep.c
437 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
440 2018-08-27 Tom Tromey <tom@tromey.com>
442 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
444 (ppc64_standard_linkage1, ppc64_standard_linkage2)
445 (ppc64_standard_linkage3, ppc64_standard_linkage4)
446 (ppc64_standard_linkage5, ppc64_standard_linkage6)
447 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
450 2018-08-27 Tom Tromey <tom@tromey.com>
452 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
453 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
455 2018-08-27 Tom Tromey <tom@tromey.com>
457 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
458 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
460 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
462 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
464 * sparc-linux-tdep.c (sparc32_linux_sigframe)
465 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
466 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
468 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
469 (ppc64_linux_sigaction_tramp_frame)
470 (ppc32_linux_sighandler_tramp_frame)
471 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
472 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
473 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
474 * mn10300-linux-tdep.c (am33_linux_sigframe)
475 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
476 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
477 * mips-linux-tdep.c (mips_linux_o32_sigframe)
478 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
479 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
480 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
481 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
482 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
483 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
484 * microblaze-linux-tdep.c
485 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
486 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
487 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
488 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
489 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
490 * common/common-types.h (ULONGEST_MAX): New define.
491 (CORE_ADDR_MAX): Fix formatting.
492 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
493 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
494 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
495 (arm_linux_rt_sigreturn_tramp_frame)
496 (arm_eabi_linux_sigreturn_tramp_frame)
497 (arm_eabi_linux_rt_sigreturn_tramp_frame)
498 (thumb2_eabi_linux_sigreturn_tramp_frame)
499 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
500 (arm_linux_restart_syscall_tramp_frame)
501 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
502 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
503 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
505 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
507 2018-08-27 Tom Tromey <tom@tromey.com>
509 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
511 * mips-tdep.c (mips_deal_with_atomic_sequence)
512 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
513 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
514 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
515 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
517 * aarch64-tdep.c (aarch64_software_single_step): Use
520 2018-08-27 Tom Tromey <tom@tromey.com>
522 * linespec.c (complete_linespec_component): Add cast to "char".
523 * completer.c (completion_tracker::build_completion_result): Add
526 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
528 * solist.h (struct solist, struct target_so_ops): Fix
531 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
533 * ada-tasks.c (ada_task_info_s): Remove typedef.
534 (DEF_VEC_O(ada_task_info_s)): Remove.
535 (struct ada_tasks_inferior_data): Initialize fields.
536 <task_list>: Make an std::vector.
537 (get_ada_tasks_inferior_data): Allocate with new.
538 (ada_get_task_number): Adjust.
539 (get_task_number_from_id): Likewise.
540 (valid_task_id): Likewise.
541 (ada_get_task_info_from_ptid): Likewise.
542 (iterate_over_live_ada_tasks): Likewise.
543 (add_ada_task): Likewise.
544 (read_known_tasks): Likewise.
545 (ada_build_task_list): Likewise.
546 (print_ada_task_info): Likewise.
547 (info_task): Likewise.
548 (task_command_1): Likewise.
550 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
552 * ada-lang.c (add_angle_brackets): Return std::string.
554 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
556 * python/py-threadevent.c (py_get_event_thread): Initialize
559 2018-08-24 Pedro Alves <palves@redhat.com>
561 * python/py-bpevent.c (create_breakpoint_event_object): Use
563 * python/py-continueevent.c (emit_continue_event): Use
565 * python/py-exitedevent.c (create_exited_event_object): Return a
567 (emit_exited_event): Use copy-initialization.
568 * python/py-inferior.c (python_new_inferior)
569 (python_inferior_deleted, add_thread_object): Use
571 * python/py-infevents.c (create_inferior_call_event_object)
572 (create_register_changed_event_object)
573 (create_memory_changed_event_object): Return a gdbpy_ref<>.
574 (emit_inferior_call_event, emit_memory_changed_event)
575 (emit_register_changed_event): Use copy-initialization.
576 * python/py-newobjfileevent.c (create_new_objfile_event_object):
577 Return a gdbpy_ref<>.
578 (emit_new_objfile_event): Use copy-initialization.
579 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
580 (emit_clear_objfiles_event): Use copy-initialization.
581 * python/py-signalevent.c (create_signal_event_object): Use
583 * python/py-threadevent.c (create_thread_event_object): Use
586 2018-08-24 Pedro Alves <palves@redhat.com>
587 Simon Marchi <simon.marchi@ericsson.com>
590 * python/py-continueevent.c: Include "gdbthread.h".
591 (create_continue_event_object): Add intro comment. Add 'ptid'
592 parameter. Use it to find thread to pass to
593 create_thread_event_object.
594 (emit_continue_event): Pass PTID down to
595 create_continue_event_object.
596 * python/py-event.h (py_get_event_thread): Declare.
597 (create_thread_event_object): Remove default from 'thread'
599 * python/py-stopevent.c (create_stop_event_object): Use
601 * python/py-threadevent.c (get_event_thread): Rename to ...
602 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
603 and use it to find the thread.
604 (create_thread_event_object): Assert that THREAD isn't null.
605 Don't find the event thread here.
607 2018-08-23 Kevin Buettner <kevinb@redhat.com>
609 * block.h (blockrange, blockranges): New struct declarations.
610 (struct block): Add new field named `ranges'.
611 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
612 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
613 macros for accessing ranges in struct block.
614 (make_blockranges): New declaration.
615 block.c (make_blockranges): New function.
616 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
618 * symtab.h (find_pc_partial_function): Add new parameter `block'.
619 * blockframe.c (cache_pc_function_block): New static global.
620 (clear_pc_function_cache): Clear cache_pc_function_block.
621 (find_pc_partial_function): Move comment to symtab.h. Add
622 support for non-contiguous blocks.
623 * cli/cli-cmds.c (block.h): Include.
624 (print_disassembly): Handle printing of non-contiguous blocks.
625 (disassemble_current_function): Likewise.
626 (disassemble_command): Likewise.
628 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
630 * blockframe.c (get_pc_function_start): Likewise.
631 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
632 (gcc_symbol_address): Likewise.
633 * compile/compile-object-run.c (compile_object_run): Likewise.
634 * compile/compile.c (get_expr_block_and_pc): Likewise.
635 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
636 (func_addr_to_tail_call_list): Likewise.
637 * findvar.c (default_read_var_value): Likewise.
638 * inline-frame.c (inline_frame_this_id): Likewise.
639 (skip-inline_frames): Likewise.
640 * infcmd.c (until_next_command): Likewise.
641 * linespec.c (convert_linespec_to_sals): Likewise.
642 * parse.c (parse_exp_in_context_1): Likewise.
643 * printcmd.c (build_address_symbolic): likewise.
644 (info_address_command): Likewise.
645 symtab.c (find_function_start_sal): Likewise.
646 (skip_prologue_sal): Likewise.
647 (find_function_alias_target): Likewise.
648 (find_gnu_ifunc): Likewise.
649 * stack.c (find_frame_funname): Likewise.
650 * symtab.c (fixup_symbol_section): Likewise.
651 (find_function_start_sal): Likewise.
652 (skip_prologue_sal): Likewsie.
653 (find_function_alias_target): Likewise.
654 (find_gnu_ifunc): Likewise.
655 * tracepoint.c (info_scope_command): Likewise.
656 * value.c (value_fn_field): Likewise.
658 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
659 in place of find_pc_partial_function.
660 * blockframe.c (find_function_entry_range_from_pc): New function.
661 * symtab.h (find_function_entry_range_from_pc): Declare and document.
662 * objfiles.c (objfile_relocate1): Relocate start and end addresses
663 for each range in a block.
666 2018-08-23 Xavier Roirand <roirand@adacore.com>
668 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
671 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
673 * solib-svr4.c (read_program_headers_from_bfd): Return
674 gdb::optional<gdb::byte_vector>.
675 (svr4_exec_displacement): Adjust.
677 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
679 * solib-svr4.c (read_program_header): Return
680 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
681 (find_program_interpreter): Return
682 gdb::optional<gdb::byte_vector>.
683 (scan_dyntag_auxv): Adjust.
684 (enable_break): Adjust.
685 (svr4_exec_displacement): Adjust.
687 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
689 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
690 * inf-child.c (inf_child_target::terminal_save_inferior): New.
692 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
694 * guile/scm-string.c (gdbscm_scm_from_printf): Use
696 * guile/scm-utils.c (gdbscm_printf): Likewise.
697 * serial.c (serial_printf): Likewise.
698 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
700 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
702 * stack.c (print_frame): Print frame architecture when printing on
704 * NEWS: Mention new "arch" attribute in frame output.
706 2018-08-21 Alan Hayward <alan.hayward@arm.com>
708 * arch/aarch64.h (aarch64_regnum): Update comment.
710 2018-08-21 Alan Hayward <alan.hayward@arm.com>
712 * NEWS: Add SVE to 8.2 section.
714 2018-08-21 Pedro Alves <palves@redhat.com>
716 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
717 out from gdbscm_parse_function_args.
718 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
719 gdbscm_parse_function_args_1.
721 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
724 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
727 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
729 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
731 2018-08-19 Michael Spang <spang@google.com>
734 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
737 2018-08-18 Kevin Buettner <kevinb@redhat.com>
739 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
740 dwarf_variable_value.
741 * dwarf2-frame.c (class dwarf_expr_executor):
742 Add override for dwarf_variable_value.
743 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
744 (class symbol_needs_eval_context): Likewise.
745 (indirect_synthetic_pointer): Add forward declaration.
746 (sect_variable_value): New function.
747 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
748 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
749 for DW_OP_GNU_variable_value.
751 2018-08-16 Tom Tromey <tom@tromey.com>
753 * top.c (read_command_file): Update.
754 (command_line_input): Remove "repeat" argument.
755 * ada-lang.c (get_selections): Update.
756 * linespec.c (decode_line_2): Update.
757 * defs.h (command_line_input): Remove argument.
758 * cli/cli-script.c (read_next_line): Update.
759 * python/py-gdb-readline.c: Update.
761 2018-08-17 Tom Tromey <tom@tromey.com>
763 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
766 2018-08-15 Tom Tromey <tom@tromey.com>
768 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
770 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
772 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
773 If used, use find_pc_partial_function to find address range
775 * mi/mi-main.c (mi_cmd_list_features): Report
776 "data-disassemble-a-option" feature.
777 * NEWS: Mention new -data-disassemble option -a.
779 2018-08-13 Tom Tromey <tom@tromey.com>
781 * common/common-defs.h (_FORTIFY_SOURCE): Define.
783 2018-08-13 Alan Hayward <alan.hayward@arm.com>
785 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
786 (aarch64_linux_collect_sve_regset): Likewise.
787 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
788 * regcache.h (regcache_map_entry_size): New function.
790 2018-08-13 Alan Hayward <alan.hayward@arm.com>
792 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
793 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
794 (SVE_HEADER_VL_LENGTH): Likewise.
795 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
796 (SVE_HEADER_FLAGS_LENGTH): Likewise.
797 (SVE_HEADER_RESERVED_LENGTH): Likewise.
798 (SVE_HEADER_SIZE_OFFSET): Likewise.
799 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
800 (SVE_HEADER_VL_OFFSET): Likewise.
801 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
802 (SVE_HEADER_FLAGS_OFFSET): Likewise.
803 (SVE_HEADER_RESERVED_OFFSET): Likewise.
804 (SVE_HEADER_SIZE): Likewise.
805 (aarch64_linux_core_read_vq): Add function.
806 (aarch64_linux_core_read_description): Check for SVE section.
808 2018-08-13 Alan Hayward <alan.hayward@arm.com>
810 * aarch64-fbsd-tdep.c
811 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
813 * aarch64-linux-tdep.c
814 (aarch64_linux_iterate_over_regset_sections): Likewise.
816 (alpha_linux_iterate_over_regset_sections):
818 (alphanbsd_iterate_over_regset_sections): Likewise.
820 (amd64fbsd_iterate_over_regset_sections): Likewise.
822 (amd64_linux_iterate_over_regset_sections): Likewise.
824 (armbsd_iterate_over_regset_sections): Likewise.
826 (arm_fbsd_iterate_over_regset_sections): Likewise.
828 (arm_linux_iterate_over_regset_sections): Likewise.
829 * corelow.c (get_core_registers_cb): Likewise.
830 (core_target::fetch_registers): Likewise.
831 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
832 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
833 * gdbarch.h (void): Regenerate.
834 * gdbarch.sh: Add supply_size and collect_size.
835 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
836 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
837 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
838 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
839 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
840 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
841 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
842 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
843 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
844 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
845 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
846 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
847 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
848 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
849 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
850 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
851 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
852 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
853 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
854 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
855 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
856 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
857 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
858 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
859 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
860 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
861 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
862 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
863 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
864 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
866 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
868 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
871 2018-08-10 Keith Seitz <keiths@redhat.com>
873 * compile/compile-c-support.c (add_code_header, add_code_footer):
874 Move into policy class.
875 (c_push_user_expression, pop_user_expression_nop)
876 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
877 (compile_program): New host class.
878 (c_compile_program): New typedef.
879 (c_compute_porgram): Use c_compile_program.
881 2018-08-10 Keith Seitz <keiths@redhat.com>
883 * compile/compile-internal.h (compile_instance::~compile_instance):
884 Remove calls to htab_delete.
885 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
886 * compile.c (compile_instance::compile_instance): Initialize
887 htab unique pointers.
888 (compile_instance::get_cached_type, compile_instance::insert_type)
889 (compile_instance::error_symbol_once): Update for unique_ptr.
891 2018-08-10 Keith Seitz <keiths@redhat.com>
893 * compile/compile-c-symbols.c (struct symbol_error)
894 (hash_symbol_error, eq_symbol_error, del_symbol_error)
895 (compile_instance::insert_symbol_error)
896 (compile_instance::error_symbol_once): Move to ...
897 * compile/compile.c: ... here.
899 2018-08-10 Keith Seitz <keiths@redhat.com>
901 * compile/compile-c-support.c (c_get_compile_context): Use `new'
902 instead of `new_compile_instance'.
903 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
905 If the symbol error map is not initialized, create it.
906 (generate_c_for_for_one_symbol): Do not check/initialize
907 the symbol error map.
908 * compile/compile-c-types.c (compile_c_instance): Make a class.
910 (compile_instance::compile_instance): Initialize the type cache.
911 (get_cached_type): New function.
912 (insert_type): Update description.
913 (compile_c_instance::m_default_cflags): Define.
914 (convert_type): Update description. Use get_cached_type.
915 (delete_instance): Moved to destructor.
916 (new_compile_instance): Moved to constructor.
917 * compile/compile-c.h (compile_c_instance): Make class inheriting
918 from compile_instance.
919 <base>: Remove field.
920 <type_map, symbol_err_map>: Move to base class.
921 <c_plugin>: Rename to `m_plugin' and remove pointer type.
922 * compile/compile-internal.h (compile_instance): Make class.
923 <type_map_t, symbol_err_map_t>: Define.
924 <fe>: Rename to `m_gcc_fe'.
925 <scope, block, gcc_target_options>: Add `m_' prefix.
926 <m_type_map, m_symbol_err_map>: New fields, moved from
929 (convert_type, new_compile_instance): Remove.
930 * compile/compile.c (cleanup_compile_instance): Remove.
931 (compile_to_object): Use unique_ptr to eliminate cleanups.
932 (compile_instance::set_print_callback, compile_instance::version)
933 (compile_instance::set_verbose)
934 (compile_instance::set_driver_filename)
935 (compile_instance::set_triplet_regexp)
936 (compile_instance::set_arguments)
937 (compile_instance::set_source_file)
938 (compile_instance::compile): Define.
940 2018-08-10 Keith Seitz <keiths@redhat.com>
942 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
943 * compile/compile-c-types.c: Define GCC_METHODN macros and include
944 gcc-c-fe.def to define C plugin.
945 (delete_instance): Delete `c_plugin'.
946 (new_compile_instance): Initialize `c_plugin'.
947 * compile/compile-c.h: Include gcc_c_plugin.h.
948 (struct compile_c_instance) <c_plugin>: New member.
949 * gcc-c-plugin.h: New file.
950 Update all callers with API change.
952 2018-08-10 Keith Seitz <keiths@redhat.com>
954 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
955 (HFILES_NO_SRCDIR): ... to here.
956 Add compile-internal.h and compile-c.h.
957 * compile/compile-c-support.c: Include compile-c.h.
958 * compile/compile-c-symbols.c: Include compile-c.h.
959 (generate_c_for_variable_locations): Update comment.
960 * compile/compile-c-types.c: Include compile-c.h.
961 * compile/compile-c.h: New file -- moved C language declarations
962 from other files here.
963 * compile/compile-internal.h: Do not include hashtab.h or
965 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
966 (gcc_convert_symbol, gcc_symbol_address)
967 (generate_c_for_variable_locations, c_get_mode_for_size)
968 (c_get_range_decl_name): Definitions moved to compile-c.h.
969 * compile/compile-loc2c.c: Include compile-c.h.
971 2018-08-10 Keith Seitz <keiths@redhat.com>
973 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
974 (c_symbol_substitution_name): ... this.
977 2018-08-10 Keith Seitz <keiths@redhat.com>
979 * compile/compile-c-support.c (c_compute_program): Use
980 unique_xmalloc_ptr to eliminate cleanup.
981 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
982 Return a unique_xmalloc_ptr and eliminate cleanup.
983 * compile/compile-internal.h (generate_c_for_variable_locations):
984 Return unique_xmalloc_ptr and update description.
986 2018-08-10 Alan Hayward <alan.hayward@arm.com>
988 * corelow.c (core_target::get_core_register_section): Rename
989 min_size to section_min_size.
991 2018-08-09 Jim Wilson <jimw@sifive.com>
993 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
994 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
995 * NEWS: Mention new GNU/Linux RISC-V target.
996 * configure.host: Add riscv*-*-linux*.
997 * configure.nat: Add riscv*.
998 * configure.tgt: Add riscv*-*-linux*.
999 * riscv-linux-nat.c: New file.
1000 * riscv-linux-tdep.c: New file.
1002 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
1004 * infrun.c (resume): Make static, add forward declaration.
1005 (proceed): Update header comment.
1006 * infrun.h (resume): Delete declaration.
1008 2018-08-09 Tom Tromey <tom@tromey.com>
1010 * riscv-tdep.h: Minor formatting fixes.
1012 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
1014 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
1015 * dwarf-index-cache.c (create_dir_and_check): Likewise.
1016 (test_mkdir_recursive): Likewise.
1017 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
1019 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
1021 * valarith.c (value_subscripted_rvalue): If an array is not in
1022 memory, and we don't know the upper bound, then we can't know that
1023 the requested element exists or not.
1025 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
1027 * target.c (str_comma_list_concat_elem): Fix typo in comment.
1028 (target_options_to_string): Add comment.
1030 2018-08-08 Tom Tromey <tom@tromey.com>
1032 * unittests/scoped_mmap-selftests.c: Check result of "write".
1034 2018-08-08 Jim Wilson <jimw@sifive.com>
1036 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
1037 (decode_register_index_short): New.
1038 (decode_j_type_insn, decode_cj_type_insn): New.
1039 (decode_b_type_insn, decode_cb_type_insn): New.
1040 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
1041 local xlen. Check xlen when decoding ambiguous compressed insns. In
1042 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
1043 is_c_sw_insn instead of is_sw_insn.
1044 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
1045 (riscv_software_single_step): New.
1046 * riscv-tdep.h (riscv_software_single_step): Declare.
1048 * riscv-tdep.c (riscv_isa_xlen): Drop static.
1049 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
1051 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
1054 * target.c (dispose_inferior): Don't dispose of inferiors that are
1057 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
1059 * remote.c (remote_target::download_tracepoint): Change char* to
1062 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
1064 * target.h (target_options_to_string): Return an std::string.
1065 * target.c (str_comma_list_concat_elem): Return void, use
1067 (do_option): Likewise.
1068 (target_options_to_string): Return an std::string.
1069 * linux-nat.c (linux_nat_target::wait): Adjust.
1070 * target-debug.h (target_debug_print_options): Adjust.
1072 2018-08-07 Tom Tromey <tom@tromey.com>
1074 * Makefile.in (CPPFLAGS): New variable.
1075 (INTERNAL_CPPFLAGS): Use it.
1077 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
1079 * NEWS: Mention the index cache.
1081 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
1083 * common/pathstuff.h (get_standard_cache_dir): New.
1084 * common/pathstuff.c (get_standard_cache_dir): New.
1085 * build-id.h (build_id_to_string): New.
1086 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
1087 DEBUG_STR_SUFFIX): Move to here.
1088 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
1089 DEBUG_STR_SUFFIX): Move from there.
1090 (write_psymtabs_to_index): Make non-static, add basename
1091 parameter. Write to temporary files, rename when done.
1092 (save_gdb_index_command): Adjust call to
1093 write_psymtabs_to_index.
1094 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
1096 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
1097 (get_gdb_index_contents_from_cache): New.
1098 (get_gdb_index_contents_from_cache_dwz): New.
1099 (dwarf2_initialize_objfile): Read index from cache.
1100 (dwarf2_build_psymtabs): Save to index.
1101 * dwarf-index-cache.h: New file.
1102 * dwarf-index-cache.c: New file.
1103 * dwarf-index-write.h: New file.
1105 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
1107 * gnulib/aclocal.m4: Re-generate.
1108 * gnulib/config.in: Re-generate.
1109 * gnulib/configure: Re-generate.
1110 * gnulib/import/Makefile.am: Re-generate.
1111 * gnulib/import/Makefile.in: Re-generate.
1112 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
1113 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
1114 * gnulib/import/m4/mkdir.m4: New file.
1115 * gnulib/import/mkdir.c: New file.
1116 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
1119 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
1121 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
1122 * common/scoped_mmap.c: New file.
1123 * common/scoped_mmap.h (destroy): New method.
1124 (~scoped_mmap, reset): Use destroy.
1125 (scoped_mmap): New move constructor.
1126 (mmap_file): New declaration.
1127 * unittests/scoped_mmap-selftests.c (test_normal,
1128 test_invalid_filename, run_tests): New functions.
1129 (_initialize_scoped_mmap_selftests): Register selftest.
1131 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
1133 * dwarf2read.c (read_gdb_index_from_section): Rename to...
1134 (read_gdb_index_from_buffer): ... this. Remove section
1135 parameter, add buffer parameter.
1136 (get_gdb_index_contents_ftype,
1137 get_gdb_index_contents_dwz_ftype): New typedefs.
1138 (dwarf2_read_gdb_index): Add callback parameters to get the
1140 (get_gdb_index_contents_from_section): New.
1141 (dwarf2_initialize_objfile): Update call to
1142 dwarf2_read_gdb_index.
1144 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
1146 * common/filestuff.h (gdb_fopen_cloexec): New overload.
1147 (gdb_open_cloexec): Likewise.
1148 * nat/linux-osdata.c (command_from_pid): Use string_printf.
1149 (commandline_from_pid): Likewise.
1150 (linux_xfer_osdata_threads): Likewise.
1151 (linux_xfer_osdata_fds): Likewise.
1152 * ada-lang.c (is_package_name): Likewise.
1153 * auxv.c (procfs_xfer_auxv): Likewise.
1154 * breakpoint.c (print_one_breakpoint_location): Use
1156 (print_one_catch_solib): Use string_printf.
1157 * coff-pe-read.c (add_pe_exported_sym): Likewise.
1158 (add_pe_forwarded_sym): Likewise.
1159 * dwarf2read.c (create_type_unit_group): Likewise.
1160 (build_error_marker_type): Likewise.
1161 * infcall.c (get_function_name): Likewise.
1162 * valprint.c (print_converted_chars_to_obstack): Likewise.
1163 * xtensa-tdep.c (xtensa_register_type): Likewise.
1165 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
1167 * remote.c (remote_target::download_tracepoint): Fix format
1170 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1172 * tracefile.c: Include common/byte-vector.h.
1173 (trace_save): Change type of buf to gdb::byte_vector. Initialize
1174 with trace_regblock_size if needed. Update uses of buf.
1176 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1178 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
1179 std::vector<unsigned char>.
1180 * tracepoint.c (collection_list::collection_list): Remove
1181 m_regs_mask initializer from initializer list. Resize
1182 m_regs_mask using the largest remote register number.
1183 (collection_list::add_remote_register): Remove size check on
1184 m_regs_mask. Use at to access element.
1185 (collection_list::stringify): Change type of temp_buf to
1186 gdb::char_vector. Update uses of temp_buf. Resize if needed to
1187 stringify the register mask. Use pack_hex_byte for the register
1190 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1192 * tracepoint.h (class collection_list) <add_register>: Remove.
1193 <add_remote_register, add_ax_registers, add_local_register>:
1195 <add_memrange>: Add scope parameter.
1196 * tracepoint.c (encode_actions_1): Likewise.
1197 (collection_list::add_register): Rename to ...
1198 (collection_list::add_remote_register): ... this. Update
1200 (collection_list::add_ax_registers, add_local_register): New
1202 (collection_list::add_memrange): Add scope parameter. Call
1203 add_local_register instead of add_register.
1204 (finalize_tracepoint_aexpr): New function.
1205 (collection_list::collect_symbol): Update calls to add_memrange.
1206 Call add_local_register instead of add_register. Call
1207 add_ax_registers. Call finalize_tracepoint_aexpr.
1208 (encode_actions_1): Get remote regnos for $reg action. Call
1209 add_remote_register, add_ax_registers, and add_local_register.
1210 Update call to add_memrange. Call finalize_tracepoint_aexpr.
1211 (validate_actionline): Call finalize_tracepoint_aexpr.
1213 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1215 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
1216 Replace array buf with gdb::char_vector buf, of size
1217 get_remote_packet_size (). Replace references to buf and
1218 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
1219 and xsnprintf with snprintf. Raise errors if the buffer is too
1222 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1224 * remote.c (remote_target::download_tracepoint): Fix the has_more
1225 predicate in the QTDP action list iteration.
1227 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1229 * remote.c (remote_target::download_tracepoint): Fix indentation
1232 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1234 * proc-api.c (_initialize_proc_api): Remove c, unused.
1235 * procfs.c (procfs_init_inferior): Remove signals, unused.
1236 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
1239 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
1240 Andrew Burgess <andrew.burgess@embecosm.com>
1242 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
1243 'W_STOPCODE (0)' as this could be ambiguous.
1245 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
1247 * ser-tcp.c (net_open): Fix thinko when deciding whether to
1248 disable TCP's Nagle algorithm (use "ai_protocol" instead of
1251 2018-08-02 Tom Tromey <tom@tromey.com>
1254 * dwarf2read.c (read_func_scope): Set symtab on template parameter
1256 (process_structure_scope): Likewise.
1258 2018-08-02 Xavier Roirand <roirand@adacore.com>
1261 * darwin-nat.c (darwin_kill_inferior): Fix handling of
1264 2018-08-02 Tom Tromey <tom@tromey.com>
1266 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
1267 (darwin_suspend_inferior, darwin_resume_inferior)
1268 (darwin_decode_notify_message, darwin_resume_inferior_threads)
1269 (darwin_check_new_threads): Check result of get_darwin_inferior.
1271 2018-07-31 Joel Brobecker <brobecker@adacore.com>
1275 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
1277 * varobj.c (varobj_get_path_expr_parent): Report an error if
1278 parent is a dynamic varobj.
1280 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
1282 * gnulib/aclocal.m4: Re-generate.
1283 * gnulib/config.in: Re-generate.
1284 * gnulib/configure: Re-generate.
1285 * gnulib/import/Makefile.in: Re-generate.
1286 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
1287 * gnulib/import/m4/onceonly.m4: Re-generate.
1289 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
1291 * target-descriptions.c (struct xml_test_tdesc): New.
1292 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
1293 (record_xml_tdesc): Update.
1294 (maintenance_check_xml_descriptions): Update.
1295 * target-descriptions.h (record_xml_tdesc): Update comment.
1297 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
1299 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
1300 checking array bounds are defined.
1302 2018-07-30 Tom Tromey <tom@tromey.com>
1304 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
1305 irreflexivity violation.
1307 2018-07-30 Tom Tromey <tom@tromey.com>
1309 * cli/cli-decode.c (lookup_cmd): Remove lint code.
1310 * value.c (unpack_long): Remove lint code.
1311 * valops.c (value_ind): Remove lint code.
1312 * valarith.c (value_x_binop, value_x_unop, value_equal)
1313 (value_pos): Remove lint code.
1315 2018-07-28 Tom de Vries <tdevries@suse.de>
1317 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
1318 with undefined upper bound as <optimized out>.
1320 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
1322 * gcore.in: Rename variable "name" to "prefix". Expand
1325 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
1327 * windows-nat.c (windows_nat_target::create_inferior): Update to
1328 call close() in global namespace.
1330 2018-07-26 Tom Tromey <tom@tromey.com>
1332 * dwarf-index-write.c (add_address_entry): Don't add objfile
1334 * dbxread.c (find_stab_function): Rename from
1335 find_stab_function_addr. Return a bound_minimal_symbol.
1336 (read_dbx_symtab): Use raw_text_low, raw_text_high.
1337 Don't add objfile offsets.
1338 (end_psymtab): Use raw_text_low, raw_text_high,
1339 MSYMBOL_VALUE_RAW_ADDRESS.
1340 (read_ofile_symtab): Update.
1341 (process_one_symbol): Update.
1342 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
1344 (dw2_relocate): Remove.
1345 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
1347 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
1349 (process_psymtab_comp_unit_reader, add_partial_symbol)
1350 (add_partial_subprogram, dwarf2_ranges_read): Update.
1351 (load_partial_dies): Update.
1352 (add_address_entry): Don't add objfile offsets.
1353 (dwarf2_build_include_psymtabs): Update.
1354 (create_addrmap_from_aranges): Don't add objfile offsets.
1355 (dw2_find_pc_sect_compunit_symtab): Update.
1356 * mdebugread.c (parse_symbol): Don't add objfile offsets.
1357 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
1359 (parse_partial_symbols): Don't add objfile offsets. Use
1360 raw_text_low, raw_text_high. Update.
1361 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
1362 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
1363 or call 'relocate' quick function. Clear psymbol_map.
1364 * psympriv.h (struct partial_symbol) <address>: Add section
1366 <set_unrelocated_address>: Rename from set_address.
1367 <raw_text_low, raw_text_high>: New methods.
1368 <text_low, text_high>: Add objfile parameter.
1369 (add_psymbol_to_bcache): Add 'section' parameter. Call
1370 set_unrelocated_address.
1371 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
1372 (find_pc_psymbol): Update.
1373 (fixup_psymbol_section, relocate_psymtabs): Remove.
1374 (dump_psymtab, psym_functions): Update.
1375 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
1377 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
1378 (start_psymtab_common): Update.
1379 * symfile-debug.c (debug_qf_relocate): Remove.
1380 (debug_sym_quick_functions): Update.
1381 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
1382 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
1385 2018-07-26 Tom Tromey <tromey@redhat.com>
1387 * dbxread.c (end_psymtab): Use text_high_valid and
1389 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
1390 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
1391 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
1393 <text_low_valid, text_high_valid>: New fields.
1394 <set_text_low, set_text_high>: Update.
1395 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
1397 2018-07-26 Tom Tromey <tom@tromey.com>
1399 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
1401 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
1402 textlow and texthigh fields.
1403 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
1405 * mdebugread.c (parse_lines, parse_partial_symbols)
1406 (psymtab_to_symtab_1): Update.
1407 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
1408 Rename fields. Update comment. Now private.
1409 <text_low, text_high, set_text_low, set_text_high>: New methods.
1410 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
1411 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
1412 (start_psymtab_common, maintenance_info_psymtabs)
1413 (maintenance_check_psymtabs): Update.
1414 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
1416 (scan_xcoff_symtab): Update.
1418 2018-07-26 Tom Tromey <tromey@redhat.com>
1420 * psympriv.h (struct partial_symbol) <unrelocated_address,
1421 address, set_address>: New methods.
1422 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
1423 (fixup_psymbol_section, relocate_psymtabs): Update.
1424 (print_partial_symbols): Add 'objfile' parameter. Update.
1425 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
1428 2018-07-26 Tom Tromey <tom@tromey.com>
1430 * dwarf-index-write.c (write_psymbols, debug_names::insert)
1431 (debug_names::write_psymbols): Update.
1432 * psympriv.h (struct partial_symbol): Derive from
1433 general_symbol_info.
1434 <obj_section>: New method.
1435 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
1436 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
1437 (find_pc_sect_psymbol, fixup_psymbol_section)
1438 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
1439 (print_partial_symbols, recursively_search_psymtabs)
1440 (compare_psymbols, psymbol_hash, psymbol_compare)
1441 (add_psymbol_to_bcache, maintenance_check_psymtabs)
1442 (psymbol_name_matches, psym_fill_psymbol_map): Update.
1444 2018-07-26 Tom Tromey <tromey@redhat.com>
1446 * dbxread.c (end_psymtab): Remove dead code.
1448 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
1450 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
1451 DWARF unwinders are disabled.
1452 * dwarf2-frame.c: Add dwarf2read.h include.
1453 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
1455 (dwarf2_frame_unwinders_enabled_p): Define.
1456 (show_dwarf_unwinders_enabled_p): New function.
1457 (_initialize_dwarf2_frame): Register switch to control DWARF
1459 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
1460 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
1461 (show_dwarf_cmdlist): Remove static keyword.
1462 * dwarf2read.h (set_dwarf_cmdlist): Declare.
1463 (show_dwarf_cmdlist): Declare.
1464 * NEWS: Document new feature.
1466 2018-07-26 Tom de Vries <tdevries@suse.de>
1468 PR breakpoints/23366
1469 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
1471 2018-07-26 Tom de Vries <tdevries@suse.de>
1473 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
1474 DW_AT_count can't be translated to a dynamic prop.
1476 2018-07-25 Tom de Vries <tdevries@suse.de>
1478 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
1481 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
1483 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
1485 2018-07-25 Joel Brobecker <brobecker@adacore.com>
1487 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
1489 2018-07-24 Keith Seitz <keiths@redhat.comt
1492 * dwarf2read.c (dw2_add_symbol_to_list): New function.
1493 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
1494 instead of add_symbol_to_list.
1495 (read_file_scope): Call prepare_one_comp_unit before reading
1498 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
1500 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
1502 2018-07-24 Tom Tromey <tom@tromey.com>
1504 * utils.c (malloc, realloc, free): Don't declare.
1505 * configure, config.in: Rebuild.
1506 * configure.ac: Don't check for declarations of free, malloc, or
1509 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1511 * aarch64-linux-nat.c
1512 (aarch64_linux_nat_target::stopped_data_address): Remove unused
1514 * arm-linux-nat.c (fetch_regs): Likewise.
1515 (store_regs): Likewise.
1516 (fetch_vfp_regs): Likewise.
1517 (store_vfp_regs): Likewise.
1518 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
1519 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
1520 (arm_linux_nat_target::insert_watchpoint): Likewise.
1521 (arm_linux_nat_target::remove_watchpoint): Likewise.
1522 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
1524 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
1526 * ppc-linux-nat.c (fetch_register): Likewise.
1527 (fetch_all_gp_regs): Likewise.
1528 (fetch_ppc_registers): Likewise.
1529 (store_all_gp_regs): Likewise.
1530 (store_ppc_registers): Likewise.
1531 (hwdebug_insert_point): Likewise.
1532 (can_use_watchpoint_cond_accel): Likewise.
1533 * remote-sim.c (gdb_os_write_stdout): Likewise.
1535 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1536 Tom Tromey <tom@tromey.com>
1538 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
1540 * configure: Rebuild.
1542 2018-07-22 Tom Tromey <tom@tromey.com>
1544 * regformats/regdat.sh: Define xmltarget_${name} inside
1545 #ifndef IN_PROCESS_AGENT.
1547 2018-07-22 Tom Tromey <tom@tromey.com>
1549 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
1551 2018-07-22 Tom Tromey <tom@tromey.com>
1553 * symfile.c (reread_symbols): Notify iter, not objfile.
1555 2018-07-22 Tom Tromey <tom@tromey.com>
1557 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
1559 (ravenscar_thread_target::prepare_to_store): Likewise.
1561 2018-07-22 Tom Tromey <tom@tromey.com>
1563 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
1564 unused variable. Call value_fetch_lazy when needed.
1565 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
1566 Remove unused variable. Call value_fetch_lazy when needed.
1568 2018-07-22 Tom Tromey <tom@tromey.com>
1570 * m32c-tdep.c (mark_dma): Return void.
1571 (make_regs): Remove unused declarations.
1573 2018-07-22 Tom Tromey <tom@tromey.com>
1575 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
1576 cmdscm_get_valid_command_smob_arg_unsafe for effect.
1577 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
1578 bkscm_get_valid_block_smob_arg_unsafe for effect.
1580 2018-07-22 Tom Tromey <tom@tromey.com>
1582 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
1585 2018-07-22 Tom Tromey <tom@tromey.com>
1587 * windows-nat.c (saved_context): Conditionally define.
1588 * remote.c (remote_target::remote_btrace_maybe_reopen):
1589 Conditionally declare "warned".
1590 * inflow.c (sigquit_ours): Conditionally define.
1591 (new_tty): Move "tty" declaration inside #if.
1592 * guile/guile.c (guile_datadir): Conditionally define.
1593 * charset.c (set_be_le_names): Move some declarations inside #if.
1594 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
1596 (parse_xml_btrace_conf): Likewise.
1598 2018-07-22 Tom Tromey <tom@tromey.com>
1600 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
1602 2018-07-22 Tom Tromey <tom@tromey.com>
1604 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
1605 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
1606 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
1607 * buildsym-legacy.c (get_macro_table): Remove unused variable.
1608 * stack.c (frame_apply_level_command): Remove unused variable.
1609 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
1610 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
1611 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
1613 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
1614 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
1615 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
1617 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
1618 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
1620 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
1621 Remove unused variable.
1622 * cli/cli-script.c (recurse_read_control_structure): Remove unused
1624 * common/tdesc.c (print_xml_feature::visit): Remove unused
1626 * compile/compile-object-load.c (store_regs): Remove unused
1628 * complaints.c (clear_complaints): Remove unused variable.
1629 * corelow.c (core_target_open): Remove unused variable.
1630 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
1632 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
1634 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
1636 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
1638 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
1640 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
1642 * ia64-tdep.c (examine_prologue): Remove unused variable.
1643 * infcall.c (run_inferior_call): Remove unused variable.
1644 * inferior.c (exit_inferior): Remove unused variable.
1645 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
1646 * linespec.c (decode_line_2): Remove unused variable.
1647 * linux-nat.c (super_close): Remove.
1648 * linux-tdep.c (linux_info_proc): Remove unused variable.
1649 * mi/mi-main.c (mi_execute_command): Remove unused variable.
1650 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
1651 Remove unused variable.
1652 * parse.c (find_minsym_type_and_address): Remove unused variable.
1653 * printcmd.c (info_symbol_command, printf_floating): Remove unused
1655 * python/py-breakpoint.c (bppy_set_commands): Remove unused
1657 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
1659 * record-btrace.c (record_btrace_target::store_registers): Remove
1661 (cmd_show_record_btrace_cpu): Remove unused variable.
1662 * riscv-tdep.c (riscv_register_reggroup_p)
1663 (riscv_push_dummy_call, riscv_return_value): Remove unused
1665 * rust-exp.y (literal): Remove unused variable.
1666 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
1668 <STRUCTOP_ANONYMOUS>: Likewise.
1669 * s390-linux-tdep.c (s390_linux_init_abi_31)
1670 (s390_linux_init_abi_64): Remove unused variable.
1671 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
1672 (file_select_thread, net_windows_open, _initialize_ser_windows):
1673 Remove unused variables.
1674 * symtab.c (find_pc_sect_line): Remove unused variable.
1675 * target-memory.c (compute_garbled_blocks): Remove unused
1677 (target_write_memory_blocks): Remove unused variable.
1678 * target.c (target_stack::unpush): Remove unused variables.
1679 * tracepoint.c (start_tracing, all_tracepoint_actions)
1680 (merge_uploaded_trace_state_variables)
1681 (print_one_static_tracepoint_marker): Remove unused variable.
1682 * unittests/basic_string_view/element_access/char/1.cc (test01):
1683 Remove unused variable.
1684 * windows-nat.c (windows_continue, windows_add_all_dlls)
1685 (do_initial_windows_stuff, windows_nat_target::create_inferior):
1686 Remove unused variables.
1688 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
1690 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
1691 attr_profile in HAVE_ELF.
1692 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
1695 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
1697 * frame.c (frame_register_unwind): Change parameter name.
1698 (frame_unwind_register): Likewise.
1699 (frame_unwind_register_value): Likewise.
1700 (frame_unwind_register_signed): Likewise.
1701 (frame_unwind_register_unsigned): Likewise.
1702 * frame.h (frame_register_unwind): Likewise.
1703 (frame_unwind_register): Likewise.
1704 (frame_unwind_register_value): Likewise.
1705 (frame_unwind_register_signed): Likewise.
1706 (frame_unwind_register_unsigned): Likewise.
1707 (frame_unwind_arch): Likewise.
1709 2018-07-20 Maciej W. Rozycki <macro@mips.com>
1711 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
1714 2018-07-20 Maciej W. Rozycki <macro@mips.com>
1716 * mips-linux-nat.c (mips_linux_nat_target::read_description):
1717 Call `get_ptrace_pid' rather than extracting the ptrace PID by
1720 2018-07-20 Keith Seitz <keiths@redhat.com>
1722 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
1723 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
1724 m_compunit_symtab, m_language>: Add "m_" prefix.
1726 * buildsym.c: Update all uses.
1728 2018-07-20 Tom Tromey <tom@tromey.com>
1730 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
1731 * buildsym.h (record_line_ftype): Remove typedef.
1733 2018-07-20 Tom Tromey <tom@tromey.com>
1735 * buildsym-legacy.h (augment_type_symtab): Don't declare.
1736 (end_expandable_symtab): Likewise.
1737 (end_symtab_get_static_block): Likewise.
1738 (end_symtab_from_static_block): Likewise.
1739 * buildsym-legacy.c (augment_type_symtab): Remove.
1740 (end_expandable_symtab): Remove.
1741 (end_symtab_get_static_block): Remove.
1742 (end_symtab_from_static_block): Remove.
1744 2018-07-20 Tom Tromey <tom@tromey.com>
1746 * dwarf2read.c: Include buildsym.h.
1747 (struct dwarf2_cu) <builder>: New method.
1748 (fixup_go_packaging): Update.
1749 (process_full_comp_unit, process_full_type_unit): Update. Don't
1750 use scoped_free_pendings.
1751 (using_directives): Add "cu" parameter, remove "language".
1752 (read_import_statement, setup_type_unit_groups, )
1753 (read_func_scope, read_lexical_block_scope)
1754 (dwarf2_record_block_ranges, read_namespace): Update.
1755 (lnp_state_machine::lnp_state_machine): Add cu parameter.
1756 (lnp_state_machine::handle_end_sequence): Update.
1757 (class lnp_state_machine) <m_cu>: New member.
1758 <m_record_line_callback>: Remove.
1759 <m_currently_recording_lines>: New member.
1760 (lnp_state_machine::handle_set_file): Update.
1761 (noop_record_line): Remove.
1762 (dwarf_record_line_p): Add cu parameter.
1763 (dwarf_record_line_1, dwarf_finish_line): Likewise.
1764 (lnp_state_machine::record_line)
1765 (lnp_state_machine::lnp_state_machine)
1766 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
1767 (dwarf_decode_lines): Update.
1768 (dwarf2_start_subfile): Add cu parameter.
1769 (dwarf2_start_symtab, new_symbol): Update.
1770 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
1771 Remove dwarf2_per_objfile parameter.
1772 (dwarf_decode_macros): Update.
1774 2018-07-20 Tom Tromey <tom@tromey.com>
1776 * stabsread.c (define_symbol): Update.
1777 * buildsym-legacy.h (get_buildsym_compunit): Declare.
1778 * dwarf2read.c (new_symbol): Update.
1779 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
1780 * cp-namespace.c: Include buildsym.h.
1781 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
1782 * buildsym-legacy.c (get_buildsym_compunit): New function.
1784 2018-07-20 Tom Tromey <tom@tromey.com>
1786 * xcoffread.c: Include buildsym-legacy.h.
1787 * windows-nat.c: Include buildsym-legacy.h.
1788 * stabsread.c: Include buildsym-legacy.h.
1789 * mdebugread.c: Include buildsym-legacy.h.
1790 * buildsym-legacy.h: New file.
1791 * buildsym-legacy.c: New file, from buildsym.c.
1792 * go32-nat.c: Include buildsym-legacy.h.
1793 * dwarf2read.c: Include buildsym-legacy.h.
1794 * dbxread.c: Include buildsym-legacy.h.
1795 * cp-namespace.c: Include buildsym-legacy.h.
1796 * coffread.c: Include buildsym-legacy.h.
1797 * buildsym.h: Move some contents to buildsym-legacy.h.
1798 * buildsym.c: Include buildsym-legacy.h. Move many functions to
1800 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
1802 2018-07-20 Tom Tromey <tom@tromey.com>
1804 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
1805 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
1806 (buildsym_compunit::buildsym_compunit)
1807 (buildsym_compunit::~buildsym_compunit)
1808 (buildsym_compunit::get_macro_table): Define.
1810 2018-07-20 Tom Tromey <tom@tromey.com>
1812 * buildsym.c (reset_symtab_globals): Remove.
1813 (buildsym_compunit::end_symtab_from_static_block): Update.
1814 (buildsym_compunit::augment_type_symtab): Update.
1815 (end_symtab_from_static_block): Call free_buildsym_compunit.
1816 (augment_type_symtab, end_symtab, end_expandable_symtab):
1819 2018-07-20 Tom Tromey <tom@tromey.com>
1821 * arch-utils.c: Do not include buildsym.h.
1822 * mipsread.c: Do not include buildsym.h.
1823 * machoread.c: Do not include buildsym.h.
1824 * elfread.c: Do not include buildsym.h.
1826 2018-07-20 Tom Tromey <tom@tromey.com>
1828 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
1830 (buildsym_compunit): Add new constructor.
1831 (struct buildsym_compunit) <get_last_source_file, finish_block,
1832 record_block_range, start_subfile, patch_subfile_names,
1833 push_subfile, pop_subfile, record_line, get_compunit_symtab,
1834 set_last_source_start_addr, get_last_source_start_addr,
1835 get_local_using_directives, set_local_using_directives,
1836 get_global_using_directives, outermost_context_p,
1837 get_current_context_stack, get_context_stack_depth,
1838 get_current_subfile, get_local_symbols, get_file_symbols,
1839 get_global_symbols, record_debugformat, record_producer,
1840 push_context, pop_context, end_symtab_get_static_block,
1841 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
1843 <record_pending_block, finish_block_internal, make_blockvector,
1844 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
1848 2018-05-22 Tom Tromey <tom@tromey.com>
1850 * buildsym.c (record_pending_block): Move earlier. Remove objfile
1852 (finish_block_internal): Update.
1854 2018-07-20 Tom Tromey <tom@tromey.com>
1856 * buildsym.c (record_pending_block): Move earlier. Remove objfile
1858 (finish_block_internal): Update.
1860 2018-07-20 Tom Tromey <tom@tromey.com>
1862 * buildsym.h (EXTERN): Don't define or undef.
1863 * buildsym.c (EXTERN): Don't define.
1865 2018-07-20 Tom Tromey <tom@tromey.com>
1867 * buildsym.c: Remove TODO comment.
1869 2018-07-20 Tom Tromey <tom@tromey.com>
1871 * coffread.c (coff_symtab_read): Update.
1872 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
1873 (xcoff_new_init): Update.
1874 * mipsread.c (mipscoff_new_init): Update.
1875 * mdebugread.c (mdebug_build_psymtabs): Update.
1876 * elfread.c (elf_new_init): Update.
1877 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
1879 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
1880 (coffstab_build_psymtabs, elfstab_build_psymtabs)
1881 (stabsect_build_psymtabs): Update.
1882 * buildsym.h (buildsym_init): Don't declare.
1883 * buildsym.c: Update comment.
1884 (prepare_for_building): Remove.
1885 (start_symtab, restart_symtab): Update.
1886 (reset_symtab_globals): Update comment.
1887 (buildsym_init): Remove.
1889 2018-07-20 Tom Tromey <tom@tromey.com>
1891 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
1892 * stabsread.c (patch_block_stabs, define_symbol, read_type)
1893 (read_enum_type, common_block_start, common_block_end)
1894 (cleanup_undefined_types_1, finish_global_stabs): Update.
1895 * mdebugread.c (psymtab_to_symtab_1): Update.
1896 * dwarf2read.c (fixup_go_packaging, read_func_scope)
1897 (read_lexical_block_scope, new_symbol): Update.
1898 * dbxread.c (process_one_symbol): Update.
1899 * coffread.c (coff_symtab_read, process_coff_symbol)
1900 (coff_read_enum_type): Update.
1901 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
1903 (get_local_symbols, get_file_symbols, get_global_symbols): New
1905 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
1907 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
1908 (~scoped_free_pendings): Update.
1909 (finish_block, prepare_for_building, reset_symtab_globals)
1910 (end_symtab_get_static_block, end_symtab_with_blockvector)
1911 (augment_type_symtab, push_context): Update.
1912 (get_local_symbols, get_file_symbols, get_global_symbols): New
1914 (buildsym_init): Update.
1916 2018-07-20 Tom Tromey <tom@tromey.com>
1918 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
1919 (process_full_type_unit): Likewise.
1920 (dwarf2_start_symtab): Set list_in_scope.
1922 2018-07-20 Tom Tromey <tom@tromey.com>
1924 * dwarf2read.c (process_psymtab_comp_unit_reader)
1925 (build_type_psymtabs_reader): Do not set list_in_scope.
1927 2018-07-20 Tom Tromey <tom@tromey.com>
1929 * buildsym.c (free_pendings): Remove.
1930 (add_symbol_to_list, scoped_free_pendings)
1931 (finish_block_internal, buildsym_init): Update.
1933 2018-07-20 Tom Tromey <tom@tromey.com>
1935 * xcoffread.c (read_xcoff_symtab): Update.
1936 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
1938 * dbxread.c (process_one_symbol): Update.
1939 * coffread.c (coff_symtab_read): Update.
1940 * buildsym.h (finish_block): Update.
1941 * buildsym.c (finish_block): Remove "listhead" argument.
1942 (end_symtab_get_static_block): Update.
1944 2018-07-20 Tom Tromey <tom@tromey.com>
1946 * buildsym.h (class scoped_free_pendings): Remove constructor.
1947 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
1949 <m_pending_block_obstack, m_pending_blocks>: New members.
1950 (pending_block_obstack, pending_blocks): Remove.
1951 (scoped_free_pendings::scoped_free_pendings): Default.
1952 (~scoped_free_pendings): Update.
1953 (free_pending_blocks): Remove.
1954 (finish_block_internal, record_pending_block, make_blockvector)
1955 (end_symtab_get_static_block, augment_type_symtab, push_context)
1956 (buildsym_init): Update.
1958 2018-07-20 Tom Tromey <tom@tromey.com>
1960 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
1961 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
1963 (pending_addrmap, pending_addrmap_obstack)
1964 (pending_addrmap_interesting): Remove.
1965 (scoped_free_pendings, record_block_range, make_blockvector)
1966 (prepare_for_building, reset_symtab_globals, buildsym_init):
1969 2018-07-20 Tom Tromey <tom@tromey.com>
1971 * xcoffread.c (process_linenos): Update.
1972 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
1973 * mdebugread.c (psymtab_to_symtab_1): Update.
1974 * dwarf2read.c (setup_type_unit_groups)
1975 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
1976 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
1977 * dbxread.c (process_one_symbol): Update.
1978 * coffread.c (coff_symtab_read, enter_linenos)
1979 (process_coff_symbol): Update.
1980 * buildsym.h (current_subfile): Don't declare.
1981 (get_current_subfile): Declare.
1982 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
1984 (start_subfile, free_buildsym_compunit, push_subfile)
1985 (prepare_for_building, start_symtab): Update.
1986 (get_current_subfile): New function.
1988 2018-07-20 Tom Tromey <tom@tromey.com>
1990 * coffread.c (coff_symtab_read): Update.
1991 * xcoffread.c (read_xcoff_symtab): Update.
1992 * dwarf2read.c (new_symbol): Update.
1993 (read_func_scope, read_lexical_block_scope): Update.
1994 * dbxread.c (process_one_symbol): Update.
1995 * buildsym.h (context_stack, context_stack_depth): Don't declare.
1996 (outermost_context_p): Remove macro.
1997 (outermost_context_p, get_current_context_stack)
1998 (get_context_stack_depth): Declare.
1999 (pop_context): Return struct context_stack.
2000 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
2002 (context_stack_size): Remove.
2003 (INITIAL_CONTEXT_STACK_SIZE): Remove.
2004 (prepare_for_building, end_symtab_get_static_block)
2005 (augment_type_symtab, push_context): Update.
2006 (pop_context): Return struct context_stack.
2007 (outermost_context_p, get_current_context_stack)
2008 (get_context_stack_depth): New functions.
2009 (buildsym_init): Update.
2011 2018-07-20 Tom Tromey <tom@tromey.com>
2013 * rust-exp.y: Now a pure parser. Update all rules.
2014 (%union): Move earlier.
2015 (current_parser, work_obstack): Remove globals.
2016 (rust_parser, ~rust_parser): Update.
2017 (class rust_parser) <copy_name, concat3, crate_name, super_name,
2018 lex_character, lex_number, lex_string, lex_identifier,
2019 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
2020 convert_name, convert_params_to_expression,
2021 convert_ast_to_expression, ast_basic_type, ast_operation,
2022 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
2023 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
2024 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
2025 ast_array_type, ast_slice_type, ast_reference_type,
2026 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
2027 (rust_parse): Update.
2028 (rustyyerror, rustyylex): Add parser parameter.
2029 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
2030 (rust_lex_stringish_test, rust_lex_test_sequence)
2031 (rust_lex_test_trailing_dot, rust_lex_test_completion)
2032 (rust_lex_test_push_back, rust_lex_tests): Update.
2034 2018-07-19 Pedro Alves <palves@redhat.com>
2036 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
2037 gdb::unique_xmalloc_ptr.
2038 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
2039 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
2040 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
2041 copy-initialization.
2042 * guile/scm-pretty-print.c (ppscm_print_children): Use
2043 gdb::unique_xmalloc_ptr instead of cleanups.
2044 (gdbscm_apply_val_pretty_printer): Remove cleanups.
2045 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
2046 gdb::unique_xmalloc_ptr.
2047 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
2048 Adjust to use gdb::unique_xmalloc_ptr.
2049 * guile/scm-utils.c (extract_arg): Adjust.
2050 * guile/scm-value.c (gdbscm_value_field): Adjust to use
2051 gdb::unique_xmalloc_ptr instead of a cleanup.
2053 2018-07-19 Tom Tromey <tom@tromey.com>
2055 * utils.c (do_value_free_to_mark)
2056 (make_cleanup_value_free_to_mark): Remove.
2057 * utils.h (make_cleanup_value_free_to_mark): Remove.
2059 2018-07-19 Pedro Alves <palves@redhat.com>
2061 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
2062 forwarding reference.
2064 2018-07-18 Pedro Alves <palves@redhat.com>
2066 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
2067 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
2070 2018-07-18 Pedro Alves <palves@redhat.com>
2072 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
2074 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
2076 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
2077 directly instead of a cleanup.
2078 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
2079 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
2080 (vlscm_binop_gdbthrow): New, factored out from ...
2081 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
2082 (vlscm_rich_compare): Use gdbscm_wrap.
2083 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
2084 instead of a cleanup.
2085 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
2087 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
2088 Use xfree directly instead of a cleanup.
2089 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
2090 Adjust to use gdbscm_wrap and scoped_value_mark.
2091 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
2092 (gdbscm_value_address, gdbscm_value_dereference)
2093 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
2095 (gdbscm_value_dynamic_type): Use scoped_value_mark.
2096 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
2098 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
2099 gdbscm_wrap and scoped_value_mark.
2100 (gdbscm_value_to_string): Use xfree directly instead of a
2101 cleanup. Move 'buffer' unique_ptr to TRY scope.
2102 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
2103 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
2105 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
2106 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
2108 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
2111 2018-07-18 Tom de Vries <tdevries@suse.de>
2113 * findvar.c (default_read_var_value): Also resolve dynamic type for
2114 LOC_OPTIMIZED_OUT vars.
2116 2018-07-18 Maciej W. Rozycki <macro@mips.com>
2118 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
2121 2018-07-17 Tom Tromey <tom@tromey.com>
2123 * guile/scm-param.c (pascm_set_func, pascm_show_func)
2124 (compute_enum_list, pascm_set_param_value_x)
2125 (gdbscm_parameter_value): Update.
2126 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
2127 (gdbscm_scm_to_host_string): Update.
2128 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
2130 * guile/scm-cmd.c (cmdscm_add_completion): Update.
2131 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
2132 * guile/scm-string.c (gdbscm_scm_to_string): Return
2134 (gdbscm_scm_to_host_string): Likewise.
2136 2018-07-17 Tom Tromey <tom@tromey.com>
2138 * guile/guile.c (gdbscm_eval_from_control_command): Update.
2139 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
2140 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
2141 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
2144 2018-07-17 Tom Tromey <tom@tromey.com>
2146 * guile/scm-param.c (pascm_signal_setshow_error): Update.
2147 * guile/guile-internal.h (gdbscm_exception_message_to_string):
2149 * guile/scm-cmd.c (cmdscm_function): Update.
2150 * guile/scm-pretty-print.c
2151 (ppscm_print_exception_unless_memory_error): Update.
2152 * guile/scm-exception.c (gdbscm_exception_message_to_string):
2153 Return unique_xmalloc_ptr.
2155 2018-07-17 Tom Tromey <tom@tromey.com>
2157 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
2160 2018-07-17 Jim Wilson <jimw@sifive.com>
2162 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
2163 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
2164 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
2165 unecessary braces after EF_RISCV_RVC test. Delete call to
2166 set_gdbarch_decr_pc_after_break.
2168 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
2169 RISCV_LAST_FP_REGNUM + 1.
2170 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
2172 2018-07-17 Tom Tromey <tom@tromey.com>
2174 * configure.ac: Remove --disable-gdbcli.
2175 * configure: Rebuild.
2176 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
2177 (SUBDIR_CLI_CFLAGS): Remove.
2178 (SFILES): Use SUBDIR_CLI_SRCS.
2179 (COMMON_OBS): Use SUBDIR_CLI_OBS.
2181 2018-07-17 Tom Tromey <tom@tromey.com>
2184 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
2186 2018-07-16 Jim Wilson <jimw@sifive.com>
2188 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
2190 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
2192 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
2194 (libunwind_frame_sniffer): Likewise.
2195 (libunwind_frame_prev_register): Likewise.
2196 (libunwind_sigtramp_frame_sniffer): Likewise.
2197 * ia64-tdep.c (ia64_access_reg): Likewise.
2198 (ia64_access_rse_reg): Likewise.
2199 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
2200 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
2202 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
2204 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
2206 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
2208 * remote-sim.c (gdbsim_target::close,
2209 gdbsim_target::mourn_inferior): Remove unused variables.
2211 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
2213 * ia64-tdep.c (ktab_buf): New global.
2214 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
2215 (get_kernel_table): Adjust.
2217 2018-07-16 Tom Tromey <tom@tromey.com>
2219 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
2220 * dwarf2read.c (using_directives, new_symbol): Use
2221 outermost_context_p.
2222 * dbxread.c (process_one_symbol): Use outermost_context_p.
2223 * coffread.c (coff_symtab_read): Use outermost_context_p.
2225 2018-07-16 Tom Tromey <tom@tromey.com>
2227 * dwarf2read.c (using_directives, read_func_scope)
2228 (read_lexical_block_scope): Update.
2229 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
2230 * buildsym.h (local_using_directives, global_using_directives):
2232 (get_local_using_directives, set_local_using_directives)
2233 (get_global_using_directives): Declare.
2234 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
2235 m_global_using_directives>: New members.
2236 (finish_block_internal, prepare_for_building)
2237 (reset_symtab_globals, end_symtab_get_static_block)
2238 (push_context): Update.
2239 (get_local_using_directives, set_local_using_directives)
2240 (get_global_using_directives): New functions.
2241 (buildsym_init): Update.
2243 2018-07-16 Tom Tromey <tom@tromey.com>
2245 * xcoffread.c (xcoff_initial_scan): Don't call
2246 free_pending_blocks.
2247 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
2248 * buildsym.h (class scoped_free_pendings): Add constructor.
2249 (free_pending_blocks): Don't declare.
2250 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
2251 (free_pending_blocks): Now static.
2253 2018-07-16 Tom Tromey <tom@tromey.com>
2255 * buildsym.h (push_subfile, pop_subfile): Update declarations.
2256 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
2258 (struct subfile_stack): Remove.
2259 (subfile_stack): Remove.
2260 (push_subfile, pop_subfile, buildsym_init): Update.
2262 2018-07-16 Tom Tromey <tom@tromey.com>
2264 * buildsym.c (push_subfile): Use gdb_assert.
2265 (pop_subfile): Use gdb_assert.
2267 2018-07-16 Tom Tromey <tom@tromey.com>
2269 * buildsym.h (merge_symbol_lists): Remove.
2270 * buildsym.c (merge_symbol_lists): Remove.
2272 2018-07-16 Tom Tromey <tom@tromey.com>
2274 * stabsread.c (scan_file_globals): Update comment.
2275 * stabsread.h (scan_file_globals): Move from buildsym.h.
2276 * buildsym.h (scan_file_globals): Move to stabsread.h.
2278 2018-07-16 Tom Tromey <tom@tromey.com>
2280 * xcoffread.c (xcoff_new_init): Update.
2281 * mipsread.c (mipscoff_new_init): Update.
2282 * mdebugread.c (mdebug_build_psymtabs): Update.
2283 * elfread.c (elf_new_init): Update.
2284 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
2285 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
2286 * buildsym.h (buildsym_new_init): Don't declare.
2287 * buildsym.c (buildsym_new_init): Remove.
2289 2018-07-16 Tom Tromey <tom@tromey.com>
2291 * stabsread.h (within_function): Move from buildsym.h.
2292 * stabsread.c (start_stabs): Clear within_function.
2293 * coffread.c (coff_start_symtab): Clear within_function.
2294 * buildsym.h (within_function): Move to stabsread.h.
2295 * buildsym.c (prepare_for_building): Update.
2297 2018-07-16 Tom Tromey <tom@tromey.com>
2299 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
2300 * dwarf2read.c (dwarf2_start_symtab): Don't set
2301 processing_gcc_compilation.
2302 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
2304 2018-07-16 Tom Tromey <tom@tromey.com>
2306 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
2307 (next_symbol_text_func): Move from buildsym.h.
2308 * stabsread.c (hashname): Move from buildsym.c.
2309 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
2310 (next_symbol_text_func, hashname): Move to stabsread.h.
2311 * buildsym.c: Don't include bcache.h
2312 (hashname): Move to stasbread.c.
2314 2018-07-16 Tom Tromey <tom@tromey.com>
2316 * buildsym.h (context_stack_size): Don't declare.
2317 * buildsym.c (context_stack_size): New global.
2319 2018-07-16 Tom Tromey <tom@tromey.com>
2321 * dbxread.c (processing_acc_compilation): New global.
2322 * buildsym.h (processing_acc_compilation): Don't declare.
2324 2018-07-16 Tom Tromey <tom@tromey.com>
2326 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
2327 * dbxread.c (read_ofile_symtab): Update.
2328 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
2329 * buildsym.h (last_source_start_addr): Remove.
2330 (set_last_source_start_addr, get_last_source_start_addr):
2332 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
2334 (struct buildsym_compunit) <m_last_source_start_addr>: New
2336 (prepare_for_building): Remove start_addr parameter.
2337 (start_symtab, restart_symtab, end_symtab_get_static_block)
2338 (end_symtab_with_blockvector): Update.
2339 (set_last_source_start_addr, get_last_source_start_addr): New
2342 2018-07-16 Tom Tromey <tom@tromey.com>
2344 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
2346 (have_line_numbers): Remove.
2347 (record_line, prepare_for_building, end_symtab_get_static_block)
2348 (augment_type_symtab): Update.
2350 2018-07-16 Tom Tromey <tom@tromey.com>
2352 * buildsym.c (~buildsym_compunit): Free the macro table.
2353 (struct buildsym_compunit) <get_macro_table, release_macros>: New
2355 <m_pending_macros>: New member.
2356 (pending_macros): Remove.
2357 (~scoped_free_pendings, get_macro_table, prepare_for_building)
2358 (reset_symtab_globals, end_symtab_get_static_block)
2359 (end_symtab_with_blockvector, augment_type_symtab)
2360 (buildsym_init): Update.
2362 2018-07-16 Tom Tromey <tom@tromey.com>
2364 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
2366 (buildsym_compunit::set_last_source_file): New method.
2367 <m_last_source_file>: New member.
2368 (prepare_for_building): Remove "name" parameter.
2369 (start_symtab, restart_symtab, reset_symtab_globals): Update.
2370 (last_source_file): Remove.
2371 (set_last_source_file, get_last_source_file): Update.
2373 2018-07-16 Tom Tromey <tom@tromey.com>
2375 * buildsym.c (prepare_for_building): Add assert.
2377 2018-07-16 Tom Tromey <tom@tromey.com>
2379 * buildsym.c (~buildsym_compunit): Update.
2380 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
2381 (start_subfile, patch_subfile_names)
2382 (end_symtab_with_blockvector): Update.
2384 2018-07-16 Tom Tromey <tom@tromey.com>
2386 * buildsym.c (struct buildsym_compunit): Add constructor,
2387 destructor, initializers.
2388 (start_buildsym_compunit): Remove.
2389 (free_buildsym_compunit): Use "delete".
2390 (start_symtab, restart_symtab): Use "new".
2392 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
2394 * symfile.c (set_objfile_default_section_offset): Remove struct
2397 2018-07-14 Stafford Horne <shorne@gmail.com>
2399 * (Responsible Maintainers): Add myself as or1k maintainer.
2401 2018-07-13 Tom Tromey <tom@tromey.com>
2403 * symfile.c (set_objfile_default_section_offset): Use extra braces
2406 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
2408 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
2411 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2413 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2414 unittests/cli-utils-selftests.c
2415 * unittests/cli-utils-selftests.c: New file.
2417 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2419 * NEWS: Mention new commands. Mention change to 'thread apply'.
2421 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2423 * thread.c (thr_try_catch_cmd): New function.
2424 (thread_apply_all_command): Handle qcs flags.
2425 (thread_apply_command): Handle qcs flags.
2426 (taas_command): New function.
2427 (tfaas_command): New function.
2428 (_initialize_thread): Update to setup the new commands 'taas
2429 and 'tfaas'. Change doc string for 'thread apply'.
2431 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2433 * stack.c: (trailing_outermost_frame): New function, mostly
2434 extracted from backtrace_command_1.
2435 (leading_innermost_frame): New function.
2436 (backtrace_command_1): Update to call trailing_outermost_frame.
2437 (frame_apply_command_count): New function.
2438 (frame_apply_level_command): New function.
2439 (frame_apply_all_command): New function.
2440 (frame_apply_command): New function.
2441 (faas_command): New function.
2442 (frame_cmd_list): New variable.
2443 (_initialize_stack): Update to setup the new commands 'frame apply'
2446 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2448 * cli-utils.c (number_or_range_parser::get_number): Only handle
2449 numbers or convenience var as numbers.
2450 (parse_flags): New function.
2451 (parse_flags_qcs): New function.
2452 (number_or_range_parser::finished): Ensure parsing end is detected
2453 before end of string.
2454 * cli-utils.h (parse_flags): New function.
2455 (parse_flags_qcs): New function.
2456 (number_or_range_parser): Remove m_finished bool.
2457 (number_or_range_parser::skip_range): Set m_in_range to false.
2459 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
2461 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
2464 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
2465 Jan Kratochvil <jan.kratochvil@redhat.com>
2466 Paul Fertser <fercerpav@gmail.com>
2467 Tsutomu Seki <sekiriki@gmail.com>
2468 Pedro Alves <palves@redhat.com>
2470 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2471 'unittests/parse-connection-spec-selftests.c'.
2472 (COMMON_SFILES): Add 'common/netstuff.c'.
2473 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
2474 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
2475 * common/netstuff.c: New file.
2476 * common/netstuff.h: New file.
2477 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
2478 (wait_for_connect): Update comment. New parameter
2479 'gdb::optional<int> sock' instead of 'struct serial *scb'.
2480 Use 'sock' directly instead of 'scb->fd'.
2481 (try_connect): New function, with code from 'net_open'.
2482 (net_open): Rewrite main loop to deal with multiple
2483 sockets/addresses. Handle IPv6-style hostnames; implement
2484 support for IPv6 connections.
2485 * unittests/parse-connection-spec-selftests.c: New file.
2487 2018-07-11 Pedro Alves <palves@redhat.com>
2490 * remote.c (remote_target::remote_detach_pid): Call
2491 set_current_process.
2493 2018-07-11 Pedro Alves <palves@redhat.com>
2495 * h8300-tdep.c (h8300_gdbarch_init): Remove
2496 set_gdbarch_ecoff_reg_to_regnum calls.
2498 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
2501 * c-typeprint.c (c_type_print_base_struct_union): Don't print
2502 offsets/sizes for static members of a class/struct.
2504 2018-07-11 Alan Hayward <alan.hayward@arm.com>
2506 * target-descriptions.c (tdesc_register_bitsize): Rename.
2507 * target-descriptions.h (tdesc_register_bitsize): Likewise.
2508 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
2509 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
2511 2018-07-10 Tom Tromey <tom@tromey.com>
2513 * breakpoint.c (moribund_locations): Now static and a
2515 (breakpoint_init_inferior, moribund_breakpoint_here_p)
2516 (build_bpstat_chain, update_global_location_list)
2517 (breakpoint_retire_moribund): Update.
2518 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
2521 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
2523 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
2524 (riscv_register_reggroup_p): Use new function, remove unneeded
2526 (riscv_push_dummy_call): Extend assert to compare against xlen or
2527 flen based on register type.
2529 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
2531 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
2533 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
2535 * remote.c (show_hardware_watchpoint_limit): New function.
2536 (show_hardware_watchpoint_length_limit): New function.
2537 (show_hardware_breakpoint_limit): New function.
2538 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
2539 where appropriate, update help text.
2541 2018-07-09 Tom Tromey <tom@tromey.com>
2543 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
2544 (CLIBS): Don't mention NAT_CLIBS.
2546 2018-07-09 Tom Tromey <tom@tromey.com>
2548 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
2549 (LIBGDB_OBS, clean mostlyclean): Update.
2550 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
2552 2018-07-09 Tom Tromey <tom@tromey.com>
2554 * Makefile.in (%.c: %.y): Use ECHO_YACC.
2555 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
2556 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
2558 2018-07-09 Tom Tromey <tom@tromey.com>
2560 * Makefile.in (ALLDEPFILES): Remove exec.c.
2561 (COMMON_OBS): Remove exec.o.
2562 (COMMON_SFILES): Add exec.c.
2564 2018-07-09 Tom Tromey <tom@tromey.com>
2566 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
2568 2018-07-09 Tom Tromey <tom@tromey.com>
2570 * Makefile.in (clean mostlyclean): Remove stamp-version.
2571 (version.c): Depend on stamp-version.
2572 (stamp-version): New rule, from version.c rule.
2574 2018-07-09 Tom Tromey <tom@tromey.com>
2576 * Makefile.in (init.c): Depend on stamp-init.
2577 (stamp-init): New rule, from init.c rule.
2578 (clean mostlyclean): Remove stamp-init.
2580 2018-07-09 Tom Tromey <tom@tromey.com>
2582 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
2583 SUBDIR_GCC_COMPILE_SRCS.
2585 2018-07-09 Tom Tromey <tom@tromey.com>
2587 * Makefile.in (init.c): Remove some unused sed rules.
2589 2018-07-09 Tom Tromey <tom@tromey.com>
2591 * Makefile.in (TSOBS): Remove.
2592 (INIT_FILES): Update.
2593 (LIBGDB_OBS): Update.
2594 (COMMON_SFILES): Add inflow.c.
2595 (SFILES): Remove inflow.c.
2597 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
2599 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
2601 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
2603 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
2604 get_saveloc_name, is_signal_frame_name, step_name,
2605 init_remote_name, create_addr_space_name,
2606 destroy_addr_space_name, search_unwind_table_name,
2607 find_dyn_list_name): Constify.
2609 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
2611 * darwin-nat.c (darwin_pthread_kill): New function.
2612 (darwin_resume_thread): Use darwin_pthread_kill.
2614 2018-07-05 Tom de Vries <tdevries@suse.de>
2616 * macroexp.c (macro_buffer) <operator=>: New member function.
2618 2018-07-04 Tom Tromey <tom@tromey.com>
2620 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
2622 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
2624 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
2625 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
2626 * maint.c: Likewise.
2629 2018-07-04 Joel Brobecker <brobecker@adacore.com>
2631 * NEWS: Create a new section for the next release branch.
2632 Rename the section of the current branch, now that it has
2635 2018-07-04 Joel Brobecker <brobecker@adacore.com>
2637 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
2638 * version.in: Bump version to 8.2.50.DATE-git.
2640 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
2641 Pedro Alves <palves@redhat.com>
2643 * linux-nat.c (linux_init_ptrace): Rename to ...
2644 (linux_init_ptrace_procfs): ... this. Call
2645 linux_proc_init_warnings.
2646 (linux_nat_target::post_attach)
2647 (linux_nat_target::post_startup_inferior): Adjust.
2648 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
2649 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
2651 2018-07-04 Tom de Vries <tdevries@suse.de>
2653 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
2655 (read_comp_unit_head): ... here.
2657 2018-07-03 Tom Tromey <tom@tromey.com>
2659 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
2660 (stop_tracing, tstatus_command)
2661 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
2662 (print_one_static_tracepoint_marker): Update.
2663 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
2665 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
2667 (all_tracepoints, static_tracepoints_here): Return std::vector.
2669 2018-07-03 Tom Tromey <tom@tromey.com>
2671 * common/ptid.c (ptid_equal): Remove.
2672 * common/ptid.h (ptid_equal): Don't declare.
2673 * ada-tasks.c: Update.
2674 * breakpoint.c: Update.
2675 * common/agent.c: Update.
2676 * corelow.c: Update.
2677 * darwin-nat-info.c: Update.
2678 * darwin-nat.c: Update.
2680 * dtrace-probe.c: Update.
2681 * dummy-frame.c: Update.
2682 * fbsd-nat.c: Update.
2684 * gdbthread.h: Update.
2685 * gnu-nat.c: Update.
2686 * go32-nat.c: Update.
2687 * inf-loop.c: Update.
2688 * inf-ptrace.c: Update.
2689 * infcall.c: Update.
2693 * linux-fork.c: Update.
2694 * linux-nat.c: Update.
2695 * linux-thread-db.c: Update.
2696 * mi/mi-cmd-var.c: Update.
2697 * mi/mi-interp.c: Update.
2698 * mi/mi-main.c: Update.
2699 * nto-procfs.c: Update.
2700 * ppc-linux-tdep.c: Update.
2702 * python/py-inferior.c: Update.
2703 * python/py-record-btrace.c: Update.
2704 * python/py-record.c: Update.
2705 * ravenscar-thread.c: Update.
2706 * regcache.c: Update.
2707 * remote-sim.c: Update.
2709 * sol-thread.c: Update.
2712 * tui/tui-stack.c: Update.
2714 * windows-nat.c: Update.
2715 * windows-tdep.c: Update.
2717 2018-07-03 Tom Tromey <tom@tromey.com>
2719 * common/ptid.c (ptid_match): Remove.
2720 * common/ptid.h (ptid_match): Don't declare.
2721 * fbsd-nat.c: Update.
2724 * linux-nat.c: Update.
2725 * record-btrace.c: Update.
2726 * regcache.c: Update.
2729 2018-07-03 Tom Tromey <tom@tromey.com>
2731 * common/ptid.c (ptid_tid_p): Remove.
2732 * common/ptid.h (ptid_tid_p): Don't declare.
2733 * sol-thread.c: Update.
2735 2018-07-03 Tom Tromey <tom@tromey.com>
2737 * common/ptid.c (ptid_lwp_p): Remove.
2738 * common/ptid.h (ptid_lwp_p): Don't declare.
2739 * fbsd-nat.c: Update.
2740 * linux-nat.c: Update.
2741 * nat/linux-procfs.c: Update.
2742 * nat/x86-linux-dregs.c: Update.
2743 * sol-thread.c: Update.
2745 2018-07-03 Tom Tromey <tom@tromey.com>
2747 * common/ptid.c (ptid_is_pid): Remove.
2748 * common/ptid.h (ptid_is_pid): Don't declare.
2750 * linux-nat.c: Update.
2751 * mi/mi-interp.c: Update.
2755 2018-07-03 Tom Tromey <tom@tromey.com>
2757 * common/ptid.c (ptid_get_tid): Remove.
2758 * common/ptid.h (ptid_get_tid): Don't declare.
2759 * ada-tasks.c: Update.
2760 * aix-thread.c: Update.
2761 * bsd-uthread.c: Update.
2762 * darwin-nat.c: Update.
2763 * fbsd-nat.c: Update.
2764 * i386-darwin-nat.c: Update.
2766 * linux-tdep.c: Update.
2767 * nto-procfs.c: Update.
2768 * ppc-ravenscar-thread.c: Update.
2769 * python/py-infthread.c: Update.
2770 * ravenscar-thread.c: Update.
2771 * sol-thread.c: Update.
2772 * sparc-ravenscar-thread.c: Update.
2773 * windows-nat.c: Update.
2775 2018-07-03 Tom Tromey <tom@tromey.com>
2777 * common/ptid.c (ptid_get_lwp): Remove.
2778 * common/ptid.h (ptid_get_lwp): Don't declare.
2779 * aarch64-linux-nat.c: Update.
2780 * ada-tasks.c: Update.
2781 * aix-thread.c: Update.
2782 * amd64-linux-nat.c: Update.
2783 * arm-linux-nat.c: Update.
2784 * corelow.c: Update.
2785 * fbsd-nat.c: Update.
2786 * fbsd-tdep.c: Update.
2787 * gnu-nat.c: Update.
2788 * i386-cygwin-tdep.c: Update.
2789 * i386-gnu-nat.c: Update.
2790 * i386-linux-nat.c: Update.
2791 * ia64-linux-nat.c: Update.
2792 * inf-ptrace.c: Update.
2794 * linux-fork.c: Update.
2795 * linux-nat.c: Update.
2796 * linux-tdep.c: Update.
2797 * linux-thread-db.c: Update.
2798 * mips-linux-nat.c: Update.
2799 * nat/aarch64-linux-hw-point.c: Update.
2800 * nat/aarch64-linux.c: Update.
2801 * nat/linux-btrace.c: Update.
2802 * nat/linux-osdata.c: Update.
2803 * nat/linux-procfs.c: Update.
2804 * nat/x86-linux-dregs.c: Update.
2805 * obsd-nat.c: Update.
2806 * ppc-fbsd-nat.c: Update.
2807 * ppc-linux-nat.c: Update.
2809 * python/py-infthread.c: Update.
2810 * ravenscar-thread.c: Update.
2812 * s390-linux-nat.c: Update.
2813 * sol-thread.c: Update.
2814 * sol2-tdep.c: Update.
2815 * spu-linux-nat.c: Update.
2816 * x86-linux-nat.c: Update.
2817 * xtensa-linux-nat.c: Update.
2819 2018-07-03 Tom Tromey <tom@tromey.com>
2821 * common/ptid.c (ptid_get_pid): Remove.
2822 * common/ptid.h (ptid_get_pid): Don't declare.
2823 * aarch64-linux-nat.c: Update.
2824 * ada-lang.c: Update.
2825 * aix-thread.c: Update.
2826 * alpha-bsd-nat.c: Update.
2827 * amd64-fbsd-nat.c: Update.
2828 * amd64-linux-nat.c: Update.
2829 * arm-linux-nat.c: Update.
2830 * arm-nbsd-nat.c: Update.
2832 * break-catch-syscall.c: Update.
2833 * breakpoint.c: Update.
2834 * bsd-uthread.c: Update.
2835 * corelow.c: Update.
2837 * darwin-nat.c: Update.
2838 * fbsd-nat.c: Update.
2839 * fbsd-tdep.c: Update.
2841 * gnu-nat.c: Update.
2842 * hppa-nbsd-nat.c: Update.
2843 * hppa-obsd-nat.c: Update.
2844 * i386-fbsd-nat.c: Update.
2845 * ia64-linux-nat.c: Update.
2846 * inf-ptrace.c: Update.
2848 * inferior.c: Update.
2849 * inferior.h: Update.
2852 * linux-fork.c: Update.
2853 * linux-nat.c: Update.
2854 * linux-tdep.c: Update.
2855 * linux-thread-db.c: Update.
2856 * m68k-bsd-nat.c: Update.
2857 * mi/mi-interp.c: Update.
2858 * mi/mi-main.c: Update.
2859 * mips-linux-nat.c: Update.
2860 * mips-nbsd-nat.c: Update.
2861 * mips64-obsd-nat.c: Update.
2862 * nat/aarch64-linux-hw-point.c: Update.
2863 * nat/aarch64-linux.c: Update.
2864 * nat/linux-btrace.c: Update.
2865 * nat/linux-osdata.c: Update.
2866 * nat/linux-procfs.c: Update.
2867 * nat/x86-linux-dregs.c: Update.
2868 * nto-procfs.c: Update.
2869 * obsd-nat.c: Update.
2870 * ppc-linux-nat.c: Update.
2871 * ppc-nbsd-nat.c: Update.
2872 * ppc-obsd-nat.c: Update.
2873 * proc-service.c: Update.
2875 * python/py-inferior.c: Update.
2876 * python/py-infthread.c: Update.
2877 * ravenscar-thread.c: Update.
2879 * remote-sim.c: Update.
2881 * rs6000-nat.c: Update.
2882 * s390-linux-nat.c: Update.
2883 * sh-nbsd-nat.c: Update.
2884 * sol-thread.c: Update.
2885 * sparc-nat.c: Update.
2886 * sparc64-tdep.c: Update.
2887 * spu-linux-nat.c: Update.
2888 * spu-tdep.c: Update.
2889 * target-debug.h: Update.
2892 * tid-parse.c: Update.
2893 * tracefile-tfile.c: Update.
2894 * vax-bsd-nat.c: Update.
2895 * windows-nat.c: Update.
2896 * x86-linux-nat.c: Update.
2897 * x86-nat.c: Update.
2899 2018-07-03 Tom Tromey <tom@tromey.com>
2901 * common/ptid.c (pid_to_ptid): Remove.
2902 * common/ptid.h (pid_to_ptid): Don't declare.
2903 * aix-thread.c: Update.
2904 * arm-linux-nat.c: Update.
2905 * common/ptid.c: Update.
2906 * common/ptid.h: Update.
2907 * corelow.c: Update.
2909 * darwin-nat.c: Update.
2910 * fbsd-nat.c: Update.
2911 * fork-child.c: Update.
2912 * gnu-nat.c: Update.
2913 * go32-nat.c: Update.
2914 * inf-ptrace.c: Update.
2916 * inferior.c: Update.
2918 * linux-fork.c: Update.
2919 * linux-nat.c: Update.
2920 * nat/aarch64-linux-hw-point.c: Update.
2921 * nat/fork-inferior.c: Update.
2922 * nat/x86-linux-dregs.c: Update.
2923 * nto-procfs.c: Update.
2924 * obsd-nat.c: Update.
2926 * progspace.c: Update.
2928 * rs6000-nat.c: Update.
2929 * s390-linux-nat.c: Update.
2930 * sol-thread.c: Update.
2931 * spu-linux-nat.c: Update.
2934 * tracefile-tfile.c: Update.
2935 * windows-nat.c: Update.
2937 2018-07-03 Tom Tromey <tom@tromey.com>
2939 * common/ptid.h (ptid_build): Don't declare.
2940 * common/ptid.c (ptid_build): Remove.
2941 * aix-thread.c: Update.
2942 * bsd-kvm.c: Update.
2943 * bsd-uthread.c: Update.
2944 * common/agent.c: Update.
2945 * common/ptid.c: Update.
2946 * common/ptid.h: Update.
2947 * corelow.c: Update.
2948 * darwin-nat.c: Update.
2949 * fbsd-nat.c: Update.
2950 * gnu-nat.c: Update.
2951 * linux-fork.c: Update.
2952 * linux-nat.c: Update.
2953 * linux-thread-db.c: Update.
2954 * nat/linux-osdata.c: Update.
2955 * nat/linux-procfs.c: Update.
2956 * nto-procfs.c: Update.
2957 * obsd-nat.c: Update.
2958 * proc-service.c: Update.
2960 * ravenscar-thread.c: Update.
2961 * remote-sim.c: Update.
2963 * sol-thread.c: Update.
2965 * windows-nat.c: Update.
2967 2018-07-03 Tom Tromey <tom@tromey.com>
2969 * infrun.c (follow_exec): Use exit_inferior_silent.
2970 * inferior.c (exit_inferior_num_silent): Remove.
2971 * inferior.h (exit_inferior_num_silent): Don't declare.
2973 2018-07-03 Tom Tromey <tom@tromey.com>
2976 * darwin-nat.c (darwin_attach_pid): Reset inferior and
2977 inferior_ptid on error.
2979 2018-07-02 Maciej W. Rozycki <macro@mips.com>
2980 Simon Marchi <simon.marchi@polymtl.ca>
2983 * disasm.h (gdb_disassembler): Add
2984 `m_disassembler_options_holder'. member
2985 * disasm.c (get_all_disassembler_options): New function.
2986 (gdb_disassembler::gdb_disassembler): Use it.
2987 (gdb_buffered_insn_length_init_dis): Likewise.
2988 (gdb_buffered_insn_length): Adjust accordingly.
2989 (set_disassembler_options): Handle options with arguments.
2990 (show_disassembler_options_sfunc): Likewise. Add a leading new
2991 line if showing options with descriptions.
2992 (disassembler_options_completer): Adapt to using the
2993 `disasm_options_and_args_t' structure.
2994 * mips-tdep.c (mips_disassembler_options): New variable.
2995 (mips_disassembler_options_o32): Likewise.
2996 (mips_disassembler_options_n32): Likewise.
2997 (mips_disassembler_options_n64): Likewise.
2998 (gdb_print_insn_mips): Don't set `disassembler_options'.
2999 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
3001 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
3002 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
3003 `gdbarch_disassembler_options_implicit' and
3004 `gdbarch_valid_disassembler_options'.
3005 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
3006 `disasm_options_and_args_t' structure.
3007 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
3009 (valid_disassembler_options): Switch from `disasm_options_t' to
3010 the `disasm_options_and_args_t' structure.
3011 * NEWS: Document `set disassembler-options' support for the MIPS
3013 * gdbarch.h: Regenerate.
3014 * gdbarch.c: Regenerate.
3016 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
3018 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
3020 2018-06-29 Joel Brobecker <brobecker@adacore.com>
3022 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
3023 parameter in call to amd64_target_description.
3024 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
3025 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
3026 (amd64fbsd_init_abi): Likewise.
3027 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
3028 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
3029 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
3030 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
3032 2018-06-29 Pedro Alves <palves@redhat.com>
3034 * gdb/amd64-tdep.h (amd64_create_target_description): Add
3035 "segments" parameter.
3036 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
3037 (_initialize_amd64_tdep): Update call to
3038 amd64_create_target_description.
3039 (amd64_target_description): Add "segments" parameter. Adjust
3040 the implementation to use it.
3041 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
3042 call to amd64_create_target_description.
3043 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
3044 * gdb/arch/amd64.h (amd64_create_target_description): Add
3045 "segments" register.
3046 * gdb/arch/amd64.c (amd64_create_target_description): Add
3047 "segments" parameter. Call create_feature_i386_64bit_segments
3048 only if SEGMENTS is true.
3049 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
3050 call to amd64_create_target_description.
3052 2018-06-29 Pedro Alves <palves@redhat.com>
3054 * thread.c (thread_target_id_str): New, factored out from ...
3055 (print_thread_info_1): ... here. Use it to compute the max
3056 "Target Id" column width.
3058 2018-06-29 Pedro Alves <palves@redhat.com>
3060 * remote.c (remote_target::extra_thread_info): Delete
3061 'display_buf' and 'n' locals. from the cache, regardless of
3062 packet mechanims is in use. Use cache for qThreadExtra and qP
3065 2018-06-29 Pedro Alves <palves@redhat.com>
3067 * blockframe.c (find_pc_sect_containing_function): New function.
3068 * breakpoint.c (print_breakpoint_location): Don't call
3069 find_pc_sect_function.
3070 * linespec.c (create_sals_line_offset): Record the location's
3072 * linespec.c (convert_address_location_to_sals): Fill in sal's
3073 symbol with find_pc_sect_containing_function.
3074 * symtab.c (find_function_start_sal): Rename to ...
3075 (find_function_start_sal_1): ... this.
3076 (find_function_start_sal): Reimplement as wrapper around
3077 find_function_start_sal_1, and use
3078 find_pc_sect_containing_function to fill in the sal's symbol.
3079 (find_function_start_sal(symbol*, bool)): Adjust.
3080 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
3082 (find_pc_sect_containing_function): Declare.
3084 2018-06-29 Pedro Alves <palves@redhat.com>
3086 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
3087 true if the the location has no symbol.
3089 2018-06-28 Tom Tromey <tom@tromey.com>
3091 * NEWS: Mention --enable-codesign.
3092 * silent-rules.mk (ECHO_SIGN): New variable.
3093 * configure.ac: Add --enable-codesign.
3094 * configure: Rebuild.
3095 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
3096 (gdb$(EXEEXT)): Optionally invoke codesign.
3098 2018-06-28 Pedro Alves <palves@redhat.com>
3100 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
3102 (switch_to_thread_no_regs): Adjust comment.
3103 * infcmd.c (stop_pc): Delete.
3104 (post_create_inferior, info_program_command): Replace references
3105 to stop_pc with references to thread_info->suspend.stop_pc.
3106 * inferior.h (stop_pc): Delete declaration.
3107 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
3108 (handle_inferior_event_1, handle_signal_stop)
3109 (process_event_stop_test, keep_going_stepped_thread)
3110 (handle_step_into_function, handle_step_into_function_backward)
3111 (print_stop_location): Replace references to stop_pc with
3112 references to thread_info->suspend.stop_pc.
3113 (struct infcall_suspend_state) <stop_pc>: Delete field.
3114 (save_infcall_suspend_state, restore_infcall_suspend_state):
3115 Remove references to inf_stat->stop_pc.
3116 * linux-fork.c (fork_load_infrun_state): Likewise.
3117 * record-btrace.c (record_btrace_set_replay): Likewise.
3118 * record-full.c (record_full_goto_entry): Likewise.
3119 * remote.c (print_one_stopped_thread): Likewise.
3120 * target.c (target_resume): Extend comment.
3121 * thread.c (set_executing_thread): New.
3122 (set_executing): Use it.
3123 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
3124 Remove references to stop_pc.
3126 2018-06-28 Pedro Alves <palves@redhat.com>
3128 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
3129 Moving fetching stop_pc until after ecs->event_thread is refreshed.
3131 2018-06-28 Tom Tromey <tom@tromey.com>
3133 * coffread.c (coff_symfile_finish): Update.
3134 * xcoffread.c (xcoff_symfile_finish): Update.
3135 * elfread.c (elf_symfile_finish): Update.
3136 * symfile.h (dwarf2_free_objfile): Don't declare.
3137 * dwarf2read.c (_initialize_dwarf2_read): Use
3138 register_objfile_data_with_cleanup.
3139 (dwarf2_free_objfile): Now static. Change signature.
3141 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
3143 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
3144 option "-o" to add-symbol-file-load to add an offset to each
3145 section's load address.
3146 * symfile.c (set_objfile_default_section_offset): New function.
3148 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
3150 * symfile.c (add_symbol_file_command): Make sure that sections
3151 with the same name are sorted in the same order.
3153 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
3155 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
3156 require the second argument. If omitted, load sections at the
3157 addresses specified in the file.
3159 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
3161 * symfile.c (symbol_file_command, symbol_file_add_main_1)
3162 (_initialize_symfile): Add option "-o" to symbol-file to add an
3163 offset to each section of the symbol file.
3165 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
3167 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
3169 2018-06-27 Tom Tromey <tom@tromey.com>
3171 * stack.c (_initialize_stack): Update "func" help text.
3173 2018-06-27 Tom Tromey <tom@tromey.com>
3175 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
3177 (unwind_infopy_str, pyuw_create_unwind_info)
3178 (unwind_infopy_add_saved_register, pyuw_sniffer)
3179 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
3181 (struct saved_reg): Add constructor.
3182 <value>: Now a gdbpy_ref<>.
3184 2018-06-27 Tom Tromey <tom@tromey.com>
3186 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
3188 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
3190 * gdb-gdb.py.in: Format using autopep8.
3192 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
3194 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
3195 (type_lookup_function): Recognize CORE_ADDR values.
3197 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
3199 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
3202 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
3204 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
3207 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
3209 * gdb-gdb.py: Move to...
3210 * gdb-gdb.py.in: ... here.
3211 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
3212 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
3214 (distclean): Remove gdb-gdb.py when cleaning.
3215 (gdb-gdb.py, gdb-gdb.gdb): New rules.
3216 * configure: Re-generate.
3218 2018-06-27 Pedro Alves <palves@redhat.com>
3220 * proc-service.c (get_ps_regcache): New.
3221 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
3222 (ps_lsetfpregs): Use it.
3224 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
3227 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
3228 (dwarf_decode_lines_1): Adjust.
3230 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
3232 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
3234 <info_proc>: Likewise.
3236 2018-06-26 Joel Brobecker <brobecker@adacore.com>
3238 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
3239 to windows_fetch_one_register, and only handle the case of
3240 fetching one register. Move the code that reloads the context
3241 and iterates over all registers if R is negative to...
3242 (windows_nat_target::fetch_registers): ... here.
3243 (do_windows_store_inferior_registers): Rename to
3244 windows_store_one_register, and only handle the case of storing
3245 one register. Move the code that handles the case where r is
3247 (windows_nat_target::store_registers) ... here.
3249 2018-06-26 Tom Tromey <tom@tromey.com>
3252 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
3253 * rust-lang.c (rust_print_struct_def): Add podata parameter.
3255 (rust_internal_print_type): Add podata parameter.
3256 (rust_print_type): Update.
3258 2018-06-26 Tom Tromey <tom@tromey.com>
3260 * typeprint.h (struct print_offset_data) <update, finish,
3261 maybe_print_hole>: New methods.
3262 <indentation>: New constant.
3263 * typeprint.c (print_offset_data::indentation): Define.
3264 (print_offset_data::maybe_print_hole, print_offset_data::update)
3265 (print_offset_data::finish): Move from c-typeprint.c and rename.
3266 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
3267 (print_spaces_filtered_with_print_options): Update.
3268 (c_print_type_union_field_offset, maybe_print_hole)
3269 (c_print_type_struct_field_offset): Move to typeprint.c and
3271 (c_type_print_base_struct_union): Update.
3273 2018-06-25 Pedro Alves <palves@redhat.com>
3275 * gdbthread.h (thread_info_ref, delete_thread)
3276 (delete_thread_silent, first_thread_of_inferior)
3277 (any_thread_of_inferior, switch_to_thread)
3278 (enable_thread_stack_temporaries)
3279 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
3280 (get_last_thread_stack_temporary)
3281 (value_in_thread_stack_temporaries, can_access_registers_thread):
3282 Spell out "struct thread_info" instead of just "thread_info".
3283 * inferior.h (notice_new_inferior): Likewise.
3285 2018-06-25 Pedro Alves <palves@redhat.com>
3287 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
3288 pass thread_info pointer to delete_thread.
3289 (windows_nat_target::detach): Pass inferior pointer to
3291 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
3293 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
3294 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
3295 and pass a thread_info pointer to delete_thread.
3296 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
3297 pass thread_info pointer to delete_thread.
3298 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
3299 delete_thread_silent call.
3300 * procfs.c (procfs_target::detach): Pass inferior pointer to
3302 (procfs_target::wait): Pass thread_info pointer to delete_thread.
3303 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
3304 delete_thread_silent call.
3305 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
3306 pass thread_info pointer to delete_thread.
3307 (windows_nat_target::detach): Pass inferior pointer to
3310 2018-06-22 Alan Hayward <alan.hayward@arm.com>
3312 * regcache.c (readable_regcache::read_part): Fix asserts.
3313 (reg_buffer::raw_collect_part): New function.
3314 (regcache::write_part): Fix asserts.
3315 (reg_buffer::raw_supply_part): New function.
3316 (regcache::transfer_regset_register): New helper function.
3317 (regcache::transfer_regset): Call new functions.
3318 (regcache_supply_regset): Use gdb_byte*.
3319 (regcache::supply_regset): Likewise.
3320 (regcache_collect_regset): Likewise.
3321 (regcache::collect_regset): Likewise.
3322 * regcache.h (reg_buffer::raw_collect_part): New declaration.
3323 (reg_buffer::raw_supply_part): Likewise.
3324 (regcache::transfer_regset_register): Likewise.
3325 (regcache::transfer_regset): Use gdb_byte*.
3327 2018-06-22 Alan Hayward <alan.hayward@arm.com>
3329 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
3331 2018-06-21 Pedro Alves <palves@redhat.com>
3333 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
3334 instead of a ptid_t. All callers adjusted.
3335 * ada-tasks.c (ada_get_task_number): Likewise. All callers
3337 (print_ada_task_info, display_current_task_id, task_command_1):
3339 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
3341 (breakpoint_kind): Adjust.
3342 (remove_breakpoints_pid): Rename to ...
3343 (remove_breakpoints_inf): ... this. Adjust to take an inferior
3344 pointer. All callers adjusted.
3345 (bpstat_clear_actions): Use inferior_thread.
3346 (get_bpstat_thread): New.
3347 (bpstat_do_actions): Use it.
3348 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
3349 to take a thread_info pointer. All callers adjusted.
3350 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
3351 (breakpoint_re_set_thread): Use inferior_thread.
3352 * breakpoint.h (struct inferior): Forward declare.
3353 (bpstat_stop_status): Update.
3354 (remove_breakpoints_pid): Delete.
3355 (remove_breakpoints_inf): New.
3356 * bsd-uthread.c (bsd_uthread_target::wait)
3357 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
3358 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
3359 (maint_btrace_packet_history_cmd)
3360 (maint_btrace_clear_packet_history_cmd): Adjust.
3361 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
3363 * cli/cli-interp.c: Include "inferior.h".
3364 * common/refcounted-object.h (struct
3365 refcounted_object_ref_policy): New.
3366 * compile/compile-object-load.c: Include gdbthread.h.
3367 (store_regs): Use inferior_thread.
3368 * corelow.c (core_target::close): Use current_inferior.
3369 (core_target_open): Adjust to use first_thread_of_inferior and use
3370 the current inferior.
3371 * ctf.c (ctf_target::close): Adjust to use current_inferior.
3372 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
3373 <thread>: ... this new field. All references adjusted.
3374 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
3375 Take a thread_info pointer instead of a ptid_t.
3376 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
3377 (dummy_frame_discard, register_dummy_frame_dtor): Take a
3378 thread_info pointer instead of a ptid_t.
3379 * elfread.c: Include "inferior.h".
3380 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
3381 Use inferior_thread.
3382 * eval.c (evaluate_subexp): Likewise.
3383 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
3385 * gdb_proc_service.h (struct thread_info): Forward declare.
3386 (struct ps_prochandle) <ptid>: Delete, replaced by ...
3387 <thread>: ... this new field. All references adjusted.
3388 * gdbarch.h, gdbarch.c: Regenerate.
3389 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
3390 'thread' parameter. All implementations and callers adjusted.
3391 * gdbthread.h (thread_info) <set_running>: New method.
3392 (delete_thread, delete_thread_silent): Take a thread_info pointer
3394 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
3395 (first_thread_of_process): Delete, replaced by ...
3396 (first_thread_of_inferior): ... this new function. All callers
3398 (any_live_thread_of_process): Delete, replaced by ...
3399 (any_live_thread_of_inferior): ... this new function. All callers
3401 (switch_to_thread, switch_to_no_thread): Declare.
3402 (is_executing): Delete.
3403 (enable_thread_stack_temporaries): Update comment.
3404 <enable_thread_stack_temporaries>: Take a thread_info pointer
3405 instead of a ptid_t. Incref the thread.
3406 <~enable_thread_stack_temporaries>: Decref the thread.
3409 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
3410 (get_last_thread_stack_temporary)
3411 (value_in_thread_stack_temporaries, can_access_registers_thread):
3412 Take a thread_info pointer instead of a ptid_t. All callers
3414 * infcall.c (get_call_return_value): Use inferior_thread.
3415 (run_inferior_call): Work with thread pointers instead of ptid_t.
3416 (call_function_by_hand_dummy): Work with thread pointers instead
3417 of ptid_t. Use thread_info_ref.
3418 * infcmd.c (proceed_thread_callback): Access thread's state
3420 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
3421 access thread's state directly.
3422 (continue_command): Use inferior_thread.
3423 (info_program_command): Use find_thread_ptid and access thread
3425 (proceed_after_attach_callback): Use thread state directly.
3426 (notice_new_inferior): Take a thread_info pointer instead of a
3427 ptid_t. All callers adjusted.
3428 (exit_inferior): Take an inferior pointer instead of a pid. All
3430 (exit_inferior_silent): New.
3431 (detach_inferior): Delete.
3432 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
3433 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
3434 (detach_inferior_command, kill_inferior_command): Use
3435 find_inferior_id instead of valid_gdb_inferior_id and
3436 gdb_inferior_id_to_pid.
3437 (inferior_command): Use inferior and thread pointers.
3438 * inferior.h (struct thread_info): Forward declare.
3439 (notice_new_inferior): Take a thread_info pointer instead of a
3440 ptid_t. All callers adjusted.
3441 (detach_inferior): Delete declaration.
3442 (exit_inferior, exit_inferior_silent): Take an inferior pointer
3443 instead of a pid. All callers adjusted.
3444 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
3445 (valid_gdb_inferior_id): Delete.
3446 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
3447 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
3448 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
3450 <inf>: ... this new field.
3451 <step_ptid>: Delete, replaced by ...
3452 <step_thread>: ... this new field.
3453 (get_displaced_stepping_state): Take an inferior pointer instead
3454 of a pid. All callers adjusted.
3455 (displaced_step_in_progress_any_inferior): Adjust.
3456 (displaced_step_in_progress_thread): Take a thread pointer instead
3457 of a ptid_t. All callers adjusted.
3458 (displaced_step_in_progress, add_displaced_stepping_state): Take
3459 an inferior pointer instead of a pid. All callers adjusted.
3460 (get_displaced_step_closure_by_addr): Adjust.
3461 (remove_displaced_stepping_state): Take an inferior pointer
3462 instead of a pid. All callers adjusted.
3463 (displaced_step_prepare_throw, displaced_step_prepare)
3464 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
3465 All callers adjusted.
3466 (start_step_over): Adjust.
3467 (infrun_thread_ptid_changed): Remove bit updating ptids in the
3468 displaced step queue.
3469 (do_target_resume): Adjust.
3470 (fetch_inferior_event): Use inferior_thread.
3471 (context_switch, get_inferior_stop_soon): Take an
3472 execution_control_state pointer instead of a ptid_t. All callers
3474 (switch_to_thread_cleanup): Delete.
3475 (stop_all_threads): Use scoped_restore_current_thread.
3476 * inline-frame.c: Include "gdbthread.h".
3477 (inline_state) <inline_state>: Take a thread pointer instead of a
3478 ptid_t. All callers adjusted.
3479 <ptid>: Delete, replaced by ...
3480 <thread>: ... this new field.
3481 (find_inline_frame_state): Take a thread pointer instead of a
3482 ptid_t. All callers adjusted.
3483 (skip_inline_frames, step_into_inline_frame)
3484 (inline_skipped_frames, inline_skipped_symbol): Take a thread
3485 pointer instead of a ptid_t. All callers adjusted.
3486 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
3487 (inline_skipped_frames, inline_skipped_symbol): Likewise.
3488 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
3490 * linux-nat.c (get_detach_signal): Likewise.
3491 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
3492 (thread_db_notice_clone): Adjust.
3493 (thread_db_find_new_threads_silently)
3494 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
3495 a thread pointer instead of a ptid_t. All callers adjusted.
3496 * mi/mi-cmd-var.c: Include "inferior.h".
3497 (mi_cmd_var_update_iter): Update to use thread pointers.
3498 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
3500 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
3502 (mi_output_running): ... this new function.
3503 (mi_on_resume_1): Adjust to use it.
3504 (mi_user_selected_context_changed): Adjust to use inferior_thread.
3505 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
3507 (interrupt_thread_callback): : Adjust to use thread and inferior
3509 * proc-service.c: Include "gdbthread.h".
3510 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
3511 * progspace-and-thread.c: Include "inferior.h".
3512 * progspace.c: Include "inferior.h".
3513 * python/py-exitedevent.c (create_exited_event_object): Adjust to
3514 hold a reference to an inferior_object.
3515 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
3517 * python/py-inferior.c (struct inferior_object): Give the type a
3518 tag name instead of a typedef.
3519 (python_on_normal_stop): No need to check if the current thread is
3521 (inferior_to_inferior_object): Change return type to
3522 inferior_object. All callers adjusted.
3523 (find_thread_object): Delete, bits factored out to ...
3524 (thread_to_thread_object): ... this new function.
3525 * python/py-infthread.c (create_thread_object): Use
3526 inferior_to_inferior_object.
3527 (thpy_is_stopped): Use thread pointer directly.
3528 (gdbpy_selected_thread): Use inferior_thread.
3529 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
3530 field, replaced with ...
3531 <thread>: ... this new field. All users adjusted.
3532 (btpy_insn_or_gap_new): Drop const.
3533 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
3535 * python/py-record.c: Include "gdbthread.h".
3536 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
3537 a ptid_t. All callers adjusted.
3538 (gdbpy_current_recording): Use inferior_thread.
3539 * python/py-record.h (recpy_record_object) <ptid>: Delete
3540 field, replaced with ...
3541 <thread>: ... this new field. All users adjusted.
3542 (recpy_element_object) <ptid>: Delete
3543 field, replaced with ...
3544 <thread>: ... this new field. All users adjusted.
3545 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
3546 a ptid_t. All callers adjusted.
3547 * python/py-threadevent.c: Include "gdbthread.h".
3548 (get_event_thread): Use thread_to_thread_object.
3549 * python/python-internal.h (struct inferior_object): Forward
3551 (find_thread_object, find_inferior_object): Delete declarations.
3552 (thread_to_thread_object, inferior_to_inferior_object): New
3554 * record-btrace.c: Include "inferior.h".
3555 (require_btrace_thread): Use inferior_thread.
3556 (record_btrace_frame_sniffer)
3557 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
3558 (get_thread_current_frame): Use scoped_restore_current_thread and
3560 (get_thread_current_frame): Use thread pointer directly.
3561 (record_btrace_replay_at_breakpoint): Use thread's inferior
3563 * record-full.c: Include "inferior.h".
3564 * regcache.c: Include "gdbthread.h".
3565 (get_thread_arch_regcache): Use the inferior's address space
3567 (get_thread_regcache, registers_changed_thread): New.
3568 * regcache.h (get_thread_regcache(thread_info *thread)): New
3570 (registers_changed_thread): New.
3571 (remote_target) <remote_detach_1>: Swap order of parameters.
3572 (remote_add_thread): <remote_add_thread>: Return the new thread.
3573 (get_remote_thread_info(ptid_t)): New overload.
3574 (remote_target::remote_notice_new_inferior): Use thread pointers
3576 (remote_target::process_initial_stop_replies): Use
3577 thread_info::set_running.
3578 (remote_target::remote_detach_1, remote_target::detach)
3579 (extended_remote_target::detach): Adjust.
3580 * stack.c (frame_show_address): Use inferior_thread.
3581 * target-debug.h (target_debug_print_thread_info_pp): New.
3582 * target-delegates.c: Regenerate.
3583 * target.c (default_thread_address_space): Delete.
3584 (memory_xfer_partial_1): Use current_inferior.
3585 (target_detach): Use current_inferior.
3586 (target_thread_address_space): Delete.
3587 (generic_mourn_inferior): Use current_inferior.
3588 * target.h (struct target_ops) <thread_address_space>: Delete.
3589 (target_thread_address_space): Delete.
3590 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
3592 (delete_thread_1, delete_thread, delete_thread_silent): Take a
3593 thread pointer instead of a ptid_t. Adjust all callers.
3594 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
3595 (first_thread_of_process): Delete, replaced by ...
3596 (first_thread_of_inferior): ... this new function. All callers
3598 (any_thread_of_process): Rename to ...
3599 (any_thread_of_inferior): ... this, and take an inferior pointer.
3600 (any_live_thread_of_process): Rename to ...
3601 (any_live_thread_of_inferior): ... this, and take an inferior
3603 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
3604 (value_in_thread_stack_temporaries)
3605 (get_last_thread_stack_temporary): Take a thread pointer instead
3606 of a ptid_t. Adjust all callers.
3607 (thread_info::set_running): New.
3608 (validate_registers_access): Use inferior_thread.
3609 (can_access_registers_ptid): Rename to ...
3610 (can_access_registers_thread): ... this, and take a thread
3612 (print_thread_info_1): Adjust to compare thread pointers instead
3614 (switch_to_no_thread, switch_to_thread): Make extern.
3615 (scoped_restore_current_thread::~scoped_restore_current_thread):
3616 Use m_thread pointer directly.
3617 (scoped_restore_current_thread::scoped_restore_current_thread):
3618 Use inferior_thread.
3619 (thread_command): Use thread pointer directly.
3620 (thread_num_make_value_helper): Use inferior_thread.
3621 * top.c (execute_command): Use inferior_thread.
3622 * tui/tui-interp.c: Include "inferior.h".
3623 * varobj.c (varobj_create): Use inferior_thread.
3624 (value_of_root_1): Use find_thread_global_id instead of
3625 global_thread_id_to_ptid.
3627 2018-06-21 Alan Hayward <alan.hayward@arm.com>
3629 * regcache.c (readable_regcache::read_part): Avoid memcpy when
3631 (regcache::write_part): Likewise.
3632 (readable_regcache::cooked_read_part): Update comment.
3633 (readable_regcache::cooked_write_part): Likewise.
3634 * regcache.h: (readable_regcache::read_part): Likewise.
3635 (regcache::write_part): Likewise.
3637 2018-06-21 Richard Bunt <richard.bunt@arm.com>
3638 Dirk Schubert <dirk.schubert@arm.com>
3640 * aarch64-linux-nat.c (post_attach): New.
3641 (aarch64_linux_nat_target::post_attach): Override post_attach to
3642 record the number of hardware debug registers.
3644 2018-06-20 Tom Tromey <tom@tromey.com>
3646 * python/py-param.c (add_setshow_generic): Make parameters const.
3647 (parmpy_init): Update.
3649 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
3651 * regcache.h (regcache_cooked_read_ftype): Rename to...
3652 (register_read_ftype): ...this, change type to function_view.
3653 (class reg_buffer) <save>: Remove src parameter.
3654 (readonly_detached_regcache) <readonly_detached_regcache>: Make
3655 parameter non-const in first overload. Remove src parameter in
3657 * regcache.c (do_cooked_read): Remove.
3658 (readonly_detached_regcache::readonly_detached_regcache): Make
3659 parameter non-const, adjust call to other constructor.
3660 (reg_buffer::save): Remove src parameter.
3661 * frame.c (do_frame_register_read): Remove.
3662 (frame_save_as_regcache): Use lambda function.
3663 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
3664 parameter to ppu2spu_data *.
3665 (ppu2spu_sniffer): Use lambda function.
3667 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
3669 * record-full.c (record_full_target::insert_breakpoint): Remove
3670 "struct" keyword, add const.
3672 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
3674 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
3675 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
3676 * configure.ac: Remove AC_PREREQ, add missing quoting.
3677 * gnulib/configure.ac: Modernize usage of
3678 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
3679 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
3680 (AUTOMAKE_VERSION): Bump to 1.15.1.
3681 * configure: Re-generate.
3682 * config.in: Re-generate.
3683 * aclocal.m4: Re-generate.
3684 * gnulib/aclocal.m4: Re-generate.
3685 * gnulib/config.in: Re-generate.
3686 * gnulib/configure: Re-generate.
3687 * gnulib/import/Makefile.in: Re-generate.
3689 2018-06-19 Pedro Alves <palves@redhat.com>
3691 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
3692 (lookup_minimal_symbol_by_pc_section): ... here with
3693 gdb_assert_not_reached added.
3695 2018-06-19 Pedro Alves <palves@redhat.com>
3697 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
3698 parameter with a block parameter. Compare location's block symbol
3699 with the frame's block instead of addresses.
3700 (skip_inline_frames): Pass the current block instead of the
3701 frame's address. Break out as soon as we determine the frame
3702 should not be skipped.
3704 2018-06-18 Tom Tromey <tom@tromey.com>
3706 * solib-aix.c (solib_aix_get_section_offsets): Return
3708 (solib_aix_solib_create_inferior_hook): Update.
3710 2018-06-18 Tom Tromey <tom@tromey.com>
3712 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
3714 2018-06-18 Tom Tromey <tom@tromey.com>
3716 * solib-frv.c (frv_relocate_main_executable): Use
3718 * solib-dsbt.c (dsbt_relocate_main_executable): Use
3721 2018-06-18 Tom Tromey <tom@tromey.com>
3723 * objfiles.h (inhibit_section_map_updates): Update.
3724 (resume_section_map_updates, resume_section_map_updates_cleanup):
3726 * solib-svr4.c (svr4_handle_solib_event): Update.
3727 * objfiles.c (inhibit_section_map_updates): Return
3728 scoped_restore_tmpl<int>.
3729 (resume_section_map_updates, resume_section_map_updates_cleanup):
3732 2018-06-18 Tom Tromey <tom@tromey.com>
3734 * valprint.h (read_string): Update.
3735 * valprint.c (read_string): Change type of "buffer".
3736 (val_print_string): Update.
3737 * python/py-value.c (valpy_string): Update.
3738 * language.h (struct language_defn) <la_get_string>: Change
3740 (default_get_string, c_get_string): Update.
3741 * language.c (default_get_string): Change type of "buffer".
3742 * guile/scm-value.c (gdbscm_value_to_string): Update.
3743 * c-lang.c (c_get_string): Change type of "buffer".
3745 2018-06-18 Tom Tromey <tom@tromey.com>
3747 * ser-mingw.c (struct pipe_state_destroyer): New.
3748 (pipe_state_up): New typedef.
3749 (cleanup_pipe_state): Remove.
3750 (pipe_windows_open): Use pipe_state_up. Don't release argv.
3752 2018-06-18 Tom Tromey <tom@tromey.com>
3754 * rust-lang.h (rust_yyerror): Don't declare.
3755 * rust-lang.c (rust_language_defn): Update.
3756 * rust-exp.y (yyerror): Now static.
3757 * parse.c (parse_exp_in_context_1): Update.
3758 * p-lang.h (p_yyerror): Don't declare.
3759 * p-lang.c (p_language_defn): Update.
3760 * p-exp.y (yyerror): Now static.
3761 * opencl-lang.c (opencl_language_defn): Update.
3762 * objc-lang.c (objc_language_defn): Update.
3763 * m2-lang.h (m2_yyerror): Don't declare.
3764 * m2-lang.c (m2_language_defn): Update.
3765 * m2-exp.y (yyerror): Now static.
3766 * language.h (struct language_defn) <la_error>: Remove.
3767 * language.c (unk_lang_error): Remove.
3768 (unknown_language_defn, auto_language_defn): Remove.
3769 * go-lang.h (go_yyerror): Don't declare.
3770 * go-lang.c (go_language_defn): Update.
3771 * go-exp.y (yyerror): Now static.
3772 * f-lang.h (f_yyerror): Don't declare.
3773 * f-lang.c (f_language_defn): Update.
3774 * f-exp.y (yyerror): Now static.
3775 * d-lang.h (d_yyerror): Don't declare.
3776 * d-lang.c (d_language_defn): Update.
3777 * d-exp.y (yyerror): Now static.
3778 * c-lang.h (c_yyerror): Don't declare.
3779 * c-lang.c (c_language_defn, cplus_language_defn)
3780 (asm_language_defn, minimal_language_defn): Update.
3781 * c-exp.y (yyerror): Now static.
3782 * ada-lang.h (ada_yyerror): Don't declare.
3783 * ada-lang.c (ada_language_defn): Update.
3784 * ada-exp.y (yyerror): Now static.
3786 2018-06-18 Alan Hayward <alan.hayward@arm.com>
3788 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
3789 (store_sveregs_to_thread): Likewise.
3790 (aarch64_linux_fetch_inferior_registers): Check for SVE.
3791 (aarch64_linux_store_inferior_registers): Likewise.
3792 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
3794 (aarch64_sve_regs_copy_to_regcache): Likewise.
3795 (aarch64_sve_regs_copy_from_regcache): Likewise.
3796 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
3798 (aarch64_sve_regs_copy_to_regcache): Likewise.
3799 (aarch64_sve_regs_copy_from_regcache): Likewise.
3800 (sve_context): Structure from Linux headers.
3801 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
3802 (SVE_SIG_ZREG_SIZE): Likewise.
3803 (SVE_SIG_PREG_SIZE): Likewise.
3804 (SVE_SIG_FFR_SIZE): Likewise.
3805 (SVE_SIG_REGS_OFFSET): Likewise.
3806 (SVE_SIG_ZREGS_OFFSET): Likewise.
3807 (SVE_SIG_ZREG_OFFSET): Likewise.
3808 (SVE_SIG_ZREGS_SIZE): Likewise.
3809 (SVE_SIG_PREGS_OFFSET): Likewise.
3810 (SVE_SIG_PREG_OFFSET): Likewise.
3811 (SVE_SIG_PREGS_SIZE): Likewise.
3812 (SVE_SIG_FFR_OFFSET): Likewise.
3813 (SVE_SIG_REGS_SIZE): Likewise.
3814 (SVE_SIG_CONTEXT_SIZE): Likewise.
3815 (SVE_PT_REGS_MASK): Likewise.
3816 (SVE_PT_REGS_FPSIMD): Likewise.
3817 (SVE_PT_REGS_SVE): Likewise.
3818 (SVE_PT_VL_INHERIT): Likewise.
3819 (SVE_PT_VL_ONEXEC): Likewise.
3820 (SVE_PT_REGS_OFFSET): Likewise.
3821 (SVE_PT_FPSIMD_OFFSET): Likewise.
3822 (SVE_PT_FPSIMD_SIZE): Likewise.
3823 (SVE_PT_SVE_ZREG_SIZE): Likewise.
3824 (SVE_PT_SVE_PREG_SIZE): Likewise.
3825 (SVE_PT_SVE_FFR_SIZE): Likewise.
3826 (SVE_PT_SVE_FPSR_SIZE): Likewise.
3827 (SVE_PT_SVE_FPCR_SIZE): Likewise.
3828 (__SVE_SIG_TO_PT): Likewise.
3829 (SVE_PT_SVE_OFFSET): Likewise.
3830 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
3831 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
3832 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
3833 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
3834 (SVE_PT_SVE_PREG_OFFSET): Likewise.
3835 (SVE_PT_SVE_PREGS_SIZE): Likewise.
3836 (SVE_PT_SVE_FFR_OFFSET): Likewise.
3837 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
3838 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
3839 (SVE_PT_SVE_SIZE): Likewise.
3840 (SVE_PT_SIZE): Likewise.
3841 (HAS_SVE_STATE): New define.
3843 2018-06-18 Alan Hayward <alan.hayward@arm.com>
3845 * nat/aarch64-sve-linux-sigcontext.h: New file.
3846 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
3848 (SVE_VQ_MIN): Likewise.
3849 (SVE_VQ_MAX): Likewise.
3850 (SVE_VL_MIN): Likewise.
3851 (SVE_VL_MAX): Likewise.
3852 (SVE_NUM_ZREGS): Likewise.
3853 (SVE_NUM_PREGS): Likewise.
3854 (sve_vl_valid): Likewise.
3855 (struct user_sve_header): Likewise.
3857 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
3858 Richard Bunt <Richard.Bunt@arm.com>
3860 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
3861 was requested by GDB.
3863 2018-06-15 Tom de Vries <tdevries@suse.de>
3865 * MAINTAINERS (Write After Approval): Add Tom de Vries.
3867 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
3869 * gnulib/update-gnulib.sh: Print expected versions of
3872 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
3874 * arch-utils.c (default_type_align): Use type_length_units.
3875 * gdbtypes.c (type_align): Use type_length_units.
3877 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3879 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
3880 of 'define' command.
3882 2018-06-14 Tom de Vries <tdevries@suse.de>
3885 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
3886 get_no_prettyformat_print_options.
3888 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
3890 * sparc-nat.h: Include target.h.
3891 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
3892 <fetch_registers>: Remove this argument in function call.
3893 <store_registers>: Remove this argument in function call, remove
3895 <low_forget_process>: Call sparc64_forget_process instead of
3896 sparc_forget_process.
3898 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3900 * procfs.c (_initialize_procfs): Use add_inf_child_target.
3901 (procfs_target::make_corefile_notes): Adjust to new
3902 target_read_alloc return type.
3904 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3905 Stephen Roberts <stephen.roberts@arm.com>
3908 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
3909 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
3910 Move should_notify_stop local into more inner scope.
3912 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3913 Stephen Roberts <stephen.roberts@arm.com>
3916 * infrun.c (resume_1): Add call to mark_async_event_handler.
3918 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3920 * infrun.c (do_target_wait): Change old version of $pc printed.
3922 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
3924 * dwarf2read.c (read_index_from_section): Rename to...
3925 (read_gdb_index_from_section): ... this, update all callers.
3926 (dwarf2_read_index): Rename to...
3927 (dwarf2_read_gdb_index): ... this, update all callers.
3929 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
3931 * gdb/hppa-linux-nat.c
3932 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
3933 hppa_linux_nat_target::fetch_registers.
3935 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3937 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
3938 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
3939 (AARCH64_DWARF_SVE_FFR): Likewise.
3940 (AARCH64_DWARF_SVE_P0): Likewise.
3941 (AARCH64_DWARF_SVE_Z0): Likewise.
3943 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3945 * common/common-regcache.h (raw_compare): New function.
3946 * regcache.c (regcache::raw_compare): Likewise.
3947 * regcache.h (regcache::raw_compare): New declaration.
3949 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3951 * common/common-regcache.h (reg_buffer_common): New structure.
3952 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
3953 (reg_buffer::raw_supply): Likewise.
3954 (reg_buffer::raw_supply_integer): Likewise.
3955 (reg_buffer::raw_supply_zeroed): Likewise.
3956 (reg_buffer::raw_collect): Likewise.
3957 (reg_buffer::raw_collect_integer): Likewise.
3958 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
3959 (reg_buffer::raw_supply): Likewise.
3960 (reg_buffer::raw_supply_integer): Likewise.
3961 (reg_buffer::raw_supply_zeroed): Likewise.
3962 (reg_buffer::raw_collect): Likewise.
3963 (reg_buffer::raw_collect_integer): Likewise.
3965 2018-06-10 Tom Tromey <tom@tromey.com>
3967 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
3968 (class remote_state) <stop_reply_queue>: Now std::vector.
3969 (remote_state::~remote_state)
3970 (remote_target::stop_reply_queue_length): Update.
3971 (struct queue_iter_param, remove_child_of_pending_fork)
3972 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
3973 (check_pending_event_prevents_wildcard_vcont_callback)
3974 (remove_stop_reply_for_inferior)
3975 (remove_stop_reply_of_remote_state)
3976 (remote_notif_remove_once_on_match)
3977 (stop_reply_match_ptid_and_ws)
3978 (remote_kill_child_of_pending_fork): Remove.
3979 (remote_target::remove_new_fork_children)
3980 (remote_target::check_pending_events_prevent_wildcard_vcont)
3981 (remote_target::discard_pending_stop_replies)
3982 (remote_target::discard_pending_stop_replies_in_queue)
3983 (remote_target::remote_notif_remove_queued_reply)
3984 (remote_target::queued_stop_reply)
3985 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
3986 (remote_target::wait, remote_target::kill_new_fork_children)
3987 (remote_target::async): Update.
3989 2018-06-10 Tom Tromey <tom@tromey.com>
3991 * record-full.c (record_full_arch_list_cleanups): Remove.
3992 (record_full_message): Use try/catch.
3993 (record_full_wait_cleanups): Remove.
3994 (record_full_wait_1): Use try/catch.
3995 (record_full_restore): Likewise.
3997 2018-06-10 Tom Tromey <tom@tromey.com>
3999 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
4000 declare VEC. Add constructor.
4001 <in_target_beneath>: Now bool.
4002 (record_full_breakpoints): Now a std::vector, static.
4003 (record_full_sync_record_breakpoints)
4004 (record_full_init_record_breakpoints)
4005 (record_full_target::insert_breakpoint)
4006 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
4008 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
4010 * dwarf2read.c (process_cu_includes): Remove struct keyword.
4011 * serial.c (serial_interface_lookup): Remove struct keyword.
4013 2018-06-10 Tom Tromey <tom@tromey.com>
4015 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
4017 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
4019 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
4021 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
4022 "beneath" as a method.
4023 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
4024 Use "beneath" as a method.
4026 2018-06-10 Tom Tromey <tom@tromey.com>
4028 * tracefile.c (struct trace_file_writer_deleter): New.
4029 <operator()>: Rename from trace_file_writer_xfree.
4030 (trace_file_writer_up): New typedef.
4031 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
4033 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
4035 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
4036 <m_registers, m_register_status>: Change type to
4038 * regcache.c (reg_buffer::reg_buffer): Use new instead of
4041 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
4043 * common/common-regcache.h (enum register_status): Add
4044 underlying type "signed char".
4045 * regcache.h (reg_buffer) <m_register_status>: Change type to
4047 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
4048 register_status instead of signed char.
4049 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
4050 (reg_buffer::get_register_status): Remove cast.
4051 (readable_regcache::raw_read): Remove cast.
4052 (readable_regcache::cooked_read): Remove cast.
4054 2018-06-09 Tom Tromey <tom@tromey.com>
4056 * source.c (reverse_search_command, forward_search_command): Use
4059 2018-06-09 Tom Tromey <tom@tromey.com>
4061 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
4062 (serial_ops_list): Now static, std::vector.
4063 (serial_interface_lookup, serial_add_interface): Update.
4065 2018-06-09 Tom Tromey <tom@tromey.com>
4067 * dwarf2read.c (process_cu_includes): Update.
4068 (process_full_comp_unit): Update.
4069 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
4072 2018-06-08 Paul Koning <paul_koning@dell.com>
4076 * python/python.c (do_start_initialization):
4077 Avoid call to internal Python API.
4078 (init__gdb_module): New function.
4080 2018-06-08 Gary Benson <gbenson@redhat.com>
4082 * linux-thread-db.c (valprint.h): New include.
4083 (struct check_thread_db_info): New structure.
4084 (check_thread_db_on_load, tdb_testinfo): New static globals.
4085 (check_thread_db, check_thread_db_callback): New functions.
4086 (try_thread_db_load_1): Run integrity checks if requested.
4087 (maintenance_check_libthread_db): New function.
4088 (_initialize_thread_db): Register "maint check libthread-db"
4089 and "maint set/show check-libthread-db".
4090 * NEWS: Mention the above new commands.
4092 2018-06-08 Tom Tromey <tom@tromey.com>
4094 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
4097 2018-06-08 Tom Tromey <tom@tromey.com>
4099 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
4101 2018-06-08 Tom Tromey <tom@tromey.com>
4103 * common/btrace-common.h (struct btrace_data): Add constructor,
4104 destructor, move assignment operator.
4105 <empty, clear, fini>: New methods.
4106 <format>: Initialize.
4107 (btrace_data_init, btrace_data_fini, btrace_data_clear)
4108 (btrace_data_empty): Don't declare.
4109 * common/btrace-common.c (btrace_data_init): Remove.
4110 (btrace_data::fini): Rename from btrace_data_fini.
4111 (btrace_data::empty): Rename from btrace_data_empty.
4112 (btrace_data::clear): Rename from btrace_data_clear. Return
4114 * btrace.h (make_cleanup_btrace_data): Don't declare.
4115 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
4116 (parse_xml_btrace): Update.
4117 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
4118 (maint_btrace_clear_packet_history_cmd): Update.
4120 2018-06-07 Pedro Alves <palves@redhat.com>
4122 * target.h (target_ops) <beneath>: Now a method. All references
4124 (class target_stack): New.
4125 * target.c (g_target_stack): New.
4126 (g_current_top_target): Delete.
4127 (current_top_target): Get the top target out of g_target_stack.
4128 (target_stack::push, target_stack::unpush): New.
4129 (push_target, unpush_target): Reimplement.
4130 (target_is_pushed): Reimplement in terms of g_target_stack.
4131 (target_ops::beneath, target_stack::find_beneath): New.
4133 2018-06-07 Pedro Alves <palves@redhat.com>
4135 * target.h (find_target_beneath): Delete declaration.
4136 * target.c (find_target_beneath): Delete definition.
4137 * aix-thread.c: All callers of find_target_beneath adjusted to
4138 call target_ops::beneath instead.
4139 * bsd-uthread.c: Likewise.
4140 * linux-thread-db.c: Likewise.
4141 * ravenscar-thread.c: Likewise.
4142 * sol-thread.c: Likewise.
4143 * spu-multiarch.c: Likewise.
4145 2018-06-07 Pedro Alves <palves@redhat.com>
4147 * target.h (target_ops) <beneath>: Now a method. All references
4149 (target_ops) <m_beneath>: New.
4150 * target.c (target_ops::beneath): New.
4151 * corelow.c: Adjust all references to target_ops::beneath.
4152 * linux-thread-db.c: Likewise.
4153 * make-target-delegates: Likewise.
4154 * record-btrace.c: Likewise.
4155 * record-full.c: Likewise.
4156 * remote.c: Likewise.
4157 * target.c: Likewise.
4158 * target-delegates.c: Regenerate.
4160 2018-06-07 Pedro Alves <palves@redhat.com>
4162 * target.h (target_stack): Delete.
4163 (current_top_target): Declare function.
4164 * target.c (target_stack): Delete.
4165 (g_current_top_target): New.
4166 (current_top_target): New function.
4167 * auxv.c: Use current_top_target instead of target_stack
4169 * avr-tdep.c: Likewise.
4170 * breakpoint.c: Likewise.
4171 * corefile.c: Likewise.
4172 * elfread.c: Likewise.
4174 * exceptions.c: Likewise.
4175 * frame.c: Likewise.
4176 * gdbarch-selftests.c: Likewise.
4177 * gnu-v3-abi.c: Likewise.
4178 * ia64-tdep.c: Likewise.
4179 * ia64-vms-tdep.c: Likewise.
4180 * infcall.c: Likewise.
4181 * infcmd.c: Likewise.
4182 * infrun.c: Likewise.
4183 * linespec.c: Likewise.
4184 * linux-tdep.c: Likewise.
4185 * minsyms.c: Likewise.
4186 * ppc-linux-nat.c: Likewise.
4187 * ppc-linux-tdep.c: Likewise.
4188 * procfs.c: Likewise.
4189 * regcache.c: Likewise.
4190 * remote.c: Likewise.
4191 * rs6000-tdep.c: Likewise.
4192 * s390-linux-nat.c: Likewise.
4193 * s390-tdep.c: Likewise.
4194 * solib-aix.c: Likewise.
4195 * solib-darwin.c: Likewise.
4196 * solib-dsbt.c: Likewise.
4197 * solib-spu.c: Likewise.
4198 * solib-svr4.c: Likewise.
4199 * solib-target.c: Likewise.
4200 * sparc-tdep.c: Likewise.
4201 * sparc64-tdep.c: Likewise.
4202 * spu-tdep.c: Likewise.
4203 * symfile.c: Likewise.
4204 * symtab.c: Likewise.
4205 * target-descriptions.c: Likewise.
4206 * target-memory.c: Likewise.
4207 * target.c: Likewise.
4208 * target.h: Likewise.
4209 * tracefile-tfile.c: Likewise.
4210 * tracepoint.c: Likewise.
4211 * valops.c: Likewise.
4212 * valprint.c: Likewise.
4213 * value.c: Likewise.
4214 * windows-tdep.c: Likewise.
4215 * mi/mi-main.c: Likewise.
4217 2018-06-07 Tom Tromey <tom@tromey.com>
4219 * valprint.h (build_address_symbolic): Declare.
4220 * printcmd.c (print_address_symbolic): Update.
4221 (build_address_symbolic): Change "name" and "filename" to
4223 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
4225 * defs.h (build_address_symbolic): Remove declaration.
4227 2018-06-07 Alan Hayward <alan.hayward@arm.com>
4229 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
4230 (aarch64_vnv_type): Add function.
4231 (aarch64_pseudo_register_name): Add V regs for SVE.
4232 (aarch64_pseudo_register_type): Likewise.
4233 (aarch64_pseudo_register_reggroup_p): Likewise.
4234 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
4235 (aarch64_pseudo_read_value): Add V regs for SVE.
4236 (aarch64_pseudo_write_2): Use V0 offset for SVE
4237 (aarch64_pseudo_write): Add V regs for SVE.
4238 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
4240 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
4242 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
4243 (sve_vl_from_vq): Likewise.
4245 2018-06-05 Tom Tromey <tom@tromey.com>
4247 * cli/cli-cmds.c (show_version): Update.
4248 * top.c (print_gdb_version): Add "interactive" parameter.
4250 * main.c (captured_main_1): Update.
4251 * top.h (print_gdb_version): Add "interactive" parameter and a
4254 2018-06-05 David Malcolm <dmalcolm@redhat.com>
4256 * common/enum-flags.h: Add trailing semicolon to example in
4259 2018-06-05 Tom Tromey <tom@tromey.com>
4262 * NEWS: Add entry about pager.
4263 * utils.c (pagination_disabled_for_command): New global.
4264 (prompt_for_continue): Allow "c" response to prompt.
4265 (reinitialize_more_filter): Clear
4266 pagination_disabled_for_command.
4267 (fputs_maybe_filtered): Check pagination_disabled_for_command.
4269 2018-06-04 Tom Tromey <tom@tromey.com>
4271 * ada-lang.h (ada_lookup_symbol_list): Update.
4272 * ada-lang.c (resolve_subexp): Update.
4273 (symbols_are_identical_enums): Change type of syms. Remove nsyms
4275 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
4276 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
4277 results parameter to std::vector.
4278 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
4280 * ada-exp.y (block_lookup): Update.
4281 (select_possible_type_sym): Change type of syms. Remove nsyms
4283 (write_var_or_type, write_name_assoc): Update.
4285 2018-06-04 Joel Brobecker <brobecker@adacore.com>
4287 * windows-nat.c (windows_nat_target::xfer_partial): Return
4288 TARGET_XFER_E_IO if we need to delegate to the target beneath
4289 but BENEATH is NULL.
4291 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
4293 * Makefile.in (config.status): Add configure.nat as a
4296 2018-06-04 Tom Tromey <tom@tromey.com>
4298 * cp-name-parser.y (cpname_state): Add method declarations.
4299 (HANDLE_QUAL): Update.
4300 (cpname_state::d_grab, cpname_state::fill_comp)
4301 (cpname_state::make_operator, cpname_state::make_dtor)
4302 (cpname_state::make_builtin_type, cpname_state::make_name)
4303 (cpname_state::d_qualify, cpname_state::d_int_type)
4304 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
4305 (%union): Move earlier.
4307 2018-06-04 Alan Hayward <alan.hayward@arm.com>
4309 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
4311 2018-06-04 Alan Hayward <alan.hayward@arm.com>
4313 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
4314 (aarch64_pseudo_write_1): Likewise.
4315 (aarch64_pseudo_read_value): Use helper.
4316 (aarch64_pseudo_write): Likewise.
4318 2018-06-04 Pedro Alves <palves@redhat.com>
4320 * darwin-nat.c (darwin_ops): Delete.
4321 (darwin_attach_pid): Use get_native_target.
4323 2018-06-04 Alan Hayward <alan.hayward@arm.com>
4325 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
4326 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
4328 2018-06-04 Alan Hayward <alan.hayward@arm.com>
4330 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
4331 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
4332 (aarch64_gdbarch_init): Check for SVE.
4333 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
4335 2018-06-04 Alan Hayward <alan.hayward@arm.com>
4337 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
4338 * aarch64-tdep.h (aarch64_read_description): Likewise.
4339 * arch/aarch64.c (aarch64_create_target_description): Likewise.
4340 * arch/aarch64.h (aarch64_create_target_description): Likewise.
4341 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
4342 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
4343 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
4345 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
4347 * value.c (value_fetch_lazy_bitfield): New.
4348 (value_fetch_lazy_memory): New.
4349 (value_fetch_lazy_register): New.
4350 (value_fetch_lazy): Factor out to smaller functions.
4352 2018-06-01 Tom Tromey <tom@tromey.com>
4354 * cp-name-parser.y (backslashable, represented): Now const.
4356 2018-06-01 Tom Tromey <tom@tromey.com>
4358 * cp-name-parser.y: Include parser-defs.h.
4359 (parser_fprintf): Remove declaration.
4361 2018-06-01 Tom Tromey <tom@tromey.com>
4363 * cp-name-parser.y: Use %pure-parser, %lex-param, and
4365 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
4366 (global_result): Remove globals.
4367 (struct cpname_state): New.
4368 (yyparse): Don't declare.
4369 (yylex, yyerror): Move declarations after %union.
4370 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
4371 (make_name): Add state parameter.
4373 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
4375 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
4377 (yylex): Add lvalp, state parameters.
4378 (yyerror): Add state parameter.
4379 (cp_demangled_name_to_comp): Update.
4381 2018-06-01 Tom Tromey <tom@tromey.com>
4383 * cp-name-parser.y (parser_fprintf): Declare.
4384 (GDB_YY_REMAP_PREFIX): Define.
4385 Include yy-remap.h. Don't redefine yy* identifiers.
4387 2018-06-01 Tom Tromey <tom@tromey.com>
4389 * python/py-type.c (typy_legacy_template_argument): Update.
4390 * cp-support.h (cp_demangled_name_to_comp): Update.
4391 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
4392 parameter to be a "std::string *".
4395 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
4397 * ada-lex.l: Include "diagnostics.h" instead of
4398 "common/diagnostics.h".
4399 * unittests/environ-selftests.c: Likewise.
4400 * common/diagnostics.h: Moved to ../include.
4402 2018-06-01 Joel Brobecker <brobecker@adacore.com>
4404 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
4405 to language_mode_manual while calling breakpoint_re_set_one.
4407 2018-06-01 Tom Tromey <tom@tromey.com>
4409 * valops.c (value_cast_structs, destructor_name_p): Update.
4410 * symtab.c (gdb_mangle_name): Update.
4411 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
4413 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
4414 (pascal_object_print_value_fields, pascal_object_print_value):
4416 * p-typeprint.c (pascal_type_print_derivation_info): Update.
4417 * linespec.c (find_methods): Update.
4418 * gdbtypes.h (type_name_no_tag): Remove.
4419 (type_name_or_error): Rename from type_name_no_tag_or_error.
4420 * gdbtypes.c (type_name_no_tag): Remove.
4421 (type_name_or_error): Rename from type_name_no_tag_or_error.
4422 (lookup_struct_elt_type, check_typedef): Update.
4423 * expprint.c (print_subexp_standard): Update.
4424 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
4425 * d-namespace.c (d_lookup_nested_symbol): Update.
4426 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
4427 (cp_print_class_member): Update.
4428 * cp-namespace.c (cp_lookup_nested_symbol): Update.
4429 * completer.c (add_struct_fields): Update.
4430 * c-typeprint.c (cp_type_print_derivation_info)
4431 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
4433 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
4434 (ada_prefer_type, ada_is_exception_sym): Update.
4436 2018-06-01 Tom Tromey <tom@tromey.com>
4438 * valops.c (enum_constant_from_type, value_namespace_elt)
4439 (value_maybe_namespace_elt): Update.
4440 * valarith.c (find_size_for_pointer_math): Update.
4441 * target-descriptions.c (make_gdb_type): Update.
4442 * symmisc.c (print_symbol): Update.
4443 * stabsread.c (define_symbol, read_type)
4444 (complain_about_struct_wipeout, add_undefined_type)
4445 (cleanup_undefined_types_1): Update.
4446 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
4447 (rust_range_type_p, val_print_struct, rust_print_struct_def)
4448 (rust_internal_print_type, rust_composite_type)
4449 (rust_evaluate_funcall, rust_evaluate_subexp)
4450 (rust_inclusive_range_type_p): Update.
4451 * python/py-type.c (typy_get_tag): Update.
4452 * p-typeprint.c (pascal_type_print_base): Update.
4453 * mdebugread.c (parse_symbol, parse_type): Update.
4454 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
4456 * guile/scm-type.c (gdbscm_type_tag): Update.
4457 * go-lang.c (sixg_string_p): Update.
4458 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
4460 * gdbtypes.h (struct main_type) <tag_name>: Remove.
4461 (TYPE_TAG_NAME): Remove.
4462 * gdbtypes.c (type_name_no_tag): Simplify.
4463 (check_typedef, check_types_equal, recursive_dump_type)
4464 (copy_type_recursive, arch_composite_type): Update.
4465 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
4466 in summary mode when needed.
4467 * eval.c (evaluate_funcall): Update.
4468 * dwarf2read.c (fixup_go_packaging, read_structure_type)
4469 (process_structure_scope, read_enumeration_type)
4470 (read_namespace_type, read_module_type, determine_prefix): Update.
4471 * cp-support.c (inspect_type): Update.
4472 * coffread.c (process_coff_symbol, decode_base_type): Update.
4473 * c-varobj.c (c_is_path_expr_parent): Update.
4474 * c-typeprint.c (c_type_print_base_struct_union): Update.
4475 (c_type_print_base_1): Update. Print struct/class/union/enum in
4476 summary when using C language.
4477 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
4478 (gen_maybe_namespace_elt): Update.
4479 * ada-lang.c (ada_type_name): Simplify.
4480 (empty_record, ada_template_to_fixed_record_type_1)
4481 (template_to_static_fixed_type)
4482 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
4484 2018-06-01 Tom Tromey <tom@tromey.com>
4486 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
4488 * c-typeprint.c (c_print_type_1): Add "language" parameter.
4489 (c_print_type): Update.
4490 (c_print_type): New overload.
4491 (c_type_print_varspec_prefix, c_type_print_args)
4492 (c_type_print_varspec_suffix, c_print_type_no_offsets)
4493 (c_type_print_base_struct_union, c_type_print_base_1)
4494 (cp_type_print_method_args): Add "language" parameter.
4495 (c_type_print_base): Update.
4496 * c-lang.h (c_print_type): Add new overload.
4498 2018-06-01 Tom Tromey <tom@tromey.com>
4500 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
4501 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
4503 2018-06-01 Alan Hayward <alan.hayward@arm.com>
4505 * aarch64-tdep.c (aarch64_sve_register_names): New const
4507 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
4508 (AARCH64_SVE_Z_REGS_NUM): New define.
4509 (AARCH64_SVE_P_REGS_NUM): Likewise.
4510 (AARCH64_SVE_NUM_REGS): Likewise.
4512 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
4514 * nat/linux-ptrace.h [__alpha__]
4515 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
4518 2018-05-31 Maciej W. Rozycki <macro@mips.com>
4520 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
4521 the endianness selected.
4522 * NEWS: Document `set endian auto' mode operation update.
4524 2018-05-31 Alan Hayward <alan.hayward@arm.com>
4526 * Makefile.in: Add new header.
4527 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
4528 (sve_vl_from_vg): Likewise.
4529 (sve_vq_from_vl): Likewise.
4530 (sve_vl_from_vq): Likewise.
4531 (sve_vq_from_vg): Likewise.
4532 (sve_vg_from_vq): Likewise.
4533 * configure.nat: Add new c file.
4534 * nat/aarch64-sve-linux-ptrace.c: New file.
4535 * nat/aarch64-sve-linux-ptrace.h: New file.
4537 2018-05-31 Alan Hayward <alan.hayward@arm.com>
4539 * aarch64-linux-nat.c (aarch64_linux_read_description):
4541 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
4543 * aarch64-tdep.c (tdesc_aarch64_list): Add.
4544 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
4545 (aarch64_gdbarch_init): Add parmeter zero.
4546 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
4547 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
4548 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
4550 * doc/gdb.texinfo: Describe SVE feature
4551 * features/aarch64-sve.c: New file.
4553 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
4556 * gdbarch.sh (significant_addr_bit): Default to zero when
4557 not set by target architecture.
4558 * gdbarch.c: Re-generated.
4559 * utils.c (address_significant): Update.
4561 2018-05-30 Joel Brobecker <brobecker@adacore.com>
4563 * stack.c (func_command): Remove trailing newline in call to error.
4565 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4567 * regcache.h (regcache_raw_collect): Remove, update callers to
4568 use regcache::raw_collect.
4569 * regcache.c (regcache_raw_collect): Remove.
4571 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4573 * regcache.h (regcache_raw_supply): Remove, update callers to
4574 use detached_regcache::raw_supply.
4575 * regcache.c (regcache_raw_supply): Remove.
4577 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4579 * regcache.h (regcache_cooked_write_part): Remove, update
4580 callers to use regcache::cooked_write_part.
4581 * regcache.c (regcache_cooked_write_part): Remove.
4583 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4585 * regcache.h (regcache_cooked_read_part): Remove, update callers
4586 to use readable_regcache::cooked_read_part.
4587 * regcache.c (regcache_cooked_read_part): Remove.
4589 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4591 * regcache.h (regcache_cooked_read_value): Remove, update
4592 callers to use readable_regcache::cooked_read_value.
4593 * regcache.c (regcache_cooked_read_value): Remove.
4595 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4597 * regcache.h (regcache_cooked_write): Remove, update callers to
4598 use regcache::cooked_write.
4599 * regcache.c (regcache_cooked_write): Remove.
4601 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4603 * regcache.h (regcache_invalidate): Remove, update callers to
4604 use detached_regcache::invalidate instead.
4605 * regcache.c (regcache_invalidate): Remove.
4607 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4609 * regcache.h (regcache_raw_write_part): Remove, update callers
4610 to use regcache::raw_write_part instead.
4611 * regcache.c (regcache_raw_write_part): Remove.
4613 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4615 * regcache.h (regcache_raw_read_part): Remove, update callers to
4616 use readable_regcache::raw_read_part instead.
4617 * regcache.c (regcache_raw_read_part): Remove.
4619 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4621 * regcache.h (regcache_cooked_read): Remove, update callers to
4622 use readable_regcache::cooked_read instead.
4623 * regcache.c (regcache_cooked_read): Remove.
4625 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4627 * regcache.h (regcache_raw_write): Remove, update callers to use
4628 regcache::raw_write instead.
4629 * regcache.c (regcache_raw_write): Remove.
4631 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4633 * regcache.h (regcache_raw_read): Remove, update callers to use
4634 readable_regcache::raw_read instead.
4635 * regcache.c (regcache_raw_read): Remove.
4637 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4639 * regcache.h (regcache_raw_update): Remove, update callers to
4640 use readable_regcache::raw_update instead.
4641 * regcache.c (regcache_raw_update): Remove.
4643 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4645 * regcache.h (regcache_register_status): Remove, update callers
4646 to use reg_buffer::get_register_status directly instead.
4647 * regcache.c (regcache_register_status): Remove.
4649 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4651 * regcache.h (regcache_get_ptid): Remove, update all callers to
4652 call regcache::ptid instead.
4653 * regcache.c (regcache_get_ptid): Remove.
4655 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4657 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
4659 2018-05-30 Pedro Alves <palves@redhat.com>
4661 * common/common-exceptions.h (exception_rethrow): Use
4664 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
4666 * breakpoint.c (print_solib_event, check_status_catch_solib):
4667 Remove struct keyword in range-based for loops.
4668 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
4669 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
4671 * linespec.c (find_superclass_methods, search_minsyms_for_name):
4673 * symfile.c (addr_info_make_relative): Likewise.
4674 * thread.c (value_in_thread_stack_temporaries): Likewise.
4676 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
4679 * valops.c (value_struct_elt_for_reference): Call check_typedef on
4680 aggregate type to get its real type before accessing it.
4682 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
4684 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
4685 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
4686 * coff-pe-read.c (add_pe_forwarded_sym): Replace
4687 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
4688 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
4689 * jit.c (jit_breakpoint_re_set_internal): Likewise.
4690 * printcmd.c (info_address_command): Likewise.
4692 2018-05-29 Tom Tromey <tom@tromey.com>
4694 * windows-nat.c (handle_exception): Update fall-through comment.
4696 2018-05-29 Tom Tromey <tom@tromey.com>
4698 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
4699 (struct program_space) <added_solibs>: Now a std::vector.
4700 * breakpoint.c (print_solib_event): Update.
4701 (check_status_catch_solib): Update.
4702 * progspace.c (clear_program_space_solib_cache): Update.
4703 * solib.c (update_solib_list): Update.
4705 2018-05-29 Tom Tromey <tom@tromey.com>
4707 * python/py-type.c (typy_richcompare): Update.
4708 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
4709 * gdbtypes.h (types_deeply_equal): Return bool.
4710 (types_equal): Likewise.
4711 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
4713 (check_types_equal): Change worklist to std::vector. Return
4715 (struct type_equality_entry): Add constructor.
4716 (compare_maybe_null_strings): Return bool.
4717 (check_types_worklist): Return bool. Change worklist to
4719 (types_deeply_equal): Use std::vector.
4720 (types_equal): Return bool.
4721 (compare_maybe_null_strings): Simplify.
4723 2018-05-29 Tom Tromey <tom@tromey.com>
4725 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
4727 2018-05-29 Tom Tromey <tom@tromey.com>
4729 * objc-lang.h: Don't include cp-support.h.
4730 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
4733 2018-05-27 Tom Tromey <tom@tromey.com>
4735 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
4737 2018-05-25 Tom Tromey <tom@tromey.com>
4739 * value.c (value::location): Initialize.
4741 2018-05-25 Tom Tromey <tom@tromey.com>
4743 * dbxread.c (init_bincl_list): Remove.
4744 (bincl_list): Now a std::vector.
4745 (bincls_allocated, next_bincl): Remove.
4746 (free_bincl_list, do_free_bincl_list_cleanup)
4747 (make_cleanup_free_bincl_list): Remove.
4748 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
4750 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
4751 (struct header_file_location): Add constructor.
4752 (add_bincl_to_list): Remove.
4754 2018-05-25 Tom Tromey <tom@tromey.com>
4756 * tui/tui.c (tui_enable): Update.
4757 * mi/mi-interp.c (mi_interp::init): Update.
4758 * interps.h (class interp) <name>: New method.
4759 <m_name>: Rename from name.
4760 (~scoped_restore_interp): Update.
4761 * interps.c (interp::interp): Update.
4762 (interp_add, interp_set, interp_lookup_existing)
4763 (current_interp_named_p): Update.
4765 2018-05-25 Tom Tromey <tom@tromey.com>
4767 * interps.c (interp_name): Remove.
4768 * mi/mi-interp.c (mi_interp::init): Update.
4769 * interps.h (interp_name): Remove.
4770 (~scoped_restore_interp): Update.
4771 * tui/tui.c (tui_enable): Update.
4773 2018-05-25 Tom Tromey <tom@tromey.com>
4775 * utils.c (fputs_maybe_filtered): Update.
4776 * linespec.c (decode_line_full): Update.
4777 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
4778 (mi_print_breakpoint_for_event, mi_solib_loaded)
4779 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
4780 (mi_user_selected_context_changed): Update.
4781 * mi/mi-main.c (mi_execute_command): Update.
4782 * cli/cli-script.c (execute_control_command): Update.
4783 * python/python.c (execute_gdb_command): Update.
4784 * solib.c (info_sharedlibrary_command): Update.
4785 * interps.c (interp_ui_out): Remove.
4786 * interps.h (interp_ui_out): Remove.
4788 2018-05-25 Tom Tromey <tom@tromey.com>
4790 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
4791 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
4792 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
4794 2018-05-25 Tom Tromey <tom@tromey.com>
4796 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
4797 * interps.c (interp_exec): Use scoped_restore.
4799 2018-05-25 Tom Tromey <tom@tromey.com>
4801 * remote.c (remote_target::remote_file_get): Use
4803 (remote_target::remote_file_put): Likewise.
4805 2018-05-25 Tom Tromey <tom@tromey.com>
4807 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
4809 (get_pe_section_index, add_pe_exported_sym): Update.
4810 (read_pe_exported_syms): Use gdb::def_vector.
4812 2018-05-25 Tom Tromey <tom@tromey.com>
4814 * frame.c (remove_prev_frame): Remove.
4815 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
4817 2018-05-25 Maciej W. Rozycki <macro@mips.com>
4819 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
4821 * mips-linux-nat.c (supply_fpregset): Always call
4822 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
4823 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
4824 `mips_fill_fpregset'.
4825 * mips-linux-tdep.c (mips_supply_fpregset)
4826 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
4827 (mips_fill_fpregset_wrapper): Remove functions.
4828 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
4829 (mips_linux_fpregset): Remove variable.
4830 (mips_linux_iterate_over_regset_sections): Use
4831 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
4832 (mips_linux_o32_sigframe_init): Remove comment.
4834 2018-05-25 Pedro Alves <palves@redhat.com>
4836 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
4837 (struct readahead_cache, struct packet_reg, struct
4838 remote_arch_state, class remote_state): Move higher up in the
4840 (remote_target::m_remote_state): Now an object instead of a pointer.
4841 (remote_target::get_remote_state): Adjust.
4843 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
4845 * stack.c (select_and_print_frame): Delete.
4846 (struct function_bounds): Move struct within function.
4847 (func_command): Most content moved into new function
4848 find_frame_for_function, use new function, print result, add
4850 (find_frame_for_function): New function, now returns a result.
4852 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4854 * stack.c (iterate_over_block_arg_vars): Fix comment.
4855 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
4857 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
4861 (scoped_restore_selected_frame::scoped_restore_selected_frame):
4863 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
4865 * frame.h (class scoped_restore_selected_frame): New class.
4866 * stack.c (print_frame_local_vars): Remove catching and rethrowing
4867 of any exception, use scoped_restore_selected_frame to restore the
4870 2018-05-24 Pedro Alves <palves@redhat.com>
4872 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
4875 2018-05-23 Tom Tromey <tom@tromey.com>
4877 * complaints.c (struct complaints): Remove.
4878 (symfile_complaint_book): Remove.
4879 (series): New global.
4880 (complaint_internal): Update.
4881 (clear_complaints): Update.
4883 2018-05-23 Tom Tromey <tom@tromey.com>
4885 * complaints.c (counters): New global.
4886 (struct complain): Remove.
4887 (struct complaints) <root>: Remove.
4888 (complaint_sentinel): Remove.
4889 (symfile_complaint_book): Update.
4890 (find_complaint) Remove.
4891 (complaint_internal, clear_complaints): Update.
4893 2018-05-23 Tom Tromey <tom@tromey.com>
4895 * complaints.c (struct complain) <file, line>: Remove.
4896 (find_complaint): Remove file, line parameters.
4897 (complaint_internal): Update.
4899 2018-05-23 Tom Tromey <tom@tromey.com>
4901 * complaints.c (vcomplaint): Remove.
4902 (complaint_internal) Merge in contents of vcomplaint.
4904 2018-05-23 Tom Tromey <tom@tromey.com>
4906 * complaints.c (struct complaints) <explanation>: Remove.
4907 (symfile_explanations): Remove.
4908 (symfile_complaint_book): Update.
4909 (vcomplaint): Update.
4910 (struct explanation): Remove.
4912 2018-05-23 Tom Tromey <tom@tromey.com>
4914 * complaints.c (symfile_complaints): Remove.
4915 (complaint_internal): Remove "complaints" parameter.
4916 (clear_complaints, vcomplaint): Remove "c" parameter.
4917 (get_complaints): Remove.
4918 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
4919 (dwarf2_debug_line_missing_file_complaint)
4920 (dwarf2_debug_line_missing_end_sequence_complaint)
4921 (dwarf2_complex_location_expr_complaint)
4922 (dwarf2_const_value_length_mismatch_complaint)
4923 (dwarf2_section_buffer_overflow_complaint)
4924 (dwarf2_macro_malformed_definition_complaint)
4925 (dwarf2_invalid_attrib_class_complaint)
4926 (create_addrmap_from_index, dw2_symtab_iter_next)
4927 (dw2_expand_marked_cus)
4928 (dw2_debug_names_iterator::find_vec_in_debug_names)
4929 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
4930 (create_debug_type_hash_table, init_cutu_and_read_dies)
4931 (partial_die_parent_scope, add_partial_enumeration)
4932 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
4933 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
4934 (read_import_statement, read_file_scope, create_dwo_cu_reader)
4935 (create_cus_hash_table, create_dwp_hash_table)
4936 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
4937 (dwarf2_rnglists_process, dwarf2_ranges_process)
4938 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
4939 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
4940 (handle_struct_member_die, process_structure_scope)
4941 (read_array_type, read_common_block, read_module_type)
4942 (read_tag_pointer_type, read_typedef, read_base_type)
4943 (read_subrange_type, load_partial_dies, partial_die_info::read)
4944 (partial_die_info::read, partial_die_info::read)
4945 (partial_die_info::read, read_checked_initial_length_and_offset)
4946 (dwarf2_string_attr, read_formatted_entries)
4947 (dwarf_decode_line_header)
4948 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
4949 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
4950 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
4951 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
4952 (get_signatured_type, get_DW_AT_signature_type)
4953 (decode_locdesc, file_file_name, consume_improper_spaces)
4954 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
4955 (dwarf_decode_macro_bytes, dwarf_decode_macros)
4956 (dwarf2_symbol_mark_computed, set_die_type)
4957 (read_attribute_value): Update.
4958 * stap-probe.c (handle_stap_probe, get_stap_base_address):
4960 * dbxread.c (unknown_symtype_complaint)
4961 (lbrac_mismatch_complaint, repeated_header_complaint)
4962 (set_namestring, function_outside_compilation_unit_complaint)
4963 (read_dbx_symtab, process_one_symbol): Update.
4964 * gdbtypes.c (stub_noname_complaint): Update.
4965 * windows-nat.c (handle_unload_dll): Update.
4966 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
4967 (decode_base_type): Update.
4968 * xcoffread.c (bf_notfound_complaint, ef_complaint)
4969 (eb_complaint, record_include_begin, record_include_end)
4970 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
4971 (process_xcoff_symbol, read_symbol)
4972 (function_outside_compilation_unit_complaint)
4973 (scan_xcoff_symtab): Update.
4974 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
4975 * buildsym.c (finish_block_internal, make_blockvector)
4976 (end_symtab_get_static_block, augment_type_symtab): Update.
4977 * dtrace-probe.c (dtrace_process_dof)
4978 (dtrace_static_probe_ops::get_probes): Update.
4979 * complaints.h (struct complaint): Don't declare.
4980 (symfile_complaints): Remove.
4981 (complaint_internal): Remove "complaints" parameter.
4982 (complaint): Likewise.
4983 (clear_complaints): Likewise.
4984 * symfile.c (syms_from_objfile_1, finish_new_objfile)
4985 (reread_symbols): Update.
4986 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
4987 (dwarf2_frame_cache, decode_frame_entry): Update.
4988 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
4989 * objc-lang.c (lookup_objc_class, lookup_child_selector)
4990 (info_selectors_command): Update.
4991 * macrotab.c (macro_include, check_for_redefinition)
4992 (macro_undef): Update.
4993 * objfiles.c (filter_overlapping_sections): Update.
4994 * stabsread.c (invalid_cpp_abbrev_complaint)
4995 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
4996 (define_symbol, error_type, read_type, rs6000_builtin_type)
4997 (stabs_method_name_from_physname, read_member_functions)
4998 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
4999 (attach_fields_to_type, complain_about_struct_wipeout)
5000 (read_range_type, read_args, common_block_start)
5001 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
5003 * mdebugread.c (index_complaint, unknown_ext_complaint)
5004 (basic_type_complaint, bad_tag_guess_complaint)
5005 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
5006 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
5007 (parse_procedure, parse_lines)
5008 (function_outside_compilation_unit_complaint)
5009 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
5010 (bad_tag_guess_complaint, reg_value_complaint): Update.
5011 * cp-support.c (demangled_name_complaint): Update.
5012 * macroscope.c (sal_macro_scope): Update.
5013 * dwarf-index-write.c (class debug_names): Update.
5015 2018-05-23 Tom Tromey <tom@tromey.com>
5017 * complaints.c (clear_complaints): Remove "noisy" parameter.
5018 * complaints.h (clear_complaints): Update.
5019 * symfile.c (syms_from_objfile_1, finish_new_objfile)
5020 (reread_symbols): Update.
5022 2018-05-23 Tom Tromey <tom@tromey.com>
5024 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
5026 (vcomplaint, clear_complaints): Update.
5027 (symfile_explanations): Remove some messages.
5029 2018-05-23 Tom Tromey <tom@tromey.com>
5031 * complaints.c (internal_complaint): Remove.
5032 * complaints.h (internal_complaint): Remove.
5034 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5036 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
5038 2018-05-22 Pedro Alves <palves@redhat.com>
5040 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
5041 (remote_fileio_badfd, remote_fileio_return_errno)
5042 (remote_fileio_return_success, remote_fileio_func_open)
5043 (remote_fileio_func_open, remote_fileio_func_close)
5044 (remote_fileio_func_read, remote_fileio_func_write)
5045 (remote_fileio_func_lseek, remote_fileio_func_rename)
5046 (remote_fileio_func_unlink, remote_fileio_func_stat)
5047 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
5048 (remote_fileio_func_isatty, remote_fileio_func_system): Add
5049 remote_target parameter.
5050 (remote_fio_func_map) <func>: Add remote_target parameter.
5051 (do_remote_fileio_request, remote_fileio_request):
5052 * remote-fileio.h (remote_fileio_request):
5053 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
5054 remote_target parameter.
5055 (remote_notif_process, handle_notification): Adjust to pass down
5057 (remote_notif_state_allocate): Add remote_target parameter. Save
5059 * remote-notif.h (struct remote_target): Forward declare.
5060 (struct notif_client) <parse, ack, can_get_pending_events>: Add
5061 remote_target parameter.
5062 (struct remote_notif_state) <remote>: New field.
5063 (remote_notif_ack, remote_notif_parse): Add remote_target
5065 (remote_notif_state_allocate, remote_notif_state_allocate): Add
5066 remote_target parameter.
5067 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
5068 (threads_listing_context, rmt_thread_action, protocol_feature)
5069 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
5070 (packet_result, struct threads_listing_context, remote_state):
5071 Move definitions and declarations higher up.
5072 (remote_target) <~remote_target>: Declare.
5073 (remote_download_command_source, remote_file_put, remote_file_get)
5074 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
5075 (remote_hostio_pread_vFile, remote_hostio_send_command)
5076 (remote_hostio_set_filesystem, remote_hostio_open)
5077 (remote_hostio_close, remote_hostio_unlink, remote_state)
5078 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
5079 (get_memory_write_packet_size, get_memory_read_packet_size)
5080 (append_pending_thread_resumptions, remote_detach_1)
5081 (append_resumption, remote_resume_with_vcont)
5082 (add_current_inferior_and_thread, wait_ns, wait_as)
5083 (process_stop_reply, remote_notice_new_inferior)
5084 (process_initial_stop_replies, remote_add_thread)
5085 (btrace_sync_conf, remote_btrace_maybe_reopen)
5086 (remove_new_fork_children, kill_new_fork_children)
5087 (discard_pending_stop_replies, stop_reply_queue_length)
5088 (check_pending_events_prevent_wildcard_vcont)
5089 (discard_pending_stop_replies_in_queue, stop_reply)
5090 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
5091 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
5092 (remote_interrupt_as, remote_interrupt_ns)
5093 (remote_get_noisy_reply, remote_query_attached)
5094 (remote_add_inferior, remote_current_thread, get_current_thread)
5095 (set_thread, set_general_thread, set_continue_thread)
5096 (set_general_process, write_ptid)
5097 (remote_unpack_thread_info_response, remote_get_threadinfo)
5098 (parse_threadlist_response, remote_get_threadlist)
5099 (remote_threadlist_iterator, remote_get_threads_with_ql)
5100 (remote_get_threads_with_qxfer)
5101 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
5102 (get_offsets, remote_check_symbols, remote_supported_packet)
5103 (remote_query_supported, remote_packet_size)
5104 (remote_serial_quit_handler, remote_detach_pid)
5105 (remote_vcont_probe, remote_resume_with_hc)
5106 (send_interrupt_sequence, interrupt_query)
5107 (remote_notif_get_pending_events, fetch_register_using_p)
5108 (send_g_packet, process_g_packet, fetch_registers_using_g)
5109 (store_register_using_P, store_registers_using_G)
5110 (set_remote_traceframe, check_binary_download)
5111 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
5112 (remote_xfer_live_readonly_partial, remote_read_bytes)
5113 (remote_send_printf, remote_flash_write, readchar)
5114 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
5115 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
5116 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
5117 (extended_remote_disable_randomization, extended_remote_run)
5118 (send_environment_packet, extended_remote_environment_support)
5119 (extended_remote_set_inferior_cwd, remote_write_qxfer)
5120 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
5121 (packet_command): Now methods of ...
5122 (remote_target): ... this class.
5123 (m_remote_state) <remote_target>: New field.
5124 (struct remote_state) <stop_reply_queue,
5125 remote_async_inferior_event_token, wait_forever_enabled_p>: New
5127 (remote_state::remote_state): Allocate stop_reply_queue.
5128 (remote_state): Delete global.
5129 (get_remote_state_raw): Delete.
5130 (remote_target::get_remote_state): Allocate m_remote_state on
5132 (get_current_remote_target): New.
5133 (remote_ops, extended_remote_ops): Delete.
5134 (wait_forever_enabled_p, remote_async_inferior_event_token):
5135 Delete, moved to struct remote_state.
5136 (remote_target::close): Delete self. Destruction bits split to
5138 (remote_target::~remote_target): ... this.
5139 (show_memory_packet_size): Adjust to use
5140 get_current_remote_target.
5141 (struct protocol_feature) <func>: Add remote_target parameter.
5142 All callers adjusted.
5143 (curr_quit_handler_target): New.
5144 (remote_serial_quit_handler): Reimplement.
5145 (remote_target::open_1): Adjust to use get_current_remote_target.
5146 Heap-allocate remote_target/extended_remote_target instances.
5147 (vcont_builder::vcont_builder): Add remote_target parameter, and
5148 save it in m_remote. All callers adjusted.
5149 (vcont_builder::m_remote): New field.
5150 (vcont_builder::restart, vcont_builder::flush)
5151 (vcont_builder::push_action): Use it.
5152 (remote_target::commit_resume): Use it.
5153 (struct queue_iter_param) <remote>: New field.
5154 (remote_target::remove_new_fork_children): Fill in 'remote' field.
5155 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
5156 (check_pending_event_prevents_wildcard_vcont_callback)
5157 (remote_target::check_pending_events_prevent_wildcard_vcont)
5158 (remote_target::discard_pending_stop_replies)
5159 (remote_target::discard_pending_stop_replies_in_queue)
5160 (remote_target::remote_notif_remove_queued_reply): Fill in
5162 (remote_notif_get_pending_events): New.
5163 (remote_target::readchar, remote_target::remote_serial_write):
5164 Save/restore curr_quit_handler_target.
5166 (kill_new_fork_children): Fill in 'remote' field.
5167 (packet_command): Use get_current_remote_target, defer to
5168 remote_target method of same name.
5169 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
5170 parameter, and save it in m_remote. All callers adjusted.
5171 (scoped_remote_fd::release): Use m_remote.
5172 (scoped_remote_fd::m_remote): New field.
5173 (remote_file_put, remote_file_get, remote_file_delete): Use
5174 get_current_remote_target, defer to remote_target method of same
5176 (remote_btrace_reset): Add remote_state paremeter. Update all
5178 (remote_async_inferior_event_handler). Pass down 'data'.
5179 (remote_new_objfile): Use get_current_remote_target.
5180 (remote_target::vcont_r_supported): New.
5181 (set_range_stepping): Use get_current_remote_target and
5182 remote_target::vcont_r_supported.
5183 (_initialize_remote): Don't allocate 'remote_state' and
5184 'stop_reply_queue' globals.
5185 * remote.h (struct remote_target): Forward declare.
5186 (getpkt, putpkt, remote_notif_get_pending_events): Add
5187 'remote_target' parameter.
5189 2018-05-22 Pedro Alves <palves@redhat.com>
5191 * remote.c (vcont_builder): Now a class. Make all data members
5193 (vcont_builder) <vcont_builder, restart, flush, push_action>:
5195 (vcont_builder_restart): Rename to ...
5196 (vcont_builder::restart): ... this.
5197 (vcont_builder_flush): Rename to ...
5198 (vcont_builder::flush): ... this.
5199 (vcont_builder_push_action): Rename to ...
5200 (vcont_builder::push_action): ... this.
5201 (remote_target::commit_resume): Adjust.
5203 2018-05-22 Pedro Alves <palves@redhat.com>
5205 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
5206 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
5207 (get_fixed_memory_packet_size): New.
5208 (get_memory_packet_size): Use it.
5209 (set_memory_packet_size): Don't override the config size with
5210 DEFAULT_MAX_MEMORY_PACKET_SIZE.
5211 (show_memory_packet_size): Use get_fixed_memory_packet_size.
5212 Don't refer to get_memory_packet_size if not connected to a remote
5213 target. Show "(default)" if configured size is 0.
5215 2018-05-22 Pedro Alves <palves@redhat.com>
5217 * remote.c (remote_target::mourn_inferior): Move
5218 discard_pending_stop_replies call here from ...
5219 (_initialize_remote): ... here.
5221 2018-05-22 Pedro Alves <palves@redhat.com>
5223 * remote.c (compare_section_command): Remove set_general_process
5226 2018-05-22 Pedro Alves <palves@redhat.com>
5228 * remote.c (struct packet_reg, struct remote_arch_state):
5229 Move higher up in the file.
5230 (remote_state) <m_arch_states>: Store remote_arch_state values
5231 instead of remote_arch_state pointers.
5232 (remote_state::get_remote_arch_state): Adjust.
5234 2018-05-22 Pedro Alves <palves@redhat.com>
5236 * remote.c: Include <unordered_map>.
5237 (remote_state): Now a class.
5238 (remote_state) <get_remote_arch_state>: Declare method.
5239 <get_remote_arch_state>: New field.
5240 (remote_arch_state) <remote_arch_state>: Declare ctor.
5241 <regs>: Now a unique_ptr.
5242 (remote_gdbarch_data_handle): Delete.
5243 (get_remote_arch_state): Delete.
5244 (remote_state::get_remote_arch_state): New.
5245 (get_remote_state): Adjust to call remote_state's
5246 get_remote_arch_state method.
5247 (init_remote_state): Delete, bits factored out to ...
5248 (remote_arch_state::remote_arch_state): ... this new method.
5249 (get_remote_packet_size, get_memory_packet_size)
5250 (process_g_packet, remote_target::fetch_registers)
5251 (remote_target::prepare_to_store, store_registers_using_G)
5252 (remote_target::store_registers, remote_target::get_trace_status):
5253 Adjust to call remote_state's method.
5254 (_initialize_remote): Remove reference to
5255 remote_gdbarch_data_handle.
5257 2018-05-22 Pedro Alves <palves@redhat.com>
5259 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
5260 pread>: New method declarations.
5261 (remote_target::open_1): Adjust.
5262 (readahead_cache_invalidate): Rename to ...
5263 (readahead_cache::invalidate): ... this, and adjust to be a class
5265 (readahead_cache_invalidate_fd): Rename to ...
5266 (readahead_cache::invalidate_fd): ... this, and adjust to be a
5268 (remote_hostio_pwrite): Adjust.
5269 (remote_hostio_pread_from_cache): Rename to ...
5270 (readahead_cache::pread): ... this, and adjust to be a class
5272 (remote_hostio_close): Adjust.
5274 2018-05-22 Pedro Alves <palves@redhat.com>
5276 * remote.c (remote_hostio_close_cleanup): Delete.
5277 (class scoped_remote_fd): New.
5278 (remote_file_put, remote_file_get): Use it.
5280 2018-05-22 Pedro Alves <palves@redhat.com>
5282 (struct vCont_action_support): Use bool and initialize all fields.
5283 (struct readahead_cache): Initialize all fields.
5284 (remote_state): Use bool and initialize all fields.
5285 (remote_state::remote_state, remote_state::~remote_state): New.
5286 (new_remote_state): Delete.
5287 (_initialize_remote): Use new to allocate remote_state.
5289 2018-05-22 Pedro Alves <palves@redhat.com>
5293 * c-exp.y: Include "c-support.h".
5294 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
5295 of tolower. Use c_ident_is_alpha to scan names.
5296 * c-lang.c: Include "c-support.h".
5297 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
5298 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
5299 * c-support.h: New file, with bits factored out from ...
5300 * cp-name-parser.y: ... this file.
5301 Include "c-support.h".
5302 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
5303 c-support.h and renamed.
5304 (symbol_end, yylex): Adjust.
5306 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5308 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
5309 parameter type to CORE_ADDR.
5310 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
5311 parameter type in declaration to CORE_ADDR.
5312 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
5313 target_auxv_search to get AT_HWCAP and use the result to get the
5315 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
5316 to CORE_ADDR. Remove the cast of the return value to unsigned
5317 long. Fix error predicate of target_auxv_search.
5318 (ppc_linux_nat_target::read_description): Change the type of the
5319 hwcap variable to CORE_ADDR.
5321 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5323 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
5324 if the size of fpscr is larger than 32 bits.
5326 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5328 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
5329 (ppc32_linux_vsxregmap): New global.
5330 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
5331 regcache_supply_regset, and regcache_collect_regset.
5332 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
5333 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
5334 (fetch_vsx_register, store_vsx_register): Remove.
5335 (fetch_vsx_registers): Add regno parameter. Get regset using
5336 ppc_linux_vsxregset. Use regset to supply registers.
5337 (store_vsx_registers): Add regno parameter. Get regset using
5338 ppc_linux_vsxregset. Use regset to collect registers.
5339 (fetch_register): Call fetch_vsx_registers instead of
5341 (store_register): Call store_vsx_registers instead of
5343 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
5344 new regno parameter.
5345 (store_ppc_registers): Call store_vsx_registers with -1 for the
5346 new regno parameter.
5347 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
5348 (ppc_collect_vsxregset): Remove.
5350 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5352 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
5354 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
5355 for vector register offset fields.
5356 (ppc64_fbsd_reg_offsets): Likewise.
5357 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
5358 to vector register offset fields.
5359 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
5360 to vector register offset fields.
5361 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
5362 vector register offset fields.
5363 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
5364 initializers for vector register offset fields.
5365 (rs6000_aix64_reg_offsets): Likewise.
5366 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
5367 (ppc_supply_vrregset): Remove.
5368 (ppc_collect_vrregset): Remove.
5369 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
5370 (ppc_linux_vrregset) : New function.
5371 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
5372 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
5373 (ppc32_linux_vrregset): Remove.
5374 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
5375 and use result instead of ppc32_linux_vrregset.
5376 (ppc32_linux_reg_offsets): Remove initializers for vector register
5378 (ppc64_linux_reg_offsets): Likewise.
5379 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
5380 * ppc-linux-nat.c: Include regset.h.
5381 (gdb_vrregset_t): Adjust comment to account for little-endian
5383 (supply_vrregset, fill_vrregset): Remove.
5384 (fetch_altivec_register, store_altivec_register): Remove.
5385 (fetch_altivec_registers): Add regno parameter. Get regset using
5386 ppc_linux_vrregset. Use regset to supply registers.
5387 (store_altivec_registers): Add regno parameter. Get regset using
5388 ppc_linux_vrregset. Use regset to collect registers.
5389 (fetch_register): Call fetch_altivec_registers instead of
5390 fetch_altivec_register.
5391 (store_register): Call store_altivec_registers instead of
5392 store_altivec_register.
5393 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
5394 the new regno parameter.
5395 (store_ppc_registers): Call store_altivec_registers with -1 for
5396 the new regno parameter.
5398 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5400 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
5401 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
5402 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5403 (gdb_vrregset_t): Change array type size to
5404 PPC_LINUX_SIZEOF_VRREGSET.
5405 (gdb_vsxregset_t): Change array type size to
5406 PPC_LINUX_SIZEOF_VSXREGSET.
5407 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
5408 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
5409 PPC_LINUX_SIZEOF_VSXREGSET.
5411 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5413 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
5414 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
5416 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
5417 ppc_linux_target_wordsize with tid.
5418 (ppc_linux_nat_target::read_description): Call ppc_linux_target
5420 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
5421 (ppc64_64bit_inferior_p): Add static and inline specifiers.
5422 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
5423 tid parameter. Remove static specifier.
5424 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
5425 (ppc_linux_target_wordsize): New declaration.
5427 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5429 * arch/ppc-linux-common.c: New file.
5430 * arch/ppc-linux-common.h: New file.
5431 * arch/ppc-linux-tdesc.h: New file.
5432 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
5433 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
5434 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
5435 arch/ppc-linux-tdesc.h.
5436 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
5437 arch/ppc-linux-tdesc.h.
5438 (ppc_linux_nat_target::read_description): Remove target
5439 description matching code. Fill a ppc_linux_features struct and
5440 call ppc_linux_match_description with it. Move comment about ISA
5441 2.05 to ppc-linux-common.c.
5442 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
5443 arch/ppc-linux-tdesc.h.
5444 (ppc_linux_core_read_description): Remove target description
5445 matching code. Fill a ppc_linux_features struct and call
5446 ppc_linux_match_description with it.
5447 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5448 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5449 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5450 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5451 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5452 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5453 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5454 (tdesc_powerpc_e500l): Remove.
5456 2018-05-22 Joel Brobecker <brobecker@adacore.com>
5458 * ada-lang.c (catch_assert_command): Pass empty string instead
5459 of NULL for excep_string argument.
5461 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5463 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
5464 the width of the requested register exceeds the width of the
5467 2018-05-21 Tom Tromey <tom@tromey.com>
5469 * printcmd.c (output_command): Remove.
5470 (output_command_const): Rename to output_command.
5471 * valprint.h (output_command): Rename from output_command_const.
5472 * tracepoint.c (trace_dump_actions): Call output_command.
5474 2018-05-21 Tom Tromey <tom@tromey.com>
5476 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
5477 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
5478 * ada-lang.h (create_ada_exception_catchpoint): Update.
5479 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
5481 (create_excep_cond_exprs, ~ada_catchpoint)
5482 (should_stop_exception, print_one_exception)
5483 (print_mention_exception, print_recreate_exception): Update.
5484 (ada_get_next_arg): Remove.
5485 (catch_ada_exception_command_split): Use std::string. Change type
5486 of "excep_string", "cond_string".
5487 (catch_ada_exception_command): Update.
5488 (create_ada_exception_catchpoint): Change type of excep_string.
5489 (ada_exception_sal): Remove excep_string parameter.
5490 (~ada_catchpoint): Remove.
5492 2018-05-21 Tom Tromey <tom@tromey.com>
5494 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
5497 2018-05-21 Tom Tromey <tom@tromey.com>
5499 * ada-lang.c (ada_exception_message_1, ada_exception_message):
5500 Return unique_xmalloc_ptr.
5501 (print_it_exception): Update.
5503 2018-05-21 Tom Tromey <tom@tromey.com>
5505 * tracepoint.c (trace_dump_actions): Use std::string.
5507 2018-05-21 Tom Tromey <tom@tromey.com>
5509 * symfile.c (reread_symbols): Use std::string for original_name.
5511 2018-05-21 Tom Tromey <tom@tromey.com>
5513 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
5514 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
5517 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
5519 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
5521 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
5522 * objfiles.c (get_objfile_bfd_data): Allocate
5523 objfile_per_bfd_storage with obstack_new when allocating on
5526 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
5528 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
5530 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
5531 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
5532 * mdebugread.c (mdebug_build_psymtabs): Likewise.
5533 (add_pending): Likewise.
5534 (parse_symbol): Likewise.
5535 (parse_partial_symbols): Likewise.
5536 (psymtab_to_symtab_1): Likewise.
5537 (new_psymtab): Likewise.
5538 (elfmdebug_build_psymtabs): Likewise.
5539 * minsyms.c (terminate_minimal_symbol_table): Likewise.
5540 * objfiles.c (get_objfile_bfd_data): Likewise.
5541 (objfile_register_static_link): Likewise.
5542 * psymtab.c (allocate_psymtab): Likewise.
5543 * stabsread.c (read_member_functions): Likewise.
5544 * xcoffread.c (xcoff_end_psymtab): Likewise.
5546 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
5548 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
5549 compiler supports std::is_trivially_constructible.
5550 * common/poison.h: Include obstack.h.
5551 (IsMallocable): Define to is_trivially_constructible if the
5552 compiler supports it, define to true_type otherwise.
5556 (XOBNEWVEC): Redefine.
5557 * gdb_obstack.h (obstack_zalloc): New.
5558 (OBSTACK_ZALLOC): Redefine.
5559 (obstack_calloc): New.
5560 (OBSTACK_CALLOC): Redefine.
5562 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
5563 (gdbarch_obstack): New declaration in gdbarch.h, definition in
5565 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
5566 obstack_calloc/obstack_zalloc.
5567 (gdbarch_obstack_zalloc): Remove.
5568 * target-descriptions.c (tdesc_data_init): Use obstack_new.
5570 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5572 * stack.c (backtrace_command_1): Remove useless variable int i.
5574 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5576 * stack.c (print_frame_info): Fix comment.
5578 2018-05-18 Tom Tromey <tom@tromey.com>
5580 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
5581 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
5582 (~dwarf2_per_objfile): Update
5583 (dwarf2_get_dwz_file): Use new.
5584 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
5587 2018-05-18 Tom Tromey <tom@tromey.com>
5589 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
5591 * dwarf2read.c (struct dwp_file): Add constructor and
5593 (open_and_init_dwp_file): Return a unique_ptr.
5594 (dwarf2_per_objfile, create_dwp_hash_table)
5595 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
5596 (lookup_dwo_unit_in_dwp): Update.
5597 (open_and_init_dwp_file, get_dwp_file): Update.
5599 2018-05-18 Tom Tromey <tom@tromey.com>
5601 * dwarf2read.c (dwarf2_per_objfile): Update.
5602 (struct mapped_index): Add initializers.
5603 (dwarf2_read_index): Use new.
5604 (dw2_symtab_iter_init): Update.
5605 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
5608 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
5610 * dwarf2read.c (mapped_index) <total_size>: Remove.
5612 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
5614 * unittests/format_pieces-selftests.c (test_format_specifier):
5617 2018-05-18 Tom Tromey <tom@tromey.com>
5619 * c-typeprint.c (maybe_print_hole): New function.
5620 (c_print_type_struct_field_offset): Update.
5621 (c_type_print_base_struct_union): Call maybe_print_hole.
5623 2018-05-17 Keith Seitz <keiths@redhat.com>
5625 * breakpoint.c (build_bpstat_chain): New function, moved from
5627 (bpstat_stop_status): Add optional parameter, `stop_chain'.
5628 If no stop chain is passed, call build_bpstat_chain to build it.
5629 * breakpoint.h (build_bpstat_chain): Declare.
5630 (bpstat_stop_status): Move documentation here from breakpoint.c.
5631 * infrun.c (handle_signal_stop): Before eliding inlined frames,
5632 build the stop chain and pass it to skip_inline_frames.
5633 Pass this stop chain to bpstat_stop_status.
5634 * inline-frame.c: Include breakpoint.h.
5635 (stopped_by_user_bp_inline_frame): New function.
5636 (skip_inline_frames): Add parameter `stop_chain'.
5637 Move documention to inline-frame.h.
5638 If non-NULL, use stopped_by_user_bp_inline_frame to determine
5639 whether the frame should be elided.
5640 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
5641 Add moved documentation and update for new parameter.
5643 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
5646 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5647 unittests/format_pieces-selftests.c.
5648 * common/format.h (format_piece) <operator==>: New.
5649 (format_pieces) <operator[]>: Remove.
5650 * common/format.c (format_pieces::format_pieces): Handle \e.
5651 * unittests/format_pieces-selftests.c: New.
5653 2018-05-17 Tom Tromey <tom@tromey.com>
5656 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
5657 (dw2_instantiate_symtab): Add skip_partial parameter.
5658 (dw2_find_last_source_symtab, dw2_map_expand_apply)
5659 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
5660 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
5661 (dw2_expand_symtabs_matching_one)
5662 (dw2_find_pc_sect_compunit_symtab)
5663 (dw2_debug_names_lookup_symbol)
5664 (dw2_debug_names_expand_symtabs_for_function): Update.
5665 (init_cutu_and_read_dies): Add skip_partial parameter.
5666 (process_psymtab_comp_unit, build_type_psymtabs_1)
5667 (process_skeletonless_type_unit, load_partial_comp_unit)
5668 (psymtab_to_symtab_1): Update.
5669 (load_full_comp_unit): Add skip_partial parameter.
5670 (process_imported_unit_die, dwarf2_read_addr_index)
5671 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
5672 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
5673 (read_signatured_type): Update.
5675 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
5677 * value.c (release_value): Remove unused variable.
5678 (record_latest_value): Likewise.
5679 (access_value_history): Likewise.
5680 (preserve_values): Likewise.
5682 2018-05-17 Tom Tromey <tom@tromey.com>
5684 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
5687 2018-05-16 Maciej W. Rozycki <macro@mips.com>
5690 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
5691 Also handle registers whose width is not a multiple of
5693 (linux_nat_trad_target::store_register): Likewise.
5695 2018-05-16 Tom Tromey <tom@tromey.com>
5697 * gdbcore.h (core_bfd): Redefine.
5698 * corelow.c (core_target::close): Update.
5699 (core_target_open): Update.
5700 * progspace.h (struct program_space) <cbfd>: Now a
5703 2018-05-16 Tom Tromey <tom@tromey.com>
5706 * symfile-add-flags.h (enum symfile_add_flags)
5707 <SYMFILE_NOT_FILENAME>: New constant.
5708 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
5709 objfile name from BFD.
5710 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
5711 * minidebug.c (find_separate_debug_file_in_section): Put
5712 ".gnu_debugdata" into BFD's file name.
5714 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
5716 * regcache.c (regcache_read_ftype, regcache_write_ftype):
5719 2018-05-15 Tamar Christina <tamar.christina@arm.com>
5722 * aarch64-tdep.c (aarch64_analyze_prologue,
5723 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
5724 Indicate not interested in errors.
5726 2018-05-15 Maciej W. Rozycki <macro@mips.com>
5728 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
5729 Supply the MIPS_ZERO_REGNUM register.
5731 2018-05-15 Maciej W. Rozycki <macro@mips.com>
5733 * mips-tdep.c (mask_address_var): Make variable static.
5735 2018-05-14 Tom Tromey <tom@tromey.com>
5737 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
5739 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
5741 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
5742 FXSAVE_ADDR for the mxcsr register.
5744 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
5746 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
5748 2018-05-11 Pedro Alves <palves@redhat.com>
5750 * corelow.c (core_target) <core_target>: No longer inline.
5751 Initialize m_core_gdbarch, m_core_vec and build the section table
5753 <~core_target>: New.
5754 <core_gdbarch, get_core_register_section>: New methods.
5755 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
5756 factored out from ...
5757 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
5759 (sniff_core_bfd): Add gdbarch parameter.
5760 (core_close): Delete, merged into ...
5761 (core_target::close): ... here. Delete self.
5762 (core_close_cleanup): Delete.
5763 (core_target_open): Allocate a core_target on the heap. Use a
5764 unique_ptr instead of a cleanup. Bits moved into the core_target
5765 ctor. Adjust to use core_target methods instead of globals.
5766 (get_core_register_section): Rename to ...
5767 (core_target::get_core_register_section): ... this and adjust.
5768 (struct get_core_registers_cb_data): New.
5769 (get_core_registers_cb): Use it. Use bool.
5770 (core_target::fetch_registers, core_target::files_info)
5771 (core_target::xfer_partial, core_target::read_description)
5772 (core_target::pid_to, core_target::thread_name): Adjust to
5773 reference class fields instead of globals.
5774 * target.h (struct target_ops_deleter, target_ops_up): New.
5776 2018-05-11 Pedro Alves <palves@redhat.com>
5778 * corefile.c (core_file_command): Move to corelow.c.
5779 * corelow.c (the_core_target): Delete.
5780 (core_file_command): Moved from corefile.c. Check exec_bfd
5781 instead of the_core_target. Use target_detach instead of calling
5782 into the_core_target directly.
5783 (maybe_say_no_core_file_now): New.
5784 (core_target::detach): Use it.
5785 (_initialize_corelow): Remove references to the_core_target.
5786 * gdbcore.h (the_core_target): Delete.
5788 2018-05-11 Tom Tromey <tromey@redhat.com>
5789 Pedro Alves <palves@redhat.com>
5791 * corefile.c (core_bfd): Remove.
5792 * gdbcore.h (core_bfd): Now a macro.
5793 * progspace.h (struct program_space) <cbfd>: New field.
5795 2018-05-11 Tom Tromey <tom@tromey.com>
5797 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
5800 2018-05-10 Tom Tromey <tom@tromey.com>
5802 * configure: Rebuild.
5803 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
5805 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5808 * regformats/regdat.sh: Adjust script, following the addition
5809 of the new expedite_regs parameter to init_target_desc.
5811 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
5814 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
5815 set_gdbarch_significant_addr_bit.
5816 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
5817 set_gdbarch_significant_addr_bit.
5818 * utils.c (address_significant): Update to sign extend addr.
5820 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
5822 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
5823 (xtensa_linux_init_abi): Limit tdep->num_regs by
5824 tdep->num_nopriv_regs.
5825 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
5826 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
5829 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
5831 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
5833 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5835 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
5836 (I387_MXCSR_INIT_VAL): New constant.
5837 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
5838 buffer if it was supplied by the inferior.
5839 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
5840 (i387_xsave_get_clear_bv): New function.
5841 (i387_supply_xsave): Only read x87 control registers from the
5842 xsave buffer if the feature is enabled, and the state will have
5843 been written, otherwise, provide a suitable default.
5844 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
5845 including x87 control registers. Update control registers if they
5846 have changed from the default value, and mark features as enabled
5848 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
5850 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
5852 * spu-tdep.c (info_spu_event_command): Fix output formatting.
5854 2018-05-07 Tom Tromey <tom@tromey.com>
5856 * configure: Rebuild.
5857 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
5859 2018-05-07 Tom Tromey <tom@tromey.com>
5862 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
5863 bit. Use correct value for VDIV.
5865 2018-05-04 Tom Tromey <tom@tromey.com>
5867 * configure: Rebuild.
5868 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
5870 2018-05-04 Tom Tromey <tom@tromey.com>
5872 * linux-record.c (record_linux_system_call) <case
5873 RECORD_SYS_RECVFROM>: Add "break".
5875 2018-05-04 Tom Tromey <tom@tromey.com>
5877 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
5878 Add missing "break".
5879 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
5880 Add missing "break".
5882 2018-05-04 Tom Tromey <tom@tromey.com>
5884 * rs6000-tdep.c (ppc_process_record_op4)
5885 (ppc_process_record_op63): Add fall-through comment.
5887 2018-05-04 Tom Tromey <tom@tromey.com>
5889 * i386-tdep.c (i386_process_record): Add fall-through comment.
5891 2018-05-04 Tom Tromey <tom@tromey.com>
5893 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
5896 2018-05-04 Tom Tromey <tom@tromey.com>
5898 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
5899 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
5900 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
5902 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
5904 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
5907 2018-05-04 Tom Tromey <tom@tromey.com>
5909 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
5911 2018-05-04 Tom Tromey <tom@tromey.com>
5913 * s390-tdep.c (s390_process_record): Fix fall-through comments.
5914 * xcoffread.c (scan_xcoff_symtab): Move comment later.
5915 * symfile.c (section_is_mapped): Fix fall-through comment.
5916 * stabsread.c (define_symbol, read_member_functions): Fix
5917 fall-through comment.
5918 * s390-linux-tdep.c (s390_process_record): Fix fall-through
5920 * remote.c (remote_wait_as): Fix fall-through comment.
5921 * p-exp.y (yylex): Fix fall-through comment.
5922 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
5924 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
5925 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
5926 * jv-exp.y (yylex): Fix fall-through comment.
5927 * go-exp.y (lex_one_token): Fix fall-through comment.
5928 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
5929 fall-through comment.
5930 * f-exp.y (yylex): Fix fall-through comment.
5931 * dwarf2read.c (process_die): Fix fall-through comments.
5932 * dbxread.c (process_one_symbol): Fix fall-through comment.
5933 * d-exp.y (lex_one_token): Fix fall-through comment.
5934 * cp-name-parser.y (yylex): Fix fall-through comment.
5935 * coffread.c (coff_symtab_read): Fix fall-through comment.
5936 * c-exp.y (lex_one_token): Fix fall-through comment.
5937 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
5939 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
5942 2018-05-04 Tom Tromey <tom@tromey.com>
5945 * NEWS: Mention gdb.execute change.
5946 * gdbcmd.h (execute_control_command): Don't declare.
5947 * python/python.c (execute_gdb_command): Use read_command_lines_1,
5948 execute_control_commands, execute_control_commands_to_string.
5949 * cli/cli-script.h (execute_control_commands)
5950 (execute_control_commands_to_string): Declare.
5951 (execute_control_command): Add from_tty parameter.
5952 * cli/cli-script.c (execute_control_commands)
5953 (execute_control_commands_to_string): New functions.
5954 (execute_user_command): Use execute_control_commands.
5955 (execute_control_command_1): Add "from_tty" parameter. Update.
5956 (execute_control_command): Likewise.
5958 2018-05-04 Tom Tromey <tom@tromey.com>
5961 * NEWS: Mention that breakpoint commands are writable.
5962 * python/py-breakpoint.c (bppy_set_commands): New function.
5963 (breakpoint_object_getset) <"commands">: Use it.
5965 2018-05-04 Tom Tromey <tom@tromey.com>
5967 * tracepoint.c (actions_command): Update.
5968 * mi/mi-cmd-break.c (mi_command_line_array)
5969 (mi_command_line_array_cnt, mi_command_line_array_ptr)
5970 (mi_read_next_line): Remove.
5971 (mi_cmd_break_commands): Update.
5972 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
5974 * cli/cli-script.c (get_command_line): Update.
5975 (process_next_line): Use function_view. Constify.
5976 (recurse_read_control_structure, read_command_lines)
5977 (read_command_lines_1): Change argument types to function_view.
5978 (do_define_command, document_command): Update.
5979 * breakpoint.h (check_tracepoint_command): Don't declare.
5980 * breakpoint.c (check_tracepoint_command): Remove.
5981 (commands_command_1, create_tracepoint_from_upload): Update.
5983 2018-05-04 Tom Tromey <tom@tromey.com>
5986 * cli/cli-script.h (enum command_control_type) <define_control>:
5988 * cli/cli-script.c (multi_line_command_p): Handle define_control.
5989 (build_command_line, execute_control_command_1)
5990 (process_next_line): Likewise.
5991 (do_define_command): New function, extracted from define_command.
5992 (define_command): Use it.
5994 2018-05-04 Tom Tromey <tom@tromey.com>
5996 * tracepoint.c (actions_command): Update.
5997 * cli/cli-script.h (read_command_lines): Update.
5998 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
5999 (MAX_TMPBUF): Remove define.
6000 (define_command): Use string_printf.
6001 (document_command): Likewise.
6002 * breakpoint.c (commands_command_1): Update.
6004 2018-05-04 Tom Tromey <tom@tromey.com>
6006 * top.c (execute_command): Update.
6007 * cli/cli-script.h (print_command_lines): Now varargs.
6008 * cli/cli-script.c (print_command_lines): Now varargs.
6009 (execute_control_command_1) <case while_control, case if_control>:
6012 2018-05-04 Tom Tromey <tom@tromey.com>
6014 * tracepoint.c (all_tracepoint_actions): Rename from
6015 all_tracepoint_actions_and_cleanup. Change return type.
6016 (actions_command, encode_actions_1, encode_actions)
6017 (trace_dump_actions, tdump_command): Update.
6018 * remote.c (remote_download_command_source): Update.
6019 * python/python.c (gdbpy_eval_from_control_command)
6020 (python_command, python_interactive_command): Update.
6021 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
6022 * guile/guile.c (guile_command)
6023 (gdbscm_eval_from_control_command, guile_command): Update.
6024 * compile/compile.c (compile_code_command)
6025 (compile_print_command, compile_to_object): Update.
6026 * cli/cli-script.h (struct command_lines_deleter): New.
6027 (counted_command_line): New typedef.
6028 (struct command_line): Add constructor, destructor.
6029 <body_list>: Remove.
6030 <body_list_0, body_list_1>: New members.
6031 (command_line_up): Remove typedef.
6032 (read_command_lines, read_command_lines_1, get_command_line):
6034 (copy_command_lines): Don't declare.
6035 * cli/cli-script.c (build_command_line): Use "new".
6036 (get_command_line): Return counted_command_line.
6037 (print_command_lines, execute_user_command)
6038 (execute_control_command_1, while_command, if_command): Update.
6039 (realloc_body_list): Remove.
6040 (process_next_line, recurse_read_control_structure): Update.
6041 (read_command_lines, read_command_lines_1): Return counted_command_line.
6042 (free_command_lines): Use "delete".
6043 (copy_command_lines): Remove.
6044 (define_command, document_command, show_user_1): Update.
6045 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
6046 a counted_command_line.
6047 * breakpoint.h (counted_command_line): Remove typedef.
6048 (breakpoint_set_commands): Update.
6049 * breakpoint.c (check_no_tracepoint_commands)
6050 (validate_commands_for_breakpoint): Update.
6051 (breakpoint_set_commands): Change commands to be a
6052 counted_command_line.
6053 (commands_command_1, update_dprintf_command_list)
6054 (create_tracepoint_from_upload): Update.
6056 2018-05-04 Tom Tromey <tom@tromey.com>
6058 * cli/cli-decode.h (cmd_list_element): New constructor.
6059 (~cmd_list_element): New destructor.
6060 (struct cmd_list_element): Add initializers.
6061 * cli/cli-decode.c (do_add_cmd): Use "new".
6062 (delete_cmd): Use "delete".
6064 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
6065 Pedro Alves <palves@redhat.com>
6067 PR breakpoints/19806 and support for PR external/20207.
6068 * NEWS: Mention Aarch64 watchpoint improvements.
6069 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
6070 watchpoints and PR external/20207 watchpoints.
6071 * nat/aarch64-linux-hw-point.c
6072 (kernel_supports_any_contiguous_range): New.
6073 (aarch64_watchpoint_offset): New.
6074 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
6075 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
6076 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
6077 (aarch64_align_watchpoint): New parameters aligned_offset_p and
6078 next_addr_orig_p. Support PR external/20207 watchpoints.
6079 (aarch64_downgrade_regs): New.
6080 (aarch64_dr_state_insert_one_point): New parameters offset and
6082 (aarch64_dr_state_remove_one_point): Likewise.
6083 (aarch64_handle_breakpoint): Update caller.
6084 (aarch64_handle_aligned_watchpoint): Likewise.
6085 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
6087 (aarch64_linux_set_debug_regs): Remove const from state. Call
6088 aarch64_downgrade_regs.
6089 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
6090 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
6091 (DR_CONTROL_MASK): ... this.
6092 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
6093 (unsigned int aarch64_watchpoint_offset): New prototype.
6094 (aarch64_linux_set_debug_regs): Remove const from state.
6095 * utils.c (align_up, align_down): Move to ...
6096 * common/common-utils.c (align_up, align_down): ... here.
6097 * utils.h (align_up, align_down): Move to ...
6098 * common/common-utils.h (align_up, align_down): ... here.
6100 2018-05-04 Joel Brobecker <brobecker@adacore.com>
6102 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
6103 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
6104 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
6105 Re-implement to match the ABI as summarized in GCC's
6106 gcc/config/sparc/sparc.c. All callers updated.
6107 (sparc32_store_arguments): Remove assertion.
6109 2018-05-04 Tom Tromey <tom@tromey.com>
6111 * printcmd.c: Don't include tui.h.
6112 (decode_format): Use skip_spaces.
6114 2018-05-04 Tom Tromey <tom@tromey.com>
6117 * printcmd.c (last_count): New global.
6118 (x_command): Use saved count when repeating.
6120 2018-05-04 Tom Tromey <tom@tromey.com>
6122 * nto-procfs.c (do_closedir_cleanup): Remove.
6123 (procfs_pidlist): Use gdb_dir_up.
6124 * procfs.c (do_closedir_cleanup): Remove.
6125 (proc_update_threads): Use gdb_dir_up.
6126 * common/filestuff.h (struct gdb_dir_deleter): New.
6127 (gdb_dir_up): New typedef.
6129 2018-05-04 Tom Tromey <tom@tromey.com>
6131 * ada-lang.c (print_mention_exception): Use std::string.
6133 2018-05-04 Tom Tromey <tom@tromey.com>
6135 * ada-lang.c (create_excep_cond_exprs): Update.
6136 (ada_exception_catchpoint_cond_string): Use std::string.
6138 2018-05-04 Tom Tromey <tom@tromey.com>
6140 * ada-lang.c (xget_renaming_scope): Return std::string.
6141 (old_renaming_is_invisible): Update.
6143 2018-05-04 Tom Tromey <tom@tromey.com>
6145 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
6146 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
6148 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
6150 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
6152 2018-05-04 Tom Tromey <tom@tromey.com>
6154 * remote.c (remote_query_supported_append): Change type.
6155 (remote_check_symbols): Update.
6157 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
6160 * configure.ac: Prepend libpython.
6161 * python/python-config.py: Likewise.
6162 * configure: Regenerate.
6164 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
6166 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
6168 2018-05-03 Pedro Alves <palves@redhat.com>
6171 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
6172 override. Write 'true' instead of '1'.
6173 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
6176 2018-05-02 Pedro Alves <palves@redhat.com>
6178 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
6179 add_inf_child_target.
6180 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
6181 add_inf_child_target.
6182 * aix-thread.c (aix_thread_target_info): New.
6183 (aix_thread_target) <shortname, longname, doc>: Delete.
6185 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
6186 add_inf_child_target.
6187 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
6188 add_inf_child_target.
6189 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
6190 add_inf_child_target.
6191 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
6192 add_inf_child_target.
6193 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
6194 add_inf_child_target.
6195 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
6196 add_inf_child_target.
6197 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
6198 add_inf_child_target.
6199 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
6200 add_inf_child_target.
6201 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
6202 add_inf_child_target.
6203 * bfd-target.c (target_bfd_target_info): New.
6204 (target_bfd) <shortname, longname, doc>: Delete.
6206 * bsd-kvm.c (bsd_kvm_target_info): New.
6207 (bsd_kvm_target) <shortname, longname, doc>: Delete.
6209 (bsd_kvm_target::open): Rename to ...
6210 (bsd_kvm_target_open): ... this. Adjust.
6211 * bsd-uthread.c (bsd_uthread_target_info): New.
6212 (bsd_uthread_target) <shortname, longname, doc>: Delete.
6214 * corefile.c (core_file_command): Adjust.
6215 * corelow.c (core_target_info): New.
6216 (core_target) <shortname, longname, doc>: Delete.
6218 (core_target::open): Rename to ...
6219 (core_target_open): ... this. Adjust.
6220 * ctf.c (ctf_target_info): New.
6221 (ctf_target) <shortname, longname, doc>: Delete.
6223 (ctf_target::open): Rename to ...
6224 (ctf_target_open): ... this.
6225 (_initialize_ctf): Adjust.
6226 * exec.c (exec_target_info): New.
6227 (exec_target) <shortname, longname, doc>: Delete.
6229 (exec_target::open): Rename to ...
6230 (exec_target_open): ... this.
6231 * gdbcore.h (core_target_open): Declare.
6232 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
6233 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
6234 add_inf_child_target.
6235 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
6236 add_inf_child_target.
6237 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
6238 add_inf_child_target.
6239 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
6240 add_inf_child_target.
6241 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
6242 add_inf_child_target.
6243 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
6244 add_inf_child_target.
6245 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
6246 add_inf_child_target.
6247 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
6248 add_inf_child_target.
6249 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
6250 add_inf_child_target.
6251 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
6252 add_inf_child_target.
6253 * inf-child.c (inf_child_target_info): New.
6254 (inf_child_target::info): New.
6255 (inf_child_open_target): Remove 'target' parameter. Use
6256 get_native_target instead.
6257 (inf_child_target::open): Delete.
6258 (add_inf_child_target): New.
6259 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
6262 (add_inf_child_target): Declare.
6263 (inf_child_open_target): Declare.
6264 * linux-thread-db.c (thread_db_target_info): New.
6265 (thread_db_target) <shortname, longname, doc>: Delete.
6267 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
6268 add_inf_child_target.
6269 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
6270 add_inf_child_target.
6271 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
6272 add_inf_child_target.
6273 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
6274 add_inf_child_target.
6275 * make-target-delegates (print_class): Adjust.
6276 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
6277 add_inf_child_target.
6278 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
6279 add_inf_child_target.
6280 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
6281 add_inf_child_target.
6282 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
6283 add_inf_child_target.
6284 * nto-procfs.c (nto_native_target_info): New.
6285 (nto_procfs_target_native) <shortname, longname, doc>:
6288 (nto_procfs_target_info): New.
6289 (nto_procfs_target_procfs) <shortname, longname, doc>:
6292 (init_procfs_targets): Adjust.
6293 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
6294 add_inf_child_target.
6295 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
6296 add_inf_child_target.
6297 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
6298 add_inf_child_target.
6299 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
6300 add_inf_child_target.
6301 * ravenscar-thread.c (ravenscar_target_info): New.
6302 (ravenscar_thread_target) <shortname, longname, doc>:
6305 * record-btrace.c (record_btrace_target_info):
6306 (record_btrace_target) <shortname, longname, doc>: Delete.
6308 (record_btrace_target::open): Rename to ...
6309 (record_btrace_target_open): ... this. Adjust.
6310 * record-full.c (record_longname, record_doc): New.
6311 (record_full_base_target) <shortname, longname, doc>: Delete.
6313 (record_full_target_info): New.
6314 (record_full_target): <shortname>: Delete.
6316 (record_full_core_open_1, record_full_open_1): Update comments.
6317 (record_full_base_target::open): Rename to ...
6318 (record_full_open): ... this.
6319 (cmd_record_full_restore): Update.
6320 (_initialize_record_full): Update.
6321 * remote-sim.c (remote_sim_target_info): New.
6322 (gdbsim_target) <shortname, longname, doc>: Delete.
6324 (gdbsim_target::open): Rename to ...
6325 (gdbsim_target_open): ... this.
6326 (_initialize_remote_sim): Adjust.
6327 * remote.c (remote_doc): New.
6328 (remote_target_info): New.
6329 (remote_target) <shortname, longname, doc>: Delete.
6331 (extended_remote_target_info): New.
6332 (extended_remote_target) <shortname, longname, doc>: Delete.
6334 (remote_target::open_1): Make static. Adjust.
6335 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
6336 * s390-linux-nat.c (_initialize_s390_nat): Use
6337 add_inf_child_target.
6338 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
6339 add_inf_child_target.
6340 * sol-thread.c (thread_db_target_info): New.
6341 (sol_thread_target) <shortname, longname, doc>: Delete.
6343 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
6344 add_inf_child_target.
6345 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
6346 add_inf_child_target.
6347 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
6348 add_inf_child_target.
6349 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
6350 add_inf_child_target.
6351 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
6352 add_inf_child_target.
6353 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
6354 add_inf_child_target.
6355 * spu-linux-nat.c (_initialize_spu_nat): Use
6356 add_inf_child_target.
6357 * spu-multiarch.c (spu_multiarch_target_info): New.
6358 (spu_multiarch_target) <shortname, longname, doc>: Delete.
6360 * target-delegates.c: Regenerate.
6361 * target.c: Include <unordered_map>.
6362 (target_ops_p): Delete.
6363 (DEF_VEC_P(target_ops_p)): Delete.
6364 (target_factories): New.
6365 (test_target_info): New.
6366 (test_target_ops::info): New.
6367 (open_target): Adjust to use target_factories.
6368 (add_target_with_completer): Rename to ...
6369 (add_target): ... this. Change prototype. Register target_info
6370 and open callback in target_factories. Register target_info in
6371 command context instead of target_ops.
6372 (add_target): Delete old implementation.
6373 (add_deprecated_target_alias): Change prototype. Adjust.
6374 (the_native_target): New.
6375 (set_native_target, get_native_target): New.
6376 (find_default_run_target): Use the_native_target.
6377 (find_attach_target, find_run_target): Simplify.
6378 (target_ops::open): Delete.
6379 (dummy_target_info): New.
6380 (dummy_target::shortname, dummy_target::longname)
6381 (dummy_target::doc): Delete.
6382 (dummy_target::info): New.
6383 (debug_target::shortname, debug_target::longname)
6384 (debug_target::doc): Delete.
6385 (debug_target::info): New.
6386 * target.h (struct target_info): New.
6387 (target_ops::~target_ops): Add comment.
6388 (target_ops::info): New.
6389 (target_ops::shortname, target_ops::longname, target_ops::doc): No
6390 longer virtual. Implement in terms of target_info.
6391 (set_native_target, get_native_target): Declare.
6392 (target_open_ftype): New.
6393 (add_target, add_target_with_completer)
6394 (add_deprecated_target_alias): Change prototype.
6395 (test_target) <shortname, longname, doc>: Delete.
6397 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
6398 add_inf_child_target.
6399 * tracefile-tfile.c (tfile_target_info): New.
6400 (tfile_target) <shortname, longname, doc>: Delete.
6402 (tfile_target::open): Rename to ...
6403 (tfile_target_open): ... this.
6404 (_initialize_tracefile_tfile): Adjust.
6405 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
6406 add_inf_child_target.
6407 * windows-nat.c (_initialize_windows_nat): Use
6408 add_inf_child_target.
6409 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
6410 add_inf_child_target.
6412 2018-05-02 Pedro Alves <palves@redhat.com>
6414 * linux-nat.h (linux_nat_target) <low_new_thread,
6415 low_delete_thread, low_new_fork, low_forget_process,
6416 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
6417 New virtual methods.
6418 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
6419 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
6420 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
6421 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
6422 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
6424 * linux-fork.c (delete_fork): Adjust to call low method.
6425 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
6426 (linux_nat_new_fork, linux_nat_forget_process_hook)
6427 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
6428 (linux_nat_status_is_event):
6429 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
6430 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
6432 (sigtrap_is_event): Rename to ...
6433 (linux_nat_target::low_status_is_event): ... this.
6434 (linux_nat_set_status_is_event): Delete.
6435 (save_stop_reason, linux_nat_wait_1)
6436 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
6438 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
6439 (linux_nat_set_new_fork, linux_nat_set_forget_process)
6440 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
6441 (linux_nat_set_prepare_to_resume): Delete.
6442 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
6443 low virtual methods.
6444 * amd64-linux-nat.c: Likewise.
6445 * arm-linux-nat.c: Likewise.
6446 * i386-linux-nat.c: Likewise.
6447 * ia64-linux-nat.c: Likewise.
6448 * mips-linux-nat.c: Likewise.
6449 * ppc-linux-nat.c: Likewise.
6450 * s390-linux-nat.c: Likewise.
6451 * sparc64-linux-nat.c: Likewise.
6452 * x86-linux-nat.c: Likewise.
6453 * x86-linux-nat.h: Include "nat/x86-linux.h".
6454 (x86_linux_nat_target) <low_new_fork, low_forget_process,
6455 low_prepare_to_resume, low_new_thread, low_delete_thread>:
6458 2018-05-02 Pedro Alves <palves@redhat.com>
6460 * target.h (target_ops)
6461 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
6462 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
6463 stopped_by_watchpoint, have_continuable_watchpoint,
6464 stopped_data_address, watchpoint_addr_within_range,
6465 can_accel_watchpoint_condition, can_run, thread_alive,
6466 has_all_memory, has_memory, has_stack, has_registers,
6467 has_execution, can_async_p, is_async_p, supports_non_stop,
6468 always_non_stop_p, can_execute_reverse, supports_multi_process,
6469 supports_enable_disable_tracepoint,
6470 supports_disable_randomization, supports_string_tracing,
6471 supports_evaluation_of_breakpoint_conditions,
6472 can_run_breakpoint_commands, filesystem_is_local,
6473 can_download_tracepoint, get_trace_state_variable_value,
6474 set_trace_notes, get_tib_address, use_agent, can_use_agent,
6475 record_is_replaying, record_will_replay,
6476 augmented_libraries_svr4_read>: Adjust to return bool.
6477 * aarch64-linux-nat.c: All implementations adjusted.
6478 * aix-thread.c: All implementations adjusted.
6479 * arm-linux-nat.c: All implementations adjusted.
6480 * breakpoint.c: All implementations adjusted.
6481 * bsd-kvm.c: All implementations adjusted.
6482 * bsd-uthread.c: All implementations adjusted.
6483 * corelow.c: All implementations adjusted.
6484 * ctf.c: All implementations adjusted.
6485 * darwin-nat.c: All implementations adjusted.
6486 * darwin-nat.h: All implementations adjusted.
6487 * exec.c: All implementations adjusted.
6488 * fbsd-nat.c: All implementations adjusted.
6489 * fbsd-nat.h: All implementations adjusted.
6490 * gnu-nat.c: All implementations adjusted.
6491 * gnu-nat.h: All implementations adjusted.
6492 * go32-nat.c: All implementations adjusted.
6493 * ia64-linux-nat.c: All implementations adjusted.
6494 * inf-child.c: All implementations adjusted.
6495 * inf-child.h: All implementations adjusted.
6496 * inf-ptrace.c: All implementations adjusted.
6497 * inf-ptrace.h: All implementations adjusted.
6498 * linux-nat.c: All implementations adjusted.
6499 * linux-nat.h: All implementations adjusted.
6500 * mips-linux-nat.c: All implementations adjusted.
6501 * nto-procfs.c: All implementations adjusted.
6502 * ppc-linux-nat.c: All implementations adjusted.
6503 * procfs.c: All implementations adjusted.
6504 * ravenscar-thread.c: All implementations adjusted.
6505 * record-btrace.c: All implementations adjusted.
6506 * record-full.c: All implementations adjusted.
6507 * remote-sim.c: All implementations adjusted.
6508 * remote.c: All implementations adjusted.
6509 * s390-linux-nat.c: All implementations adjusted.
6510 * sol-thread.c: All implementations adjusted.
6511 * spu-multiarch.c: All implementations adjusted.
6512 * target-delegates.c: All implementations adjusted.
6513 * target.c: All implementations adjusted.
6514 * target.h: All implementations adjusted.
6515 * tracefile-tfile.c: All implementations adjusted.
6516 * tracefile.c: All implementations adjusted.
6517 * tracefile.h: All implementations adjusted.
6518 * windows-nat.c: All implementations adjusted.
6519 * x86-linux-nat.h: All implementations adjusted.
6520 * x86-nat.h: All implementations adjusted.
6522 2018-05-02 Pedro Alves <palves@redhat.com>
6524 * make-target-delegates (scan_target_h): Don't trim lines here.
6525 Replace sequences of tabs and/or whitespace with a single
6527 (top level, parsing methods): Trim each line before processing it
6530 2018-05-02 Pedro Alves <palves@redhat.com>
6531 John Baldwin <jhb@freebsd.org>
6533 * target.h (enum strata) <debug_stratum>: New.
6534 (struct target_ops) <all delegation methods>: Replace by C++
6535 virtual methods, and drop "to_" prefix. All references updated
6537 <to_shortname, to_longname, to_doc, to_data,
6538 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
6539 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
6540 virtual methods. All references updated throughout.
6541 <can_attach, supports_terminal_ours, can_create_inferior,
6542 get_thread_control_capabilities, attach_no_wait>: New
6544 <insert_breakpoint, remove_breakpoint>: Now
6545 TARGET_DEFAULT_NORETURN methods.
6546 <info_proc>: Now returns bool.
6548 (OPS_MAGIC): Delete.
6549 (current_target): Delete. All references replaced by references
6551 (target_stack): ... this. New.
6552 (target_shortname, target_longname): Adjust.
6553 (target_can_run): Now a function declaration.
6554 (default_child_has_all_memory, default_child_has_memory)
6555 (default_child_has_stack, default_child_has_registers)
6556 (default_child_has_execution): Remove target_ops parameter.
6557 (complete_target_initialization): Delete.
6558 (memory_breakpoint_target): New template class.
6559 (test_target_ops): Refactor as a C++ class with virtual methods.
6560 * make-target-delegates (NAME_PART): Tighten.
6561 (POINTER_PART, CP_SYMBOL): New.
6562 (SIMPLE_RETURN_PART): Reimplement.
6563 (VEC_RETURN_PART): Expect less.
6564 (RETURN_PART, VIRTUAL_PART): New.
6565 (METHOD): Adjust to C++ virtual methods.
6566 (scan_target_h): Remove reference to C99.
6567 (dname): Output "target_ops::" prefix.
6568 (write_function_header): Adjust to output a C++ class method.
6569 (write_declaration): New.
6570 (write_delegator): Adjust to output a C++ class method.
6571 (tdname): Output "dummy_target::" prefix.
6572 (write_tdefault, write_debugmethod): Adjust to output a C++ class
6574 (tdefault_names, debug_names): Delete.
6575 (return_types, tdefaults, styles, argtypes_array): New.
6576 (top level): All methods are delegators.
6578 (top level): Print dummy_target and debug_target classes.
6579 * target-delegates.c: Regenerate.
6580 * target-debug.h (target_debug_print_enum_info_proc_what)
6581 (target_debug_print_thread_control_capabilities)
6582 (target_debug_print_thread_info_p): New.
6583 * target.c (dummy_target): Delete.
6584 (the_dummy_target, the_debug_target): New.
6585 (target_stack): Now extern.
6586 (set_targetdebug): Push/unpush debug target.
6587 (default_child_has_all_memory, default_child_has_memory)
6588 (default_child_has_stack, default_child_has_registers)
6589 (default_child_has_execution): Remove target_ops parameter.
6590 (complete_target_initialization): Delete.
6591 (add_target_with_completer): No longer call
6592 complete_target_initialization.
6593 (target_supports_terminal_ours): Use regular delegation.
6594 (update_current_target): Delete.
6595 (push_target): No longer check magic number. Don't call
6596 update_current_target.
6597 (unpush_target): Don't call update_current_target.
6598 (target_is_pushed): No longer check magic number.
6599 (target_require_runnable): Skip for all stratums over
6601 (target_ops::info_proc): New.
6602 (target_info_proc): Use find_target_at and
6603 find_default_run_target.
6604 (target_supports_disable_randomization): Use regular delegation.
6605 (target_get_osdata): Use find_target_at.
6606 (target_ops::open, target_ops::close, target_ops::can_attach)
6607 (target_ops::attach, target_ops::can_create_inferior)
6608 (target_ops::create_inferior, target_ops::can_run)
6609 (target_can_run): New.
6610 (default_fileio_target): Use regular delegation.
6611 (target_ops::fileio_open, target_ops::fileio_pwrite)
6612 (target_ops::fileio_pread, target_ops::fileio_fstat)
6613 (target_ops::fileio_close, target_ops::fileio_unlink)
6614 (target_ops::fileio_readlink): New.
6615 (target_fileio_open_1, target_fileio_unlink)
6616 (target_fileio_readlink): Always call the target method. Handle
6618 (return_zero, return_zero_has_execution): Delete.
6619 (init_dummy_target): Delete.
6620 (dummy_target::dummy_target, dummy_target::shortname)
6621 (dummy_target::longname, dummy_target::doc)
6622 (debug_target::debug_target, debug_target::shortname)
6623 (debug_target::longname, debug_target::doc): New.
6624 (target_supports_delete_record): Use regular delegation.
6625 (setup_target_debug): Delete.
6626 (maintenance_print_target_stack): Skip debug_stratum.
6627 (initialize_targets): Instantiate the_dummy_target and
6629 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
6631 (target_auxv_search, fprint_target_auxv): Adjust.
6632 (info_auxv_command): Adjust to use target_stack.
6633 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
6634 * exceptions.c (print_flush): Handle a NULL target_stack.
6635 * regcache.c (target_ops_no_register): Refactor as class with
6638 * exec.c (exec_target): New class.
6639 (exec_ops): Now an exec_target.
6640 (exec_open, exec_close_1, exec_get_section_table)
6641 (exec_xfer_partial, exec_files_info, exec_has_memory)
6642 (exec_make_note_section): Refactor as exec_target methods.
6643 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
6645 (exec_target::find_memory_regions): New.
6646 (_initialize_exec): Don't call init_exec_ops.
6647 * gdbcore.h (exec_file_clear): Delete.
6649 * corefile.c (core_target): Delete.
6650 (core_file_command): Adjust.
6651 * corelow.c (core_target): New class.
6652 (the_core_target): New.
6653 (core_close): Remove target_ops parameter.
6654 (core_close_cleanup): Adjust.
6655 (core_target::close): New.
6656 (core_open, core_detach, get_core_registers, core_files_info)
6657 (core_xfer_partial, core_thread_alive, core_read_description)
6658 (core_pid_to_str, core_thread_name, core_has_memory)
6659 (core_has_stack, core_has_registers, core_info_proc): Rework as
6660 core_target methods.
6661 (ignore, core_remove_breakpoint, init_core_ops): Delete.
6662 (_initialize_corelow): Initialize the_core_target.
6663 * gdbcore.h (core_target): Delete.
6664 (the_core_target): New.
6666 * ctf.c: (ctf_target): New class.
6667 (ctf_ops): Now a ctf_target.
6668 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
6669 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
6670 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
6672 (init_ctf_ops): Delete.
6673 (_initialize_ctf): Don't call it.
6674 * tracefile-tfile.c (tfile_target): New class.
6675 (tfile_ops): Now a tfile_target.
6676 (tfile_open, tfile_close, tfile_files_info)
6677 (tfile_get_tracepoint_status, tfile_trace_find)
6678 (tfile_fetch_registers, tfile_xfer_partial)
6679 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
6680 Refactor as tfile_target methods.
6681 (tfile_xfer_partial_features): Remove target_ops parameter.
6682 (init_tfile_ops): Delete.
6683 (_initialize_tracefile_tfile): Don't call it.
6684 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
6685 (tracefile_has_stack, tracefile_has_registers)
6686 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
6687 tracefile_target methods.
6688 (init_tracefile_ops): Delete.
6689 (tracefile_target::tracefile_target): New.
6690 * tracefile.h: Include "target.h".
6691 (tracefile_target): New class.
6692 (init_tracefile_ops): Delete.
6694 * spu-multiarch.c (spu_multiarch_target): New class.
6695 (spu_ops): Now a spu_multiarch_target.
6696 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
6697 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
6698 (spu_search_memory, spu_mourn_inferior): Refactor as
6699 spu_multiarch_target methods.
6700 (init_spu_ops): Delete.
6701 (_initialize_spu_multiarch): Remove references to init_spu_ops,
6702 complete_target_initialization.
6704 * ravenscar-thread.c (ravenscar_thread_target): New class.
6705 (ravenscar_ops): Now a ravenscar_thread_target.
6706 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
6707 (ravenscar_thread_alive, ravenscar_pid_to_str)
6708 (ravenscar_fetch_registers, ravenscar_store_registers)
6709 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
6710 (ravenscar_stopped_by_hw_breakpoint)
6711 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
6712 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
6713 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
6715 (init_ravenscar_thread_ops): Delete.
6716 (_initialize_ravenscar): Remove references to
6717 init_ravenscar_thread_ops and complete_target_initialization.
6719 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
6720 (bsd_uthread_target): New class.
6721 (bsd_uthread_ops): Now a bsd_uthread_target.
6722 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
6723 (bsd_uthread_close, bsd_uthread_mourn_inferior)
6724 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
6725 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
6726 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
6727 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
6728 (bsd_uthread_target): Delete function.
6729 (_initialize_bsd_uthread): Remove reference to
6730 complete_target_initialization.
6732 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
6733 (target_bfd): ... this new class.
6734 (target_bfd_xfer_partial, target_bfd_get_section_table)
6735 (target_bfd_close): Refactor as target_bfd methods.
6736 (target_bfd::~target_bfd): New.
6737 (target_bfd_reopen): Adjust.
6738 (target_bfd::close): New.
6740 * record-btrace.c (record_btrace_target): New class.
6741 (record_btrace_ops): Now a record_btrace_target.
6742 (record_btrace_open, record_btrace_stop_recording)
6743 (record_btrace_disconnect, record_btrace_close)
6744 (record_btrace_async, record_btrace_info)
6745 (record_btrace_insn_history, record_btrace_insn_history_range)
6746 (record_btrace_insn_history_from, record_btrace_call_history)
6747 (record_btrace_call_history_range)
6748 (record_btrace_call_history_from, record_btrace_record_method)
6749 (record_btrace_is_replaying, record_btrace_will_replay)
6750 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
6751 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
6752 (record_btrace_store_registers, record_btrace_prepare_to_store)
6753 (record_btrace_to_get_unwinder)
6754 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
6755 (record_btrace_commit_resume, record_btrace_wait)
6756 (record_btrace_stop, record_btrace_can_execute_reverse)
6757 (record_btrace_stopped_by_sw_breakpoint)
6758 (record_btrace_supports_stopped_by_sw_breakpoint)
6759 (record_btrace_stopped_by_hw_breakpoint)
6760 (record_btrace_supports_stopped_by_hw_breakpoint)
6761 (record_btrace_update_thread_list, record_btrace_thread_alive)
6762 (record_btrace_goto_begin, record_btrace_goto_end)
6763 (record_btrace_goto, record_btrace_stop_replaying_all)
6764 (record_btrace_execution_direction)
6765 (record_btrace_prepare_to_generate_core)
6766 (record_btrace_done_generating_core): Refactor as
6767 record_btrace_target methods.
6768 (init_record_btrace_ops): Delete.
6769 (_initialize_record_btrace): Remove reference to
6770 init_record_btrace_ops.
6771 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
6772 the execution_direction global.
6773 (record_full_base_target, record_full_target)
6774 (record_full_core_target): New classes.
6775 (record_full_ops): Now a record_full_target.
6776 (record_full_core_ops): Now a record_full_core_target.
6777 (record_full_target::detach, record_full_target::disconnect)
6778 (record_full_core_target::disconnect)
6779 (record_full_target::mourn_inferior, record_full_target::kill):
6781 (record_full_open, record_full_close, record_full_async): Refactor
6782 as methods of the record_full_base_target class.
6783 (record_full_resume, record_full_commit_resume): Refactor
6784 as methods of the record_full_target class.
6785 (record_full_wait, record_full_stopped_by_watchpoint)
6786 (record_full_stopped_data_address)
6787 (record_full_stopped_by_sw_breakpoint)
6788 (record_full_supports_stopped_by_sw_breakpoint)
6789 (record_full_stopped_by_hw_breakpoint)
6790 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
6791 methods of the record_full_base_target class.
6792 (record_full_store_registers, record_full_xfer_partial)
6793 (record_full_insert_breakpoint, record_full_remove_breakpoint):
6794 Refactor as methods of the record_full_target class.
6795 (record_full_can_execute_reverse, record_full_get_bookmark)
6796 (record_full_goto_bookmark, record_full_execution_direction)
6797 (record_full_record_method, record_full_info, record_full_delete)
6798 (record_full_is_replaying, record_full_will_replay)
6799 (record_full_goto_begin, record_full_goto_end, record_full_goto)
6800 (record_full_stop_replaying): Refactor as methods of the
6801 record_full_base_target class.
6802 (record_full_core_resume, record_full_core_kill)
6803 (record_full_core_fetch_registers)
6804 (record_full_core_prepare_to_store)
6805 (record_full_core_store_registers, record_full_core_xfer_partial)
6806 (record_full_core_insert_breakpoint)
6807 (record_full_core_remove_breakpoint)
6808 (record_full_core_has_execution): Refactor
6809 as methods of the record_full_core_target class.
6810 (record_full_base_target::supports_delete_record): New.
6811 (init_record_full_ops): Delete.
6812 (init_record_full_core_ops): Delete.
6813 (record_full_save): Refactor as method of the
6814 record_full_base_target class.
6815 (_initialize_record_full): Remove references to
6816 init_record_full_ops and init_record_full_core_ops.
6818 * remote.c (remote_target, extended_remote_target): New classes.
6819 (remote_ops): Now a remote_target.
6820 (extended_remote_ops): Now an extended_remote_target.
6821 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
6822 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
6823 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
6824 (remote_pass_signals, remote_set_syscall_catchpoint)
6825 (remote_program_signals, )
6826 (remote_thread_always_alive): Remove target_ops parameter.
6827 (remote_thread_alive, remote_thread_name)
6828 (remote_update_thread_list, remote_threads_extra_info)
6829 (remote_static_tracepoint_marker_at)
6830 (remote_static_tracepoint_markers_by_strid)
6831 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
6832 (remote_open): Refactor as methods of remote_target.
6833 (extended_remote_open, extended_remote_detach)
6834 (extended_remote_attach, extended_remote_post_attach):
6835 (extended_remote_supports_disable_randomization)
6836 (extended_remote_create_inferior): : Refactor as method of
6837 extended_remote_target.
6838 (remote_set_permissions, remote_open_1, remote_detach)
6839 (remote_follow_fork, remote_follow_exec, remote_disconnect)
6840 (remote_resume, remote_commit_resume, remote_stop)
6841 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
6842 (remote_terminal_ours, remote_wait, remote_fetch_registers)
6843 (remote_prepare_to_store, remote_store_registers)
6844 (remote_flash_erase, remote_flash_done, remote_files_info)
6845 (remote_kill, remote_mourn, remote_insert_breakpoint)
6846 (remote_remove_breakpoint, remote_insert_watchpoint)
6847 (remote_watchpoint_addr_within_range)
6848 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
6849 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
6850 (remote_supports_stopped_by_sw_breakpoint)
6851 (remote_stopped_by_hw_breakpoint)
6852 (remote_supports_stopped_by_hw_breakpoint)
6853 (remote_stopped_by_watchpoint, remote_stopped_data_address)
6854 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
6855 (remote_verify_memory): Refactor as methods of remote_target.
6856 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
6858 (remote_xfer_partial, remote_get_memory_xfer_limit)
6859 (remote_search_memory, remote_rcmd, remote_memory_map)
6860 (remote_pid_to_str, remote_get_thread_local_address)
6861 (remote_get_tib_address, remote_read_description): Refactor as
6862 methods of remote_target.
6863 (remote_target::fileio_open, remote_target::fileio_pwrite)
6864 (remote_target::fileio_pread, remote_target::fileio_close): New.
6865 (remote_hostio_readlink, remote_hostio_fstat)
6866 (remote_filesystem_is_local, remote_can_execute_reverse)
6867 (remote_supports_non_stop, remote_supports_disable_randomization)
6868 (remote_supports_multi_process, remote_supports_cond_breakpoints)
6869 (remote_supports_enable_disable_tracepoint)
6870 (remote_supports_string_tracing)
6871 (remote_can_run_breakpoint_commands, remote_trace_init)
6872 (remote_download_tracepoint, remote_can_download_tracepoint)
6873 (remote_download_trace_state_variable, remote_enable_tracepoint)
6874 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
6875 (remote_trace_start, remote_get_trace_status)
6876 (remote_get_tracepoint_status, remote_trace_stop)
6877 (remote_trace_find, remote_get_trace_state_variable_value)
6878 (remote_save_trace_data, remote_get_raw_trace_data)
6879 (remote_set_disconnected_tracing, remote_core_of_thread)
6880 (remote_set_circular_trace_buffer, remote_traceframe_info)
6881 (remote_get_min_fast_tracepoint_insn_len)
6882 (remote_set_trace_buffer_size, remote_set_trace_notes)
6883 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
6884 (remote_disable_btrace, remote_teardown_btrace)
6885 (remote_read_btrace, remote_btrace_conf)
6886 (remote_augmented_libraries_svr4_read, remote_load)
6887 (remote_pid_to_exec_file, remote_can_do_single_step)
6888 (remote_execution_direction, remote_thread_handle_to_thread_info):
6889 Refactor as methods of remote_target.
6890 (init_remote_ops, init_extended_remote_ops): Delete.
6891 (remote_can_async_p, remote_is_async_p, remote_async)
6892 (remote_thread_events, remote_upload_tracepoints)
6893 (remote_upload_trace_state_variables): Refactor as methods of
6895 (_initialize_remote): Remove references to init_remote_ops and
6896 init_extended_remote_ops.
6898 * remote-sim.c (gdbsim_target): New class.
6899 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
6900 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
6901 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
6902 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
6903 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
6904 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
6905 Refactor as methods of gdbsim_target.
6906 (gdbsim_ops): Now a gdbsim_target.
6907 (init_gdbsim_ops): Delete.
6908 (gdbsim_cntrl_c): Adjust.
6909 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
6911 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
6912 (the_amd64_linux_nat_target): New.
6913 (amd64_linux_fetch_inferior_registers)
6914 (amd64_linux_store_inferior_registers): Refactor as methods of
6915 amd64_linux_nat_target.
6916 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
6917 * i386-linux-nat.c: Don't include "linux-nat.h".
6918 (i386_linux_nat_target): New class.
6919 (the_i386_linux_nat_target): New.
6920 (i386_linux_fetch_inferior_registers)
6921 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
6922 as methods of i386_linux_nat_target.
6923 (_initialize_i386_linux_nat): Adjust. Set linux_target.
6924 * inf-child.c (inf_child_ops): Delete.
6925 (inf_child_fetch_inferior_registers)
6926 (inf_child_store_inferior_registers): Delete.
6927 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
6928 methods of inf_child_target.
6929 (inf_child_target::supports_terminal_ours)
6930 (inf_child_target::terminal_init)
6931 (inf_child_target::terminal_inferior)
6932 (inf_child_target::terminal_ours_for_output)
6933 (inf_child_target::terminal_ours, inf_child_target::interrupt)
6934 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
6936 (inf_child_open, inf_child_disconnect, inf_child_close)
6937 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
6938 (inf_child_post_startup_inferior, inf_child_can_run)
6939 (inf_child_pid_to_exec_file): Refactor as methods of
6941 (inf_child_follow_fork): Delete.
6942 (inf_child_target::can_create_inferior)
6943 (inf_child_target::can_attach): New.
6944 (inf_child_target::has_all_memory, inf_child_target::has_memory)
6945 (inf_child_target::has_stack, inf_child_target::has_registers)
6946 (inf_child_target::has_execution): New.
6947 (inf_child_fileio_open, inf_child_fileio_pwrite)
6948 (inf_child_fileio_pread, inf_child_fileio_fstat)
6949 (inf_child_fileio_close, inf_child_fileio_unlink)
6950 (inf_child_fileio_readlink, inf_child_use_agent)
6951 (inf_child_can_use_agent): Refactor as methods of
6953 (return_zero, inf_child_target): Delete.
6954 (inf_child_target::inf_child_target): New.
6955 * inf-child.h: Include "target.h".
6956 (inf_child_target): Delete function prototype.
6957 (inf_child_target): New class.
6958 (inf_child_open_target, inf_child_mourn_inferior)
6959 (inf_child_maybe_unpush_target): Delete.
6960 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
6961 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
6962 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
6963 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
6964 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
6965 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
6966 (inf_ptrace_wait, inf_ptrace_xfer_partial)
6967 (inf_ptrace_thread_alive, inf_ptrace_files_info)
6968 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
6969 methods of inf_ptrace_target.
6970 (inf_ptrace_target): Delete function.
6971 * inf-ptrace.h: Include "inf-child.h".
6972 (inf_ptrace_target): Delete function declaration.
6973 (inf_ptrace_target): New class.
6974 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
6975 * linux-nat.c (linux_target): New.
6976 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
6977 (linux_nat_target::~linux_nat_target): New.
6978 (linux_child_post_attach, linux_child_post_startup_inferior)
6979 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
6980 (linux_child_remove_fork_catchpoint)
6981 (linux_child_insert_vfork_catchpoint)
6982 (linux_child_remove_vfork_catchpoint)
6983 (linux_child_insert_exec_catchpoint)
6984 (linux_child_remove_exec_catchpoint)
6985 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
6986 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
6987 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
6988 (linux_nat_stopped_data_address)
6989 (linux_nat_stopped_by_sw_breakpoint)
6990 (linux_nat_supports_stopped_by_sw_breakpoint)
6991 (linux_nat_stopped_by_hw_breakpoint)
6992 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
6993 (linux_nat_kill, linux_nat_mourn_inferior)
6994 (linux_nat_xfer_partial, linux_nat_thread_alive)
6995 (linux_nat_update_thread_list, linux_nat_pid_to_str)
6996 (linux_nat_thread_name, linux_child_pid_to_exec_file)
6997 (linux_child_static_tracepoint_markers_by_strid)
6998 (linux_nat_is_async_p, linux_nat_can_async_p)
6999 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
7000 (linux_nat_supports_multi_process)
7001 (linux_nat_supports_disable_randomization, linux_nat_async)
7002 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
7003 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
7004 (linux_nat_fileio_open, linux_nat_fileio_readlink)
7005 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
7006 methods of linux_nat_target.
7007 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
7008 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
7010 (check_stopped_by_watchpoint): Adjust.
7011 (linux_xfer_partial): Delete.
7012 (linux_target_install_ops, linux_target, linux_nat_add_target):
7014 (linux_nat_target::linux_nat_target): New.
7015 * linux-nat.h: Include "inf-ptrace.h".
7016 (linux_nat_target): New.
7017 (linux_target, linux_target_install_ops, linux_nat_add_target):
7018 Delete function declarations.
7019 (linux_target): Declare global.
7020 * linux-thread-db.c (thread_db_target): New.
7021 (thread_db_target::thread_db_target): New.
7022 (thread_db_ops): Delete.
7023 (the_thread_db_target): New.
7024 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
7025 (thread_db_update_thread_list, thread_db_pid_to_str)
7026 (thread_db_extra_thread_info)
7027 (thread_db_thread_handle_to_thread_info)
7028 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
7029 (thread_db_resume): Refactor as methods of thread_db_target.
7030 (init_thread_db_ops): Delete.
7031 (_initialize_thread_db): Remove reference to init_thread_db_ops.
7032 * x86-linux-nat.c: Don't include "linux-nat.h".
7033 (super_post_startup_inferior): Delete.
7034 (x86_linux_nat_target::~x86_linux_nat_target): New.
7035 (x86_linux_child_post_startup_inferior)
7036 (x86_linux_read_description, x86_linux_enable_btrace)
7037 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
7038 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
7039 methods of x86_linux_nat_target.
7040 (x86_linux_create_target): Delete. Bits folded ...
7041 (x86_linux_add_target): ... here. Now takes a linux_nat_target
7043 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
7044 (x86_linux_nat_target): New class.
7045 (x86_linux_create_target): Delete.
7046 (x86_linux_add_target): Now takes a linux_nat_target pointer.
7047 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
7048 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
7049 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
7050 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
7051 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
7053 (x86_use_watchpoints): Delete.
7054 * x86-nat.h: Include "breakpoint.h" and "target.h".
7055 (x86_use_watchpoints): Delete.
7056 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
7057 (x86_stopped_by_watchpoint, x86_stopped_data_address)
7058 (x86_insert_watchpoint, x86_remove_watchpoint)
7059 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
7060 (x86_stopped_by_hw_breakpoint): New declarations.
7061 (x86_nat_target): New template class.
7063 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
7064 (the_ppc_linux_nat_target): New.
7065 (ppc_linux_fetch_inferior_registers)
7066 (ppc_linux_can_use_hw_breakpoint)
7067 (ppc_linux_region_ok_for_hw_watchpoint)
7068 (ppc_linux_ranged_break_num_registers)
7069 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
7070 (ppc_linux_insert_mask_watchpoint)
7071 (ppc_linux_remove_mask_watchpoint)
7072 (ppc_linux_can_accel_watchpoint_condition)
7073 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
7074 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
7075 (ppc_linux_watchpoint_addr_within_range)
7076 (ppc_linux_masked_watch_num_registers)
7077 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
7078 (ppc_linux_read_description): Refactor as methods of
7079 ppc_linux_nat_target.
7080 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
7082 * procfs.c (procfs_xfer_partial): Delete forward declaration.
7083 (procfs_target): New class.
7084 (the_procfs_target): New.
7085 (procfs_target): Delete function.
7086 (procfs_auxv_parse, procfs_attach, procfs_detach)
7087 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
7088 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
7089 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
7090 (procfs_create_inferior, procfs_update_thread_list)
7091 (procfs_thread_alive, procfs_pid_to_str)
7092 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
7093 (procfs_stopped_data_address, procfs_insert_watchpoint)
7094 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
7095 (proc_find_memory_regions, procfs_info_proc)
7096 (procfs_make_note_section): Refactor as methods of procfs_target.
7097 (_initialize_procfs): Adjust.
7098 * sol-thread.c (sol_thread_target): New class.
7099 (sol_thread_ops): Now a sol_thread_target.
7100 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
7101 (sol_thread_fetch_registers, sol_thread_store_registers)
7102 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
7103 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
7104 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
7105 (init_sol_thread_ops): Delete.
7106 (_initialize_sol_thread): Adjust. Remove references to
7107 init_sol_thread_ops and complete_target_initialization.
7109 * windows-nat.c (windows_nat_target): New class.
7110 (windows_fetch_inferior_registers)
7111 (windows_store_inferior_registers, windows_resume, windows_wait)
7112 (windows_attach, windows_detach, windows_pid_to_exec_file)
7113 (windows_files_info, windows_create_inferior)
7114 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
7115 (windows_close, windows_pid_to_str, windows_xfer_partial)
7116 (windows_get_tib_address, windows_get_ada_task_ptid)
7117 (windows_thread_name, windows_thread_alive): Refactor as
7118 windows_nat_target methods.
7119 (do_initial_windows_stuff): Adjust.
7120 (windows_target): Delete function.
7121 (_initialize_windows_nat): Adjust.
7123 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
7124 (darwin_mourn_inferior, darwin_kill_inferior)
7125 (darwin_create_inferior, darwin_attach, darwin_detach)
7126 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
7127 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
7128 (darwin_supports_multi_process): Refactor as darwin_nat_target
7130 (darwin_resume_to, darwin_files_info): Delete.
7131 (_initialize_darwin_inferior): Rename to ...
7132 (_initialize_darwin_nat): ... this. Adjust to C++ification.
7133 * darwin-nat.h: Include "inf-child.h".
7134 (darwin_nat_target): New class.
7135 (darwin_complete_target): Delete.
7136 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
7137 (darwin_target): New.
7138 (i386_darwin_fetch_inferior_registers)
7139 (i386_darwin_store_inferior_registers): Refactor as methods of
7141 (darwin_complete_target): Delete, with ...
7142 (_initialize_i386_darwin_nat): ... bits factored out here.
7144 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
7145 (the_alpha_linux_nat_target): New.
7146 (alpha_linux_register_u_offset): Refactor as
7147 alpha_linux_nat_target method.
7148 (_initialize_alpha_linux_nat): Adjust.
7149 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
7150 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
7151 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
7152 methods of linux_nat_trad_target.
7153 (linux_trad_target): Delete.
7154 * linux-nat-trad.h (linux_trad_target): Delete function.
7155 (linux_nat_trad_target): New class.
7156 * mips-linux-nat.c (mips_linux_nat_target): New class.
7157 (super_fetch_registers, super_store_registers, super_close):
7159 (the_mips_linux_nat_target): New.
7160 (mips64_linux_regsets_fetch_registers)
7161 (mips64_linux_regsets_store_registers)
7162 (mips64_linux_fetch_registers, mips64_linux_store_registers)
7163 (mips_linux_register_u_offset, mips_linux_read_description)
7164 (mips_linux_can_use_hw_breakpoint)
7165 (mips_linux_stopped_by_watchpoint)
7166 (mips_linux_stopped_data_address)
7167 (mips_linux_region_ok_for_hw_watchpoint)
7168 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
7169 (mips_linux_close): Refactor as methods of mips_linux_nat.
7170 (_initialize_mips_linux_nat): Adjust to C++ification.
7172 * aix-thread.c (aix_thread_target): New class.
7173 (aix_thread_ops): Now an aix_thread_target.
7174 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
7175 (aix_thread_fetch_registers, aix_thread_store_registers)
7176 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
7177 (aix_thread_thread_alive, aix_thread_pid_to_str)
7178 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
7179 Refactor as methods of aix_thread_target.
7180 (init_aix_thread_ops): Delete.
7181 (_initialize_aix_thread): Remove references to init_aix_thread_ops
7182 and complete_target_initialization.
7183 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
7184 (rs6000_nat_target): New class.
7185 (the_rs6000_nat_target): New.
7186 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
7187 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
7188 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
7189 (super_create_inferior): Delete.
7190 (_initialize_rs6000_nat): Adjust to C++ification.
7192 * arm-linux-nat.c (arm_linux_nat_target): New class.
7193 (the_arm_linux_nat_target): New.
7194 (arm_linux_fetch_inferior_registers)
7195 (arm_linux_store_inferior_registers, arm_linux_read_description)
7196 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
7197 (arm_linux_remove_hw_breakpoint)
7198 (arm_linux_region_ok_for_hw_watchpoint)
7199 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
7200 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
7201 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
7202 arm_linux_nat_target.
7203 (_initialize_arm_linux_nat): Adjust to C++ification.
7205 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
7206 (the_aarch64_linux_nat_target): New.
7207 (aarch64_linux_fetch_inferior_registers)
7208 (aarch64_linux_store_inferior_registers)
7209 (aarch64_linux_child_post_startup_inferior)
7210 (aarch64_linux_read_description)
7211 (aarch64_linux_can_use_hw_breakpoint)
7212 (aarch64_linux_insert_hw_breakpoint)
7213 (aarch64_linux_remove_hw_breakpoint)
7214 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
7215 (aarch64_linux_region_ok_for_hw_watchpoint)
7216 (aarch64_linux_stopped_data_address)
7217 (aarch64_linux_stopped_by_watchpoint)
7218 (aarch64_linux_watchpoint_addr_within_range)
7219 (aarch64_linux_can_do_single_step): Refactor as methods of
7220 aarch64_linux_nat_target.
7221 (super_post_startup_inferior): Delete.
7222 (_initialize_aarch64_linux_nat): Adjust to C++ification.
7224 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
7225 (the_hppa_linux_nat_target): New.
7226 (hppa_linux_fetch_inferior_registers)
7227 (hppa_linux_store_inferior_registers): Refactor as methods of
7228 hppa_linux_nat_target.
7229 (_initialize_hppa_linux_nat): Adjust to C++ification.
7231 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
7232 (the_ia64_linux_nat_target): New.
7233 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
7234 (ia64_linux_stopped_data_address)
7235 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
7236 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
7237 ia64_linux_nat_target methods.
7238 (super_xfer_partial): Delete.
7239 (_initialize_ia64_linux_nat): Adjust to C++ification.
7241 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
7242 (the_m32r_linux_nat_target): New.
7243 (m32r_linux_fetch_inferior_registers)
7244 (m32r_linux_store_inferior_registers): Refactor as
7245 m32r_linux_nat_target methods.
7246 (_initialize_m32r_linux_nat): Adjust to C++ification.
7248 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
7249 (the_m68k_linux_nat_target): New.
7250 (m68k_linux_fetch_inferior_registers)
7251 (m68k_linux_store_inferior_registers): Refactor as
7252 m68k_linux_nat_target methods.
7253 (_initialize_m68k_linux_nat): Adjust to C++ification.
7255 * s390-linux-nat.c (s390_linux_nat_target): New class.
7256 (the_s390_linux_nat_target): New.
7257 (s390_linux_fetch_inferior_registers)
7258 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
7259 (s390_insert_watchpoint, s390_remove_watchpoint)
7260 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
7261 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
7262 (s390_auxv_parse, s390_read_description): Refactor as methods of
7263 s390_linux_nat_target.
7264 (_initialize_s390_nat): Adjust to C++ification.
7266 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
7267 (the_sparc_linux_nat_target): New.
7268 (_initialize_sparc_linux_nat): Adjust to C++ification.
7269 * sparc-nat.c (sparc_fetch_inferior_registers)
7270 (sparc_store_inferior_registers): Remove target_ops parameter.
7271 * sparc-nat.h (sparc_fetch_inferior_registers)
7272 (sparc_store_inferior_registers): Remove target_ops parameter.
7273 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
7274 (the_sparc64_linux_nat_target): New.
7275 (_initialize_sparc64_linux_nat): Adjust to C++ification.
7277 * spu-linux-nat.c (spu_linux_nat_target): New class.
7278 (the_spu_linux_nat_target): New.
7279 (spu_child_post_startup_inferior, spu_child_post_attach)
7280 (spu_child_wait, spu_fetch_inferior_registers)
7281 (spu_store_inferior_registers, spu_xfer_partial)
7282 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
7284 (_initialize_spu_nat): Adjust to C++ification.
7286 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
7287 (the_tilegx_linux_nat_target): New.
7288 (fetch_inferior_registers, store_inferior_registers):
7289 Refactor as methods.
7290 (_initialize_tile_linux_nat): Adjust to C++ification.
7292 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
7293 (the_xtensa_linux_nat_target): New.
7294 (xtensa_linux_fetch_inferior_registers)
7295 (xtensa_linux_store_inferior_registers): Refactor as
7296 xtensa_linux_nat_target methods.
7297 (_initialize_xtensa_linux_nat): Adjust to C++ification.
7299 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
7300 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
7301 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
7302 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
7303 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
7304 (fbsd_stopped_by_sw_breakpoint)
7305 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
7306 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
7307 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
7308 (fbsd_post_startup_inferior, fbsd_post_attach)
7309 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
7310 (fbsd_set_syscall_catchpoint)
7311 (super_xfer_partial, super_resume, super_wait)
7312 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
7313 (fbsd_handle_debug_trap): Remove target_ops parameter.
7314 (fbsd_nat_add_target): Delete.
7315 * fbsd-nat.h: Include "inf-ptrace.h".
7316 (fbsd_nat_add_target): Delete.
7317 (USE_SIGTRAP_SIGINFO): Define.
7318 (fbsd_nat_target): New class.
7320 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
7321 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
7322 (amd64bsd_target): Delete.
7323 * amd64-bsd-nat.h: New file.
7324 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
7326 (amd64_fbsd_nat_target): New class.
7327 (the_amd64_fbsd_nat_target): New.
7328 (amd64fbsd_read_description): Refactor as method of
7329 amd64_fbsd_nat_target.
7330 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
7331 (_initialize_amd64fbsd_nat): Adjust to C++ification.
7332 * amd64-nat.h (amd64bsd_target): Delete function declaration.
7333 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
7334 (i386bsd_store_inferior_registers): Remove target_ops parameter.
7335 (i386bsd_target): Delete.
7336 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
7337 (i386bsd_fetch_inferior_registers)
7338 (i386bsd_store_inferior_registers): Declare.
7339 (i386_bsd_nat_target): New class.
7340 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
7341 (the_i386_fbsd_nat_target): New.
7342 (i386fbsd_resume, i386fbsd_read_description): Refactor as
7343 i386_fbsd_nat_target methods.
7344 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
7345 (_initialize_i386fbsd_nat): Adjust to C++ification.
7346 * x86-bsd-nat.c (super_mourn_inferior): Delete.
7347 (x86bsd_mourn_inferior, x86bsd_target): Delete.
7348 (_initialize_x86_bsd_nat): Adjust to C++ification.
7349 * x86-bsd-nat.h: Include "x86-nat.h".
7350 (x86bsd_target): Delete declaration.
7351 (x86bsd_nat_target): New class.
7353 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
7354 (the_aarch64_fbsd_nat_target): New.
7355 (aarch64_fbsd_fetch_inferior_registers)
7356 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
7357 aarch64_fbsd_nat_target.
7358 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
7359 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
7360 (the_alpha_bsd_nat_target): New.
7361 (alphabsd_fetch_inferior_registers)
7362 (alphabsd_store_inferior_registers): Refactor as
7363 alpha_bsd_nat_target methods.
7364 (_initialize_alphabsd_nat): Refactor as methods of
7365 alpha_bsd_nat_target.
7366 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
7367 (the_amd64_nbsd_nat_target): New.
7368 (_initialize_amd64nbsd_nat): Adjust to C++ification.
7369 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
7370 (the_amd64_obsd_nat_target): New.
7371 (_initialize_amd64obsd_nat): Adjust to C++ification.
7372 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
7373 (the_arm_fbsd_nat_target): New.
7374 (arm_fbsd_fetch_inferior_registers)
7375 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
7376 (_initialize_arm_fbsd_nat): Refactor as methods of
7377 arm_fbsd_nat_target.
7378 (_initialize_arm_fbsd_nat): Adjust to C++ification.
7379 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
7380 (the_arm_netbsd_nat_target): New.
7381 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
7382 arm_netbsd_nat_target.
7383 (_initialize_arm_netbsd_nat): Adjust to C++ification.
7384 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
7385 (the_hppa_nbsd_nat_target): New.
7386 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
7387 hppa_nbsd_nat_target methods.
7388 (_initialize_hppanbsd_nat): Adjust to C++ification.
7389 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
7390 (the_hppa_obsd_nat_target): New.
7391 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
7392 methods of hppa_obsd_nat_target.
7393 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
7395 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
7396 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
7398 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
7399 (_initialize_i386obsd_nat): Use add_target.
7400 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
7401 (the_m68k_bsd_nat_target): New.
7402 (m68kbsd_fetch_inferior_registers)
7403 (m68kbsd_store_inferior_registers): Refactor as methods of
7404 m68k_bsd_nat_target.
7405 (_initialize_m68kbsd_nat): Adjust to C++ification.
7406 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
7407 (the_mips_fbsd_nat_target): New.
7408 (mips_fbsd_fetch_inferior_registers)
7409 (mips_fbsd_store_inferior_registers): Refactor as methods of
7410 mips_fbsd_nat_target.
7411 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
7413 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
7414 (the_mips_nbsd_nat_target): New.
7415 (mipsnbsd_fetch_inferior_registers)
7416 (mipsnbsd_store_inferior_registers): Refactor as methods of
7417 mips_nbsd_nat_target.
7418 (_initialize_mipsnbsd_nat): Adjust to C++ification.
7419 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
7420 (the_mips64_obsd_nat_target): New.
7421 (mips64obsd_fetch_inferior_registers)
7422 (mips64obsd_store_inferior_registers): Refactor as methods of
7423 mips64_obsd_nat_target.
7424 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
7426 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
7428 * nbsd-nat.h: Include "inf-ptrace.h".
7429 (nbsd_nat_target): New class.
7430 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
7431 (obsd_wait): Refactor as methods of obsd_nat_target.
7432 (obsd_add_target): Delete.
7433 * obsd-nat.h: Include "inf-ptrace.h".
7434 (obsd_nat_target): New class.
7435 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
7436 (the_ppc_fbsd_nat_target): New.
7437 (ppcfbsd_fetch_inferior_registers)
7438 (ppcfbsd_store_inferior_registers): Refactor as methods of
7439 ppc_fbsd_nat_target.
7440 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
7442 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
7443 (the_ppc_nbsd_nat_target): New.
7444 (ppcnbsd_fetch_inferior_registers)
7445 (ppcnbsd_store_inferior_registers): Refactor as methods of
7446 ppc_nbsd_nat_target.
7447 (_initialize_ppcnbsd_nat): Adjust to C++ification.
7448 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
7449 (the_ppc_obsd_nat_target): New.
7450 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
7451 methods of ppc_obsd_nat_target.
7452 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
7454 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
7455 (the_sh_nbsd_nat_target): New.
7456 (shnbsd_fetch_inferior_registers)
7457 (shnbsd_store_inferior_registers): Refactor as methods of
7459 (_initialize_shnbsd_nat): Adjust to C++ification.
7460 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
7461 (inf_ptrace_xfer_partial): Delete.
7462 (sparc_xfer_partial, sparc_target): Delete.
7463 * sparc-nat.h (sparc_fetch_inferior_registers)
7464 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
7465 (sparc_target): Delete function declaration.
7466 (sparc_target): New template class.
7467 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
7468 (_initialize_sparcnbsd_nat): Adjust to C++ification.
7469 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
7470 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
7472 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
7473 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
7474 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
7475 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
7477 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
7478 (the_vax_bsd_nat_target): New.
7479 (vaxbsd_fetch_inferior_registers)
7480 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
7482 (_initialize_vaxbsd_nat): Adjust to C++ification.
7484 * bsd-kvm.c (bsd_kvm_target): New class.
7485 (bsd_kvm_ops): Now a bsd_kvm_target.
7486 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
7487 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
7488 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
7490 (bsd_kvm_return_one): Delete.
7491 (bsd_kvm_add_target): Adjust to C++ification.
7493 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
7494 (nto_procfs_target_procfs): New classes.
7495 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
7496 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
7497 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
7498 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
7499 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
7500 (procfs_remove_hw_breakpoint, procfs_resume)
7501 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
7502 (procfs_kill_inferior, procfs_store_registers)
7503 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
7504 as methods of nto_procfs_target.
7505 (nto_procfs_ops): Now an nto_procfs_target_procfs.
7506 (nto_native_ops): Delete.
7507 (procfs_open, procfs_native_open): Delete.
7508 (nto_native_ops): Now an nto_procfs_target_native.
7509 (init_procfs_targets): Adjust to C++ification.
7510 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
7511 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
7512 Refactor as methods of nto_procfs_target.
7514 * go32-nat.c (go32_nat_target): New class.
7515 (the_go32_nat_target): New.
7516 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
7517 (go32_store_registers, go32_xfer_partial, go32_files_info)
7518 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
7519 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
7520 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
7521 (go32_pid_to_str): Refactor as methods of go32_nat_target.
7522 (go32_target): Delete.
7523 (_initialize_go32_nat): Adjust to C++ification.
7525 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
7526 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
7527 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
7528 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
7530 (gnu_target): Delete.
7531 * gnu-nat.h (gnu_target): Delete.
7532 (gnu_nat_target): New class.
7533 * i386-gnu-nat.c (gnu_base_target): New.
7534 (i386_gnu_nat_target): New class.
7535 (the_i386_gnu_nat_target): New.
7536 (_initialize_i386gnu_nat): Adjust to C++ification.
7538 2018-05-02 Pedro Alves <palves@redhat.com>
7540 * bfd-target.c (target_bfd_xclose): Rename to ...
7541 (target_bfd_close): ... this.
7542 (target_bfd_reopen): Adjust.
7543 * target.c (target_close): Remove references to to_xclose.
7544 * target.h (target_ops::to_xclose): Delete.
7545 (target_ops::to_close): Update comments.
7547 2018-05-02 Pedro Alves <palves@redhat.com>
7549 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
7551 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
7552 * inf-ptrace.c (inf_ptrace_register_u_offset)
7553 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
7554 (inf_ptrace_store_register, inf_ptrace_store_registers)
7555 (inf_ptrace_trad_target): Move to ...
7556 * linux-nat-trad.c: ... this new file.
7557 * linux-nat-trad.h: New file.
7558 * linux-nat.c (linux_target_install_ops): Make extern.
7559 (linux_trad_target): Delete.
7560 * linux-nat.h (linux_trad_target): Delete declaration.
7561 (linux_target_install_ops): Declare.
7562 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
7565 2018-05-02 Pedro Alves <palves@redhat.com>
7567 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
7568 procfs_target/add_target here.
7569 * procfs.c (procfs_target): Make static.
7570 (_initialize_procfs): Call add_target here.
7571 * procfs.h (struct target_ops): Remove forward declaration.
7572 (procfs_target): Remove declaration.
7573 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
7575 2018-05-02 Pedro Alves <palves@redhat.com>
7577 * procfs.c (procfs_stopped_by_watchpoint)
7578 (procfs_insert_watchpoint, procfs_remove_watchpoint)
7579 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
7581 (procfs_use_watchpoints): Delete, move contents...
7582 (procfs_target): ... here.
7583 * procfs.h (procfs_use_watchpoints): Delete declaration.
7584 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
7585 procfs_use_watchpoints.
7586 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
7587 procfs_use_watchpoints.
7589 2018-05-02 Tom Tromey <tom@tromey.com>
7592 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
7593 and var_zuinteger_unlimited.
7594 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
7595 and PARAM_ZUINTEGER_UNLIMITED.
7596 (set_parameter_value): Handle var_zuinteger and
7597 var_zuinteger_unlimited.
7598 (add_setshow_generic): Likewise.
7599 (parmpy_init): Likewise.
7601 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
7604 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
7605 pointer is not null before dereferencing it.
7607 2018-04-30 Tom Tromey <tom@tromey.com>
7609 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
7612 2018-04-30 Tom Tromey <tom@tromey.com>
7614 * breakpoint.c (mention): Remove use of is_mi_like_p.
7615 (print_mention_ranged_breakpoint): Likewise.
7616 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
7619 2018-04-30 Tom Tromey <tom@tromey.com>
7621 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
7623 2018-04-30 Tom Tromey <tom@tromey.com>
7625 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
7626 (info_spu_event_command): Remove some uses of is_mi_like_p.
7628 2018-04-30 Tom Tromey <tom@tromey.com>
7630 * python/py-framefilter.c (py_print_single_arg)
7631 (enumerate_locals, py_print_args, py_print_frame): Remove some
7632 uses of is_mi_like_p.
7634 2018-04-30 Tom Tromey <tom@tromey.com>
7637 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
7638 * ui-out.h (ui_out::is_mi_like_p): Now const.
7639 (ui_out::do_is_mi_like_p): Now const.
7640 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
7642 2018-04-30 Tom Tromey <tom@tromey.com>
7644 * varobj.c (varobj_set_visualizer): Use new_reference.
7645 * python/python.c (gdbpy_decode_line): Use new_reference.
7646 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
7649 2018-04-30 Tom Tromey <tom@tromey.com>
7651 * varobj.c (install_new_value): Use new_reference.
7652 * value.h (value_incref): Return void. Swap intro comment with
7654 * value.c (set_value_parent): Use new_reference.
7655 (value_incref): Return void. Update intro comment.
7656 (release_value): Use new_reference.
7657 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
7659 2018-04-30 Tom Tromey <tom@tromey.com>
7661 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
7662 * gdb_bfd.h (new_bfd_ref): Remove.
7663 (gdb_bfd_open): Update comment.
7664 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
7665 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
7666 (gdb_bfd_fdopenr): Use new_reference.
7667 * exec.c (exec_file_attach): Use new_reference.
7669 2018-04-30 Tom Tromey <tom@tromey.com>
7671 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
7674 2018-04-30 Tom Tromey <tom@tromey.com>
7676 * jit.c (jit_read_code_entry): Use type_align.
7677 * i386-tdep.c (i386_gdbarch_init): Don't call
7678 set_gdbarch_long_long_align_bit.
7679 * gdbarch.sh: Remove long_long_align_bit.
7680 * gdbarch.c, gdbarch.h: Rebuild.
7681 * arc-tdep.c (arc_type_align): New function.
7682 (arc_gdbarch_init): Use arc_type_align. Don't call
7683 set_gdbarch_long_long_align_bit.
7685 2018-04-30 Tom Tromey <tom@tromey.com>
7687 * rust-lang.c (rust_type_alignment): Remove.
7688 (rust_composite_type): Use type_align.
7690 2018-04-30 Tom Tromey <tom@tromey.com>
7692 * NEWS: Mention Type.align.
7693 * python/py-type.c (typy_get_alignof): New function.
7694 (type_object_getset): Add "alignof".
7696 2018-04-30 Tom Tromey <tom@tromey.com>
7700 * std-operator.def (UNOP_ALIGNOF): New operator.
7701 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
7703 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
7704 * c-lang.c (c_op_print_tab): Add alignof.
7705 * c-exp.y (ALIGNOF): New token.
7706 (exp): Add "ALIGNOF" production.
7707 (ident_tokens): Add _Alignof and alignof.
7709 2018-04-30 Tom Tromey <tom@tromey.com>
7711 * i386-tdep.c (i386_type_align): New function.
7712 (i386_gdbarch_init): Update.
7713 * gdbarch.sh (type_align): New method.
7714 * gdbarch.c, gdbarch.h: Rebuild.
7715 * arch-utils.h (default_type_align): Declare.
7716 * arch-utils.c (default_type_align): New function.
7717 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
7718 (struct type) <align_log2>: New field.
7719 <instance_flags>: Now a bitfield.
7720 (TYPE_RAW_ALIGN): New macro.
7721 (type_align, type_raw_align, set_type_align): Declare.
7722 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
7724 * dwarf2read.c (quirk_rust_enum): Set type alignment.
7725 (get_alignment, maybe_set_alignment): New functions.
7726 (read_structure_type, read_enumeration_type, read_array_type)
7727 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
7728 (read_subrange_type, read_base_type): Set type alignment.
7730 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
7732 * dwarf2read.c (read_index_from_section): Use bool.
7734 2018-04-29 Fabian Groffen <grobian@gentoo.org>
7737 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
7740 2018-04-29 John Reiser <jreiser@BitWagon.com>
7743 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
7744 last step, and do it atomically.
7746 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
7748 * compile/compile-c-types.c (convert_int, convert_float):
7751 2018-04-27 Tom Tromey <tom@tromey.com>
7754 * rust-lang.c (rust_inclusive_range_type_p): New function.
7755 (rust_range): Handle inclusive ranges.
7756 (rust_compute_range): Likewise.
7757 * rust-exp.y (struct rust_op) <inclusive>: New field.
7758 (DOTDOTEQ): New constant.
7759 (range_expr): Add "..=" productions.
7760 (operator_tokens): Add "..=" token.
7761 (ast_range): Add "inclusive" parameter.
7762 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
7764 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
7766 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
7767 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
7769 * expprint.c (print_subexp_standard): Handle new bounds values.
7770 (dump_subexp_body_standard): Likewise.
7772 2018-04-27 Tom Tromey <tom@tromey.com>
7774 * configure: Rebuild.
7775 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
7776 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
7778 (class symbol_needs_eval_context): Likewise.
7779 * dwarf2read.c (mock_mapped_index::symbol_name_count)
7780 (mock_mapped_index::symbol_name_at): Use "override". Remove
7782 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
7784 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
7785 * aarch64-tdep.c (instruction_reader::read): Use "override".
7786 (instruction_reader_test::read): Likewise.
7787 * arm-tdep.c (instruction_reader::read): Use "override".
7788 (instruction_reader_thumb::read): Likewise.
7790 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
7793 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
7794 instead of remote_send.
7795 (remote_send): Remove.
7797 2018-04-26 Pedro Alves <palves@redhat.com>
7799 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
7800 find_function_start_sal instead of find_pc_line.
7802 2018-04-26 Pedro Alves <palves@redhat.com>
7804 * breakpoint.c (set_breakpoint_location_function): Handle
7806 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
7807 * elfread.c (elf_symtab_read): Give data symbols with
7808 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
7809 (elf_rel_plt_read): Update comment.
7810 * linespec.c (convert_linespec_to_sals): Handle
7812 (minsym_found): Handle mst_data_gnu_ifunc.
7813 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
7814 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
7815 * parse.c (find_minsym_type_and_address): Handle
7817 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
7818 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
7819 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
7821 <mst_data_gnu_ifunc>: New enumerator.
7823 2018-04-26 Pedro Alves <palves@redhat.com>
7825 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
7826 (lookup_minimal_symbol_by_pc_section): ... this. Replace
7827 'want_trampoline' parameter by a lookup_msym_prefer parameter.
7829 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
7830 (lookup_minimal_symbol_by_pc): Adjust.
7831 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
7832 (lookup_solib_trampoline_symbol_by_pc): Adjust.
7833 * minsyms.h (lookup_msym_prefer): New enum.
7834 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
7835 parameter by a lookup_msym_prefer parameter.
7837 2018-04-26 Pedro Alves <palves@redhat.com>
7839 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
7840 ends in "@plt" instead of looking at the symbol's section.
7842 2018-04-26 Pedro Alves <palves@redhat.com>
7844 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
7846 (find_pc_partial_function_gnu_ifunc): Rename to ...
7847 (find_pc_partial_function): ... this, and remove references to
7849 (find_pc_partial_function): Delete old implementation.
7850 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
7852 2018-04-26 Pedro Alves <palves@redhat.com>
7854 * linespec.c (struct bound_minimal_symbol_search_key): New.
7855 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
7856 skip first line if we found a GNU ifunc minimal symbol by name.
7857 (compare_msymbols): Change parameters to work with a destructured
7859 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
7862 2018-04-26 Pedro Alves <palves@redhat.com>
7864 * breakpoint.c (set_breakpoint_location_function): Don't resolve
7865 ifunc targets here. Instead, if we have an ifunc minsym, use its
7867 (add_location_to_breakpoint): Store the minsym and the objfile in
7868 the breakpoint location.
7869 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
7870 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
7871 Record the minsym in the sal.
7872 * symtab.h (symtab_and_line) <msymbol>: New field.
7874 2018-04-26 Pedro Alves <palves@redhat.com>
7876 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
7877 unless we actually resolved the ifunc.
7879 2018-04-26 Pedro Alves <palves@redhat.com>
7881 * c-exp.y (variable production): Prefer ifunc minsyms over
7882 regular function symbols.
7883 * symtab.c (find_gnu_ifunc): New function.
7884 * minsyms.h (lookup_msym_prefer): New enum.
7885 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
7886 parameter by a lookup_msym_prefer parameter.
7887 * symtab.h (find_gnu_ifunc): New declaration.
7889 2018-04-26 Pedro Alves <palves@redhat.com>
7891 * blockframe.c (find_gnu_ifunc_target_type): New function.
7892 (find_function_type): New.
7893 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
7894 return a value with a memory address.
7895 (eval_call): For calls to GNU ifunc functions, try to find the
7896 type of the target function from the type that the resolver
7898 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
7900 * infcall.c (find_function_return_type): Delete.
7901 (find_function_addr): Add 'function_type' parameter. For calls to
7902 GNU ifunc functions, try to find the type of the target function
7903 from the type that the resolver returns, and return it via
7905 (call_function_by_hand_dummy): Adjust to use the function type
7906 returned by find_function_addr.
7907 (find_function_addr): Add 'function_type' parameter and move
7909 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
7912 2018-04-26 Pedro Alves <palves@redhat.com>
7914 * c-exp.y (variable production): Skip finding an alias for ifunc
7917 2018-04-26 Pedro Alves <palves@redhat.com>
7919 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
7921 2018-04-25 Pedro Alves <palves@redhat.com>
7923 * infcmd.c (kill_command): Print the pid as string, not the whole
7924 thread's ptid. Add comment. s/has been killed/killed/ in output
7926 * remote.c (remote_detach_1): Print the pid as string, not the
7927 whole thread's ptid.
7929 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
7930 Sergio Durigan Junior <sergiodj@redhat.com>
7931 Pedro Alves <palves@redhat.com>
7933 * infcmd.c (kill_command): Print message when inferior has
7935 * inferior.c (print_inferior_events): Remove 'static'. Set as
7937 (add_inferior): Improve message printed when
7938 'print_inferior_events' is on.
7939 (exit_inferior): Remove message printed when
7940 'print_inferior_events' is on.
7941 (detach_inferior): Improve message printed when
7942 'print_inferior_events' is on.
7943 (initialize_inferiors): Use 'add_inferior_silent' to set
7944 'current_inferior_'.
7945 * inferior.h (print_inferior_events): Declare here as
7947 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
7948 '[Detaching...]' messages when 'print_inferior_events' is on.
7949 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
7950 as prefix/suffix for messages. Remove periods. Fix erroneous
7951 'Detaching after fork from child...', replace it by '... from
7953 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
7954 prefix/suffix when printing 'Detaching...' messages. Print
7955 them when 'print_inferior_events' is on.
7956 * remote.c (remote_detach_1): Print message when detaching
7957 from inferior and '!is_fork_parent'.
7959 2018-04-24 Tom Tromey <tom@tromey.com>
7961 * cli-out.h: Reindent.
7963 2018-04-24 Tom Tromey <tom@tromey.com>
7965 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
7966 (cli_ui_out::do_field_string): Use fputs_filtered.
7967 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
7969 2018-04-23 Tom Tromey <tom@tromey.com>
7971 * guile/scm-frame.c (gdbscm_frame_read_var): Use
7972 gdb::unique_xmalloc_ptr.
7974 2018-04-23 Tom Tromey <tom@tromey.com>
7976 * configure: Rebuild.
7978 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
7981 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
7982 prepare_for_testing. Set normal_bp to r_debug_state if target
7985 2018-04-21 Pedro Alves <palves@redhat.com>
7986 Rajendra SY <rajendra.sy@gmail.com>
7988 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
7989 * remote.c (extended_remote_attach): In all-stop mode, mark the
7990 thread as executing.
7992 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7994 * thread.c (thread_apply_all_command): Fix comment.
7995 (thread_command): Fix comment.
7997 2018-04-10 Alan Hayward <alan.hayward@arm.com>
7999 * common/tdesc.h (tdesc_create_feature): Remove xml filename
8001 * features/aarch64-core.c (create_feature_aarch64_core):
8003 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
8005 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
8007 * features/i386/32bit-avx512.c
8008 (create_feature_i386_32bit_avx512): Likewise.
8009 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
8011 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
8013 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
8015 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
8017 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
8019 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
8021 * features/i386/64bit-avx512.c
8022 (create_feature_i386_64bit_avx512): Likewise.
8023 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
8025 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
8027 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
8029 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
8031 * features/i386/64bit-segments.c
8032 (create_feature_i386_64bit_segments): Likewise.
8033 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
8035 * features/i386/x32-core.c
8036 (create_feature_i386_x32_core): Likewise.
8037 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
8038 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
8039 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
8040 * target-descriptions.c: In generated code, don't pass xml
8043 2018-04-18 Alan Hayward <alan.hayward@arm.com>
8045 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
8046 (print_xml_feature::visit_post): Likewise.
8047 (print_xml_feature::visit): Likewise.
8048 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
8049 (print_xml_feature): Add new class.
8050 * regformats/regdat.sh: Null xmltarget on feature targets.
8051 * target-descriptions.c (struct target_desc): Add xmltarget.
8052 (maintenance_check_tdesc_xml_convert): Add unittest function.
8053 (tdesc_get_features_xml): Add function to get xml.
8054 (maintenance_check_xml_descriptions): Test xml generation.
8055 * xml-tdesc.c (string_read_description_xml): Add function.
8056 * xml-tdesc.h (string_read_description_xml): Add declaration.
8058 2018-04-18 Alan Hayward <alan.hayward@arm.com>
8060 * features/Makefile: Add feature marker to targets with new style
8061 target descriptions.
8062 * regformats/aarch64.dat: Regenerate.
8063 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
8064 * regformats/i386/amd64-avx-linux.dat: Likewise.
8065 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
8066 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
8067 * regformats/i386/amd64-linux.dat: Likewise.
8068 * regformats/i386/amd64-mpx-linux.dat: Likewise.
8069 * regformats/i386/amd64.dat: Likewise.
8070 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
8071 * regformats/i386/i386-avx-linux.dat: Likewise.
8072 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
8073 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
8074 * regformats/i386/i386-linux.dat: Likewise.
8075 * regformats/i386/i386-mmx-linux.dat: Likewise.
8076 * regformats/i386/i386-mpx-linux.dat: Likewise.
8077 * regformats/i386/i386.dat: Likewise.
8078 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
8079 * regformats/i386/x32-avx-linux.dat: Likewise.
8080 * regformats/i386/x32-linux.dat: Likewise.
8081 * regformats/tic6x-c62x-linux.dat: Likewise.
8082 * regformats/tic6x-c64x-linux.dat: Likewise.
8083 * regformats/tic6x-c64xp-linux.dat: Likewise.
8084 * regformats/regdat.sh: Parse feature marker.
8086 2018-04-18 Alan Hayward <alan.hayward@arm.com>
8088 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
8089 (tdesc_osabi_name): Likewise.
8090 * target-descriptions.c (tdesc_architecture_name): Add new
8092 (tdesc_osabi_name): Likewise.
8094 2018-04-18 Alan Hayward <alan.hayward@arm.com>
8096 * common/tdesc.c (tdesc_predefined_type): Move to here.
8097 (tdesc_named_type): Likewise.
8098 (tdesc_create_vector): Likewise.
8099 (tdesc_create_struct): Likewise.
8100 (tdesc_set_struct_size): Likewise.
8101 (tdesc_create_union): Likewise.
8102 (tdesc_create_flags): Likewise.
8103 (tdesc_create_enum): Likewise.
8104 (tdesc_add_field): Likewise.
8105 (tdesc_add_typed_bitfield): Likewise.
8106 (tdesc_add_bitfield): Likewise.
8107 (tdesc_add_flag): Likewise.
8108 (tdesc_add_enum_value): Likewise.
8109 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
8110 (struct tdesc_type_vector): Likewise.
8111 (struct tdesc_type_field): Likewise.
8112 (struct tdesc_type_with_fields): Likewise.
8113 (tdesc_create_enum): Add declaration.
8114 (tdesc_add_typed_bitfield): Likewise.
8115 (tdesc_add_enum_value): Likewise.
8116 * target-descriptions.c (tdesc_type_field): Move from here.
8117 (tdesc_type_builtin): Likewise.
8118 (tdesc_type_vector): Likewise.
8119 (tdesc_type_with_fields): Likewise.
8120 (tdesc_predefined_types): Likewise.
8121 (tdesc_named_type): Likewise.
8122 (tdesc_create_vector): Likewise.
8123 (tdesc_create_struct): Likewise.
8124 (tdesc_set_struct_size): Likewise.
8125 (tdesc_create_union): Likewise.
8126 (tdesc_create_flags): Likewise.
8127 (tdesc_create_enum): Likewise.
8128 (tdesc_add_field): Likewise.
8129 (tdesc_add_typed_bitfield): Likewise.
8130 (tdesc_add_bitfield): Likewise.
8131 (tdesc_add_flag): Likewise.
8132 (tdesc_add_enum_value): Likewise.
8133 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
8134 (tdesc_add_typed_bitfield): Likewise.
8135 (tdesc_add_enum_value): Likewise.
8137 2018-04-18 Alan Hayward <alan.hayward@arm.com>
8139 * common/tdesc.c (tdesc_feature::accept): Move to here.
8140 (tdesc_feature::operator==): Likewise.
8141 (tdesc_create_reg): Likewise.
8142 * common/tdesc.h (tdesc_type_kind): Likewise.
8143 (struct tdesc_type): Likewise.
8144 (struct tdesc_feature): Likewise.
8145 * regformats/regdat.sh: Create a feature.
8146 * target-descriptions.c (tdesc_type_kind): Move from here.
8147 (tdesc_type): Likewise.
8148 (tdesc_type_up): Likewise.
8149 (tdesc_feature): Likewise.
8150 (tdesc_create_reg): Likewise.
8152 2018-04-18 Alan Hayward <alan.hayward@arm.com>
8154 * Makefile.in: Add arch/tdesc.c
8155 * common/tdesc.c: New file.
8156 * common/tdesc.h (tdesc_element_visitor): Move to here.
8157 (tdesc_element): Likewise.
8158 (tdesc_reg): Likewise.
8159 (tdesc_reg_up): Likewise.
8160 * regformats/regdef.h (reg): Add offset to constructors.
8161 * target-descriptions.c (tdesc_element_visitor): Move from here.
8162 (tdesc_element): Likewise.
8163 (tdesc_reg): Likewise.
8164 (tdesc_reg_up): Likewise.
8166 2018-04-17 Tom Tromey <tom@tromey.com>
8168 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
8171 2018-04-17 Tom Tromey <tom@tromey.com>
8173 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
8175 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
8177 * symtab.c (print_symbol_info): Skip printing filename and line
8178 number when `last' is NULL.
8179 (symtab_symbol_info): Use empty string instead of NULL for first
8180 invocation of print_symbol_info.
8181 (rbreak_command): Pass NULL to `last' parameter of
8184 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
8186 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
8189 2018-04-16 Pedro Alves <palves@redhat.com>
8191 * MAINTAINERS (sh): Remove.
8192 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
8193 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
8194 (ALLDEPFILES): Remove sh64-tdep.c.
8195 * NEWS: Mentions that support for SH-5/SH64 is removed.
8196 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
8197 (sh*-*-openbsd*): Ditto.
8198 (sh64-*-elf*): Remove.
8200 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
8201 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
8202 * sh-tdep.c: No longer include "sh64-tdep.h".
8203 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
8204 * sh64-tdep.c, sh64-tdep.h: Remove files.
8206 2018-04-16 Pedro Alves <palves@redhat.com>
8208 * MAINTAINERS: Remove m88k.
8209 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
8210 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
8211 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
8212 * NEWS: Mention that support for m88k was removed.
8213 * configure.host (m88*-*-*): Remove support.
8214 * configure.nat (m88k-*-*): Remove support.
8215 * configure.tgt (m88*-*-openbsd*): Remove.
8216 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
8218 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
8220 * configure.tgt (x86_tobjs): New variable.
8221 (amd64_tobjs, i386_tobjs): Use it.
8223 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8225 * symtab.c (print_symbol_info): Precede the symbol definition by
8226 the line number when available.
8227 * NEWS: Advertise this enhancement.
8229 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
8231 * NEWS (New options): announce set/show record btrace cpu.
8232 * btrace.c: Include record-btrace.h.
8233 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
8234 the vendor is unknown.
8235 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
8236 Maybe overwrite the btrace configuration's cpu.
8237 (btrace_compute_ftrace): Add cpu parameter. Update callers.
8238 (btrace_fetch): Add cpu parameter. Update callers.
8239 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
8240 Maybe overwrite the btrace configuration's cpu. Skip enabling
8241 errata workarounds if the vendor is unknown.
8242 * python/py-record-btrace.c: Include record-btrace.h.
8243 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
8244 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
8245 * record-btrace.c (record_btrace_cpu_state_kind): New.
8246 (record_btrace_cpu): New.
8247 (set_record_btrace_cpu_cmdlist): New.
8248 (record_btrace_get_cpu): New.
8249 (require_btrace_thread, record_btrace_info)
8250 (record_btrace_resume_thread): Call record_btrace_get_cpu.
8251 (cmd_set_record_btrace_cpu_none): New.
8252 (cmd_set_record_btrace_cpu_auto): New.
8253 (cmd_set_record_btrace_cpu): New.
8254 (cmd_show_record_btrace_cpu): New.
8255 (_initialize_record_btrace): Initialize set/show record btrace cpu
8257 * record-btrace.h (record_btrace_get_cpu): New.
8259 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
8261 * record.c (set_record_command): Fix typo in message.
8263 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
8265 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
8267 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
8269 * infrun.c (process_event_stop_test): Call
8270 gdbarch_in_indirect_branch_thunk.
8271 * gdbarch.sh (in_indirect_branch_thunk): New.
8272 * gdbarch.c: Regenerated.
8273 * gdbarch.h: Regenerated.
8276 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
8277 (HFILES_NO_SRCDIR): Add x86-tdep.h.
8278 (ALLDEPFILES): Add x86-tdep.c.
8279 * arch-utils.h (default_in_indirect_branch_thunk): New.
8280 * arch-utils.c (default_in_indirect_branch_thunk): New.
8281 * i386-tdep: Include x86-tdep.h.
8282 (i386_in_indirect_branch_thunk): New.
8283 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
8285 * amd64-tdep: Include x86-tdep.h.
8286 (amd64_in_indirect_branch_thunk): New.
8287 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
8289 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
8292 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
8293 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
8294 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
8297 2018-04-12 Tom Tromey <tom@tromey.com>
8299 * rust-lang.c (rust_print_struct_def): Remove univariant code.
8300 (rust_evaluate_subexp): Likewise.
8302 2018-04-12 Pedro Alves <palves@redhat.com>
8304 * procfs.c (procfs_detach): Make forward declaration's prototype
8305 match definition's protototype.
8306 (proc_get_LDT_entry): Remove stale do_cleanups call.
8308 2018-04-12 Pedro Alves <palves@redhat.com>
8310 * target.h (target_ops::to_has_exited): Delete.
8311 (target_has_exited): Delete.
8312 * target-delegates.c: Regenerate.
8314 2018-04-11 Pedro Alves <palves@redhat.com>
8316 * target.c (fileio_fh_t::t): Add comment.
8317 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
8318 (target_fileio_close): Handle a NULL target.
8319 (invalidate_fileio_fh): New.
8320 (target_close): Call it.
8321 * remote.c (remote_hostio_send_command): No longer check whether
8322 remote_desc is open.
8324 2018-04-11 Pedro Alves <palves@redhat.com>
8326 * target.c (fileio_fh_t): Make it a named struct instead of a
8328 (fileio_fh_t::is_closed): New method.
8329 (DEF_VEC_O (fileio_fh_t)): Remove.
8330 (fileio_fhandles): Now a std::vector.
8331 (is_closed_fileio_fh): Delete.
8332 (acquire_fileio_fd): Adjust. Rename parameters.
8333 (release_fileio_fd): Adjust.
8334 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
8335 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
8336 (target_fileio_close): Adjust.
8338 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
8340 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
8343 2018-04-10 Pedro Alves <palves@redhat.com>
8345 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
8346 (scoped_finish_thread_state): New class.
8347 * infcmd.c (run_command_1): Use it instead of finish_thread_state
8349 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
8350 (fetch_inferior_event, normal_stop): Likewise.
8351 * thread.c (finish_thread_state_cleanup): Delete.
8353 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8354 Pedro Alves <palves@redhat.com>
8356 * value.c: Include "selftest.h" and "common/array-view.h".
8357 (struct range) <operator ==>: New.
8358 (test_ranges_contain): New.
8359 (check_ranges_vector): New.
8360 (test_insert_into_bit_range_vector): New.
8361 (_initialize_values): Register selftests.
8362 * common/array-view.h (operator==, operator!=): New.
8364 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8366 * common/gdb_vecs.h (unordered_remove): Add overload that takes
8368 * inline-frame.c: Include <algorithm>.
8369 (struct inline_state): Add constructor.
8370 (inline_state_s): Remove.
8371 (DEF_VEC_O(inline_state_s)): Remove.
8372 (inline_states): Change type to std::vector.
8373 (find_inline_frame_state): Adjust to std::vector.
8374 (allocate_inline_frame_state): Remove.
8375 (clear_inline_frame_state): Adjust to std::vector.
8376 (skip_inline_frames): Adjust to std::vector.
8378 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8380 * tracepoint.h (struct trace_state_variable): Add constructor.
8381 <name>: Change type to std::string.
8382 * tracepoint.c (tsv_s): Remove.
8383 (DEF_VEC_O(tsv_s)): Remove.
8384 (tvariables): Change to std::vector.
8385 (create_trace_state_variable): Adjust to std::vector.
8386 (find_trace_state_variable): Likewise.
8387 (find_trace_state_variable_by_number): Likewise.
8388 (delete_trace_state_variable): Likewise.
8389 (trace_variable_command): Adjust to std::string.
8390 (delete_trace_variable_command): Likewise.
8391 (tvariables_info_1): Adjust to std::vector.
8392 (save_trace_state_variables): Likewise.
8393 (start_tracing): Likewise.
8394 (merge_uploaded_trace_state_variables): Adjust to std::vector
8396 * target.h (struct target_ops)
8397 <to_download_trace_state_variable>: Pass reference to
8398 trace_state_variable.
8399 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
8400 * target-delegates.c: Re-generate.
8401 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
8402 (mi_tsv_deleted): Likewise.
8403 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
8404 * remote.c (remote_download_trace_state_variable): Change
8405 pointer to reference and adjust.
8406 * make-target-delegates (parse_argtypes): Handle references.
8407 (write_function_header): Likewise.
8408 (munge_type): Likewise.
8410 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8412 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8413 string_view-selftests.c.
8414 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
8416 * unittests/basic_string_view/cons/char/1.cc: Likewise.
8417 * unittests/basic_string_view/cons/char/2.cc: Likewise.
8418 * unittests/basic_string_view/cons/char/3.cc: Likewise.
8419 * unittests/basic_string_view/element_access/char/1.cc:
8421 * unittests/basic_string_view/element_access/char/empty.cc:
8423 * unittests/basic_string_view/element_access/char/front_back.cc:
8425 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
8426 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
8428 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
8430 * unittests/basic_string_view/modifiers/swap/char/1.cc:
8432 * unittests/basic_string_view/operations/compare/char/1.cc:
8434 * unittests/basic_string_view/operations/compare/char/13650.cc:
8436 * unittests/basic_string_view/operations/copy/char/1.cc:
8438 * unittests/basic_string_view/operations/data/char/1.cc:
8440 * unittests/basic_string_view/operations/find/char/1.cc:
8442 * unittests/basic_string_view/operations/find/char/2.cc:
8444 * unittests/basic_string_view/operations/find/char/3.cc:
8446 * unittests/basic_string_view/operations/find/char/4.cc:
8448 * unittests/basic_string_view/operations/rfind/char/1.cc:
8450 * unittests/basic_string_view/operations/rfind/char/2.cc:
8452 * unittests/basic_string_view/operations/rfind/char/3.cc:
8454 * unittests/basic_string_view/operations/substr/char/1.cc:
8456 * unittests/basic_string_view/operators/char/2.cc: Likewise.
8457 * unittests/string_view-selftests.c: New file.
8459 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8461 * unittests/basic_string_view/capacity/1.cc: New file.
8462 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
8463 * unittests/basic_string_view/cons/char/1.cc: New file.
8464 * unittests/basic_string_view/cons/char/2.cc: New file.
8465 * unittests/basic_string_view/cons/char/3.cc: New file.
8466 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
8467 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
8468 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
8469 * unittests/basic_string_view/element_access/char/1.cc: New file.
8470 * unittests/basic_string_view/element_access/char/2.cc: New file.
8471 * unittests/basic_string_view/element_access/char/empty.cc: New file.
8472 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
8473 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
8474 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
8475 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
8476 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
8477 * unittests/basic_string_view/include.cc: New file.
8478 * unittests/basic_string_view/inserters/char/1.cc: New file.
8479 * unittests/basic_string_view/inserters/char/2.cc: New file.
8480 * unittests/basic_string_view/inserters/char/3.cc: New file.
8481 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
8482 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
8483 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
8484 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
8485 * unittests/basic_string_view/literals/types.cc: New file.
8486 * unittests/basic_string_view/literals/values.cc: New file.
8487 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
8488 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
8489 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
8490 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
8491 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
8492 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
8493 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
8494 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
8495 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
8496 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
8497 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
8498 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
8499 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
8500 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
8501 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
8502 * unittests/basic_string_view/operations/data/char/1.cc: New file.
8503 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
8504 * unittests/basic_string_view/operations/find/char/1.cc: New file.
8505 * unittests/basic_string_view/operations/find/char/2.cc: New file.
8506 * unittests/basic_string_view/operations/find/char/3.cc: New file.
8507 * unittests/basic_string_view/operations/find/char/4.cc: New file.
8508 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
8509 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
8510 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
8511 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
8512 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
8513 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
8514 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
8515 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
8516 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
8517 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
8518 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
8519 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
8520 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
8521 * unittests/basic_string_view/operators/char/2.cc: New file.
8522 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
8523 * unittests/basic_string_view/range_access/char/1.cc: New file.
8524 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
8525 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
8526 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
8527 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
8528 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
8529 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
8530 * unittests/basic_string_view/requirements/typedefs.cc: New file.
8531 * unittests/basic_string_view/typedefs.cc: New file.
8532 * unittests/basic_string_view/types/1.cc: New file.
8534 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8536 * common/gdb_string_view.h: Remove libstdc++ implementation
8537 details, adjust to gdb reality.
8538 * common/gdb_string_view.tcc: Likewise.
8539 * cli/cli-script.c (struct string_view): Remove.
8540 (user_args) <m_args>: Change element type to gdb::string_view.
8541 (user_args::insert_args): Adjust.
8543 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8545 * common/gdb_string_view.h: New file.
8546 * common/gdb_string_view.tcc: New file.
8548 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8550 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
8551 * configure: Re-generate.
8553 2018-04-09 Pedro Alves <palves@redhat.com>
8555 * gdbarch.sh: Include "observable.h" instead of "observer.h".
8556 (set_target_gdbarch): Call
8557 gdb::observers::architecture_changed.notify instead of
8558 observer_notify_architecture_changed.
8560 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8562 * tracepoint.c (struct current_traceframe_cleanup): Remove.
8563 (do_restore_current_traceframe_cleanup): Remove.
8564 (restore_current_traceframe_cleanup_dtor): Remove.
8565 (make_cleanup_restore_current_traceframe): Remove.
8566 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
8568 * tracepoint.h (struct scoped_restore_current_traceframe): New.
8569 * infrun.c (fetch_inferior_event): Use
8570 scoped_restore_current_traceframe.
8572 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8574 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
8576 <n_allocated_type_units>: Remove.
8577 <all_type_units>: Change to std::vector.
8578 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
8579 to std::vector change.
8580 (dwarf2_per_objfile::get_cutu): Likewise.
8581 (dwarf2_per_objfile::get_tu): Likewise.
8582 (create_signatured_type_table_from_index): Likewise.
8583 (create_signatured_type_table_from_debug_names): Likewise.
8584 (dw2_symtab_iter_next): Likewise.
8585 (dw2_print_stats): Likewise.
8586 (dw2_expand_all_symtabs): Likewise.
8587 (dw2_expand_marked_cus): Likewise.
8588 (dw2_debug_names_iterator::next): Likewise.
8589 (dwarf2_initialize_objfile): Likewise.
8590 (add_signatured_type_cu_to_table): Likewise.
8591 (create_all_type_units): Likewise.
8592 (add_type_unit): Likewise.
8593 (struct tu_abbrev_offset): Add constructor.
8594 (build_type_psymtabs_1): Adjust to std::vector change.
8595 (print_tu_stats): Likewise.
8596 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
8597 (write_debug_names): Likewise.
8599 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8601 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
8602 Make an std::vector.
8603 <n_comp_units>: Remove.
8604 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
8605 to std::vector change.
8606 (dwarf2_per_objfile::get_cutu): Likewise.
8607 (dwarf2_per_objfile::get_cu): Likewise.
8608 (create_cus_from_index): Likewise.
8609 (create_addrmap_from_index): Likewise.
8610 (create_addrmap_from_aranges): Likewise.
8611 (dwarf2_read_index): Likewise.
8612 (dw2_find_last_source_symtab): Likewise.
8613 (dw2_map_symtabs_matching_filename): Likewise.
8614 (dw2_symtab_iter_next): Likewise.
8615 (dw2_print_stats): Likewise.
8616 (dw2_expand_all_symtabs): Likewise.
8617 (dw2_expand_symtabs_with_fullname): Likewise.
8618 (dw2_expand_marked_cus): Likewise.
8619 (dw2_map_symbol_filenames): Likewise.
8620 (create_cus_from_debug_names): Likewise.
8621 (dwarf2_read_debug_names): Likewise.
8622 (dw2_debug_names_iterator::next): Likewise.
8623 (dwarf2_initialize_objfile): Likewise.
8624 (set_partial_user): Likewise.
8625 (dwarf2_build_psymtabs_hard): Likewise.
8626 (read_comp_units_from_section): Remove arguments, adjust to
8628 (create_all_comp_units): Adjust to std::vector and
8629 read_comp_units_from_section changes.
8630 (dwarf2_find_containing_comp_unit): Adjust to std::vector
8632 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
8633 (psyms_seen_size): Likewise.
8634 (write_gdbindex): Likewise.
8635 (write_debug_names): Likewise.
8637 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8639 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
8640 with dwarf2_per_objfile.
8641 (create_cus_from_index): Likewise.
8642 (create_signatured_type_table_from_index): Likewise.
8643 (dwarf2_read_index): Likewise.
8644 (dwarf2_initialize_objfile): Likewise.
8645 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
8646 per_cu rather than get_dwarf2_per_objfile.
8648 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8650 * dwarf2read.h (struct signatured_type): Forward declare.
8651 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
8653 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
8654 (dw2_get_cutu): ...this.
8655 (dwarf2_per_objfile::get_cu): Rename from...
8656 (dw2_get_cu): ...this.
8657 (dwarf2_per_objfile::get_tu): New.
8658 (create_addrmap_from_index): Adjust.
8659 (create_addrmap_from_aranges): Adjust.
8660 (dw2_find_last_source_symtab): Adjust.
8661 (dw2_map_symtabs_matching_filename): Adjust.
8662 (dw2_symtab_iter_next): Adjust.
8663 (dw2_print_stats): Adjust.
8664 (dw2_expand_all_symtabs): Adjust.
8665 (dw2_expand_symtabs_with_fullname): Adjust.
8666 (dw2_expand_marked_cus): Adjust.
8667 (dw_expand_symtabs_matching_file_matcher): Adjust.
8668 (dw2_map_symbol_filenames): Adjust.
8669 (dw2_debug_names_iterator::next): Adjust.
8670 (dwarf2_initialize_objfile): Adjust.
8671 (set_partial_user): Adjust.
8672 (dwarf2_build_psymtabs_hard): Adjust.
8674 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8676 * dwarf2read.c (create_signatured_type_table_from_debug_names):
8677 Remove unused variables.
8678 (dw2_map_symtabs_matching_filename): Likewise.
8679 (dwarf2_record_block_ranges): Likewise.
8680 (dwarf2_read_addr_index): Likewise.
8681 (follow_die_offset): Likewise.
8683 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8685 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
8686 to symbol_file_add_main.
8688 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8691 * mi/mi-console.c (do_fputc_async_safe): New.
8692 (mi_console_file::write_async_safe): New.
8693 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
8694 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
8696 * ui-file.c (ui_file::putstrn): Adjust call to
8697 fputstrn_unfiltered.
8698 * utils.c (printchar): Replace do_fputs and do_fprintf
8699 parameters by do_fputc.
8700 (fputstr_filtered): Adjust call to printchar.
8701 (fputstr_unfiltered): Likewise.
8702 (fputstrn_filtered): Likewise.
8703 (fputstrn_unfiltered): Add do_fputc parameter, pass to
8705 * utils.h (do_fputc_ftype): New typedef.
8706 (fputstrn_unfiltered): Add do_fputc parameter.
8708 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8710 * regformats/i386/i386-avx.dat: Remove.
8712 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
8715 * amd64-tdep.c (amd64_none_init_abi): New function.
8716 (amd64_x32_none_init_abi): New function.
8717 (_initialize_amd64_tdep): Register handlers for x86-64 and
8718 x64_32 with GDB_OSABI_NONE.
8719 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
8720 GDB_OSABI_NONE osabi.
8722 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
8725 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
8727 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
8728 * osabi.c (gdb_osabi_names): Add "unknown" entry.
8730 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
8732 * common/byte-vector.h (char_vector): New type.
8733 * target.h (target_read_alloc): Return
8734 gdb::optional<byte_vector>.
8735 (target_read_stralloc): Return gdb::optional<char_vector>.
8736 (target_get_osdata): Return gdb::optional<char_vector>.
8737 * target.c (target_read_alloc_1): Templatize. Replacement
8738 manual memory management with vector.
8739 (target_read_alloc): Change return type, adjust.
8740 (target_read_stralloc): Change return type, adjust.
8741 (target_get_osdata): Change return type, adjust.
8742 * auxv.c (struct auxv_info) <length>: Remove.
8743 <data>: Change type to gdb::optional<byte_vector>.
8744 (auxv_inferior_data_cleanup): Free auxv_info with delete.
8745 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
8746 (target_auxv_search): Adjust.
8747 (fprint_target_auxv): Adjust.
8748 * avr-tdep.c (avr_io_reg_read_command): Adjust.
8749 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
8750 (linux_make_corefile_notes): Adjust.
8751 * osdata.c (get_osdata): Adjust.
8752 * remote.c (remote_get_threads_with_qxfer): Adjust.
8753 (remote_memory_map): Adjust.
8754 (remote_traceframe_info): Adjust.
8755 (btrace_read_config): Adjust.
8756 (remote_read_btrace): Adjust.
8757 (remote_pid_to_exec_file): Adjust.
8758 * solib-aix.c (solib_aix_get_library_list): Adjust.
8759 * solib-dsbt.c (decode_loadmap): Don't free buf.
8760 (dsbt_get_initial_loadmaps): Adjust.
8761 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
8762 * solib-target.c (solib_target_current_sos): Adjust.
8763 * tracepoint.c (sdata_make_value): Adjust.
8764 * xml-support.c (xinclude_start_include): Adjust.
8765 (xml_fetch_content_from_file): Adjust.
8766 * xml-support.h (xml_fetch_another): Change return type.
8767 (xml_fetch_content_from_file): Change return type.
8768 * xml-syscall.c (xml_init_syscalls_info): Adjust.
8769 * xml-tdesc.c (file_read_description_xml): Adjust.
8770 (fetch_available_features_from_target): Change return type.
8771 (target_fetch_description_xml): Adjust.
8772 (target_read_description_xml): Adjust.
8774 2018-04-06 Tom Tromey <tom@tromey.com>
8776 * value.c (~value): Update.
8777 (struct value) <contents>: Now unique_xmalloc_ptr.
8778 (value_contents_bits_eq, allocate_value_contents)
8779 (value_contents_raw, value_contents_all_raw)
8780 (value_contents_for_printing, value_contents_for_printing_const)
8781 (set_value_enclosing_type): Update.
8783 2018-04-06 Tom Tromey <tom@tromey.com>
8785 * value.c (range_s): Remove typedef, VEC.
8786 (struct range): Add operator<.
8787 (range_lessthan): Remove.
8788 (ranges_contain): Change type.
8790 (struct value) <unavailable, optimized_out>: Now std::vector.
8791 (value_entirely_available)
8792 (value_entirely_covered_by_range_vector)
8793 (value_entirely_unavailable, value_entirely_optimized_out):
8795 (insert_into_bit_range_vector): Change argument type.
8796 (find_first_range_overlap): Likewise.
8797 (struct ranges_and_idx, value_contents_bits_eq)
8798 (require_not_optimized_out, require_available): Update.
8799 (ranges_copy_adjusted): Change argument types.
8800 (value_optimized_out, value_copy, value_fetch_lazy): Update.
8802 2018-04-06 Tom Tromey <tom@tromey.com>
8804 * value.c (~value): Update.
8805 (struct value) <parent>: Now a value_ref_ptr.
8806 (value_parent, set_value_parent, value_address, value_copy):
8809 2018-04-06 Tom Tromey <tom@tromey.com>
8811 * value.c (struct value): Add constructor, destructor, and member
8813 (allocate_value_lazy, value_decref): Update.
8815 2018-04-06 Tom Tromey <tom@tromey.com>
8817 * value.c (struct value) <released, next>: Remove.
8818 (all_values): Now a std::vector.
8819 (allocate_value_lazy): Update.
8820 (value_next): Remove.
8821 (value_mark, value_free_to_mark, release_value)
8822 (value_release_to_mark): Update.
8824 2018-04-06 Tom Tromey <tom@tromey.com>
8826 * value.h (fetch_subexp_value, value_release_to_mark): Update.
8827 (free_value_chain): Remove.
8828 * value.c (free_value_chain): Remove.
8829 (value_release_to_mark): Return a std::vector.
8830 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
8832 (check_condition): Update.
8833 * eval.c (fetch_subexp_value): Change "val_chain" to a
8835 * breakpoint.c (update_watchpoint): Update.
8836 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
8838 2018-04-06 Tom Tromey <tom@tromey.com>
8840 * value.h (free_all_values): Remove.
8841 * value.c (free_all_values): Remove.
8843 2018-04-06 Tom Tromey <tom@tromey.com>
8845 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
8846 (value_history_chain, value_history_count): Remove.
8847 (value_history): New global.
8848 (record_latest_value, access_value_history, show_values)
8849 (preserve_values): Update.
8851 2018-04-06 Tom Tromey <tom@tromey.com>
8853 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
8854 * varobj.c (varobj_set_display_format, varobj_set_value)
8855 (install_default_visualizer, construct_visualizer)
8856 (install_new_value, ~varobj, varobj_get_value_type)
8857 (my_value_of_variable, varobj_editable_p): Update.
8858 * c-varobj.c (c_describe_child, c_value_of_variable)
8859 (cplus_number_of_children, cplus_describe_child): Update.
8860 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
8861 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
8862 (ada_value_of_variable, ada_value_is_changeable_p): Update.
8864 2018-04-06 Tom Tromey <tom@tromey.com>
8866 * printcmd.c (last_examine_address): Change type to
8868 (do_examine, x_command): Update.
8870 2018-04-06 Tom Tromey <tom@tromey.com>
8872 * value.c (release_value): Update.
8873 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
8874 (struct bpstats) <val>: Now a value_ref_ptr.
8875 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
8876 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
8877 (~watchpoint, print_it_watchpoint, watch_command_1)
8878 (invalidate_bp_value_on_memory_change): Update.
8880 2018-04-06 Tom Tromey <tom@tromey.com>
8882 * varobj.c (varobj_clear_saved_item)
8883 (update_dynamic_varobj_children, install_new_value, ~varobj):
8885 * value.h (value_incref): Move declaration earlier.
8886 (value_decref): Rename from value_free.
8887 (struct value_ref_policy): New.
8888 (value_ref_ptr): New typedef.
8889 (struct value_deleter): Remove.
8890 (gdb_value_up): Remove typedef.
8891 (release_value): Change return type.
8892 (release_value_or_incref): Remove.
8893 * value.c (set_value_parent): Update.
8894 (value_incref): Change return type.
8895 (value_decref): Rename from value_free.
8896 (value_free_to_mark, free_all_values, free_value_chain): Update.
8897 (release_value): Return value_ref_ptr.
8898 (release_value_or_incref): Remove.
8899 (record_latest_value, set_internalvar, clear_internalvar):
8901 * stack.c (info_frame_command): Don't call value_free.
8902 * python/py-value.c (valpy_dealloc, valpy_new)
8903 (value_to_value_object): Update.
8904 * printcmd.c (do_examine): Update.
8905 * opencl-lang.c (lval_func_free_closure): Update.
8906 * mi/mi-main.c (register_changed_p): Don't call value_free.
8907 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
8908 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
8909 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
8911 * guile/scm-value.c (vlscm_free_value_smob)
8912 (vlscm_scm_from_value): Update.
8913 * frame.c (frame_register_unwind, frame_unwind_register_signed)
8914 (frame_unwind_register_unsigned, get_frame_register_bytes)
8915 (put_frame_register_bytes): Don't call value_free.
8916 * findvar.c (address_from_register): Don't call value_free.
8917 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
8918 * dwarf2loc.c (entry_data_value_free_closure)
8919 (value_of_dwarf_reg_entry, free_pieced_value_closure)
8920 (dwarf2_evaluate_loc_desc_full): Update.
8921 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
8922 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
8923 (~watchpoint, watch_command_1)
8924 (invalidate_bp_value_on_memory_change): Update.
8925 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
8927 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
8930 * warning.m4: Add -Wno-error=deprecated-register.
8931 * configure: Re-generate.
8933 2018-04-05 Tom Tromey <tom@tromey.com>
8935 * linespec.h: Remove include of "vec.h".
8937 2018-04-05 Tom Tromey <tom@tromey.com>
8939 * linespec.c (typep): Remove typedef.
8940 (find_methods, find_superclass_methods): Take a std::vector.
8941 (find_method): Use std::vector.
8943 2018-04-05 Tom Tromey <tom@tromey.com>
8945 * utils.c (compare_strings): Remove.
8946 * utils.h (compare_strings): Remove.
8947 * objc-lang.h (find_imps): Update.
8948 * objc-lang.c (find_methods): Take a std::vector.
8949 (uniquify_strings, find_imps): Likewise.
8950 * linespec.c (find_methods): Take a std::vector.
8951 (decode_objc): Use std::vector.
8952 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
8954 (find_method, find_function_symbols): Use std::vector.
8956 2018-04-05 Tom Tromey <tom@tromey.com>
8958 * completer.c (completion_tracker::completion_tracker): Remove
8960 (completion_tracker::discard_completions): Likewise.
8961 * breakpoint.c (ambiguous_names_p): Remove cast.
8962 * ada-lang.c (_initialize_ada_language): Remove cast.
8963 * utils.h (streq): Update.
8964 (streq_hash): Add new declaration.
8965 * utils.c (streq): Return bool.
8966 (streq_hash): New function.
8968 2018-04-05 Tom Tromey <tom@tromey.com>
8970 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
8971 Remove a string copy.
8973 2018-04-05 Tom Tromey <tom@tromey.com>
8975 * linespec.c (filter_results): Use std::vector.
8976 (decode_line_2, decode_line_full): Update.
8978 2018-04-05 Tom Tromey <tom@tromey.com>
8980 * linespec.c (canonical_to_fullform): Return std::string.
8981 (filter_results): Update.
8982 (struct decode_line_2_item): Add constructor.
8983 <fullform, displayform>: Now std::string.
8984 (decode_line_2_compare_items): Now a std::sort comparator.
8985 (decode_line_2): Update.
8987 2018-04-05 Tom Tromey <tom@tromey.com>
8989 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
8990 (unexpected_linespec_error): Update.
8991 (linespec_parse_basic, parse_linespec): Update.
8993 2018-04-05 Tom Tromey <tom@tromey.com>
8995 * linespec.c (linespec_parse_basic): Reindent.
8997 2018-04-05 Tom Tromey <tom@tromey.com>
8999 * minsyms.h (iterate_over_minimal_symbols): Update.
9000 * minsyms.c (iterate_over_minimal_symbols): Take a
9002 * linespec.c (struct collect_minsyms): Remove.
9003 (compare_msyms): Now a std::sort comparator.
9004 (add_minsym): Add parameters.
9005 (search_minsyms_for_name): Update. Use std::vector.
9007 2018-04-03 Tom Tromey <tom@tromey.com>
9009 * mipsread.c (read_alphacoff_dynamic_symtab): Use
9012 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
9014 * MAINTAINERS (Write After Approval): Add Weimin Pan.
9016 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
9019 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
9020 printing static type.
9022 2018-04-01 Tom Tromey <tom@tromey.com>
9024 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
9025 (rs6000_xfer_shared_libraries): Update.
9027 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
9029 * common/gdb_vecs.h (char_ptr): Remove.
9030 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
9032 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
9034 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
9036 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
9038 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
9040 * tracepoint.h (struct uploaded_tp): Initialize fields.
9041 <actions, step_actions, cmd_strings>: Change type to
9042 std::vector<char *>.
9043 * tracepoint.c (get_uploaded_tp): Allocate with new.
9044 (free_uploaded_tps): Free with delete.
9045 (parse_tracepoint_definition): Adjust to std::vector change.
9046 * breakpoint.c (read_uploaded_action): Likewise.
9047 (create_tracepoint_from_upload): Likewise.
9048 * ctf.c (ctf_write_uploaded_tp): Likewise.
9049 (SET_ARRAY_FIELD): Likewise.
9050 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
9052 2018-03-30 Tom Tromey <tom@tromey.com>
9054 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
9056 (svr4_keep_data_in_core): Update.
9057 (svr4_read_so_list): Update.
9059 2018-03-30 Tom Tromey <tom@tromey.com>
9061 * windows-nat.c (handle_output_debug_string, handle_exception):
9063 * target.h (target_read_string): Update.
9064 * target.c (target_read_string): Change "string" to
9066 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
9068 * solib-frv.c (frv_current_sos): Update.
9069 * solib-dsbt.c (dsbt_current_sos): Update.
9070 * solib-darwin.c (darwin_current_sos): Update.
9071 * linux-thread-db.c (inferior_has_bug): Update.
9072 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
9073 Update. Remove alloca.
9074 * ada-lang.c (ada_main_name): Update.
9076 2018-03-30 Tom Tromey <tom@tromey.com>
9078 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
9079 (struct dwo_file_deleter): New.
9080 (dwo_file_up): New typedef.
9081 (open_and_init_dwo_file): Use dwo_file_up.
9082 (free_dwo_file_cleanup): Remove.
9084 2018-03-30 Tom Tromey <tom@tromey.com>
9086 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
9087 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
9089 2018-03-30 Tom Tromey <tom@tromey.com>
9091 * dwarf2read.c (class free_cached_comp_units): New class.
9092 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
9093 (free_cached_comp_units): Remove function.
9095 2018-03-30 Tom Tromey <tom@tromey.com>
9097 * utils.h (make_cleanup_unpush_target): Remove.
9098 * inf-ptrace.c (struct target_unpusher): New.
9099 (target_unpush_up) New typedef.
9100 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
9102 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
9104 2018-03-27 Tom Tromey <tom@tromey.com>
9106 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
9108 2018-03-27 Pedro Alves <palves@redhat.com>
9109 Tom Tromey <tom@tromey.com>
9111 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
9112 destructor. Now a class.
9113 (gdb_readline_wrapper_cleanup): Remove function.
9114 (gdb_readline_wrapper): Remove cleanups.
9116 2018-03-27 Tom Tromey <tom@tromey.com>
9118 * typeprint.h (struct type_print_options) <local_typedefs,
9119 global_typedefs>: Remove "struct" keyword.
9120 (class typedef_hash_table): New class.
9121 (recursively_update_typedef_hash, add_template_parameters)
9122 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
9123 (find_typedef_in_hash): Don't declare.
9124 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
9125 (typedef_hash_table::recursively_update): Rename from
9126 recursively_update_typedef_hash. Now a member.
9127 (typedef_hash_table::add_template_parameters): Rename from
9128 add_template_parameters. Now a member.
9129 (typedef_hash_table::typedef_hash_table): Now a constructor;
9130 rename from create_typedef_hash.
9131 (typedef_hash_table::~typedef_hash_table): Now a destructor;
9132 rename from free_typedef_hash.
9133 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
9134 (do_free_global_table): Remove.
9135 (typedef_hash_table::typedef_hash_table): New constructor; renamed
9136 from copy_type_recursive.
9137 (create_global_typedef_table): Remove.
9138 (typedef_hash_table::find_global_typedef): Now a member of
9140 (typedef_hash_table::find_typedef): Rename from
9141 find_typedef_in_hash; now a member.
9142 (whatis_exp): Update.
9143 * extension.h (struct ext_lang_type_printers): Add constructor and
9145 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
9147 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
9148 Now a constructor; rename from start_ext_lang_type_printers.
9149 (ext_lang_type_printers): Now a destructor; rename from
9150 free_ext_lang_type_printers.
9151 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
9153 (c_type_print_base_struct_union): Update. Remove cleanups.
9155 2018-03-27 Tom Tromey <tom@tromey.com>
9157 * dwarf-index-write.c: Include <cmath>.
9159 2018-03-27 Joel Brobecker <brobecker@adacore.com>
9161 * NEWS: Add entry describing new "set|show varsize-limit" command.
9162 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
9164 * printcmd.c (_initialize_printcmd): Add "set var" alias of
9167 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
9169 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
9171 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
9172 * dwarf-index-common.c: New file.
9173 * dwarf-index-common.h: New file.
9174 * dwarf-index-write.c: New file.
9175 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
9176 (struct dwarf2_section_info): Move from here.
9177 (dwarf2_section_info_def): Likewise.
9178 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
9179 (offset_type): Likewise.
9180 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
9181 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
9182 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
9183 (byte_swap): Likewise.
9184 (MAYBE_SWAP): Likewise.
9185 (dwarf2_per_cu_ptr): Likewise.
9186 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
9187 (struct tu_stats): Likewise.
9188 (struct dwarf2_per_objfile): Likewise.
9189 (struct dwarf2_per_cu_data): Likewise.
9190 (struct signatured_type): Likewise.
9191 (sig_type_ptr): Likewise.
9192 (DEF_VEC_P (sig_type_ptr)): Likewise.
9193 (INDEX4_SUFFIX): Likewise.
9194 (INDEX5_SUFFIX): Likewise.
9195 (DEBUG_STR_SUFFIX): Likewise.
9196 (dwarf2_read_section): Make non-static.
9197 (mapped_index_string_hash): Move from here.
9198 (dwarf5_djb_hash): Likewise.
9199 (file_write): Likewise.
9200 (class data_buf): Likewise.
9201 (struct symtab_index_entry): Likewise.
9202 (struct mapped_symtab): Likewise.
9203 (find_slot): Likewise.
9204 (hash_expand): Likewise.
9205 (add_index_entry): Likewise.
9206 (uniquify_cu_indices): Likewise.
9207 (class c_str_view): Likewise.
9208 (class c_str_view_hasher): Likewise.
9209 (class vector_hasher): Likewise.
9210 (write_hash_table): Likewise.
9211 (psym_index_map): Likewise.
9212 (struct addrmap_index_data): Likewise.
9213 (add_address_entry): Likewise.
9214 (add_address_entry_worker): Likewise.
9215 (write_address_map): Likewise.
9216 (symbol_kind): Likewise.
9217 (write_psymbols): Likewise.
9218 (struct signatured_type_index_data): Likewise.
9219 (write_one_signatured_type): Likewise.
9220 (recursively_count_psymbols): Likewise.
9221 (recursively_write_psymbols): Likewise.
9222 (class debug_names): Likewise.
9223 (check_dwarf64_offsets): Likewise.
9224 (psyms_seen_size): Likewise.
9225 (write_gdbindex): Likewise.
9226 (write_debug_names): Likewise.
9227 (assert_file_size): Likewise.
9228 (write_psymtabs_to_index): Likewise.
9229 (save_gdb_index_command): Likewise.
9230 (_initialize_dwarf2_read): Don't register the "save gdb-index"
9232 * dwarf2read.h: New file.
9234 2018-03-27 Joel Brobecker <brobecker@adacore.com>
9237 * dwarf2read.c (dwarf2_physname): Do not return the demangled
9238 symbol name if the CU's language stores symbol names in linkage
9240 * language.h (struct language_defn)
9241 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
9242 all instances of this struct.
9244 2018-03-26 Tom Tromey <tom@tromey.com>
9246 * stack.c (backtrace_command_1): Remove verbose code.
9248 2018-03-26 Tom Tromey <tom@tromey.com>
9250 * python/py-framefilter.c (py_print_type): Don't catch
9251 exceptions. Return void.
9252 (py_print_value): Likewise.
9253 (py_print_single_arg): Likewise.
9254 (enumerate_args): Don't catch exceptions.
9255 (py_print_args): Likewise.
9256 (py_print_frame): Likewise.
9257 (gdbpy_apply_frame_filter): Catch exceptions here.
9259 2018-03-26 Tom Tromey <tom@tromey.com>
9261 * stack.c (_initialize_stack): Remove trailing newlines from help
9262 text. Add "Usage" line to "backtrace" help.
9264 2018-03-26 Tom Tromey <tom@tromey.com>
9267 * python/py-framefilter.c (py_print_args): Call wrap_hint.
9269 2018-03-26 Tom Tromey <tom@tromey.com>
9271 * python/py-framefilter.c (py_print_single_arg): Return
9272 EXT_LANG_BT_ERROR from catch.
9274 2018-03-26 Tom Tromey <tom@tromey.com>
9277 * stack.c (backtrace_command_1): Move some code into no-filters
9280 2018-03-26 Tom Tromey <tom@tromey.com>
9282 * python/py-framefilter.c (throw_quit_or_print_exception): New
9284 (gdbpy_apply_frame_filter): Use it.
9286 2018-03-26 Tom Tromey <tom@tromey.com>
9289 * python/py-framefilter.c (py_print_type, py_print_value)
9290 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
9293 2018-03-26 Tom Tromey <tom@tromey.com>
9295 * python/py-framefilter.c (enumerate_args): Use
9296 gdb::unique_xmalloc_ptr.
9298 2018-03-26 Tom Tromey <tom@tromey.com>
9300 * python/py-framefilter.c (py_print_frame): Return
9302 (gdbpy_apply_frame_filter): Update comment.
9303 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
9305 <EXT_LANG_BT_NO_FILTERS>: Change value.
9307 2018-03-26 Tom Tromey <tom@tromey.com>
9310 * stack.c (backtrace_command): Parse "hide" argument.
9311 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
9312 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
9315 2018-03-26 Tom Tromey <tom@tromey.com>
9317 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
9319 (backtrace_command): Remove "fulltrace", add "flags".
9321 2018-03-26 Tom Tromey <tom@tromey.com>
9323 * stack.c (backtrace_command): Rewrite command line parsing.
9325 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
9327 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
9329 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
9331 * filename-seen-cache.h: Add include guard.
9333 2018-03-26 Keith Seitz <keiths@redhat.com>
9335 * symfile.c (place_section): Remove "struct" from section_addr_info
9337 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
9338 "struct" keyword from section_addr_info.
9340 2018-03-26 Alan Hayward <alan.hayward@arm.com>
9342 * regformats/regdef.h (reg): Add constructors.
9344 2018-03-25 Pedro Alves <palves@redhat.com>
9346 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
9347 if then/else bodies in var_func_name extraction.
9349 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
9351 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
9352 lookup_minimal_symbol() to find symbol entry.
9353 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
9355 2018-03-23 Keith Seitz <keiths@redhat.com>
9358 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
9359 nested type definitions for C++, too.
9361 2018-03-23 Tom Tromey <tom@tromey.com>
9363 * machoread.c (struct oso_el): Add a constructor. Don't define as
9365 (macho_register_oso): Remove.
9366 (macho_symtab_read): Take a std::vector.
9367 (oso_el_compare_name): Now a std::sort comparator.
9368 (macho_symfile_read_all_oso): Take a std::vector.
9369 (macho_symfile_read): Use std::vector. Remove cleanups.
9371 2018-03-22 Tom Tromey <tom@tromey.com>
9373 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
9374 (record_full_goto_bookmark): Use std::string.
9376 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9379 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
9382 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9384 * rs6000-tdep.c (store_insn_p): New function.
9385 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
9386 and cr_reg to their unshifted values. Use store_insn_p to
9387 match LR saves using either R1 or fdata->alloca_reg. Use
9388 store_insn_p to match CR saves. Set alloca_reg_offset
9389 when alloca_reg and framep are set. Remove lr_reg shift
9390 when assigning to fdata->lr_register.
9392 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
9394 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
9395 command line args instead of emitting a warning.
9397 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
9399 * tracepoint.h (struct static_tracepoint_marker): Initialize
9400 fields, define default constructor, move constructor and move
9401 assignment, disable the rest.
9402 <str_id, extra>: Make std::string.
9403 (release_static_tracepoint_marker): Remove.
9404 (free_current_marker): Remove.
9405 * tracepoint.c (free_current_marker): Remove.
9406 (parse_static_tracepoint_marker_definition): Adjust to
9407 std::string, use new hex2str overload.
9408 (release_static_tracepoint_marker): Remove.
9409 (print_one_static_tracepoint_marker): Get marker by reference
9410 and adjust to std::string.
9411 (info_static_tracepoint_markers_command): Adjust to std::vector
9413 * target.h (static_tracepoint_marker_p): Remove typedef.
9414 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
9415 (struct target_ops) <to_static_tracepoint_marker_at>: Return
9417 <to_static_tracepoint_markers_by_strid>: Return std::vector.
9419 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
9420 (target_debug_print_std_vector_static_tracepoint_marker): New.
9421 (target_debug_print_struct_static_tracepoint_marker_p): Rename
9423 (target_debug_print_static_tracepoint_marker_p): ... this.
9424 * target-delegates.c: Re-generate.
9425 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
9427 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
9428 (decode_static_tracepoint_spec): Adjust to std::vector.
9429 (tracepoint_print_one_detail): Adjust to std::string.
9430 (strace_marker_decode_location): Adjust to std::string.
9431 (update_static_tracepoint): Adjust to std::string, remove call
9432 to release_static_tracepoint_marker.
9433 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
9434 Adjust to std::vector.
9435 * remote.c (remote_static_tracepoint_marker_at): Return bool.
9436 (remote_static_tracepoint_markers_by_strid): Adjust to
9438 * common/rsp-low.h (hex2str): New overload with explicit count
9440 * common/rsp-low.c (hex2str): New overload with explicit count
9442 * unittests/rsp-low-selftests.c (test_hex2str): New function.
9443 (_initialize_rsp_low_selftests): Add test_hex2str test.
9444 * unittests/tracepoint-selftests.c
9445 (test_parse_static_tracepoint_marker_definition): Adjust to
9448 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
9450 * tracepoint.c (parse_static_tracepoint_marker_definition):
9451 Consider case where the definition is followed by more
9453 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9454 tracepoint-selftests.c.
9455 * unittests/tracepoint-selftests.c: New.
9457 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9459 * MAINTAINERS (Write After Approval): Add Pedro Franco de
9462 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
9464 * symtab.c (find_pc_sect_line): fixed indentation.
9466 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
9468 * symtab.c (find_pc_sect_line): now uses binary search.
9470 2018-03-19 Tom Tromey <tom@tromey.com>
9472 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
9475 2018-03-19 Pedro Alves <palves@redhat.com>
9476 Tom Tromey <tom@tromey.com>
9478 * unittests/observable-selftests.c: New file.
9479 * common/observable.h: New file.
9480 * observable.h: New file.
9481 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
9482 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
9483 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
9484 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
9485 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
9486 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
9487 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
9488 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
9489 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
9490 python/py-breakpoint.c, python/py-finishbreakpoint.c,
9491 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
9492 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
9493 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
9494 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
9495 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
9496 tui/tui-interp.c, valops.c: Update all users.
9497 * tui/tui-hooks.c (tui_bp_created_observer)
9498 (tui_bp_deleted_observer, tui_bp_modified_observer)
9499 (tui_inferior_exit_observer, tui_before_prompt_observer)
9500 (tui_normal_stop_observer, tui_register_changed_observer):
9502 (tui_observers_token): New global.
9503 (attach_or_detach, tui_attach_detach_observers): New functions.
9504 (tui_install_hooks, tui_remove_hooks): Use
9505 tui_attach_detach_observers.
9506 * record-btrace.c (record_btrace_thread_observer): Remove.
9507 (record_btrace_thread_observer_token): New global.
9508 * observer.sh: Remove.
9509 * observer.c: Rename to observable.c.
9510 * observable.c (namespace gdb_observers): Define new objects.
9511 (observer_debug): Move into gdb_observers namespace.
9512 (struct observer, struct observer_list, xalloc_observer_list_node)
9513 (xfree_observer_list_node, generic_observer_attach)
9514 (generic_observer_detach, generic_observer_notify): Remove.
9515 (_initialize_observer): Update.
9516 Don't include observer.inc.
9517 * Makefile.in (generated_files): Remove observer.h, observer.inc.
9518 (clean mostlyclean): Likewise.
9519 (observer.h, observer.inc): Remove targets.
9520 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
9521 (COMMON_SFILES): Use observable.c, not observer.c.
9522 * .gitignore: Remove observer.h.
9524 2018-03-18 Tom Tromey <tom@tromey.com>
9526 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
9528 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
9530 2018-03-17 Tom Tromey <tom@tromey.com>
9532 * auto-load.c (auto_load_objfile_script_1): Use std::string.
9534 2018-03-17 Tom Tromey <tom@tromey.com>
9536 * target.c (class scoped_target_fd): New.
9537 (target_fileio_close_cleanup): Remove.
9538 (target_fileio_read_alloc_1): Use scoped_target_fd.
9540 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
9542 * silent-rules.mk: New.
9543 * Makefile.in: Include silent-rules.mk
9544 (srcdir, VPATH, top_srcdir): Move up.
9545 (COMPILE): Add ECHO_CXX.
9546 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
9547 (init.c): Add ECHO_INIT_C.
9548 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
9549 (version.c): Add ECHO_GEN.
9550 (printcmd.o): Add ECHO_CXX.
9551 (target-float.o): Add ECHO_CXX.
9552 (ada-exp.o): Add ECHO_CXX.
9553 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
9554 (insight$(EXEEXT)): Add ECHO_CXXLD.
9555 * gnulib/configure.ac: Add AM_SILENT_RULES.
9556 * gnulib/aclocal.m4: Re-generate.
9557 * gnulib/configure: Re-generate.
9558 * gnulib/import/Makefile.in: Re-generate.
9560 2018-03-16 Tom Tromey <tom@tromey.com>
9562 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
9563 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
9564 * utils.c (do_free_section_addr_info)
9565 (make_cleanup_free_section_addr_info): Remove.
9566 * symfile.h (struct other_sections): Add constructor.
9567 (struct section_addr_info): Remove.
9568 (section_addr_info): New typedef.
9569 (struct sym_fns) <sym_offsets>: Change type of parameter.
9570 (build_section_addr_info_from_objfile)
9571 (relative_addr_info_to_section_offsets, addr_info_make_relative)
9572 (default_symfile_offsets, symbol_file_add)
9573 (symbol_file_add_from_bfd)
9574 (build_section_addr_info_from_section_table): Update.
9575 (alloc_section_addr_info, free_section_addr_info): Don't declare.
9576 * symfile.c (alloc_section_addr_info): Remove.
9577 (build_section_addr_info_from_section_table): Change return type.
9579 (build_section_addr_info_from_bfd)
9580 (build_section_addr_info_from_objfile): Likewise.
9581 (free_section_addr_info): Remove.
9582 (relative_addr_info_to_section_offsets): Change type of "addrs".
9583 (addrs_section_compar): Now a std::sort comparator.
9584 (addrs_section_sort): Change return type.
9585 (addr_info_make_relative): Change type of "addrs". Update.
9586 (default_symfile_offsets, syms_from_objfile_1)
9587 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
9588 (symbol_file_add_separate): Update.
9589 (symbol_file_add): Change type of "addrs". Update.
9590 (add_symbol_file_command): Update. Remove cleanups.
9591 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
9593 * symfile-debug.c (debug_sym_offsets): Change type of "info".
9594 * solib.c (solib_read_symbols): Update.
9595 * objfiles.c (objfile_relocate): Update. Remove cleanups.
9596 * machoread.c (macho_symfile_offsets): Update.
9597 * jit.c (jit_bfd_try_read_symtab): Update.
9599 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
9601 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9602 unittests/utils-selftests.c.
9603 * unittests/utils-selftests.c: New file.
9605 2018-03-14 Tom Tromey <tom@tromey.com>
9608 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
9611 2018-03-14 Tom Tromey <tom@tromey.com>
9614 * printcmd.c (printf_pointer): Allow "-" in format.
9616 2018-03-14 Tom Tromey <tom@tromey.com>
9618 * printcmd.c (_initialize_printcmd): Add usage to printf.
9620 2018-03-14 Yao Qi <qiyao@sourceware.org>
9622 * MAINTAINERS: Update my email address.
9624 2018-03-13 Tom Tromey <tom@tromey.com>
9626 * machoread.c (macho_check_dsym): Change filenamep to a
9628 (macho_symfile_read): Update.
9629 * symfile.c (load_command): Use std::string.
9631 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
9633 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
9634 to error message string.
9635 (riscv_register_name): Use xsnprintf instead of sprintf.
9636 (riscv_insn::fetch_instruction): Use gdb_assert instead of
9638 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
9640 (riscv_push_dummy_call): Likewise.
9642 2018-03-12 Tom Tromey <tom@tromey.com>
9644 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
9645 Use gdb::byte_vector.
9646 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
9648 2018-03-12 Yao Qi <yao.qi@linaro.org>
9650 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
9651 parameter type to readable_regcache.
9652 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
9655 2018-03-11 Tom Tromey <tom@tromey.com>
9657 * dwarf2read.c (struct nextfield): Add initializers.
9658 (struct nextfnfield): Remove.
9659 (struct fnfieldlist): Add initializers. Remove "length" and
9660 "head", use std::vector.
9661 (struct decl_field_list): Remove.
9662 (struct field_info): Add initializers.
9663 <fields, baseclasses>: Now std::vector.
9664 <nbaseclasses, nfnfields, typedef_field_list_count,
9665 nested_types_list_count>: Remove.
9666 (dwarf2_add_field, dwarf2_add_type_defn)
9667 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
9668 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
9669 (process_structure_scope): Update.
9671 2018-03-11 Tom Tromey <tom@tromey.com>
9673 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
9674 for use by std::sort.
9675 (build_type_psymtabs_1): Use std::vector.
9677 2018-03-09 Eli Zaretskii <eliz@gnu.org>
9679 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
9680 and LIBMPFR in the printed configuration.
9682 2018-03-08 Tom Tromey <tom@tromey.com>
9684 * source.c (get_filename_and_charpos): Use scoped_fd.
9685 * nto-procfs.c (procfs_open_1): Use scoped_fd.
9686 (procfs_pidlist): Likewise.
9687 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
9688 (iterate_over_mappings): Likewise.
9690 2018-03-08 Tom Tromey <tom@tromey.com>
9692 * infcall.c (struct call_return_meta_info)
9693 <stack_temporaries_enabled>: Remove.
9694 (get_call_return_value, call_function_by_hand_dummy): Update.
9695 * thread.c (disable_thread_stack_temporaries): Remove.
9696 (enable_thread_stack_temporaries): Remove.
9697 (thread_stack_temporaries_enabled_p): Return bool.
9698 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
9699 (get_last_thread_stack_temporary): Update.
9700 * eval.c (evaluate_subexp): Update.
9701 * gdbthread.h (class enable_thread_stack_temporaries): Now a
9702 class, not a function.
9703 (value_ptr, value_vec): Remove typedefs.
9704 (class thread_info) <stack_temporaries_enabled>: Now bool.
9705 <stack_temporaries>: Now a std::vector.
9706 (thread_stack_temporaries_enabled_p)
9707 (value_in_thread_stack_temporaries): Return bool.
9709 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
9711 * remote.c (putpkt_binary): Fix omitted bytes reporting.
9712 (getpkt_or_notif_sane_1): Likewise.
9714 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
9716 * build-id.c (build_id_to_debug_bfd): Use std::string.
9718 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
9720 * build-id.c (find_separate_debug_file_by_buildid): Return
9722 * build-id.h (find_separate_debug_file_by_buildid): Return
9724 * coffread.c (coff_symfile_read): Adjust to std::string.
9725 * elfread.c (elf_symfile_read): Adjust to std::string.
9726 * symfile.c (separate_debug_file_exists): Change parameter to
9728 (find_separate_debug_file): Return std::string.
9729 (find_separate_debug_file_by_debuglink): Return std::string.
9730 * symfile.h (find_separate_debug_file_by_debuglink): Return
9733 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
9735 * common/xml-utils.c (xml_escape_text): Move code to...
9736 (xml_escape_text_append): ... this new function.
9737 * common/xml-utils.h (xml_escape_text_append): New declaration.
9738 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
9740 (_initialize_xml_utils): register test_xml_escape_text_append as
9743 2018-03-07 Alan Hayward <alan.hayward@arm.com>
9745 * defs.h: Remove MAX_REGISTER_SIZE.
9746 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
9748 * python/py-unwind.c (pyuw_sniffer): Likewise.
9750 2018-03-07 Tom Tromey <tom@tromey.com>
9752 * linux-tdep.c (linux_info_proc): Update.
9753 * target.h (struct target_ops) <to_fileio_readlink>: Return
9755 (target_fileio_readlink): Return optional<string>.
9756 * remote.c (remote_hostio_readlink): Return optional<string>.
9757 * inf-child.c (inf_child_fileio_readlink): Return
9759 * target.c (target_fileio_readlink): Return optional<string>.
9761 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
9763 * regcache.c (cooked_read_test): Add riscv to the list of
9764 architectures that have a save_reggroup.
9766 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
9768 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
9769 value is not a dynamic class object.
9771 2018-03-06 Tom Tromey <tom@tromey.com>
9773 * rust-exp.y: Formatting fixes.
9775 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9777 * riscv-tdep.c (riscv_register_name): Remove target description
9779 (riscv_gdbarch_init): Remove target description check.
9781 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9783 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
9785 * riscv-tdep.h: Likewise.
9787 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9789 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
9790 (riscv_pseudo_register_write): Delete.
9791 (riscv_gdbarch_init): Remove all use of pseudo registers.
9793 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9795 * record-btrace.c (btrace_print_lines): Replace cleanup
9796 parameter with RAII equivalents.
9797 (btrace_insn_history): Replace cleanup with RAII equivalents.
9798 * ui-out.h (make_cleanup_ui_out_list_begin_end,
9799 make_cleanup_ui_out_tuple_begin_end): Remove.
9800 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
9801 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
9802 make_cleanup_ui_out_list_begin_end): Remove.
9804 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9806 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
9807 parameter types to std::vector. Use bool.
9808 (record_btrace_wait): Replace VEC(tp_t) with
9809 std::vector<thread_info *>.
9810 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
9812 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9814 * record-btrace.c (record_btrace_disable_callback): Remove.
9815 (struct scoped_btrace_disable): New.
9816 (record_btrace_open): Use scoped_btrace_disable.
9818 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9820 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
9821 reading values from registers.
9823 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9825 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
9828 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9830 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
9831 change parameter type. Use GDB's print functions, and use
9832 core_addr_to_string where appropriate.
9833 (riscv_push_dummy_call): Use core_addr_to_string where
9834 appropriate, update call to riscv_print_arg_location, and reindent
9836 (riscv_return_value): Update call to riscv_print_arg_location.
9838 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9839 Tim Newsome <tim@sifive.com>
9840 Albert Ou <a0u@eecs.berkeley.edu>
9841 Darius Rad <darius@bluespec.com>
9843 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
9844 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
9845 (ALLDEPFILES): Add riscv-tdep.c
9846 * configure.tgt: Add riscv support.
9847 * riscv-tdep.c: New file.
9848 * riscv-tdep.h: New file.
9849 * NEWS: Mention new target.
9850 * MAINTAINERS: Add entry for riscv.
9852 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9854 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
9855 fields within aggregates.
9857 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
9859 * record-btrace.c (btrace_print_lines): Change type of flags to
9860 gdb_disassembly_flags.
9862 2018-03-04 John Baldwin <jhb@FreeBSD.org>
9864 * fbsd-nat.c: Include "inf-ptrace.h".
9865 (USE_SIGTRAP_SIGINFO): Conditionally define.
9866 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
9867 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
9868 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
9870 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
9872 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
9874 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
9875 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
9876 "supports_stopped_by_hw_breakpoint" target methods.
9878 2018-03-04 John Baldwin <jhb@FreeBSD.org>
9880 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
9881 * fbsd-nat.c (debug_fbsd_nat): New variable.
9882 (show_fbsd_nat_debug): New function.
9883 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
9884 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
9886 2018-03-04 John Baldwin <jhb@FreeBSD.org>
9888 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
9889 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
9891 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
9892 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
9895 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9897 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
9898 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
9900 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9902 * charset.c (struct charset_vector): New.
9903 (charsets): Change type to charset_vector.
9904 (find_charset_names): Adjust.
9906 (_initialize_charset): Adjust.
9908 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9910 * progspace.h (struct program_space) <deleted_solibs>: Change
9911 type to std::vector<std::string>.
9912 * progspace.c (clear_program_space_solib_cache): Adjust.
9913 * breakpoint.c (print_solib_event): Adjust.
9914 (check_status_catch_solib): Adjust.
9915 * solib.c (update_solib_list): Adjust.
9916 * ui-out.h (class ui_out) <field_string>: New overload.
9917 * ui-out.c (ui_out::field_string): New overload.
9919 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9921 * progspace.h (struct program_space): Add constructor and
9922 destructor, initialize fields.
9923 (add_program_space): Remove.
9924 * progspace.c (add_program_space): Rename to...
9925 (program_space::program_space): ... this.
9926 (release_program_space): Rename to...
9927 (program_space::~program_space): ... this.
9928 (delete_program_space): Use delete to delete program_space.
9929 (initialize_progspace): Use new to allocate program_space.
9930 * inferior.c (add_inferior_with_spaces): Likewise.
9931 (clone_inferior_command): Likewise.
9932 * infrun.c (follow_fork_inferior): Likewise.
9933 (handle_vfork_child_exec_or_exit): Likewise.
9935 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9937 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
9938 (delim_string_to_char_ptr_vec): Return std::vector of
9939 gdb::unique_xmalloc_ptr.
9940 (dirnames_to_char_ptr_vec_append): Take std::vector of
9941 gdb::unique_xmalloc_ptr.
9942 (dirnames_to_char_ptr_vec): Return std::vector of
9943 gdb::unique_xmalloc_ptr.
9944 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
9945 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
9946 (delim_string_to_char_ptr_vec): Return an std::vector of
9947 gdb::unique_xmalloc_ptr, adjust the code.
9948 (dirnames_to_char_ptr_vec_append): Take an std::vector of
9949 gdb::unique_xmalloc_ptr, adjust the code.
9950 (dirnames_to_char_ptr_vec): Return an std::vector of
9951 gdb::unique_xmalloc_ptr, adjust the code.
9952 * auto-load.c (auto_load_safe_path_vec): Change type to
9953 std::vector of gdb::unique_xmalloc_ptr.
9954 (auto_load_expand_dir_vars): Return an std::vector of
9955 gdb::unique_xmalloc_ptr, adjust the code.
9956 (auto_load_safe_path_vec_update): Adjust.
9957 (filename_is_in_auto_load_safe_path_vec): Adjust.
9958 (auto_load_objfile_script_1): Adjust.
9959 * build-id.c (build_id_to_debug_bfd): Adjust.
9960 * linux-thread-db.c (thread_db_load_search): Adjust.
9961 * source.c (add_path): Adjust.
9963 * symfile.c (find_separate_debug_file): Adjust.
9964 * utils.c (do_free_char_ptr_vec): Remove.
9965 (make_cleanup_free_char_ptr_vec): Remove.
9967 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
9970 * common/pathstuff.c: Conditionally include "<windows.h>".
9972 2018-03-01 Georg Sauthoff <mail@georg.so>
9975 * gcore.in: Quote variables and switch interpreter to bash.
9977 2018-03-01 Tom Tromey <tom@tromey.com>
9979 * dwarf2read.c (alloc_discriminant_info): Fix default_index
9980 assertion. Add assertion for discriminant_index.
9981 (quirk_rust_enum): Use correct base type name in univariant case.
9983 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
9985 * record.c (get_call_history_modifiers): Return a
9987 (cmd_record_call_history): Adjust.
9988 * record-btrace.c (record_btrace_call_history): Adjust.
9989 (record_btrace_call_history_range): Adjust.
9990 (record_btrace_call_history_from): Adjust.
9991 * target-debug.h (target_debug_print_record_print_flags): New.
9992 * target-delegates.c: Re-generate.
9993 * target.c (target_call_history): Change flags type.
9994 (target_call_history_from): Likewise.
9995 (target_call_history_range): Likewise.
9996 * target.h (struct target_ops) <target_call_history>: Likewise.
9997 (target_call_history_from): Likewise.
9998 (target_call_history_range): Likewise.
10000 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
10001 Simon Marchi <simon.marchi@polymtl.ca>
10003 * common/common-utils.c: Include "sys/stat.h".
10004 (is_regular_file): Move here from "source.c"; change return
10006 * common/common-utils.h (is_regular_file): New prototype.
10007 * common/pathstuff.c (contains_dir_separator): New function.
10008 * common/pathstuff.h (contains_dir_separator): New prototype.
10009 * source.c: Don't include "sys/stat.h".
10010 (is_regular_file): Move to "common/common-utils.c".
10012 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
10014 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
10015 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
10016 * auto-load.c: Include "common/pathstuff.h".
10017 * common/common-def.h (current_directory): Move here.
10018 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
10020 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
10022 * common/pathstuff.c: New file.
10023 * common/pathstuff.h: New file.
10024 * compile/compile.c: Include "common/pathstuff.h".
10025 * defs.h (current_directory): Move to "common/common-defs.h".
10026 * dwarf2read.c: Include "common/pathstuff.h".
10027 * exec.c: Likewise.
10028 * guile/scm-safe-call.c: Likewise.
10029 * linux-thread-db.c: Likewise.
10030 * main.c: Likewise.
10031 * nto-tdep.c: Likewise.
10032 * objfiles.c: Likewise.
10033 * source.c: Likewise.
10034 * symtab.c: Likewise.
10035 * utils.c: Include "common/pathstuff.h".
10036 (gdb_realpath): Move to "common/pathstuff.c".
10037 (gdb_realpath_keepfile): Likewise.
10038 (gdb_abspath): Likewise.
10039 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
10040 (gdb_realpath_keepfile): Likewise.
10041 (gdb_abspath): Likewise.
10043 2018-02-28 John Baldwin <jhb@FreeBSD.org>
10045 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
10046 wildcard process pid for super_resume for kernels with a
10049 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
10051 * compile/compile.c (get_args): Add additional comments
10052 explaining function.
10054 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
10055 Tom Tromey <tom@tromey.com>
10057 * target.h (memory_write_request_s): Remove typedef. Don't define
10059 (target_write_memory_blocks): Change argument to std::vector.
10060 (struct memory_write_request): Add constructor.
10061 * target-memory.c (compare_block_starting_address): Return bool.
10062 Change argument types.
10063 (claim_memory): Change arguments to use std::vector.
10064 (split_regular_and_flash_blocks, blocks_to_erase)
10065 (compute_garbled_blocks): Likewise.
10066 (cleanup_request_data, cleanup_write_requests_vector): Remove.
10067 (target_write_memory_blocks): Change argument to std::vector.
10068 * symfile.c (struct load_section_data): Add constructor and
10069 destructor. Use std::vector for "requests".
10070 (struct load_progress_data): Add initializers.
10071 (load_section_callback): Update. Use "new".
10072 (clear_memory_write_data): Remove.
10073 (generic_load): Update.
10075 2018-02-27 Alan Hayward <alan.hayward@arm.com>
10077 * arch/aarch64.h: Use common/tdesc.h.
10079 2018-02-26 Maciej W. Rozycki <macro@mips.com>
10081 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
10082 architecture with a 64-bit ABI.
10084 2018-02-26 Maciej W. Rozycki <macro@mips.com>
10086 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
10087 ahead of target description loading.
10089 2018-02-26 Tom Tromey <tom@tromey.com>
10091 * stack.c (backtrace_command_1): Update.
10092 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
10094 * python/py-framefilter.c (py_print_frame)
10095 (gdbpy_apply_frame_filter): Change type of "flags".
10096 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
10098 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
10099 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
10100 * extension.h (enum frame_filter_flag): Rename from
10101 frame_filter_flags.
10102 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
10103 (apply_ext_lang_frame_filter): Change type of "flags".
10104 * extension.c (apply_ext_lang_frame_filter): Change type of
10106 * extension-priv.h (struct extension_language_ops)
10107 <apply_frame_filter>: Change type of "flags".
10109 2018-02-26 Tom Tromey <tom@tromey.com>
10112 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
10113 off-by-one in py_end computation.
10114 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
10116 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
10119 2018-02-26 Tom Tromey <tom@tromey.com>
10121 * dwarf2read.c (struct variant_field): New.
10122 (struct nextfield) <variant>: New field.
10123 (dwarf2_add_field): Handle DW_TAG_variant_part.
10124 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
10125 discriminated union.
10126 (read_structure_type): Handle DW_TAG_variant_part.
10127 (handle_struct_member_die): New function, extracted from
10128 process_structure_scope. Handle DW_TAG_variant.
10129 (process_structure_scope): Handle discriminated unions. Call
10130 handle_struct_member_die.
10132 2018-02-26 Tom Tromey <tom@tromey.com>
10134 * rust-lang.h (rust_last_path_segment): Declare.
10135 * rust-lang.c (rust_last_path_segment): Now public. Change
10137 (struct disr_info): Remove.
10138 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
10139 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
10140 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
10141 (rust_enum_p, rust_enum_variant): New function.
10142 (rust_underscore_fields): Remove "offset" parameter.
10143 (rust_print_enum): New function.
10144 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
10145 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
10146 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
10148 (rust_internal_print_type): New function, from rust_print_type.
10150 (rust_print_type): Call rust_internal_print_type.
10151 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
10152 Update enum handling.
10153 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
10154 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
10155 (rust_union_quirks): New functions.
10156 (process_full_comp_unit, process_full_type_unit): Call
10158 (process_structure_scope): Update rust_unions if necessary.
10160 2018-02-26 Tom Tromey <tom@tromey.com>
10162 * value.h (value_union_variant): Declare.
10163 * valops.c (value_union_variant): New function.
10164 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
10165 (struct discriminant_info): New.
10166 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
10168 (struct main_type) <flag_discriminated_union>: New field.
10170 2018-02-26 Tom Tromey <tom@tromey.com>
10172 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10173 unittests/unpack-selftests.c.
10174 * unittests/unpack-selftests.c: New file.
10175 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
10177 2018-02-26 Yao Qi <yao.qi@linaro.org>
10179 * dwarf2read.c (struct partial_die_info) <read>: New method.
10180 (read_partial_die): Remove the declaration.
10181 (load_partial_dies): Update.
10182 (partial_die_info::partial_die_info):
10183 (read_partial_die): Change it to partial_die_info::read.
10185 2018-02-26 Yao Qi <yao.qi@linaro.org>
10187 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
10188 (fixup_partial_die): Remove declaration.
10189 (scan_partial_symbols): Update.
10190 (partial_die_parent_scope): Likewise.
10191 (partial_die_full_name): Likewise.
10192 (fixup_partial_die): Change it to partial_die_info::fixup.
10194 2018-02-26 Yao Qi <yao.qi@linaro.org>
10196 * dwarf2read.c (read_partial_die): Update the declaration.
10197 (load_partial_dies): Caller update.
10198 (read_partial_die): Remove one argument abbrev_len.
10200 2018-02-26 Yao Qi <yao.qi@linaro.org>
10202 * dwarf2read.c (struct partial_die_info): Add ctor, delete
10203 assignment operator.
10204 (load_partial_dies): Use ctor and copy ctor.
10205 (read_partial_die): Update.
10206 (dwarf2_cu::find_partial_die): Use ctor.
10208 2018-02-26 Yao Qi <yao.qi@linaro.org>
10210 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
10211 (find_partial_die_in_comp_unit): Change it to
10212 dwarf2_cu::find_partial_die.
10213 (find_partial_die): Update.
10215 2018-02-26 Yao Qi <yao.qi@linaro.org>
10217 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
10220 2018-02-26 Yao Qi <yao.qi@linaro.org>
10222 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
10224 2018-02-26 Alan Hayward <alan.hayward@arm.com>
10226 * arch/amd64.h: Use common/tdesc.h.
10227 * arch/i386.c: Likewise.
10228 * arch/i386.h: Likewise.
10229 * arch/tic6x.c: Likewise.
10230 * arch/tdesc.h: Move file from here...
10231 * common/tdesc.h: ...to here.
10232 * features/aarch64-core.c: Regenerate.
10233 * features/aarch64-fpu.c: Regenerate.
10234 * features/i386/32bit-avx.c: Regenerate.
10235 * features/i386/32bit-avx512.c: Regenerate.
10236 * features/i386/32bit-core.c: Regenerate.
10237 * features/i386/32bit-linux.c: Regenerate.
10238 * features/i386/32bit-mpx.c: Regenerate.
10239 * features/i386/32bit-pkeys.c: Regenerate.
10240 * features/i386/32bit-sse.c: Regenerate.
10241 * features/i386/64bit-avx.c: Regenerate.
10242 * features/i386/64bit-avx512.c: Regenerate.
10243 * features/i386/64bit-core.c: Regenerate.
10244 * features/i386/64bit-linux.c: Regenerate.
10245 * features/i386/64bit-mpx.c: Regenerate.
10246 * features/i386/64bit-pkeys.c: Regenerate.
10247 * features/i386/64bit-segments.c: Regenerate.
10248 * features/i386/64bit-sse.c: Regenerate.
10249 * features/i386/x32-core.c: Regenerate.
10250 * features/tic6x-c6xp.c: Regenerate.
10251 * features/tic6x-core.c: Regenerate.
10252 * features/tic6x-gp.c: Regenerate.
10253 * target-descriptions.c: Use common/tdesc.h.
10254 * target-descriptions.h: Likewise.
10256 2018-02-24 Tom Tromey <tom@tromey.com>
10258 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
10259 (try_thread_db_load_from_dir, thread_db_load_search): Use
10261 (info_auto_load_libthread_db_compare): Return bool. Change
10263 (info_auto_load_libthread_db): Use std::vector, std::string.
10266 2018-02-24 Tom Tromey <tom@tromey.com>
10268 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
10270 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
10272 * gdbarch.c: Rebuild.
10273 * gdbarch.h: Rebuild.
10274 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
10275 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
10276 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
10279 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
10281 * gdbtypes.h (sect_offset): Change type to uint64_t.
10282 (sect_offset_str): New function.
10283 * dwarf2read.c (create_addrmap_from_aranges): Use
10285 (error_check_comp_unit_head): Likewise.
10286 (create_debug_type_hash_table): Likewise.
10287 (read_cutu_die_from_dwo): Likewise.
10288 (init_cutu_and_read_dies): Likewise.
10289 (init_cutu_and_read_dies_no_follow): Likewise.
10290 (process_psymtab_comp_unit_reader): Likewise.
10291 (partial_die_parent_scope): Likewise.
10292 (peek_die_abbrev): Likewise.
10293 (process_queue): Likewise.
10294 (dwarf2_physname): Likewise.
10295 (read_namespace_alias): Likewise.
10296 (read_import_statement): Likewise.
10297 (create_dwo_cu_reader): Likewise.
10298 (create_cus_hash_table): Likewise.
10299 (lookup_dwo_cutu): Likewise.
10300 (inherit_abstract_dies): Likewise.
10301 (read_func_scope): Likewise.
10302 (read_call_site_scope): Likewise.
10303 (dwarf2_add_member_fn): Likewise.
10304 (read_common_block): Likewise.
10305 (read_module_type): Likewise.
10306 (read_typedef): Likewise.
10307 (read_subrange_type): Likewise.
10308 (load_partial_dies): Likewise.
10309 (read_partial_die): Likewise.
10310 (find_partial_die): Likewise.
10311 (read_str_index): Likewise.
10312 (dwarf2_string_attr): Likewise.
10313 (build_error_marker_type): Likewise.
10314 (lookup_die_type): Likewise.
10315 (dump_die_shallow): Likewise.
10316 (follow_die_ref): Likewise.
10317 (dwarf2_fetch_die_loc_sect_off): Likewise.
10318 (dwarf2_fetch_constant_bytes): Likewise.
10319 (follow_die_sig): Likewise.
10320 (get_signatured_type): Likewise.
10321 (get_DW_AT_signature_type): Likewise.
10322 (dwarf2_find_containing_comp_unit): Likewise.
10323 (set_die_type): Likewise.
10325 2018-02-21 John Baldwin <jhb@FreeBSD.org>
10327 * arch/aarch64.c: Include "common-defs.h".
10328 * arch/amd64.c: Likewise.
10329 * arch/i386.c: Likewise.
10331 2018-02-21 Tom Tromey <tom@tromey.com>
10333 * value.h: (extract_field_op): Update.
10334 * eval.c (extract_field_op): Return a const char *.
10335 * expression.h (parse_expression_for_completion): Update.
10336 * completer.c (complete_expression): Update.
10337 (add_struct_fields): Make fieldname const.
10338 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
10339 (mark_completion_tag, parse_exp_in_context_1): Update.
10340 (parse_expression_for_completion): Change "name" to
10341 unique_xmalloc_ptr*.
10343 2018-02-21 Tom Tromey <tom@tromey.com>
10345 * infcall.c (call_function_by_hand_dummy): Use std::vector.
10347 2018-02-21 Yao Qi <yao.qi@linaro.org>
10349 * avr-tdep.c (avr_read_pc): Change parameter type to
10351 * gdbarch.sh (read_pc): Likewise.
10352 * gdbarch.c: Re-generated.
10353 * gdbarch.h: Re-generated.
10354 * hppa-tdep.c (hppa_read_pc): Change parameter type to
10356 * ia64-tdep.c (ia64_read_pc): Likewise.
10357 * mips-tdep.c (mips_read_pc): Likewise.
10358 * spu-tdep.c (spu_read_pc): Likewise.
10360 2018-02-21 Yao Qi <yao.qi@linaro.org>
10362 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
10363 * regcache-dump.c: New file.
10364 * regcache.c: Move register_dump to regcache-dump.c.
10365 (maintenance_print_registers): Likewise.
10366 (maintenance_print_raw_registers): Likewise.
10367 (maintenance_print_cooked_registers): Likewise.
10368 (maintenance_print_register_groups): Likewise.
10369 (maintenance_print_remote_registers): Likewise.
10370 (_initialize_regcache): Likewise.
10371 * regcache.h (register_dump): Moved from regcache.c.
10373 2018-02-21 Yao Qi <yao.qi@linaro.org>
10375 * regcache.c (regcache::regcache): Update.
10376 (regcache::invalidate): Move it to detached_regcache::invalidate.
10377 (get_thread_arch_aspace_regcache): Update.
10378 (regcache::raw_update): Update.
10379 (regcache::cooked_read): Remove some code.
10380 (regcache::cooked_read_value): Likewise.
10381 (regcache::raw_write): Remove assert on m_readonly_p.
10382 (regcache::raw_supply_integer): Move it to
10383 detached_regcache::raw_supply_integer.
10384 (regcache::raw_supply_zeroed): Likewise.
10385 * regcache.h (detached_regcache) <raw_supply_integer>: New
10387 <raw_supply_zeroed, invalidate>: Likewise.
10388 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
10389 <invalidate>: Likewise.
10390 <m_readonly_p>: Removed.
10392 2018-02-21 Yao Qi <yao.qi@linaro.org>
10394 * infcmd.c (get_return_value): Let stop_regs point to
10395 get_current_regcache.
10396 * regcache.c (regcache::regcache): Remove.
10397 (register_dump_reg_buffer): New class.
10398 (regcache_print): Adjust.
10399 * regcache.h (regcache): Remove constructors.
10401 2018-02-21 Yao Qi <yao.qi@linaro.org>
10403 * regcache.c (class register_dump): New class.
10404 (register_dump_regcache, register_dump_none): New class.
10405 (register_dump_remote, register_dump_groups): New class.
10406 (regcache_print): Update.
10407 * regcache.h (regcache_dump_what): Move it to regcache.c.
10408 (regcache) <dump>: Remove.
10410 2018-02-21 Yao Qi <yao.qi@linaro.org>
10412 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
10414 (jit_unwind_reg_set_impl): Call raw_supply.
10415 (jit_frame_sniffer): Use reg_buffer_rw.
10416 * record-full.c (record_full_core_regbuf): Change its type.
10417 (record_full_core_open_1): Use reg_buffer_rw.
10418 (record_full_close): Likewise.
10419 (record_full_core_fetch_registers): Use regcache->raw_supply.
10420 (record_full_core_store_registers): Likewise.
10421 * regcache.c (regcache::get_register_status): Move it to
10423 (regcache_raw_set_cached_value): Remove.
10424 (regcache::raw_set_cached_value): Remove.
10425 (regcache::raw_write): Call raw_supply.
10426 (regcache::raw_supply): Move it to reg_buffer_rw.
10427 * regcache.h (regcache_raw_set_cached_value): Remove.
10428 (reg_buffer_rw): New class.
10430 2018-02-21 Yao Qi <yao.qi@linaro.org>
10432 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
10433 readonly_detached_regcache.
10434 (dummy_frame_prev_register): Use regcache->cooked_read.
10435 * frame.c (frame_save_as_regcache): Change return type.
10436 (frame_pop): Update.
10437 * frame.h (frame_save_as_regcache): Update declaration.
10438 * inferior.h (get_infcall_suspend_state_regcache): Update
10440 * infrun.c (infcall_suspend_state) <registers>: use
10441 readonly_detached_regcache.
10442 (save_infcall_suspend_state): Don't use regcache_dup.
10443 (get_infcall_suspend_state_regcache): Change return type.
10444 * linux-fork.c (struct fork_info) <savedregs>: Change to
10445 readonly_detached_regcache.
10447 (fork_save_infrun_state): Don't use regcache_dup.
10448 (info_checkpoints_command): Adjust.
10449 * mi/mi-main.c (register_changed_p): Update declaration.
10450 (mi_cmd_data_list_changed_registers): Use
10451 readonly_detached_regcache.
10452 (register_changed_p): Change parameter type to
10453 readonly_detached_regcache.
10454 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
10455 readonly_detached_regcache.
10456 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
10457 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
10459 (regcache::save): Move it to reg_buffer.
10460 (regcache::restore): Change parameter type.
10461 (regcache_dup): Remove.
10462 * regcache.h (reg_buffer) <save>: New method.
10463 (readonly_detached_regcache): New class.
10464 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
10465 readonly_detached_regcache.
10466 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
10468 2018-02-21 Yao Qi <yao.qi@linaro.org>
10470 * frame.c (frame_save_as_regcache): Use regcache method save.
10471 (frame_pop): Use regcache method restore.
10472 * infrun.c (restore_infcall_suspend_state): Likewise.
10473 * linux-fork.c (fork_load_infrun_state): Likewise.
10474 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
10476 * regcache.c (regcache_save): Remove.
10477 (regcache::restore): More asserts.
10478 (regcache_cpy): Remove.
10479 * regcache.h (regcache_save): Remove the declaration.
10480 (regcache::restore): Move from private to public.
10481 Remove the friend declaration of regcache_cpy.
10482 (regcache_cpy): Remove declaration.
10484 2018-02-21 Yao Qi <yao.qi@linaro.org>
10486 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
10487 parameter type to 'readable_regcache *'.
10488 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
10489 * arm-tdep.c (arm_neon_quad_read): Likewise.
10490 (arm_pseudo_read): Likewise.
10491 * avr-tdep.c (avr_pseudo_register_read): Likewise.
10492 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
10493 * frv-tdep.c (frv_pseudo_register_read): Likewise.
10494 * gdbarch.c: Re-generated.
10495 * gdbarch.h: Re-generated.
10496 * gdbarch.sh (pseudo_register_read): Change parameter type to
10497 'readable_regcache *'.
10498 (pseudo_register_read_value): Likewise.
10499 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
10500 (h8300_pseudo_register_read): Likewise.
10501 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
10502 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
10503 (i386_pseudo_register_read_into_value): Likewise.
10504 (i386_pseudo_register_read_value): Likewise.
10505 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
10507 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
10508 * m32c-tdep.c (m32c_raw_read): Likewise.
10509 (m32c_read_flg): Likewise.
10510 (m32c_banked_register): Likewise.
10511 (m32c_banked_read): Likewise.
10512 (m32c_sb_read): Likewise.
10513 (m32c_part_read): Likewise.
10514 (m32c_cat_read): Likewise.
10515 (m32c_r3r2r1r0_read): Likewise.
10516 (m32c_pseudo_register_read): Likewise.
10517 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
10518 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
10519 (mep_pseudo_cr64_read): Likewise.
10520 (mep_pseudo_register_read): Likewise.
10521 * mips-tdep.c (mips_pseudo_register_read): Likewise.
10522 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
10523 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
10524 * regcache.c (regcache::raw_read): Move it to readable_regcache.
10525 (regcache::cooked_read): Likewise.
10526 (regcache::cooked_read_value): Likewise.
10527 (regcache_cooked_read_signed):
10528 (regcache::cooked_read): Likewise.
10529 * regcache.h (readable_regcache): New class.
10530 (regcache): Inherit readable_regcache. Move some methods to
10532 * rl78-tdep.c (rl78_pseudo_register_read): Change
10533 parameter type to 'readable_regcache *'.
10534 * rs6000-tdep.c (do_regcache_raw_read): Remove.
10535 (e500_pseudo_register_read): Change parameter type to
10536 'readable_regcache *'.
10537 (dfp_pseudo_register_read): Likewise.
10538 (vsx_pseudo_register_read): Likewise.
10539 (efpr_pseudo_register_read): Likewise.
10540 * s390-tdep.c (s390_pseudo_register_read): Likewise.
10541 * sh-tdep.c (sh_pseudo_register_read): Likewise.
10542 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
10543 (sh64_pseudo_register_read): Likewise.
10544 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
10545 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
10546 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
10547 (spu_pseudo_register_read): Likewise.
10548 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
10549 (xtensa_pseudo_register_read): Likewise.
10551 2018-02-21 Yao Qi <yao.qi@linaro.org>
10553 * regcache.c (regcache::regcache): Call reg_buffer ctor.
10554 (regcache::arch): Move it to reg_buffer::arch.
10555 (regcache::register_buffer): Likewise.
10556 (regcache::assert_regnum): Likewise.
10557 (regcache::num_raw_registers): Likewise.
10558 * regcache.h (reg_buffer): New class.
10559 (regcache): Inherit reg_buffer.
10561 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
10563 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
10564 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
10566 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
10568 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
10570 2018-02-19 Alan Hayward <alan.hayward@arm.com>
10572 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
10573 (SFILES): Remove common/*.c files.
10574 (COMMON_OBS): Remove some *.o files built from common/*.c files.
10575 * common/common.host: Add common reference.
10576 * configure.ac: Likewise.
10577 * configure: Regenerate.
10579 2018-02-16 Yao Qi <yao.qi@linaro.org>
10581 * block.c (block_namespace_info): Inherit allocate_on_obstack.
10582 (block_initialize_namespace): Use new.
10583 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
10584 (dwarf2_free_objfile): Use delete.
10585 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
10586 (copy_type_recursive): Use new.
10587 * gdb_obstack.h (allocate_on_obstack): New.
10589 2018-02-15 Yao Qi <yao.qi@linaro.org>
10592 * inferior.c (exit_inferior_1): Reset inf->control.
10594 2018-02-15 Joel Brobecker <brobecker@adacore.com>
10596 * ada-lang.c (ada_to_fixed_value_create): Delete advance
10599 2018-02-14 Pedro Alves <palves@redhat.com>
10601 * frame-unwind.c (frame_unwind_try_unwinder): Always call
10602 frame_cleanup_after_sniffer on exception.
10604 2018-02-14 Tom Tromey <tom@tromey.com>
10606 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
10608 (solib_bfd_open): Make pathname const.
10609 * solib.c (solib_bfd_open): Make pathname const.
10610 * solib-spu.c (spu_bfd_fopen): Make name const.
10611 (spu_bfd_open): Make pathname const.
10612 * solib-darwin.c (darwin_bfd_open): Make pathname const.
10613 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
10615 2018-02-14 Tom Tromey <tom@tromey.com>
10617 * symfile.c (symfile_bfd_open): Update.
10618 * source.h (openp, source_full_path_of, find_and_open_source):
10619 Change argument type to unique_xmalloc_ptr.
10620 * source.c (openp): Take a unique_xmalloc_ptr.
10621 (source_full_path_of, find_and_open_source): Likewise.
10622 (open_source_file, symtab_to_fullname): Update.
10623 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
10624 unique_xmalloc_ptr.
10625 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
10626 (exec_file_find): Update.
10627 * psymtab.c (psymtab_to_fullname): Update.
10628 * nto-tdep.h (nto_find_and_open_solib): Update.
10629 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
10630 unique_xmalloc_ptr.
10631 * exec.c (exec_file_attach): Update.
10632 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
10633 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
10635 2018-02-14 Tom Tromey <tom@tromey.com>
10637 * solib.c: Include source.h.
10638 * nto-tdep.c: Include source.h.
10639 * mi/mi-cmd-env.c: Include source.h.
10640 * infcmd.c: Include source.h.
10641 * exec.c: Include source.h.
10642 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
10643 (add_path, directory_switch, source_path, init_source_path): Move
10645 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
10646 (add_path, directory_switch, source_path, init_source_path):
10649 2018-02-14 Tom Tromey <tom@tromey.com>
10651 * solist.h (exec_file_find, solib_find): Return
10652 unique_xmalloc_ptr.
10653 (solib_bfd_fopen): Take a const char *.
10654 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
10655 (exec_file_find, solib_find): Likewise.
10656 (solib_bfd_fopen): Do not take ownership of "pathname".
10657 (solib_bfd_open): Use unique_xmalloc_ptr.
10658 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
10659 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
10660 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
10661 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
10663 2018-02-14 Joel Brobecker <brobecker@adacore.com>
10665 * ada-lang.c (name_match_type_from_name): Remove reference to
10666 ada_name_for_lookup in function's documentation.
10667 * ada-lang.h (ada_name_for_lookup): Delete declaration.
10669 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
10671 * defs.h (enum openp_flags): New enum.
10672 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
10673 Move to enum openp_flags.
10674 (openp_flags): New enum flags.
10675 (openp): Change parameter type to openp_flags.
10676 * source.c (openp): Change parameter type to openp_flags.
10677 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
10678 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
10680 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
10682 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
10685 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
10687 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
10689 (class dwarf2_queue_guard): ...the destructor of this new class.
10690 (dw2_do_instantiate_symtab): Create instance of the new class
10691 dwarf2_queue_guard, remove cleanup.
10693 2018-02-09 Tom Tromey <tom@tromey.com>
10695 * source.c (find_source_lines): Don't reference past the end of
10698 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10700 * remote.c (remote_btrace_maybe_reopen): Change error message.
10701 * btrace.c (btrace_enable): Likewise.
10702 (parse_xml_btrace): Likewise.
10703 (parse_xml_btrace_conf): Likewise.
10705 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10707 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
10708 (linux_enable_pt, linux_enable_bts): Call
10709 diagnose_perf_event_open_fail.
10711 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10713 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
10714 Remove parameter and change return type. Update callers. Move it.
10715 (linux_enable_bts, linux_enable_pt): Improve error message.
10716 (linux_enable_pt): Remove zero buffer size check.
10717 (linux_enable_btrace): Improve error messages. Remove NULL return
10720 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10722 * btrace.c (btrace_enable): Remove target_supports_btrace call.
10723 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
10724 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
10725 (linux_supports_pt, linux_supports_btrace): Remove.
10726 (linux_enable_bts): Call cpu_supports_bts.
10727 * nat/linux-btrace.h (linux_supports_btrace): Remove.
10728 * remote.c (remote_supports_btrace): Remove.
10729 (init_remote_ops): Remove remote_supports_btrace.
10730 * target-delegates.c: Regenerated.
10731 * target.c (target_supports_btrace): Remove.
10732 * target.h (target_ops) <to_supports_btrace>: Remove
10733 (target_supports_btrace): Remove.
10734 * x86-linux-nat.c (x86_linux_create_target): Remove
10735 linux_supports_btrace.
10737 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10739 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
10741 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
10742 exception and use message in own exception.
10744 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10746 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
10747 (perf_event_pt_event_type): Use gdb_file_up.
10748 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
10749 scoped_fd, and scoped_mmap.
10751 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10753 * common/scoped_mmap.h: New.
10754 * unittests/scoped_mmap-selftest.c: New.
10755 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10756 unittests/scoped_mmap-selftest.c.
10758 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10760 * common/scoped_fd.h: New.
10761 * unittests/scoped_fd-selftest.c: New.
10762 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10763 unittests/scoped_fd-selftest.c.
10765 2018-02-09 Tom Tromey <tom@tromey.com>
10767 * auto-load.c (auto_load_section_scripts): Use
10768 gdb::unique_xmalloc_ptr.
10770 2018-02-09 Tom Tromey <tom@tromey.com>
10772 * auto-load.c (execute_script_contents): Use std::string.
10774 2018-02-09 Joel Brobecker <brobecker@adacore.com>
10776 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
10777 Python function, rather than a new command.
10779 2018-02-08 Tom Tromey <tom@tromey.com>
10781 * solib.c (solib_find_1): Use std::string.
10782 (solib_bfd_fopen): Use unique_xmalloc_ptr.
10784 2018-02-08 Tom Tromey <tom@tromey.com>
10786 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
10788 2018-02-08 Tom Tromey <tom@tromey.com>
10790 * source.c (find_source_lines): Use gdb::def_vector.
10792 2018-02-08 Tom Tromey <tom@tromey.com>
10794 * macrocmd.c (struct temporary_macro_definition): New.
10795 (macro_define_command): Use temporary_macro_definition. Remove
10797 (free_macro_definition_ptr): Remove.
10799 2018-02-08 Tom Tromey <tom@tromey.com>
10801 * macroexp.c (maybe_expand): Use std::string.
10803 2018-02-08 Tom Tromey <tom@tromey.com>
10805 * macroexp.c (struct macro_buffer): Add initializers for some
10807 (init_buffer, init_shared_buffer, free_buffer)
10808 (free_buffer_return_text): Remove.
10809 (macro_buffer): New constructors.
10810 (~macro_buffer): New destructor.
10811 (macro_buffer::set_shared): New method.
10812 (macro_buffer::resize_buffer, macro_buffer::appendc)
10813 (macro_buffer::appendmem): Now methods, not free functions.
10814 (set_token, append_tokens_without_splicing, stringify)
10815 (macro_stringify): Update.
10816 (gather_arguments): Change return type. Remove argc_p argument,
10817 add args_ptr argument. Use std::vector.
10818 (substitute_args): Remove argc argument. Accept std::vector.
10819 (expand): Update. Use std::vector.
10820 (scan, macro_expand, macro_expand_next): Update.
10822 2018-02-08 Tom Tromey <tom@tromey.com>
10824 * symtab.c (default_collect_symbol_completion_matches_break_on):
10825 Use unique_xmalloc_ptr.
10826 * macroscope.h: (sal_macro_scope, user_macro_scope)
10827 (default_macro_scope): Return unique_xmalloc_ptr.
10828 * macroscope.c (sal_macro_scope, user_macro_scope)
10829 (default_macro_scope): Return unique_xmalloc_ptr.
10830 * macroexp.h (macro_expand, macro_expand_once): Return
10831 unique_xmalloc_ptr.
10832 * macroexp.c (macro_expand, macro_expand_once): Return
10833 unique_xmalloc_ptr.
10834 * macrocmd.c (macro_expand_command, macro_expand_once_command)
10835 (info_macro_command, info_macros_command): Use
10836 unique_xmalloc_ptr.
10837 * compile/compile-c-support.c (write_macro_definitions): Use
10838 unique_xmalloc_ptr.
10839 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
10841 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
10843 * value.c (value_static_field): Assign field type instead of
10844 containing type when returning an optimized out value.
10846 2018-02-06 Yao Qi <yao.qi@linaro.org>
10848 * ft32-tdep.c (ft32_read_pc): Remove.
10849 (ft32_write_pc): Remove.
10850 (ft32_gdbarch_init): Update.
10851 * m32r-tdep.c (m32r_read_pc): Remove.
10852 (m32r_gdbarch_init): Update.
10853 * mep-tdep.c (mep_read_pc): Remove.
10854 (mep_gdbarch_init): Update.
10855 * microblaze-tdep.c (microblaze_write_pc): Remove.
10856 (microblaze_gdbarch_init): Update.
10857 * mn10300-tdep.c (mn10300_read_pc): Remove.
10858 (mn10300_write_pc): Remove.
10859 (mn10300_gdbarch_init): Update.
10860 * moxie-tdep.c (moxie_read_pc): Remove.
10861 (moxie_write_pc): Remove.
10862 (moxie_gdbarch_init): Update.
10864 2018-02-06 Yao Qi <yao.qi@linaro.org>
10866 * expprint.c (print_subexp_standard): Handle
10867 OP_F77_UNDETERMINED_ARGLIST.
10868 (dump_subexp_body_standard): Likewise.
10870 2018-02-05 Alan Hayward <alan.hayward@arm.com>
10872 * target-descriptions.c (tdesc_element_visitor) Add empty
10874 (tdesc_type): Move make_gdb_type from here.
10875 (tdesc_type_builtin): Likewise.
10876 (tdesc_type_vector): Likewise.
10877 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
10878 (make_gdb_type_struct): Move from tdesc_type_with_fields.
10879 (make_gdb_type_union): Likewise.
10880 (make_gdb_type_flags): Likewise.
10881 (make_gdb_type_enum): Likewise.
10882 (make_gdb_type): New function.
10883 (tdesc_register_type): Use static make_gdb_type.
10885 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
10887 * infcmd.c (default_print_one_register_info): Align natural-format
10888 column values consistently one under another.
10889 (pad_to_column): New function.
10891 2018-02-05 Joel Brobecker <brobecker@adacore.com>
10893 * dwarf2read.c (dwarf2_physname): Move commment.
10895 2018-02-01 Leszek Swirski <leszeks@google.com>
10897 * varobj.c (varobj_formatted_print_options): Allow recursive
10898 pretty printing if pretty printing is enabled.
10900 2018-02-01 Leszek Swirski <leszeks@google.com>
10902 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
10903 names after a structop as a filename.
10905 2018-02-01 Yao Qi <yao.qi@linaro.org>
10907 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
10908 (arm_record_coproc_data_proc): Likewise.
10910 2018-02-01 Yao Qi <yao.qi@linaro.org>
10912 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
10914 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
10916 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
10917 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
10919 2018-01-31 Pedro Alves <palves@redhat.com>
10921 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
10922 * inflow.c (child_terminal_save_inferior): Wrap reference to
10923 tcgetpgrp in HAVE_TERMIOS_H.
10924 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
10926 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
10927 always iterate over all inferiors.
10928 (gdbsim_cntrl_c): Adjust.
10929 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
10931 2018-01-31 Joel Brobecker <brobecker@adacore.com>
10933 * gdbtypes.c (lookup_array_range_type): Make sure the array's
10934 index type is objfile-owned if the element type is as well.
10936 2018-01-31 Joel Brobecker <brobecker@adacore.com>
10940 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
10942 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
10943 "features/s390x-linux64.c".
10944 (_initialize_s390_linux_tdep): Remove initialization of tdescs
10945 s390_linux32 and s390x_linux64.
10946 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
10948 * s390-tdep.c: Include "features/s390-linux32.c" and
10949 "features/s390x-linux64.c".
10950 (s390_tdesc_valid): Add check for tdesc_has_registers.
10951 (s390_gdbarch_init): Make sure there is always a valid tdesc.
10952 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
10953 tdesc_s390x_linux64.
10954 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
10955 tdesc_s390x_linux64 to...
10956 * s390-tdep.h: ...here.
10958 2018-01-30 Pedro Alves <palves@redhat.com>
10961 * config.in, configure: Regenerate.
10962 * configure.ac: Check for getpgid.
10963 * go32-nat.c (go32_pass_ctrlc): New.
10964 (go32_target): Install it.
10965 * inf-child.c (inf_child_target): Install
10966 child_terminal_save_inferior, child_pass_ctrlc and
10968 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
10969 (inf_ptrace_target): No longer install it.
10970 * infcmd.c (interrupt_target_1): Adjust.
10971 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
10972 (child_interrupt): Declare.
10973 (inferior::terminal_state): New.
10974 * inflow.c (struct terminal_info): Update comments.
10975 (inferior_process_group): Delete.
10976 (terminal_is_ours): Delete.
10977 (gdb_tty_state): New.
10978 (child_terminal_init): Adjust.
10979 (is_gdb_terminal, sharing_input_terminal_1)
10980 (sharing_input_terminal): New functions.
10981 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
10982 Set the process's actual process group in the foreground if
10983 possible. Handle is_ours_for_output/is_ours distinction. Don't
10984 mark terminal as the inferior's if not sharing GDB's terminal.
10985 Don't check attach_flag.
10986 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
10987 pass down a target_terminal_state.
10988 (child_terminal_save_inferior): New, factored out from ...
10989 (child_terminal_ours_1): ... this. Handle
10990 target_terminal_state::is_ours_for_output.
10991 (child_interrupt, child_pass_ctrlc): New.
10992 (inflow_inferior_exit): Clear the inferior's terminal_state.
10993 (copy_terminal_info): Copy the inferior's terminal state.
10994 (_initialize_inflow): Remove reference to terminal_is_ours.
10995 * inflow.h (inferior_process_group): Delete.
10996 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
10997 * procfs.c (procfs_target): Don't install procfs_interrupt.
10998 (procfs_interrupt): Delete.
10999 * remote.c (remote_serial_quit_handler): Adjust.
11000 (remote_interrupt): Remove ptid parameter. Adjust.
11001 * target-delegates.c: Regenerate.
11002 * target.c: Include "terminal.h".
11003 (target_terminal::terminal_state): Rename to ...
11004 (target_terminal::m_terminal_state): ... this.
11005 (target_terminal::init): Adjust.
11006 (target_terminal::inferior): Adjust to per-inferior
11008 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
11009 (target_terminal::ours, target_terminal::ours_for_output): Use
11010 target_terminal_is_ours_kind.
11011 (target_interrupt): Remove ptid parameter. Adjust.
11012 (default_target_pass_ctrlc): Adjust.
11013 * target.h (target_ops::to_terminal_save_inferior): New field.
11014 (target_ops::to_interrupt): Remove ptid_t parameter.
11015 (target_interrupt): Remove ptid_t parameter. Update comment.
11016 (target_pass_ctrlc): Update comment.
11017 * target/target.h (target_terminal_state): New scoped enum,
11018 factored out of ...
11019 (target_terminal::terminal_state): ... here.
11020 (target_terminal::inferior): Update comments.
11021 (target_terminal::restore_inferior): New.
11022 (target_terminal::is_inferior, target_terminal::is_ours)
11023 (target_terminal::is_ours_for_output): Adjust.
11024 (target_terminal::scoped_restore_terminal_state): Adjust to
11025 rename, and call restore_inferior() instead of inferior().
11026 (target_terminal::scoped_restore_terminal_state::m_state): Change
11028 (target_terminal::terminal_state): Rename to ...
11029 (target_terminal::m_terminal_state): ... this and change type.
11031 2018-01-30 Pedro Alves <palves@redhat.com>
11033 * linux-nat.c (wait_for_signal): New function.
11034 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
11036 (async_terminal_is_ours)
11037 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
11038 (linux_nat_add_target): Don't override
11039 to_terminal_inferior/to_terminal_ours.
11041 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
11043 * remote.c (remote_follow_fork): Don't call "detach_inferior".
11045 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
11047 * dwarf2read.c (free_dwo_files): Add forward-declaration.
11048 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
11049 dwarf2_per_objfile_free here.
11050 (dwarf2_per_objfile_free): Remove.
11051 (_initialize_dwarf2_read): Don't register
11052 dwarf2_per_objfile_free as a registry cleanup.
11054 2018-01-27 Eli Zaretskii <eliz@gnu.org>
11056 Avoid compilation errors in MinGW native builds
11058 The error is triggered by including python-internal.h, and the
11061 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
11062 from build-gnulib/import/math.h:27,
11063 from d:/usr/Python26/include/pyport.h:235,
11064 from d:/usr/Python26/include/Python.h:58,
11065 from python/python-internal.h:94,
11066 from python/py-arch.c:24:
11067 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
11071 This happens because Python headers define 'hypot' to expand t
11072 '_hypot' in the Windows builds.
11073 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
11074 'hypoth'. This avoids a compilation error.
11076 2018-01-26 Alan Hayward <alan.hayward@arm.com>
11078 * MAINTAINERS (Write After Approval): Fix ordering.
11080 2018-01-26 Alan Hayward <alan.hayward@arm.com>
11082 * MAINTAINERS (Write After Approval): Add Alan Hayward.
11084 2018-01-26 Alan Modra <amodra@gmail.com>
11086 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
11087 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
11088 Remove nop. Make const. Comment.
11089 (powerpc32_plt_stub_so_2): New.
11090 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
11091 Correct count. Update uses.
11092 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
11093 Move common code reading PLT entry word. Correct
11094 powerpc32_plt_stub PLT address calculation.
11095 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
11096 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
11097 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
11098 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
11099 (ppc64_standard_linkage8): Likewise.
11100 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
11101 Correct insns description.
11102 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
11104 2018-01-24 Pedro Alves <palves@redhat.com>
11106 GCC PR libstdc++/83906
11107 * gdbtypes.c (operator==(const dynamic_prop &,
11108 const dynamic_prop &)): New.
11109 (operator==(const range_bounds &, const range_bounds &)): New.
11110 (check_types_equal): Use them instead of memcmp.
11111 * gdbtypes.h (operator==(const dynamic_prop &,
11112 const dynamic_prop &)): Declare.
11113 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
11114 (operator==(const range_bounds &, const range_bounds &)): Declare.
11115 (operator!=(const range_bounds &, const range_bounds &)): Declare.
11117 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11119 * s390-linux-tdep.c (s390_record_address_mask)
11120 (s390_record_calc_disp_common, s390_record_calc_disp)
11121 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
11122 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
11123 (s390_process_record): Move to s390-tdep.c.
11124 (s390_linux_init_abi_any): Adjust.
11125 * s390-tdep.c (s390_record_address_mask)
11126 (s390_record_calc_disp_common, s390_record_calc_disp)
11127 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
11128 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
11129 (s390_process_record): Moved from s390-linux-tdep.c
11130 (s390_gdbarch_init): Adjust.
11132 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11134 * s390-linux-nat.c (s390-tdep.h): New include.
11135 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
11136 (HFILES_NO_SRCDIR): Add s390-tdep.h.
11137 (ALLDEPFILES): Add s390-tdep.c.
11138 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
11139 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
11140 * s390-tdep.h: ...this. New file.
11141 * s390-linux-tdep.c (s390-tdep.h): New include.
11142 (_initialize_s390_tdep): Rename to...
11143 (_initialize_s390_linux_tdep): ...this and adjust.
11144 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
11145 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
11147 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
11148 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
11149 (s390_is_partial_instruction, s390_software_single_step)
11150 (is_non_branch_ril, s390_displaced_step_copy_insn)
11151 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
11152 (s390_prologue_data, s390_addr, s390_store, s390_load)
11153 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
11154 (s390_register_call_saved, s390_guess_tracepoint_registers)
11155 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
11156 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
11157 (s390_pseudo_register_name, s390_pseudo_register_type)
11158 (s390_pseudo_register_read, s390_pseudo_register_write)
11159 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
11160 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
11161 (s390_addr_bits_remove, s390_address_class_type_flags)
11162 (s390_address_class_type_flags_to_name)
11163 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
11164 (s390_function_arg_float, s390_function_arg_vector)
11165 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
11166 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
11167 (s390_frame_align, s390_register_return_value, s390_return_value)
11168 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
11169 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
11170 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
11171 (s390_trad_frame_prev_register, s390_unwind_cache)
11172 (s390_prologue_frame_unwind_cache)
11173 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
11174 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
11175 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
11176 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
11177 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
11178 (s390_frame_base_address, s390_local_base_address)
11179 (s390_frame_base, s390_gcc_target_options)
11180 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
11181 (s390_validate_reg_range, s390_tdesc_valid)
11182 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
11183 * s390-tdep.c: ...this. New file.
11185 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11187 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
11188 (s390_process_record, s390_gdbarch_tdep_alloc)
11189 (s390_linux_init_abi_any): Use/set new hook.
11191 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11193 * s390-linux-tdep.c (osabi.h): New include.
11194 (s390_linux_init_abi_31, s390_linux_init_abi_64)
11195 (s390_linux_init_abi_any): New functions.
11196 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
11198 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11200 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
11201 tdesc_has_registers check
11203 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11205 * s390-linux-tdep.c (s390_tdesc_valid): New function.
11206 (s390_validate_reg_range): New macro.
11207 (s390_gdbarch_init): Adjust.
11209 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11211 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
11212 (s390_gdbarch_tdep_alloc): Adjust.
11213 (s390_gdbarch_init): Adjust.
11215 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11217 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
11218 <have_tdb>: Change type to bool.
11219 (s390_gdbarch_tdep_alloc): Adjust.
11220 (s390_gdbarch_init): Adjust.
11222 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11224 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
11225 (gdbarch_tdep) <have_upper, have_vx>: New fields.
11226 (s390_gdbarch_tdep_alloc): New function.
11227 (s390_gdbarch_init): Allocate tdep at start and use its fields
11228 instead of separate variables.
11230 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11232 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
11233 when looking for cached gdbarch and add comment for remaining.
11235 2018-01-22 Pedro Alves <palves@redhat.com>
11236 Sergio Durigan Junior <sergiodj@redhat.com>
11238 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
11241 2018-01-22 Maciej W. Rozycki <macro@mips.com>
11243 * MAINTAINERS: Update my company e-mail address.
11245 2018-01-22 Yao Qi <yao.qi@linaro.org>
11247 * regcache.c (cooked_write_test): New function.
11248 (_initialize_regcache): Register the test.
11250 2018-01-22 Yao Qi <yao.qi@linaro.org>
11252 * ia64-tdep.c (ia64_pseudo_register_read): Call
11253 regcache->cooked_read instead of regcache_cooked_read_unsigned.
11254 * m32c-tdep.c (m32c_cat_read): Likewise.
11255 (m32c_r3r2r1r0_read): Likewise.
11256 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
11257 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
11259 2018-01-22 Yao Qi <yao.qi@linaro.org>
11261 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
11262 method raw_read instead of regcache_raw_read.
11263 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
11264 * arm-tdep.c (arm_neon_quad_read): Likewise.
11265 * avr-tdep.c (avr_pseudo_register_read): Likewise.
11266 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
11267 * frv-tdep.c (frv_pseudo_register_read): Likewise.
11268 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
11269 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
11270 (i386_pseudo_register_read_into_value): Likewise.
11271 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
11272 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
11273 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
11274 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
11275 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
11276 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
11277 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
11278 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
11279 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
11281 2018-01-22 Yao Qi <yao.qi@linaro.org>
11283 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
11284 * configure.tgt: Remove target mt.
11285 * mt-tdep.c: Remove.
11286 * regcache.c (cooked_read_test): Remove the check for mt.
11288 2018-01-22 Yao Qi <yao.qi@linaro.org>
11290 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
11291 instead of gdbarch_pseudo_register_read_value.
11293 2018-01-22 Joel Brobecker <brobecker@adacore.com>
11295 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
11298 2018-01-22 Joel Brobecker <brobecker@adacore.com>
11300 * linespec.c (create_sals_line_offset): Remove code that preserved
11301 the symtab_and_line's line number.
11303 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
11305 * varobj.c (varobj_create): Don't set valid_block when creating a
11308 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
11310 * varobj.c (varobj_create): Remove out of date comment.
11312 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
11315 * ada-exp.y (write_var_from_sym): Pass extra parameter when
11316 updating innermost block.
11317 * parse.c (innermost_block_tracker::update): Take extra type
11318 parameter, and check types match before updating innermost block.
11319 (write_dollar_variable): Update innermost block for registers.
11320 * parser-defs.h (enum innermost_block_tracker_type): New enum.
11321 (innermost_block_tracker::innermost_block_tracker): Initialise
11323 (innermost_block_tracker::reset): Take type parameter.
11324 (innermost_block_tracker::update): Take type parameter, and pass
11325 type through as needed.
11326 (innermost_block_tracker::m_types): New member.
11327 * varobj.c (varobj_create): Pass type when reseting innermost
11330 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
11332 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
11333 * ada-lang.c (resolve_subexp): Likewise.
11334 * breakpoint.c (set_breakpoint_condition) Likewise.
11335 (watch_command_1) Likewise.
11336 * c-exp.y (variable): Likewise.
11337 * d-exp.y (PrimaryExpression): Likewise.
11338 * f-exp.y (variable): Likewise.
11339 * go-exp.y (variable): Likewise.
11340 * m2-exp.y (variable): Likewise.
11341 * objfiles.c (objfile::~objfile): Likewise.
11342 * p-exp.y (variable): Likewise.
11343 * parse.c (innermost_block): Change type.
11344 * parser-defs.h (class innermost_block_tracker): New.
11345 (innermost_block): Change to innermost_block_tracker.
11346 * printcmd.c (display_command): Switch to innermost_block API.
11347 (do_one_display): Likewise.
11348 * rust-exp.y (do_one_display): Likewise.
11349 * symfile.c (clear_symtab_users): Likewise.
11350 * varobj.c (varobj_create): Switch to innermost_block API, replace
11351 use of innermost_block with block stored on varobj object.
11353 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
11355 * expression.h (innermost_block): Remove declaration.
11356 * varobj.c: Add 'parser-defs.h' include.
11358 2018-01-19 Tom Tromey <tom@tromey.com>
11360 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
11361 symbols in the static and global blocks.
11363 2018-01-19 James Clarke <jrtc27@jrtc27.com>
11365 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
11366 gdb_ptrace.h, and move including gdb_wait.h ...
11367 * nat/linux-ptrace.h: ... to here.
11369 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
11371 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
11372 inf_ptrace_detach_success.
11373 (inf_ptrace_detach_success): Add inferior parameter, use it
11374 instead of inferior_ptid, pass it to detach_inferior.
11375 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
11377 * inferior.c (detach_inferior): Add overload that takes an
11379 * inferior.h (detach_inferior): Likewise.
11380 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
11381 use inferior_ptid, adjust call to inf_ptrace_detach_success.
11382 * linux-thread-db.c (thread_db_detach): Use inf parameter.
11384 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
11386 * target.h (struct target_ops) <to_detach>: Add inferior
11388 (target_detach): Likewise.
11389 * target.c (dispose_inferior): Pass inferior down.
11390 (target_detach): Pass inferior down. Assert that it is equal to
11391 the current inferior.
11392 * aix-thread.c (aix_thread_detach): Pass inferior down.
11393 * corefile.c (core_file_command): Pass current_inferior() down.
11394 * corelow.c (core_detach): Add inferior parameter.
11395 * darwin-nat.c (darwin_detach): Likewise.
11396 * gnu-nat.c (gnu_detach): Likewise.
11397 * inf-ptrace.c (inf_ptrace_detach): Likewise.
11398 * infcmd.c (detach_command): Pass current_inferior() down to
11400 * infrun.c (follow_fork_inferior): Pass parent_inf to
11402 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
11404 * linux-nat.c (linux_nat_detach): Add inferior parameter.
11405 * linux-thread-db.c (thread_db_detach): Likewise.
11406 * nto-procfs.c (procfs_detach): Likewise.
11407 * procfs.c (procfs_detach): Likewise.
11408 * record.c (record_detach): Likewise.
11409 * record.h (struct inferior): Forward-declare.
11410 (record_detach): Add inferior parameter.
11411 * remote-sim.c (gdbsim_detach): Likewise.
11412 * remote.c (remote_detach_1): Likewise.
11413 (remote_detach): Likewise.
11414 (extended_remote_detach): Likewise.
11415 * sol-thread.c (sol_thread_detach): Likewise.
11416 * target-debug.h (target_debug_print_inferior_p): New macro.
11417 * target-delegates.c: Re-generate.
11418 * top.c (kill_or_detach): Pass inferior down to target_detach.
11419 * windows-nat.c (windows_detach): Add inferior parameter.
11421 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
11423 * target.h (struct target_ops) <to_detach>: Remove args
11425 (target_detach): Likewise.
11426 * target.c (dispose_inferior): Adjust.
11427 (target_detach): Remove args parameter, adjust.
11428 * aix-thread.c (aix_thread_detach): Adjust.
11429 * corefile.c (core_file_command): Adjust.
11430 * corelow.c (core_detach): Adjust.
11431 * darwin-nat.c (darwin_detach): Adjust.
11432 * gnu-nat.c (gnu_detach): Adjust.
11433 * inf-ptrace.c (inf_ptrace_detach): Adjust.
11434 * infcmd.c (detach_command): Adjust
11435 * infrun.c (follow_fork_inferior): Adjust.
11436 (handle_vfork_child_exec_or_exit): Adjust.
11437 * linux-fork.c (linux_fork_detach): Remove args parameter.
11438 * linux-fork.h (linux_fork_detach): Likewise.
11439 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
11440 * linux-thread-db.c (thread_db_detach): Likewise.
11441 * nto-procfs.c (procfs_detach): Likewise.
11442 * procfs.c (procfs_detach): Likewise.
11443 (do_detach): Remove signo parameter.
11444 * record.c (record_detach): Remove args parameter.
11445 * record.h (record_detach): Likewise.
11446 * remote-sim.c (gdbsim_detach): Likewise.
11447 * remote.c (remote_detach_1): Likewise.
11448 (remote_detach): Likewise.
11449 (extended_remote_detach): Likewise.
11450 * sol-thread.c (sol_thread_detach): Likewise.
11451 * target-delegates.c: Re-generate.
11452 * top.c (struct qt_args) <args>: Remove field.
11453 (kill_or_detach): Don't pass args.
11454 (quit_force): Don't set args.
11455 * windows-nat.c (windows_detach): Remove args parameter.
11457 2018-01-19 Yao Qi <yao.qi@linaro.org>
11459 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
11460 (arm_linux_init_abi): Install it.
11462 2018-01-19 Yao Qi <yao.qi@linaro.org>
11464 * osabi.c (gdb_osabi_names): Extend the regexp for
11465 arm-linux-gnueabihf.
11467 2018-01-18 Yao Qi <yao.qi@linaro.org>
11469 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
11471 (abbrev_table::add_abbrev): Update.
11472 (abbrev_table::lookup_abbrev): Update.
11474 2018-01-18 Yao Qi <yao.qi@linaro.org>
11476 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
11478 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
11480 * compile/compile.c (compile_to_object): Convert "triplet_rx"
11483 2018-01-17 Tom Tromey <tom@tromey.com>
11485 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
11487 2018-01-17 Tom Tromey <tom@tromey.com>
11489 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
11490 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
11491 (create_array_type_with_stride): Update.
11492 * dwarf2read.c (set_die_type): Update.
11494 2018-01-17 Tom Tromey <tom@tromey.com>
11496 * dwarf2read.c (delayed_method_info): Remove typedef.
11497 (dwarf2_cu::method_info): Now a std::vector.
11498 (add_to_method_list): Update.
11499 (free_delayed_list): Remove.
11500 (compute_delayed_physnames): Update.
11501 (process_full_comp_unit, process_full_type_unit): Clear the method
11502 list. Remove cleanups.
11503 (psymtab_include_file_name): Add name_holder parameter. Use
11504 unique_xmalloc_ptr.
11505 (dwarf_decode_lines): Update.
11507 2018-01-17 Tom Tromey <tom@tromey.com>
11508 Simon Marchi <simon.marchi@ericsson.com>
11510 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
11511 (dwarf2_per_objfile::free_cached_comp_units)
11512 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
11513 (init_cutu_and_read_dies_no_follow): Update.
11514 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
11515 (dwarf2_cu::~dwarf2_cu): New.
11516 (free_heap_comp_unit, free_stack_comp_unit): Remove.
11517 (age_cached_comp_units, free_one_cached_comp_unit): Update.
11519 2018-01-17 Tom Tromey <tom@tromey.com>
11520 Simon Marchi <simon.marchi@ericsson.com>
11522 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
11523 (struct die_reader_specs) <abbrev_table>: New member.
11524 (struct abbrev_table): Add constructor.
11525 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
11526 <abbrev_obstack>: Now an auto_obstack.
11527 (abbrev_table_up): New typedef.
11528 (init_cu_die_reader): Add abbrev_table parameter.
11529 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
11530 Add result_dwo_abbrev_table.
11531 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
11532 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
11534 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
11536 (skip_children): Update.
11537 (abbrev_table::alloc_abbrev): Rename from
11538 abbrev_table_alloc_abbrev.
11539 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
11540 (abbrev_table::lookup_abbrev): Rename from
11541 abbrev_table_lookup_abbrev.
11542 (abbrev_table_read_table): Return abbrev_table_up.
11543 (abbrev_table_free, abbrev_table_free_cleanup)
11544 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
11545 (load_partial_dies): Update.
11547 2018-01-17 Tom Tromey <tom@tromey.com>
11549 * dwarf2read.c (dwarf2_compute_name): Update comment.
11550 (read_func_scope, read_variable): Update.
11551 (new_symbol): Remove.
11552 (new_symbol_full): Rename to new_symbol.
11554 2018-01-17 Mike Gulick <mgulick@mathworks.com>
11557 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
11558 a warning instead of throwing an error, set section size to 0 and return
11560 * gdb_bfd.h (gdb_bfd_map_section): Update description.
11562 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
11564 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
11566 (linux_ptrace_attach_fail_reason_string): Likewise.
11567 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
11569 (linux_ptrace_attach_fail_reason_string): Likewise.
11570 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
11572 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
11574 * linux-nat.c (linux_nat_attach): Remove xstrdup.
11576 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
11579 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
11580 checking for fs_base/gs_base fields in struct user_regs_struct.
11581 * configure: Regenerate.
11583 2018-01-17 Yao Qi <yao.qi@linaro.org>
11585 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
11587 (aarch64_linux_init_abi): Install it to gdbarch hook
11588 gcc_target_options.
11590 2018-01-15 Pedro Alves <palves@redhat.com>
11592 * common/signals-state-save-restore.c
11593 (save_original_signals_state): Fix typos.
11595 2017-01-12 Tom Tromey <tom@tromey.com>
11596 Sergio Durigan Junior <sergiodj@redhat.com>
11598 * Makefile.in (install-only): Install gdb-add-index.
11600 2018-01-12 John Baldwin <jhb@FreeBSD.org>
11602 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
11604 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11606 * infrun.c (keep_going_pass_signal): Clear step-over info when
11607 insert_breakpoints fails.
11609 2018-01-11 Pedro Alves <palves@redhat.com>
11612 * infrun.c (resume): Rename to ...
11613 (resume_1): ... this.
11614 (resume): Reimplement as wrapper around resume_1.
11616 2018-01-11 Pedro Alves <palves@redhat.com>
11619 * remote.c (remote_parse_stop_reply): Default to the last-set
11620 general thread instead of to 'magic_null_ptid'.
11622 2018-01-10 Pedro Alves <palves@redhat.com>
11624 * language.h (language_get_symbol_name_matcher): Rename ...
11625 (get_symbol_name_matcher): ... this.
11626 * language.c (language_get_symbol_name_matcher): Ditto.
11627 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
11630 2018-01-10 Pedro Alves <palves@redhat.com>
11634 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
11635 Adjust to use language_get_symbol_name_matcher instead of
11636 language_defn::la_get_symbol_name_matcher.
11637 * language.c (language_get_symbol_name_matcher): If in Ada mode
11638 and the lookup name is a verbatim match, return Ada's matcher.
11639 * language.h (language_get_symbol_name_matcher): Adjust comment.
11640 (ada_lookup_name_info::verbatim_p):: New method.
11642 2018-01-10 Pedro Alves <palves@redhat.com>
11645 * ada-lang.c (ada_collect_symbol_completion_matches): If the
11646 minsym's language is language_auto or language_cplus, pass down
11647 language_ada instead.
11648 * symtab.c (compare_symbol_name): Don't frob symbol language here.
11650 2018-01-10 Pedro Alves <palves@redhat.com>
11653 * minsyms.c (linkage_name_str): New function.
11654 (iterate_over_minimal_symbols): Use it.
11656 2018-01-09 John Baldwin <jhb@FreeBSD.org>
11658 * NEWS: Document that 'info proc' now works on FreeBSD.
11660 2018-01-09 John Baldwin <jhb@FreeBSD.org>
11662 * configure.ac: Check for kinfo_getfile in libutil.
11663 * configure: Regenerate.
11664 * config.in: Regenerate.
11665 * fbsd-nat.c: Include "fbsd-tdep.h".
11666 (fbsd_fetch_cmdline): New.
11667 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
11668 rather than calling error.
11669 (fbsd_info_proc): New.
11670 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
11671 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
11672 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
11674 2018-01-09 John Baldwin <jhb@FreeBSD.org>
11676 * fbsd-nat.c (struct free_deleter): Remove.
11677 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
11679 2018-01-09 John Baldwin <jhb@FreeBSD.org>
11681 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
11682 NULL for an empty pathname.
11684 2018-01-09 John Baldwin <jhb@FreeBSD.org>
11686 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
11687 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
11688 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
11689 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
11690 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
11691 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
11692 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
11693 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
11694 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
11695 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
11696 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
11697 (fbsd_core_fetch_timeval, fbsd_print_sigset)
11698 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
11699 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
11700 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
11702 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
11704 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
11705 (gnu_xfer_auxv): New function.
11706 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
11707 TARGET_OBJECT_AUXV.
11709 2018-01-08 Yao Qi <yao.qi@linaro.org>
11710 Simon Marchi <simon.marchi@ericsson.com>
11712 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
11714 (COMMON_OBS): Remove selftest.o.
11715 * configure.ac: Append selftest-arch.c and common/selftest.c to
11716 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
11717 * configure: Re-generated.
11718 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
11720 (maintenance_info_selftests): Likewise.
11722 2018-01-08 Xavier Roirand <roirand@adacore.com>
11724 * ada-valprint.c (val_print_packed_array_elements): Use
11725 proper number of elements when printing an array indexed
11726 by an enumeration type.
11728 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11730 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
11731 (dw2_get_file_names_reader): Adjust.
11732 (lookup_dwo_signatured_type): Adjust.
11733 (lookup_dwp_signatured_type): Adjust.
11734 (lookup_signatured_type): Adjust.
11735 (create_type_unit_group): Adjust.
11736 (get_type_unit_group): Adjust.
11737 (process_psymtab_comp_unit_reader): Adjust.
11738 (build_type_psymtabs_reader): Adjust.
11739 (scan_partial_symbols): Adjust.
11740 (add_partial_symbol): Adjust.
11741 (add_partial_subprogram): Adjust.
11742 (peek_die_abbrev): Adjust.
11743 (fixup_go_packaging): Adjust.
11744 (process_imported_unit_die): Adjust.
11745 (dwarf2_compute_name): Adjust.
11746 (dwarf2_physname): Adjust.
11747 (read_import_statement): Adjust.
11748 (handle_DW_AT_stmt_list): Adjust.
11749 (read_file_scope): Adjust.
11750 (read_func_scope): Adjust.
11751 (read_lexical_block_scope): Adjust.
11752 (read_call_site_scope): Adjust.
11753 (read_variable): Adjust.
11754 (dwarf2_rnglists_process): Adjust.
11755 (dwarf2_ranges_process): Adjust.
11756 (dwarf2_ranges_read): Adjust.
11757 (dwarf2_get_pc_bounds): Adjust.
11758 (dwarf2_record_block_ranges): Adjust.
11759 (dwarf2_add_field): Adjust.
11760 (dwarf2_add_member_fn): Adjust.
11761 (read_structure_type): Adjust.
11762 (process_structure_scope): Adjust.
11763 (read_enumeration_type): Adjust.
11764 (read_array_type): Adjust.
11765 (mark_common_block_symbol_computed): Adjust.
11766 (read_common_block): Adjust.
11767 (read_namespace_type): Adjust.
11768 (read_namespace): Adjust.
11769 (read_module_type): Adjust.
11770 (read_tag_pointer_type): Adjust.
11771 (read_tag_ptr_to_member_type): Adjust.
11772 (read_tag_string_type): Adjust.
11773 (read_subroutine_type): Adjust.
11774 (read_typedef): Adjust.
11775 (read_base_type): Adjust.
11776 (attr_to_dynamic_prop): Adjust.
11777 (read_subrange_type): Adjust.
11778 (read_unspecified_type): Adjust.
11779 (dwarf2_read_abbrevs): Adjust.
11780 (load_partial_dies): Adjust.
11781 (read_partial_die): Adjust.
11782 (find_partial_die): Adjust.
11783 (guess_partial_die_structure_name): Adjust.
11784 (fixup_partial_die): Adjust.
11785 (read_attribute_value): Adjust.
11786 (read_addr_index): Adjust.
11787 (read_addr_index_from_leb128): Adjust.
11788 (read_str_index): Adjust.
11789 (dwarf2_string_attr): Adjust.
11790 (get_debug_line_section): Adjust.
11791 (dwarf_decode_line_header): Adjust.
11792 (lnp_state_machine::check_line_address): Adjust.
11793 (dwarf_decode_lines_1): Adjust.
11794 (dwarf_decode_lines): Adjust.
11795 (dwarf2_start_symtab): Adjust.
11796 (var_decode_location): Adjust.
11797 (new_symbol_full): Adjust.
11798 (dwarf2_const_value_data): Adjust.
11799 (dwarf2_const_value_attr): Adjust.
11800 (dwarf2_const_value): Adjust.
11801 (die_type): Adjust.
11802 (die_containing_type): Adjust.
11803 (build_error_marker_type): Adjust.
11804 (lookup_die_type): Adjust.
11805 (guess_full_die_structure_name): Adjust.
11806 (anonymous_struct_prefix): Adjust.
11807 (determine_prefix): Adjust.
11808 (dwarf2_name): Adjust.
11809 (follow_die_ref_or_sig): Adjust.
11810 (follow_die_offset): Adjust.
11811 (follow_die_ref): Adjust.
11812 (follow_die_sig_1): Adjust.
11813 (follow_die_sig): Adjust.
11814 (get_signatured_type): Adjust.
11815 (get_DW_AT_signature_type): Adjust.
11816 (decode_locdesc): Adjust.
11817 (dwarf_decode_macros): Adjust.
11818 (cu_debug_loc_section): Adjust.
11819 (fill_in_loclist_baton): Adjust.
11820 (dwarf2_symbol_mark_computed): Adjust.
11821 (init_one_comp_unit): Don't assign
11822 dwarf2_cu::dwarf2_per_objfile.
11823 (set_die_type): Adjust.
11825 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11827 * dwarf2read.c (struct mapped_debug_names): Add constructor.
11828 <dwarf2_per_objfile>: New field.
11829 (dwarf2_per_objfile): Remove global.
11830 (get_dwarf2_per_objfile): New function.
11831 (set_dwarf2_per_objfile): New function.
11832 (dwarf2_build_psymtabs_hard): Change objfile parameter to
11833 dwarf2_per_objfile.
11834 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
11835 (read_abbrev_offset): Likewise.
11836 (read_indirect_string): Likewise.
11837 (read_indirect_line_string): Likewise.
11838 (read_indirect_string_at_offset): Likewise.
11839 (read_indirect_string_from_dwz): Likewise.
11840 (dwarf2_find_containing_comp_unit): Change objfile parameter to
11841 dwarf2_per_objfile.
11842 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
11843 (create_all_comp_units): Change objfile parameter to
11844 dwarf2_per_objfile.
11845 (create_all_type_units): Likewise.
11846 (process_queue): Add dwarf2_per_objfile parameter.
11847 (read_and_check_comp_unit_head): Likewise.
11848 (lookup_dwo_unit_in_dwp): Likewise.
11849 (get_dwp_file): Likewise.
11850 (process_cu_includes): Likewise.
11851 (struct free_dwo_file_cleanup_data): New struct.
11852 (dwarf2_has_info): Use get_dwarf2_per_objfile and
11853 set_dwarf2_per_objfile.
11854 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
11855 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
11856 context, adjust calls.
11857 (dw2_instantiate_symtab): Likewise.
11858 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
11859 (dw2_get_cu): Likewise.
11860 (create_cu_from_index_list): Change objfile parameter to
11861 dwarf2_per_objfile.
11862 (create_cus_from_index_list): Get dwarf2_per_objfile from
11863 context, adjust calls.
11864 (create_cus_from_index): Likewise.
11865 (create_signatured_type_table_from_index): Change objfile
11866 parameter to dwarf2_per_objfile.
11867 (create_signatured_type_table_from_debug_names): Change objfile
11868 parameter to dwarf2_per_objfile.
11869 (create_addrmap_from_index): Likewise.
11870 (create_addrmap_from_aranges): Likewise.
11871 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
11872 (dw2_setup): Remove.
11873 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
11875 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
11876 get_dwarf2_per_objfile.
11877 (dw2_forget_cached_source_info): Likewise.
11878 (dw2_map_symtabs_matching_filename): Likewise.
11879 (struct dw2_symtab_iterator) <index>: Remove.
11880 <dwarf2_per_objfile>: New field.
11881 (dw2_symtab_iter_init): Replace index parameter with
11882 dwarf2_per_objfile.
11883 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
11884 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
11885 (dw2_print_stats): Likewise.
11886 (dw2_dump): Likewise.
11887 (dw2_expand_symtabs_for_function): Likewise.
11888 (dw2_expand_all_symtabs): Likewise.
11889 (dw2_expand_symtabs_with_fullname): Likewise.
11890 (dw2_expand_marked_cus): Replace index and objfile parameters
11891 with dwarf2_per_objfile.
11892 (dw_expand_symtabs_matching_file_matcher): Add
11893 dwarf2_per_objfile parameter and adjust calls.
11894 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
11896 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
11897 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
11899 (create_cus_from_debug_names_list): Replace objfile parameter
11900 with dwarf2_per_objfile and adjust calls.
11901 (create_cus_from_debug_names): Likewise.
11902 (dwarf2_read_debug_names): Likewise.
11903 (mapped_debug_names::namei_to_name): Adjust call.
11904 (dw2_debug_names_iterator::next): Likewise.
11905 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
11906 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
11907 (dw2_debug_names_dump): Likewise.
11908 (dw2_debug_names_expand_symtabs_for_function): Likewise.
11909 (dw2_debug_names_expand_symtabs_matching): Likewise.
11910 (dwarf2_initialize_objfile): Likewise.
11911 (dwarf2_build_psymtabs): Likewise.
11912 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
11914 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
11915 (read_and_check_comp_unit_head): Likewise.
11916 (read_abbrev_offset): Likewise.
11917 (create_debug_type_hash_table): Likewise.
11918 (create_debug_types_hash_table): Likewise.
11919 (create_all_type_units): Replace objfile parameter with
11920 dwarf2_per_objfile.
11921 (add_type_unit): Add dwarf2_per_objfile parameter.
11922 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
11923 with dwarf2_per_objfile.
11924 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
11925 (lookup_dwp_signatured_type): Likewise.
11926 (lookup_signatured_type): Likewise.
11927 (read_cutu_die_from_dwo): Likewise.
11928 (init_tu_and_read_dwo_dies): Likewise.
11929 (init_cutu_and_read_dies): Likewise.
11930 (init_cutu_and_read_dies_no_follow): Likewise.
11931 (allocate_type_unit_groups_table): Add objfile parameter.
11932 (create_type_unit_group): Use dwarf2_per_objfile from cu.
11933 (get_type_unit_group): Likewise.
11934 (process_psymtab_comp_unit): Update call.
11935 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
11936 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
11937 (print_tu_stats): Likewise.
11938 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
11939 in void* parameter.
11940 (build_type_psymtabs): Change objfile parameter to
11941 dwarf2_per_objfile.
11942 (process_skeletonless_type_unit): Use dwarf2_per_objfile
11943 passed in void* parameter.
11944 (process_skeletonless_type_units): Change objfile parameter to
11945 dwarf2_per_objfile.
11946 (set_partial_user): Likewise.
11947 (dwarf2_build_psymtabs_hard): Likewise.
11948 (read_comp_units_from_section): Likewise.
11949 (create_all_comp_units): Likewise.
11950 (scan_partial_symbols): Update calls.
11951 (add_partial_symbol): Likewise.
11952 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
11953 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
11954 (process_queue): Add dwarf2_per_objfile parameter.
11955 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
11956 (compute_compunit_symtab_includes): Likewise.
11957 (process_cu_includes): Add dwarf2_per_objfile parameter.
11958 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
11959 (process_full_type_unit): Likewise.
11960 (process_imported_unit_die): Update call.
11961 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
11962 (read_file_scope): Likewise.
11963 (allocate_dwo_file_hash_table): Add objfile parameter.
11964 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
11965 (create_cus_hash_table): Likewise.
11966 (create_dwp_hash_table): Likewise.
11967 (create_dwo_unit_in_dwp_v1): Likewise.
11968 (create_dwp_v2_section): Likewise.
11969 (create_dwo_unit_in_dwp_v2): Likewise.
11970 (lookup_dwo_unit_in_dwp): Likewise.
11971 (try_open_dwop_file): Likewise.
11972 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
11973 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
11974 cleanup to include a reference to dwarf2_per_objfile.
11975 (open_dwp_file): Add dwarf2_per_objfile parameter.
11976 (open_and_init_dwp_file): Likewise.
11977 (get_dwp_file): Likewise.
11978 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
11979 (queue_and_load_all_dwo_tus): Update call.
11980 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
11982 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
11983 (dwarf2_ranges_process): Likewise.
11984 (dwarf2_get_pc_bounds): Likewise.
11985 (mark_common_block_symbol_computed): Likewise.
11986 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
11987 (dwarf2_read_abbrevs): Update call.
11988 (read_partial_die): Use dwarf2_per_objfile from cu.
11989 (find_partial_die): Likewise.
11990 (fixup_partial_die): Likewise.
11991 (read_attribute_value): Likewise.
11992 (read_indirect_string_at_offset_from): Add objfile parameter.
11993 (read_indirect_string_at_offset): Add dwarf2_per_objfile
11995 (read_indirect_string_from_dwz): Add objfile parameter.
11996 (read_indirect_string): Add objfile parameter.
11997 (read_addr_index_1): Add dwarf2_per_objfile parameter.
11998 (read_addr_index): Use dwarf2_per_objfile from cu.
11999 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
12001 (read_str_index): Use dwarf2_per_objfile from cu.
12002 (get_debug_line_section): Likewise.
12003 (read_formatted_entries): Add dwarf2_per_objfile parameter.
12004 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
12005 (new_symbol_full): Use dwarf2_per_objfile from cu.
12006 (build_error_marker_type): Likewise.
12007 (lookup_die_type): Likewise.
12008 (determine_prefix): Likewise.
12009 (follow_die_offset): Likewise.
12010 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
12011 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
12012 (dwarf2_fetch_die_type_sect_off): Likewise.
12013 (dwarf2_get_die_type): Likewise.
12014 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
12015 (get_signatured_type): Likewise.
12016 (get_DW_AT_signature_type): Likewise.
12017 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
12018 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
12019 (cu_debug_loc_section): Likewise.
12020 (fill_in_loclist_baton): Likewise.
12021 (dwarf2_symbol_mark_computed): Likewise.
12022 (dwarf2_find_containing_comp_unit): Change objfile parameter to
12023 dwarf2_per_objfile.
12024 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
12026 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
12027 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
12028 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
12029 (set_die_type): Use dwarf2_free_objfile from cu.
12030 (get_die_type_at_offset): Likewise.
12031 (dwarf2_per_objfile_free): Don't assign global variable.
12032 (debug_names) <constructor>: Add dwarf2_per_objfile
12033 parameter, update m_debugstrlookup construction.
12034 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
12036 <m_dwarf2_per_objfile>: New field.
12037 <lookup>: Use m_dwarf2_per_objfile.
12038 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
12039 (psyms_seen_size): Likewise.
12040 (write_gdbindex): Replace objfile parameter with
12041 dwarf2_per_objfile.
12042 (write_debug_names): Likewise.
12043 (write_psymtabs_to_index): Likewise.
12044 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
12047 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
12049 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
12050 <dwarf2_per_objfile>: New field.
12051 (struct dwarf2_per_cu_data) <objfile>: Remove.
12052 <dwarf2_per_objfile>: New field.
12053 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
12055 (create_signatured_type_table_from_index): Likewise.
12056 (create_debug_type_hash_table): Likewise.
12057 (fill_in_sig_entry_from_dwo_entry): Likewise.
12058 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
12059 (create_type_unit_group): Assign dwarf2_per_objfile instead of
12061 (create_partial_symtab): Access objfile through
12062 dwarf2_per_objfile.
12063 (process_psymtab_comp_unit_reader): Likewise.
12064 (read_comp_units_from_section): Likewise.
12065 (scan_partial_symbols): Likewise.
12066 (add_partial_symbol): Likewise.
12067 (add_partial_subprogram): Likewise.
12068 (peek_die_abbrev): Likewise.
12069 (fixup_go_packaging): Likewise.
12070 (process_full_comp_unit): Likewise.
12071 (process_full_type_unit): Likewise.
12072 (process_imported_unit_die): Likewise.
12073 (dwarf2_compute_name): Likewise.
12074 (dwarf2_physname): Likewise.
12075 (read_import_statement): Likewise.
12076 (create_cus_hash_table): Assign dwarf2_physname instead of
12078 (read_func_scope): Access objfile through dwarf2_per_objfile.
12079 (read_lexical_block_scope): Likewise.
12080 (read_call_site_scope): Likewise.
12081 (read_variable): Likewise.
12082 (dwarf2_rnglists_process): Likewise.
12083 (dwarf2_ranges_process): Likewise.
12084 (dwarf2_ranges_read): Likewise.
12085 (dwarf2_record_block_ranges): Likewise.
12086 (dwarf2_add_field): Likewise.
12087 (dwarf2_add_member_fn): Likewise.
12088 (read_structure_type): Likewise.
12089 (process_structure_scope): Likewise.
12090 (read_enumeration_type): Likewise.
12091 (read_array_type): Likewise.
12092 (read_common_block): Likewise.
12093 (read_namespace_type): Likewise.
12094 (read_namespace): Likewise.
12095 (read_module_type): Likewise.
12096 (read_tag_pointer_type): Likewise.
12097 (read_tag_ptr_to_member_type): Likewise.
12098 (read_tag_string_type): Likewise.
12099 (read_subroutine_type): Likewise.
12100 (read_typedef): Likewise.
12101 (read_base_type): Likewise.
12102 (attr_to_dynamic_prop): Likewise.
12103 (read_subrange_type): Likewise.
12104 (read_unspecified_type): Likewise.
12105 (load_partial_dies): Likewise.
12106 (read_partial_die): Likewise.
12107 (find_partial_die): Likewise.
12108 (guess_partial_die_structure_name): Likewise.
12109 (fixup_partial_die): Likewise.
12110 (read_attribute_value): Likewise.
12111 (read_addr_index_from_leb128): Likewise.
12112 (dwarf2_read_addr_index): Likewise.
12113 (dwarf2_string_attr): Likewise.
12114 (lnp_state_machine::check_line_address): Likewise.
12115 (dwarf_decode_lines_1): Likewise.
12116 (dwarf_decode_lines): Likewise.
12117 (dwarf2_start_symtab): Likewise.
12118 (var_decode_location): Likewise.
12119 (new_symbol_full): Likewise.
12120 (dwarf2_const_value_data): Likewise.
12121 (dwarf2_const_value_attr): Likewise.
12122 (dwarf2_const_value): Likewise.
12123 (die_type): Likewise.
12124 (die_containing_type): Likewise.
12125 (lookup_die_type): Likewise.
12126 (guess_full_die_structure_name): Likewise.
12127 (anonymous_struct_prefix): Likewise.
12128 (dwarf2_name): Likewise.
12129 (follow_die_ref_or_sig): Likewise.
12130 (follow_die_offset): Likewise.
12131 (follow_die_ref): Likewise.
12132 (dwarf2_fetch_die_loc_sect_off): Likewise.
12133 (dwarf2_fetch_constant_bytes): Likewise.
12134 (dwarf2_fetch_die_type_sect_off): Likewise.
12135 (dwarf2_get_die_type): Likewise.
12136 (follow_die_sig): Likewise.
12137 (decode_locdesc): Likewise.
12138 (dwarf2_per_cu_objfile): Likewise.
12139 (dwarf2_per_cu_text_offset): Likewise.
12140 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
12142 (set_die_type): Access objfile through
12143 dwarf2_per_objfile.
12145 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
12147 * valprint.c (converted_character_d): Remove typedef.
12148 (DEF_VEC_O (converted_character_d)): Remove.
12149 (count_next_character): Use std::vector.
12150 (print_converted_chars_to_obstack): Likewise.
12151 (generic_printstr): Likewise.
12153 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
12155 * xml-support.h (struct gdb_xml_value): Add constructor.
12156 <value>: Change type to unique_xmalloc_ptr.
12157 (gdb_xml_value_s): Remove typedef.
12158 (DEF_VEC_O (gdb_xml_value_s)): Remove.
12159 (gdb_xml_element_start_handler): Change parameter type to
12161 (xml_find_attribute): Likewise.
12162 * xml-support.c (xml_find_attribute): Change parameter type to
12163 std::vector and adjust.
12164 (gdb_xml_values_cleanup): Remove.
12165 (gdb_xml_parser::start_element): Adjust to std::vector.
12166 (xinclude_start_include): Change paraeter type to std::vector
12168 * btrace.c (check_xml_btrace_version): Likewise.
12169 (parse_xml_btrace_block): Likewise.
12170 (parse_xml_btrace_pt_config_cpu): Likewise.
12171 (parse_xml_btrace_pt): Likewise.
12172 (parse_xml_btrace_conf_bts): Likewise.
12173 (parse_xml_btrace_conf_pt): Likewise.
12174 * memory-map.c (memory_map_start_memory): Likewise.
12175 (memory_map_start_property): Likewise.
12176 * osdata.c (osdata_start_osdata): Likewise.
12177 (osdata_start_item): Likewise.
12178 (osdata_start_column): Likewise.
12179 * remote.c (start_thread): Likewise.
12180 * solib-aix.c (library_list_start_library): Likewise.
12181 (library_list_start_list): Likewise.
12182 * solib-svr4.c (library_list_start_library): Likewise.
12183 (svr4_library_list_start_list): Likewise.
12184 * solib-target.c (library_list_start_segment): Likewise.
12185 (library_list_start_section): Likewise.
12186 (library_list_start_library): Likewise.
12187 (library_list_start_list): Likewise.
12188 * tracepoint.c (traceframe_info_start_memory): Likewise.
12189 (traceframe_info_start_tvar): Likewise.
12190 * xml-syscall.c (syscall_start_syscall): Likewise.
12191 * xml-tdesc.c (tdesc_start_target): Likewise.
12192 (tdesc_start_feature): Likewise.
12193 (tdesc_start_reg): Likewise.
12194 (tdesc_start_union): Likewise.
12195 (tdesc_start_struct): Likewise.
12196 (tdesc_start_flags): Likewise.
12197 (tdesc_start_enum): Likewise.
12198 (tdesc_start_field): Likewise.
12199 (tdesc_start_enum_value): Likewise.
12200 (tdesc_start_vector): Likewise.
12202 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
12204 * extension.h (struct xmethod_worker) <clone>: Remove.
12205 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
12207 (python_xmethod_worker::clone): Remove.
12208 * valops.c (find_overload_match): Use std::move instead of
12211 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
12213 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
12214 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
12215 <free_xmethod_worker_data>: Remove.
12216 <get_matching_xmethod_workers>: Chance VEC to std::vector.
12217 <get_xmethod_arg_types>: Remove.
12218 <get_xmethod_result_type>: Remove.
12219 <invoke_xmethod>: Remove.
12220 * extension.c (new_xmethod_worker): Remove.
12221 (clone_xmethod_worker): Remove.
12222 (get_matching_xmethod_workers): Return void, pass std::vector by
12224 (get_xmethod_arg_types): Rename to...
12225 (xmethod_worker::get_arg_types): ... this, and adjust.
12226 (get_xmethod_result_type): Rename to...
12227 (xmethod_worker::get_result_type): ... this, and adjust.
12228 (invoke_xmethod): Remove.
12229 (free_xmethod_worker): Remove.
12230 (free_xmethod_worker_vec): Remove.
12231 * extension.h (enum ext_lang_rc): Move here from
12233 (struct xmethod_worker): Add constructor and destructor.
12236 <invoke, clone, do_get_result_type, do_get_arg_types>: New
12237 virtual pure methods.
12238 <get_arg_types, get_result_type>: New methods.
12239 (xmethod_worker_ptr): Remove typedef.
12240 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
12241 (xmethod_worker_vec): Remove typedef.
12242 (xmethod_worker_up): New typedef.
12243 (invoke_xmethod): Remove.
12244 (clone_xmethod_worker): Remove.
12245 (free_xmethod_worker): Remove.
12246 (free_xmethod_worker_vec): Remove.
12247 (get_xmethod_arg_types): Remove.
12248 (get_xmethod_result_type): Remove.
12249 * valops.c (find_method_list): Use std::vector, don't use
12250 intermediate vector.
12251 (value_find_oload_method_list): Use std::vector.
12252 (find_overload_match): Use std::vector.
12253 (find_oload_champ): Use std::vector.
12254 * value.c (value_free): Use operator delete.
12255 (value_of_xmethod): Rename to...
12256 (value_from_xmethod): ... this. Don't assign
12257 xmethod_worker::value, take rvalue-reference.
12258 (result_type_of_xmethod): Adjust.
12259 (call_xmethod): Adjust.
12260 * value.h: Include extension.h.
12261 (struct xmethod_worker): Don't forward-declare.
12262 (value_of_xmethod): Rename to...
12263 (value_from_xmethod): ... this, take rvalue-reference.
12264 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
12265 (struct python_xmethod_worker): ... this, add constructor and
12267 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
12268 (gdbpy_free_xmethod_worker_data): Rename to...
12269 (python_xmethod_worker::~python_xmethod_worker): ... this and
12271 (gdbpy_clone_xmethod_worker_data): Rename to...
12272 (python_xmethod_worker::clone): ... this and adjust.
12273 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
12275 (gdbpy_get_xmethod_arg_types): Rename to...
12276 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
12277 (gdbpy_get_xmethod_result_type): Rename to...
12278 (python_xmethod_worker::do_get_result_type): ... this and
12280 (gdbpy_invoke_xmethod): Rename to...
12281 (python_xmethod_worker::invoke): ... this and adjust.
12282 (new_python_xmethod_worker): Rename to...
12283 (python_xmethod_worker::python_xmethod_worker): ... this and
12285 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
12287 (gdbpy_free_xmethod_worker_data): Remove.
12288 (gdbpy_get_matching_xmethod_workers): Use std::vector.
12289 (gdbpy_get_xmethod_arg_types): Remove.
12290 (gdbpy_get_xmethod_result_type): Remove.
12291 (gdbpy_invoke_xmethod): Remove.
12292 * python/python.c (python_extension_ops): Remove obsolete
12295 2018-01-05 Pedro Alves <palves@redhat.com>
12298 * common/signals-state-save-restore.c
12299 (save_original_signals_state): New parameter 'quiet'. Warn if we
12300 find a custom handler preinstalled, instead of internal erroring.
12301 But only warn if !quiet.
12302 * common/signals-state-save-restore.h
12303 (save_original_signals_state): New parameter 'quiet'.
12304 * main.c (captured_main_1): Move save_original_signals_state call
12305 after option handling, and pass QUIET.
12307 2018-01-05 Pedro Alves <palves@redhat.com>
12309 * spu-tdep.c (spu_catch_start): Pass
12310 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
12312 2018-01-05 Pedro Alves <palves@redhat.com>
12315 * ada-lang.c (literal_symbol_name_matcher): New function.
12316 (ada_get_symbol_name_matcher): Use it for
12317 symbol_name_match_type::SEARCH_NAME.
12318 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
12319 it down instead of assuming symbol_name_match_type::FULL.
12320 * block.h (block_lookup_symbol): New parameter 'match_type'.
12321 * c-valprint.c (print_unpacked_pointer): Use
12322 lookup_symbol_search_name instead of lookup_symbol.
12323 * compile/compile-object-load.c (get_out_value_type): Pass down
12324 symbol_name_match_type::SEARCH_NAME.
12325 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
12326 symbol_name_match_type::FULL.
12327 * cp-support.c (cp_get_symbol_name_matcher): Handle
12328 symbol_name_match_type::SEARCH_NAME.
12329 * infrun.c (insert_exception_resume_breakpoint): Use
12330 lookup_symbol_search_name.
12331 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
12332 * psymtab.c (maintenance_check_psymtabs): Use
12333 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
12334 * stack.c (print_frame_args): Use lookup_symbol_search_name and
12335 SYMBOL_SEARCH_NAME.
12336 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
12337 if symbol_name_match_type::SEARCH_NAME.
12338 (lookup_symbol_in_language): Pass down
12339 symbol_name_match_type::FULL.
12340 (lookup_symbol_search_name): New.
12341 (lookup_language_this): Pass down
12342 symbol_name_match_type::SEARCH_NAME.
12343 (lookup_symbol_aux, lookup_local_symbol): New parameter
12344 'match_type'. Pass it down.
12345 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
12346 (lookup_symbol_search_name): New declaration.
12347 (lookup_symbol_in_block): New 'match_type' parameter.
12349 2018-01-05 Pedro Alves <palves@redhat.com>
12352 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
12354 (ada_lookup_symbol): Reimplement in terms of
12355 ada_lookup_symbol_list, bits factored out from
12356 ada_lookup_encoded_symbol.
12358 2018-01-05 Joel Brobecker <brobecker@adacore.com>
12360 * ada-exp.y (write_object_renaming): When subscripting an array
12361 using a symbol as the index, pass the block in call to
12362 ada_lookup_encoded_symbol when looking that symbol up.
12364 2018-01-05 Jerome Guitton <guitton@adacore.com>
12366 * ada-lang.c (ada_array_length): Use ada_index_type instead of
12369 2018-01-05 Joel Brobecker <brobecker@adacore.com>
12371 * ada-lang.c (ada_to_fixed_value_create): Add handling of
12372 the case where VALUE_LVAL (val0) is not lval_memory.
12374 2018-01-05 Xavier Roirand <roirand@adacore.com>
12376 * ada-valprint.c (print_optional_low_bound): Handle
12377 character-indexed array printing like boolean-indexed array
12380 2018-01-05 Joel Brobecker <brobecker@adacore.com>
12382 * NEWS: Create a new section for the next release branch.
12383 Rename the section of the current branch, now that it has
12386 2018-01-05 Joel Brobecker <brobecker@adacore.com>
12388 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
12389 * version.in: Bump version to 8.1.50.DATE-git.
12391 2018-01-03 Xavier Roirand <roirand@adacore.com>
12393 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
12395 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
12397 (default_exception_support_info) <catch_handlers_sym>: Add field.
12398 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
12399 (ada_exception_name_addr_1): Add "catch handlers" handling.
12400 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
12401 Update all callers.
12402 (create_excep_cond_exprs) <ex>: Add parameter.
12403 (re_set_exception): Update create_excep_cond_exprs call.
12404 (print_it_exception, print_one_exception, print_mention_exception)
12405 (print_recreate_exception): Add "catch handler" handling.
12406 (allocate_location_catch_handlers, re_set_catch_handlers)
12407 (check_status_catch_handlers, print_it_catch_handlers)
12408 (print_one_catch_handlers, print_mention_catch_handlers)
12409 (print_recreate_catch_handlers): New function.
12410 (catch_handlers_breakpoint_ops): New variable.
12411 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
12412 Add parameter. Add "catch handler" handling.
12413 (ada_exception_sym_name, ada_exception_breakpoint_ops):
12414 Add "catch handler" handling.
12415 (ada_exception_catchpoint_cond_string): Add "catch handler"
12417 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
12419 (catch_ada_handlers_command): New function.
12420 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
12421 operations structure.
12422 (_initialize_ada_language): Add "catch handlers" command entry.
12423 * NEWS: Document "catch handlers" feature.
12425 2018-01-02 Joel Brobecker <brobecker@adacore.com>
12427 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
12428 account when creating the array type of the slice.
12429 (ada_value_slice): Likewise.
12431 2018-01-02 Joel Brobecker <brobecker@adacore.com>
12433 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
12435 (create_array_type_with_stride): Add byte_stride_prop parameter.
12436 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
12437 New parameter. Update all callers in this file.
12438 (array_type_has_dynamic_stride): New function.
12439 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
12440 of arrays with dynamic byte strides.
12441 * dwarf2read.c (read_array_type): Add support for dynamic
12442 DW_AT_byte_stride attributes.
12444 2018-01-02 Joel Brobecker <brobecker@adacore.com>
12446 * dwarf2read.c (read_unspecified_type): Treat
12447 DW_TAG_enumeration_type DIEs from Ada units as stubs.
12449 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12451 Update copyright year range in all GDB files.
12453 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12455 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
12456 and gdb/testsuite/gdb.base/step-line.c.
12458 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12460 * copyright.py (main): Dump the contents of
12461 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
12462 even if BY_HAND is empty.
12464 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12466 * top.c (print_gdb_version): Update Copyright year in version
12469 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12471 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
12473 For older changes see ChangeLog-2017.
12479 version-control: never