1 2018-09-16 Tom Tromey <tom@tromey.com>
3 * python/py-progspace.c (pspy_get_objfiles): Update.
4 * python/python-internal.h (objfile_to_objfile_object): Change
6 * python/py-newobjfileevent.c (create_new_objfile_event_object):
8 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
10 * python/python.c (gdbpy_get_current_objfile): Update.
11 (gdbpy_objfiles): Update.
12 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
14 (objfile_to_objfile_object): Return a new reference.
15 * python/py-symtab.c (stpy_get_objfile): Update.
16 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
19 2018-09-16 Tom Tromey <tom@tromey.com>
21 * python/py-inferior.c (infpy_get_progspace): Update.
22 * python/python-internal.h (pspace_to_pspace_object): Change
24 * python/py-newobjfileevent.c
25 (create_clear_objfiles_event_object): Update.
26 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
28 * python/python.c (gdbpy_get_current_progspace): Update.
29 (gdbpy_progspaces): Update.
30 * python/py-progspace.c (pspace_to_pspace_object): Return a new
32 * python/py-objfile.c (objfpy_get_progspace): Update.
33 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
36 2018-09-16 Tom Tromey <tom@tromey.com>
38 * python/lib/gdb/__init__.py (current_progspace, objfiles)
39 (solib_name, block_for_pc, find_pc_line): New functions.
40 (execute_unwinders): Update.
41 * python/py-block.c (gdbpy_block_for_pc): Remove.
42 * python/py-inferior.c (infpy_get_progspace): New function.
43 (inferior_object_getset) <progspace>: Add.
44 * python/py-progspace.c (pspy_objfiles): Rewrite.
45 (pspy_solib_name, pspy_block_for_pc)
46 (pspy_find_pc_line, pspy_is_valid): New functions.
47 (progspace_object_methods): Add entries for solib_name,
48 block_for_pc, find_pc_line, is_valid.
49 * python/python-internal.h (gdbpy_block_for_pc)
50 (build_objfiles_list): Don't declare.
51 * python/python.c: Don't include solib.h.
52 (gdbpy_solib_name, gdbpy_find_pc_line)
53 (gdbpy_get_current_progspace, build_objfiles_list)
54 (gdbpy_objfiles): Remove.
55 (GdbMethods) <current_progspace, objfiles, block_for_pc,
56 solib_name, find_pc_line>: Remove entries.
58 2018-09-16 Tom Tromey <tom@tromey.com>
60 * top.c (new_ui_command): Use GNU style for metasyntactic
62 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
64 * maint.c (maintenance_translate_address): Remove "<>" around
66 * interps.c (interpreter_exec_cmd): Use GNU style for
67 metasyntactic variables.
68 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
69 metasyntactic variables.
70 * tracepoint.c (tfind_range_command): Use GNU style for
71 metasyntactic variables.
72 (tfind_outside_command): Likewise.
73 (_initialize_tracepoint): Likewise.
74 * remote.c (extended_remote_target::create_inferior): Use GNU
75 style for metasyntactic variables.
76 * sparc64-tdep.c (adi_examine_command): Use GNU style for
77 metasyntactic variables.
78 (adi_assign_command): Likewise.
80 2018-09-16 Tom Tromey <tom@tromey.com>
82 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
83 metasyntactic variables. Print message if no disassembler options
86 2018-09-15 Tom Tromey <tom@tromey.com>
88 * infcmd.c (get_inferior_args): Return const char *.
89 * inferior.h (get_inferior_args): Return type now const.
90 * linux-tdep.c (linux_fill_prpsinfo): Update.
91 * procfs.c (procfs_target::make_corefile_notes): Update.
93 2018-09-07 Tom Tromey <tom@tromey.com>
95 * python/python.c (execute_gdb_command): Call bpstat_do_actions
98 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
100 * nios2-tdep.c (nios2_type_align): New.
101 (nios2_gdb_arch_init): Install type_align hook.
103 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
105 * eval.c (fake_method::fake_method): Call xzalloc directly for a
106 type that is neither object file owned, nor gdbarch owned.
107 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
109 (alloc_type_instance): Allocate non-objfile owned types on the
111 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
112 using TYPE_ALLOC to ensure memory is allocated on the correct
114 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
115 obstack, or the gdbarch obstack.
116 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
118 2018-09-14 Tom Tromey <tom@tromey.com>
120 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
123 2018-09-14 Tom Tromey <tom@tromey.com>
125 * nat/fork-inferior.c (get_startup_shell): Remove "static".
127 2018-09-13 Tom Tromey <tom@tromey.com>
129 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
132 2018-09-13 Tom Tromey <tom@tromey.com>
134 * exec.c (try_open_exec_file): Use std::string.
136 2018-09-13 Tom Tromey <tom@tromey.com>
138 * utils.h (gdb_bfd_errmsg): Return std::string.
139 * exec.c (exec_file_attach): Update.
140 * compile/compile-object-load.c (compile_object_load): Update.
141 * utils.c (gdb_bfd_errmsg): Return std::string.
143 2018-09-13 Tom Tromey <tom@tromey.com>
145 * procfs.c (struct procinfo_deleter): New.
146 (procinfo_up): New typedef.
147 (do_destroy_procinfo_cleanup): Remove.
148 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
150 2018-09-13 Tom Tromey <tom@tromey.com>
152 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
154 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
155 2018-09-13 Tom Tromey <tom@tromey.com>
157 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
158 (pspy_get_objfiles): New function.
159 (progspace_object_methods): New.
160 (pspace_object_type): Add tp_methods callback.
161 * python/python-internal.h (build_objfiles_list): New
163 * python/python.c (build_objfiles_list): New function.
164 (gdbpy_objfiles): Implement using build_objfiles_list.
165 * NEWS: Mention the Progspace.objfiles method.
167 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
169 * python/py-inferior.c (infpy_get_progspace): New function.
170 (inferior_object_getset): Add progspace property.
171 * NEWS: Mention the new property.
173 2018-09-13 Tom Tromey <tom@tromey.com>
176 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
178 2018-09-13 Tom Tromey <tom@tromey.com>
181 * rust-lang.c (rust_enum_variant): Now static.
182 (rust_empty_enum_p): New function.
183 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
186 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
188 * python/py-inferior.c (infpy_repr): New.
189 (inferior_object_type): Register infpy_repr.
190 * python/py-objfile.c (objfpy_repr): New.
191 (objfile_object_type): Register objfpy_repr.
193 2018-09-12 John Baldwin <jhb@FreeBSD.org>
195 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
197 2018-09-12 John Baldwin <jhb@FreeBSD.org>
199 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
202 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
204 * common/common-utils.c: Don't include '<sys/stat.h>'.
205 (is_regular_file): Move to...
206 * common/filestuff.c (is_regular_file): ... here.
207 * common/common-utils.h (is_regular_file): Move to...
208 * common/filestuff.h (is_regular_file): ... here.
210 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
212 * skip.c (debug_skip): New variable.
213 (skiplist_entry::do_skip_file_p): Add debug output.
214 (skiplist_entry::do_skip_gfile_p): Likewise.
215 (skiplist_entry::skip_function_p): Likewise.
216 (_initialize_step_skip): Create debug command.
217 * NEWS: Mention set/show debug skip.
219 2018-09-11 Xavier Roirand <roirand@adacore.com>
221 * darwin-nat.c (should_disable_startup_with_shell):
223 (darwin_nat_target::create_inferior): Add call.
225 2018-09-11 Xavier Roirand <roirand@adacore.com>
227 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
228 inf_port, msg_state>: Initialize.
229 (struct darwin_thread_info) <signaled, single_step>: Change
231 (struct darwin_thread_info) <event>: Initialize.
233 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
237 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
240 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
243 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
247 * gnulib/aclocal.m4: Regenerate.
248 * gnulib/config.in: Regenerate.
249 * gnulib/configure: Regenerate.
250 * gnulib/import/Makefile.am: Update.
251 * gnulib/import/Makefile.in: Update.
252 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
253 * gnulib/import/_Noreturn.h: ... this.
254 * gnulib/import/alloca.in.h: Update.
255 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
256 * gnulib/import/arg-nonnull.h: ... this.
257 * gnulib/import/assure.h: Update.
258 * gnulib/import/at-func.c: Update.
259 * gnulib/import/basename-lgpl.c: Update.
260 * gnulib/import/extra/snippet/c++defs.h: Rename to...
261 * gnulib/import/c++defs.h: ... this.
262 * gnulib/import/canonicalize-lgpl.c: Update.
263 * gnulib/import/cdefs.h: Update.
264 * gnulib/import/chdir-long.c: Update.
265 * gnulib/import/chdir-long.h: Update.
266 * gnulib/import/cloexec.c: Update.
267 * gnulib/import/cloexec.h: Update.
268 * gnulib/import/close.c: Update.
269 * gnulib/import/closedir.c: Update.
270 * gnulib/import/config.charset: Update.
271 * gnulib/import/dirent-private.h: Update.
272 * gnulib/import/dirent.in.h: Update.
273 * gnulib/import/dirfd.c: Update.
274 * gnulib/import/dirname-lgpl.c: Update.
275 * gnulib/import/dirname.h: Update.
276 * gnulib/import/dosname.h: Update.
277 * gnulib/import/dup-safer-flag.c: Update.
278 * gnulib/import/dup-safer.c: Update.
279 * gnulib/import/dup.c: Update.
280 * gnulib/import/dup2.c: Update.
281 * gnulib/import/errno.in.h: Update.
282 * gnulib/import/error.c: Update.
283 * gnulib/import/error.h: Update.
284 * gnulib/import/exitfail.c: Update.
285 * gnulib/import/exitfail.h: Update.
286 * gnulib/import/extra/update-copyright: Update.
287 * gnulib/import/fchdir.c: Update.
288 * gnulib/import/fcntl.c: Update.
289 * gnulib/import/fcntl.in.h: Update.
290 * gnulib/import/fd-hook.c: Update.
291 * gnulib/import/fd-hook.h: Update.
292 * gnulib/import/fd-safer-flag.c: Update.
293 * gnulib/import/fd-safer.c: Update.
294 * gnulib/import/fdopendir.c: Update.
295 * gnulib/import/filename.h: Update.
296 * gnulib/import/filenamecat-lgpl.c: Update.
297 * gnulib/import/filenamecat.h: Update.
298 * gnulib/import/flexmember.h: Update.
299 * gnulib/import/float+.h: Update.
300 * gnulib/import/float.c: Update.
301 * gnulib/import/float.in.h: Update.
302 * gnulib/import/fnmatch.c: Update.
303 * gnulib/import/fnmatch.in.h: Update.
304 * gnulib/import/fnmatch_loop.c: Update.
305 * gnulib/import/fpucw.h: Update.
306 * gnulib/import/frexp.c: Update.
307 * gnulib/import/frexpl.c: Update.
308 * gnulib/import/fstat.c: Update.
309 * gnulib/import/fstatat.c: Update.
310 * gnulib/import/getcwd-lgpl.c: Update.
311 * gnulib/import/getcwd.c: Update.
312 * gnulib/import/getdtablesize.c: Update.
313 * gnulib/import/getlogin_r.c: Update.
314 * gnulib/import/getprogname.c: Update.
315 * gnulib/import/getprogname.h: Update.
316 * gnulib/import/gettext.h: Update.
317 * gnulib/import/gettimeofday.c: Update.
318 * gnulib/import/glob-libc.h: Update.
319 * gnulib/import/glob.c: Update.
320 * gnulib/import/glob.in.h: Update.
321 * gnulib/import/glob_internal.h: Update.
322 * gnulib/import/glob_pattern_p.c: Update.
323 * gnulib/import/globfree.c: Update.
324 * gnulib/import/hard-locale.c: Update.
325 * gnulib/import/hard-locale.h: Update.
326 * gnulib/import/intprops.h: Update.
327 * gnulib/import/inttypes.in.h: Update.
328 * gnulib/import/isnan.c: Update.
329 * gnulib/import/isnand-nolibm.h: Update.
330 * gnulib/import/isnand.c: Update.
331 * gnulib/import/isnanl-nolibm.h: Update.
332 * gnulib/import/isnanl.c: Update.
333 * gnulib/import/itold.c: Update.
334 * gnulib/import/libc-config.h: Update.
335 * gnulib/import/limits.in.h: Update.
336 * gnulib/import/localcharset.c: Update.
337 * gnulib/import/localcharset.h: Update.
338 * gnulib/import/localtime-buffer.c: Update.
339 * gnulib/import/localtime-buffer.h: Update.
340 * gnulib/import/lstat.c: Update.
341 * gnulib/import/m4/00gnulib.m4: Update.
342 * gnulib/import/m4/__inline.m4: Update.
343 * gnulib/import/m4/absolute-header.m4: Update.
344 * gnulib/import/m4/alloca.m4: Update.
345 * gnulib/import/m4/builtin-expect.m4: Update.
346 * gnulib/import/m4/canonicalize.m4: Update.
347 * gnulib/import/m4/chdir-long.m4: Update.
348 * gnulib/import/m4/close.m4: Update.
349 * gnulib/import/m4/closedir.m4: Update.
350 * gnulib/import/m4/configmake.m4: Update.
351 * gnulib/import/m4/d-ino.m4: Update.
352 * gnulib/import/m4/d-type.m4: Update.
353 * gnulib/import/m4/dirent_h.m4: Update.
354 * gnulib/import/m4/dirfd.m4: Update.
355 * gnulib/import/m4/dirname.m4: Update.
356 * gnulib/import/m4/double-slash-root.m4: Update.
357 * gnulib/import/m4/dup.m4: Update.
358 * gnulib/import/m4/dup2.m4: Update.
359 * gnulib/import/m4/eealloc.m4: Update.
360 * gnulib/import/m4/environ.m4: Update.
361 * gnulib/import/m4/errno_h.m4: Update.
362 * gnulib/import/m4/error.m4: Update.
363 * gnulib/import/m4/exponentd.m4: Update.
364 * gnulib/import/m4/exponentl.m4: Update.
365 * gnulib/import/m4/extensions.m4: Update.
366 * gnulib/import/m4/extern-inline.m4: Update.
367 * gnulib/import/m4/fchdir.m4: Update.
368 * gnulib/import/m4/fcntl-o.m4: Update.
369 * gnulib/import/m4/fcntl.m4: Update.
370 * gnulib/import/m4/fcntl_h.m4: Update.
371 * gnulib/import/m4/fdopendir.m4: Update.
372 * gnulib/import/m4/filenamecat.m4: Update.
373 * gnulib/import/m4/flexmember.m4: Update.
374 * gnulib/import/m4/float_h.m4: Update.
375 * gnulib/import/m4/fnmatch.m4: Update.
376 * gnulib/import/m4/fnmatch_h.m4: Update.
377 * gnulib/import/m4/fpieee.m4: Update.
378 * gnulib/import/m4/frexp.m4: Update.
379 * gnulib/import/m4/frexpl.m4: Update.
380 * gnulib/import/m4/fstat.m4: Update.
381 * gnulib/import/m4/fstatat.m4: Update.
382 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
383 * gnulib/import/m4/getcwd-path-max.m4: Update.
384 * gnulib/import/m4/getcwd.m4: Update.
385 * gnulib/import/m4/getdtablesize.m4: Update.
386 * gnulib/import/m4/getlogin.m4: Update.
387 * gnulib/import/m4/getlogin_r.m4: Update.
388 * gnulib/import/m4/getpagesize.m4: Update.
389 * gnulib/import/m4/getprogname.m4: Update.
390 * gnulib/import/m4/gettimeofday.m4: Update.
391 * gnulib/import/m4/glibc21.m4: Update.
392 * gnulib/import/m4/glob.m4: Update.
393 * gnulib/import/m4/glob_h.m4: Update.
394 * gnulib/import/m4/gnulib-cache.m4: Update.
395 * gnulib/import/m4/gnulib-common.m4: Update.
396 * gnulib/import/m4/gnulib-comp.m4: Update.
397 * gnulib/import/m4/gnulib-tool.m4: Update.
398 * gnulib/import/m4/hard-locale.m4: Update.
399 * gnulib/import/m4/include_next.m4: Update.
400 * gnulib/import/m4/inttypes-pri.m4: Update.
401 * gnulib/import/m4/inttypes.m4: Update.
402 * gnulib/import/m4/isnand.m4: Update.
403 * gnulib/import/m4/isnanl.m4: Update.
404 * gnulib/import/m4/largefile.m4: Update.
405 * gnulib/import/m4/limits-h.m4: Update.
406 * gnulib/import/m4/localcharset.m4: Update.
407 * gnulib/import/m4/locale-fr.m4: Update.
408 * gnulib/import/m4/locale-ja.m4: Update.
409 * gnulib/import/m4/locale-zh.m4: Update.
410 * gnulib/import/m4/localtime-buffer.m4: Update.
411 * gnulib/import/m4/longlong.m4: Update.
412 * gnulib/import/m4/lstat.m4: Update.
413 * gnulib/import/m4/malloc.m4: Update.
414 * gnulib/import/m4/malloca.m4: Update.
415 * gnulib/import/m4/math_h.m4: Update.
416 * gnulib/import/m4/mbrtowc.m4: Update.
417 * gnulib/import/m4/mbsinit.m4: Update.
418 * gnulib/import/m4/mbsrtowcs.m4: Update.
419 * gnulib/import/m4/mbstate_t.m4: Update.
420 * gnulib/import/m4/memchr.m4: Update.
421 * gnulib/import/m4/memmem.m4: Update.
422 * gnulib/import/m4/mempcpy.m4: Update.
423 * gnulib/import/m4/memrchr.m4: Update.
424 * gnulib/import/m4/mkdir.m4: Update.
425 * gnulib/import/m4/mkstemp.m4: Update.
426 * gnulib/import/m4/mmap-anon.m4: Update.
427 * gnulib/import/m4/mode_t.m4: Update.
428 * gnulib/import/m4/msvc-inval.m4: Update.
429 * gnulib/import/m4/msvc-nothrow.m4: Update.
430 * gnulib/import/m4/multiarch.m4: Update.
431 * gnulib/import/m4/nocrash.m4: Update.
432 * gnulib/import/m4/off_t.m4: Update.
433 * gnulib/import/m4/onceonly.m4: Update.
434 * gnulib/import/m4/open-cloexec.m4: Update.
435 * gnulib/import/m4/open.m4: Update.
436 * gnulib/import/m4/openat.m4: Update.
437 * gnulib/import/m4/opendir.m4: Update.
438 * gnulib/import/m4/pathmax.m4: Update.
439 * gnulib/import/m4/rawmemchr.m4: Update.
440 * gnulib/import/m4/readdir.m4: Update.
441 * gnulib/import/m4/readlink.m4: Update.
442 * gnulib/import/m4/realloc.m4: Update.
443 * gnulib/import/m4/rename.m4: Update.
444 * gnulib/import/m4/rewinddir.m4: Update.
445 * gnulib/import/m4/rmdir.m4: Update.
446 * gnulib/import/m4/save-cwd.m4: Update.
447 * gnulib/import/m4/secure_getenv.m4: Update.
448 * gnulib/import/m4/setenv.m4: Update.
449 * gnulib/import/m4/signal_h.m4: Update.
450 * gnulib/import/m4/ssize_t.m4: Update.
451 * gnulib/import/m4/stat-time.m4: Update.
452 * gnulib/import/m4/stat.m4: Update.
453 * gnulib/import/m4/std-gnu11.m4: Update.
454 * gnulib/import/m4/stdbool.m4: Update.
455 * gnulib/import/m4/stddef_h.m4: Update.
456 * gnulib/import/m4/stdint.m4: Update.
457 * gnulib/import/m4/stdio_h.m4: Update.
458 * gnulib/import/m4/stdlib_h.m4: Update.
459 * gnulib/import/m4/strchrnul.m4: Update.
460 * gnulib/import/m4/strdup.m4: Update.
461 * gnulib/import/m4/strerror.m4: Update.
462 * gnulib/import/m4/string_h.m4: Update.
463 * gnulib/import/m4/strstr.m4: Update.
464 * gnulib/import/m4/strtok_r.m4: Update.
465 * gnulib/import/m4/sys_socket_h.m4: Update.
466 * gnulib/import/m4/sys_stat_h.m4: Update.
467 * gnulib/import/m4/sys_time_h.m4: Update.
468 * gnulib/import/m4/sys_types_h.m4: Update.
469 * gnulib/import/m4/tempname.m4: Update.
470 * gnulib/import/m4/time_h.m4: Update.
471 * gnulib/import/m4/unistd-safer.m4: Update.
472 * gnulib/import/m4/unistd_h.m4: Update.
473 * gnulib/import/m4/warn-on-use.m4: Update.
474 * gnulib/import/m4/wchar_h.m4: Update.
475 * gnulib/import/m4/wchar_t.m4: Update.
476 * gnulib/import/m4/wctype_h.m4: Update.
477 * gnulib/import/m4/wint_t.m4: Update.
478 * gnulib/import/malloc.c: Update.
479 * gnulib/import/malloc/scratch_buffer.h: Update.
480 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
481 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
482 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
483 * gnulib/import/malloca.c: Update.
484 * gnulib/import/malloca.h: Update.
485 * gnulib/import/malloca.valgrind: Update.
486 * gnulib/import/math.in.h: Update.
487 * gnulib/import/mbrtowc.c: Update.
488 * gnulib/import/mbsinit.c: Update.
489 * gnulib/import/mbsrtowcs-impl.h: Update.
490 * gnulib/import/mbsrtowcs-state.c: Update.
491 * gnulib/import/mbsrtowcs.c: Update.
492 * gnulib/import/memchr.c: Update.
493 * gnulib/import/memmem.c: Update.
494 * gnulib/import/mempcpy.c: Update.
495 * gnulib/import/memrchr.c: Update.
496 * gnulib/import/mkdir.c: Update.
497 * gnulib/import/mkstemp.c: Update.
498 * gnulib/import/msvc-inval.c: Update.
499 * gnulib/import/msvc-inval.h: Update.
500 * gnulib/import/msvc-nothrow.c: Update.
501 * gnulib/import/msvc-nothrow.h: Update.
502 * gnulib/import/open.c: Update.
503 * gnulib/import/openat-die.c: Update.
504 * gnulib/import/openat-priv.h: Update.
505 * gnulib/import/openat-proc.c: Update.
506 * gnulib/import/openat.c: Update.
507 * gnulib/import/openat.h: Update.
508 * gnulib/import/opendir.c: Update.
509 * gnulib/import/pathmax.h: Update.
510 * gnulib/import/pipe-safer.c: Update.
511 * gnulib/import/rawmemchr.c: Update.
512 * gnulib/import/readdir.c: Update.
513 * gnulib/import/readlink.c: Update.
514 * gnulib/import/realloc.c: Update.
515 * gnulib/import/ref-add.sin: Update.
516 * gnulib/import/ref-del.sin: Update.
517 * gnulib/import/rename.c: Update.
518 * gnulib/import/rewinddir.c: Update.
519 * gnulib/import/rmdir.c: Update.
520 * gnulib/import/same-inode.h: Update.
521 * gnulib/import/save-cwd.c: Update.
522 * gnulib/import/save-cwd.h: Update.
523 * gnulib/import/scratch_buffer.h: Update.
524 * gnulib/import/secure_getenv.c: Update.
525 * gnulib/import/setenv.c: Update.
526 * gnulib/import/signal.in.h: Update.
527 * gnulib/import/stat-time.c: Update.
528 * gnulib/import/stat-time.h: Update.
529 * gnulib/import/stat-w32.c: Update.
530 * gnulib/import/stat-w32.h: Update.
531 * gnulib/import/stat.c: Update.
532 * gnulib/import/stdbool.in.h: Update.
533 * gnulib/import/stddef.in.h: Update.
534 * gnulib/import/stdint.in.h: Update.
535 * gnulib/import/stdio.in.h: Update.
536 * gnulib/import/stdlib.in.h: Update.
537 * gnulib/import/str-two-way.h: Update.
538 * gnulib/import/strchrnul.c: Update.
539 * gnulib/import/strdup.c: Update.
540 * gnulib/import/streq.h: Update.
541 * gnulib/import/strerror-override.c: Update.
542 * gnulib/import/strerror-override.h: Update.
543 * gnulib/import/strerror.c: Update.
544 * gnulib/import/string.in.h: Update.
545 * gnulib/import/stripslash.c: Update.
546 * gnulib/import/strnlen1.c: Update.
547 * gnulib/import/strnlen1.h: Update.
548 * gnulib/import/strstr.c: Update.
549 * gnulib/import/strtok_r.c: Update.
550 * gnulib/import/sys_stat.in.h: Update.
551 * gnulib/import/sys_time.in.h: Update.
552 * gnulib/import/sys_types.in.h: Update.
553 * gnulib/import/tempname.c: Update.
554 * gnulib/import/tempname.h: Update.
555 * gnulib/import/time.in.h: Update.
556 * gnulib/import/unistd--.h: Update.
557 * gnulib/import/unistd-safer.h: Update.
558 * gnulib/import/unistd.in.h: Update.
559 * gnulib/import/unsetenv.c: Update.
560 * gnulib/import/verify.h: Update.
561 * gnulib/import/extra/snippet/warn-on-use.h: Update.
562 * gnulib/import/wchar.in.h: Update.
563 * gnulib/import/wctype.in.h: Update.
564 * gnulib/import/xalloc-oversized.h: Update.
565 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
566 "53e2c179f26a890fa6685af4b6c1397ee370433b".
568 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
570 * record-btrace.c (get_thread_current_frame): Remove
573 2018-09-10 Jerome Guitton <guitton@adacore.com>
575 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
576 with check_tag to 1 if and only if the type is tagged and the
577 component being searched cannot been found in the current
578 view. Otherwise, always call ada_to_fixed_type with
581 2018-09-10 Xavier Roirand <roirand@adacore.com>
583 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
585 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
586 * ada-varobj.c (ada_varobj_get_number_of_children,
587 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
589 2018-09-10 Xavier Roirand <roirand@adacore.com>
591 * ada-valprint.c (ada_value_print): Use type instead of
594 2018-09-10 Xavier Roirand <roirand@adacore.com>
596 * ada-lang.c (ada_value_subscript): Handle case when parameter is
597 an array of access to unconstrained array.
599 2018-09-10 Xavier Roirand <roirand@adacore.com>
601 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
602 (ada_check_typedef): Use it.
604 2018-09-10 Xavier Roirand <roirand@adacore.com>
606 * ada-varobj.c (ada_varobj_describe_struct_child)
607 (ada_varobj_describe_child): Handle union case like struct one.
609 2018-09-10 Tom Tromey <tom@tromey.com>
612 * python/python.c (_initialize_python): Make example in "python"
613 help work in Python 3.
615 2018-09-10 Eli Zaretskii <eliz@gnu.org>
617 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
618 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
619 $(EXEEXT) to the script, as it is not a program.
621 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
623 * python/py-prettyprint.c (pretty_print_one_value): Return
625 (print_string_repr): Adjust.
626 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
627 * python/python-internal.h (apply_varobj_pretty_printer): Return
629 * varobj.c (varobj_value_get_print_value): Adjust.
631 2018-09-08 Tom Tromey <tom@tromey.com>
634 * python/py-prettyprint.c (pretty_print_one_value): Check for
637 2018-09-08 Joel Brobecker <brobecker@adacore.com>
639 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
640 replace_operator_with_call.
642 2018-09-08 Joel Brobecker <brobecker@adacore.com>
644 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
646 2018-09-08 Joel Brobecker <brobecker@adacore.com>
648 * ada-typeprint.c (print_range): Print the bounds using TYPE
649 rather than its TYPE_TARGET_TYPE.
651 2018-09-08 Joel Brobecker <brobecker@adacore.com>
653 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
654 call to ada_to_fixed_value_create.
656 2018-09-08 Jerome Guitton <guitton@adacore.com>
658 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
660 2018-09-08 Joel Brobecker <brobecker@adacore.com>
662 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
665 2018-09-08 Joel Brobecker <brobecker@adacore.com>
667 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
668 Move update of loop variable "fi".
670 2018-09-08 Joel Brobecker <brobecker@adacore.com>
672 * ada-lang.c (value_assign_to_component): In the case of
673 big-endian targets, extract the bits of the given VAL
674 using an src_offset of zero if container is not a scalar.
676 2018-09-06 Simon Ser <contact@emersion.fr>
679 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
680 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
681 * fbsd-tdep.c (fbsd_make_note_desc): New.
682 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
683 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
684 * target.h (enum target_object) Add FreeBSD-specific
685 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
687 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
689 * compile/compile-c.h (generate_c_for_variable_locations):
690 Change reference to pointer.
691 * compile/compile-c-support.c (compile_program) <compute>:
693 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
694 (generate_c_for_for_one_variable): Likewise
695 (generate_c_for_variable_locations): Likewise
696 * compile/compile-c-types.c (compile_c_instance::convert_type):
698 * compile/compile-cplus-symbols.c (convert_one_symbol):
699 std::move the scope passed to enter_scope.
700 * compile/compile-cplus-types.c
701 (compile_cplus_instance::enter_scope): Make parameter
703 (compile_cplus_instance::new_scope): Change reference to
705 (compile_cplus_instance::convert_type): Likewise
706 (compile_cplus_convert_typedef): std::move the scope passed to
708 (compile_cplus_convert_struct_or_union): Likewise.
709 (compile_cplus_convert_enum): Likewise.
710 (compile_cplus_convert_namespace): Likewise.
711 * compile/compile-cplus.h (compile_cplus_instance)
712 <enter_scope>: Make parameter rvalue-reference.
713 * compile/compile-internal.h (compile_instance)
714 <get_cached_type>: Likewise
715 * compile/compile-loc2c.c (push): Likewise
719 (print_label): Likewise
720 (pushf_register_address): Likewise
721 (pushf_register): Likewise
722 (do_compile_dwarf_expr_to_c): Likewise
723 (compile_dwarf_expr_to_c): Likewise
724 (compile_dwarf_bounds_to_c): Likewise
725 * compile/compile.c (compile_instance::get_cached_type):
727 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
728 (compile_dwarf_bounds_to_c): Likewise
729 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
730 (dwarf2_compile_property_to_c): Likewise
731 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
732 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
735 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
737 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
738 * tui/tui-data.c (init_content_element): Don't initialize it.
740 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
742 * tui/tui-data.h (struct tui_win_info)
743 <detail::opaque>: Remove.
744 * tui/tui-data.c (init_win_info): Remove assignment.
746 2018-09-05 Tom Tromey <tom@tromey.com>
748 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
750 * target-float.c (host_float_ops<T>::to_string)
751 (host_float_ops<T>::from_string): Use
752 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
753 * configure: Rebuild.
755 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
757 * printcmd.c (printf_c_string): Use
758 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
759 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
761 2018-09-05 Tom Tromey <tom@tromey.com>
763 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
765 2018-09-05 Tom de Vries <tdevries@suse.de>
767 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
768 with resolve_abstract_p == true.
769 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
770 defaulting to false. Propagate resolve_abstract_p to
771 dwarf2_fetch_die_loc_sect_off.
772 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
773 parameter, defaulting to false.
774 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
775 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
777 * dwarf2read.h (struct die_info): Forward-declare.
778 (die_info_ptr): New typedef.
779 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
781 2018-09-05 Joel Brobecker <brobecker@adacore.com>
785 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
786 Pedro Alves <palves@redhat.com>
788 * gnulib/Makefile.in (aclocal_m4_deps): Move to
789 "aclocal-m4-deps.mk". Include file here.
790 $(srcdir)/aclocal.m4: Add "configure.ac".
791 * gnulib/aclocal-m4-deps.mk: New file.
792 * gnulib/update-gnulib.sh: Automatically update
793 "aclocal-m4-deps.mk".
795 2018-09-04 Tom Tromey <tom@tromey.com>
797 * configure: Rebuild.
798 * configure.ac: Remove multi-ice code.
800 2018-09-04 Tom Tromey <tom@tromey.com>
802 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
805 2018-09-04 Tom Tromey <tom@tromey.com>
807 * Makefile.in (printcmd.o, target-float.o): Remove.
808 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
810 2018-09-04 Tom Tromey <tom@tromey.com>
812 * gnulib/Makefile.in: Remove obsolete comment.
813 * Makefile.in: Remove obsolete comment.
815 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
817 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
820 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
822 * riscv-tdep.c: Add 'prologue-value.h' include.
823 (struct riscv_unwind_cache): New struct.
824 (riscv_debug_unwinder): New global.
825 (riscv_scan_prologue): Update arguments, capture register details
827 (riscv_skip_prologue): Reformat arguments line, move end of
828 prologue calculation into riscv_scan_prologue.
829 (riscv_frame_cache): Update return type, create
830 riscv_unwind_cache, scan the prologue, and fill in remaining cache
832 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
833 (riscv_frame_prev_register): Use the trad_frame within the
835 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
838 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
840 * trad-frame.h (trad_frame_set_realreg): Declare.
841 (trad_frame_set_addr): Declare.
842 * trad-frame.c (trad_frame_set_realreg): Define new function.
843 (trad_frame_set_addr): Define new function.
844 (trad_frame_set_reg_realreg): Use new function.
845 (trad_frame_set_reg_addr): Use new function.
847 2018-09-01 Keith Seitz <keiths@redhat.com>
849 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
850 pulongest instead of "%lld".
851 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
854 2018-08-31 Tom Tromey <tom@tromey.com>
856 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
859 2018-08-31 Pedro Alves <palves@redhat.com>
861 * gdbarch.h: Regenerate.
863 2018-08-31 Pedro Alves <palves@redhat.com>
865 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
866 * target.h (Hardware watchpoint interfaces): Describe
867 continuable/steppable/non-steppable watchpoints.
868 * gdbarch.h, gdbarch.c: Regenerate.
870 2018-08-31 Pedro Alves <palves@redhat.com>
872 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
875 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
876 * target.h (target_ops::have_continuable_watchpoint): Delete.
877 (target_have_continuable_watchpoint): Delete.
878 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
879 * target-delegates.c: Regenerate.
881 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
883 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
884 the files present in "gnulib/import/m4/".
886 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
888 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
889 c.sw, c.swsp, and c.sdsp.
891 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
893 * riscv-tdep.c (struct riscv_inferior_data): Delete.
894 (riscv_read_misa_reg): Don't cache value read into inferior data.
895 (riscv_new_inferior_data): Delete.
896 (riscv_inferior_data_cleanup): Delete.
897 (riscv_inferior_data): Delete.
898 (riscv_invalidate_inferior_data): Delete.
899 (_initialize_riscv_tdep): Remove initialisation of inferior data.
901 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
903 * compile/compile-cplus-types.c
904 (compile_cplus_instance::leave_scope): Take the address of scope
906 (compile_cplus_instance::convert_qualified_base): Compare quals
909 2018-08-30 Keith Seitz <keiths@redhat.com>
911 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
912 Use "%s" and host_address_to_string instead of "%p" in printf.
914 2018-08-29 Keith Seitz <keiths@redhat.com>
916 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
917 and compile-cplus-types.c.
918 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
919 * c-lang.c (cplus_language_defn): Set C++ compile functions.
920 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
922 * compile/compile-c-support.c: Include compile-cplus.h.
923 (load_libcompile): Templatize.
924 (get_compile_context): "New" function.
925 (c_get_compile_context): Use get_compile_context.
926 (cplus_get_compile_context): New function.
927 (cplus_push_user_expression, cplus_pop_user_expression)
928 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
929 (cplus_compute_program): Define new structs/functions.
930 * compile/compile-cplus-symmbols.c: New file.
931 * compile/compile-cplus-types.c: New file.
932 * compile/compile-cplus.h: New file.
933 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
935 * compile/compile-object-load.c (get_out_value_type): Use
936 strncmp_iw when comparing symbol names.
937 (compile_object_load): Add mst_bss and mst_data.
938 * compile/compile.c (_initialize_compile): Remove
939 -Wno-implicit-function-declaration from `compile_args'.
940 * compile/gcc-cp-plugin.h: New file.
941 * NEWS: Mention C++ compile support and new debug options.
943 2018-08-29 Keith Seitz <keiths@redhat.com>
945 * linespec.c (collect_info::add_symbol): Make virtual.
946 (struct symbol_searcher_collect_info): New struct.
947 (symbol_searcher::find_all_symbols): New method.
948 * symtab.h (class symbol_searcher): New class.
950 2018-08-29 Keith Seitz <keiths@redhat.com>
952 * linespec.c (struct linespec) <function_symbols, label_symbols>:
953 Change to vector of block_symbol. Update all users.
954 (struct collect_info) <symbols>: Likewise.
955 (collect_info::add_symbol): Take block_symbol as argument.
957 (decode_compound_collector) <m_symbols>: Change type to vector
958 of block_symbol. Update all users.
959 (decode_compound_collector::operator ()): Change parameter type
961 (find_method, find_function_symbols, find_linespec_symbols)
962 (find_label_symbols_in_block, find_label_symbols): Change symbol
963 vectors to block_symbol vectors.
964 * symtab.h (symbol_found_callback_ftype): Change parameter type to
967 2018-08-29 Keith Seitz <keiths@redhat.com>
969 * linespec.c (symbolp): Remove typedef and VEC definitions.
970 (bound_minimal_symbol_d): Likewise.
972 2018-08-29 Keith Seitz <keiths@redhat.com>
974 * linespec.c (decode_compound_collector::decode_compound_collector):
975 Remove initialization for `m_symtabs'.
976 (decode_compound_collector::release_symbols): Change return type
977 to std::vector. Update all callers.
978 (class decode_compound_collector) <m_symbols>: Change type to
980 (lookup_prefix_sym): Change return type to std::vector. Update all
982 (compare_symbols): Remove.
983 (std_compare_symbols): Rename to `compare_symbols'.
984 (find_method): Change `sym_classes' parameter to std::vector.
985 Update all callers. Use std::sort to sort sym_classes.
986 (find_linespec_symbols): Remove cleanup.
988 2018-08-29 Keith Seitz <keiths@redhat.com>
990 * linespec.c (struct linespec) <minimal_symbols>: Change type to
991 std::vector. Update all users.
992 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
993 (struct collect_info) <minimal_symbols>: Likewise.
994 (compare_msymbols): Return bool. Change parameters to const
995 bound_minimal_symbol references.
996 (find_method, find_function_symbols, find_linespec_symbols): Change
997 `minsyms' parameter to std::vector. Update all callers.
999 2018-08-29 Keith Seitz <keiths@redhat.com>
1001 * linespec.c (struct linespec) <label_symbols>: Change type to
1002 std::vector. Update all users.
1003 (find_label_symbols_in_block): Change `result' parameter to
1004 std::vector. Update all callers.
1005 (find_label_symbols): Return std::vector. Update all callers.
1007 2018-08-29 Keith Seitz <keiths@redhat.com>
1009 * linespec.c (struct linespec) <function_symbols>: Change type to
1010 std::vector. Update all users.
1011 (struct collect_info) <function_symbols>: Likewise.
1012 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
1013 (std_compare_symbols): New function.
1014 (find_method, find_function_symbols, find_linespec_symbols)
1015 (find_label_symbols_in_block): Change `symbols' parameter to
1016 std::vector. Update all callers.
1017 (find_label_symbols): Likewise for `function_symbols' and
1020 2018-08-29 Keith Seitz <keiths@redhat.com>
1022 * linespec.c (symtab_vector_up): Define.
1023 (struct linespec) <file_symtabs>: Change type to std::vector *.
1025 (struct collect_info) <file_symtabs>: Likewise.
1026 (collect_symtabs_from_filename): Return symtab_vector_up.
1028 (decode_objc): Remove cleanup.
1029 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
1030 (symtab_collector::release_symtabs): Return symtab_vector_up.
1032 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
1034 (collect_symtabs_from_filename, symtabs_from_filename): Return
1035 symtab_vector_up. Update all callers.
1037 2018-08-29 Tom Tromey <tom@tromey.com>
1039 * csky-tdep.c (csky_analyze_prologue): Use
1040 core_addr_to_string_nz.
1042 2018-08-29 Tom Tromey <tom@tromey.com>
1044 * windows-nat.c (struct xlate_exception) <them>: Change type to
1046 (xlate): Fix formatting. Remove last entry.
1047 (struct xlate_exception, xlate): Comment out.
1048 (windows_nat_target::resume): Use ranged for.
1050 2018-08-29 Jim Wilson <jimw@sifive.com>
1052 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
1053 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
1055 (riscv_linux_nat_target::store_registers): Likewise.
1057 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
1061 * gnulib/aclocal.m4: Regenerate.
1062 * gnulib/config.in: Regenerate.
1063 * gnulib/configure: Regenerate.
1064 * gnulib/import/Makefile.am: Update.
1065 * gnulib/import/Makefile.in: Update.
1066 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
1067 * gnulib/import/_Noreturn.h: ... this.
1068 * gnulib/import/alloca.in.h: Update.
1069 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
1070 * gnulib/import/arg-nonnull.h: ... this.
1071 * gnulib/import/assure.h: Update.
1072 * gnulib/import/at-func.c: Update.
1073 * gnulib/import/basename-lgpl.c: Update.
1074 * gnulib/import/extra/snippet/c++defs.h: Rename to...
1075 * gnulib/import/c++defs.h: ... this.
1076 * gnulib/import/canonicalize-lgpl.c: Update.
1077 * gnulib/import/cdefs.h: Update.
1078 * gnulib/import/chdir-long.c: Update.
1079 * gnulib/import/chdir-long.h: Update.
1080 * gnulib/import/cloexec.c: Update.
1081 * gnulib/import/cloexec.h: Update.
1082 * gnulib/import/close.c: Update.
1083 * gnulib/import/closedir.c: Update.
1084 * gnulib/import/config.charset: Update.
1085 * gnulib/import/dirent-private.h: Update.
1086 * gnulib/import/dirent.in.h: Update.
1087 * gnulib/import/dirfd.c: Update.
1088 * gnulib/import/dirname-lgpl.c: Update.
1089 * gnulib/import/dirname.h: Update.
1090 * gnulib/import/dosname.h: Update.
1091 * gnulib/import/dup-safer-flag.c: Update.
1092 * gnulib/import/dup-safer.c: Update.
1093 * gnulib/import/dup.c: Update.
1094 * gnulib/import/dup2.c: Update.
1095 * gnulib/import/errno.in.h: Update.
1096 * gnulib/import/error.c: Update.
1097 * gnulib/import/error.h: Update.
1098 * gnulib/import/exitfail.c: Update.
1099 * gnulib/import/exitfail.h: Update.
1100 * gnulib/import/extra/update-copyright: Update.
1101 * gnulib/import/fchdir.c: Update.
1102 * gnulib/import/fcntl.c: Update.
1103 * gnulib/import/fcntl.in.h: Update.
1104 * gnulib/import/fd-hook.c: Update.
1105 * gnulib/import/fd-hook.h: Update.
1106 * gnulib/import/fd-safer-flag.c: Update.
1107 * gnulib/import/fd-safer.c: Update.
1108 * gnulib/import/fdopendir.c: Update.
1109 * gnulib/import/filename.h: Update.
1110 * gnulib/import/filenamecat-lgpl.c: Update.
1111 * gnulib/import/filenamecat.h: Update.
1112 * gnulib/import/flexmember.h: Update.
1113 * gnulib/import/float+.h: Update.
1114 * gnulib/import/float.c: Update.
1115 * gnulib/import/float.in.h: Update.
1116 * gnulib/import/fnmatch.c: Update.
1117 * gnulib/import/fnmatch.in.h: Update.
1118 * gnulib/import/fnmatch_loop.c: Update.
1119 * gnulib/import/fpucw.h: Update.
1120 * gnulib/import/frexp.c: Update.
1121 * gnulib/import/frexpl.c: Update.
1122 * gnulib/import/fstat.c: Update.
1123 * gnulib/import/fstatat.c: Update.
1124 * gnulib/import/getcwd-lgpl.c: Update.
1125 * gnulib/import/getcwd.c: Update.
1126 * gnulib/import/getdtablesize.c: Update.
1127 * gnulib/import/getlogin_r.c: Update.
1128 * gnulib/import/getprogname.c: Update.
1129 * gnulib/import/getprogname.h: Update.
1130 * gnulib/import/gettext.h: Update.
1131 * gnulib/import/gettimeofday.c: Update.
1132 * gnulib/import/glob-libc.h: Update.
1133 * gnulib/import/glob.c: Update.
1134 * gnulib/import/glob.in.h: Update.
1135 * gnulib/import/glob_internal.h: Update.
1136 * gnulib/import/glob_pattern_p.c: Update.
1137 * gnulib/import/globfree.c: Update.
1138 * gnulib/import/hard-locale.c: Update.
1139 * gnulib/import/hard-locale.h: Update.
1140 * gnulib/import/intprops.h: Update.
1141 * gnulib/import/inttypes.in.h: Update.
1142 * gnulib/import/isnan.c: Update.
1143 * gnulib/import/isnand-nolibm.h: Update.
1144 * gnulib/import/isnand.c: Update.
1145 * gnulib/import/isnanl-nolibm.h: Update.
1146 * gnulib/import/isnanl.c: Update.
1147 * gnulib/import/itold.c: Update.
1148 * gnulib/import/libc-config.h: Update.
1149 * gnulib/import/limits.in.h: Update.
1150 * gnulib/import/localcharset.c: Update.
1151 * gnulib/import/localcharset.h: Update.
1152 * gnulib/import/localtime-buffer.c: Update.
1153 * gnulib/import/localtime-buffer.h: Update.
1154 * gnulib/import/lstat.c: Update.
1155 * gnulib/import/m4/00gnulib.m4: Update.
1156 * gnulib/import/m4/__inline.m4: Update.
1157 * gnulib/import/m4/absolute-header.m4: Update.
1158 * gnulib/import/m4/alloca.m4: Update.
1159 * gnulib/import/m4/builtin-expect.m4: Update.
1160 * gnulib/import/m4/canonicalize.m4: Update.
1161 * gnulib/import/m4/chdir-long.m4: Update.
1162 * gnulib/import/m4/close.m4: Update.
1163 * gnulib/import/m4/closedir.m4: Update.
1164 * gnulib/import/m4/configmake.m4: Update.
1165 * gnulib/import/m4/d-ino.m4: Update.
1166 * gnulib/import/m4/d-type.m4: Update.
1167 * gnulib/import/m4/dirent_h.m4: Update.
1168 * gnulib/import/m4/dirfd.m4: Update.
1169 * gnulib/import/m4/dirname.m4: Update.
1170 * gnulib/import/m4/double-slash-root.m4: Update.
1171 * gnulib/import/m4/dup.m4: Update.
1172 * gnulib/import/m4/dup2.m4: Update.
1173 * gnulib/import/m4/eealloc.m4: Update.
1174 * gnulib/import/m4/environ.m4: Update.
1175 * gnulib/import/m4/errno_h.m4: Update.
1176 * gnulib/import/m4/error.m4: Update.
1177 * gnulib/import/m4/exponentd.m4: Update.
1178 * gnulib/import/m4/exponentl.m4: Update.
1179 * gnulib/import/m4/extensions.m4: Update.
1180 * gnulib/import/m4/extern-inline.m4: Update.
1181 * gnulib/import/m4/fchdir.m4: Update.
1182 * gnulib/import/m4/fcntl-o.m4: Update.
1183 * gnulib/import/m4/fcntl.m4: Update.
1184 * gnulib/import/m4/fcntl_h.m4: Update.
1185 * gnulib/import/m4/fdopendir.m4: Update.
1186 * gnulib/import/m4/filenamecat.m4: Update.
1187 * gnulib/import/m4/flexmember.m4: Update.
1188 * gnulib/import/m4/float_h.m4: Update.
1189 * gnulib/import/m4/fnmatch.m4: Update.
1190 * gnulib/import/m4/fnmatch_h.m4: Update.
1191 * gnulib/import/m4/fpieee.m4: Update.
1192 * gnulib/import/m4/frexp.m4: Update.
1193 * gnulib/import/m4/frexpl.m4: Update.
1194 * gnulib/import/m4/fstat.m4: Update.
1195 * gnulib/import/m4/fstatat.m4: Update.
1196 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
1197 * gnulib/import/m4/getcwd-path-max.m4: Update.
1198 * gnulib/import/m4/getcwd.m4: Update.
1199 * gnulib/import/m4/getdtablesize.m4: Update.
1200 * gnulib/import/m4/getlogin.m4: Update.
1201 * gnulib/import/m4/getlogin_r.m4: Update.
1202 * gnulib/import/m4/getpagesize.m4: Update.
1203 * gnulib/import/m4/getprogname.m4: Update.
1204 * gnulib/import/m4/gettimeofday.m4: Update.
1205 * gnulib/import/m4/glibc21.m4: Update.
1206 * gnulib/import/m4/glob.m4: Update.
1207 * gnulib/import/m4/glob_h.m4: Update.
1208 * gnulib/import/m4/gnulib-cache.m4: Update.
1209 * gnulib/import/m4/gnulib-common.m4: Update.
1210 * gnulib/import/m4/gnulib-comp.m4: Update.
1211 * gnulib/import/m4/gnulib-tool.m4: Update.
1212 * gnulib/import/m4/hard-locale.m4: Update.
1213 * gnulib/import/m4/include_next.m4: Update.
1214 * gnulib/import/m4/inttypes-pri.m4: Update.
1215 * gnulib/import/m4/inttypes.m4: Update.
1216 * gnulib/import/m4/isnand.m4: Update.
1217 * gnulib/import/m4/isnanl.m4: Update.
1218 * gnulib/import/m4/largefile.m4: Update.
1219 * gnulib/import/m4/limits-h.m4: Update.
1220 * gnulib/import/m4/localcharset.m4: Update.
1221 * gnulib/import/m4/locale-fr.m4: Update.
1222 * gnulib/import/m4/locale-ja.m4: Update.
1223 * gnulib/import/m4/locale-zh.m4: Update.
1224 * gnulib/import/m4/localtime-buffer.m4: Update.
1225 * gnulib/import/m4/longlong.m4: Update.
1226 * gnulib/import/m4/lstat.m4: Update.
1227 * gnulib/import/m4/malloc.m4: Update.
1228 * gnulib/import/m4/malloca.m4: Update.
1229 * gnulib/import/m4/math_h.m4: Update.
1230 * gnulib/import/m4/mbrtowc.m4: Update.
1231 * gnulib/import/m4/mbsinit.m4: Update.
1232 * gnulib/import/m4/mbsrtowcs.m4: Update.
1233 * gnulib/import/m4/mbstate_t.m4: Update.
1234 * gnulib/import/m4/memchr.m4: Update.
1235 * gnulib/import/m4/memmem.m4: Update.
1236 * gnulib/import/m4/mempcpy.m4: Update.
1237 * gnulib/import/m4/memrchr.m4: Update.
1238 * gnulib/import/m4/mkdir.m4: Update.
1239 * gnulib/import/m4/mkstemp.m4: Update.
1240 * gnulib/import/m4/mmap-anon.m4: Update.
1241 * gnulib/import/m4/mode_t.m4: Update.
1242 * gnulib/import/m4/msvc-inval.m4: Update.
1243 * gnulib/import/m4/msvc-nothrow.m4: Update.
1244 * gnulib/import/m4/multiarch.m4: Update.
1245 * gnulib/import/m4/nocrash.m4: Update.
1246 * gnulib/import/m4/off_t.m4: Update.
1247 * gnulib/import/m4/onceonly.m4: Update.
1248 * gnulib/import/m4/open-cloexec.m4: Update.
1249 * gnulib/import/m4/open.m4: Update.
1250 * gnulib/import/m4/openat.m4: Update.
1251 * gnulib/import/m4/opendir.m4: Update.
1252 * gnulib/import/m4/pathmax.m4: Update.
1253 * gnulib/import/m4/rawmemchr.m4: Update.
1254 * gnulib/import/m4/readdir.m4: Update.
1255 * gnulib/import/m4/readlink.m4: Update.
1256 * gnulib/import/m4/realloc.m4: Update.
1257 * gnulib/import/m4/rename.m4: Update.
1258 * gnulib/import/m4/rewinddir.m4: Update.
1259 * gnulib/import/m4/rmdir.m4: Update.
1260 * gnulib/import/m4/save-cwd.m4: Update.
1261 * gnulib/import/m4/secure_getenv.m4: Update.
1262 * gnulib/import/m4/setenv.m4: Update.
1263 * gnulib/import/m4/signal_h.m4: Update.
1264 * gnulib/import/m4/ssize_t.m4: Update.
1265 * gnulib/import/m4/stat-time.m4: Update.
1266 * gnulib/import/m4/stat.m4: Update.
1267 * gnulib/import/m4/std-gnu11.m4: Update.
1268 * gnulib/import/m4/stdbool.m4: Update.
1269 * gnulib/import/m4/stddef_h.m4: Update.
1270 * gnulib/import/m4/stdint.m4: Update.
1271 * gnulib/import/m4/stdio_h.m4: Update.
1272 * gnulib/import/m4/stdlib_h.m4: Update.
1273 * gnulib/import/m4/strchrnul.m4: Update.
1274 * gnulib/import/m4/strdup.m4: Update.
1275 * gnulib/import/m4/strerror.m4: Update.
1276 * gnulib/import/m4/string_h.m4: Update.
1277 * gnulib/import/m4/strstr.m4: Update.
1278 * gnulib/import/m4/strtok_r.m4: Update.
1279 * gnulib/import/m4/sys_socket_h.m4: Update.
1280 * gnulib/import/m4/sys_stat_h.m4: Update.
1281 * gnulib/import/m4/sys_time_h.m4: Update.
1282 * gnulib/import/m4/sys_types_h.m4: Update.
1283 * gnulib/import/m4/tempname.m4: Update.
1284 * gnulib/import/m4/time_h.m4: Update.
1285 * gnulib/import/m4/unistd-safer.m4: Update.
1286 * gnulib/import/m4/unistd_h.m4: Update.
1287 * gnulib/import/m4/warn-on-use.m4: Update.
1288 * gnulib/import/m4/wchar_h.m4: Update.
1289 * gnulib/import/m4/wchar_t.m4: Update.
1290 * gnulib/import/m4/wctype_h.m4: Update.
1291 * gnulib/import/m4/wint_t.m4: Update.
1292 * gnulib/import/malloc.c: Update.
1293 * gnulib/import/malloc/scratch_buffer.h: Update.
1294 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
1295 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
1296 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
1297 * gnulib/import/malloca.c: Update.
1298 * gnulib/import/malloca.h: Update.
1299 * gnulib/import/malloca.valgrind: Update.
1300 * gnulib/import/math.in.h: Update.
1301 * gnulib/import/mbrtowc.c: Update.
1302 * gnulib/import/mbsinit.c: Update.
1303 * gnulib/import/mbsrtowcs-impl.h: Update.
1304 * gnulib/import/mbsrtowcs-state.c: Update.
1305 * gnulib/import/mbsrtowcs.c: Update.
1306 * gnulib/import/memchr.c: Update.
1307 * gnulib/import/memmem.c: Update.
1308 * gnulib/import/mempcpy.c: Update.
1309 * gnulib/import/memrchr.c: Update.
1310 * gnulib/import/mkdir.c: Update.
1311 * gnulib/import/mkstemp.c: Update.
1312 * gnulib/import/msvc-inval.c: Update.
1313 * gnulib/import/msvc-inval.h: Update.
1314 * gnulib/import/msvc-nothrow.c: Update.
1315 * gnulib/import/msvc-nothrow.h: Update.
1316 * gnulib/import/open.c: Update.
1317 * gnulib/import/openat-die.c: Update.
1318 * gnulib/import/openat-priv.h: Update.
1319 * gnulib/import/openat-proc.c: Update.
1320 * gnulib/import/openat.c: Update.
1321 * gnulib/import/openat.h: Update.
1322 * gnulib/import/opendir.c: Update.
1323 * gnulib/import/pathmax.h: Update.
1324 * gnulib/import/pipe-safer.c: Update.
1325 * gnulib/import/rawmemchr.c: Update.
1326 * gnulib/import/readdir.c: Update.
1327 * gnulib/import/readlink.c: Update.
1328 * gnulib/import/realloc.c: Update.
1329 * gnulib/import/ref-add.sin: Update.
1330 * gnulib/import/ref-del.sin: Update.
1331 * gnulib/import/rename.c: Update.
1332 * gnulib/import/rewinddir.c: Update.
1333 * gnulib/import/rmdir.c: Update.
1334 * gnulib/import/same-inode.h: Update.
1335 * gnulib/import/save-cwd.c: Update.
1336 * gnulib/import/save-cwd.h: Update.
1337 * gnulib/import/scratch_buffer.h: Update.
1338 * gnulib/import/secure_getenv.c: Update.
1339 * gnulib/import/setenv.c: Update.
1340 * gnulib/import/signal.in.h: Update.
1341 * gnulib/import/stat-time.c: Update.
1342 * gnulib/import/stat-time.h: Update.
1343 * gnulib/import/stat-w32.c: Update.
1344 * gnulib/import/stat-w32.h: Update.
1345 * gnulib/import/stat.c: Update.
1346 * gnulib/import/stdbool.in.h: Update.
1347 * gnulib/import/stddef.in.h: Update.
1348 * gnulib/import/stdint.in.h: Update.
1349 * gnulib/import/stdio.in.h: Update.
1350 * gnulib/import/stdlib.in.h: Update.
1351 * gnulib/import/str-two-way.h: Update.
1352 * gnulib/import/strchrnul.c: Update.
1353 * gnulib/import/strdup.c: Update.
1354 * gnulib/import/streq.h: Update.
1355 * gnulib/import/strerror-override.c: Update.
1356 * gnulib/import/strerror-override.h: Update.
1357 * gnulib/import/strerror.c: Update.
1358 * gnulib/import/string.in.h: Update.
1359 * gnulib/import/stripslash.c: Update.
1360 * gnulib/import/strnlen1.c: Update.
1361 * gnulib/import/strnlen1.h: Update.
1362 * gnulib/import/strstr.c: Update.
1363 * gnulib/import/strtok_r.c: Update.
1364 * gnulib/import/sys_stat.in.h: Update.
1365 * gnulib/import/sys_time.in.h: Update.
1366 * gnulib/import/sys_types.in.h: Update.
1367 * gnulib/import/tempname.c: Update.
1368 * gnulib/import/tempname.h: Update.
1369 * gnulib/import/time.in.h: Update.
1370 * gnulib/import/unistd--.h: Update.
1371 * gnulib/import/unistd-safer.h: Update.
1372 * gnulib/import/unistd.in.h: Update.
1373 * gnulib/import/unsetenv.c: Update.
1374 * gnulib/import/verify.h: Update.
1375 * gnulib/import/extra/snippet/warn-on-use.h: Update.
1376 * gnulib/import/wchar.in.h: Update.
1377 * gnulib/import/wctype.in.h: Update.
1378 * gnulib/import/xalloc-oversized.h: Update.
1379 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
1380 "53e2c179f26a890fa6685af4b6c1397ee370433b".
1382 2018-08-16 Gary Benson <gbenson@redhat.com>
1385 * gdb/main.c (captured_main_1): Exit with nonzero status
1386 in batch mode if the last command to be executed failed.
1387 * NEWS: Mention the above.
1389 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
1391 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
1392 end of warning message.
1394 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1397 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
1398 (aarch64_extract_return_value): Use
1399 aapcs_is_vfp_call_or_return_candidate.
1400 (aarch64_return_in_memory): Likewise.
1401 (aarch64_store_return_value): Likewise.
1403 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1406 (aapcs_is_vfp_call_or_return_candidate): Make static
1407 (pass_in_v_or_stack): Remove function.
1408 (pass_in_v_vfp_candidate): New function.
1409 (aarch64_push_dummy_call): Check for float register candidates.
1411 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1413 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
1414 (aapcs_is_vfp_call_or_return_candidate_1): New function.
1415 (aapcs_is_vfp_call_or_return_candidate): Likewise.
1417 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
1420 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
1421 (struct ipa_sym_addresses): Rename to...
1422 (struct ipa_sym_addresses_common): ... this.
1423 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
1425 2018-08-28 Tom Tromey <tom@tromey.com>
1427 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1428 (token_fifo): Now a std::vector.
1429 (yylex, c_parse): Update.
1430 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1431 (token_fifo): Now a std::vector.
1432 (yylex, d_parse): Update.
1433 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1434 (token_fifo): Now a std::vector.
1435 (yylex, go_parse): Update.
1437 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
1439 * parser-defs.h (struct type_stack) <elements>: Change type to
1440 std::vector<union type_stack_elt>.
1441 <depth, size>: Remove.
1442 * parse.c (parse_exp_in_context_1): Adjust.
1443 (type_stack_reserve): Remove.
1444 (check_type_stack_depth): Remove.
1445 (insert_into_type_stack): Adjust to std::vector.
1446 (insert_type): Likewise.
1447 (push_type): Likewise.
1448 (push_type_int): Likewise.
1449 (insert_type_address_space): Likewise.
1450 (pop_type): Likewise.
1451 (pop_type_int): Likewise.
1452 (pop_typelist): Likewise.
1453 (pop_type_stack): Likewise.
1454 (append_type_stack): Likewise.
1455 (push_type_stack): Likewise.
1456 (get_type_stack): Likewise.
1457 (type_stack_cleanup): Likewise.
1458 (push_typelist): Likewise.
1459 (follow_types): Likewise.
1460 (_initialize_parse): Likewise.
1462 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
1464 * NEWS: Mention csky target.
1466 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
1467 Hafiz Abid Qadeer <abidh@codesourcery.com>
1468 Don Breazeal <donb@codesourcery.com>
1470 * csky-linux-tdep.c: New file.
1471 * csky-tdep.c: Likewise.
1472 * csky-tdep.h: Likewise.
1473 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
1475 (HFILES_NO_SRCDIR): Add csky-tdep.h.
1476 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
1477 * configure.tgt: Add csky support.
1479 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
1481 * python/py-framefilter.c (py_print_frame): Print frame architecture
1482 when printing on an MI output.
1484 2018-08-27 Tom Tromey <tom@tromey.com>
1487 * configure: Rebuild.
1488 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
1490 2018-08-27 Tom Tromey <tom@tromey.com>
1492 * aarch64-linux-tdep.c
1493 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
1496 2018-08-27 Tom Tromey <tom@tromey.com>
1498 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
1500 (ppc64_standard_linkage1, ppc64_standard_linkage2)
1501 (ppc64_standard_linkage3, ppc64_standard_linkage4)
1502 (ppc64_standard_linkage5, ppc64_standard_linkage6)
1503 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
1506 2018-08-27 Tom Tromey <tom@tromey.com>
1508 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
1509 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
1511 2018-08-27 Tom Tromey <tom@tromey.com>
1513 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
1514 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
1516 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
1518 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
1520 * sparc-linux-tdep.c (sparc32_linux_sigframe)
1521 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
1522 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
1524 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
1525 (ppc64_linux_sigaction_tramp_frame)
1526 (ppc32_linux_sighandler_tramp_frame)
1527 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1528 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
1529 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
1530 * mn10300-linux-tdep.c (am33_linux_sigframe)
1531 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
1532 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
1533 * mips-linux-tdep.c (mips_linux_o32_sigframe)
1534 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
1535 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
1536 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
1537 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
1538 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
1539 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
1540 * microblaze-linux-tdep.c
1541 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1542 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
1543 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
1544 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
1545 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
1546 * common/common-types.h (ULONGEST_MAX): New define.
1547 (CORE_ADDR_MAX): Fix formatting.
1548 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
1549 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
1550 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
1551 (arm_linux_rt_sigreturn_tramp_frame)
1552 (arm_eabi_linux_sigreturn_tramp_frame)
1553 (arm_eabi_linux_rt_sigreturn_tramp_frame)
1554 (thumb2_eabi_linux_sigreturn_tramp_frame)
1555 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
1556 (arm_linux_restart_syscall_tramp_frame)
1557 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
1558 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
1559 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
1561 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
1563 2018-08-27 Tom Tromey <tom@tromey.com>
1565 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
1567 * mips-tdep.c (mips_deal_with_atomic_sequence)
1568 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
1569 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
1570 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
1571 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
1573 * aarch64-tdep.c (aarch64_software_single_step): Use
1576 2018-08-27 Tom Tromey <tom@tromey.com>
1578 * linespec.c (complete_linespec_component): Add cast to "char".
1579 * completer.c (completion_tracker::build_completion_result): Add
1582 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1584 * solist.h (struct solist, struct target_so_ops): Fix
1587 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1589 * ada-tasks.c (ada_task_info_s): Remove typedef.
1590 (DEF_VEC_O(ada_task_info_s)): Remove.
1591 (struct ada_tasks_inferior_data): Initialize fields.
1592 <task_list>: Make an std::vector.
1593 (get_ada_tasks_inferior_data): Allocate with new.
1594 (ada_get_task_number): Adjust.
1595 (get_task_number_from_id): Likewise.
1596 (valid_task_id): Likewise.
1597 (ada_get_task_info_from_ptid): Likewise.
1598 (iterate_over_live_ada_tasks): Likewise.
1599 (add_ada_task): Likewise.
1600 (read_known_tasks): Likewise.
1601 (ada_build_task_list): Likewise.
1602 (print_ada_task_info): Likewise.
1603 (info_task): Likewise.
1604 (task_command_1): Likewise.
1606 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1608 * ada-lang.c (add_angle_brackets): Return std::string.
1610 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
1612 * python/py-threadevent.c (py_get_event_thread): Initialize
1615 2018-08-24 Pedro Alves <palves@redhat.com>
1617 * python/py-bpevent.c (create_breakpoint_event_object): Use
1618 copy-initialization.
1619 * python/py-continueevent.c (emit_continue_event): Use
1620 copy-initialization.
1621 * python/py-exitedevent.c (create_exited_event_object): Return a
1623 (emit_exited_event): Use copy-initialization.
1624 * python/py-inferior.c (python_new_inferior)
1625 (python_inferior_deleted, add_thread_object): Use
1626 copy-initialization.
1627 * python/py-infevents.c (create_inferior_call_event_object)
1628 (create_register_changed_event_object)
1629 (create_memory_changed_event_object): Return a gdbpy_ref<>.
1630 (emit_inferior_call_event, emit_memory_changed_event)
1631 (emit_register_changed_event): Use copy-initialization.
1632 * python/py-newobjfileevent.c (create_new_objfile_event_object):
1633 Return a gdbpy_ref<>.
1634 (emit_new_objfile_event): Use copy-initialization.
1635 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
1636 (emit_clear_objfiles_event): Use copy-initialization.
1637 * python/py-signalevent.c (create_signal_event_object): Use
1638 copy-initialization.
1639 * python/py-threadevent.c (create_thread_event_object): Use
1640 copy-initialization.
1642 2018-08-24 Pedro Alves <palves@redhat.com>
1643 Simon Marchi <simon.marchi@ericsson.com>
1646 * python/py-continueevent.c: Include "gdbthread.h".
1647 (create_continue_event_object): Add intro comment. Add 'ptid'
1648 parameter. Use it to find thread to pass to
1649 create_thread_event_object.
1650 (emit_continue_event): Pass PTID down to
1651 create_continue_event_object.
1652 * python/py-event.h (py_get_event_thread): Declare.
1653 (create_thread_event_object): Remove default from 'thread'
1655 * python/py-stopevent.c (create_stop_event_object): Use
1656 py_get_event_thread.
1657 * python/py-threadevent.c (get_event_thread): Rename to ...
1658 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
1659 and use it to find the thread.
1660 (create_thread_event_object): Assert that THREAD isn't null.
1661 Don't find the event thread here.
1663 2018-08-23 Kevin Buettner <kevinb@redhat.com>
1665 * block.h (blockrange, blockranges): New struct declarations.
1666 (struct block): Add new field named `ranges'.
1667 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
1668 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
1669 macros for accessing ranges in struct block.
1670 (make_blockranges): New declaration.
1671 block.c (make_blockranges): New function.
1672 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
1674 * symtab.h (find_pc_partial_function): Add new parameter `block'.
1675 * blockframe.c (cache_pc_function_block): New static global.
1676 (clear_pc_function_cache): Clear cache_pc_function_block.
1677 (find_pc_partial_function): Move comment to symtab.h. Add
1678 support for non-contiguous blocks.
1679 * cli/cli-cmds.c (block.h): Include.
1680 (print_disassembly): Handle printing of non-contiguous blocks.
1681 (disassemble_current_function): Likewise.
1682 (disassemble_command): Likewise.
1684 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
1686 * blockframe.c (get_pc_function_start): Likewise.
1687 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
1688 (gcc_symbol_address): Likewise.
1689 * compile/compile-object-run.c (compile_object_run): Likewise.
1690 * compile/compile.c (get_expr_block_and_pc): Likewise.
1691 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
1692 (func_addr_to_tail_call_list): Likewise.
1693 * findvar.c (default_read_var_value): Likewise.
1694 * inline-frame.c (inline_frame_this_id): Likewise.
1695 (skip-inline_frames): Likewise.
1696 * infcmd.c (until_next_command): Likewise.
1697 * linespec.c (convert_linespec_to_sals): Likewise.
1698 * parse.c (parse_exp_in_context_1): Likewise.
1699 * printcmd.c (build_address_symbolic): likewise.
1700 (info_address_command): Likewise.
1701 symtab.c (find_function_start_sal): Likewise.
1702 (skip_prologue_sal): Likewise.
1703 (find_function_alias_target): Likewise.
1704 (find_gnu_ifunc): Likewise.
1705 * stack.c (find_frame_funname): Likewise.
1706 * symtab.c (fixup_symbol_section): Likewise.
1707 (find_function_start_sal): Likewise.
1708 (skip_prologue_sal): Likewsie.
1709 (find_function_alias_target): Likewise.
1710 (find_gnu_ifunc): Likewise.
1711 * tracepoint.c (info_scope_command): Likewise.
1712 * value.c (value_fn_field): Likewise.
1714 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
1715 in place of find_pc_partial_function.
1716 * blockframe.c (find_function_entry_range_from_pc): New function.
1717 * symtab.h (find_function_entry_range_from_pc): Declare and document.
1718 * objfiles.c (objfile_relocate1): Relocate start and end addresses
1719 for each range in a block.
1722 2018-08-23 Xavier Roirand <roirand@adacore.com>
1724 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
1727 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1729 * solib-svr4.c (read_program_headers_from_bfd): Return
1730 gdb::optional<gdb::byte_vector>.
1731 (svr4_exec_displacement): Adjust.
1733 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1735 * solib-svr4.c (read_program_header): Return
1736 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
1737 (find_program_interpreter): Return
1738 gdb::optional<gdb::byte_vector>.
1739 (scan_dyntag_auxv): Adjust.
1740 (enable_break): Adjust.
1741 (svr4_exec_displacement): Adjust.
1743 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1745 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
1746 * inf-child.c (inf_child_target::terminal_save_inferior): New.
1748 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1750 * guile/scm-string.c (gdbscm_scm_from_printf): Use
1752 * guile/scm-utils.c (gdbscm_printf): Likewise.
1753 * serial.c (serial_printf): Likewise.
1754 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
1756 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
1758 * stack.c (print_frame): Print frame architecture when printing on
1760 * NEWS: Mention new "arch" attribute in frame output.
1762 2018-08-21 Alan Hayward <alan.hayward@arm.com>
1764 * arch/aarch64.h (aarch64_regnum): Update comment.
1766 2018-08-21 Alan Hayward <alan.hayward@arm.com>
1768 * NEWS: Add SVE to 8.2 section.
1770 2018-08-21 Pedro Alves <palves@redhat.com>
1772 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
1773 out from gdbscm_parse_function_args.
1774 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
1775 gdbscm_parse_function_args_1.
1777 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
1780 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
1783 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
1785 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
1787 2018-08-19 Michael Spang <spang@google.com>
1790 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
1791 for PT_TLS segments.
1793 2018-08-18 Kevin Buettner <kevinb@redhat.com>
1795 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
1796 dwarf_variable_value.
1797 * dwarf2-frame.c (class dwarf_expr_executor):
1798 Add override for dwarf_variable_value.
1799 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
1800 (class symbol_needs_eval_context): Likewise.
1801 (indirect_synthetic_pointer): Add forward declaration.
1802 (sect_variable_value): New function.
1803 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
1804 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
1805 for DW_OP_GNU_variable_value.
1807 2018-08-16 Tom Tromey <tom@tromey.com>
1809 * top.c (read_command_file): Update.
1810 (command_line_input): Remove "repeat" argument.
1811 * ada-lang.c (get_selections): Update.
1812 * linespec.c (decode_line_2): Update.
1813 * defs.h (command_line_input): Remove argument.
1814 * cli/cli-script.c (read_next_line): Update.
1815 * python/py-gdb-readline.c: Update.
1817 2018-08-17 Tom Tromey <tom@tromey.com>
1819 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
1822 2018-08-15 Tom Tromey <tom@tromey.com>
1824 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
1826 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
1828 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
1829 If used, use find_pc_partial_function to find address range
1831 * mi/mi-main.c (mi_cmd_list_features): Report
1832 "data-disassemble-a-option" feature.
1833 * NEWS: Mention new -data-disassemble option -a.
1835 2018-08-13 Tom Tromey <tom@tromey.com>
1837 * common/common-defs.h (_FORTIFY_SOURCE): Define.
1839 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1841 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
1842 (aarch64_linux_collect_sve_regset): Likewise.
1843 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
1844 * regcache.h (regcache_map_entry_size): New function.
1846 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1848 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
1849 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
1850 (SVE_HEADER_VL_LENGTH): Likewise.
1851 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
1852 (SVE_HEADER_FLAGS_LENGTH): Likewise.
1853 (SVE_HEADER_RESERVED_LENGTH): Likewise.
1854 (SVE_HEADER_SIZE_OFFSET): Likewise.
1855 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
1856 (SVE_HEADER_VL_OFFSET): Likewise.
1857 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
1858 (SVE_HEADER_FLAGS_OFFSET): Likewise.
1859 (SVE_HEADER_RESERVED_OFFSET): Likewise.
1860 (SVE_HEADER_SIZE): Likewise.
1861 (aarch64_linux_core_read_vq): Add function.
1862 (aarch64_linux_core_read_description): Check for SVE section.
1864 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1866 * aarch64-fbsd-tdep.c
1867 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
1869 * aarch64-linux-tdep.c
1870 (aarch64_linux_iterate_over_regset_sections): Likewise.
1871 * alpha-linux-tdep.c
1872 (alpha_linux_iterate_over_regset_sections):
1874 (alphanbsd_iterate_over_regset_sections): Likewise.
1876 (amd64fbsd_iterate_over_regset_sections): Likewise.
1877 * amd64-linux-tdep.c
1878 (amd64_linux_iterate_over_regset_sections): Likewise.
1880 (armbsd_iterate_over_regset_sections): Likewise.
1882 (arm_fbsd_iterate_over_regset_sections): Likewise.
1884 (arm_linux_iterate_over_regset_sections): Likewise.
1885 * corelow.c (get_core_registers_cb): Likewise.
1886 (core_target::fetch_registers): Likewise.
1887 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
1888 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
1889 * gdbarch.h (void): Regenerate.
1890 * gdbarch.sh: Add supply_size and collect_size.
1891 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
1892 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
1893 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
1894 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
1895 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
1896 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
1897 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
1898 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
1899 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
1900 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
1901 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
1902 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
1903 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
1904 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
1905 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
1906 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
1907 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
1908 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
1909 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
1910 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
1911 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
1912 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
1913 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
1914 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
1915 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
1916 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
1917 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
1918 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
1919 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
1920 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
1922 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
1924 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
1927 2018-08-10 Keith Seitz <keiths@redhat.com>
1929 * compile/compile-c-support.c (add_code_header, add_code_footer):
1930 Move into policy class.
1931 (c_push_user_expression, pop_user_expression_nop)
1932 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
1933 (compile_program): New host class.
1934 (c_compile_program): New typedef.
1935 (c_compute_porgram): Use c_compile_program.
1937 2018-08-10 Keith Seitz <keiths@redhat.com>
1939 * compile/compile-internal.h (compile_instance::~compile_instance):
1940 Remove calls to htab_delete.
1941 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
1942 * compile.c (compile_instance::compile_instance): Initialize
1943 htab unique pointers.
1944 (compile_instance::get_cached_type, compile_instance::insert_type)
1945 (compile_instance::error_symbol_once): Update for unique_ptr.
1947 2018-08-10 Keith Seitz <keiths@redhat.com>
1949 * compile/compile-c-symbols.c (struct symbol_error)
1950 (hash_symbol_error, eq_symbol_error, del_symbol_error)
1951 (compile_instance::insert_symbol_error)
1952 (compile_instance::error_symbol_once): Move to ...
1953 * compile/compile.c: ... here.
1955 2018-08-10 Keith Seitz <keiths@redhat.com>
1957 * compile/compile-c-support.c (c_get_compile_context): Use `new'
1958 instead of `new_compile_instance'.
1959 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
1961 If the symbol error map is not initialized, create it.
1962 (generate_c_for_for_one_symbol): Do not check/initialize
1963 the symbol error map.
1964 * compile/compile-c-types.c (compile_c_instance): Make a class.
1966 (compile_instance::compile_instance): Initialize the type cache.
1967 (get_cached_type): New function.
1968 (insert_type): Update description.
1969 (compile_c_instance::m_default_cflags): Define.
1970 (convert_type): Update description. Use get_cached_type.
1971 (delete_instance): Moved to destructor.
1972 (new_compile_instance): Moved to constructor.
1973 * compile/compile-c.h (compile_c_instance): Make class inheriting
1974 from compile_instance.
1975 <base>: Remove field.
1976 <type_map, symbol_err_map>: Move to base class.
1977 <c_plugin>: Rename to `m_plugin' and remove pointer type.
1978 * compile/compile-internal.h (compile_instance): Make class.
1979 <type_map_t, symbol_err_map_t>: Define.
1980 <fe>: Rename to `m_gcc_fe'.
1981 <scope, block, gcc_target_options>: Add `m_' prefix.
1982 <m_type_map, m_symbol_err_map>: New fields, moved from
1985 (convert_type, new_compile_instance): Remove.
1986 * compile/compile.c (cleanup_compile_instance): Remove.
1987 (compile_to_object): Use unique_ptr to eliminate cleanups.
1988 (compile_instance::set_print_callback, compile_instance::version)
1989 (compile_instance::set_verbose)
1990 (compile_instance::set_driver_filename)
1991 (compile_instance::set_triplet_regexp)
1992 (compile_instance::set_arguments)
1993 (compile_instance::set_source_file)
1994 (compile_instance::compile): Define.
1996 2018-08-10 Keith Seitz <keiths@redhat.com>
1998 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
1999 * compile/compile-c-types.c: Define GCC_METHODN macros and include
2000 gcc-c-fe.def to define C plugin.
2001 (delete_instance): Delete `c_plugin'.
2002 (new_compile_instance): Initialize `c_plugin'.
2003 * compile/compile-c.h: Include gcc_c_plugin.h.
2004 (struct compile_c_instance) <c_plugin>: New member.
2005 * gcc-c-plugin.h: New file.
2006 Update all callers with API change.
2008 2018-08-10 Keith Seitz <keiths@redhat.com>
2010 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
2011 (HFILES_NO_SRCDIR): ... to here.
2012 Add compile-internal.h and compile-c.h.
2013 * compile/compile-c-support.c: Include compile-c.h.
2014 * compile/compile-c-symbols.c: Include compile-c.h.
2015 (generate_c_for_variable_locations): Update comment.
2016 * compile/compile-c-types.c: Include compile-c.h.
2017 * compile/compile-c.h: New file -- moved C language declarations
2018 from other files here.
2019 * compile/compile-internal.h: Do not include hashtab.h or
2020 common/enum-flags.h.
2021 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
2022 (gcc_convert_symbol, gcc_symbol_address)
2023 (generate_c_for_variable_locations, c_get_mode_for_size)
2024 (c_get_range_decl_name): Definitions moved to compile-c.h.
2025 * compile/compile-loc2c.c: Include compile-c.h.
2027 2018-08-10 Keith Seitz <keiths@redhat.com>
2029 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
2030 (c_symbol_substitution_name): ... this.
2033 2018-08-10 Keith Seitz <keiths@redhat.com>
2035 * compile/compile-c-support.c (c_compute_program): Use
2036 unique_xmalloc_ptr to eliminate cleanup.
2037 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
2038 Return a unique_xmalloc_ptr and eliminate cleanup.
2039 * compile/compile-internal.h (generate_c_for_variable_locations):
2040 Return unique_xmalloc_ptr and update description.
2042 2018-08-10 Alan Hayward <alan.hayward@arm.com>
2044 * corelow.c (core_target::get_core_register_section): Rename
2045 min_size to section_min_size.
2047 2018-08-09 Jim Wilson <jimw@sifive.com>
2049 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
2050 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
2051 * NEWS: Mention new GNU/Linux RISC-V target.
2052 * configure.host: Add riscv*-*-linux*.
2053 * configure.nat: Add riscv*.
2054 * configure.tgt: Add riscv*-*-linux*.
2055 * riscv-linux-nat.c: New file.
2056 * riscv-linux-tdep.c: New file.
2058 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2060 * infrun.c (resume): Make static, add forward declaration.
2061 (proceed): Update header comment.
2062 * infrun.h (resume): Delete declaration.
2064 2018-08-09 Tom Tromey <tom@tromey.com>
2066 * riscv-tdep.h: Minor formatting fixes.
2068 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
2070 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
2071 * dwarf-index-cache.c (create_dir_and_check): Likewise.
2072 (test_mkdir_recursive): Likewise.
2073 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
2075 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2077 * valarith.c (value_subscripted_rvalue): If an array is not in
2078 memory, and we don't know the upper bound, then we can't know that
2079 the requested element exists or not.
2081 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
2083 * target.c (str_comma_list_concat_elem): Fix typo in comment.
2084 (target_options_to_string): Add comment.
2086 2018-08-08 Tom Tromey <tom@tromey.com>
2088 * unittests/scoped_mmap-selftests.c: Check result of "write".
2090 2018-08-08 Jim Wilson <jimw@sifive.com>
2092 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
2093 (decode_register_index_short): New.
2094 (decode_j_type_insn, decode_cj_type_insn): New.
2095 (decode_b_type_insn, decode_cb_type_insn): New.
2096 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
2097 local xlen. Check xlen when decoding ambiguous compressed insns. In
2098 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
2099 is_c_sw_insn instead of is_sw_insn.
2100 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
2101 (riscv_software_single_step): New.
2102 * riscv-tdep.h (riscv_software_single_step): Declare.
2104 * riscv-tdep.c (riscv_isa_xlen): Drop static.
2105 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
2107 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
2110 * target.c (dispose_inferior): Don't dispose of inferiors that are
2113 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
2115 * remote.c (remote_target::download_tracepoint): Change char* to
2118 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
2120 * target.h (target_options_to_string): Return an std::string.
2121 * target.c (str_comma_list_concat_elem): Return void, use
2123 (do_option): Likewise.
2124 (target_options_to_string): Return an std::string.
2125 * linux-nat.c (linux_nat_target::wait): Adjust.
2126 * target-debug.h (target_debug_print_options): Adjust.
2128 2018-08-07 Tom Tromey <tom@tromey.com>
2130 * Makefile.in (CPPFLAGS): New variable.
2131 (INTERNAL_CPPFLAGS): Use it.
2133 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2135 * NEWS: Mention the index cache.
2137 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2139 * common/pathstuff.h (get_standard_cache_dir): New.
2140 * common/pathstuff.c (get_standard_cache_dir): New.
2141 * build-id.h (build_id_to_string): New.
2142 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
2143 DEBUG_STR_SUFFIX): Move to here.
2144 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
2145 DEBUG_STR_SUFFIX): Move from there.
2146 (write_psymtabs_to_index): Make non-static, add basename
2147 parameter. Write to temporary files, rename when done.
2148 (save_gdb_index_command): Adjust call to
2149 write_psymtabs_to_index.
2150 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
2152 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
2153 (get_gdb_index_contents_from_cache): New.
2154 (get_gdb_index_contents_from_cache_dwz): New.
2155 (dwarf2_initialize_objfile): Read index from cache.
2156 (dwarf2_build_psymtabs): Save to index.
2157 * dwarf-index-cache.h: New file.
2158 * dwarf-index-cache.c: New file.
2159 * dwarf-index-write.h: New file.
2161 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2163 * gnulib/aclocal.m4: Re-generate.
2164 * gnulib/config.in: Re-generate.
2165 * gnulib/configure: Re-generate.
2166 * gnulib/import/Makefile.am: Re-generate.
2167 * gnulib/import/Makefile.in: Re-generate.
2168 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
2169 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2170 * gnulib/import/m4/mkdir.m4: New file.
2171 * gnulib/import/mkdir.c: New file.
2172 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
2175 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2177 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
2178 * common/scoped_mmap.c: New file.
2179 * common/scoped_mmap.h (destroy): New method.
2180 (~scoped_mmap, reset): Use destroy.
2181 (scoped_mmap): New move constructor.
2182 (mmap_file): New declaration.
2183 * unittests/scoped_mmap-selftests.c (test_normal,
2184 test_invalid_filename, run_tests): New functions.
2185 (_initialize_scoped_mmap_selftests): Register selftest.
2187 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2189 * dwarf2read.c (read_gdb_index_from_section): Rename to...
2190 (read_gdb_index_from_buffer): ... this. Remove section
2191 parameter, add buffer parameter.
2192 (get_gdb_index_contents_ftype,
2193 get_gdb_index_contents_dwz_ftype): New typedefs.
2194 (dwarf2_read_gdb_index): Add callback parameters to get the
2196 (get_gdb_index_contents_from_section): New.
2197 (dwarf2_initialize_objfile): Update call to
2198 dwarf2_read_gdb_index.
2200 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2202 * common/filestuff.h (gdb_fopen_cloexec): New overload.
2203 (gdb_open_cloexec): Likewise.
2204 * nat/linux-osdata.c (command_from_pid): Use string_printf.
2205 (commandline_from_pid): Likewise.
2206 (linux_xfer_osdata_threads): Likewise.
2207 (linux_xfer_osdata_fds): Likewise.
2208 * ada-lang.c (is_package_name): Likewise.
2209 * auxv.c (procfs_xfer_auxv): Likewise.
2210 * breakpoint.c (print_one_breakpoint_location): Use
2212 (print_one_catch_solib): Use string_printf.
2213 * coff-pe-read.c (add_pe_exported_sym): Likewise.
2214 (add_pe_forwarded_sym): Likewise.
2215 * dwarf2read.c (create_type_unit_group): Likewise.
2216 (build_error_marker_type): Likewise.
2217 * infcall.c (get_function_name): Likewise.
2218 * valprint.c (print_converted_chars_to_obstack): Likewise.
2219 * xtensa-tdep.c (xtensa_register_type): Likewise.
2221 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
2223 * remote.c (remote_target::download_tracepoint): Fix format
2226 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2228 * tracefile.c: Include common/byte-vector.h.
2229 (trace_save): Change type of buf to gdb::byte_vector. Initialize
2230 with trace_regblock_size if needed. Update uses of buf.
2232 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2234 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
2235 std::vector<unsigned char>.
2236 * tracepoint.c (collection_list::collection_list): Remove
2237 m_regs_mask initializer from initializer list. Resize
2238 m_regs_mask using the largest remote register number.
2239 (collection_list::add_remote_register): Remove size check on
2240 m_regs_mask. Use at to access element.
2241 (collection_list::stringify): Change type of temp_buf to
2242 gdb::char_vector. Update uses of temp_buf. Resize if needed to
2243 stringify the register mask. Use pack_hex_byte for the register
2246 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2248 * tracepoint.h (class collection_list) <add_register>: Remove.
2249 <add_remote_register, add_ax_registers, add_local_register>:
2251 <add_memrange>: Add scope parameter.
2252 * tracepoint.c (encode_actions_1): Likewise.
2253 (collection_list::add_register): Rename to ...
2254 (collection_list::add_remote_register): ... this. Update
2256 (collection_list::add_ax_registers, add_local_register): New
2258 (collection_list::add_memrange): Add scope parameter. Call
2259 add_local_register instead of add_register.
2260 (finalize_tracepoint_aexpr): New function.
2261 (collection_list::collect_symbol): Update calls to add_memrange.
2262 Call add_local_register instead of add_register. Call
2263 add_ax_registers. Call finalize_tracepoint_aexpr.
2264 (encode_actions_1): Get remote regnos for $reg action. Call
2265 add_remote_register, add_ax_registers, and add_local_register.
2266 Update call to add_memrange. Call finalize_tracepoint_aexpr.
2267 (validate_actionline): Call finalize_tracepoint_aexpr.
2269 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2271 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
2272 Replace array buf with gdb::char_vector buf, of size
2273 get_remote_packet_size (). Replace references to buf and
2274 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
2275 and xsnprintf with snprintf. Raise errors if the buffer is too
2278 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2280 * remote.c (remote_target::download_tracepoint): Fix the has_more
2281 predicate in the QTDP action list iteration.
2283 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2285 * remote.c (remote_target::download_tracepoint): Fix indentation
2288 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2290 * proc-api.c (_initialize_proc_api): Remove c, unused.
2291 * procfs.c (procfs_init_inferior): Remove signals, unused.
2292 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
2295 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
2296 Andrew Burgess <andrew.burgess@embecosm.com>
2298 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
2299 'W_STOPCODE (0)' as this could be ambiguous.
2301 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
2303 * ser-tcp.c (net_open): Fix thinko when deciding whether to
2304 disable TCP's Nagle algorithm (use "ai_protocol" instead of
2307 2018-08-02 Tom Tromey <tom@tromey.com>
2310 * dwarf2read.c (read_func_scope): Set symtab on template parameter
2312 (process_structure_scope): Likewise.
2314 2018-08-02 Xavier Roirand <roirand@adacore.com>
2317 * darwin-nat.c (darwin_kill_inferior): Fix handling of
2320 2018-08-02 Tom Tromey <tom@tromey.com>
2322 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
2323 (darwin_suspend_inferior, darwin_resume_inferior)
2324 (darwin_decode_notify_message, darwin_resume_inferior_threads)
2325 (darwin_check_new_threads): Check result of get_darwin_inferior.
2327 2018-07-31 Joel Brobecker <brobecker@adacore.com>
2331 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
2333 * varobj.c (varobj_get_path_expr_parent): Report an error if
2334 parent is a dynamic varobj.
2336 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2338 * gnulib/aclocal.m4: Re-generate.
2339 * gnulib/config.in: Re-generate.
2340 * gnulib/configure: Re-generate.
2341 * gnulib/import/Makefile.in: Re-generate.
2342 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2343 * gnulib/import/m4/onceonly.m4: Re-generate.
2345 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2347 * target-descriptions.c (struct xml_test_tdesc): New.
2348 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
2349 (record_xml_tdesc): Update.
2350 (maintenance_check_xml_descriptions): Update.
2351 * target-descriptions.h (record_xml_tdesc): Update comment.
2353 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
2355 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
2356 checking array bounds are defined.
2358 2018-07-30 Tom Tromey <tom@tromey.com>
2360 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
2361 irreflexivity violation.
2363 2018-07-30 Tom Tromey <tom@tromey.com>
2365 * cli/cli-decode.c (lookup_cmd): Remove lint code.
2366 * value.c (unpack_long): Remove lint code.
2367 * valops.c (value_ind): Remove lint code.
2368 * valarith.c (value_x_binop, value_x_unop, value_equal)
2369 (value_pos): Remove lint code.
2371 2018-07-28 Tom de Vries <tdevries@suse.de>
2373 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
2374 with undefined upper bound as <optimized out>.
2376 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
2378 * gcore.in: Rename variable "name" to "prefix". Expand
2381 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
2383 * windows-nat.c (windows_nat_target::create_inferior): Update to
2384 call close() in global namespace.
2386 2018-07-26 Tom Tromey <tom@tromey.com>
2388 * dwarf-index-write.c (add_address_entry): Don't add objfile
2390 * dbxread.c (find_stab_function): Rename from
2391 find_stab_function_addr. Return a bound_minimal_symbol.
2392 (read_dbx_symtab): Use raw_text_low, raw_text_high.
2393 Don't add objfile offsets.
2394 (end_psymtab): Use raw_text_low, raw_text_high,
2395 MSYMBOL_VALUE_RAW_ADDRESS.
2396 (read_ofile_symtab): Update.
2397 (process_one_symbol): Update.
2398 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
2400 (dw2_relocate): Remove.
2401 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
2403 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
2405 (process_psymtab_comp_unit_reader, add_partial_symbol)
2406 (add_partial_subprogram, dwarf2_ranges_read): Update.
2407 (load_partial_dies): Update.
2408 (add_address_entry): Don't add objfile offsets.
2409 (dwarf2_build_include_psymtabs): Update.
2410 (create_addrmap_from_aranges): Don't add objfile offsets.
2411 (dw2_find_pc_sect_compunit_symtab): Update.
2412 * mdebugread.c (parse_symbol): Don't add objfile offsets.
2413 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
2415 (parse_partial_symbols): Don't add objfile offsets. Use
2416 raw_text_low, raw_text_high. Update.
2417 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
2418 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
2419 or call 'relocate' quick function. Clear psymbol_map.
2420 * psympriv.h (struct partial_symbol) <address>: Add section
2422 <set_unrelocated_address>: Rename from set_address.
2423 <raw_text_low, raw_text_high>: New methods.
2424 <text_low, text_high>: Add objfile parameter.
2425 (add_psymbol_to_bcache): Add 'section' parameter. Call
2426 set_unrelocated_address.
2427 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2428 (find_pc_psymbol): Update.
2429 (fixup_psymbol_section, relocate_psymtabs): Remove.
2430 (dump_psymtab, psym_functions): Update.
2431 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
2433 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
2434 (start_psymtab_common): Update.
2435 * symfile-debug.c (debug_qf_relocate): Remove.
2436 (debug_sym_quick_functions): Update.
2437 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
2438 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
2441 2018-07-26 Tom Tromey <tromey@redhat.com>
2443 * dbxread.c (end_psymtab): Use text_high_valid and
2445 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
2446 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
2447 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2449 <text_low_valid, text_high_valid>: New fields.
2450 <set_text_low, set_text_high>: Update.
2451 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
2453 2018-07-26 Tom Tromey <tom@tromey.com>
2455 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
2457 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
2458 textlow and texthigh fields.
2459 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
2461 * mdebugread.c (parse_lines, parse_partial_symbols)
2462 (psymtab_to_symtab_1): Update.
2463 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2464 Rename fields. Update comment. Now private.
2465 <text_low, text_high, set_text_low, set_text_high>: New methods.
2466 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2467 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
2468 (start_psymtab_common, maintenance_info_psymtabs)
2469 (maintenance_check_psymtabs): Update.
2470 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
2472 (scan_xcoff_symtab): Update.
2474 2018-07-26 Tom Tromey <tromey@redhat.com>
2476 * psympriv.h (struct partial_symbol) <unrelocated_address,
2477 address, set_address>: New methods.
2478 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
2479 (fixup_psymbol_section, relocate_psymtabs): Update.
2480 (print_partial_symbols): Add 'objfile' parameter. Update.
2481 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
2484 2018-07-26 Tom Tromey <tom@tromey.com>
2486 * dwarf-index-write.c (write_psymbols, debug_names::insert)
2487 (debug_names::write_psymbols): Update.
2488 * psympriv.h (struct partial_symbol): Derive from
2489 general_symbol_info.
2490 <obj_section>: New method.
2491 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
2492 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2493 (find_pc_sect_psymbol, fixup_psymbol_section)
2494 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
2495 (print_partial_symbols, recursively_search_psymtabs)
2496 (compare_psymbols, psymbol_hash, psymbol_compare)
2497 (add_psymbol_to_bcache, maintenance_check_psymtabs)
2498 (psymbol_name_matches, psym_fill_psymbol_map): Update.
2500 2018-07-26 Tom Tromey <tromey@redhat.com>
2502 * dbxread.c (end_psymtab): Remove dead code.
2504 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
2506 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
2507 DWARF unwinders are disabled.
2508 * dwarf2-frame.c: Add dwarf2read.h include.
2509 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
2511 (dwarf2_frame_unwinders_enabled_p): Define.
2512 (show_dwarf_unwinders_enabled_p): New function.
2513 (_initialize_dwarf2_frame): Register switch to control DWARF
2515 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
2516 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
2517 (show_dwarf_cmdlist): Remove static keyword.
2518 * dwarf2read.h (set_dwarf_cmdlist): Declare.
2519 (show_dwarf_cmdlist): Declare.
2520 * NEWS: Document new feature.
2522 2018-07-26 Tom de Vries <tdevries@suse.de>
2524 PR breakpoints/23366
2525 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
2527 2018-07-26 Tom de Vries <tdevries@suse.de>
2529 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
2530 DW_AT_count can't be translated to a dynamic prop.
2532 2018-07-25 Tom de Vries <tdevries@suse.de>
2534 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
2537 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
2539 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
2541 2018-07-25 Joel Brobecker <brobecker@adacore.com>
2543 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
2545 2018-07-24 Keith Seitz <keiths@redhat.comt
2548 * dwarf2read.c (dw2_add_symbol_to_list): New function.
2549 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
2550 instead of add_symbol_to_list.
2551 (read_file_scope): Call prepare_one_comp_unit before reading
2554 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
2556 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
2558 2018-07-24 Tom Tromey <tom@tromey.com>
2560 * utils.c (malloc, realloc, free): Don't declare.
2561 * configure, config.in: Rebuild.
2562 * configure.ac: Don't check for declarations of free, malloc, or
2565 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2567 * aarch64-linux-nat.c
2568 (aarch64_linux_nat_target::stopped_data_address): Remove unused
2570 * arm-linux-nat.c (fetch_regs): Likewise.
2571 (store_regs): Likewise.
2572 (fetch_vfp_regs): Likewise.
2573 (store_vfp_regs): Likewise.
2574 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
2575 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
2576 (arm_linux_nat_target::insert_watchpoint): Likewise.
2577 (arm_linux_nat_target::remove_watchpoint): Likewise.
2578 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
2580 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
2582 * ppc-linux-nat.c (fetch_register): Likewise.
2583 (fetch_all_gp_regs): Likewise.
2584 (fetch_ppc_registers): Likewise.
2585 (store_all_gp_regs): Likewise.
2586 (store_ppc_registers): Likewise.
2587 (hwdebug_insert_point): Likewise.
2588 (can_use_watchpoint_cond_accel): Likewise.
2589 * remote-sim.c (gdb_os_write_stdout): Likewise.
2591 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2592 Tom Tromey <tom@tromey.com>
2594 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
2596 * configure: Rebuild.
2598 2018-07-22 Tom Tromey <tom@tromey.com>
2600 * regformats/regdat.sh: Define xmltarget_${name} inside
2601 #ifndef IN_PROCESS_AGENT.
2603 2018-07-22 Tom Tromey <tom@tromey.com>
2605 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
2607 2018-07-22 Tom Tromey <tom@tromey.com>
2609 * symfile.c (reread_symbols): Notify iter, not objfile.
2611 2018-07-22 Tom Tromey <tom@tromey.com>
2613 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
2615 (ravenscar_thread_target::prepare_to_store): Likewise.
2617 2018-07-22 Tom Tromey <tom@tromey.com>
2619 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
2620 unused variable. Call value_fetch_lazy when needed.
2621 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
2622 Remove unused variable. Call value_fetch_lazy when needed.
2624 2018-07-22 Tom Tromey <tom@tromey.com>
2626 * m32c-tdep.c (mark_dma): Return void.
2627 (make_regs): Remove unused declarations.
2629 2018-07-22 Tom Tromey <tom@tromey.com>
2631 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
2632 cmdscm_get_valid_command_smob_arg_unsafe for effect.
2633 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
2634 bkscm_get_valid_block_smob_arg_unsafe for effect.
2636 2018-07-22 Tom Tromey <tom@tromey.com>
2638 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
2641 2018-07-22 Tom Tromey <tom@tromey.com>
2643 * windows-nat.c (saved_context): Conditionally define.
2644 * remote.c (remote_target::remote_btrace_maybe_reopen):
2645 Conditionally declare "warned".
2646 * inflow.c (sigquit_ours): Conditionally define.
2647 (new_tty): Move "tty" declaration inside #if.
2648 * guile/guile.c (guile_datadir): Conditionally define.
2649 * charset.c (set_be_le_names): Move some declarations inside #if.
2650 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
2652 (parse_xml_btrace_conf): Likewise.
2654 2018-07-22 Tom Tromey <tom@tromey.com>
2656 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
2658 2018-07-22 Tom Tromey <tom@tromey.com>
2660 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
2661 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
2662 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
2663 * buildsym-legacy.c (get_macro_table): Remove unused variable.
2664 * stack.c (frame_apply_level_command): Remove unused variable.
2665 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
2666 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
2667 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
2669 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
2670 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
2671 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
2673 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
2674 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
2676 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
2677 Remove unused variable.
2678 * cli/cli-script.c (recurse_read_control_structure): Remove unused
2680 * common/tdesc.c (print_xml_feature::visit): Remove unused
2682 * compile/compile-object-load.c (store_regs): Remove unused
2684 * complaints.c (clear_complaints): Remove unused variable.
2685 * corelow.c (core_target_open): Remove unused variable.
2686 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
2688 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
2690 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
2692 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
2694 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
2696 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
2698 * ia64-tdep.c (examine_prologue): Remove unused variable.
2699 * infcall.c (run_inferior_call): Remove unused variable.
2700 * inferior.c (exit_inferior): Remove unused variable.
2701 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
2702 * linespec.c (decode_line_2): Remove unused variable.
2703 * linux-nat.c (super_close): Remove.
2704 * linux-tdep.c (linux_info_proc): Remove unused variable.
2705 * mi/mi-main.c (mi_execute_command): Remove unused variable.
2706 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
2707 Remove unused variable.
2708 * parse.c (find_minsym_type_and_address): Remove unused variable.
2709 * printcmd.c (info_symbol_command, printf_floating): Remove unused
2711 * python/py-breakpoint.c (bppy_set_commands): Remove unused
2713 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
2715 * record-btrace.c (record_btrace_target::store_registers): Remove
2717 (cmd_show_record_btrace_cpu): Remove unused variable.
2718 * riscv-tdep.c (riscv_register_reggroup_p)
2719 (riscv_push_dummy_call, riscv_return_value): Remove unused
2721 * rust-exp.y (literal): Remove unused variable.
2722 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
2724 <STRUCTOP_ANONYMOUS>: Likewise.
2725 * s390-linux-tdep.c (s390_linux_init_abi_31)
2726 (s390_linux_init_abi_64): Remove unused variable.
2727 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
2728 (file_select_thread, net_windows_open, _initialize_ser_windows):
2729 Remove unused variables.
2730 * symtab.c (find_pc_sect_line): Remove unused variable.
2731 * target-memory.c (compute_garbled_blocks): Remove unused
2733 (target_write_memory_blocks): Remove unused variable.
2734 * target.c (target_stack::unpush): Remove unused variables.
2735 * tracepoint.c (start_tracing, all_tracepoint_actions)
2736 (merge_uploaded_trace_state_variables)
2737 (print_one_static_tracepoint_marker): Remove unused variable.
2738 * unittests/basic_string_view/element_access/char/1.cc (test01):
2739 Remove unused variable.
2740 * windows-nat.c (windows_continue, windows_add_all_dlls)
2741 (do_initial_windows_stuff, windows_nat_target::create_inferior):
2742 Remove unused variables.
2744 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
2746 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
2747 attr_profile in HAVE_ELF.
2748 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
2751 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
2753 * frame.c (frame_register_unwind): Change parameter name.
2754 (frame_unwind_register): Likewise.
2755 (frame_unwind_register_value): Likewise.
2756 (frame_unwind_register_signed): Likewise.
2757 (frame_unwind_register_unsigned): Likewise.
2758 * frame.h (frame_register_unwind): Likewise.
2759 (frame_unwind_register): Likewise.
2760 (frame_unwind_register_value): Likewise.
2761 (frame_unwind_register_signed): Likewise.
2762 (frame_unwind_register_unsigned): Likewise.
2763 (frame_unwind_arch): Likewise.
2765 2018-07-20 Maciej W. Rozycki <macro@mips.com>
2767 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
2770 2018-07-20 Maciej W. Rozycki <macro@mips.com>
2772 * mips-linux-nat.c (mips_linux_nat_target::read_description):
2773 Call `get_ptrace_pid' rather than extracting the ptrace PID by
2776 2018-07-20 Keith Seitz <keiths@redhat.com>
2778 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
2779 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
2780 m_compunit_symtab, m_language>: Add "m_" prefix.
2782 * buildsym.c: Update all uses.
2784 2018-07-20 Tom Tromey <tom@tromey.com>
2786 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
2787 * buildsym.h (record_line_ftype): Remove typedef.
2789 2018-07-20 Tom Tromey <tom@tromey.com>
2791 * buildsym-legacy.h (augment_type_symtab): Don't declare.
2792 (end_expandable_symtab): Likewise.
2793 (end_symtab_get_static_block): Likewise.
2794 (end_symtab_from_static_block): Likewise.
2795 * buildsym-legacy.c (augment_type_symtab): Remove.
2796 (end_expandable_symtab): Remove.
2797 (end_symtab_get_static_block): Remove.
2798 (end_symtab_from_static_block): Remove.
2800 2018-07-20 Tom Tromey <tom@tromey.com>
2802 * dwarf2read.c: Include buildsym.h.
2803 (struct dwarf2_cu) <builder>: New method.
2804 (fixup_go_packaging): Update.
2805 (process_full_comp_unit, process_full_type_unit): Update. Don't
2806 use scoped_free_pendings.
2807 (using_directives): Add "cu" parameter, remove "language".
2808 (read_import_statement, setup_type_unit_groups, )
2809 (read_func_scope, read_lexical_block_scope)
2810 (dwarf2_record_block_ranges, read_namespace): Update.
2811 (lnp_state_machine::lnp_state_machine): Add cu parameter.
2812 (lnp_state_machine::handle_end_sequence): Update.
2813 (class lnp_state_machine) <m_cu>: New member.
2814 <m_record_line_callback>: Remove.
2815 <m_currently_recording_lines>: New member.
2816 (lnp_state_machine::handle_set_file): Update.
2817 (noop_record_line): Remove.
2818 (dwarf_record_line_p): Add cu parameter.
2819 (dwarf_record_line_1, dwarf_finish_line): Likewise.
2820 (lnp_state_machine::record_line)
2821 (lnp_state_machine::lnp_state_machine)
2822 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
2823 (dwarf_decode_lines): Update.
2824 (dwarf2_start_subfile): Add cu parameter.
2825 (dwarf2_start_symtab, new_symbol): Update.
2826 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
2827 Remove dwarf2_per_objfile parameter.
2828 (dwarf_decode_macros): Update.
2830 2018-07-20 Tom Tromey <tom@tromey.com>
2832 * stabsread.c (define_symbol): Update.
2833 * buildsym-legacy.h (get_buildsym_compunit): Declare.
2834 * dwarf2read.c (new_symbol): Update.
2835 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
2836 * cp-namespace.c: Include buildsym.h.
2837 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
2838 * buildsym-legacy.c (get_buildsym_compunit): New function.
2840 2018-07-20 Tom Tromey <tom@tromey.com>
2842 * xcoffread.c: Include buildsym-legacy.h.
2843 * windows-nat.c: Include buildsym-legacy.h.
2844 * stabsread.c: Include buildsym-legacy.h.
2845 * mdebugread.c: Include buildsym-legacy.h.
2846 * buildsym-legacy.h: New file.
2847 * buildsym-legacy.c: New file, from buildsym.c.
2848 * go32-nat.c: Include buildsym-legacy.h.
2849 * dwarf2read.c: Include buildsym-legacy.h.
2850 * dbxread.c: Include buildsym-legacy.h.
2851 * cp-namespace.c: Include buildsym-legacy.h.
2852 * coffread.c: Include buildsym-legacy.h.
2853 * buildsym.h: Move some contents to buildsym-legacy.h.
2854 * buildsym.c: Include buildsym-legacy.h. Move many functions to
2856 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
2858 2018-07-20 Tom Tromey <tom@tromey.com>
2860 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
2861 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
2862 (buildsym_compunit::buildsym_compunit)
2863 (buildsym_compunit::~buildsym_compunit)
2864 (buildsym_compunit::get_macro_table): Define.
2866 2018-07-20 Tom Tromey <tom@tromey.com>
2868 * buildsym.c (reset_symtab_globals): Remove.
2869 (buildsym_compunit::end_symtab_from_static_block): Update.
2870 (buildsym_compunit::augment_type_symtab): Update.
2871 (end_symtab_from_static_block): Call free_buildsym_compunit.
2872 (augment_type_symtab, end_symtab, end_expandable_symtab):
2875 2018-07-20 Tom Tromey <tom@tromey.com>
2877 * arch-utils.c: Do not include buildsym.h.
2878 * mipsread.c: Do not include buildsym.h.
2879 * machoread.c: Do not include buildsym.h.
2880 * elfread.c: Do not include buildsym.h.
2882 2018-07-20 Tom Tromey <tom@tromey.com>
2884 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
2886 (buildsym_compunit): Add new constructor.
2887 (struct buildsym_compunit) <get_last_source_file, finish_block,
2888 record_block_range, start_subfile, patch_subfile_names,
2889 push_subfile, pop_subfile, record_line, get_compunit_symtab,
2890 set_last_source_start_addr, get_last_source_start_addr,
2891 get_local_using_directives, set_local_using_directives,
2892 get_global_using_directives, outermost_context_p,
2893 get_current_context_stack, get_context_stack_depth,
2894 get_current_subfile, get_local_symbols, get_file_symbols,
2895 get_global_symbols, record_debugformat, record_producer,
2896 push_context, pop_context, end_symtab_get_static_block,
2897 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
2899 <record_pending_block, finish_block_internal, make_blockvector,
2900 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
2904 2018-05-22 Tom Tromey <tom@tromey.com>
2906 * buildsym.c (record_pending_block): Move earlier. Remove objfile
2908 (finish_block_internal): Update.
2910 2018-07-20 Tom Tromey <tom@tromey.com>
2912 * buildsym.c (record_pending_block): Move earlier. Remove objfile
2914 (finish_block_internal): Update.
2916 2018-07-20 Tom Tromey <tom@tromey.com>
2918 * buildsym.h (EXTERN): Don't define or undef.
2919 * buildsym.c (EXTERN): Don't define.
2921 2018-07-20 Tom Tromey <tom@tromey.com>
2923 * buildsym.c: Remove TODO comment.
2925 2018-07-20 Tom Tromey <tom@tromey.com>
2927 * coffread.c (coff_symtab_read): Update.
2928 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
2929 (xcoff_new_init): Update.
2930 * mipsread.c (mipscoff_new_init): Update.
2931 * mdebugread.c (mdebug_build_psymtabs): Update.
2932 * elfread.c (elf_new_init): Update.
2933 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
2935 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
2936 (coffstab_build_psymtabs, elfstab_build_psymtabs)
2937 (stabsect_build_psymtabs): Update.
2938 * buildsym.h (buildsym_init): Don't declare.
2939 * buildsym.c: Update comment.
2940 (prepare_for_building): Remove.
2941 (start_symtab, restart_symtab): Update.
2942 (reset_symtab_globals): Update comment.
2943 (buildsym_init): Remove.
2945 2018-07-20 Tom Tromey <tom@tromey.com>
2947 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
2948 * stabsread.c (patch_block_stabs, define_symbol, read_type)
2949 (read_enum_type, common_block_start, common_block_end)
2950 (cleanup_undefined_types_1, finish_global_stabs): Update.
2951 * mdebugread.c (psymtab_to_symtab_1): Update.
2952 * dwarf2read.c (fixup_go_packaging, read_func_scope)
2953 (read_lexical_block_scope, new_symbol): Update.
2954 * dbxread.c (process_one_symbol): Update.
2955 * coffread.c (coff_symtab_read, process_coff_symbol)
2956 (coff_read_enum_type): Update.
2957 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
2959 (get_local_symbols, get_file_symbols, get_global_symbols): New
2961 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
2963 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
2964 (~scoped_free_pendings): Update.
2965 (finish_block, prepare_for_building, reset_symtab_globals)
2966 (end_symtab_get_static_block, end_symtab_with_blockvector)
2967 (augment_type_symtab, push_context): Update.
2968 (get_local_symbols, get_file_symbols, get_global_symbols): New
2970 (buildsym_init): Update.
2972 2018-07-20 Tom Tromey <tom@tromey.com>
2974 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
2975 (process_full_type_unit): Likewise.
2976 (dwarf2_start_symtab): Set list_in_scope.
2978 2018-07-20 Tom Tromey <tom@tromey.com>
2980 * dwarf2read.c (process_psymtab_comp_unit_reader)
2981 (build_type_psymtabs_reader): Do not set list_in_scope.
2983 2018-07-20 Tom Tromey <tom@tromey.com>
2985 * buildsym.c (free_pendings): Remove.
2986 (add_symbol_to_list, scoped_free_pendings)
2987 (finish_block_internal, buildsym_init): Update.
2989 2018-07-20 Tom Tromey <tom@tromey.com>
2991 * xcoffread.c (read_xcoff_symtab): Update.
2992 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
2994 * dbxread.c (process_one_symbol): Update.
2995 * coffread.c (coff_symtab_read): Update.
2996 * buildsym.h (finish_block): Update.
2997 * buildsym.c (finish_block): Remove "listhead" argument.
2998 (end_symtab_get_static_block): Update.
3000 2018-07-20 Tom Tromey <tom@tromey.com>
3002 * buildsym.h (class scoped_free_pendings): Remove constructor.
3003 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
3005 <m_pending_block_obstack, m_pending_blocks>: New members.
3006 (pending_block_obstack, pending_blocks): Remove.
3007 (scoped_free_pendings::scoped_free_pendings): Default.
3008 (~scoped_free_pendings): Update.
3009 (free_pending_blocks): Remove.
3010 (finish_block_internal, record_pending_block, make_blockvector)
3011 (end_symtab_get_static_block, augment_type_symtab, push_context)
3012 (buildsym_init): Update.
3014 2018-07-20 Tom Tromey <tom@tromey.com>
3016 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
3017 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
3019 (pending_addrmap, pending_addrmap_obstack)
3020 (pending_addrmap_interesting): Remove.
3021 (scoped_free_pendings, record_block_range, make_blockvector)
3022 (prepare_for_building, reset_symtab_globals, buildsym_init):
3025 2018-07-20 Tom Tromey <tom@tromey.com>
3027 * xcoffread.c (process_linenos): Update.
3028 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
3029 * mdebugread.c (psymtab_to_symtab_1): Update.
3030 * dwarf2read.c (setup_type_unit_groups)
3031 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
3032 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
3033 * dbxread.c (process_one_symbol): Update.
3034 * coffread.c (coff_symtab_read, enter_linenos)
3035 (process_coff_symbol): Update.
3036 * buildsym.h (current_subfile): Don't declare.
3037 (get_current_subfile): Declare.
3038 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
3040 (start_subfile, free_buildsym_compunit, push_subfile)
3041 (prepare_for_building, start_symtab): Update.
3042 (get_current_subfile): New function.
3044 2018-07-20 Tom Tromey <tom@tromey.com>
3046 * coffread.c (coff_symtab_read): Update.
3047 * xcoffread.c (read_xcoff_symtab): Update.
3048 * dwarf2read.c (new_symbol): Update.
3049 (read_func_scope, read_lexical_block_scope): Update.
3050 * dbxread.c (process_one_symbol): Update.
3051 * buildsym.h (context_stack, context_stack_depth): Don't declare.
3052 (outermost_context_p): Remove macro.
3053 (outermost_context_p, get_current_context_stack)
3054 (get_context_stack_depth): Declare.
3055 (pop_context): Return struct context_stack.
3056 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
3058 (context_stack_size): Remove.
3059 (INITIAL_CONTEXT_STACK_SIZE): Remove.
3060 (prepare_for_building, end_symtab_get_static_block)
3061 (augment_type_symtab, push_context): Update.
3062 (pop_context): Return struct context_stack.
3063 (outermost_context_p, get_current_context_stack)
3064 (get_context_stack_depth): New functions.
3065 (buildsym_init): Update.
3067 2018-07-20 Tom Tromey <tom@tromey.com>
3069 * rust-exp.y: Now a pure parser. Update all rules.
3070 (%union): Move earlier.
3071 (current_parser, work_obstack): Remove globals.
3072 (rust_parser, ~rust_parser): Update.
3073 (class rust_parser) <copy_name, concat3, crate_name, super_name,
3074 lex_character, lex_number, lex_string, lex_identifier,
3075 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
3076 convert_name, convert_params_to_expression,
3077 convert_ast_to_expression, ast_basic_type, ast_operation,
3078 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
3079 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
3080 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
3081 ast_array_type, ast_slice_type, ast_reference_type,
3082 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
3083 (rust_parse): Update.
3084 (rustyyerror, rustyylex): Add parser parameter.
3085 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
3086 (rust_lex_stringish_test, rust_lex_test_sequence)
3087 (rust_lex_test_trailing_dot, rust_lex_test_completion)
3088 (rust_lex_test_push_back, rust_lex_tests): Update.
3090 2018-07-19 Pedro Alves <palves@redhat.com>
3092 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
3093 gdb::unique_xmalloc_ptr.
3094 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
3095 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
3096 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
3097 copy-initialization.
3098 * guile/scm-pretty-print.c (ppscm_print_children): Use
3099 gdb::unique_xmalloc_ptr instead of cleanups.
3100 (gdbscm_apply_val_pretty_printer): Remove cleanups.
3101 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
3102 gdb::unique_xmalloc_ptr.
3103 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3104 Adjust to use gdb::unique_xmalloc_ptr.
3105 * guile/scm-utils.c (extract_arg): Adjust.
3106 * guile/scm-value.c (gdbscm_value_field): Adjust to use
3107 gdb::unique_xmalloc_ptr instead of a cleanup.
3109 2018-07-19 Tom Tromey <tom@tromey.com>
3111 * utils.c (do_value_free_to_mark)
3112 (make_cleanup_value_free_to_mark): Remove.
3113 * utils.h (make_cleanup_value_free_to_mark): Remove.
3115 2018-07-19 Pedro Alves <palves@redhat.com>
3117 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
3118 forwarding reference.
3120 2018-07-18 Pedro Alves <palves@redhat.com>
3122 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
3123 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
3126 2018-07-18 Pedro Alves <palves@redhat.com>
3128 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
3130 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
3132 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
3133 directly instead of a cleanup.
3134 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
3135 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
3136 (vlscm_binop_gdbthrow): New, factored out from ...
3137 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
3138 (vlscm_rich_compare): Use gdbscm_wrap.
3139 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
3140 instead of a cleanup.
3141 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
3143 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3144 Use xfree directly instead of a cleanup.
3145 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
3146 Adjust to use gdbscm_wrap and scoped_value_mark.
3147 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
3148 (gdbscm_value_address, gdbscm_value_dereference)
3149 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
3151 (gdbscm_value_dynamic_type): Use scoped_value_mark.
3152 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
3154 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
3155 gdbscm_wrap and scoped_value_mark.
3156 (gdbscm_value_to_string): Use xfree directly instead of a
3157 cleanup. Move 'buffer' unique_ptr to TRY scope.
3158 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
3159 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
3161 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
3162 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
3164 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
3167 2018-07-18 Tom de Vries <tdevries@suse.de>
3169 * findvar.c (default_read_var_value): Also resolve dynamic type for
3170 LOC_OPTIMIZED_OUT vars.
3172 2018-07-18 Maciej W. Rozycki <macro@mips.com>
3174 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
3177 2018-07-17 Tom Tromey <tom@tromey.com>
3179 * guile/scm-param.c (pascm_set_func, pascm_show_func)
3180 (compute_enum_list, pascm_set_param_value_x)
3181 (gdbscm_parameter_value): Update.
3182 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
3183 (gdbscm_scm_to_host_string): Update.
3184 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
3186 * guile/scm-cmd.c (cmdscm_add_completion): Update.
3187 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
3188 * guile/scm-string.c (gdbscm_scm_to_string): Return
3190 (gdbscm_scm_to_host_string): Likewise.
3192 2018-07-17 Tom Tromey <tom@tromey.com>
3194 * guile/guile.c (gdbscm_eval_from_control_command): Update.
3195 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
3196 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
3197 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
3200 2018-07-17 Tom Tromey <tom@tromey.com>
3202 * guile/scm-param.c (pascm_signal_setshow_error): Update.
3203 * guile/guile-internal.h (gdbscm_exception_message_to_string):
3205 * guile/scm-cmd.c (cmdscm_function): Update.
3206 * guile/scm-pretty-print.c
3207 (ppscm_print_exception_unless_memory_error): Update.
3208 * guile/scm-exception.c (gdbscm_exception_message_to_string):
3209 Return unique_xmalloc_ptr.
3211 2018-07-17 Tom Tromey <tom@tromey.com>
3213 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
3216 2018-07-17 Jim Wilson <jimw@sifive.com>
3218 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
3219 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
3220 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
3221 unecessary braces after EF_RISCV_RVC test. Delete call to
3222 set_gdbarch_decr_pc_after_break.
3224 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
3225 RISCV_LAST_FP_REGNUM + 1.
3226 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
3228 2018-07-17 Tom Tromey <tom@tromey.com>
3230 * configure.ac: Remove --disable-gdbcli.
3231 * configure: Rebuild.
3232 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
3233 (SUBDIR_CLI_CFLAGS): Remove.
3234 (SFILES): Use SUBDIR_CLI_SRCS.
3235 (COMMON_OBS): Use SUBDIR_CLI_OBS.
3237 2018-07-17 Tom Tromey <tom@tromey.com>
3240 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
3242 2018-07-16 Jim Wilson <jimw@sifive.com>
3244 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
3246 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3248 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
3250 (libunwind_frame_sniffer): Likewise.
3251 (libunwind_frame_prev_register): Likewise.
3252 (libunwind_sigtramp_frame_sniffer): Likewise.
3253 * ia64-tdep.c (ia64_access_reg): Likewise.
3254 (ia64_access_rse_reg): Likewise.
3255 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
3256 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
3258 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3260 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
3262 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3264 * remote-sim.c (gdbsim_target::close,
3265 gdbsim_target::mourn_inferior): Remove unused variables.
3267 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
3269 * ia64-tdep.c (ktab_buf): New global.
3270 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
3271 (get_kernel_table): Adjust.
3273 2018-07-16 Tom Tromey <tom@tromey.com>
3275 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
3276 * dwarf2read.c (using_directives, new_symbol): Use
3277 outermost_context_p.
3278 * dbxread.c (process_one_symbol): Use outermost_context_p.
3279 * coffread.c (coff_symtab_read): Use outermost_context_p.
3281 2018-07-16 Tom Tromey <tom@tromey.com>
3283 * dwarf2read.c (using_directives, read_func_scope)
3284 (read_lexical_block_scope): Update.
3285 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
3286 * buildsym.h (local_using_directives, global_using_directives):
3288 (get_local_using_directives, set_local_using_directives)
3289 (get_global_using_directives): Declare.
3290 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
3291 m_global_using_directives>: New members.
3292 (finish_block_internal, prepare_for_building)
3293 (reset_symtab_globals, end_symtab_get_static_block)
3294 (push_context): Update.
3295 (get_local_using_directives, set_local_using_directives)
3296 (get_global_using_directives): New functions.
3297 (buildsym_init): Update.
3299 2018-07-16 Tom Tromey <tom@tromey.com>
3301 * xcoffread.c (xcoff_initial_scan): Don't call
3302 free_pending_blocks.
3303 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
3304 * buildsym.h (class scoped_free_pendings): Add constructor.
3305 (free_pending_blocks): Don't declare.
3306 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
3307 (free_pending_blocks): Now static.
3309 2018-07-16 Tom Tromey <tom@tromey.com>
3311 * buildsym.h (push_subfile, pop_subfile): Update declarations.
3312 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
3314 (struct subfile_stack): Remove.
3315 (subfile_stack): Remove.
3316 (push_subfile, pop_subfile, buildsym_init): Update.
3318 2018-07-16 Tom Tromey <tom@tromey.com>
3320 * buildsym.c (push_subfile): Use gdb_assert.
3321 (pop_subfile): Use gdb_assert.
3323 2018-07-16 Tom Tromey <tom@tromey.com>
3325 * buildsym.h (merge_symbol_lists): Remove.
3326 * buildsym.c (merge_symbol_lists): Remove.
3328 2018-07-16 Tom Tromey <tom@tromey.com>
3330 * stabsread.c (scan_file_globals): Update comment.
3331 * stabsread.h (scan_file_globals): Move from buildsym.h.
3332 * buildsym.h (scan_file_globals): Move to stabsread.h.
3334 2018-07-16 Tom Tromey <tom@tromey.com>
3336 * xcoffread.c (xcoff_new_init): Update.
3337 * mipsread.c (mipscoff_new_init): Update.
3338 * mdebugread.c (mdebug_build_psymtabs): Update.
3339 * elfread.c (elf_new_init): Update.
3340 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
3341 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
3342 * buildsym.h (buildsym_new_init): Don't declare.
3343 * buildsym.c (buildsym_new_init): Remove.
3345 2018-07-16 Tom Tromey <tom@tromey.com>
3347 * stabsread.h (within_function): Move from buildsym.h.
3348 * stabsread.c (start_stabs): Clear within_function.
3349 * coffread.c (coff_start_symtab): Clear within_function.
3350 * buildsym.h (within_function): Move to stabsread.h.
3351 * buildsym.c (prepare_for_building): Update.
3353 2018-07-16 Tom Tromey <tom@tromey.com>
3355 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
3356 * dwarf2read.c (dwarf2_start_symtab): Don't set
3357 processing_gcc_compilation.
3358 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
3360 2018-07-16 Tom Tromey <tom@tromey.com>
3362 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
3363 (next_symbol_text_func): Move from buildsym.h.
3364 * stabsread.c (hashname): Move from buildsym.c.
3365 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
3366 (next_symbol_text_func, hashname): Move to stabsread.h.
3367 * buildsym.c: Don't include bcache.h
3368 (hashname): Move to stasbread.c.
3370 2018-07-16 Tom Tromey <tom@tromey.com>
3372 * buildsym.h (context_stack_size): Don't declare.
3373 * buildsym.c (context_stack_size): New global.
3375 2018-07-16 Tom Tromey <tom@tromey.com>
3377 * dbxread.c (processing_acc_compilation): New global.
3378 * buildsym.h (processing_acc_compilation): Don't declare.
3380 2018-07-16 Tom Tromey <tom@tromey.com>
3382 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
3383 * dbxread.c (read_ofile_symtab): Update.
3384 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
3385 * buildsym.h (last_source_start_addr): Remove.
3386 (set_last_source_start_addr, get_last_source_start_addr):
3388 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
3390 (struct buildsym_compunit) <m_last_source_start_addr>: New
3392 (prepare_for_building): Remove start_addr parameter.
3393 (start_symtab, restart_symtab, end_symtab_get_static_block)
3394 (end_symtab_with_blockvector): Update.
3395 (set_last_source_start_addr, get_last_source_start_addr): New
3398 2018-07-16 Tom Tromey <tom@tromey.com>
3400 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
3402 (have_line_numbers): Remove.
3403 (record_line, prepare_for_building, end_symtab_get_static_block)
3404 (augment_type_symtab): Update.
3406 2018-07-16 Tom Tromey <tom@tromey.com>
3408 * buildsym.c (~buildsym_compunit): Free the macro table.
3409 (struct buildsym_compunit) <get_macro_table, release_macros>: New
3411 <m_pending_macros>: New member.
3412 (pending_macros): Remove.
3413 (~scoped_free_pendings, get_macro_table, prepare_for_building)
3414 (reset_symtab_globals, end_symtab_get_static_block)
3415 (end_symtab_with_blockvector, augment_type_symtab)
3416 (buildsym_init): Update.
3418 2018-07-16 Tom Tromey <tom@tromey.com>
3420 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
3422 (buildsym_compunit::set_last_source_file): New method.
3423 <m_last_source_file>: New member.
3424 (prepare_for_building): Remove "name" parameter.
3425 (start_symtab, restart_symtab, reset_symtab_globals): Update.
3426 (last_source_file): Remove.
3427 (set_last_source_file, get_last_source_file): Update.
3429 2018-07-16 Tom Tromey <tom@tromey.com>
3431 * buildsym.c (prepare_for_building): Add assert.
3433 2018-07-16 Tom Tromey <tom@tromey.com>
3435 * buildsym.c (~buildsym_compunit): Update.
3436 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
3437 (start_subfile, patch_subfile_names)
3438 (end_symtab_with_blockvector): Update.
3440 2018-07-16 Tom Tromey <tom@tromey.com>
3442 * buildsym.c (struct buildsym_compunit): Add constructor,
3443 destructor, initializers.
3444 (start_buildsym_compunit): Remove.
3445 (free_buildsym_compunit): Use "delete".
3446 (start_symtab, restart_symtab): Use "new".
3448 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
3450 * symfile.c (set_objfile_default_section_offset): Remove struct
3453 2018-07-14 Stafford Horne <shorne@gmail.com>
3455 * (Responsible Maintainers): Add myself as or1k maintainer.
3457 2018-07-13 Tom Tromey <tom@tromey.com>
3459 * symfile.c (set_objfile_default_section_offset): Use extra braces
3462 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
3464 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
3467 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3469 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3470 unittests/cli-utils-selftests.c
3471 * unittests/cli-utils-selftests.c: New file.
3473 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3475 * NEWS: Mention new commands. Mention change to 'thread apply'.
3477 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3479 * thread.c (thr_try_catch_cmd): New function.
3480 (thread_apply_all_command): Handle qcs flags.
3481 (thread_apply_command): Handle qcs flags.
3482 (taas_command): New function.
3483 (tfaas_command): New function.
3484 (_initialize_thread): Update to setup the new commands 'taas
3485 and 'tfaas'. Change doc string for 'thread apply'.
3487 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3489 * stack.c: (trailing_outermost_frame): New function, mostly
3490 extracted from backtrace_command_1.
3491 (leading_innermost_frame): New function.
3492 (backtrace_command_1): Update to call trailing_outermost_frame.
3493 (frame_apply_command_count): New function.
3494 (frame_apply_level_command): New function.
3495 (frame_apply_all_command): New function.
3496 (frame_apply_command): New function.
3497 (faas_command): New function.
3498 (frame_cmd_list): New variable.
3499 (_initialize_stack): Update to setup the new commands 'frame apply'
3502 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3504 * cli-utils.c (number_or_range_parser::get_number): Only handle
3505 numbers or convenience var as numbers.
3506 (parse_flags): New function.
3507 (parse_flags_qcs): New function.
3508 (number_or_range_parser::finished): Ensure parsing end is detected
3509 before end of string.
3510 * cli-utils.h (parse_flags): New function.
3511 (parse_flags_qcs): New function.
3512 (number_or_range_parser): Remove m_finished bool.
3513 (number_or_range_parser::skip_range): Set m_in_range to false.
3515 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
3517 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
3520 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3521 Jan Kratochvil <jan.kratochvil@redhat.com>
3522 Paul Fertser <fercerpav@gmail.com>
3523 Tsutomu Seki <sekiriki@gmail.com>
3524 Pedro Alves <palves@redhat.com>
3526 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3527 'unittests/parse-connection-spec-selftests.c'.
3528 (COMMON_SFILES): Add 'common/netstuff.c'.
3529 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
3530 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
3531 * common/netstuff.c: New file.
3532 * common/netstuff.h: New file.
3533 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
3534 (wait_for_connect): Update comment. New parameter
3535 'gdb::optional<int> sock' instead of 'struct serial *scb'.
3536 Use 'sock' directly instead of 'scb->fd'.
3537 (try_connect): New function, with code from 'net_open'.
3538 (net_open): Rewrite main loop to deal with multiple
3539 sockets/addresses. Handle IPv6-style hostnames; implement
3540 support for IPv6 connections.
3541 * unittests/parse-connection-spec-selftests.c: New file.
3543 2018-07-11 Pedro Alves <palves@redhat.com>
3546 * remote.c (remote_target::remote_detach_pid): Call
3547 set_current_process.
3549 2018-07-11 Pedro Alves <palves@redhat.com>
3551 * h8300-tdep.c (h8300_gdbarch_init): Remove
3552 set_gdbarch_ecoff_reg_to_regnum calls.
3554 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3557 * c-typeprint.c (c_type_print_base_struct_union): Don't print
3558 offsets/sizes for static members of a class/struct.
3560 2018-07-11 Alan Hayward <alan.hayward@arm.com>
3562 * target-descriptions.c (tdesc_register_bitsize): Rename.
3563 * target-descriptions.h (tdesc_register_bitsize): Likewise.
3564 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
3565 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
3567 2018-07-10 Tom Tromey <tom@tromey.com>
3569 * breakpoint.c (moribund_locations): Now static and a
3571 (breakpoint_init_inferior, moribund_breakpoint_here_p)
3572 (build_bpstat_chain, update_global_location_list)
3573 (breakpoint_retire_moribund): Update.
3574 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
3577 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
3579 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
3580 (riscv_register_reggroup_p): Use new function, remove unneeded
3582 (riscv_push_dummy_call): Extend assert to compare against xlen or
3583 flen based on register type.
3585 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
3587 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
3589 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
3591 * remote.c (show_hardware_watchpoint_limit): New function.
3592 (show_hardware_watchpoint_length_limit): New function.
3593 (show_hardware_breakpoint_limit): New function.
3594 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
3595 where appropriate, update help text.
3597 2018-07-09 Tom Tromey <tom@tromey.com>
3599 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
3600 (CLIBS): Don't mention NAT_CLIBS.
3602 2018-07-09 Tom Tromey <tom@tromey.com>
3604 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
3605 (LIBGDB_OBS, clean mostlyclean): Update.
3606 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
3608 2018-07-09 Tom Tromey <tom@tromey.com>
3610 * Makefile.in (%.c: %.y): Use ECHO_YACC.
3611 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
3612 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
3614 2018-07-09 Tom Tromey <tom@tromey.com>
3616 * Makefile.in (ALLDEPFILES): Remove exec.c.
3617 (COMMON_OBS): Remove exec.o.
3618 (COMMON_SFILES): Add exec.c.
3620 2018-07-09 Tom Tromey <tom@tromey.com>
3622 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
3624 2018-07-09 Tom Tromey <tom@tromey.com>
3626 * Makefile.in (clean mostlyclean): Remove stamp-version.
3627 (version.c): Depend on stamp-version.
3628 (stamp-version): New rule, from version.c rule.
3630 2018-07-09 Tom Tromey <tom@tromey.com>
3632 * Makefile.in (init.c): Depend on stamp-init.
3633 (stamp-init): New rule, from init.c rule.
3634 (clean mostlyclean): Remove stamp-init.
3636 2018-07-09 Tom Tromey <tom@tromey.com>
3638 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
3639 SUBDIR_GCC_COMPILE_SRCS.
3641 2018-07-09 Tom Tromey <tom@tromey.com>
3643 * Makefile.in (init.c): Remove some unused sed rules.
3645 2018-07-09 Tom Tromey <tom@tromey.com>
3647 * Makefile.in (TSOBS): Remove.
3648 (INIT_FILES): Update.
3649 (LIBGDB_OBS): Update.
3650 (COMMON_SFILES): Add inflow.c.
3651 (SFILES): Remove inflow.c.
3653 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
3655 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
3657 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
3659 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
3660 get_saveloc_name, is_signal_frame_name, step_name,
3661 init_remote_name, create_addr_space_name,
3662 destroy_addr_space_name, search_unwind_table_name,
3663 find_dyn_list_name): Constify.
3665 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
3667 * darwin-nat.c (darwin_pthread_kill): New function.
3668 (darwin_resume_thread): Use darwin_pthread_kill.
3670 2018-07-05 Tom de Vries <tdevries@suse.de>
3672 * macroexp.c (macro_buffer) <operator=>: New member function.
3674 2018-07-04 Tom Tromey <tom@tromey.com>
3676 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
3678 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
3680 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
3681 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
3682 * maint.c: Likewise.
3685 2018-07-04 Joel Brobecker <brobecker@adacore.com>
3687 * NEWS: Create a new section for the next release branch.
3688 Rename the section of the current branch, now that it has
3691 2018-07-04 Joel Brobecker <brobecker@adacore.com>
3693 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
3694 * version.in: Bump version to 8.2.50.DATE-git.
3696 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
3697 Pedro Alves <palves@redhat.com>
3699 * linux-nat.c (linux_init_ptrace): Rename to ...
3700 (linux_init_ptrace_procfs): ... this. Call
3701 linux_proc_init_warnings.
3702 (linux_nat_target::post_attach)
3703 (linux_nat_target::post_startup_inferior): Adjust.
3704 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
3705 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
3707 2018-07-04 Tom de Vries <tdevries@suse.de>
3709 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
3711 (read_comp_unit_head): ... here.
3713 2018-07-03 Tom Tromey <tom@tromey.com>
3715 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
3716 (stop_tracing, tstatus_command)
3717 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
3718 (print_one_static_tracepoint_marker): Update.
3719 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
3721 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
3723 (all_tracepoints, static_tracepoints_here): Return std::vector.
3725 2018-07-03 Tom Tromey <tom@tromey.com>
3727 * common/ptid.c (ptid_equal): Remove.
3728 * common/ptid.h (ptid_equal): Don't declare.
3729 * ada-tasks.c: Update.
3730 * breakpoint.c: Update.
3731 * common/agent.c: Update.
3732 * corelow.c: Update.
3733 * darwin-nat-info.c: Update.
3734 * darwin-nat.c: Update.
3736 * dtrace-probe.c: Update.
3737 * dummy-frame.c: Update.
3738 * fbsd-nat.c: Update.
3740 * gdbthread.h: Update.
3741 * gnu-nat.c: Update.
3742 * go32-nat.c: Update.
3743 * inf-loop.c: Update.
3744 * inf-ptrace.c: Update.
3745 * infcall.c: Update.
3749 * linux-fork.c: Update.
3750 * linux-nat.c: Update.
3751 * linux-thread-db.c: Update.
3752 * mi/mi-cmd-var.c: Update.
3753 * mi/mi-interp.c: Update.
3754 * mi/mi-main.c: Update.
3755 * nto-procfs.c: Update.
3756 * ppc-linux-tdep.c: Update.
3758 * python/py-inferior.c: Update.
3759 * python/py-record-btrace.c: Update.
3760 * python/py-record.c: Update.
3761 * ravenscar-thread.c: Update.
3762 * regcache.c: Update.
3763 * remote-sim.c: Update.
3765 * sol-thread.c: Update.
3768 * tui/tui-stack.c: Update.
3770 * windows-nat.c: Update.
3771 * windows-tdep.c: Update.
3773 2018-07-03 Tom Tromey <tom@tromey.com>
3775 * common/ptid.c (ptid_match): Remove.
3776 * common/ptid.h (ptid_match): Don't declare.
3777 * fbsd-nat.c: Update.
3780 * linux-nat.c: Update.
3781 * record-btrace.c: Update.
3782 * regcache.c: Update.
3785 2018-07-03 Tom Tromey <tom@tromey.com>
3787 * common/ptid.c (ptid_tid_p): Remove.
3788 * common/ptid.h (ptid_tid_p): Don't declare.
3789 * sol-thread.c: Update.
3791 2018-07-03 Tom Tromey <tom@tromey.com>
3793 * common/ptid.c (ptid_lwp_p): Remove.
3794 * common/ptid.h (ptid_lwp_p): Don't declare.
3795 * fbsd-nat.c: Update.
3796 * linux-nat.c: Update.
3797 * nat/linux-procfs.c: Update.
3798 * nat/x86-linux-dregs.c: Update.
3799 * sol-thread.c: Update.
3801 2018-07-03 Tom Tromey <tom@tromey.com>
3803 * common/ptid.c (ptid_is_pid): Remove.
3804 * common/ptid.h (ptid_is_pid): Don't declare.
3806 * linux-nat.c: Update.
3807 * mi/mi-interp.c: Update.
3811 2018-07-03 Tom Tromey <tom@tromey.com>
3813 * common/ptid.c (ptid_get_tid): Remove.
3814 * common/ptid.h (ptid_get_tid): Don't declare.
3815 * ada-tasks.c: Update.
3816 * aix-thread.c: Update.
3817 * bsd-uthread.c: Update.
3818 * darwin-nat.c: Update.
3819 * fbsd-nat.c: Update.
3820 * i386-darwin-nat.c: Update.
3822 * linux-tdep.c: Update.
3823 * nto-procfs.c: Update.
3824 * ppc-ravenscar-thread.c: Update.
3825 * python/py-infthread.c: Update.
3826 * ravenscar-thread.c: Update.
3827 * sol-thread.c: Update.
3828 * sparc-ravenscar-thread.c: Update.
3829 * windows-nat.c: Update.
3831 2018-07-03 Tom Tromey <tom@tromey.com>
3833 * common/ptid.c (ptid_get_lwp): Remove.
3834 * common/ptid.h (ptid_get_lwp): Don't declare.
3835 * aarch64-linux-nat.c: Update.
3836 * ada-tasks.c: Update.
3837 * aix-thread.c: Update.
3838 * amd64-linux-nat.c: Update.
3839 * arm-linux-nat.c: Update.
3840 * corelow.c: Update.
3841 * fbsd-nat.c: Update.
3842 * fbsd-tdep.c: Update.
3843 * gnu-nat.c: Update.
3844 * i386-cygwin-tdep.c: Update.
3845 * i386-gnu-nat.c: Update.
3846 * i386-linux-nat.c: Update.
3847 * ia64-linux-nat.c: Update.
3848 * inf-ptrace.c: Update.
3850 * linux-fork.c: Update.
3851 * linux-nat.c: Update.
3852 * linux-tdep.c: Update.
3853 * linux-thread-db.c: Update.
3854 * mips-linux-nat.c: Update.
3855 * nat/aarch64-linux-hw-point.c: Update.
3856 * nat/aarch64-linux.c: Update.
3857 * nat/linux-btrace.c: Update.
3858 * nat/linux-osdata.c: Update.
3859 * nat/linux-procfs.c: Update.
3860 * nat/x86-linux-dregs.c: Update.
3861 * obsd-nat.c: Update.
3862 * ppc-fbsd-nat.c: Update.
3863 * ppc-linux-nat.c: Update.
3865 * python/py-infthread.c: Update.
3866 * ravenscar-thread.c: Update.
3868 * s390-linux-nat.c: Update.
3869 * sol-thread.c: Update.
3870 * sol2-tdep.c: Update.
3871 * spu-linux-nat.c: Update.
3872 * x86-linux-nat.c: Update.
3873 * xtensa-linux-nat.c: Update.
3875 2018-07-03 Tom Tromey <tom@tromey.com>
3877 * common/ptid.c (ptid_get_pid): Remove.
3878 * common/ptid.h (ptid_get_pid): Don't declare.
3879 * aarch64-linux-nat.c: Update.
3880 * ada-lang.c: Update.
3881 * aix-thread.c: Update.
3882 * alpha-bsd-nat.c: Update.
3883 * amd64-fbsd-nat.c: Update.
3884 * amd64-linux-nat.c: Update.
3885 * arm-linux-nat.c: Update.
3886 * arm-nbsd-nat.c: Update.
3888 * break-catch-syscall.c: Update.
3889 * breakpoint.c: Update.
3890 * bsd-uthread.c: Update.
3891 * corelow.c: Update.
3893 * darwin-nat.c: Update.
3894 * fbsd-nat.c: Update.
3895 * fbsd-tdep.c: Update.
3897 * gnu-nat.c: Update.
3898 * hppa-nbsd-nat.c: Update.
3899 * hppa-obsd-nat.c: Update.
3900 * i386-fbsd-nat.c: Update.
3901 * ia64-linux-nat.c: Update.
3902 * inf-ptrace.c: Update.
3904 * inferior.c: Update.
3905 * inferior.h: Update.
3908 * linux-fork.c: Update.
3909 * linux-nat.c: Update.
3910 * linux-tdep.c: Update.
3911 * linux-thread-db.c: Update.
3912 * m68k-bsd-nat.c: Update.
3913 * mi/mi-interp.c: Update.
3914 * mi/mi-main.c: Update.
3915 * mips-linux-nat.c: Update.
3916 * mips-nbsd-nat.c: Update.
3917 * mips64-obsd-nat.c: Update.
3918 * nat/aarch64-linux-hw-point.c: Update.
3919 * nat/aarch64-linux.c: Update.
3920 * nat/linux-btrace.c: Update.
3921 * nat/linux-osdata.c: Update.
3922 * nat/linux-procfs.c: Update.
3923 * nat/x86-linux-dregs.c: Update.
3924 * nto-procfs.c: Update.
3925 * obsd-nat.c: Update.
3926 * ppc-linux-nat.c: Update.
3927 * ppc-nbsd-nat.c: Update.
3928 * ppc-obsd-nat.c: Update.
3929 * proc-service.c: Update.
3931 * python/py-inferior.c: Update.
3932 * python/py-infthread.c: Update.
3933 * ravenscar-thread.c: Update.
3935 * remote-sim.c: Update.
3937 * rs6000-nat.c: Update.
3938 * s390-linux-nat.c: Update.
3939 * sh-nbsd-nat.c: Update.
3940 * sol-thread.c: Update.
3941 * sparc-nat.c: Update.
3942 * sparc64-tdep.c: Update.
3943 * spu-linux-nat.c: Update.
3944 * spu-tdep.c: Update.
3945 * target-debug.h: Update.
3948 * tid-parse.c: Update.
3949 * tracefile-tfile.c: Update.
3950 * vax-bsd-nat.c: Update.
3951 * windows-nat.c: Update.
3952 * x86-linux-nat.c: Update.
3953 * x86-nat.c: Update.
3955 2018-07-03 Tom Tromey <tom@tromey.com>
3957 * common/ptid.c (pid_to_ptid): Remove.
3958 * common/ptid.h (pid_to_ptid): Don't declare.
3959 * aix-thread.c: Update.
3960 * arm-linux-nat.c: Update.
3961 * common/ptid.c: Update.
3962 * common/ptid.h: Update.
3963 * corelow.c: Update.
3965 * darwin-nat.c: Update.
3966 * fbsd-nat.c: Update.
3967 * fork-child.c: Update.
3968 * gnu-nat.c: Update.
3969 * go32-nat.c: Update.
3970 * inf-ptrace.c: Update.
3972 * inferior.c: Update.
3974 * linux-fork.c: Update.
3975 * linux-nat.c: Update.
3976 * nat/aarch64-linux-hw-point.c: Update.
3977 * nat/fork-inferior.c: Update.
3978 * nat/x86-linux-dregs.c: Update.
3979 * nto-procfs.c: Update.
3980 * obsd-nat.c: Update.
3982 * progspace.c: Update.
3984 * rs6000-nat.c: Update.
3985 * s390-linux-nat.c: Update.
3986 * sol-thread.c: Update.
3987 * spu-linux-nat.c: Update.
3990 * tracefile-tfile.c: Update.
3991 * windows-nat.c: Update.
3993 2018-07-03 Tom Tromey <tom@tromey.com>
3995 * common/ptid.h (ptid_build): Don't declare.
3996 * common/ptid.c (ptid_build): Remove.
3997 * aix-thread.c: Update.
3998 * bsd-kvm.c: Update.
3999 * bsd-uthread.c: Update.
4000 * common/agent.c: Update.
4001 * common/ptid.c: Update.
4002 * common/ptid.h: Update.
4003 * corelow.c: Update.
4004 * darwin-nat.c: Update.
4005 * fbsd-nat.c: Update.
4006 * gnu-nat.c: Update.
4007 * linux-fork.c: Update.
4008 * linux-nat.c: Update.
4009 * linux-thread-db.c: Update.
4010 * nat/linux-osdata.c: Update.
4011 * nat/linux-procfs.c: Update.
4012 * nto-procfs.c: Update.
4013 * obsd-nat.c: Update.
4014 * proc-service.c: Update.
4016 * ravenscar-thread.c: Update.
4017 * remote-sim.c: Update.
4019 * sol-thread.c: Update.
4021 * windows-nat.c: Update.
4023 2018-07-03 Tom Tromey <tom@tromey.com>
4025 * infrun.c (follow_exec): Use exit_inferior_silent.
4026 * inferior.c (exit_inferior_num_silent): Remove.
4027 * inferior.h (exit_inferior_num_silent): Don't declare.
4029 2018-07-03 Tom Tromey <tom@tromey.com>
4032 * darwin-nat.c (darwin_attach_pid): Reset inferior and
4033 inferior_ptid on error.
4035 2018-07-02 Maciej W. Rozycki <macro@mips.com>
4036 Simon Marchi <simon.marchi@polymtl.ca>
4039 * disasm.h (gdb_disassembler): Add
4040 `m_disassembler_options_holder'. member
4041 * disasm.c (get_all_disassembler_options): New function.
4042 (gdb_disassembler::gdb_disassembler): Use it.
4043 (gdb_buffered_insn_length_init_dis): Likewise.
4044 (gdb_buffered_insn_length): Adjust accordingly.
4045 (set_disassembler_options): Handle options with arguments.
4046 (show_disassembler_options_sfunc): Likewise. Add a leading new
4047 line if showing options with descriptions.
4048 (disassembler_options_completer): Adapt to using the
4049 `disasm_options_and_args_t' structure.
4050 * mips-tdep.c (mips_disassembler_options): New variable.
4051 (mips_disassembler_options_o32): Likewise.
4052 (mips_disassembler_options_n32): Likewise.
4053 (mips_disassembler_options_n64): Likewise.
4054 (gdb_print_insn_mips): Don't set `disassembler_options'.
4055 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
4057 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
4058 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
4059 `gdbarch_disassembler_options_implicit' and
4060 `gdbarch_valid_disassembler_options'.
4061 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
4062 `disasm_options_and_args_t' structure.
4063 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
4065 (valid_disassembler_options): Switch from `disasm_options_t' to
4066 the `disasm_options_and_args_t' structure.
4067 * NEWS: Document `set disassembler-options' support for the MIPS
4069 * gdbarch.h: Regenerate.
4070 * gdbarch.c: Regenerate.
4072 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
4074 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
4076 2018-06-29 Joel Brobecker <brobecker@adacore.com>
4078 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
4079 parameter in call to amd64_target_description.
4080 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
4081 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
4082 (amd64fbsd_init_abi): Likewise.
4083 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
4084 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
4085 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
4086 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
4088 2018-06-29 Pedro Alves <palves@redhat.com>
4090 * gdb/amd64-tdep.h (amd64_create_target_description): Add
4091 "segments" parameter.
4092 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
4093 (_initialize_amd64_tdep): Update call to
4094 amd64_create_target_description.
4095 (amd64_target_description): Add "segments" parameter. Adjust
4096 the implementation to use it.
4097 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
4098 call to amd64_create_target_description.
4099 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
4100 * gdb/arch/amd64.h (amd64_create_target_description): Add
4101 "segments" register.
4102 * gdb/arch/amd64.c (amd64_create_target_description): Add
4103 "segments" parameter. Call create_feature_i386_64bit_segments
4104 only if SEGMENTS is true.
4105 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
4106 call to amd64_create_target_description.
4108 2018-06-29 Pedro Alves <palves@redhat.com>
4110 * thread.c (thread_target_id_str): New, factored out from ...
4111 (print_thread_info_1): ... here. Use it to compute the max
4112 "Target Id" column width.
4114 2018-06-29 Pedro Alves <palves@redhat.com>
4116 * remote.c (remote_target::extra_thread_info): Delete
4117 'display_buf' and 'n' locals. from the cache, regardless of
4118 packet mechanims is in use. Use cache for qThreadExtra and qP
4121 2018-06-29 Pedro Alves <palves@redhat.com>
4123 * blockframe.c (find_pc_sect_containing_function): New function.
4124 * breakpoint.c (print_breakpoint_location): Don't call
4125 find_pc_sect_function.
4126 * linespec.c (create_sals_line_offset): Record the location's
4128 * linespec.c (convert_address_location_to_sals): Fill in sal's
4129 symbol with find_pc_sect_containing_function.
4130 * symtab.c (find_function_start_sal): Rename to ...
4131 (find_function_start_sal_1): ... this.
4132 (find_function_start_sal): Reimplement as wrapper around
4133 find_function_start_sal_1, and use
4134 find_pc_sect_containing_function to fill in the sal's symbol.
4135 (find_function_start_sal(symbol*, bool)): Adjust.
4136 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
4138 (find_pc_sect_containing_function): Declare.
4140 2018-06-29 Pedro Alves <palves@redhat.com>
4142 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
4143 true if the the location has no symbol.
4145 2018-06-28 Tom Tromey <tom@tromey.com>
4147 * NEWS: Mention --enable-codesign.
4148 * silent-rules.mk (ECHO_SIGN): New variable.
4149 * configure.ac: Add --enable-codesign.
4150 * configure: Rebuild.
4151 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
4152 (gdb$(EXEEXT)): Optionally invoke codesign.
4154 2018-06-28 Pedro Alves <palves@redhat.com>
4156 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
4158 (switch_to_thread_no_regs): Adjust comment.
4159 * infcmd.c (stop_pc): Delete.
4160 (post_create_inferior, info_program_command): Replace references
4161 to stop_pc with references to thread_info->suspend.stop_pc.
4162 * inferior.h (stop_pc): Delete declaration.
4163 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
4164 (handle_inferior_event_1, handle_signal_stop)
4165 (process_event_stop_test, keep_going_stepped_thread)
4166 (handle_step_into_function, handle_step_into_function_backward)
4167 (print_stop_location): Replace references to stop_pc with
4168 references to thread_info->suspend.stop_pc.
4169 (struct infcall_suspend_state) <stop_pc>: Delete field.
4170 (save_infcall_suspend_state, restore_infcall_suspend_state):
4171 Remove references to inf_stat->stop_pc.
4172 * linux-fork.c (fork_load_infrun_state): Likewise.
4173 * record-btrace.c (record_btrace_set_replay): Likewise.
4174 * record-full.c (record_full_goto_entry): Likewise.
4175 * remote.c (print_one_stopped_thread): Likewise.
4176 * target.c (target_resume): Extend comment.
4177 * thread.c (set_executing_thread): New.
4178 (set_executing): Use it.
4179 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
4180 Remove references to stop_pc.
4182 2018-06-28 Pedro Alves <palves@redhat.com>
4184 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
4185 Moving fetching stop_pc until after ecs->event_thread is refreshed.
4187 2018-06-28 Tom Tromey <tom@tromey.com>
4189 * coffread.c (coff_symfile_finish): Update.
4190 * xcoffread.c (xcoff_symfile_finish): Update.
4191 * elfread.c (elf_symfile_finish): Update.
4192 * symfile.h (dwarf2_free_objfile): Don't declare.
4193 * dwarf2read.c (_initialize_dwarf2_read): Use
4194 register_objfile_data_with_cleanup.
4195 (dwarf2_free_objfile): Now static. Change signature.
4197 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4199 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
4200 option "-o" to add-symbol-file-load to add an offset to each
4201 section's load address.
4202 * symfile.c (set_objfile_default_section_offset): New function.
4204 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4206 * symfile.c (add_symbol_file_command): Make sure that sections
4207 with the same name are sorted in the same order.
4209 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4211 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
4212 require the second argument. If omitted, load sections at the
4213 addresses specified in the file.
4215 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4217 * symfile.c (symbol_file_command, symbol_file_add_main_1)
4218 (_initialize_symfile): Add option "-o" to symbol-file to add an
4219 offset to each section of the symbol file.
4221 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4223 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
4225 2018-06-27 Tom Tromey <tom@tromey.com>
4227 * stack.c (_initialize_stack): Update "func" help text.
4229 2018-06-27 Tom Tromey <tom@tromey.com>
4231 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
4233 (unwind_infopy_str, pyuw_create_unwind_info)
4234 (unwind_infopy_add_saved_register, pyuw_sniffer)
4235 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
4237 (struct saved_reg): Add constructor.
4238 <value>: Now a gdbpy_ref<>.
4240 2018-06-27 Tom Tromey <tom@tromey.com>
4242 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
4244 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4246 * gdb-gdb.py.in: Format using autopep8.
4248 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4250 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
4251 (type_lookup_function): Recognize CORE_ADDR values.
4253 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4255 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
4258 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4260 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
4263 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4265 * gdb-gdb.py: Move to...
4266 * gdb-gdb.py.in: ... here.
4267 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
4268 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
4270 (distclean): Remove gdb-gdb.py when cleaning.
4271 (gdb-gdb.py, gdb-gdb.gdb): New rules.
4272 * configure: Re-generate.
4274 2018-06-27 Pedro Alves <palves@redhat.com>
4276 * proc-service.c (get_ps_regcache): New.
4277 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
4278 (ps_lsetfpregs): Use it.
4280 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
4283 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
4284 (dwarf_decode_lines_1): Adjust.
4286 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4288 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
4290 <info_proc>: Likewise.
4292 2018-06-26 Joel Brobecker <brobecker@adacore.com>
4294 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
4295 to windows_fetch_one_register, and only handle the case of
4296 fetching one register. Move the code that reloads the context
4297 and iterates over all registers if R is negative to...
4298 (windows_nat_target::fetch_registers): ... here.
4299 (do_windows_store_inferior_registers): Rename to
4300 windows_store_one_register, and only handle the case of storing
4301 one register. Move the code that handles the case where r is
4303 (windows_nat_target::store_registers) ... here.
4305 2018-06-26 Tom Tromey <tom@tromey.com>
4308 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
4309 * rust-lang.c (rust_print_struct_def): Add podata parameter.
4311 (rust_internal_print_type): Add podata parameter.
4312 (rust_print_type): Update.
4314 2018-06-26 Tom Tromey <tom@tromey.com>
4316 * typeprint.h (struct print_offset_data) <update, finish,
4317 maybe_print_hole>: New methods.
4318 <indentation>: New constant.
4319 * typeprint.c (print_offset_data::indentation): Define.
4320 (print_offset_data::maybe_print_hole, print_offset_data::update)
4321 (print_offset_data::finish): Move from c-typeprint.c and rename.
4322 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
4323 (print_spaces_filtered_with_print_options): Update.
4324 (c_print_type_union_field_offset, maybe_print_hole)
4325 (c_print_type_struct_field_offset): Move to typeprint.c and
4327 (c_type_print_base_struct_union): Update.
4329 2018-06-25 Pedro Alves <palves@redhat.com>
4331 * gdbthread.h (thread_info_ref, delete_thread)
4332 (delete_thread_silent, first_thread_of_inferior)
4333 (any_thread_of_inferior, switch_to_thread)
4334 (enable_thread_stack_temporaries)
4335 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4336 (get_last_thread_stack_temporary)
4337 (value_in_thread_stack_temporaries, can_access_registers_thread):
4338 Spell out "struct thread_info" instead of just "thread_info".
4339 * inferior.h (notice_new_inferior): Likewise.
4341 2018-06-25 Pedro Alves <palves@redhat.com>
4343 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4344 pass thread_info pointer to delete_thread.
4345 (windows_nat_target::detach): Pass inferior pointer to
4347 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
4349 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
4350 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
4351 and pass a thread_info pointer to delete_thread.
4352 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
4353 pass thread_info pointer to delete_thread.
4354 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
4355 delete_thread_silent call.
4356 * procfs.c (procfs_target::detach): Pass inferior pointer to
4358 (procfs_target::wait): Pass thread_info pointer to delete_thread.
4359 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
4360 delete_thread_silent call.
4361 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4362 pass thread_info pointer to delete_thread.
4363 (windows_nat_target::detach): Pass inferior pointer to
4366 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4368 * regcache.c (readable_regcache::read_part): Fix asserts.
4369 (reg_buffer::raw_collect_part): New function.
4370 (regcache::write_part): Fix asserts.
4371 (reg_buffer::raw_supply_part): New function.
4372 (regcache::transfer_regset_register): New helper function.
4373 (regcache::transfer_regset): Call new functions.
4374 (regcache_supply_regset): Use gdb_byte*.
4375 (regcache::supply_regset): Likewise.
4376 (regcache_collect_regset): Likewise.
4377 (regcache::collect_regset): Likewise.
4378 * regcache.h (reg_buffer::raw_collect_part): New declaration.
4379 (reg_buffer::raw_supply_part): Likewise.
4380 (regcache::transfer_regset_register): Likewise.
4381 (regcache::transfer_regset): Use gdb_byte*.
4383 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4385 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
4387 2018-06-21 Pedro Alves <palves@redhat.com>
4389 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
4390 instead of a ptid_t. All callers adjusted.
4391 * ada-tasks.c (ada_get_task_number): Likewise. All callers
4393 (print_ada_task_info, display_current_task_id, task_command_1):
4395 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
4397 (breakpoint_kind): Adjust.
4398 (remove_breakpoints_pid): Rename to ...
4399 (remove_breakpoints_inf): ... this. Adjust to take an inferior
4400 pointer. All callers adjusted.
4401 (bpstat_clear_actions): Use inferior_thread.
4402 (get_bpstat_thread): New.
4403 (bpstat_do_actions): Use it.
4404 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
4405 to take a thread_info pointer. All callers adjusted.
4406 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
4407 (breakpoint_re_set_thread): Use inferior_thread.
4408 * breakpoint.h (struct inferior): Forward declare.
4409 (bpstat_stop_status): Update.
4410 (remove_breakpoints_pid): Delete.
4411 (remove_breakpoints_inf): New.
4412 * bsd-uthread.c (bsd_uthread_target::wait)
4413 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
4414 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
4415 (maint_btrace_packet_history_cmd)
4416 (maint_btrace_clear_packet_history_cmd): Adjust.
4417 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
4419 * cli/cli-interp.c: Include "inferior.h".
4420 * common/refcounted-object.h (struct
4421 refcounted_object_ref_policy): New.
4422 * compile/compile-object-load.c: Include gdbthread.h.
4423 (store_regs): Use inferior_thread.
4424 * corelow.c (core_target::close): Use current_inferior.
4425 (core_target_open): Adjust to use first_thread_of_inferior and use
4426 the current inferior.
4427 * ctf.c (ctf_target::close): Adjust to use current_inferior.
4428 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
4429 <thread>: ... this new field. All references adjusted.
4430 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
4431 Take a thread_info pointer instead of a ptid_t.
4432 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
4433 (dummy_frame_discard, register_dummy_frame_dtor): Take a
4434 thread_info pointer instead of a ptid_t.
4435 * elfread.c: Include "inferior.h".
4436 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
4437 Use inferior_thread.
4438 * eval.c (evaluate_subexp): Likewise.
4439 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
4441 * gdb_proc_service.h (struct thread_info): Forward declare.
4442 (struct ps_prochandle) <ptid>: Delete, replaced by ...
4443 <thread>: ... this new field. All references adjusted.
4444 * gdbarch.h, gdbarch.c: Regenerate.
4445 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
4446 'thread' parameter. All implementations and callers adjusted.
4447 * gdbthread.h (thread_info) <set_running>: New method.
4448 (delete_thread, delete_thread_silent): Take a thread_info pointer
4450 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
4451 (first_thread_of_process): Delete, replaced by ...
4452 (first_thread_of_inferior): ... this new function. All callers
4454 (any_live_thread_of_process): Delete, replaced by ...
4455 (any_live_thread_of_inferior): ... this new function. All callers
4457 (switch_to_thread, switch_to_no_thread): Declare.
4458 (is_executing): Delete.
4459 (enable_thread_stack_temporaries): Update comment.
4460 <enable_thread_stack_temporaries>: Take a thread_info pointer
4461 instead of a ptid_t. Incref the thread.
4462 <~enable_thread_stack_temporaries>: Decref the thread.
4465 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4466 (get_last_thread_stack_temporary)
4467 (value_in_thread_stack_temporaries, can_access_registers_thread):
4468 Take a thread_info pointer instead of a ptid_t. All callers
4470 * infcall.c (get_call_return_value): Use inferior_thread.
4471 (run_inferior_call): Work with thread pointers instead of ptid_t.
4472 (call_function_by_hand_dummy): Work with thread pointers instead
4473 of ptid_t. Use thread_info_ref.
4474 * infcmd.c (proceed_thread_callback): Access thread's state
4476 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
4477 access thread's state directly.
4478 (continue_command): Use inferior_thread.
4479 (info_program_command): Use find_thread_ptid and access thread
4481 (proceed_after_attach_callback): Use thread state directly.
4482 (notice_new_inferior): Take a thread_info pointer instead of a
4483 ptid_t. All callers adjusted.
4484 (exit_inferior): Take an inferior pointer instead of a pid. All
4486 (exit_inferior_silent): New.
4487 (detach_inferior): Delete.
4488 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
4489 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
4490 (detach_inferior_command, kill_inferior_command): Use
4491 find_inferior_id instead of valid_gdb_inferior_id and
4492 gdb_inferior_id_to_pid.
4493 (inferior_command): Use inferior and thread pointers.
4494 * inferior.h (struct thread_info): Forward declare.
4495 (notice_new_inferior): Take a thread_info pointer instead of a
4496 ptid_t. All callers adjusted.
4497 (detach_inferior): Delete declaration.
4498 (exit_inferior, exit_inferior_silent): Take an inferior pointer
4499 instead of a pid. All callers adjusted.
4500 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
4501 (valid_gdb_inferior_id): Delete.
4502 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
4503 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
4504 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
4506 <inf>: ... this new field.
4507 <step_ptid>: Delete, replaced by ...
4508 <step_thread>: ... this new field.
4509 (get_displaced_stepping_state): Take an inferior pointer instead
4510 of a pid. All callers adjusted.
4511 (displaced_step_in_progress_any_inferior): Adjust.
4512 (displaced_step_in_progress_thread): Take a thread pointer instead
4513 of a ptid_t. All callers adjusted.
4514 (displaced_step_in_progress, add_displaced_stepping_state): Take
4515 an inferior pointer instead of a pid. All callers adjusted.
4516 (get_displaced_step_closure_by_addr): Adjust.
4517 (remove_displaced_stepping_state): Take an inferior pointer
4518 instead of a pid. All callers adjusted.
4519 (displaced_step_prepare_throw, displaced_step_prepare)
4520 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
4521 All callers adjusted.
4522 (start_step_over): Adjust.
4523 (infrun_thread_ptid_changed): Remove bit updating ptids in the
4524 displaced step queue.
4525 (do_target_resume): Adjust.
4526 (fetch_inferior_event): Use inferior_thread.
4527 (context_switch, get_inferior_stop_soon): Take an
4528 execution_control_state pointer instead of a ptid_t. All callers
4530 (switch_to_thread_cleanup): Delete.
4531 (stop_all_threads): Use scoped_restore_current_thread.
4532 * inline-frame.c: Include "gdbthread.h".
4533 (inline_state) <inline_state>: Take a thread pointer instead of a
4534 ptid_t. All callers adjusted.
4535 <ptid>: Delete, replaced by ...
4536 <thread>: ... this new field.
4537 (find_inline_frame_state): Take a thread pointer instead of a
4538 ptid_t. All callers adjusted.
4539 (skip_inline_frames, step_into_inline_frame)
4540 (inline_skipped_frames, inline_skipped_symbol): Take a thread
4541 pointer instead of a ptid_t. All callers adjusted.
4542 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
4543 (inline_skipped_frames, inline_skipped_symbol): Likewise.
4544 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
4546 * linux-nat.c (get_detach_signal): Likewise.
4547 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
4548 (thread_db_notice_clone): Adjust.
4549 (thread_db_find_new_threads_silently)
4550 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
4551 a thread pointer instead of a ptid_t. All callers adjusted.
4552 * mi/mi-cmd-var.c: Include "inferior.h".
4553 (mi_cmd_var_update_iter): Update to use thread pointers.
4554 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
4556 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
4558 (mi_output_running): ... this new function.
4559 (mi_on_resume_1): Adjust to use it.
4560 (mi_user_selected_context_changed): Adjust to use inferior_thread.
4561 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
4563 (interrupt_thread_callback): : Adjust to use thread and inferior
4565 * proc-service.c: Include "gdbthread.h".
4566 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
4567 * progspace-and-thread.c: Include "inferior.h".
4568 * progspace.c: Include "inferior.h".
4569 * python/py-exitedevent.c (create_exited_event_object): Adjust to
4570 hold a reference to an inferior_object.
4571 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
4573 * python/py-inferior.c (struct inferior_object): Give the type a
4574 tag name instead of a typedef.
4575 (python_on_normal_stop): No need to check if the current thread is
4577 (inferior_to_inferior_object): Change return type to
4578 inferior_object. All callers adjusted.
4579 (find_thread_object): Delete, bits factored out to ...
4580 (thread_to_thread_object): ... this new function.
4581 * python/py-infthread.c (create_thread_object): Use
4582 inferior_to_inferior_object.
4583 (thpy_is_stopped): Use thread pointer directly.
4584 (gdbpy_selected_thread): Use inferior_thread.
4585 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
4586 field, replaced with ...
4587 <thread>: ... this new field. All users adjusted.
4588 (btpy_insn_or_gap_new): Drop const.
4589 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
4591 * python/py-record.c: Include "gdbthread.h".
4592 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4593 a ptid_t. All callers adjusted.
4594 (gdbpy_current_recording): Use inferior_thread.
4595 * python/py-record.h (recpy_record_object) <ptid>: Delete
4596 field, replaced with ...
4597 <thread>: ... this new field. All users adjusted.
4598 (recpy_element_object) <ptid>: Delete
4599 field, replaced with ...
4600 <thread>: ... this new field. All users adjusted.
4601 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4602 a ptid_t. All callers adjusted.
4603 * python/py-threadevent.c: Include "gdbthread.h".
4604 (get_event_thread): Use thread_to_thread_object.
4605 * python/python-internal.h (struct inferior_object): Forward
4607 (find_thread_object, find_inferior_object): Delete declarations.
4608 (thread_to_thread_object, inferior_to_inferior_object): New
4610 * record-btrace.c: Include "inferior.h".
4611 (require_btrace_thread): Use inferior_thread.
4612 (record_btrace_frame_sniffer)
4613 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
4614 (get_thread_current_frame): Use scoped_restore_current_thread and
4616 (get_thread_current_frame): Use thread pointer directly.
4617 (record_btrace_replay_at_breakpoint): Use thread's inferior
4619 * record-full.c: Include "inferior.h".
4620 * regcache.c: Include "gdbthread.h".
4621 (get_thread_arch_regcache): Use the inferior's address space
4623 (get_thread_regcache, registers_changed_thread): New.
4624 * regcache.h (get_thread_regcache(thread_info *thread)): New
4626 (registers_changed_thread): New.
4627 (remote_target) <remote_detach_1>: Swap order of parameters.
4628 (remote_add_thread): <remote_add_thread>: Return the new thread.
4629 (get_remote_thread_info(ptid_t)): New overload.
4630 (remote_target::remote_notice_new_inferior): Use thread pointers
4632 (remote_target::process_initial_stop_replies): Use
4633 thread_info::set_running.
4634 (remote_target::remote_detach_1, remote_target::detach)
4635 (extended_remote_target::detach): Adjust.
4636 * stack.c (frame_show_address): Use inferior_thread.
4637 * target-debug.h (target_debug_print_thread_info_pp): New.
4638 * target-delegates.c: Regenerate.
4639 * target.c (default_thread_address_space): Delete.
4640 (memory_xfer_partial_1): Use current_inferior.
4641 (target_detach): Use current_inferior.
4642 (target_thread_address_space): Delete.
4643 (generic_mourn_inferior): Use current_inferior.
4644 * target.h (struct target_ops) <thread_address_space>: Delete.
4645 (target_thread_address_space): Delete.
4646 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
4648 (delete_thread_1, delete_thread, delete_thread_silent): Take a
4649 thread pointer instead of a ptid_t. Adjust all callers.
4650 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
4651 (first_thread_of_process): Delete, replaced by ...
4652 (first_thread_of_inferior): ... this new function. All callers
4654 (any_thread_of_process): Rename to ...
4655 (any_thread_of_inferior): ... this, and take an inferior pointer.
4656 (any_live_thread_of_process): Rename to ...
4657 (any_live_thread_of_inferior): ... this, and take an inferior
4659 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4660 (value_in_thread_stack_temporaries)
4661 (get_last_thread_stack_temporary): Take a thread pointer instead
4662 of a ptid_t. Adjust all callers.
4663 (thread_info::set_running): New.
4664 (validate_registers_access): Use inferior_thread.
4665 (can_access_registers_ptid): Rename to ...
4666 (can_access_registers_thread): ... this, and take a thread
4668 (print_thread_info_1): Adjust to compare thread pointers instead
4670 (switch_to_no_thread, switch_to_thread): Make extern.
4671 (scoped_restore_current_thread::~scoped_restore_current_thread):
4672 Use m_thread pointer directly.
4673 (scoped_restore_current_thread::scoped_restore_current_thread):
4674 Use inferior_thread.
4675 (thread_command): Use thread pointer directly.
4676 (thread_num_make_value_helper): Use inferior_thread.
4677 * top.c (execute_command): Use inferior_thread.
4678 * tui/tui-interp.c: Include "inferior.h".
4679 * varobj.c (varobj_create): Use inferior_thread.
4680 (value_of_root_1): Use find_thread_global_id instead of
4681 global_thread_id_to_ptid.
4683 2018-06-21 Alan Hayward <alan.hayward@arm.com>
4685 * regcache.c (readable_regcache::read_part): Avoid memcpy when
4687 (regcache::write_part): Likewise.
4688 (readable_regcache::cooked_read_part): Update comment.
4689 (readable_regcache::cooked_write_part): Likewise.
4690 * regcache.h: (readable_regcache::read_part): Likewise.
4691 (regcache::write_part): Likewise.
4693 2018-06-21 Richard Bunt <richard.bunt@arm.com>
4694 Dirk Schubert <dirk.schubert@arm.com>
4696 * aarch64-linux-nat.c (post_attach): New.
4697 (aarch64_linux_nat_target::post_attach): Override post_attach to
4698 record the number of hardware debug registers.
4700 2018-06-20 Tom Tromey <tom@tromey.com>
4702 * python/py-param.c (add_setshow_generic): Make parameters const.
4703 (parmpy_init): Update.
4705 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
4707 * regcache.h (regcache_cooked_read_ftype): Rename to...
4708 (register_read_ftype): ...this, change type to function_view.
4709 (class reg_buffer) <save>: Remove src parameter.
4710 (readonly_detached_regcache) <readonly_detached_regcache>: Make
4711 parameter non-const in first overload. Remove src parameter in
4713 * regcache.c (do_cooked_read): Remove.
4714 (readonly_detached_regcache::readonly_detached_regcache): Make
4715 parameter non-const, adjust call to other constructor.
4716 (reg_buffer::save): Remove src parameter.
4717 * frame.c (do_frame_register_read): Remove.
4718 (frame_save_as_regcache): Use lambda function.
4719 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
4720 parameter to ppu2spu_data *.
4721 (ppu2spu_sniffer): Use lambda function.
4723 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
4725 * record-full.c (record_full_target::insert_breakpoint): Remove
4726 "struct" keyword, add const.
4728 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
4730 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
4731 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
4732 * configure.ac: Remove AC_PREREQ, add missing quoting.
4733 * gnulib/configure.ac: Modernize usage of
4734 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
4735 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
4736 (AUTOMAKE_VERSION): Bump to 1.15.1.
4737 * configure: Re-generate.
4738 * config.in: Re-generate.
4739 * aclocal.m4: Re-generate.
4740 * gnulib/aclocal.m4: Re-generate.
4741 * gnulib/config.in: Re-generate.
4742 * gnulib/configure: Re-generate.
4743 * gnulib/import/Makefile.in: Re-generate.
4745 2018-06-19 Pedro Alves <palves@redhat.com>
4747 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
4748 (lookup_minimal_symbol_by_pc_section): ... here with
4749 gdb_assert_not_reached added.
4751 2018-06-19 Pedro Alves <palves@redhat.com>
4753 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
4754 parameter with a block parameter. Compare location's block symbol
4755 with the frame's block instead of addresses.
4756 (skip_inline_frames): Pass the current block instead of the
4757 frame's address. Break out as soon as we determine the frame
4758 should not be skipped.
4760 2018-06-18 Tom Tromey <tom@tromey.com>
4762 * solib-aix.c (solib_aix_get_section_offsets): Return
4764 (solib_aix_solib_create_inferior_hook): Update.
4766 2018-06-18 Tom Tromey <tom@tromey.com>
4768 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
4770 2018-06-18 Tom Tromey <tom@tromey.com>
4772 * solib-frv.c (frv_relocate_main_executable): Use
4774 * solib-dsbt.c (dsbt_relocate_main_executable): Use
4777 2018-06-18 Tom Tromey <tom@tromey.com>
4779 * objfiles.h (inhibit_section_map_updates): Update.
4780 (resume_section_map_updates, resume_section_map_updates_cleanup):
4782 * solib-svr4.c (svr4_handle_solib_event): Update.
4783 * objfiles.c (inhibit_section_map_updates): Return
4784 scoped_restore_tmpl<int>.
4785 (resume_section_map_updates, resume_section_map_updates_cleanup):
4788 2018-06-18 Tom Tromey <tom@tromey.com>
4790 * valprint.h (read_string): Update.
4791 * valprint.c (read_string): Change type of "buffer".
4792 (val_print_string): Update.
4793 * python/py-value.c (valpy_string): Update.
4794 * language.h (struct language_defn) <la_get_string>: Change
4796 (default_get_string, c_get_string): Update.
4797 * language.c (default_get_string): Change type of "buffer".
4798 * guile/scm-value.c (gdbscm_value_to_string): Update.
4799 * c-lang.c (c_get_string): Change type of "buffer".
4801 2018-06-18 Tom Tromey <tom@tromey.com>
4803 * ser-mingw.c (struct pipe_state_destroyer): New.
4804 (pipe_state_up): New typedef.
4805 (cleanup_pipe_state): Remove.
4806 (pipe_windows_open): Use pipe_state_up. Don't release argv.
4808 2018-06-18 Tom Tromey <tom@tromey.com>
4810 * rust-lang.h (rust_yyerror): Don't declare.
4811 * rust-lang.c (rust_language_defn): Update.
4812 * rust-exp.y (yyerror): Now static.
4813 * parse.c (parse_exp_in_context_1): Update.
4814 * p-lang.h (p_yyerror): Don't declare.
4815 * p-lang.c (p_language_defn): Update.
4816 * p-exp.y (yyerror): Now static.
4817 * opencl-lang.c (opencl_language_defn): Update.
4818 * objc-lang.c (objc_language_defn): Update.
4819 * m2-lang.h (m2_yyerror): Don't declare.
4820 * m2-lang.c (m2_language_defn): Update.
4821 * m2-exp.y (yyerror): Now static.
4822 * language.h (struct language_defn) <la_error>: Remove.
4823 * language.c (unk_lang_error): Remove.
4824 (unknown_language_defn, auto_language_defn): Remove.
4825 * go-lang.h (go_yyerror): Don't declare.
4826 * go-lang.c (go_language_defn): Update.
4827 * go-exp.y (yyerror): Now static.
4828 * f-lang.h (f_yyerror): Don't declare.
4829 * f-lang.c (f_language_defn): Update.
4830 * f-exp.y (yyerror): Now static.
4831 * d-lang.h (d_yyerror): Don't declare.
4832 * d-lang.c (d_language_defn): Update.
4833 * d-exp.y (yyerror): Now static.
4834 * c-lang.h (c_yyerror): Don't declare.
4835 * c-lang.c (c_language_defn, cplus_language_defn)
4836 (asm_language_defn, minimal_language_defn): Update.
4837 * c-exp.y (yyerror): Now static.
4838 * ada-lang.h (ada_yyerror): Don't declare.
4839 * ada-lang.c (ada_language_defn): Update.
4840 * ada-exp.y (yyerror): Now static.
4842 2018-06-18 Alan Hayward <alan.hayward@arm.com>
4844 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
4845 (store_sveregs_to_thread): Likewise.
4846 (aarch64_linux_fetch_inferior_registers): Check for SVE.
4847 (aarch64_linux_store_inferior_registers): Likewise.
4848 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
4850 (aarch64_sve_regs_copy_to_regcache): Likewise.
4851 (aarch64_sve_regs_copy_from_regcache): Likewise.
4852 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
4854 (aarch64_sve_regs_copy_to_regcache): Likewise.
4855 (aarch64_sve_regs_copy_from_regcache): Likewise.
4856 (sve_context): Structure from Linux headers.
4857 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
4858 (SVE_SIG_ZREG_SIZE): Likewise.
4859 (SVE_SIG_PREG_SIZE): Likewise.
4860 (SVE_SIG_FFR_SIZE): Likewise.
4861 (SVE_SIG_REGS_OFFSET): Likewise.
4862 (SVE_SIG_ZREGS_OFFSET): Likewise.
4863 (SVE_SIG_ZREG_OFFSET): Likewise.
4864 (SVE_SIG_ZREGS_SIZE): Likewise.
4865 (SVE_SIG_PREGS_OFFSET): Likewise.
4866 (SVE_SIG_PREG_OFFSET): Likewise.
4867 (SVE_SIG_PREGS_SIZE): Likewise.
4868 (SVE_SIG_FFR_OFFSET): Likewise.
4869 (SVE_SIG_REGS_SIZE): Likewise.
4870 (SVE_SIG_CONTEXT_SIZE): Likewise.
4871 (SVE_PT_REGS_MASK): Likewise.
4872 (SVE_PT_REGS_FPSIMD): Likewise.
4873 (SVE_PT_REGS_SVE): Likewise.
4874 (SVE_PT_VL_INHERIT): Likewise.
4875 (SVE_PT_VL_ONEXEC): Likewise.
4876 (SVE_PT_REGS_OFFSET): Likewise.
4877 (SVE_PT_FPSIMD_OFFSET): Likewise.
4878 (SVE_PT_FPSIMD_SIZE): Likewise.
4879 (SVE_PT_SVE_ZREG_SIZE): Likewise.
4880 (SVE_PT_SVE_PREG_SIZE): Likewise.
4881 (SVE_PT_SVE_FFR_SIZE): Likewise.
4882 (SVE_PT_SVE_FPSR_SIZE): Likewise.
4883 (SVE_PT_SVE_FPCR_SIZE): Likewise.
4884 (__SVE_SIG_TO_PT): Likewise.
4885 (SVE_PT_SVE_OFFSET): Likewise.
4886 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
4887 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
4888 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
4889 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
4890 (SVE_PT_SVE_PREG_OFFSET): Likewise.
4891 (SVE_PT_SVE_PREGS_SIZE): Likewise.
4892 (SVE_PT_SVE_FFR_OFFSET): Likewise.
4893 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
4894 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
4895 (SVE_PT_SVE_SIZE): Likewise.
4896 (SVE_PT_SIZE): Likewise.
4897 (HAS_SVE_STATE): New define.
4899 2018-06-18 Alan Hayward <alan.hayward@arm.com>
4901 * nat/aarch64-sve-linux-sigcontext.h: New file.
4902 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
4904 (SVE_VQ_MIN): Likewise.
4905 (SVE_VQ_MAX): Likewise.
4906 (SVE_VL_MIN): Likewise.
4907 (SVE_VL_MAX): Likewise.
4908 (SVE_NUM_ZREGS): Likewise.
4909 (SVE_NUM_PREGS): Likewise.
4910 (sve_vl_valid): Likewise.
4911 (struct user_sve_header): Likewise.
4913 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
4914 Richard Bunt <Richard.Bunt@arm.com>
4916 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
4917 was requested by GDB.
4919 2018-06-15 Tom de Vries <tdevries@suse.de>
4921 * MAINTAINERS (Write After Approval): Add Tom de Vries.
4923 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
4925 * gnulib/update-gnulib.sh: Print expected versions of
4928 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
4930 * arch-utils.c (default_type_align): Use type_length_units.
4931 * gdbtypes.c (type_align): Use type_length_units.
4933 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4935 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
4936 of 'define' command.
4938 2018-06-14 Tom de Vries <tdevries@suse.de>
4941 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
4942 get_no_prettyformat_print_options.
4944 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
4946 * sparc-nat.h: Include target.h.
4947 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
4948 <fetch_registers>: Remove this argument in function call.
4949 <store_registers>: Remove this argument in function call, remove
4951 <low_forget_process>: Call sparc64_forget_process instead of
4952 sparc_forget_process.
4954 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4956 * procfs.c (_initialize_procfs): Use add_inf_child_target.
4957 (procfs_target::make_corefile_notes): Adjust to new
4958 target_read_alloc return type.
4960 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
4961 Stephen Roberts <stephen.roberts@arm.com>
4964 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
4965 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
4966 Move should_notify_stop local into more inner scope.
4968 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
4969 Stephen Roberts <stephen.roberts@arm.com>
4972 * infrun.c (resume_1): Add call to mark_async_event_handler.
4974 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
4976 * infrun.c (do_target_wait): Change old version of $pc printed.
4978 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
4980 * dwarf2read.c (read_index_from_section): Rename to...
4981 (read_gdb_index_from_section): ... this, update all callers.
4982 (dwarf2_read_index): Rename to...
4983 (dwarf2_read_gdb_index): ... this, update all callers.
4985 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
4987 * gdb/hppa-linux-nat.c
4988 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
4989 hppa_linux_nat_target::fetch_registers.
4991 2018-06-11 Alan Hayward <alan.hayward@arm.com>
4993 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
4994 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
4995 (AARCH64_DWARF_SVE_FFR): Likewise.
4996 (AARCH64_DWARF_SVE_P0): Likewise.
4997 (AARCH64_DWARF_SVE_Z0): Likewise.
4999 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5001 * common/common-regcache.h (raw_compare): New function.
5002 * regcache.c (regcache::raw_compare): Likewise.
5003 * regcache.h (regcache::raw_compare): New declaration.
5005 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5007 * common/common-regcache.h (reg_buffer_common): New structure.
5008 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
5009 (reg_buffer::raw_supply): Likewise.
5010 (reg_buffer::raw_supply_integer): Likewise.
5011 (reg_buffer::raw_supply_zeroed): Likewise.
5012 (reg_buffer::raw_collect): Likewise.
5013 (reg_buffer::raw_collect_integer): Likewise.
5014 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
5015 (reg_buffer::raw_supply): Likewise.
5016 (reg_buffer::raw_supply_integer): Likewise.
5017 (reg_buffer::raw_supply_zeroed): Likewise.
5018 (reg_buffer::raw_collect): Likewise.
5019 (reg_buffer::raw_collect_integer): Likewise.
5021 2018-06-10 Tom Tromey <tom@tromey.com>
5023 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
5024 (class remote_state) <stop_reply_queue>: Now std::vector.
5025 (remote_state::~remote_state)
5026 (remote_target::stop_reply_queue_length): Update.
5027 (struct queue_iter_param, remove_child_of_pending_fork)
5028 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
5029 (check_pending_event_prevents_wildcard_vcont_callback)
5030 (remove_stop_reply_for_inferior)
5031 (remove_stop_reply_of_remote_state)
5032 (remote_notif_remove_once_on_match)
5033 (stop_reply_match_ptid_and_ws)
5034 (remote_kill_child_of_pending_fork): Remove.
5035 (remote_target::remove_new_fork_children)
5036 (remote_target::check_pending_events_prevent_wildcard_vcont)
5037 (remote_target::discard_pending_stop_replies)
5038 (remote_target::discard_pending_stop_replies_in_queue)
5039 (remote_target::remote_notif_remove_queued_reply)
5040 (remote_target::queued_stop_reply)
5041 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
5042 (remote_target::wait, remote_target::kill_new_fork_children)
5043 (remote_target::async): Update.
5045 2018-06-10 Tom Tromey <tom@tromey.com>
5047 * record-full.c (record_full_arch_list_cleanups): Remove.
5048 (record_full_message): Use try/catch.
5049 (record_full_wait_cleanups): Remove.
5050 (record_full_wait_1): Use try/catch.
5051 (record_full_restore): Likewise.
5053 2018-06-10 Tom Tromey <tom@tromey.com>
5055 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
5056 declare VEC. Add constructor.
5057 <in_target_beneath>: Now bool.
5058 (record_full_breakpoints): Now a std::vector, static.
5059 (record_full_sync_record_breakpoints)
5060 (record_full_init_record_breakpoints)
5061 (record_full_target::insert_breakpoint)
5062 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
5064 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
5066 * dwarf2read.c (process_cu_includes): Remove struct keyword.
5067 * serial.c (serial_interface_lookup): Remove struct keyword.
5069 2018-06-10 Tom Tromey <tom@tromey.com>
5071 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
5073 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
5075 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
5077 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
5078 "beneath" as a method.
5079 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
5080 Use "beneath" as a method.
5082 2018-06-10 Tom Tromey <tom@tromey.com>
5084 * tracefile.c (struct trace_file_writer_deleter): New.
5085 <operator()>: Rename from trace_file_writer_xfree.
5086 (trace_file_writer_up): New typedef.
5087 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
5089 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5091 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
5092 <m_registers, m_register_status>: Change type to
5094 * regcache.c (reg_buffer::reg_buffer): Use new instead of
5097 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5099 * common/common-regcache.h (enum register_status): Add
5100 underlying type "signed char".
5101 * regcache.h (reg_buffer) <m_register_status>: Change type to
5103 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
5104 register_status instead of signed char.
5105 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
5106 (reg_buffer::get_register_status): Remove cast.
5107 (readable_regcache::raw_read): Remove cast.
5108 (readable_regcache::cooked_read): Remove cast.
5110 2018-06-09 Tom Tromey <tom@tromey.com>
5112 * source.c (reverse_search_command, forward_search_command): Use
5115 2018-06-09 Tom Tromey <tom@tromey.com>
5117 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
5118 (serial_ops_list): Now static, std::vector.
5119 (serial_interface_lookup, serial_add_interface): Update.
5121 2018-06-09 Tom Tromey <tom@tromey.com>
5123 * dwarf2read.c (process_cu_includes): Update.
5124 (process_full_comp_unit): Update.
5125 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
5128 2018-06-08 Paul Koning <paul_koning@dell.com>
5132 * python/python.c (do_start_initialization):
5133 Avoid call to internal Python API.
5134 (init__gdb_module): New function.
5136 2018-06-08 Gary Benson <gbenson@redhat.com>
5138 * linux-thread-db.c (valprint.h): New include.
5139 (struct check_thread_db_info): New structure.
5140 (check_thread_db_on_load, tdb_testinfo): New static globals.
5141 (check_thread_db, check_thread_db_callback): New functions.
5142 (try_thread_db_load_1): Run integrity checks if requested.
5143 (maintenance_check_libthread_db): New function.
5144 (_initialize_thread_db): Register "maint check libthread-db"
5145 and "maint set/show check-libthread-db".
5146 * NEWS: Mention the above new commands.
5148 2018-06-08 Tom Tromey <tom@tromey.com>
5150 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
5153 2018-06-08 Tom Tromey <tom@tromey.com>
5155 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
5157 2018-06-08 Tom Tromey <tom@tromey.com>
5159 * common/btrace-common.h (struct btrace_data): Add constructor,
5160 destructor, move assignment operator.
5161 <empty, clear, fini>: New methods.
5162 <format>: Initialize.
5163 (btrace_data_init, btrace_data_fini, btrace_data_clear)
5164 (btrace_data_empty): Don't declare.
5165 * common/btrace-common.c (btrace_data_init): Remove.
5166 (btrace_data::fini): Rename from btrace_data_fini.
5167 (btrace_data::empty): Rename from btrace_data_empty.
5168 (btrace_data::clear): Rename from btrace_data_clear. Return
5170 * btrace.h (make_cleanup_btrace_data): Don't declare.
5171 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
5172 (parse_xml_btrace): Update.
5173 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
5174 (maint_btrace_clear_packet_history_cmd): Update.
5176 2018-06-07 Pedro Alves <palves@redhat.com>
5178 * target.h (target_ops) <beneath>: Now a method. All references
5180 (class target_stack): New.
5181 * target.c (g_target_stack): New.
5182 (g_current_top_target): Delete.
5183 (current_top_target): Get the top target out of g_target_stack.
5184 (target_stack::push, target_stack::unpush): New.
5185 (push_target, unpush_target): Reimplement.
5186 (target_is_pushed): Reimplement in terms of g_target_stack.
5187 (target_ops::beneath, target_stack::find_beneath): New.
5189 2018-06-07 Pedro Alves <palves@redhat.com>
5191 * target.h (find_target_beneath): Delete declaration.
5192 * target.c (find_target_beneath): Delete definition.
5193 * aix-thread.c: All callers of find_target_beneath adjusted to
5194 call target_ops::beneath instead.
5195 * bsd-uthread.c: Likewise.
5196 * linux-thread-db.c: Likewise.
5197 * ravenscar-thread.c: Likewise.
5198 * sol-thread.c: Likewise.
5199 * spu-multiarch.c: Likewise.
5201 2018-06-07 Pedro Alves <palves@redhat.com>
5203 * target.h (target_ops) <beneath>: Now a method. All references
5205 (target_ops) <m_beneath>: New.
5206 * target.c (target_ops::beneath): New.
5207 * corelow.c: Adjust all references to target_ops::beneath.
5208 * linux-thread-db.c: Likewise.
5209 * make-target-delegates: Likewise.
5210 * record-btrace.c: Likewise.
5211 * record-full.c: Likewise.
5212 * remote.c: Likewise.
5213 * target.c: Likewise.
5214 * target-delegates.c: Regenerate.
5216 2018-06-07 Pedro Alves <palves@redhat.com>
5218 * target.h (target_stack): Delete.
5219 (current_top_target): Declare function.
5220 * target.c (target_stack): Delete.
5221 (g_current_top_target): New.
5222 (current_top_target): New function.
5223 * auxv.c: Use current_top_target instead of target_stack
5225 * avr-tdep.c: Likewise.
5226 * breakpoint.c: Likewise.
5227 * corefile.c: Likewise.
5228 * elfread.c: Likewise.
5230 * exceptions.c: Likewise.
5231 * frame.c: Likewise.
5232 * gdbarch-selftests.c: Likewise.
5233 * gnu-v3-abi.c: Likewise.
5234 * ia64-tdep.c: Likewise.
5235 * ia64-vms-tdep.c: Likewise.
5236 * infcall.c: Likewise.
5237 * infcmd.c: Likewise.
5238 * infrun.c: Likewise.
5239 * linespec.c: Likewise.
5240 * linux-tdep.c: Likewise.
5241 * minsyms.c: Likewise.
5242 * ppc-linux-nat.c: Likewise.
5243 * ppc-linux-tdep.c: Likewise.
5244 * procfs.c: Likewise.
5245 * regcache.c: Likewise.
5246 * remote.c: Likewise.
5247 * rs6000-tdep.c: Likewise.
5248 * s390-linux-nat.c: Likewise.
5249 * s390-tdep.c: Likewise.
5250 * solib-aix.c: Likewise.
5251 * solib-darwin.c: Likewise.
5252 * solib-dsbt.c: Likewise.
5253 * solib-spu.c: Likewise.
5254 * solib-svr4.c: Likewise.
5255 * solib-target.c: Likewise.
5256 * sparc-tdep.c: Likewise.
5257 * sparc64-tdep.c: Likewise.
5258 * spu-tdep.c: Likewise.
5259 * symfile.c: Likewise.
5260 * symtab.c: Likewise.
5261 * target-descriptions.c: Likewise.
5262 * target-memory.c: Likewise.
5263 * target.c: Likewise.
5264 * target.h: Likewise.
5265 * tracefile-tfile.c: Likewise.
5266 * tracepoint.c: Likewise.
5267 * valops.c: Likewise.
5268 * valprint.c: Likewise.
5269 * value.c: Likewise.
5270 * windows-tdep.c: Likewise.
5271 * mi/mi-main.c: Likewise.
5273 2018-06-07 Tom Tromey <tom@tromey.com>
5275 * valprint.h (build_address_symbolic): Declare.
5276 * printcmd.c (print_address_symbolic): Update.
5277 (build_address_symbolic): Change "name" and "filename" to
5279 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
5281 * defs.h (build_address_symbolic): Remove declaration.
5283 2018-06-07 Alan Hayward <alan.hayward@arm.com>
5285 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
5286 (aarch64_vnv_type): Add function.
5287 (aarch64_pseudo_register_name): Add V regs for SVE.
5288 (aarch64_pseudo_register_type): Likewise.
5289 (aarch64_pseudo_register_reggroup_p): Likewise.
5290 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
5291 (aarch64_pseudo_read_value): Add V regs for SVE.
5292 (aarch64_pseudo_write_2): Use V0 offset for SVE
5293 (aarch64_pseudo_write): Add V regs for SVE.
5294 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
5296 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
5298 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
5299 (sve_vl_from_vq): Likewise.
5301 2018-06-05 Tom Tromey <tom@tromey.com>
5303 * cli/cli-cmds.c (show_version): Update.
5304 * top.c (print_gdb_version): Add "interactive" parameter.
5306 * main.c (captured_main_1): Update.
5307 * top.h (print_gdb_version): Add "interactive" parameter and a
5310 2018-06-05 David Malcolm <dmalcolm@redhat.com>
5312 * common/enum-flags.h: Add trailing semicolon to example in
5315 2018-06-05 Tom Tromey <tom@tromey.com>
5318 * NEWS: Add entry about pager.
5319 * utils.c (pagination_disabled_for_command): New global.
5320 (prompt_for_continue): Allow "c" response to prompt.
5321 (reinitialize_more_filter): Clear
5322 pagination_disabled_for_command.
5323 (fputs_maybe_filtered): Check pagination_disabled_for_command.
5325 2018-06-04 Tom Tromey <tom@tromey.com>
5327 * ada-lang.h (ada_lookup_symbol_list): Update.
5328 * ada-lang.c (resolve_subexp): Update.
5329 (symbols_are_identical_enums): Change type of syms. Remove nsyms
5331 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
5332 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
5333 results parameter to std::vector.
5334 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
5336 * ada-exp.y (block_lookup): Update.
5337 (select_possible_type_sym): Change type of syms. Remove nsyms
5339 (write_var_or_type, write_name_assoc): Update.
5341 2018-06-04 Joel Brobecker <brobecker@adacore.com>
5343 * windows-nat.c (windows_nat_target::xfer_partial): Return
5344 TARGET_XFER_E_IO if we need to delegate to the target beneath
5345 but BENEATH is NULL.
5347 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
5349 * Makefile.in (config.status): Add configure.nat as a
5352 2018-06-04 Tom Tromey <tom@tromey.com>
5354 * cp-name-parser.y (cpname_state): Add method declarations.
5355 (HANDLE_QUAL): Update.
5356 (cpname_state::d_grab, cpname_state::fill_comp)
5357 (cpname_state::make_operator, cpname_state::make_dtor)
5358 (cpname_state::make_builtin_type, cpname_state::make_name)
5359 (cpname_state::d_qualify, cpname_state::d_int_type)
5360 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
5361 (%union): Move earlier.
5363 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5365 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
5367 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5369 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
5370 (aarch64_pseudo_write_1): Likewise.
5371 (aarch64_pseudo_read_value): Use helper.
5372 (aarch64_pseudo_write): Likewise.
5374 2018-06-04 Pedro Alves <palves@redhat.com>
5376 * darwin-nat.c (darwin_ops): Delete.
5377 (darwin_attach_pid): Use get_native_target.
5379 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5381 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
5382 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
5384 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5386 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
5387 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
5388 (aarch64_gdbarch_init): Check for SVE.
5389 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
5391 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5393 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
5394 * aarch64-tdep.h (aarch64_read_description): Likewise.
5395 * arch/aarch64.c (aarch64_create_target_description): Likewise.
5396 * arch/aarch64.h (aarch64_create_target_description): Likewise.
5397 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
5398 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
5399 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
5401 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
5403 * value.c (value_fetch_lazy_bitfield): New.
5404 (value_fetch_lazy_memory): New.
5405 (value_fetch_lazy_register): New.
5406 (value_fetch_lazy): Factor out to smaller functions.
5408 2018-06-01 Tom Tromey <tom@tromey.com>
5410 * cp-name-parser.y (backslashable, represented): Now const.
5412 2018-06-01 Tom Tromey <tom@tromey.com>
5414 * cp-name-parser.y: Include parser-defs.h.
5415 (parser_fprintf): Remove declaration.
5417 2018-06-01 Tom Tromey <tom@tromey.com>
5419 * cp-name-parser.y: Use %pure-parser, %lex-param, and
5421 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
5422 (global_result): Remove globals.
5423 (struct cpname_state): New.
5424 (yyparse): Don't declare.
5425 (yylex, yyerror): Move declarations after %union.
5426 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
5427 (make_name): Add state parameter.
5429 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
5431 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
5433 (yylex): Add lvalp, state parameters.
5434 (yyerror): Add state parameter.
5435 (cp_demangled_name_to_comp): Update.
5437 2018-06-01 Tom Tromey <tom@tromey.com>
5439 * cp-name-parser.y (parser_fprintf): Declare.
5440 (GDB_YY_REMAP_PREFIX): Define.
5441 Include yy-remap.h. Don't redefine yy* identifiers.
5443 2018-06-01 Tom Tromey <tom@tromey.com>
5445 * python/py-type.c (typy_legacy_template_argument): Update.
5446 * cp-support.h (cp_demangled_name_to_comp): Update.
5447 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
5448 parameter to be a "std::string *".
5451 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
5453 * ada-lex.l: Include "diagnostics.h" instead of
5454 "common/diagnostics.h".
5455 * unittests/environ-selftests.c: Likewise.
5456 * common/diagnostics.h: Moved to ../include.
5458 2018-06-01 Joel Brobecker <brobecker@adacore.com>
5460 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
5461 to language_mode_manual while calling breakpoint_re_set_one.
5463 2018-06-01 Tom Tromey <tom@tromey.com>
5465 * valops.c (value_cast_structs, destructor_name_p): Update.
5466 * symtab.c (gdb_mangle_name): Update.
5467 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
5469 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
5470 (pascal_object_print_value_fields, pascal_object_print_value):
5472 * p-typeprint.c (pascal_type_print_derivation_info): Update.
5473 * linespec.c (find_methods): Update.
5474 * gdbtypes.h (type_name_no_tag): Remove.
5475 (type_name_or_error): Rename from type_name_no_tag_or_error.
5476 * gdbtypes.c (type_name_no_tag): Remove.
5477 (type_name_or_error): Rename from type_name_no_tag_or_error.
5478 (lookup_struct_elt_type, check_typedef): Update.
5479 * expprint.c (print_subexp_standard): Update.
5480 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
5481 * d-namespace.c (d_lookup_nested_symbol): Update.
5482 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
5483 (cp_print_class_member): Update.
5484 * cp-namespace.c (cp_lookup_nested_symbol): Update.
5485 * completer.c (add_struct_fields): Update.
5486 * c-typeprint.c (cp_type_print_derivation_info)
5487 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
5489 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
5490 (ada_prefer_type, ada_is_exception_sym): Update.
5492 2018-06-01 Tom Tromey <tom@tromey.com>
5494 * valops.c (enum_constant_from_type, value_namespace_elt)
5495 (value_maybe_namespace_elt): Update.
5496 * valarith.c (find_size_for_pointer_math): Update.
5497 * target-descriptions.c (make_gdb_type): Update.
5498 * symmisc.c (print_symbol): Update.
5499 * stabsread.c (define_symbol, read_type)
5500 (complain_about_struct_wipeout, add_undefined_type)
5501 (cleanup_undefined_types_1): Update.
5502 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
5503 (rust_range_type_p, val_print_struct, rust_print_struct_def)
5504 (rust_internal_print_type, rust_composite_type)
5505 (rust_evaluate_funcall, rust_evaluate_subexp)
5506 (rust_inclusive_range_type_p): Update.
5507 * python/py-type.c (typy_get_tag): Update.
5508 * p-typeprint.c (pascal_type_print_base): Update.
5509 * mdebugread.c (parse_symbol, parse_type): Update.
5510 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
5512 * guile/scm-type.c (gdbscm_type_tag): Update.
5513 * go-lang.c (sixg_string_p): Update.
5514 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
5516 * gdbtypes.h (struct main_type) <tag_name>: Remove.
5517 (TYPE_TAG_NAME): Remove.
5518 * gdbtypes.c (type_name_no_tag): Simplify.
5519 (check_typedef, check_types_equal, recursive_dump_type)
5520 (copy_type_recursive, arch_composite_type): Update.
5521 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
5522 in summary mode when needed.
5523 * eval.c (evaluate_funcall): Update.
5524 * dwarf2read.c (fixup_go_packaging, read_structure_type)
5525 (process_structure_scope, read_enumeration_type)
5526 (read_namespace_type, read_module_type, determine_prefix): Update.
5527 * cp-support.c (inspect_type): Update.
5528 * coffread.c (process_coff_symbol, decode_base_type): Update.
5529 * c-varobj.c (c_is_path_expr_parent): Update.
5530 * c-typeprint.c (c_type_print_base_struct_union): Update.
5531 (c_type_print_base_1): Update. Print struct/class/union/enum in
5532 summary when using C language.
5533 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
5534 (gen_maybe_namespace_elt): Update.
5535 * ada-lang.c (ada_type_name): Simplify.
5536 (empty_record, ada_template_to_fixed_record_type_1)
5537 (template_to_static_fixed_type)
5538 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
5540 2018-06-01 Tom Tromey <tom@tromey.com>
5542 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
5544 * c-typeprint.c (c_print_type_1): Add "language" parameter.
5545 (c_print_type): Update.
5546 (c_print_type): New overload.
5547 (c_type_print_varspec_prefix, c_type_print_args)
5548 (c_type_print_varspec_suffix, c_print_type_no_offsets)
5549 (c_type_print_base_struct_union, c_type_print_base_1)
5550 (cp_type_print_method_args): Add "language" parameter.
5551 (c_type_print_base): Update.
5552 * c-lang.h (c_print_type): Add new overload.
5554 2018-06-01 Tom Tromey <tom@tromey.com>
5556 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
5557 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
5559 2018-06-01 Alan Hayward <alan.hayward@arm.com>
5561 * aarch64-tdep.c (aarch64_sve_register_names): New const
5563 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
5564 (AARCH64_SVE_Z_REGS_NUM): New define.
5565 (AARCH64_SVE_P_REGS_NUM): Likewise.
5566 (AARCH64_SVE_NUM_REGS): Likewise.
5568 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
5570 * nat/linux-ptrace.h [__alpha__]
5571 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
5574 2018-05-31 Maciej W. Rozycki <macro@mips.com>
5576 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
5577 the endianness selected.
5578 * NEWS: Document `set endian auto' mode operation update.
5580 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5582 * Makefile.in: Add new header.
5583 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
5584 (sve_vl_from_vg): Likewise.
5585 (sve_vq_from_vl): Likewise.
5586 (sve_vl_from_vq): Likewise.
5587 (sve_vq_from_vg): Likewise.
5588 (sve_vg_from_vq): Likewise.
5589 * configure.nat: Add new c file.
5590 * nat/aarch64-sve-linux-ptrace.c: New file.
5591 * nat/aarch64-sve-linux-ptrace.h: New file.
5593 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5595 * aarch64-linux-nat.c (aarch64_linux_read_description):
5597 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
5599 * aarch64-tdep.c (tdesc_aarch64_list): Add.
5600 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
5601 (aarch64_gdbarch_init): Add parmeter zero.
5602 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
5603 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
5604 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
5606 * doc/gdb.texinfo: Describe SVE feature
5607 * features/aarch64-sve.c: New file.
5609 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
5612 * gdbarch.sh (significant_addr_bit): Default to zero when
5613 not set by target architecture.
5614 * gdbarch.c: Re-generated.
5615 * utils.c (address_significant): Update.
5617 2018-05-30 Joel Brobecker <brobecker@adacore.com>
5619 * stack.c (func_command): Remove trailing newline in call to error.
5621 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5623 * regcache.h (regcache_raw_collect): Remove, update callers to
5624 use regcache::raw_collect.
5625 * regcache.c (regcache_raw_collect): Remove.
5627 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5629 * regcache.h (regcache_raw_supply): Remove, update callers to
5630 use detached_regcache::raw_supply.
5631 * regcache.c (regcache_raw_supply): Remove.
5633 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5635 * regcache.h (regcache_cooked_write_part): Remove, update
5636 callers to use regcache::cooked_write_part.
5637 * regcache.c (regcache_cooked_write_part): Remove.
5639 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5641 * regcache.h (regcache_cooked_read_part): Remove, update callers
5642 to use readable_regcache::cooked_read_part.
5643 * regcache.c (regcache_cooked_read_part): Remove.
5645 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5647 * regcache.h (regcache_cooked_read_value): Remove, update
5648 callers to use readable_regcache::cooked_read_value.
5649 * regcache.c (regcache_cooked_read_value): Remove.
5651 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5653 * regcache.h (regcache_cooked_write): Remove, update callers to
5654 use regcache::cooked_write.
5655 * regcache.c (regcache_cooked_write): Remove.
5657 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5659 * regcache.h (regcache_invalidate): Remove, update callers to
5660 use detached_regcache::invalidate instead.
5661 * regcache.c (regcache_invalidate): Remove.
5663 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5665 * regcache.h (regcache_raw_write_part): Remove, update callers
5666 to use regcache::raw_write_part instead.
5667 * regcache.c (regcache_raw_write_part): Remove.
5669 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5671 * regcache.h (regcache_raw_read_part): Remove, update callers to
5672 use readable_regcache::raw_read_part instead.
5673 * regcache.c (regcache_raw_read_part): Remove.
5675 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5677 * regcache.h (regcache_cooked_read): Remove, update callers to
5678 use readable_regcache::cooked_read instead.
5679 * regcache.c (regcache_cooked_read): Remove.
5681 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5683 * regcache.h (regcache_raw_write): Remove, update callers to use
5684 regcache::raw_write instead.
5685 * regcache.c (regcache_raw_write): Remove.
5687 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5689 * regcache.h (regcache_raw_read): Remove, update callers to use
5690 readable_regcache::raw_read instead.
5691 * regcache.c (regcache_raw_read): Remove.
5693 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5695 * regcache.h (regcache_raw_update): Remove, update callers to
5696 use readable_regcache::raw_update instead.
5697 * regcache.c (regcache_raw_update): Remove.
5699 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5701 * regcache.h (regcache_register_status): Remove, update callers
5702 to use reg_buffer::get_register_status directly instead.
5703 * regcache.c (regcache_register_status): Remove.
5705 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5707 * regcache.h (regcache_get_ptid): Remove, update all callers to
5708 call regcache::ptid instead.
5709 * regcache.c (regcache_get_ptid): Remove.
5711 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5713 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
5715 2018-05-30 Pedro Alves <palves@redhat.com>
5717 * common/common-exceptions.h (exception_rethrow): Use
5720 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
5722 * breakpoint.c (print_solib_event, check_status_catch_solib):
5723 Remove struct keyword in range-based for loops.
5724 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
5725 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
5727 * linespec.c (find_superclass_methods, search_minsyms_for_name):
5729 * symfile.c (addr_info_make_relative): Likewise.
5730 * thread.c (value_in_thread_stack_temporaries): Likewise.
5732 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
5735 * valops.c (value_struct_elt_for_reference): Call check_typedef on
5736 aggregate type to get its real type before accessing it.
5738 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
5740 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
5741 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
5742 * coff-pe-read.c (add_pe_forwarded_sym): Replace
5743 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
5744 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
5745 * jit.c (jit_breakpoint_re_set_internal): Likewise.
5746 * printcmd.c (info_address_command): Likewise.
5748 2018-05-29 Tom Tromey <tom@tromey.com>
5750 * windows-nat.c (handle_exception): Update fall-through comment.
5752 2018-05-29 Tom Tromey <tom@tromey.com>
5754 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
5755 (struct program_space) <added_solibs>: Now a std::vector.
5756 * breakpoint.c (print_solib_event): Update.
5757 (check_status_catch_solib): Update.
5758 * progspace.c (clear_program_space_solib_cache): Update.
5759 * solib.c (update_solib_list): Update.
5761 2018-05-29 Tom Tromey <tom@tromey.com>
5763 * python/py-type.c (typy_richcompare): Update.
5764 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
5765 * gdbtypes.h (types_deeply_equal): Return bool.
5766 (types_equal): Likewise.
5767 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
5769 (check_types_equal): Change worklist to std::vector. Return
5771 (struct type_equality_entry): Add constructor.
5772 (compare_maybe_null_strings): Return bool.
5773 (check_types_worklist): Return bool. Change worklist to
5775 (types_deeply_equal): Use std::vector.
5776 (types_equal): Return bool.
5777 (compare_maybe_null_strings): Simplify.
5779 2018-05-29 Tom Tromey <tom@tromey.com>
5781 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
5783 2018-05-29 Tom Tromey <tom@tromey.com>
5785 * objc-lang.h: Don't include cp-support.h.
5786 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
5789 2018-05-27 Tom Tromey <tom@tromey.com>
5791 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
5793 2018-05-25 Tom Tromey <tom@tromey.com>
5795 * value.c (value::location): Initialize.
5797 2018-05-25 Tom Tromey <tom@tromey.com>
5799 * dbxread.c (init_bincl_list): Remove.
5800 (bincl_list): Now a std::vector.
5801 (bincls_allocated, next_bincl): Remove.
5802 (free_bincl_list, do_free_bincl_list_cleanup)
5803 (make_cleanup_free_bincl_list): Remove.
5804 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
5806 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
5807 (struct header_file_location): Add constructor.
5808 (add_bincl_to_list): Remove.
5810 2018-05-25 Tom Tromey <tom@tromey.com>
5812 * tui/tui.c (tui_enable): Update.
5813 * mi/mi-interp.c (mi_interp::init): Update.
5814 * interps.h (class interp) <name>: New method.
5815 <m_name>: Rename from name.
5816 (~scoped_restore_interp): Update.
5817 * interps.c (interp::interp): Update.
5818 (interp_add, interp_set, interp_lookup_existing)
5819 (current_interp_named_p): Update.
5821 2018-05-25 Tom Tromey <tom@tromey.com>
5823 * interps.c (interp_name): Remove.
5824 * mi/mi-interp.c (mi_interp::init): Update.
5825 * interps.h (interp_name): Remove.
5826 (~scoped_restore_interp): Update.
5827 * tui/tui.c (tui_enable): Update.
5829 2018-05-25 Tom Tromey <tom@tromey.com>
5831 * utils.c (fputs_maybe_filtered): Update.
5832 * linespec.c (decode_line_full): Update.
5833 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
5834 (mi_print_breakpoint_for_event, mi_solib_loaded)
5835 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
5836 (mi_user_selected_context_changed): Update.
5837 * mi/mi-main.c (mi_execute_command): Update.
5838 * cli/cli-script.c (execute_control_command): Update.
5839 * python/python.c (execute_gdb_command): Update.
5840 * solib.c (info_sharedlibrary_command): Update.
5841 * interps.c (interp_ui_out): Remove.
5842 * interps.h (interp_ui_out): Remove.
5844 2018-05-25 Tom Tromey <tom@tromey.com>
5846 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
5847 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
5848 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
5850 2018-05-25 Tom Tromey <tom@tromey.com>
5852 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
5853 * interps.c (interp_exec): Use scoped_restore.
5855 2018-05-25 Tom Tromey <tom@tromey.com>
5857 * remote.c (remote_target::remote_file_get): Use
5859 (remote_target::remote_file_put): Likewise.
5861 2018-05-25 Tom Tromey <tom@tromey.com>
5863 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
5865 (get_pe_section_index, add_pe_exported_sym): Update.
5866 (read_pe_exported_syms): Use gdb::def_vector.
5868 2018-05-25 Tom Tromey <tom@tromey.com>
5870 * frame.c (remove_prev_frame): Remove.
5871 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
5873 2018-05-25 Maciej W. Rozycki <macro@mips.com>
5875 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
5877 * mips-linux-nat.c (supply_fpregset): Always call
5878 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
5879 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
5880 `mips_fill_fpregset'.
5881 * mips-linux-tdep.c (mips_supply_fpregset)
5882 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
5883 (mips_fill_fpregset_wrapper): Remove functions.
5884 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
5885 (mips_linux_fpregset): Remove variable.
5886 (mips_linux_iterate_over_regset_sections): Use
5887 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
5888 (mips_linux_o32_sigframe_init): Remove comment.
5890 2018-05-25 Pedro Alves <palves@redhat.com>
5892 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
5893 (struct readahead_cache, struct packet_reg, struct
5894 remote_arch_state, class remote_state): Move higher up in the
5896 (remote_target::m_remote_state): Now an object instead of a pointer.
5897 (remote_target::get_remote_state): Adjust.
5899 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
5901 * stack.c (select_and_print_frame): Delete.
5902 (struct function_bounds): Move struct within function.
5903 (func_command): Most content moved into new function
5904 find_frame_for_function, use new function, print result, add
5906 (find_frame_for_function): New function, now returns a result.
5908 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5910 * stack.c (iterate_over_block_arg_vars): Fix comment.
5911 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
5913 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
5917 (scoped_restore_selected_frame::scoped_restore_selected_frame):
5919 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
5921 * frame.h (class scoped_restore_selected_frame): New class.
5922 * stack.c (print_frame_local_vars): Remove catching and rethrowing
5923 of any exception, use scoped_restore_selected_frame to restore the
5926 2018-05-24 Pedro Alves <palves@redhat.com>
5928 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
5931 2018-05-23 Tom Tromey <tom@tromey.com>
5933 * complaints.c (struct complaints): Remove.
5934 (symfile_complaint_book): Remove.
5935 (series): New global.
5936 (complaint_internal): Update.
5937 (clear_complaints): Update.
5939 2018-05-23 Tom Tromey <tom@tromey.com>
5941 * complaints.c (counters): New global.
5942 (struct complain): Remove.
5943 (struct complaints) <root>: Remove.
5944 (complaint_sentinel): Remove.
5945 (symfile_complaint_book): Update.
5946 (find_complaint) Remove.
5947 (complaint_internal, clear_complaints): Update.
5949 2018-05-23 Tom Tromey <tom@tromey.com>
5951 * complaints.c (struct complain) <file, line>: Remove.
5952 (find_complaint): Remove file, line parameters.
5953 (complaint_internal): Update.
5955 2018-05-23 Tom Tromey <tom@tromey.com>
5957 * complaints.c (vcomplaint): Remove.
5958 (complaint_internal) Merge in contents of vcomplaint.
5960 2018-05-23 Tom Tromey <tom@tromey.com>
5962 * complaints.c (struct complaints) <explanation>: Remove.
5963 (symfile_explanations): Remove.
5964 (symfile_complaint_book): Update.
5965 (vcomplaint): Update.
5966 (struct explanation): Remove.
5968 2018-05-23 Tom Tromey <tom@tromey.com>
5970 * complaints.c (symfile_complaints): Remove.
5971 (complaint_internal): Remove "complaints" parameter.
5972 (clear_complaints, vcomplaint): Remove "c" parameter.
5973 (get_complaints): Remove.
5974 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
5975 (dwarf2_debug_line_missing_file_complaint)
5976 (dwarf2_debug_line_missing_end_sequence_complaint)
5977 (dwarf2_complex_location_expr_complaint)
5978 (dwarf2_const_value_length_mismatch_complaint)
5979 (dwarf2_section_buffer_overflow_complaint)
5980 (dwarf2_macro_malformed_definition_complaint)
5981 (dwarf2_invalid_attrib_class_complaint)
5982 (create_addrmap_from_index, dw2_symtab_iter_next)
5983 (dw2_expand_marked_cus)
5984 (dw2_debug_names_iterator::find_vec_in_debug_names)
5985 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
5986 (create_debug_type_hash_table, init_cutu_and_read_dies)
5987 (partial_die_parent_scope, add_partial_enumeration)
5988 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
5989 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
5990 (read_import_statement, read_file_scope, create_dwo_cu_reader)
5991 (create_cus_hash_table, create_dwp_hash_table)
5992 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
5993 (dwarf2_rnglists_process, dwarf2_ranges_process)
5994 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
5995 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
5996 (handle_struct_member_die, process_structure_scope)
5997 (read_array_type, read_common_block, read_module_type)
5998 (read_tag_pointer_type, read_typedef, read_base_type)
5999 (read_subrange_type, load_partial_dies, partial_die_info::read)
6000 (partial_die_info::read, partial_die_info::read)
6001 (partial_die_info::read, read_checked_initial_length_and_offset)
6002 (dwarf2_string_attr, read_formatted_entries)
6003 (dwarf_decode_line_header)
6004 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
6005 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
6006 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
6007 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
6008 (get_signatured_type, get_DW_AT_signature_type)
6009 (decode_locdesc, file_file_name, consume_improper_spaces)
6010 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
6011 (dwarf_decode_macro_bytes, dwarf_decode_macros)
6012 (dwarf2_symbol_mark_computed, set_die_type)
6013 (read_attribute_value): Update.
6014 * stap-probe.c (handle_stap_probe, get_stap_base_address):
6016 * dbxread.c (unknown_symtype_complaint)
6017 (lbrac_mismatch_complaint, repeated_header_complaint)
6018 (set_namestring, function_outside_compilation_unit_complaint)
6019 (read_dbx_symtab, process_one_symbol): Update.
6020 * gdbtypes.c (stub_noname_complaint): Update.
6021 * windows-nat.c (handle_unload_dll): Update.
6022 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
6023 (decode_base_type): Update.
6024 * xcoffread.c (bf_notfound_complaint, ef_complaint)
6025 (eb_complaint, record_include_begin, record_include_end)
6026 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
6027 (process_xcoff_symbol, read_symbol)
6028 (function_outside_compilation_unit_complaint)
6029 (scan_xcoff_symtab): Update.
6030 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
6031 * buildsym.c (finish_block_internal, make_blockvector)
6032 (end_symtab_get_static_block, augment_type_symtab): Update.
6033 * dtrace-probe.c (dtrace_process_dof)
6034 (dtrace_static_probe_ops::get_probes): Update.
6035 * complaints.h (struct complaint): Don't declare.
6036 (symfile_complaints): Remove.
6037 (complaint_internal): Remove "complaints" parameter.
6038 (complaint): Likewise.
6039 (clear_complaints): Likewise.
6040 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6041 (reread_symbols): Update.
6042 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
6043 (dwarf2_frame_cache, decode_frame_entry): Update.
6044 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
6045 * objc-lang.c (lookup_objc_class, lookup_child_selector)
6046 (info_selectors_command): Update.
6047 * macrotab.c (macro_include, check_for_redefinition)
6048 (macro_undef): Update.
6049 * objfiles.c (filter_overlapping_sections): Update.
6050 * stabsread.c (invalid_cpp_abbrev_complaint)
6051 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
6052 (define_symbol, error_type, read_type, rs6000_builtin_type)
6053 (stabs_method_name_from_physname, read_member_functions)
6054 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
6055 (attach_fields_to_type, complain_about_struct_wipeout)
6056 (read_range_type, read_args, common_block_start)
6057 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
6059 * mdebugread.c (index_complaint, unknown_ext_complaint)
6060 (basic_type_complaint, bad_tag_guess_complaint)
6061 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
6062 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
6063 (parse_procedure, parse_lines)
6064 (function_outside_compilation_unit_complaint)
6065 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
6066 (bad_tag_guess_complaint, reg_value_complaint): Update.
6067 * cp-support.c (demangled_name_complaint): Update.
6068 * macroscope.c (sal_macro_scope): Update.
6069 * dwarf-index-write.c (class debug_names): Update.
6071 2018-05-23 Tom Tromey <tom@tromey.com>
6073 * complaints.c (clear_complaints): Remove "noisy" parameter.
6074 * complaints.h (clear_complaints): Update.
6075 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6076 (reread_symbols): Update.
6078 2018-05-23 Tom Tromey <tom@tromey.com>
6080 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
6082 (vcomplaint, clear_complaints): Update.
6083 (symfile_explanations): Remove some messages.
6085 2018-05-23 Tom Tromey <tom@tromey.com>
6087 * complaints.c (internal_complaint): Remove.
6088 * complaints.h (internal_complaint): Remove.
6090 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6092 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
6094 2018-05-22 Pedro Alves <palves@redhat.com>
6096 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
6097 (remote_fileio_badfd, remote_fileio_return_errno)
6098 (remote_fileio_return_success, remote_fileio_func_open)
6099 (remote_fileio_func_open, remote_fileio_func_close)
6100 (remote_fileio_func_read, remote_fileio_func_write)
6101 (remote_fileio_func_lseek, remote_fileio_func_rename)
6102 (remote_fileio_func_unlink, remote_fileio_func_stat)
6103 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
6104 (remote_fileio_func_isatty, remote_fileio_func_system): Add
6105 remote_target parameter.
6106 (remote_fio_func_map) <func>: Add remote_target parameter.
6107 (do_remote_fileio_request, remote_fileio_request):
6108 * remote-fileio.h (remote_fileio_request):
6109 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
6110 remote_target parameter.
6111 (remote_notif_process, handle_notification): Adjust to pass down
6113 (remote_notif_state_allocate): Add remote_target parameter. Save
6115 * remote-notif.h (struct remote_target): Forward declare.
6116 (struct notif_client) <parse, ack, can_get_pending_events>: Add
6117 remote_target parameter.
6118 (struct remote_notif_state) <remote>: New field.
6119 (remote_notif_ack, remote_notif_parse): Add remote_target
6121 (remote_notif_state_allocate, remote_notif_state_allocate): Add
6122 remote_target parameter.
6123 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
6124 (threads_listing_context, rmt_thread_action, protocol_feature)
6125 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
6126 (packet_result, struct threads_listing_context, remote_state):
6127 Move definitions and declarations higher up.
6128 (remote_target) <~remote_target>: Declare.
6129 (remote_download_command_source, remote_file_put, remote_file_get)
6130 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
6131 (remote_hostio_pread_vFile, remote_hostio_send_command)
6132 (remote_hostio_set_filesystem, remote_hostio_open)
6133 (remote_hostio_close, remote_hostio_unlink, remote_state)
6134 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
6135 (get_memory_write_packet_size, get_memory_read_packet_size)
6136 (append_pending_thread_resumptions, remote_detach_1)
6137 (append_resumption, remote_resume_with_vcont)
6138 (add_current_inferior_and_thread, wait_ns, wait_as)
6139 (process_stop_reply, remote_notice_new_inferior)
6140 (process_initial_stop_replies, remote_add_thread)
6141 (btrace_sync_conf, remote_btrace_maybe_reopen)
6142 (remove_new_fork_children, kill_new_fork_children)
6143 (discard_pending_stop_replies, stop_reply_queue_length)
6144 (check_pending_events_prevent_wildcard_vcont)
6145 (discard_pending_stop_replies_in_queue, stop_reply)
6146 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
6147 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
6148 (remote_interrupt_as, remote_interrupt_ns)
6149 (remote_get_noisy_reply, remote_query_attached)
6150 (remote_add_inferior, remote_current_thread, get_current_thread)
6151 (set_thread, set_general_thread, set_continue_thread)
6152 (set_general_process, write_ptid)
6153 (remote_unpack_thread_info_response, remote_get_threadinfo)
6154 (parse_threadlist_response, remote_get_threadlist)
6155 (remote_threadlist_iterator, remote_get_threads_with_ql)
6156 (remote_get_threads_with_qxfer)
6157 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
6158 (get_offsets, remote_check_symbols, remote_supported_packet)
6159 (remote_query_supported, remote_packet_size)
6160 (remote_serial_quit_handler, remote_detach_pid)
6161 (remote_vcont_probe, remote_resume_with_hc)
6162 (send_interrupt_sequence, interrupt_query)
6163 (remote_notif_get_pending_events, fetch_register_using_p)
6164 (send_g_packet, process_g_packet, fetch_registers_using_g)
6165 (store_register_using_P, store_registers_using_G)
6166 (set_remote_traceframe, check_binary_download)
6167 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
6168 (remote_xfer_live_readonly_partial, remote_read_bytes)
6169 (remote_send_printf, remote_flash_write, readchar)
6170 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
6171 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
6172 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
6173 (extended_remote_disable_randomization, extended_remote_run)
6174 (send_environment_packet, extended_remote_environment_support)
6175 (extended_remote_set_inferior_cwd, remote_write_qxfer)
6176 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
6177 (packet_command): Now methods of ...
6178 (remote_target): ... this class.
6179 (m_remote_state) <remote_target>: New field.
6180 (struct remote_state) <stop_reply_queue,
6181 remote_async_inferior_event_token, wait_forever_enabled_p>: New
6183 (remote_state::remote_state): Allocate stop_reply_queue.
6184 (remote_state): Delete global.
6185 (get_remote_state_raw): Delete.
6186 (remote_target::get_remote_state): Allocate m_remote_state on
6188 (get_current_remote_target): New.
6189 (remote_ops, extended_remote_ops): Delete.
6190 (wait_forever_enabled_p, remote_async_inferior_event_token):
6191 Delete, moved to struct remote_state.
6192 (remote_target::close): Delete self. Destruction bits split to
6194 (remote_target::~remote_target): ... this.
6195 (show_memory_packet_size): Adjust to use
6196 get_current_remote_target.
6197 (struct protocol_feature) <func>: Add remote_target parameter.
6198 All callers adjusted.
6199 (curr_quit_handler_target): New.
6200 (remote_serial_quit_handler): Reimplement.
6201 (remote_target::open_1): Adjust to use get_current_remote_target.
6202 Heap-allocate remote_target/extended_remote_target instances.
6203 (vcont_builder::vcont_builder): Add remote_target parameter, and
6204 save it in m_remote. All callers adjusted.
6205 (vcont_builder::m_remote): New field.
6206 (vcont_builder::restart, vcont_builder::flush)
6207 (vcont_builder::push_action): Use it.
6208 (remote_target::commit_resume): Use it.
6209 (struct queue_iter_param) <remote>: New field.
6210 (remote_target::remove_new_fork_children): Fill in 'remote' field.
6211 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
6212 (check_pending_event_prevents_wildcard_vcont_callback)
6213 (remote_target::check_pending_events_prevent_wildcard_vcont)
6214 (remote_target::discard_pending_stop_replies)
6215 (remote_target::discard_pending_stop_replies_in_queue)
6216 (remote_target::remote_notif_remove_queued_reply): Fill in
6218 (remote_notif_get_pending_events): New.
6219 (remote_target::readchar, remote_target::remote_serial_write):
6220 Save/restore curr_quit_handler_target.
6222 (kill_new_fork_children): Fill in 'remote' field.
6223 (packet_command): Use get_current_remote_target, defer to
6224 remote_target method of same name.
6225 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
6226 parameter, and save it in m_remote. All callers adjusted.
6227 (scoped_remote_fd::release): Use m_remote.
6228 (scoped_remote_fd::m_remote): New field.
6229 (remote_file_put, remote_file_get, remote_file_delete): Use
6230 get_current_remote_target, defer to remote_target method of same
6232 (remote_btrace_reset): Add remote_state paremeter. Update all
6234 (remote_async_inferior_event_handler). Pass down 'data'.
6235 (remote_new_objfile): Use get_current_remote_target.
6236 (remote_target::vcont_r_supported): New.
6237 (set_range_stepping): Use get_current_remote_target and
6238 remote_target::vcont_r_supported.
6239 (_initialize_remote): Don't allocate 'remote_state' and
6240 'stop_reply_queue' globals.
6241 * remote.h (struct remote_target): Forward declare.
6242 (getpkt, putpkt, remote_notif_get_pending_events): Add
6243 'remote_target' parameter.
6245 2018-05-22 Pedro Alves <palves@redhat.com>
6247 * remote.c (vcont_builder): Now a class. Make all data members
6249 (vcont_builder) <vcont_builder, restart, flush, push_action>:
6251 (vcont_builder_restart): Rename to ...
6252 (vcont_builder::restart): ... this.
6253 (vcont_builder_flush): Rename to ...
6254 (vcont_builder::flush): ... this.
6255 (vcont_builder_push_action): Rename to ...
6256 (vcont_builder::push_action): ... this.
6257 (remote_target::commit_resume): Adjust.
6259 2018-05-22 Pedro Alves <palves@redhat.com>
6261 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
6262 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
6263 (get_fixed_memory_packet_size): New.
6264 (get_memory_packet_size): Use it.
6265 (set_memory_packet_size): Don't override the config size with
6266 DEFAULT_MAX_MEMORY_PACKET_SIZE.
6267 (show_memory_packet_size): Use get_fixed_memory_packet_size.
6268 Don't refer to get_memory_packet_size if not connected to a remote
6269 target. Show "(default)" if configured size is 0.
6271 2018-05-22 Pedro Alves <palves@redhat.com>
6273 * remote.c (remote_target::mourn_inferior): Move
6274 discard_pending_stop_replies call here from ...
6275 (_initialize_remote): ... here.
6277 2018-05-22 Pedro Alves <palves@redhat.com>
6279 * remote.c (compare_section_command): Remove set_general_process
6282 2018-05-22 Pedro Alves <palves@redhat.com>
6284 * remote.c (struct packet_reg, struct remote_arch_state):
6285 Move higher up in the file.
6286 (remote_state) <m_arch_states>: Store remote_arch_state values
6287 instead of remote_arch_state pointers.
6288 (remote_state::get_remote_arch_state): Adjust.
6290 2018-05-22 Pedro Alves <palves@redhat.com>
6292 * remote.c: Include <unordered_map>.
6293 (remote_state): Now a class.
6294 (remote_state) <get_remote_arch_state>: Declare method.
6295 <get_remote_arch_state>: New field.
6296 (remote_arch_state) <remote_arch_state>: Declare ctor.
6297 <regs>: Now a unique_ptr.
6298 (remote_gdbarch_data_handle): Delete.
6299 (get_remote_arch_state): Delete.
6300 (remote_state::get_remote_arch_state): New.
6301 (get_remote_state): Adjust to call remote_state's
6302 get_remote_arch_state method.
6303 (init_remote_state): Delete, bits factored out to ...
6304 (remote_arch_state::remote_arch_state): ... this new method.
6305 (get_remote_packet_size, get_memory_packet_size)
6306 (process_g_packet, remote_target::fetch_registers)
6307 (remote_target::prepare_to_store, store_registers_using_G)
6308 (remote_target::store_registers, remote_target::get_trace_status):
6309 Adjust to call remote_state's method.
6310 (_initialize_remote): Remove reference to
6311 remote_gdbarch_data_handle.
6313 2018-05-22 Pedro Alves <palves@redhat.com>
6315 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
6316 pread>: New method declarations.
6317 (remote_target::open_1): Adjust.
6318 (readahead_cache_invalidate): Rename to ...
6319 (readahead_cache::invalidate): ... this, and adjust to be a class
6321 (readahead_cache_invalidate_fd): Rename to ...
6322 (readahead_cache::invalidate_fd): ... this, and adjust to be a
6324 (remote_hostio_pwrite): Adjust.
6325 (remote_hostio_pread_from_cache): Rename to ...
6326 (readahead_cache::pread): ... this, and adjust to be a class
6328 (remote_hostio_close): Adjust.
6330 2018-05-22 Pedro Alves <palves@redhat.com>
6332 * remote.c (remote_hostio_close_cleanup): Delete.
6333 (class scoped_remote_fd): New.
6334 (remote_file_put, remote_file_get): Use it.
6336 2018-05-22 Pedro Alves <palves@redhat.com>
6338 (struct vCont_action_support): Use bool and initialize all fields.
6339 (struct readahead_cache): Initialize all fields.
6340 (remote_state): Use bool and initialize all fields.
6341 (remote_state::remote_state, remote_state::~remote_state): New.
6342 (new_remote_state): Delete.
6343 (_initialize_remote): Use new to allocate remote_state.
6345 2018-05-22 Pedro Alves <palves@redhat.com>
6349 * c-exp.y: Include "c-support.h".
6350 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
6351 of tolower. Use c_ident_is_alpha to scan names.
6352 * c-lang.c: Include "c-support.h".
6353 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
6354 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
6355 * c-support.h: New file, with bits factored out from ...
6356 * cp-name-parser.y: ... this file.
6357 Include "c-support.h".
6358 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
6359 c-support.h and renamed.
6360 (symbol_end, yylex): Adjust.
6362 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6364 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
6365 parameter type to CORE_ADDR.
6366 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
6367 parameter type in declaration to CORE_ADDR.
6368 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
6369 target_auxv_search to get AT_HWCAP and use the result to get the
6371 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
6372 to CORE_ADDR. Remove the cast of the return value to unsigned
6373 long. Fix error predicate of target_auxv_search.
6374 (ppc_linux_nat_target::read_description): Change the type of the
6375 hwcap variable to CORE_ADDR.
6377 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6379 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
6380 if the size of fpscr is larger than 32 bits.
6382 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6384 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
6385 (ppc32_linux_vsxregmap): New global.
6386 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
6387 regcache_supply_regset, and regcache_collect_regset.
6388 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
6389 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
6390 (fetch_vsx_register, store_vsx_register): Remove.
6391 (fetch_vsx_registers): Add regno parameter. Get regset using
6392 ppc_linux_vsxregset. Use regset to supply registers.
6393 (store_vsx_registers): Add regno parameter. Get regset using
6394 ppc_linux_vsxregset. Use regset to collect registers.
6395 (fetch_register): Call fetch_vsx_registers instead of
6397 (store_register): Call store_vsx_registers instead of
6399 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
6400 new regno parameter.
6401 (store_ppc_registers): Call store_vsx_registers with -1 for the
6402 new regno parameter.
6403 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
6404 (ppc_collect_vsxregset): Remove.
6406 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6408 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
6410 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
6411 for vector register offset fields.
6412 (ppc64_fbsd_reg_offsets): Likewise.
6413 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6414 to vector register offset fields.
6415 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6416 to vector register offset fields.
6417 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
6418 vector register offset fields.
6419 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
6420 initializers for vector register offset fields.
6421 (rs6000_aix64_reg_offsets): Likewise.
6422 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
6423 (ppc_supply_vrregset): Remove.
6424 (ppc_collect_vrregset): Remove.
6425 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
6426 (ppc_linux_vrregset) : New function.
6427 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
6428 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
6429 (ppc32_linux_vrregset): Remove.
6430 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
6431 and use result instead of ppc32_linux_vrregset.
6432 (ppc32_linux_reg_offsets): Remove initializers for vector register
6434 (ppc64_linux_reg_offsets): Likewise.
6435 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
6436 * ppc-linux-nat.c: Include regset.h.
6437 (gdb_vrregset_t): Adjust comment to account for little-endian
6439 (supply_vrregset, fill_vrregset): Remove.
6440 (fetch_altivec_register, store_altivec_register): Remove.
6441 (fetch_altivec_registers): Add regno parameter. Get regset using
6442 ppc_linux_vrregset. Use regset to supply registers.
6443 (store_altivec_registers): Add regno parameter. Get regset using
6444 ppc_linux_vrregset. Use regset to collect registers.
6445 (fetch_register): Call fetch_altivec_registers instead of
6446 fetch_altivec_register.
6447 (store_register): Call store_altivec_registers instead of
6448 store_altivec_register.
6449 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
6450 the new regno parameter.
6451 (store_ppc_registers): Call store_altivec_registers with -1 for
6452 the new regno parameter.
6454 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6456 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
6457 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
6458 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
6459 (gdb_vrregset_t): Change array type size to
6460 PPC_LINUX_SIZEOF_VRREGSET.
6461 (gdb_vsxregset_t): Change array type size to
6462 PPC_LINUX_SIZEOF_VSXREGSET.
6463 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
6464 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
6465 PPC_LINUX_SIZEOF_VSXREGSET.
6467 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6469 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
6470 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
6472 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
6473 ppc_linux_target_wordsize with tid.
6474 (ppc_linux_nat_target::read_description): Call ppc_linux_target
6476 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
6477 (ppc64_64bit_inferior_p): Add static and inline specifiers.
6478 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
6479 tid parameter. Remove static specifier.
6480 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
6481 (ppc_linux_target_wordsize): New declaration.
6483 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6485 * arch/ppc-linux-common.c: New file.
6486 * arch/ppc-linux-common.h: New file.
6487 * arch/ppc-linux-tdesc.h: New file.
6488 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
6489 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
6490 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
6491 arch/ppc-linux-tdesc.h.
6492 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
6493 arch/ppc-linux-tdesc.h.
6494 (ppc_linux_nat_target::read_description): Remove target
6495 description matching code. Fill a ppc_linux_features struct and
6496 call ppc_linux_match_description with it. Move comment about ISA
6497 2.05 to ppc-linux-common.c.
6498 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
6499 arch/ppc-linux-tdesc.h.
6500 (ppc_linux_core_read_description): Remove target description
6501 matching code. Fill a ppc_linux_features struct and call
6502 ppc_linux_match_description with it.
6503 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
6504 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
6505 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
6506 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
6507 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
6508 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
6509 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
6510 (tdesc_powerpc_e500l): Remove.
6512 2018-05-22 Joel Brobecker <brobecker@adacore.com>
6514 * ada-lang.c (catch_assert_command): Pass empty string instead
6515 of NULL for excep_string argument.
6517 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6519 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
6520 the width of the requested register exceeds the width of the
6523 2018-05-21 Tom Tromey <tom@tromey.com>
6525 * printcmd.c (output_command): Remove.
6526 (output_command_const): Rename to output_command.
6527 * valprint.h (output_command): Rename from output_command_const.
6528 * tracepoint.c (trace_dump_actions): Call output_command.
6530 2018-05-21 Tom Tromey <tom@tromey.com>
6532 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
6533 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
6534 * ada-lang.h (create_ada_exception_catchpoint): Update.
6535 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
6537 (create_excep_cond_exprs, ~ada_catchpoint)
6538 (should_stop_exception, print_one_exception)
6539 (print_mention_exception, print_recreate_exception): Update.
6540 (ada_get_next_arg): Remove.
6541 (catch_ada_exception_command_split): Use std::string. Change type
6542 of "excep_string", "cond_string".
6543 (catch_ada_exception_command): Update.
6544 (create_ada_exception_catchpoint): Change type of excep_string.
6545 (ada_exception_sal): Remove excep_string parameter.
6546 (~ada_catchpoint): Remove.
6548 2018-05-21 Tom Tromey <tom@tromey.com>
6550 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
6553 2018-05-21 Tom Tromey <tom@tromey.com>
6555 * ada-lang.c (ada_exception_message_1, ada_exception_message):
6556 Return unique_xmalloc_ptr.
6557 (print_it_exception): Update.
6559 2018-05-21 Tom Tromey <tom@tromey.com>
6561 * tracepoint.c (trace_dump_actions): Use std::string.
6563 2018-05-21 Tom Tromey <tom@tromey.com>
6565 * symfile.c (reread_symbols): Use std::string for original_name.
6567 2018-05-21 Tom Tromey <tom@tromey.com>
6569 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
6570 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
6573 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
6575 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
6577 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
6578 * objfiles.c (get_objfile_bfd_data): Allocate
6579 objfile_per_bfd_storage with obstack_new when allocating on
6582 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
6584 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
6586 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
6587 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
6588 * mdebugread.c (mdebug_build_psymtabs): Likewise.
6589 (add_pending): Likewise.
6590 (parse_symbol): Likewise.
6591 (parse_partial_symbols): Likewise.
6592 (psymtab_to_symtab_1): Likewise.
6593 (new_psymtab): Likewise.
6594 (elfmdebug_build_psymtabs): Likewise.
6595 * minsyms.c (terminate_minimal_symbol_table): Likewise.
6596 * objfiles.c (get_objfile_bfd_data): Likewise.
6597 (objfile_register_static_link): Likewise.
6598 * psymtab.c (allocate_psymtab): Likewise.
6599 * stabsread.c (read_member_functions): Likewise.
6600 * xcoffread.c (xcoff_end_psymtab): Likewise.
6602 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
6604 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
6605 compiler supports std::is_trivially_constructible.
6606 * common/poison.h: Include obstack.h.
6607 (IsMallocable): Define to is_trivially_constructible if the
6608 compiler supports it, define to true_type otherwise.
6612 (XOBNEWVEC): Redefine.
6613 * gdb_obstack.h (obstack_zalloc): New.
6614 (OBSTACK_ZALLOC): Redefine.
6615 (obstack_calloc): New.
6616 (OBSTACK_CALLOC): Redefine.
6618 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
6619 (gdbarch_obstack): New declaration in gdbarch.h, definition in
6621 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
6622 obstack_calloc/obstack_zalloc.
6623 (gdbarch_obstack_zalloc): Remove.
6624 * target-descriptions.c (tdesc_data_init): Use obstack_new.
6626 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6628 * stack.c (backtrace_command_1): Remove useless variable int i.
6630 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6632 * stack.c (print_frame_info): Fix comment.
6634 2018-05-18 Tom Tromey <tom@tromey.com>
6636 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
6637 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
6638 (~dwarf2_per_objfile): Update
6639 (dwarf2_get_dwz_file): Use new.
6640 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
6643 2018-05-18 Tom Tromey <tom@tromey.com>
6645 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
6647 * dwarf2read.c (struct dwp_file): Add constructor and
6649 (open_and_init_dwp_file): Return a unique_ptr.
6650 (dwarf2_per_objfile, create_dwp_hash_table)
6651 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
6652 (lookup_dwo_unit_in_dwp): Update.
6653 (open_and_init_dwp_file, get_dwp_file): Update.
6655 2018-05-18 Tom Tromey <tom@tromey.com>
6657 * dwarf2read.c (dwarf2_per_objfile): Update.
6658 (struct mapped_index): Add initializers.
6659 (dwarf2_read_index): Use new.
6660 (dw2_symtab_iter_init): Update.
6661 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
6664 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6666 * dwarf2read.c (mapped_index) <total_size>: Remove.
6668 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6670 * unittests/format_pieces-selftests.c (test_format_specifier):
6673 2018-05-18 Tom Tromey <tom@tromey.com>
6675 * c-typeprint.c (maybe_print_hole): New function.
6676 (c_print_type_struct_field_offset): Update.
6677 (c_type_print_base_struct_union): Call maybe_print_hole.
6679 2018-05-17 Keith Seitz <keiths@redhat.com>
6681 * breakpoint.c (build_bpstat_chain): New function, moved from
6683 (bpstat_stop_status): Add optional parameter, `stop_chain'.
6684 If no stop chain is passed, call build_bpstat_chain to build it.
6685 * breakpoint.h (build_bpstat_chain): Declare.
6686 (bpstat_stop_status): Move documentation here from breakpoint.c.
6687 * infrun.c (handle_signal_stop): Before eliding inlined frames,
6688 build the stop chain and pass it to skip_inline_frames.
6689 Pass this stop chain to bpstat_stop_status.
6690 * inline-frame.c: Include breakpoint.h.
6691 (stopped_by_user_bp_inline_frame): New function.
6692 (skip_inline_frames): Add parameter `stop_chain'.
6693 Move documention to inline-frame.h.
6694 If non-NULL, use stopped_by_user_bp_inline_frame to determine
6695 whether the frame should be elided.
6696 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
6697 Add moved documentation and update for new parameter.
6699 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
6702 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6703 unittests/format_pieces-selftests.c.
6704 * common/format.h (format_piece) <operator==>: New.
6705 (format_pieces) <operator[]>: Remove.
6706 * common/format.c (format_pieces::format_pieces): Handle \e.
6707 * unittests/format_pieces-selftests.c: New.
6709 2018-05-17 Tom Tromey <tom@tromey.com>
6712 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
6713 (dw2_instantiate_symtab): Add skip_partial parameter.
6714 (dw2_find_last_source_symtab, dw2_map_expand_apply)
6715 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
6716 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
6717 (dw2_expand_symtabs_matching_one)
6718 (dw2_find_pc_sect_compunit_symtab)
6719 (dw2_debug_names_lookup_symbol)
6720 (dw2_debug_names_expand_symtabs_for_function): Update.
6721 (init_cutu_and_read_dies): Add skip_partial parameter.
6722 (process_psymtab_comp_unit, build_type_psymtabs_1)
6723 (process_skeletonless_type_unit, load_partial_comp_unit)
6724 (psymtab_to_symtab_1): Update.
6725 (load_full_comp_unit): Add skip_partial parameter.
6726 (process_imported_unit_die, dwarf2_read_addr_index)
6727 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
6728 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
6729 (read_signatured_type): Update.
6731 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
6733 * value.c (release_value): Remove unused variable.
6734 (record_latest_value): Likewise.
6735 (access_value_history): Likewise.
6736 (preserve_values): Likewise.
6738 2018-05-17 Tom Tromey <tom@tromey.com>
6740 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
6743 2018-05-16 Maciej W. Rozycki <macro@mips.com>
6746 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
6747 Also handle registers whose width is not a multiple of
6749 (linux_nat_trad_target::store_register): Likewise.
6751 2018-05-16 Tom Tromey <tom@tromey.com>
6753 * gdbcore.h (core_bfd): Redefine.
6754 * corelow.c (core_target::close): Update.
6755 (core_target_open): Update.
6756 * progspace.h (struct program_space) <cbfd>: Now a
6759 2018-05-16 Tom Tromey <tom@tromey.com>
6762 * symfile-add-flags.h (enum symfile_add_flags)
6763 <SYMFILE_NOT_FILENAME>: New constant.
6764 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
6765 objfile name from BFD.
6766 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
6767 * minidebug.c (find_separate_debug_file_in_section): Put
6768 ".gnu_debugdata" into BFD's file name.
6770 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
6772 * regcache.c (regcache_read_ftype, regcache_write_ftype):
6775 2018-05-15 Tamar Christina <tamar.christina@arm.com>
6778 * aarch64-tdep.c (aarch64_analyze_prologue,
6779 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
6780 Indicate not interested in errors.
6782 2018-05-15 Maciej W. Rozycki <macro@mips.com>
6784 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
6785 Supply the MIPS_ZERO_REGNUM register.
6787 2018-05-15 Maciej W. Rozycki <macro@mips.com>
6789 * mips-tdep.c (mask_address_var): Make variable static.
6791 2018-05-14 Tom Tromey <tom@tromey.com>
6793 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
6795 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
6797 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
6798 FXSAVE_ADDR for the mxcsr register.
6800 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
6802 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
6804 2018-05-11 Pedro Alves <palves@redhat.com>
6806 * corelow.c (core_target) <core_target>: No longer inline.
6807 Initialize m_core_gdbarch, m_core_vec and build the section table
6809 <~core_target>: New.
6810 <core_gdbarch, get_core_register_section>: New methods.
6811 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
6812 factored out from ...
6813 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
6815 (sniff_core_bfd): Add gdbarch parameter.
6816 (core_close): Delete, merged into ...
6817 (core_target::close): ... here. Delete self.
6818 (core_close_cleanup): Delete.
6819 (core_target_open): Allocate a core_target on the heap. Use a
6820 unique_ptr instead of a cleanup. Bits moved into the core_target
6821 ctor. Adjust to use core_target methods instead of globals.
6822 (get_core_register_section): Rename to ...
6823 (core_target::get_core_register_section): ... this and adjust.
6824 (struct get_core_registers_cb_data): New.
6825 (get_core_registers_cb): Use it. Use bool.
6826 (core_target::fetch_registers, core_target::files_info)
6827 (core_target::xfer_partial, core_target::read_description)
6828 (core_target::pid_to, core_target::thread_name): Adjust to
6829 reference class fields instead of globals.
6830 * target.h (struct target_ops_deleter, target_ops_up): New.
6832 2018-05-11 Pedro Alves <palves@redhat.com>
6834 * corefile.c (core_file_command): Move to corelow.c.
6835 * corelow.c (the_core_target): Delete.
6836 (core_file_command): Moved from corefile.c. Check exec_bfd
6837 instead of the_core_target. Use target_detach instead of calling
6838 into the_core_target directly.
6839 (maybe_say_no_core_file_now): New.
6840 (core_target::detach): Use it.
6841 (_initialize_corelow): Remove references to the_core_target.
6842 * gdbcore.h (the_core_target): Delete.
6844 2018-05-11 Tom Tromey <tromey@redhat.com>
6845 Pedro Alves <palves@redhat.com>
6847 * corefile.c (core_bfd): Remove.
6848 * gdbcore.h (core_bfd): Now a macro.
6849 * progspace.h (struct program_space) <cbfd>: New field.
6851 2018-05-11 Tom Tromey <tom@tromey.com>
6853 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
6856 2018-05-10 Tom Tromey <tom@tromey.com>
6858 * configure: Rebuild.
6859 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
6861 2018-05-10 Joel Brobecker <brobecker@adacore.com>
6864 * regformats/regdat.sh: Adjust script, following the addition
6865 of the new expedite_regs parameter to init_target_desc.
6867 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
6870 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
6871 set_gdbarch_significant_addr_bit.
6872 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
6873 set_gdbarch_significant_addr_bit.
6874 * utils.c (address_significant): Update to sign extend addr.
6876 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
6878 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
6879 (xtensa_linux_init_abi): Limit tdep->num_regs by
6880 tdep->num_nopriv_regs.
6881 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
6882 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
6885 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
6887 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
6889 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
6891 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
6892 (I387_MXCSR_INIT_VAL): New constant.
6893 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
6894 buffer if it was supplied by the inferior.
6895 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
6896 (i387_xsave_get_clear_bv): New function.
6897 (i387_supply_xsave): Only read x87 control registers from the
6898 xsave buffer if the feature is enabled, and the state will have
6899 been written, otherwise, provide a suitable default.
6900 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
6901 including x87 control registers. Update control registers if they
6902 have changed from the default value, and mark features as enabled
6904 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
6906 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
6908 * spu-tdep.c (info_spu_event_command): Fix output formatting.
6910 2018-05-07 Tom Tromey <tom@tromey.com>
6912 * configure: Rebuild.
6913 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
6915 2018-05-07 Tom Tromey <tom@tromey.com>
6918 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
6919 bit. Use correct value for VDIV.
6921 2018-05-04 Tom Tromey <tom@tromey.com>
6923 * configure: Rebuild.
6924 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
6926 2018-05-04 Tom Tromey <tom@tromey.com>
6928 * linux-record.c (record_linux_system_call) <case
6929 RECORD_SYS_RECVFROM>: Add "break".
6931 2018-05-04 Tom Tromey <tom@tromey.com>
6933 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
6934 Add missing "break".
6935 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
6936 Add missing "break".
6938 2018-05-04 Tom Tromey <tom@tromey.com>
6940 * rs6000-tdep.c (ppc_process_record_op4)
6941 (ppc_process_record_op63): Add fall-through comment.
6943 2018-05-04 Tom Tromey <tom@tromey.com>
6945 * i386-tdep.c (i386_process_record): Add fall-through comment.
6947 2018-05-04 Tom Tromey <tom@tromey.com>
6949 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
6952 2018-05-04 Tom Tromey <tom@tromey.com>
6954 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
6955 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
6956 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
6958 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
6960 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
6963 2018-05-04 Tom Tromey <tom@tromey.com>
6965 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
6967 2018-05-04 Tom Tromey <tom@tromey.com>
6969 * s390-tdep.c (s390_process_record): Fix fall-through comments.
6970 * xcoffread.c (scan_xcoff_symtab): Move comment later.
6971 * symfile.c (section_is_mapped): Fix fall-through comment.
6972 * stabsread.c (define_symbol, read_member_functions): Fix
6973 fall-through comment.
6974 * s390-linux-tdep.c (s390_process_record): Fix fall-through
6976 * remote.c (remote_wait_as): Fix fall-through comment.
6977 * p-exp.y (yylex): Fix fall-through comment.
6978 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
6980 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
6981 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
6982 * jv-exp.y (yylex): Fix fall-through comment.
6983 * go-exp.y (lex_one_token): Fix fall-through comment.
6984 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
6985 fall-through comment.
6986 * f-exp.y (yylex): Fix fall-through comment.
6987 * dwarf2read.c (process_die): Fix fall-through comments.
6988 * dbxread.c (process_one_symbol): Fix fall-through comment.
6989 * d-exp.y (lex_one_token): Fix fall-through comment.
6990 * cp-name-parser.y (yylex): Fix fall-through comment.
6991 * coffread.c (coff_symtab_read): Fix fall-through comment.
6992 * c-exp.y (lex_one_token): Fix fall-through comment.
6993 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
6995 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
6998 2018-05-04 Tom Tromey <tom@tromey.com>
7001 * NEWS: Mention gdb.execute change.
7002 * gdbcmd.h (execute_control_command): Don't declare.
7003 * python/python.c (execute_gdb_command): Use read_command_lines_1,
7004 execute_control_commands, execute_control_commands_to_string.
7005 * cli/cli-script.h (execute_control_commands)
7006 (execute_control_commands_to_string): Declare.
7007 (execute_control_command): Add from_tty parameter.
7008 * cli/cli-script.c (execute_control_commands)
7009 (execute_control_commands_to_string): New functions.
7010 (execute_user_command): Use execute_control_commands.
7011 (execute_control_command_1): Add "from_tty" parameter. Update.
7012 (execute_control_command): Likewise.
7014 2018-05-04 Tom Tromey <tom@tromey.com>
7017 * NEWS: Mention that breakpoint commands are writable.
7018 * python/py-breakpoint.c (bppy_set_commands): New function.
7019 (breakpoint_object_getset) <"commands">: Use it.
7021 2018-05-04 Tom Tromey <tom@tromey.com>
7023 * tracepoint.c (actions_command): Update.
7024 * mi/mi-cmd-break.c (mi_command_line_array)
7025 (mi_command_line_array_cnt, mi_command_line_array_ptr)
7026 (mi_read_next_line): Remove.
7027 (mi_cmd_break_commands): Update.
7028 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
7030 * cli/cli-script.c (get_command_line): Update.
7031 (process_next_line): Use function_view. Constify.
7032 (recurse_read_control_structure, read_command_lines)
7033 (read_command_lines_1): Change argument types to function_view.
7034 (do_define_command, document_command): Update.
7035 * breakpoint.h (check_tracepoint_command): Don't declare.
7036 * breakpoint.c (check_tracepoint_command): Remove.
7037 (commands_command_1, create_tracepoint_from_upload): Update.
7039 2018-05-04 Tom Tromey <tom@tromey.com>
7042 * cli/cli-script.h (enum command_control_type) <define_control>:
7044 * cli/cli-script.c (multi_line_command_p): Handle define_control.
7045 (build_command_line, execute_control_command_1)
7046 (process_next_line): Likewise.
7047 (do_define_command): New function, extracted from define_command.
7048 (define_command): Use it.
7050 2018-05-04 Tom Tromey <tom@tromey.com>
7052 * tracepoint.c (actions_command): Update.
7053 * cli/cli-script.h (read_command_lines): Update.
7054 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
7055 (MAX_TMPBUF): Remove define.
7056 (define_command): Use string_printf.
7057 (document_command): Likewise.
7058 * breakpoint.c (commands_command_1): Update.
7060 2018-05-04 Tom Tromey <tom@tromey.com>
7062 * top.c (execute_command): Update.
7063 * cli/cli-script.h (print_command_lines): Now varargs.
7064 * cli/cli-script.c (print_command_lines): Now varargs.
7065 (execute_control_command_1) <case while_control, case if_control>:
7068 2018-05-04 Tom Tromey <tom@tromey.com>
7070 * tracepoint.c (all_tracepoint_actions): Rename from
7071 all_tracepoint_actions_and_cleanup. Change return type.
7072 (actions_command, encode_actions_1, encode_actions)
7073 (trace_dump_actions, tdump_command): Update.
7074 * remote.c (remote_download_command_source): Update.
7075 * python/python.c (gdbpy_eval_from_control_command)
7076 (python_command, python_interactive_command): Update.
7077 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
7078 * guile/guile.c (guile_command)
7079 (gdbscm_eval_from_control_command, guile_command): Update.
7080 * compile/compile.c (compile_code_command)
7081 (compile_print_command, compile_to_object): Update.
7082 * cli/cli-script.h (struct command_lines_deleter): New.
7083 (counted_command_line): New typedef.
7084 (struct command_line): Add constructor, destructor.
7085 <body_list>: Remove.
7086 <body_list_0, body_list_1>: New members.
7087 (command_line_up): Remove typedef.
7088 (read_command_lines, read_command_lines_1, get_command_line):
7090 (copy_command_lines): Don't declare.
7091 * cli/cli-script.c (build_command_line): Use "new".
7092 (get_command_line): Return counted_command_line.
7093 (print_command_lines, execute_user_command)
7094 (execute_control_command_1, while_command, if_command): Update.
7095 (realloc_body_list): Remove.
7096 (process_next_line, recurse_read_control_structure): Update.
7097 (read_command_lines, read_command_lines_1): Return counted_command_line.
7098 (free_command_lines): Use "delete".
7099 (copy_command_lines): Remove.
7100 (define_command, document_command, show_user_1): Update.
7101 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
7102 a counted_command_line.
7103 * breakpoint.h (counted_command_line): Remove typedef.
7104 (breakpoint_set_commands): Update.
7105 * breakpoint.c (check_no_tracepoint_commands)
7106 (validate_commands_for_breakpoint): Update.
7107 (breakpoint_set_commands): Change commands to be a
7108 counted_command_line.
7109 (commands_command_1, update_dprintf_command_list)
7110 (create_tracepoint_from_upload): Update.
7112 2018-05-04 Tom Tromey <tom@tromey.com>
7114 * cli/cli-decode.h (cmd_list_element): New constructor.
7115 (~cmd_list_element): New destructor.
7116 (struct cmd_list_element): Add initializers.
7117 * cli/cli-decode.c (do_add_cmd): Use "new".
7118 (delete_cmd): Use "delete".
7120 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
7121 Pedro Alves <palves@redhat.com>
7123 PR breakpoints/19806 and support for PR external/20207.
7124 * NEWS: Mention Aarch64 watchpoint improvements.
7125 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
7126 watchpoints and PR external/20207 watchpoints.
7127 * nat/aarch64-linux-hw-point.c
7128 (kernel_supports_any_contiguous_range): New.
7129 (aarch64_watchpoint_offset): New.
7130 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
7131 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
7132 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
7133 (aarch64_align_watchpoint): New parameters aligned_offset_p and
7134 next_addr_orig_p. Support PR external/20207 watchpoints.
7135 (aarch64_downgrade_regs): New.
7136 (aarch64_dr_state_insert_one_point): New parameters offset and
7138 (aarch64_dr_state_remove_one_point): Likewise.
7139 (aarch64_handle_breakpoint): Update caller.
7140 (aarch64_handle_aligned_watchpoint): Likewise.
7141 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
7143 (aarch64_linux_set_debug_regs): Remove const from state. Call
7144 aarch64_downgrade_regs.
7145 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
7146 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
7147 (DR_CONTROL_MASK): ... this.
7148 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
7149 (unsigned int aarch64_watchpoint_offset): New prototype.
7150 (aarch64_linux_set_debug_regs): Remove const from state.
7151 * utils.c (align_up, align_down): Move to ...
7152 * common/common-utils.c (align_up, align_down): ... here.
7153 * utils.h (align_up, align_down): Move to ...
7154 * common/common-utils.h (align_up, align_down): ... here.
7156 2018-05-04 Joel Brobecker <brobecker@adacore.com>
7158 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
7159 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
7160 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
7161 Re-implement to match the ABI as summarized in GCC's
7162 gcc/config/sparc/sparc.c. All callers updated.
7163 (sparc32_store_arguments): Remove assertion.
7165 2018-05-04 Tom Tromey <tom@tromey.com>
7167 * printcmd.c: Don't include tui.h.
7168 (decode_format): Use skip_spaces.
7170 2018-05-04 Tom Tromey <tom@tromey.com>
7173 * printcmd.c (last_count): New global.
7174 (x_command): Use saved count when repeating.
7176 2018-05-04 Tom Tromey <tom@tromey.com>
7178 * nto-procfs.c (do_closedir_cleanup): Remove.
7179 (procfs_pidlist): Use gdb_dir_up.
7180 * procfs.c (do_closedir_cleanup): Remove.
7181 (proc_update_threads): Use gdb_dir_up.
7182 * common/filestuff.h (struct gdb_dir_deleter): New.
7183 (gdb_dir_up): New typedef.
7185 2018-05-04 Tom Tromey <tom@tromey.com>
7187 * ada-lang.c (print_mention_exception): Use std::string.
7189 2018-05-04 Tom Tromey <tom@tromey.com>
7191 * ada-lang.c (create_excep_cond_exprs): Update.
7192 (ada_exception_catchpoint_cond_string): Use std::string.
7194 2018-05-04 Tom Tromey <tom@tromey.com>
7196 * ada-lang.c (xget_renaming_scope): Return std::string.
7197 (old_renaming_is_invisible): Update.
7199 2018-05-04 Tom Tromey <tom@tromey.com>
7201 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
7202 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
7204 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
7206 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
7208 2018-05-04 Tom Tromey <tom@tromey.com>
7210 * remote.c (remote_query_supported_append): Change type.
7211 (remote_check_symbols): Update.
7213 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
7216 * configure.ac: Prepend libpython.
7217 * python/python-config.py: Likewise.
7218 * configure: Regenerate.
7220 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
7222 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
7224 2018-05-03 Pedro Alves <palves@redhat.com>
7227 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
7228 override. Write 'true' instead of '1'.
7229 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
7232 2018-05-02 Pedro Alves <palves@redhat.com>
7234 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
7235 add_inf_child_target.
7236 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
7237 add_inf_child_target.
7238 * aix-thread.c (aix_thread_target_info): New.
7239 (aix_thread_target) <shortname, longname, doc>: Delete.
7241 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
7242 add_inf_child_target.
7243 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
7244 add_inf_child_target.
7245 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
7246 add_inf_child_target.
7247 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
7248 add_inf_child_target.
7249 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
7250 add_inf_child_target.
7251 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
7252 add_inf_child_target.
7253 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
7254 add_inf_child_target.
7255 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
7256 add_inf_child_target.
7257 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
7258 add_inf_child_target.
7259 * bfd-target.c (target_bfd_target_info): New.
7260 (target_bfd) <shortname, longname, doc>: Delete.
7262 * bsd-kvm.c (bsd_kvm_target_info): New.
7263 (bsd_kvm_target) <shortname, longname, doc>: Delete.
7265 (bsd_kvm_target::open): Rename to ...
7266 (bsd_kvm_target_open): ... this. Adjust.
7267 * bsd-uthread.c (bsd_uthread_target_info): New.
7268 (bsd_uthread_target) <shortname, longname, doc>: Delete.
7270 * corefile.c (core_file_command): Adjust.
7271 * corelow.c (core_target_info): New.
7272 (core_target) <shortname, longname, doc>: Delete.
7274 (core_target::open): Rename to ...
7275 (core_target_open): ... this. Adjust.
7276 * ctf.c (ctf_target_info): New.
7277 (ctf_target) <shortname, longname, doc>: Delete.
7279 (ctf_target::open): Rename to ...
7280 (ctf_target_open): ... this.
7281 (_initialize_ctf): Adjust.
7282 * exec.c (exec_target_info): New.
7283 (exec_target) <shortname, longname, doc>: Delete.
7285 (exec_target::open): Rename to ...
7286 (exec_target_open): ... this.
7287 * gdbcore.h (core_target_open): Declare.
7288 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
7289 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
7290 add_inf_child_target.
7291 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
7292 add_inf_child_target.
7293 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
7294 add_inf_child_target.
7295 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
7296 add_inf_child_target.
7297 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
7298 add_inf_child_target.
7299 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
7300 add_inf_child_target.
7301 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
7302 add_inf_child_target.
7303 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
7304 add_inf_child_target.
7305 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
7306 add_inf_child_target.
7307 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
7308 add_inf_child_target.
7309 * inf-child.c (inf_child_target_info): New.
7310 (inf_child_target::info): New.
7311 (inf_child_open_target): Remove 'target' parameter. Use
7312 get_native_target instead.
7313 (inf_child_target::open): Delete.
7314 (add_inf_child_target): New.
7315 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
7318 (add_inf_child_target): Declare.
7319 (inf_child_open_target): Declare.
7320 * linux-thread-db.c (thread_db_target_info): New.
7321 (thread_db_target) <shortname, longname, doc>: Delete.
7323 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
7324 add_inf_child_target.
7325 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
7326 add_inf_child_target.
7327 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
7328 add_inf_child_target.
7329 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
7330 add_inf_child_target.
7331 * make-target-delegates (print_class): Adjust.
7332 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
7333 add_inf_child_target.
7334 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
7335 add_inf_child_target.
7336 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
7337 add_inf_child_target.
7338 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
7339 add_inf_child_target.
7340 * nto-procfs.c (nto_native_target_info): New.
7341 (nto_procfs_target_native) <shortname, longname, doc>:
7344 (nto_procfs_target_info): New.
7345 (nto_procfs_target_procfs) <shortname, longname, doc>:
7348 (init_procfs_targets): Adjust.
7349 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
7350 add_inf_child_target.
7351 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
7352 add_inf_child_target.
7353 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
7354 add_inf_child_target.
7355 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
7356 add_inf_child_target.
7357 * ravenscar-thread.c (ravenscar_target_info): New.
7358 (ravenscar_thread_target) <shortname, longname, doc>:
7361 * record-btrace.c (record_btrace_target_info):
7362 (record_btrace_target) <shortname, longname, doc>: Delete.
7364 (record_btrace_target::open): Rename to ...
7365 (record_btrace_target_open): ... this. Adjust.
7366 * record-full.c (record_longname, record_doc): New.
7367 (record_full_base_target) <shortname, longname, doc>: Delete.
7369 (record_full_target_info): New.
7370 (record_full_target): <shortname>: Delete.
7372 (record_full_core_open_1, record_full_open_1): Update comments.
7373 (record_full_base_target::open): Rename to ...
7374 (record_full_open): ... this.
7375 (cmd_record_full_restore): Update.
7376 (_initialize_record_full): Update.
7377 * remote-sim.c (remote_sim_target_info): New.
7378 (gdbsim_target) <shortname, longname, doc>: Delete.
7380 (gdbsim_target::open): Rename to ...
7381 (gdbsim_target_open): ... this.
7382 (_initialize_remote_sim): Adjust.
7383 * remote.c (remote_doc): New.
7384 (remote_target_info): New.
7385 (remote_target) <shortname, longname, doc>: Delete.
7387 (extended_remote_target_info): New.
7388 (extended_remote_target) <shortname, longname, doc>: Delete.
7390 (remote_target::open_1): Make static. Adjust.
7391 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
7392 * s390-linux-nat.c (_initialize_s390_nat): Use
7393 add_inf_child_target.
7394 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
7395 add_inf_child_target.
7396 * sol-thread.c (thread_db_target_info): New.
7397 (sol_thread_target) <shortname, longname, doc>: Delete.
7399 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
7400 add_inf_child_target.
7401 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
7402 add_inf_child_target.
7403 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
7404 add_inf_child_target.
7405 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
7406 add_inf_child_target.
7407 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
7408 add_inf_child_target.
7409 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
7410 add_inf_child_target.
7411 * spu-linux-nat.c (_initialize_spu_nat): Use
7412 add_inf_child_target.
7413 * spu-multiarch.c (spu_multiarch_target_info): New.
7414 (spu_multiarch_target) <shortname, longname, doc>: Delete.
7416 * target-delegates.c: Regenerate.
7417 * target.c: Include <unordered_map>.
7418 (target_ops_p): Delete.
7419 (DEF_VEC_P(target_ops_p)): Delete.
7420 (target_factories): New.
7421 (test_target_info): New.
7422 (test_target_ops::info): New.
7423 (open_target): Adjust to use target_factories.
7424 (add_target_with_completer): Rename to ...
7425 (add_target): ... this. Change prototype. Register target_info
7426 and open callback in target_factories. Register target_info in
7427 command context instead of target_ops.
7428 (add_target): Delete old implementation.
7429 (add_deprecated_target_alias): Change prototype. Adjust.
7430 (the_native_target): New.
7431 (set_native_target, get_native_target): New.
7432 (find_default_run_target): Use the_native_target.
7433 (find_attach_target, find_run_target): Simplify.
7434 (target_ops::open): Delete.
7435 (dummy_target_info): New.
7436 (dummy_target::shortname, dummy_target::longname)
7437 (dummy_target::doc): Delete.
7438 (dummy_target::info): New.
7439 (debug_target::shortname, debug_target::longname)
7440 (debug_target::doc): Delete.
7441 (debug_target::info): New.
7442 * target.h (struct target_info): New.
7443 (target_ops::~target_ops): Add comment.
7444 (target_ops::info): New.
7445 (target_ops::shortname, target_ops::longname, target_ops::doc): No
7446 longer virtual. Implement in terms of target_info.
7447 (set_native_target, get_native_target): Declare.
7448 (target_open_ftype): New.
7449 (add_target, add_target_with_completer)
7450 (add_deprecated_target_alias): Change prototype.
7451 (test_target) <shortname, longname, doc>: Delete.
7453 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
7454 add_inf_child_target.
7455 * tracefile-tfile.c (tfile_target_info): New.
7456 (tfile_target) <shortname, longname, doc>: Delete.
7458 (tfile_target::open): Rename to ...
7459 (tfile_target_open): ... this.
7460 (_initialize_tracefile_tfile): Adjust.
7461 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
7462 add_inf_child_target.
7463 * windows-nat.c (_initialize_windows_nat): Use
7464 add_inf_child_target.
7465 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
7466 add_inf_child_target.
7468 2018-05-02 Pedro Alves <palves@redhat.com>
7470 * linux-nat.h (linux_nat_target) <low_new_thread,
7471 low_delete_thread, low_new_fork, low_forget_process,
7472 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
7473 New virtual methods.
7474 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7475 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
7476 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
7477 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7478 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
7480 * linux-fork.c (delete_fork): Adjust to call low method.
7481 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
7482 (linux_nat_new_fork, linux_nat_forget_process_hook)
7483 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
7484 (linux_nat_status_is_event):
7485 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
7486 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
7488 (sigtrap_is_event): Rename to ...
7489 (linux_nat_target::low_status_is_event): ... this.
7490 (linux_nat_set_status_is_event): Delete.
7491 (save_stop_reason, linux_nat_wait_1)
7492 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
7494 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7495 (linux_nat_set_new_fork, linux_nat_set_forget_process)
7496 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7497 (linux_nat_set_prepare_to_resume): Delete.
7498 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
7499 low virtual methods.
7500 * amd64-linux-nat.c: Likewise.
7501 * arm-linux-nat.c: Likewise.
7502 * i386-linux-nat.c: Likewise.
7503 * ia64-linux-nat.c: Likewise.
7504 * mips-linux-nat.c: Likewise.
7505 * ppc-linux-nat.c: Likewise.
7506 * s390-linux-nat.c: Likewise.
7507 * sparc64-linux-nat.c: Likewise.
7508 * x86-linux-nat.c: Likewise.
7509 * x86-linux-nat.h: Include "nat/x86-linux.h".
7510 (x86_linux_nat_target) <low_new_fork, low_forget_process,
7511 low_prepare_to_resume, low_new_thread, low_delete_thread>:
7514 2018-05-02 Pedro Alves <palves@redhat.com>
7516 * target.h (target_ops)
7517 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
7518 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
7519 stopped_by_watchpoint, have_continuable_watchpoint,
7520 stopped_data_address, watchpoint_addr_within_range,
7521 can_accel_watchpoint_condition, can_run, thread_alive,
7522 has_all_memory, has_memory, has_stack, has_registers,
7523 has_execution, can_async_p, is_async_p, supports_non_stop,
7524 always_non_stop_p, can_execute_reverse, supports_multi_process,
7525 supports_enable_disable_tracepoint,
7526 supports_disable_randomization, supports_string_tracing,
7527 supports_evaluation_of_breakpoint_conditions,
7528 can_run_breakpoint_commands, filesystem_is_local,
7529 can_download_tracepoint, get_trace_state_variable_value,
7530 set_trace_notes, get_tib_address, use_agent, can_use_agent,
7531 record_is_replaying, record_will_replay,
7532 augmented_libraries_svr4_read>: Adjust to return bool.
7533 * aarch64-linux-nat.c: All implementations adjusted.
7534 * aix-thread.c: All implementations adjusted.
7535 * arm-linux-nat.c: All implementations adjusted.
7536 * breakpoint.c: All implementations adjusted.
7537 * bsd-kvm.c: All implementations adjusted.
7538 * bsd-uthread.c: All implementations adjusted.
7539 * corelow.c: All implementations adjusted.
7540 * ctf.c: All implementations adjusted.
7541 * darwin-nat.c: All implementations adjusted.
7542 * darwin-nat.h: All implementations adjusted.
7543 * exec.c: All implementations adjusted.
7544 * fbsd-nat.c: All implementations adjusted.
7545 * fbsd-nat.h: All implementations adjusted.
7546 * gnu-nat.c: All implementations adjusted.
7547 * gnu-nat.h: All implementations adjusted.
7548 * go32-nat.c: All implementations adjusted.
7549 * ia64-linux-nat.c: All implementations adjusted.
7550 * inf-child.c: All implementations adjusted.
7551 * inf-child.h: All implementations adjusted.
7552 * inf-ptrace.c: All implementations adjusted.
7553 * inf-ptrace.h: All implementations adjusted.
7554 * linux-nat.c: All implementations adjusted.
7555 * linux-nat.h: All implementations adjusted.
7556 * mips-linux-nat.c: All implementations adjusted.
7557 * nto-procfs.c: All implementations adjusted.
7558 * ppc-linux-nat.c: All implementations adjusted.
7559 * procfs.c: All implementations adjusted.
7560 * ravenscar-thread.c: All implementations adjusted.
7561 * record-btrace.c: All implementations adjusted.
7562 * record-full.c: All implementations adjusted.
7563 * remote-sim.c: All implementations adjusted.
7564 * remote.c: All implementations adjusted.
7565 * s390-linux-nat.c: All implementations adjusted.
7566 * sol-thread.c: All implementations adjusted.
7567 * spu-multiarch.c: All implementations adjusted.
7568 * target-delegates.c: All implementations adjusted.
7569 * target.c: All implementations adjusted.
7570 * target.h: All implementations adjusted.
7571 * tracefile-tfile.c: All implementations adjusted.
7572 * tracefile.c: All implementations adjusted.
7573 * tracefile.h: All implementations adjusted.
7574 * windows-nat.c: All implementations adjusted.
7575 * x86-linux-nat.h: All implementations adjusted.
7576 * x86-nat.h: All implementations adjusted.
7578 2018-05-02 Pedro Alves <palves@redhat.com>
7580 * make-target-delegates (scan_target_h): Don't trim lines here.
7581 Replace sequences of tabs and/or whitespace with a single
7583 (top level, parsing methods): Trim each line before processing it
7586 2018-05-02 Pedro Alves <palves@redhat.com>
7587 John Baldwin <jhb@freebsd.org>
7589 * target.h (enum strata) <debug_stratum>: New.
7590 (struct target_ops) <all delegation methods>: Replace by C++
7591 virtual methods, and drop "to_" prefix. All references updated
7593 <to_shortname, to_longname, to_doc, to_data,
7594 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
7595 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
7596 virtual methods. All references updated throughout.
7597 <can_attach, supports_terminal_ours, can_create_inferior,
7598 get_thread_control_capabilities, attach_no_wait>: New
7600 <insert_breakpoint, remove_breakpoint>: Now
7601 TARGET_DEFAULT_NORETURN methods.
7602 <info_proc>: Now returns bool.
7604 (OPS_MAGIC): Delete.
7605 (current_target): Delete. All references replaced by references
7607 (target_stack): ... this. New.
7608 (target_shortname, target_longname): Adjust.
7609 (target_can_run): Now a function declaration.
7610 (default_child_has_all_memory, default_child_has_memory)
7611 (default_child_has_stack, default_child_has_registers)
7612 (default_child_has_execution): Remove target_ops parameter.
7613 (complete_target_initialization): Delete.
7614 (memory_breakpoint_target): New template class.
7615 (test_target_ops): Refactor as a C++ class with virtual methods.
7616 * make-target-delegates (NAME_PART): Tighten.
7617 (POINTER_PART, CP_SYMBOL): New.
7618 (SIMPLE_RETURN_PART): Reimplement.
7619 (VEC_RETURN_PART): Expect less.
7620 (RETURN_PART, VIRTUAL_PART): New.
7621 (METHOD): Adjust to C++ virtual methods.
7622 (scan_target_h): Remove reference to C99.
7623 (dname): Output "target_ops::" prefix.
7624 (write_function_header): Adjust to output a C++ class method.
7625 (write_declaration): New.
7626 (write_delegator): Adjust to output a C++ class method.
7627 (tdname): Output "dummy_target::" prefix.
7628 (write_tdefault, write_debugmethod): Adjust to output a C++ class
7630 (tdefault_names, debug_names): Delete.
7631 (return_types, tdefaults, styles, argtypes_array): New.
7632 (top level): All methods are delegators.
7634 (top level): Print dummy_target and debug_target classes.
7635 * target-delegates.c: Regenerate.
7636 * target-debug.h (target_debug_print_enum_info_proc_what)
7637 (target_debug_print_thread_control_capabilities)
7638 (target_debug_print_thread_info_p): New.
7639 * target.c (dummy_target): Delete.
7640 (the_dummy_target, the_debug_target): New.
7641 (target_stack): Now extern.
7642 (set_targetdebug): Push/unpush debug target.
7643 (default_child_has_all_memory, default_child_has_memory)
7644 (default_child_has_stack, default_child_has_registers)
7645 (default_child_has_execution): Remove target_ops parameter.
7646 (complete_target_initialization): Delete.
7647 (add_target_with_completer): No longer call
7648 complete_target_initialization.
7649 (target_supports_terminal_ours): Use regular delegation.
7650 (update_current_target): Delete.
7651 (push_target): No longer check magic number. Don't call
7652 update_current_target.
7653 (unpush_target): Don't call update_current_target.
7654 (target_is_pushed): No longer check magic number.
7655 (target_require_runnable): Skip for all stratums over
7657 (target_ops::info_proc): New.
7658 (target_info_proc): Use find_target_at and
7659 find_default_run_target.
7660 (target_supports_disable_randomization): Use regular delegation.
7661 (target_get_osdata): Use find_target_at.
7662 (target_ops::open, target_ops::close, target_ops::can_attach)
7663 (target_ops::attach, target_ops::can_create_inferior)
7664 (target_ops::create_inferior, target_ops::can_run)
7665 (target_can_run): New.
7666 (default_fileio_target): Use regular delegation.
7667 (target_ops::fileio_open, target_ops::fileio_pwrite)
7668 (target_ops::fileio_pread, target_ops::fileio_fstat)
7669 (target_ops::fileio_close, target_ops::fileio_unlink)
7670 (target_ops::fileio_readlink): New.
7671 (target_fileio_open_1, target_fileio_unlink)
7672 (target_fileio_readlink): Always call the target method. Handle
7674 (return_zero, return_zero_has_execution): Delete.
7675 (init_dummy_target): Delete.
7676 (dummy_target::dummy_target, dummy_target::shortname)
7677 (dummy_target::longname, dummy_target::doc)
7678 (debug_target::debug_target, debug_target::shortname)
7679 (debug_target::longname, debug_target::doc): New.
7680 (target_supports_delete_record): Use regular delegation.
7681 (setup_target_debug): Delete.
7682 (maintenance_print_target_stack): Skip debug_stratum.
7683 (initialize_targets): Instantiate the_dummy_target and
7685 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
7687 (target_auxv_search, fprint_target_auxv): Adjust.
7688 (info_auxv_command): Adjust to use target_stack.
7689 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
7690 * exceptions.c (print_flush): Handle a NULL target_stack.
7691 * regcache.c (target_ops_no_register): Refactor as class with
7694 * exec.c (exec_target): New class.
7695 (exec_ops): Now an exec_target.
7696 (exec_open, exec_close_1, exec_get_section_table)
7697 (exec_xfer_partial, exec_files_info, exec_has_memory)
7698 (exec_make_note_section): Refactor as exec_target methods.
7699 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
7701 (exec_target::find_memory_regions): New.
7702 (_initialize_exec): Don't call init_exec_ops.
7703 * gdbcore.h (exec_file_clear): Delete.
7705 * corefile.c (core_target): Delete.
7706 (core_file_command): Adjust.
7707 * corelow.c (core_target): New class.
7708 (the_core_target): New.
7709 (core_close): Remove target_ops parameter.
7710 (core_close_cleanup): Adjust.
7711 (core_target::close): New.
7712 (core_open, core_detach, get_core_registers, core_files_info)
7713 (core_xfer_partial, core_thread_alive, core_read_description)
7714 (core_pid_to_str, core_thread_name, core_has_memory)
7715 (core_has_stack, core_has_registers, core_info_proc): Rework as
7716 core_target methods.
7717 (ignore, core_remove_breakpoint, init_core_ops): Delete.
7718 (_initialize_corelow): Initialize the_core_target.
7719 * gdbcore.h (core_target): Delete.
7720 (the_core_target): New.
7722 * ctf.c: (ctf_target): New class.
7723 (ctf_ops): Now a ctf_target.
7724 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
7725 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
7726 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
7728 (init_ctf_ops): Delete.
7729 (_initialize_ctf): Don't call it.
7730 * tracefile-tfile.c (tfile_target): New class.
7731 (tfile_ops): Now a tfile_target.
7732 (tfile_open, tfile_close, tfile_files_info)
7733 (tfile_get_tracepoint_status, tfile_trace_find)
7734 (tfile_fetch_registers, tfile_xfer_partial)
7735 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
7736 Refactor as tfile_target methods.
7737 (tfile_xfer_partial_features): Remove target_ops parameter.
7738 (init_tfile_ops): Delete.
7739 (_initialize_tracefile_tfile): Don't call it.
7740 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
7741 (tracefile_has_stack, tracefile_has_registers)
7742 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
7743 tracefile_target methods.
7744 (init_tracefile_ops): Delete.
7745 (tracefile_target::tracefile_target): New.
7746 * tracefile.h: Include "target.h".
7747 (tracefile_target): New class.
7748 (init_tracefile_ops): Delete.
7750 * spu-multiarch.c (spu_multiarch_target): New class.
7751 (spu_ops): Now a spu_multiarch_target.
7752 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
7753 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
7754 (spu_search_memory, spu_mourn_inferior): Refactor as
7755 spu_multiarch_target methods.
7756 (init_spu_ops): Delete.
7757 (_initialize_spu_multiarch): Remove references to init_spu_ops,
7758 complete_target_initialization.
7760 * ravenscar-thread.c (ravenscar_thread_target): New class.
7761 (ravenscar_ops): Now a ravenscar_thread_target.
7762 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
7763 (ravenscar_thread_alive, ravenscar_pid_to_str)
7764 (ravenscar_fetch_registers, ravenscar_store_registers)
7765 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
7766 (ravenscar_stopped_by_hw_breakpoint)
7767 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
7768 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
7769 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
7771 (init_ravenscar_thread_ops): Delete.
7772 (_initialize_ravenscar): Remove references to
7773 init_ravenscar_thread_ops and complete_target_initialization.
7775 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
7776 (bsd_uthread_target): New class.
7777 (bsd_uthread_ops): Now a bsd_uthread_target.
7778 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
7779 (bsd_uthread_close, bsd_uthread_mourn_inferior)
7780 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
7781 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
7782 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
7783 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
7784 (bsd_uthread_target): Delete function.
7785 (_initialize_bsd_uthread): Remove reference to
7786 complete_target_initialization.
7788 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
7789 (target_bfd): ... this new class.
7790 (target_bfd_xfer_partial, target_bfd_get_section_table)
7791 (target_bfd_close): Refactor as target_bfd methods.
7792 (target_bfd::~target_bfd): New.
7793 (target_bfd_reopen): Adjust.
7794 (target_bfd::close): New.
7796 * record-btrace.c (record_btrace_target): New class.
7797 (record_btrace_ops): Now a record_btrace_target.
7798 (record_btrace_open, record_btrace_stop_recording)
7799 (record_btrace_disconnect, record_btrace_close)
7800 (record_btrace_async, record_btrace_info)
7801 (record_btrace_insn_history, record_btrace_insn_history_range)
7802 (record_btrace_insn_history_from, record_btrace_call_history)
7803 (record_btrace_call_history_range)
7804 (record_btrace_call_history_from, record_btrace_record_method)
7805 (record_btrace_is_replaying, record_btrace_will_replay)
7806 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
7807 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
7808 (record_btrace_store_registers, record_btrace_prepare_to_store)
7809 (record_btrace_to_get_unwinder)
7810 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
7811 (record_btrace_commit_resume, record_btrace_wait)
7812 (record_btrace_stop, record_btrace_can_execute_reverse)
7813 (record_btrace_stopped_by_sw_breakpoint)
7814 (record_btrace_supports_stopped_by_sw_breakpoint)
7815 (record_btrace_stopped_by_hw_breakpoint)
7816 (record_btrace_supports_stopped_by_hw_breakpoint)
7817 (record_btrace_update_thread_list, record_btrace_thread_alive)
7818 (record_btrace_goto_begin, record_btrace_goto_end)
7819 (record_btrace_goto, record_btrace_stop_replaying_all)
7820 (record_btrace_execution_direction)
7821 (record_btrace_prepare_to_generate_core)
7822 (record_btrace_done_generating_core): Refactor as
7823 record_btrace_target methods.
7824 (init_record_btrace_ops): Delete.
7825 (_initialize_record_btrace): Remove reference to
7826 init_record_btrace_ops.
7827 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
7828 the execution_direction global.
7829 (record_full_base_target, record_full_target)
7830 (record_full_core_target): New classes.
7831 (record_full_ops): Now a record_full_target.
7832 (record_full_core_ops): Now a record_full_core_target.
7833 (record_full_target::detach, record_full_target::disconnect)
7834 (record_full_core_target::disconnect)
7835 (record_full_target::mourn_inferior, record_full_target::kill):
7837 (record_full_open, record_full_close, record_full_async): Refactor
7838 as methods of the record_full_base_target class.
7839 (record_full_resume, record_full_commit_resume): Refactor
7840 as methods of the record_full_target class.
7841 (record_full_wait, record_full_stopped_by_watchpoint)
7842 (record_full_stopped_data_address)
7843 (record_full_stopped_by_sw_breakpoint)
7844 (record_full_supports_stopped_by_sw_breakpoint)
7845 (record_full_stopped_by_hw_breakpoint)
7846 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
7847 methods of the record_full_base_target class.
7848 (record_full_store_registers, record_full_xfer_partial)
7849 (record_full_insert_breakpoint, record_full_remove_breakpoint):
7850 Refactor as methods of the record_full_target class.
7851 (record_full_can_execute_reverse, record_full_get_bookmark)
7852 (record_full_goto_bookmark, record_full_execution_direction)
7853 (record_full_record_method, record_full_info, record_full_delete)
7854 (record_full_is_replaying, record_full_will_replay)
7855 (record_full_goto_begin, record_full_goto_end, record_full_goto)
7856 (record_full_stop_replaying): Refactor as methods of the
7857 record_full_base_target class.
7858 (record_full_core_resume, record_full_core_kill)
7859 (record_full_core_fetch_registers)
7860 (record_full_core_prepare_to_store)
7861 (record_full_core_store_registers, record_full_core_xfer_partial)
7862 (record_full_core_insert_breakpoint)
7863 (record_full_core_remove_breakpoint)
7864 (record_full_core_has_execution): Refactor
7865 as methods of the record_full_core_target class.
7866 (record_full_base_target::supports_delete_record): New.
7867 (init_record_full_ops): Delete.
7868 (init_record_full_core_ops): Delete.
7869 (record_full_save): Refactor as method of the
7870 record_full_base_target class.
7871 (_initialize_record_full): Remove references to
7872 init_record_full_ops and init_record_full_core_ops.
7874 * remote.c (remote_target, extended_remote_target): New classes.
7875 (remote_ops): Now a remote_target.
7876 (extended_remote_ops): Now an extended_remote_target.
7877 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
7878 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
7879 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
7880 (remote_pass_signals, remote_set_syscall_catchpoint)
7881 (remote_program_signals, )
7882 (remote_thread_always_alive): Remove target_ops parameter.
7883 (remote_thread_alive, remote_thread_name)
7884 (remote_update_thread_list, remote_threads_extra_info)
7885 (remote_static_tracepoint_marker_at)
7886 (remote_static_tracepoint_markers_by_strid)
7887 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
7888 (remote_open): Refactor as methods of remote_target.
7889 (extended_remote_open, extended_remote_detach)
7890 (extended_remote_attach, extended_remote_post_attach):
7891 (extended_remote_supports_disable_randomization)
7892 (extended_remote_create_inferior): : Refactor as method of
7893 extended_remote_target.
7894 (remote_set_permissions, remote_open_1, remote_detach)
7895 (remote_follow_fork, remote_follow_exec, remote_disconnect)
7896 (remote_resume, remote_commit_resume, remote_stop)
7897 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
7898 (remote_terminal_ours, remote_wait, remote_fetch_registers)
7899 (remote_prepare_to_store, remote_store_registers)
7900 (remote_flash_erase, remote_flash_done, remote_files_info)
7901 (remote_kill, remote_mourn, remote_insert_breakpoint)
7902 (remote_remove_breakpoint, remote_insert_watchpoint)
7903 (remote_watchpoint_addr_within_range)
7904 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
7905 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
7906 (remote_supports_stopped_by_sw_breakpoint)
7907 (remote_stopped_by_hw_breakpoint)
7908 (remote_supports_stopped_by_hw_breakpoint)
7909 (remote_stopped_by_watchpoint, remote_stopped_data_address)
7910 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
7911 (remote_verify_memory): Refactor as methods of remote_target.
7912 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
7914 (remote_xfer_partial, remote_get_memory_xfer_limit)
7915 (remote_search_memory, remote_rcmd, remote_memory_map)
7916 (remote_pid_to_str, remote_get_thread_local_address)
7917 (remote_get_tib_address, remote_read_description): Refactor as
7918 methods of remote_target.
7919 (remote_target::fileio_open, remote_target::fileio_pwrite)
7920 (remote_target::fileio_pread, remote_target::fileio_close): New.
7921 (remote_hostio_readlink, remote_hostio_fstat)
7922 (remote_filesystem_is_local, remote_can_execute_reverse)
7923 (remote_supports_non_stop, remote_supports_disable_randomization)
7924 (remote_supports_multi_process, remote_supports_cond_breakpoints)
7925 (remote_supports_enable_disable_tracepoint)
7926 (remote_supports_string_tracing)
7927 (remote_can_run_breakpoint_commands, remote_trace_init)
7928 (remote_download_tracepoint, remote_can_download_tracepoint)
7929 (remote_download_trace_state_variable, remote_enable_tracepoint)
7930 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
7931 (remote_trace_start, remote_get_trace_status)
7932 (remote_get_tracepoint_status, remote_trace_stop)
7933 (remote_trace_find, remote_get_trace_state_variable_value)
7934 (remote_save_trace_data, remote_get_raw_trace_data)
7935 (remote_set_disconnected_tracing, remote_core_of_thread)
7936 (remote_set_circular_trace_buffer, remote_traceframe_info)
7937 (remote_get_min_fast_tracepoint_insn_len)
7938 (remote_set_trace_buffer_size, remote_set_trace_notes)
7939 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
7940 (remote_disable_btrace, remote_teardown_btrace)
7941 (remote_read_btrace, remote_btrace_conf)
7942 (remote_augmented_libraries_svr4_read, remote_load)
7943 (remote_pid_to_exec_file, remote_can_do_single_step)
7944 (remote_execution_direction, remote_thread_handle_to_thread_info):
7945 Refactor as methods of remote_target.
7946 (init_remote_ops, init_extended_remote_ops): Delete.
7947 (remote_can_async_p, remote_is_async_p, remote_async)
7948 (remote_thread_events, remote_upload_tracepoints)
7949 (remote_upload_trace_state_variables): Refactor as methods of
7951 (_initialize_remote): Remove references to init_remote_ops and
7952 init_extended_remote_ops.
7954 * remote-sim.c (gdbsim_target): New class.
7955 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
7956 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
7957 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
7958 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
7959 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
7960 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
7961 Refactor as methods of gdbsim_target.
7962 (gdbsim_ops): Now a gdbsim_target.
7963 (init_gdbsim_ops): Delete.
7964 (gdbsim_cntrl_c): Adjust.
7965 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
7967 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
7968 (the_amd64_linux_nat_target): New.
7969 (amd64_linux_fetch_inferior_registers)
7970 (amd64_linux_store_inferior_registers): Refactor as methods of
7971 amd64_linux_nat_target.
7972 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
7973 * i386-linux-nat.c: Don't include "linux-nat.h".
7974 (i386_linux_nat_target): New class.
7975 (the_i386_linux_nat_target): New.
7976 (i386_linux_fetch_inferior_registers)
7977 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
7978 as methods of i386_linux_nat_target.
7979 (_initialize_i386_linux_nat): Adjust. Set linux_target.
7980 * inf-child.c (inf_child_ops): Delete.
7981 (inf_child_fetch_inferior_registers)
7982 (inf_child_store_inferior_registers): Delete.
7983 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
7984 methods of inf_child_target.
7985 (inf_child_target::supports_terminal_ours)
7986 (inf_child_target::terminal_init)
7987 (inf_child_target::terminal_inferior)
7988 (inf_child_target::terminal_ours_for_output)
7989 (inf_child_target::terminal_ours, inf_child_target::interrupt)
7990 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
7992 (inf_child_open, inf_child_disconnect, inf_child_close)
7993 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
7994 (inf_child_post_startup_inferior, inf_child_can_run)
7995 (inf_child_pid_to_exec_file): Refactor as methods of
7997 (inf_child_follow_fork): Delete.
7998 (inf_child_target::can_create_inferior)
7999 (inf_child_target::can_attach): New.
8000 (inf_child_target::has_all_memory, inf_child_target::has_memory)
8001 (inf_child_target::has_stack, inf_child_target::has_registers)
8002 (inf_child_target::has_execution): New.
8003 (inf_child_fileio_open, inf_child_fileio_pwrite)
8004 (inf_child_fileio_pread, inf_child_fileio_fstat)
8005 (inf_child_fileio_close, inf_child_fileio_unlink)
8006 (inf_child_fileio_readlink, inf_child_use_agent)
8007 (inf_child_can_use_agent): Refactor as methods of
8009 (return_zero, inf_child_target): Delete.
8010 (inf_child_target::inf_child_target): New.
8011 * inf-child.h: Include "target.h".
8012 (inf_child_target): Delete function prototype.
8013 (inf_child_target): New class.
8014 (inf_child_open_target, inf_child_mourn_inferior)
8015 (inf_child_maybe_unpush_target): Delete.
8016 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
8017 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
8018 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
8019 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
8020 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
8021 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
8022 (inf_ptrace_wait, inf_ptrace_xfer_partial)
8023 (inf_ptrace_thread_alive, inf_ptrace_files_info)
8024 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
8025 methods of inf_ptrace_target.
8026 (inf_ptrace_target): Delete function.
8027 * inf-ptrace.h: Include "inf-child.h".
8028 (inf_ptrace_target): Delete function declaration.
8029 (inf_ptrace_target): New class.
8030 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
8031 * linux-nat.c (linux_target): New.
8032 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
8033 (linux_nat_target::~linux_nat_target): New.
8034 (linux_child_post_attach, linux_child_post_startup_inferior)
8035 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
8036 (linux_child_remove_fork_catchpoint)
8037 (linux_child_insert_vfork_catchpoint)
8038 (linux_child_remove_vfork_catchpoint)
8039 (linux_child_insert_exec_catchpoint)
8040 (linux_child_remove_exec_catchpoint)
8041 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
8042 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
8043 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
8044 (linux_nat_stopped_data_address)
8045 (linux_nat_stopped_by_sw_breakpoint)
8046 (linux_nat_supports_stopped_by_sw_breakpoint)
8047 (linux_nat_stopped_by_hw_breakpoint)
8048 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
8049 (linux_nat_kill, linux_nat_mourn_inferior)
8050 (linux_nat_xfer_partial, linux_nat_thread_alive)
8051 (linux_nat_update_thread_list, linux_nat_pid_to_str)
8052 (linux_nat_thread_name, linux_child_pid_to_exec_file)
8053 (linux_child_static_tracepoint_markers_by_strid)
8054 (linux_nat_is_async_p, linux_nat_can_async_p)
8055 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
8056 (linux_nat_supports_multi_process)
8057 (linux_nat_supports_disable_randomization, linux_nat_async)
8058 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
8059 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
8060 (linux_nat_fileio_open, linux_nat_fileio_readlink)
8061 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
8062 methods of linux_nat_target.
8063 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
8064 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
8066 (check_stopped_by_watchpoint): Adjust.
8067 (linux_xfer_partial): Delete.
8068 (linux_target_install_ops, linux_target, linux_nat_add_target):
8070 (linux_nat_target::linux_nat_target): New.
8071 * linux-nat.h: Include "inf-ptrace.h".
8072 (linux_nat_target): New.
8073 (linux_target, linux_target_install_ops, linux_nat_add_target):
8074 Delete function declarations.
8075 (linux_target): Declare global.
8076 * linux-thread-db.c (thread_db_target): New.
8077 (thread_db_target::thread_db_target): New.
8078 (thread_db_ops): Delete.
8079 (the_thread_db_target): New.
8080 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
8081 (thread_db_update_thread_list, thread_db_pid_to_str)
8082 (thread_db_extra_thread_info)
8083 (thread_db_thread_handle_to_thread_info)
8084 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
8085 (thread_db_resume): Refactor as methods of thread_db_target.
8086 (init_thread_db_ops): Delete.
8087 (_initialize_thread_db): Remove reference to init_thread_db_ops.
8088 * x86-linux-nat.c: Don't include "linux-nat.h".
8089 (super_post_startup_inferior): Delete.
8090 (x86_linux_nat_target::~x86_linux_nat_target): New.
8091 (x86_linux_child_post_startup_inferior)
8092 (x86_linux_read_description, x86_linux_enable_btrace)
8093 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
8094 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
8095 methods of x86_linux_nat_target.
8096 (x86_linux_create_target): Delete. Bits folded ...
8097 (x86_linux_add_target): ... here. Now takes a linux_nat_target
8099 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
8100 (x86_linux_nat_target): New class.
8101 (x86_linux_create_target): Delete.
8102 (x86_linux_add_target): Now takes a linux_nat_target pointer.
8103 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
8104 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
8105 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
8106 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
8107 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
8109 (x86_use_watchpoints): Delete.
8110 * x86-nat.h: Include "breakpoint.h" and "target.h".
8111 (x86_use_watchpoints): Delete.
8112 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
8113 (x86_stopped_by_watchpoint, x86_stopped_data_address)
8114 (x86_insert_watchpoint, x86_remove_watchpoint)
8115 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
8116 (x86_stopped_by_hw_breakpoint): New declarations.
8117 (x86_nat_target): New template class.
8119 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
8120 (the_ppc_linux_nat_target): New.
8121 (ppc_linux_fetch_inferior_registers)
8122 (ppc_linux_can_use_hw_breakpoint)
8123 (ppc_linux_region_ok_for_hw_watchpoint)
8124 (ppc_linux_ranged_break_num_registers)
8125 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
8126 (ppc_linux_insert_mask_watchpoint)
8127 (ppc_linux_remove_mask_watchpoint)
8128 (ppc_linux_can_accel_watchpoint_condition)
8129 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
8130 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
8131 (ppc_linux_watchpoint_addr_within_range)
8132 (ppc_linux_masked_watch_num_registers)
8133 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
8134 (ppc_linux_read_description): Refactor as methods of
8135 ppc_linux_nat_target.
8136 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
8138 * procfs.c (procfs_xfer_partial): Delete forward declaration.
8139 (procfs_target): New class.
8140 (the_procfs_target): New.
8141 (procfs_target): Delete function.
8142 (procfs_auxv_parse, procfs_attach, procfs_detach)
8143 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
8144 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
8145 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
8146 (procfs_create_inferior, procfs_update_thread_list)
8147 (procfs_thread_alive, procfs_pid_to_str)
8148 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
8149 (procfs_stopped_data_address, procfs_insert_watchpoint)
8150 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
8151 (proc_find_memory_regions, procfs_info_proc)
8152 (procfs_make_note_section): Refactor as methods of procfs_target.
8153 (_initialize_procfs): Adjust.
8154 * sol-thread.c (sol_thread_target): New class.
8155 (sol_thread_ops): Now a sol_thread_target.
8156 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
8157 (sol_thread_fetch_registers, sol_thread_store_registers)
8158 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
8159 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
8160 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
8161 (init_sol_thread_ops): Delete.
8162 (_initialize_sol_thread): Adjust. Remove references to
8163 init_sol_thread_ops and complete_target_initialization.
8165 * windows-nat.c (windows_nat_target): New class.
8166 (windows_fetch_inferior_registers)
8167 (windows_store_inferior_registers, windows_resume, windows_wait)
8168 (windows_attach, windows_detach, windows_pid_to_exec_file)
8169 (windows_files_info, windows_create_inferior)
8170 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
8171 (windows_close, windows_pid_to_str, windows_xfer_partial)
8172 (windows_get_tib_address, windows_get_ada_task_ptid)
8173 (windows_thread_name, windows_thread_alive): Refactor as
8174 windows_nat_target methods.
8175 (do_initial_windows_stuff): Adjust.
8176 (windows_target): Delete function.
8177 (_initialize_windows_nat): Adjust.
8179 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
8180 (darwin_mourn_inferior, darwin_kill_inferior)
8181 (darwin_create_inferior, darwin_attach, darwin_detach)
8182 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
8183 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
8184 (darwin_supports_multi_process): Refactor as darwin_nat_target
8186 (darwin_resume_to, darwin_files_info): Delete.
8187 (_initialize_darwin_inferior): Rename to ...
8188 (_initialize_darwin_nat): ... this. Adjust to C++ification.
8189 * darwin-nat.h: Include "inf-child.h".
8190 (darwin_nat_target): New class.
8191 (darwin_complete_target): Delete.
8192 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
8193 (darwin_target): New.
8194 (i386_darwin_fetch_inferior_registers)
8195 (i386_darwin_store_inferior_registers): Refactor as methods of
8197 (darwin_complete_target): Delete, with ...
8198 (_initialize_i386_darwin_nat): ... bits factored out here.
8200 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
8201 (the_alpha_linux_nat_target): New.
8202 (alpha_linux_register_u_offset): Refactor as
8203 alpha_linux_nat_target method.
8204 (_initialize_alpha_linux_nat): Adjust.
8205 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
8206 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8207 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
8208 methods of linux_nat_trad_target.
8209 (linux_trad_target): Delete.
8210 * linux-nat-trad.h (linux_trad_target): Delete function.
8211 (linux_nat_trad_target): New class.
8212 * mips-linux-nat.c (mips_linux_nat_target): New class.
8213 (super_fetch_registers, super_store_registers, super_close):
8215 (the_mips_linux_nat_target): New.
8216 (mips64_linux_regsets_fetch_registers)
8217 (mips64_linux_regsets_store_registers)
8218 (mips64_linux_fetch_registers, mips64_linux_store_registers)
8219 (mips_linux_register_u_offset, mips_linux_read_description)
8220 (mips_linux_can_use_hw_breakpoint)
8221 (mips_linux_stopped_by_watchpoint)
8222 (mips_linux_stopped_data_address)
8223 (mips_linux_region_ok_for_hw_watchpoint)
8224 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
8225 (mips_linux_close): Refactor as methods of mips_linux_nat.
8226 (_initialize_mips_linux_nat): Adjust to C++ification.
8228 * aix-thread.c (aix_thread_target): New class.
8229 (aix_thread_ops): Now an aix_thread_target.
8230 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
8231 (aix_thread_fetch_registers, aix_thread_store_registers)
8232 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
8233 (aix_thread_thread_alive, aix_thread_pid_to_str)
8234 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
8235 Refactor as methods of aix_thread_target.
8236 (init_aix_thread_ops): Delete.
8237 (_initialize_aix_thread): Remove references to init_aix_thread_ops
8238 and complete_target_initialization.
8239 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
8240 (rs6000_nat_target): New class.
8241 (the_rs6000_nat_target): New.
8242 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
8243 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
8244 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
8245 (super_create_inferior): Delete.
8246 (_initialize_rs6000_nat): Adjust to C++ification.
8248 * arm-linux-nat.c (arm_linux_nat_target): New class.
8249 (the_arm_linux_nat_target): New.
8250 (arm_linux_fetch_inferior_registers)
8251 (arm_linux_store_inferior_registers, arm_linux_read_description)
8252 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
8253 (arm_linux_remove_hw_breakpoint)
8254 (arm_linux_region_ok_for_hw_watchpoint)
8255 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
8256 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
8257 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
8258 arm_linux_nat_target.
8259 (_initialize_arm_linux_nat): Adjust to C++ification.
8261 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
8262 (the_aarch64_linux_nat_target): New.
8263 (aarch64_linux_fetch_inferior_registers)
8264 (aarch64_linux_store_inferior_registers)
8265 (aarch64_linux_child_post_startup_inferior)
8266 (aarch64_linux_read_description)
8267 (aarch64_linux_can_use_hw_breakpoint)
8268 (aarch64_linux_insert_hw_breakpoint)
8269 (aarch64_linux_remove_hw_breakpoint)
8270 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
8271 (aarch64_linux_region_ok_for_hw_watchpoint)
8272 (aarch64_linux_stopped_data_address)
8273 (aarch64_linux_stopped_by_watchpoint)
8274 (aarch64_linux_watchpoint_addr_within_range)
8275 (aarch64_linux_can_do_single_step): Refactor as methods of
8276 aarch64_linux_nat_target.
8277 (super_post_startup_inferior): Delete.
8278 (_initialize_aarch64_linux_nat): Adjust to C++ification.
8280 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
8281 (the_hppa_linux_nat_target): New.
8282 (hppa_linux_fetch_inferior_registers)
8283 (hppa_linux_store_inferior_registers): Refactor as methods of
8284 hppa_linux_nat_target.
8285 (_initialize_hppa_linux_nat): Adjust to C++ification.
8287 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
8288 (the_ia64_linux_nat_target): New.
8289 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
8290 (ia64_linux_stopped_data_address)
8291 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
8292 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
8293 ia64_linux_nat_target methods.
8294 (super_xfer_partial): Delete.
8295 (_initialize_ia64_linux_nat): Adjust to C++ification.
8297 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
8298 (the_m32r_linux_nat_target): New.
8299 (m32r_linux_fetch_inferior_registers)
8300 (m32r_linux_store_inferior_registers): Refactor as
8301 m32r_linux_nat_target methods.
8302 (_initialize_m32r_linux_nat): Adjust to C++ification.
8304 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
8305 (the_m68k_linux_nat_target): New.
8306 (m68k_linux_fetch_inferior_registers)
8307 (m68k_linux_store_inferior_registers): Refactor as
8308 m68k_linux_nat_target methods.
8309 (_initialize_m68k_linux_nat): Adjust to C++ification.
8311 * s390-linux-nat.c (s390_linux_nat_target): New class.
8312 (the_s390_linux_nat_target): New.
8313 (s390_linux_fetch_inferior_registers)
8314 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
8315 (s390_insert_watchpoint, s390_remove_watchpoint)
8316 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
8317 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
8318 (s390_auxv_parse, s390_read_description): Refactor as methods of
8319 s390_linux_nat_target.
8320 (_initialize_s390_nat): Adjust to C++ification.
8322 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
8323 (the_sparc_linux_nat_target): New.
8324 (_initialize_sparc_linux_nat): Adjust to C++ification.
8325 * sparc-nat.c (sparc_fetch_inferior_registers)
8326 (sparc_store_inferior_registers): Remove target_ops parameter.
8327 * sparc-nat.h (sparc_fetch_inferior_registers)
8328 (sparc_store_inferior_registers): Remove target_ops parameter.
8329 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
8330 (the_sparc64_linux_nat_target): New.
8331 (_initialize_sparc64_linux_nat): Adjust to C++ification.
8333 * spu-linux-nat.c (spu_linux_nat_target): New class.
8334 (the_spu_linux_nat_target): New.
8335 (spu_child_post_startup_inferior, spu_child_post_attach)
8336 (spu_child_wait, spu_fetch_inferior_registers)
8337 (spu_store_inferior_registers, spu_xfer_partial)
8338 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
8340 (_initialize_spu_nat): Adjust to C++ification.
8342 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
8343 (the_tilegx_linux_nat_target): New.
8344 (fetch_inferior_registers, store_inferior_registers):
8345 Refactor as methods.
8346 (_initialize_tile_linux_nat): Adjust to C++ification.
8348 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
8349 (the_xtensa_linux_nat_target): New.
8350 (xtensa_linux_fetch_inferior_registers)
8351 (xtensa_linux_store_inferior_registers): Refactor as
8352 xtensa_linux_nat_target methods.
8353 (_initialize_xtensa_linux_nat): Adjust to C++ification.
8355 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
8356 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
8357 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
8358 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
8359 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
8360 (fbsd_stopped_by_sw_breakpoint)
8361 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
8362 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
8363 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
8364 (fbsd_post_startup_inferior, fbsd_post_attach)
8365 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
8366 (fbsd_set_syscall_catchpoint)
8367 (super_xfer_partial, super_resume, super_wait)
8368 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
8369 (fbsd_handle_debug_trap): Remove target_ops parameter.
8370 (fbsd_nat_add_target): Delete.
8371 * fbsd-nat.h: Include "inf-ptrace.h".
8372 (fbsd_nat_add_target): Delete.
8373 (USE_SIGTRAP_SIGINFO): Define.
8374 (fbsd_nat_target): New class.
8376 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
8377 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
8378 (amd64bsd_target): Delete.
8379 * amd64-bsd-nat.h: New file.
8380 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
8382 (amd64_fbsd_nat_target): New class.
8383 (the_amd64_fbsd_nat_target): New.
8384 (amd64fbsd_read_description): Refactor as method of
8385 amd64_fbsd_nat_target.
8386 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8387 (_initialize_amd64fbsd_nat): Adjust to C++ification.
8388 * amd64-nat.h (amd64bsd_target): Delete function declaration.
8389 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
8390 (i386bsd_store_inferior_registers): Remove target_ops parameter.
8391 (i386bsd_target): Delete.
8392 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
8393 (i386bsd_fetch_inferior_registers)
8394 (i386bsd_store_inferior_registers): Declare.
8395 (i386_bsd_nat_target): New class.
8396 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
8397 (the_i386_fbsd_nat_target): New.
8398 (i386fbsd_resume, i386fbsd_read_description): Refactor as
8399 i386_fbsd_nat_target methods.
8400 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8401 (_initialize_i386fbsd_nat): Adjust to C++ification.
8402 * x86-bsd-nat.c (super_mourn_inferior): Delete.
8403 (x86bsd_mourn_inferior, x86bsd_target): Delete.
8404 (_initialize_x86_bsd_nat): Adjust to C++ification.
8405 * x86-bsd-nat.h: Include "x86-nat.h".
8406 (x86bsd_target): Delete declaration.
8407 (x86bsd_nat_target): New class.
8409 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
8410 (the_aarch64_fbsd_nat_target): New.
8411 (aarch64_fbsd_fetch_inferior_registers)
8412 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
8413 aarch64_fbsd_nat_target.
8414 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
8415 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
8416 (the_alpha_bsd_nat_target): New.
8417 (alphabsd_fetch_inferior_registers)
8418 (alphabsd_store_inferior_registers): Refactor as
8419 alpha_bsd_nat_target methods.
8420 (_initialize_alphabsd_nat): Refactor as methods of
8421 alpha_bsd_nat_target.
8422 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
8423 (the_amd64_nbsd_nat_target): New.
8424 (_initialize_amd64nbsd_nat): Adjust to C++ification.
8425 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
8426 (the_amd64_obsd_nat_target): New.
8427 (_initialize_amd64obsd_nat): Adjust to C++ification.
8428 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
8429 (the_arm_fbsd_nat_target): New.
8430 (arm_fbsd_fetch_inferior_registers)
8431 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
8432 (_initialize_arm_fbsd_nat): Refactor as methods of
8433 arm_fbsd_nat_target.
8434 (_initialize_arm_fbsd_nat): Adjust to C++ification.
8435 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
8436 (the_arm_netbsd_nat_target): New.
8437 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
8438 arm_netbsd_nat_target.
8439 (_initialize_arm_netbsd_nat): Adjust to C++ification.
8440 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
8441 (the_hppa_nbsd_nat_target): New.
8442 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
8443 hppa_nbsd_nat_target methods.
8444 (_initialize_hppanbsd_nat): Adjust to C++ification.
8445 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
8446 (the_hppa_obsd_nat_target): New.
8447 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
8448 methods of hppa_obsd_nat_target.
8449 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
8451 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
8452 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
8454 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
8455 (_initialize_i386obsd_nat): Use add_target.
8456 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
8457 (the_m68k_bsd_nat_target): New.
8458 (m68kbsd_fetch_inferior_registers)
8459 (m68kbsd_store_inferior_registers): Refactor as methods of
8460 m68k_bsd_nat_target.
8461 (_initialize_m68kbsd_nat): Adjust to C++ification.
8462 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
8463 (the_mips_fbsd_nat_target): New.
8464 (mips_fbsd_fetch_inferior_registers)
8465 (mips_fbsd_store_inferior_registers): Refactor as methods of
8466 mips_fbsd_nat_target.
8467 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
8469 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
8470 (the_mips_nbsd_nat_target): New.
8471 (mipsnbsd_fetch_inferior_registers)
8472 (mipsnbsd_store_inferior_registers): Refactor as methods of
8473 mips_nbsd_nat_target.
8474 (_initialize_mipsnbsd_nat): Adjust to C++ification.
8475 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
8476 (the_mips64_obsd_nat_target): New.
8477 (mips64obsd_fetch_inferior_registers)
8478 (mips64obsd_store_inferior_registers): Refactor as methods of
8479 mips64_obsd_nat_target.
8480 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
8482 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
8484 * nbsd-nat.h: Include "inf-ptrace.h".
8485 (nbsd_nat_target): New class.
8486 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
8487 (obsd_wait): Refactor as methods of obsd_nat_target.
8488 (obsd_add_target): Delete.
8489 * obsd-nat.h: Include "inf-ptrace.h".
8490 (obsd_nat_target): New class.
8491 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
8492 (the_ppc_fbsd_nat_target): New.
8493 (ppcfbsd_fetch_inferior_registers)
8494 (ppcfbsd_store_inferior_registers): Refactor as methods of
8495 ppc_fbsd_nat_target.
8496 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
8498 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
8499 (the_ppc_nbsd_nat_target): New.
8500 (ppcnbsd_fetch_inferior_registers)
8501 (ppcnbsd_store_inferior_registers): Refactor as methods of
8502 ppc_nbsd_nat_target.
8503 (_initialize_ppcnbsd_nat): Adjust to C++ification.
8504 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
8505 (the_ppc_obsd_nat_target): New.
8506 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
8507 methods of ppc_obsd_nat_target.
8508 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
8510 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
8511 (the_sh_nbsd_nat_target): New.
8512 (shnbsd_fetch_inferior_registers)
8513 (shnbsd_store_inferior_registers): Refactor as methods of
8515 (_initialize_shnbsd_nat): Adjust to C++ification.
8516 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
8517 (inf_ptrace_xfer_partial): Delete.
8518 (sparc_xfer_partial, sparc_target): Delete.
8519 * sparc-nat.h (sparc_fetch_inferior_registers)
8520 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
8521 (sparc_target): Delete function declaration.
8522 (sparc_target): New template class.
8523 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
8524 (_initialize_sparcnbsd_nat): Adjust to C++ification.
8525 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
8526 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
8528 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
8529 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
8530 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
8531 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
8533 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
8534 (the_vax_bsd_nat_target): New.
8535 (vaxbsd_fetch_inferior_registers)
8536 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
8538 (_initialize_vaxbsd_nat): Adjust to C++ification.
8540 * bsd-kvm.c (bsd_kvm_target): New class.
8541 (bsd_kvm_ops): Now a bsd_kvm_target.
8542 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
8543 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
8544 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
8546 (bsd_kvm_return_one): Delete.
8547 (bsd_kvm_add_target): Adjust to C++ification.
8549 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
8550 (nto_procfs_target_procfs): New classes.
8551 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
8552 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
8553 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
8554 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
8555 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
8556 (procfs_remove_hw_breakpoint, procfs_resume)
8557 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
8558 (procfs_kill_inferior, procfs_store_registers)
8559 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
8560 as methods of nto_procfs_target.
8561 (nto_procfs_ops): Now an nto_procfs_target_procfs.
8562 (nto_native_ops): Delete.
8563 (procfs_open, procfs_native_open): Delete.
8564 (nto_native_ops): Now an nto_procfs_target_native.
8565 (init_procfs_targets): Adjust to C++ification.
8566 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
8567 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
8568 Refactor as methods of nto_procfs_target.
8570 * go32-nat.c (go32_nat_target): New class.
8571 (the_go32_nat_target): New.
8572 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
8573 (go32_store_registers, go32_xfer_partial, go32_files_info)
8574 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
8575 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
8576 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
8577 (go32_pid_to_str): Refactor as methods of go32_nat_target.
8578 (go32_target): Delete.
8579 (_initialize_go32_nat): Adjust to C++ification.
8581 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
8582 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
8583 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
8584 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
8586 (gnu_target): Delete.
8587 * gnu-nat.h (gnu_target): Delete.
8588 (gnu_nat_target): New class.
8589 * i386-gnu-nat.c (gnu_base_target): New.
8590 (i386_gnu_nat_target): New class.
8591 (the_i386_gnu_nat_target): New.
8592 (_initialize_i386gnu_nat): Adjust to C++ification.
8594 2018-05-02 Pedro Alves <palves@redhat.com>
8596 * bfd-target.c (target_bfd_xclose): Rename to ...
8597 (target_bfd_close): ... this.
8598 (target_bfd_reopen): Adjust.
8599 * target.c (target_close): Remove references to to_xclose.
8600 * target.h (target_ops::to_xclose): Delete.
8601 (target_ops::to_close): Update comments.
8603 2018-05-02 Pedro Alves <palves@redhat.com>
8605 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
8607 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
8608 * inf-ptrace.c (inf_ptrace_register_u_offset)
8609 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8610 (inf_ptrace_store_register, inf_ptrace_store_registers)
8611 (inf_ptrace_trad_target): Move to ...
8612 * linux-nat-trad.c: ... this new file.
8613 * linux-nat-trad.h: New file.
8614 * linux-nat.c (linux_target_install_ops): Make extern.
8615 (linux_trad_target): Delete.
8616 * linux-nat.h (linux_trad_target): Delete declaration.
8617 (linux_target_install_ops): Declare.
8618 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
8621 2018-05-02 Pedro Alves <palves@redhat.com>
8623 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8624 procfs_target/add_target here.
8625 * procfs.c (procfs_target): Make static.
8626 (_initialize_procfs): Call add_target here.
8627 * procfs.h (struct target_ops): Remove forward declaration.
8628 (procfs_target): Remove declaration.
8629 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
8631 2018-05-02 Pedro Alves <palves@redhat.com>
8633 * procfs.c (procfs_stopped_by_watchpoint)
8634 (procfs_insert_watchpoint, procfs_remove_watchpoint)
8635 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
8637 (procfs_use_watchpoints): Delete, move contents...
8638 (procfs_target): ... here.
8639 * procfs.h (procfs_use_watchpoints): Delete declaration.
8640 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8641 procfs_use_watchpoints.
8642 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
8643 procfs_use_watchpoints.
8645 2018-05-02 Tom Tromey <tom@tromey.com>
8648 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
8649 and var_zuinteger_unlimited.
8650 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
8651 and PARAM_ZUINTEGER_UNLIMITED.
8652 (set_parameter_value): Handle var_zuinteger and
8653 var_zuinteger_unlimited.
8654 (add_setshow_generic): Likewise.
8655 (parmpy_init): Likewise.
8657 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
8660 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
8661 pointer is not null before dereferencing it.
8663 2018-04-30 Tom Tromey <tom@tromey.com>
8665 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
8668 2018-04-30 Tom Tromey <tom@tromey.com>
8670 * breakpoint.c (mention): Remove use of is_mi_like_p.
8671 (print_mention_ranged_breakpoint): Likewise.
8672 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
8675 2018-04-30 Tom Tromey <tom@tromey.com>
8677 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
8679 2018-04-30 Tom Tromey <tom@tromey.com>
8681 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
8682 (info_spu_event_command): Remove some uses of is_mi_like_p.
8684 2018-04-30 Tom Tromey <tom@tromey.com>
8686 * python/py-framefilter.c (py_print_single_arg)
8687 (enumerate_locals, py_print_args, py_print_frame): Remove some
8688 uses of is_mi_like_p.
8690 2018-04-30 Tom Tromey <tom@tromey.com>
8693 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
8694 * ui-out.h (ui_out::is_mi_like_p): Now const.
8695 (ui_out::do_is_mi_like_p): Now const.
8696 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
8698 2018-04-30 Tom Tromey <tom@tromey.com>
8700 * varobj.c (varobj_set_visualizer): Use new_reference.
8701 * python/python.c (gdbpy_decode_line): Use new_reference.
8702 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
8705 2018-04-30 Tom Tromey <tom@tromey.com>
8707 * varobj.c (install_new_value): Use new_reference.
8708 * value.h (value_incref): Return void. Swap intro comment with
8710 * value.c (set_value_parent): Use new_reference.
8711 (value_incref): Return void. Update intro comment.
8712 (release_value): Use new_reference.
8713 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
8715 2018-04-30 Tom Tromey <tom@tromey.com>
8717 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
8718 * gdb_bfd.h (new_bfd_ref): Remove.
8719 (gdb_bfd_open): Update comment.
8720 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
8721 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
8722 (gdb_bfd_fdopenr): Use new_reference.
8723 * exec.c (exec_file_attach): Use new_reference.
8725 2018-04-30 Tom Tromey <tom@tromey.com>
8727 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
8730 2018-04-30 Tom Tromey <tom@tromey.com>
8732 * jit.c (jit_read_code_entry): Use type_align.
8733 * i386-tdep.c (i386_gdbarch_init): Don't call
8734 set_gdbarch_long_long_align_bit.
8735 * gdbarch.sh: Remove long_long_align_bit.
8736 * gdbarch.c, gdbarch.h: Rebuild.
8737 * arc-tdep.c (arc_type_align): New function.
8738 (arc_gdbarch_init): Use arc_type_align. Don't call
8739 set_gdbarch_long_long_align_bit.
8741 2018-04-30 Tom Tromey <tom@tromey.com>
8743 * rust-lang.c (rust_type_alignment): Remove.
8744 (rust_composite_type): Use type_align.
8746 2018-04-30 Tom Tromey <tom@tromey.com>
8748 * NEWS: Mention Type.align.
8749 * python/py-type.c (typy_get_alignof): New function.
8750 (type_object_getset): Add "alignof".
8752 2018-04-30 Tom Tromey <tom@tromey.com>
8756 * std-operator.def (UNOP_ALIGNOF): New operator.
8757 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
8759 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
8760 * c-lang.c (c_op_print_tab): Add alignof.
8761 * c-exp.y (ALIGNOF): New token.
8762 (exp): Add "ALIGNOF" production.
8763 (ident_tokens): Add _Alignof and alignof.
8765 2018-04-30 Tom Tromey <tom@tromey.com>
8767 * i386-tdep.c (i386_type_align): New function.
8768 (i386_gdbarch_init): Update.
8769 * gdbarch.sh (type_align): New method.
8770 * gdbarch.c, gdbarch.h: Rebuild.
8771 * arch-utils.h (default_type_align): Declare.
8772 * arch-utils.c (default_type_align): New function.
8773 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
8774 (struct type) <align_log2>: New field.
8775 <instance_flags>: Now a bitfield.
8776 (TYPE_RAW_ALIGN): New macro.
8777 (type_align, type_raw_align, set_type_align): Declare.
8778 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
8780 * dwarf2read.c (quirk_rust_enum): Set type alignment.
8781 (get_alignment, maybe_set_alignment): New functions.
8782 (read_structure_type, read_enumeration_type, read_array_type)
8783 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
8784 (read_subrange_type, read_base_type): Set type alignment.
8786 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
8788 * dwarf2read.c (read_index_from_section): Use bool.
8790 2018-04-29 Fabian Groffen <grobian@gentoo.org>
8793 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
8796 2018-04-29 John Reiser <jreiser@BitWagon.com>
8799 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
8800 last step, and do it atomically.
8802 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
8804 * compile/compile-c-types.c (convert_int, convert_float):
8807 2018-04-27 Tom Tromey <tom@tromey.com>
8810 * rust-lang.c (rust_inclusive_range_type_p): New function.
8811 (rust_range): Handle inclusive ranges.
8812 (rust_compute_range): Likewise.
8813 * rust-exp.y (struct rust_op) <inclusive>: New field.
8814 (DOTDOTEQ): New constant.
8815 (range_expr): Add "..=" productions.
8816 (operator_tokens): Add "..=" token.
8817 (ast_range): Add "inclusive" parameter.
8818 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
8820 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
8822 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
8823 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
8825 * expprint.c (print_subexp_standard): Handle new bounds values.
8826 (dump_subexp_body_standard): Likewise.
8828 2018-04-27 Tom Tromey <tom@tromey.com>
8830 * configure: Rebuild.
8831 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
8832 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
8834 (class symbol_needs_eval_context): Likewise.
8835 * dwarf2read.c (mock_mapped_index::symbol_name_count)
8836 (mock_mapped_index::symbol_name_at): Use "override". Remove
8838 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
8840 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
8841 * aarch64-tdep.c (instruction_reader::read): Use "override".
8842 (instruction_reader_test::read): Likewise.
8843 * arm-tdep.c (instruction_reader::read): Use "override".
8844 (instruction_reader_thumb::read): Likewise.
8846 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
8849 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
8850 instead of remote_send.
8851 (remote_send): Remove.
8853 2018-04-26 Pedro Alves <palves@redhat.com>
8855 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
8856 find_function_start_sal instead of find_pc_line.
8858 2018-04-26 Pedro Alves <palves@redhat.com>
8860 * breakpoint.c (set_breakpoint_location_function): Handle
8862 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
8863 * elfread.c (elf_symtab_read): Give data symbols with
8864 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
8865 (elf_rel_plt_read): Update comment.
8866 * linespec.c (convert_linespec_to_sals): Handle
8868 (minsym_found): Handle mst_data_gnu_ifunc.
8869 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
8870 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
8871 * parse.c (find_minsym_type_and_address): Handle
8873 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
8874 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
8875 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
8877 <mst_data_gnu_ifunc>: New enumerator.
8879 2018-04-26 Pedro Alves <palves@redhat.com>
8881 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
8882 (lookup_minimal_symbol_by_pc_section): ... this. Replace
8883 'want_trampoline' parameter by a lookup_msym_prefer parameter.
8885 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
8886 (lookup_minimal_symbol_by_pc): Adjust.
8887 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
8888 (lookup_solib_trampoline_symbol_by_pc): Adjust.
8889 * minsyms.h (lookup_msym_prefer): New enum.
8890 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
8891 parameter by a lookup_msym_prefer parameter.
8893 2018-04-26 Pedro Alves <palves@redhat.com>
8895 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
8896 ends in "@plt" instead of looking at the symbol's section.
8898 2018-04-26 Pedro Alves <palves@redhat.com>
8900 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
8902 (find_pc_partial_function_gnu_ifunc): Rename to ...
8903 (find_pc_partial_function): ... this, and remove references to
8905 (find_pc_partial_function): Delete old implementation.
8906 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
8908 2018-04-26 Pedro Alves <palves@redhat.com>
8910 * linespec.c (struct bound_minimal_symbol_search_key): New.
8911 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
8912 skip first line if we found a GNU ifunc minimal symbol by name.
8913 (compare_msymbols): Change parameters to work with a destructured
8915 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
8918 2018-04-26 Pedro Alves <palves@redhat.com>
8920 * breakpoint.c (set_breakpoint_location_function): Don't resolve
8921 ifunc targets here. Instead, if we have an ifunc minsym, use its
8923 (add_location_to_breakpoint): Store the minsym and the objfile in
8924 the breakpoint location.
8925 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
8926 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
8927 Record the minsym in the sal.
8928 * symtab.h (symtab_and_line) <msymbol>: New field.
8930 2018-04-26 Pedro Alves <palves@redhat.com>
8932 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
8933 unless we actually resolved the ifunc.
8935 2018-04-26 Pedro Alves <palves@redhat.com>
8937 * c-exp.y (variable production): Prefer ifunc minsyms over
8938 regular function symbols.
8939 * symtab.c (find_gnu_ifunc): New function.
8940 * minsyms.h (lookup_msym_prefer): New enum.
8941 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
8942 parameter by a lookup_msym_prefer parameter.
8943 * symtab.h (find_gnu_ifunc): New declaration.
8945 2018-04-26 Pedro Alves <palves@redhat.com>
8947 * blockframe.c (find_gnu_ifunc_target_type): New function.
8948 (find_function_type): New.
8949 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
8950 return a value with a memory address.
8951 (eval_call): For calls to GNU ifunc functions, try to find the
8952 type of the target function from the type that the resolver
8954 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
8956 * infcall.c (find_function_return_type): Delete.
8957 (find_function_addr): Add 'function_type' parameter. For calls to
8958 GNU ifunc functions, try to find the type of the target function
8959 from the type that the resolver returns, and return it via
8961 (call_function_by_hand_dummy): Adjust to use the function type
8962 returned by find_function_addr.
8963 (find_function_addr): Add 'function_type' parameter and move
8965 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
8968 2018-04-26 Pedro Alves <palves@redhat.com>
8970 * c-exp.y (variable production): Skip finding an alias for ifunc
8973 2018-04-26 Pedro Alves <palves@redhat.com>
8975 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
8977 2018-04-25 Pedro Alves <palves@redhat.com>
8979 * infcmd.c (kill_command): Print the pid as string, not the whole
8980 thread's ptid. Add comment. s/has been killed/killed/ in output
8982 * remote.c (remote_detach_1): Print the pid as string, not the
8983 whole thread's ptid.
8985 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
8986 Sergio Durigan Junior <sergiodj@redhat.com>
8987 Pedro Alves <palves@redhat.com>
8989 * infcmd.c (kill_command): Print message when inferior has
8991 * inferior.c (print_inferior_events): Remove 'static'. Set as
8993 (add_inferior): Improve message printed when
8994 'print_inferior_events' is on.
8995 (exit_inferior): Remove message printed when
8996 'print_inferior_events' is on.
8997 (detach_inferior): Improve message printed when
8998 'print_inferior_events' is on.
8999 (initialize_inferiors): Use 'add_inferior_silent' to set
9000 'current_inferior_'.
9001 * inferior.h (print_inferior_events): Declare here as
9003 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
9004 '[Detaching...]' messages when 'print_inferior_events' is on.
9005 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
9006 as prefix/suffix for messages. Remove periods. Fix erroneous
9007 'Detaching after fork from child...', replace it by '... from
9009 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
9010 prefix/suffix when printing 'Detaching...' messages. Print
9011 them when 'print_inferior_events' is on.
9012 * remote.c (remote_detach_1): Print message when detaching
9013 from inferior and '!is_fork_parent'.
9015 2018-04-24 Tom Tromey <tom@tromey.com>
9017 * cli-out.h: Reindent.
9019 2018-04-24 Tom Tromey <tom@tromey.com>
9021 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
9022 (cli_ui_out::do_field_string): Use fputs_filtered.
9023 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
9025 2018-04-23 Tom Tromey <tom@tromey.com>
9027 * guile/scm-frame.c (gdbscm_frame_read_var): Use
9028 gdb::unique_xmalloc_ptr.
9030 2018-04-23 Tom Tromey <tom@tromey.com>
9032 * configure: Rebuild.
9034 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
9037 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
9038 prepare_for_testing. Set normal_bp to r_debug_state if target
9041 2018-04-21 Pedro Alves <palves@redhat.com>
9042 Rajendra SY <rajendra.sy@gmail.com>
9044 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
9045 * remote.c (extended_remote_attach): In all-stop mode, mark the
9046 thread as executing.
9048 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9050 * thread.c (thread_apply_all_command): Fix comment.
9051 (thread_command): Fix comment.
9053 2018-04-10 Alan Hayward <alan.hayward@arm.com>
9055 * common/tdesc.h (tdesc_create_feature): Remove xml filename
9057 * features/aarch64-core.c (create_feature_aarch64_core):
9059 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
9061 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
9063 * features/i386/32bit-avx512.c
9064 (create_feature_i386_32bit_avx512): Likewise.
9065 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
9067 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
9069 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
9071 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
9073 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
9075 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
9077 * features/i386/64bit-avx512.c
9078 (create_feature_i386_64bit_avx512): Likewise.
9079 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
9081 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
9083 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
9085 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
9087 * features/i386/64bit-segments.c
9088 (create_feature_i386_64bit_segments): Likewise.
9089 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
9091 * features/i386/x32-core.c
9092 (create_feature_i386_x32_core): Likewise.
9093 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
9094 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
9095 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
9096 * target-descriptions.c: In generated code, don't pass xml
9099 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9101 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
9102 (print_xml_feature::visit_post): Likewise.
9103 (print_xml_feature::visit): Likewise.
9104 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
9105 (print_xml_feature): Add new class.
9106 * regformats/regdat.sh: Null xmltarget on feature targets.
9107 * target-descriptions.c (struct target_desc): Add xmltarget.
9108 (maintenance_check_tdesc_xml_convert): Add unittest function.
9109 (tdesc_get_features_xml): Add function to get xml.
9110 (maintenance_check_xml_descriptions): Test xml generation.
9111 * xml-tdesc.c (string_read_description_xml): Add function.
9112 * xml-tdesc.h (string_read_description_xml): Add declaration.
9114 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9116 * features/Makefile: Add feature marker to targets with new style
9117 target descriptions.
9118 * regformats/aarch64.dat: Regenerate.
9119 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
9120 * regformats/i386/amd64-avx-linux.dat: Likewise.
9121 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
9122 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
9123 * regformats/i386/amd64-linux.dat: Likewise.
9124 * regformats/i386/amd64-mpx-linux.dat: Likewise.
9125 * regformats/i386/amd64.dat: Likewise.
9126 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
9127 * regformats/i386/i386-avx-linux.dat: Likewise.
9128 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
9129 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
9130 * regformats/i386/i386-linux.dat: Likewise.
9131 * regformats/i386/i386-mmx-linux.dat: Likewise.
9132 * regformats/i386/i386-mpx-linux.dat: Likewise.
9133 * regformats/i386/i386.dat: Likewise.
9134 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
9135 * regformats/i386/x32-avx-linux.dat: Likewise.
9136 * regformats/i386/x32-linux.dat: Likewise.
9137 * regformats/tic6x-c62x-linux.dat: Likewise.
9138 * regformats/tic6x-c64x-linux.dat: Likewise.
9139 * regformats/tic6x-c64xp-linux.dat: Likewise.
9140 * regformats/regdat.sh: Parse feature marker.
9142 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9144 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
9145 (tdesc_osabi_name): Likewise.
9146 * target-descriptions.c (tdesc_architecture_name): Add new
9148 (tdesc_osabi_name): Likewise.
9150 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9152 * common/tdesc.c (tdesc_predefined_type): Move to here.
9153 (tdesc_named_type): Likewise.
9154 (tdesc_create_vector): Likewise.
9155 (tdesc_create_struct): Likewise.
9156 (tdesc_set_struct_size): Likewise.
9157 (tdesc_create_union): Likewise.
9158 (tdesc_create_flags): Likewise.
9159 (tdesc_create_enum): Likewise.
9160 (tdesc_add_field): Likewise.
9161 (tdesc_add_typed_bitfield): Likewise.
9162 (tdesc_add_bitfield): Likewise.
9163 (tdesc_add_flag): Likewise.
9164 (tdesc_add_enum_value): Likewise.
9165 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
9166 (struct tdesc_type_vector): Likewise.
9167 (struct tdesc_type_field): Likewise.
9168 (struct tdesc_type_with_fields): Likewise.
9169 (tdesc_create_enum): Add declaration.
9170 (tdesc_add_typed_bitfield): Likewise.
9171 (tdesc_add_enum_value): Likewise.
9172 * target-descriptions.c (tdesc_type_field): Move from here.
9173 (tdesc_type_builtin): Likewise.
9174 (tdesc_type_vector): Likewise.
9175 (tdesc_type_with_fields): Likewise.
9176 (tdesc_predefined_types): Likewise.
9177 (tdesc_named_type): Likewise.
9178 (tdesc_create_vector): Likewise.
9179 (tdesc_create_struct): Likewise.
9180 (tdesc_set_struct_size): Likewise.
9181 (tdesc_create_union): Likewise.
9182 (tdesc_create_flags): Likewise.
9183 (tdesc_create_enum): Likewise.
9184 (tdesc_add_field): Likewise.
9185 (tdesc_add_typed_bitfield): Likewise.
9186 (tdesc_add_bitfield): Likewise.
9187 (tdesc_add_flag): Likewise.
9188 (tdesc_add_enum_value): Likewise.
9189 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
9190 (tdesc_add_typed_bitfield): Likewise.
9191 (tdesc_add_enum_value): Likewise.
9193 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9195 * common/tdesc.c (tdesc_feature::accept): Move to here.
9196 (tdesc_feature::operator==): Likewise.
9197 (tdesc_create_reg): Likewise.
9198 * common/tdesc.h (tdesc_type_kind): Likewise.
9199 (struct tdesc_type): Likewise.
9200 (struct tdesc_feature): Likewise.
9201 * regformats/regdat.sh: Create a feature.
9202 * target-descriptions.c (tdesc_type_kind): Move from here.
9203 (tdesc_type): Likewise.
9204 (tdesc_type_up): Likewise.
9205 (tdesc_feature): Likewise.
9206 (tdesc_create_reg): Likewise.
9208 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9210 * Makefile.in: Add arch/tdesc.c
9211 * common/tdesc.c: New file.
9212 * common/tdesc.h (tdesc_element_visitor): Move to here.
9213 (tdesc_element): Likewise.
9214 (tdesc_reg): Likewise.
9215 (tdesc_reg_up): Likewise.
9216 * regformats/regdef.h (reg): Add offset to constructors.
9217 * target-descriptions.c (tdesc_element_visitor): Move from here.
9218 (tdesc_element): Likewise.
9219 (tdesc_reg): Likewise.
9220 (tdesc_reg_up): Likewise.
9222 2018-04-17 Tom Tromey <tom@tromey.com>
9224 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
9227 2018-04-17 Tom Tromey <tom@tromey.com>
9229 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
9231 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
9233 * symtab.c (print_symbol_info): Skip printing filename and line
9234 number when `last' is NULL.
9235 (symtab_symbol_info): Use empty string instead of NULL for first
9236 invocation of print_symbol_info.
9237 (rbreak_command): Pass NULL to `last' parameter of
9240 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
9242 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
9245 2018-04-16 Pedro Alves <palves@redhat.com>
9247 * MAINTAINERS (sh): Remove.
9248 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
9249 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
9250 (ALLDEPFILES): Remove sh64-tdep.c.
9251 * NEWS: Mentions that support for SH-5/SH64 is removed.
9252 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
9253 (sh*-*-openbsd*): Ditto.
9254 (sh64-*-elf*): Remove.
9256 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
9257 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
9258 * sh-tdep.c: No longer include "sh64-tdep.h".
9259 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
9260 * sh64-tdep.c, sh64-tdep.h: Remove files.
9262 2018-04-16 Pedro Alves <palves@redhat.com>
9264 * MAINTAINERS: Remove m88k.
9265 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
9266 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
9267 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
9268 * NEWS: Mention that support for m88k was removed.
9269 * configure.host (m88*-*-*): Remove support.
9270 * configure.nat (m88k-*-*): Remove support.
9271 * configure.tgt (m88*-*-openbsd*): Remove.
9272 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
9274 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
9276 * configure.tgt (x86_tobjs): New variable.
9277 (amd64_tobjs, i386_tobjs): Use it.
9279 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9281 * symtab.c (print_symbol_info): Precede the symbol definition by
9282 the line number when available.
9283 * NEWS: Advertise this enhancement.
9285 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9287 * NEWS (New options): announce set/show record btrace cpu.
9288 * btrace.c: Include record-btrace.h.
9289 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
9290 the vendor is unknown.
9291 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
9292 Maybe overwrite the btrace configuration's cpu.
9293 (btrace_compute_ftrace): Add cpu parameter. Update callers.
9294 (btrace_fetch): Add cpu parameter. Update callers.
9295 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
9296 Maybe overwrite the btrace configuration's cpu. Skip enabling
9297 errata workarounds if the vendor is unknown.
9298 * python/py-record-btrace.c: Include record-btrace.h.
9299 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
9300 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
9301 * record-btrace.c (record_btrace_cpu_state_kind): New.
9302 (record_btrace_cpu): New.
9303 (set_record_btrace_cpu_cmdlist): New.
9304 (record_btrace_get_cpu): New.
9305 (require_btrace_thread, record_btrace_info)
9306 (record_btrace_resume_thread): Call record_btrace_get_cpu.
9307 (cmd_set_record_btrace_cpu_none): New.
9308 (cmd_set_record_btrace_cpu_auto): New.
9309 (cmd_set_record_btrace_cpu): New.
9310 (cmd_show_record_btrace_cpu): New.
9311 (_initialize_record_btrace): Initialize set/show record btrace cpu
9313 * record-btrace.h (record_btrace_get_cpu): New.
9315 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9317 * record.c (set_record_command): Fix typo in message.
9319 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9321 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
9323 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9325 * infrun.c (process_event_stop_test): Call
9326 gdbarch_in_indirect_branch_thunk.
9327 * gdbarch.sh (in_indirect_branch_thunk): New.
9328 * gdbarch.c: Regenerated.
9329 * gdbarch.h: Regenerated.
9332 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
9333 (HFILES_NO_SRCDIR): Add x86-tdep.h.
9334 (ALLDEPFILES): Add x86-tdep.c.
9335 * arch-utils.h (default_in_indirect_branch_thunk): New.
9336 * arch-utils.c (default_in_indirect_branch_thunk): New.
9337 * i386-tdep: Include x86-tdep.h.
9338 (i386_in_indirect_branch_thunk): New.
9339 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
9341 * amd64-tdep: Include x86-tdep.h.
9342 (amd64_in_indirect_branch_thunk): New.
9343 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
9345 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
9348 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
9349 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
9350 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
9353 2018-04-12 Tom Tromey <tom@tromey.com>
9355 * rust-lang.c (rust_print_struct_def): Remove univariant code.
9356 (rust_evaluate_subexp): Likewise.
9358 2018-04-12 Pedro Alves <palves@redhat.com>
9360 * procfs.c (procfs_detach): Make forward declaration's prototype
9361 match definition's protototype.
9362 (proc_get_LDT_entry): Remove stale do_cleanups call.
9364 2018-04-12 Pedro Alves <palves@redhat.com>
9366 * target.h (target_ops::to_has_exited): Delete.
9367 (target_has_exited): Delete.
9368 * target-delegates.c: Regenerate.
9370 2018-04-11 Pedro Alves <palves@redhat.com>
9372 * target.c (fileio_fh_t::t): Add comment.
9373 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9374 (target_fileio_close): Handle a NULL target.
9375 (invalidate_fileio_fh): New.
9376 (target_close): Call it.
9377 * remote.c (remote_hostio_send_command): No longer check whether
9378 remote_desc is open.
9380 2018-04-11 Pedro Alves <palves@redhat.com>
9382 * target.c (fileio_fh_t): Make it a named struct instead of a
9384 (fileio_fh_t::is_closed): New method.
9385 (DEF_VEC_O (fileio_fh_t)): Remove.
9386 (fileio_fhandles): Now a std::vector.
9387 (is_closed_fileio_fh): Delete.
9388 (acquire_fileio_fd): Adjust. Rename parameters.
9389 (release_fileio_fd): Adjust.
9390 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
9391 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9392 (target_fileio_close): Adjust.
9394 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
9396 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
9399 2018-04-10 Pedro Alves <palves@redhat.com>
9401 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
9402 (scoped_finish_thread_state): New class.
9403 * infcmd.c (run_command_1): Use it instead of finish_thread_state
9405 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
9406 (fetch_inferior_event, normal_stop): Likewise.
9407 * thread.c (finish_thread_state_cleanup): Delete.
9409 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9410 Pedro Alves <palves@redhat.com>
9412 * value.c: Include "selftest.h" and "common/array-view.h".
9413 (struct range) <operator ==>: New.
9414 (test_ranges_contain): New.
9415 (check_ranges_vector): New.
9416 (test_insert_into_bit_range_vector): New.
9417 (_initialize_values): Register selftests.
9418 * common/array-view.h (operator==, operator!=): New.
9420 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9422 * common/gdb_vecs.h (unordered_remove): Add overload that takes
9424 * inline-frame.c: Include <algorithm>.
9425 (struct inline_state): Add constructor.
9426 (inline_state_s): Remove.
9427 (DEF_VEC_O(inline_state_s)): Remove.
9428 (inline_states): Change type to std::vector.
9429 (find_inline_frame_state): Adjust to std::vector.
9430 (allocate_inline_frame_state): Remove.
9431 (clear_inline_frame_state): Adjust to std::vector.
9432 (skip_inline_frames): Adjust to std::vector.
9434 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9436 * tracepoint.h (struct trace_state_variable): Add constructor.
9437 <name>: Change type to std::string.
9438 * tracepoint.c (tsv_s): Remove.
9439 (DEF_VEC_O(tsv_s)): Remove.
9440 (tvariables): Change to std::vector.
9441 (create_trace_state_variable): Adjust to std::vector.
9442 (find_trace_state_variable): Likewise.
9443 (find_trace_state_variable_by_number): Likewise.
9444 (delete_trace_state_variable): Likewise.
9445 (trace_variable_command): Adjust to std::string.
9446 (delete_trace_variable_command): Likewise.
9447 (tvariables_info_1): Adjust to std::vector.
9448 (save_trace_state_variables): Likewise.
9449 (start_tracing): Likewise.
9450 (merge_uploaded_trace_state_variables): Adjust to std::vector
9452 * target.h (struct target_ops)
9453 <to_download_trace_state_variable>: Pass reference to
9454 trace_state_variable.
9455 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
9456 * target-delegates.c: Re-generate.
9457 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
9458 (mi_tsv_deleted): Likewise.
9459 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
9460 * remote.c (remote_download_trace_state_variable): Change
9461 pointer to reference and adjust.
9462 * make-target-delegates (parse_argtypes): Handle references.
9463 (write_function_header): Likewise.
9464 (munge_type): Likewise.
9466 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9468 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9469 string_view-selftests.c.
9470 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
9472 * unittests/basic_string_view/cons/char/1.cc: Likewise.
9473 * unittests/basic_string_view/cons/char/2.cc: Likewise.
9474 * unittests/basic_string_view/cons/char/3.cc: Likewise.
9475 * unittests/basic_string_view/element_access/char/1.cc:
9477 * unittests/basic_string_view/element_access/char/empty.cc:
9479 * unittests/basic_string_view/element_access/char/front_back.cc:
9481 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
9482 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
9484 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
9486 * unittests/basic_string_view/modifiers/swap/char/1.cc:
9488 * unittests/basic_string_view/operations/compare/char/1.cc:
9490 * unittests/basic_string_view/operations/compare/char/13650.cc:
9492 * unittests/basic_string_view/operations/copy/char/1.cc:
9494 * unittests/basic_string_view/operations/data/char/1.cc:
9496 * unittests/basic_string_view/operations/find/char/1.cc:
9498 * unittests/basic_string_view/operations/find/char/2.cc:
9500 * unittests/basic_string_view/operations/find/char/3.cc:
9502 * unittests/basic_string_view/operations/find/char/4.cc:
9504 * unittests/basic_string_view/operations/rfind/char/1.cc:
9506 * unittests/basic_string_view/operations/rfind/char/2.cc:
9508 * unittests/basic_string_view/operations/rfind/char/3.cc:
9510 * unittests/basic_string_view/operations/substr/char/1.cc:
9512 * unittests/basic_string_view/operators/char/2.cc: Likewise.
9513 * unittests/string_view-selftests.c: New file.
9515 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9517 * unittests/basic_string_view/capacity/1.cc: New file.
9518 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
9519 * unittests/basic_string_view/cons/char/1.cc: New file.
9520 * unittests/basic_string_view/cons/char/2.cc: New file.
9521 * unittests/basic_string_view/cons/char/3.cc: New file.
9522 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
9523 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
9524 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
9525 * unittests/basic_string_view/element_access/char/1.cc: New file.
9526 * unittests/basic_string_view/element_access/char/2.cc: New file.
9527 * unittests/basic_string_view/element_access/char/empty.cc: New file.
9528 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
9529 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
9530 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
9531 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
9532 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
9533 * unittests/basic_string_view/include.cc: New file.
9534 * unittests/basic_string_view/inserters/char/1.cc: New file.
9535 * unittests/basic_string_view/inserters/char/2.cc: New file.
9536 * unittests/basic_string_view/inserters/char/3.cc: New file.
9537 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
9538 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
9539 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
9540 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
9541 * unittests/basic_string_view/literals/types.cc: New file.
9542 * unittests/basic_string_view/literals/values.cc: New file.
9543 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
9544 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
9545 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
9546 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
9547 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
9548 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
9549 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
9550 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
9551 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
9552 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
9553 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
9554 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
9555 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
9556 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
9557 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
9558 * unittests/basic_string_view/operations/data/char/1.cc: New file.
9559 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
9560 * unittests/basic_string_view/operations/find/char/1.cc: New file.
9561 * unittests/basic_string_view/operations/find/char/2.cc: New file.
9562 * unittests/basic_string_view/operations/find/char/3.cc: New file.
9563 * unittests/basic_string_view/operations/find/char/4.cc: New file.
9564 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
9565 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
9566 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
9567 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
9568 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
9569 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
9570 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
9571 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
9572 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
9573 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
9574 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
9575 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
9576 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
9577 * unittests/basic_string_view/operators/char/2.cc: New file.
9578 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
9579 * unittests/basic_string_view/range_access/char/1.cc: New file.
9580 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
9581 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
9582 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
9583 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
9584 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
9585 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
9586 * unittests/basic_string_view/requirements/typedefs.cc: New file.
9587 * unittests/basic_string_view/typedefs.cc: New file.
9588 * unittests/basic_string_view/types/1.cc: New file.
9590 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9592 * common/gdb_string_view.h: Remove libstdc++ implementation
9593 details, adjust to gdb reality.
9594 * common/gdb_string_view.tcc: Likewise.
9595 * cli/cli-script.c (struct string_view): Remove.
9596 (user_args) <m_args>: Change element type to gdb::string_view.
9597 (user_args::insert_args): Adjust.
9599 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9601 * common/gdb_string_view.h: New file.
9602 * common/gdb_string_view.tcc: New file.
9604 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9606 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
9607 * configure: Re-generate.
9609 2018-04-09 Pedro Alves <palves@redhat.com>
9611 * gdbarch.sh: Include "observable.h" instead of "observer.h".
9612 (set_target_gdbarch): Call
9613 gdb::observers::architecture_changed.notify instead of
9614 observer_notify_architecture_changed.
9616 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9618 * tracepoint.c (struct current_traceframe_cleanup): Remove.
9619 (do_restore_current_traceframe_cleanup): Remove.
9620 (restore_current_traceframe_cleanup_dtor): Remove.
9621 (make_cleanup_restore_current_traceframe): Remove.
9622 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
9624 * tracepoint.h (struct scoped_restore_current_traceframe): New.
9625 * infrun.c (fetch_inferior_event): Use
9626 scoped_restore_current_traceframe.
9628 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9630 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
9632 <n_allocated_type_units>: Remove.
9633 <all_type_units>: Change to std::vector.
9634 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9635 to std::vector change.
9636 (dwarf2_per_objfile::get_cutu): Likewise.
9637 (dwarf2_per_objfile::get_tu): Likewise.
9638 (create_signatured_type_table_from_index): Likewise.
9639 (create_signatured_type_table_from_debug_names): Likewise.
9640 (dw2_symtab_iter_next): Likewise.
9641 (dw2_print_stats): Likewise.
9642 (dw2_expand_all_symtabs): Likewise.
9643 (dw2_expand_marked_cus): Likewise.
9644 (dw2_debug_names_iterator::next): Likewise.
9645 (dwarf2_initialize_objfile): Likewise.
9646 (add_signatured_type_cu_to_table): Likewise.
9647 (create_all_type_units): Likewise.
9648 (add_type_unit): Likewise.
9649 (struct tu_abbrev_offset): Add constructor.
9650 (build_type_psymtabs_1): Adjust to std::vector change.
9651 (print_tu_stats): Likewise.
9652 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9653 (write_debug_names): Likewise.
9655 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9657 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
9658 Make an std::vector.
9659 <n_comp_units>: Remove.
9660 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9661 to std::vector change.
9662 (dwarf2_per_objfile::get_cutu): Likewise.
9663 (dwarf2_per_objfile::get_cu): Likewise.
9664 (create_cus_from_index): Likewise.
9665 (create_addrmap_from_index): Likewise.
9666 (create_addrmap_from_aranges): Likewise.
9667 (dwarf2_read_index): Likewise.
9668 (dw2_find_last_source_symtab): Likewise.
9669 (dw2_map_symtabs_matching_filename): Likewise.
9670 (dw2_symtab_iter_next): Likewise.
9671 (dw2_print_stats): Likewise.
9672 (dw2_expand_all_symtabs): Likewise.
9673 (dw2_expand_symtabs_with_fullname): Likewise.
9674 (dw2_expand_marked_cus): Likewise.
9675 (dw2_map_symbol_filenames): Likewise.
9676 (create_cus_from_debug_names): Likewise.
9677 (dwarf2_read_debug_names): Likewise.
9678 (dw2_debug_names_iterator::next): Likewise.
9679 (dwarf2_initialize_objfile): Likewise.
9680 (set_partial_user): Likewise.
9681 (dwarf2_build_psymtabs_hard): Likewise.
9682 (read_comp_units_from_section): Remove arguments, adjust to
9684 (create_all_comp_units): Adjust to std::vector and
9685 read_comp_units_from_section changes.
9686 (dwarf2_find_containing_comp_unit): Adjust to std::vector
9688 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9689 (psyms_seen_size): Likewise.
9690 (write_gdbindex): Likewise.
9691 (write_debug_names): Likewise.
9693 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9695 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
9696 with dwarf2_per_objfile.
9697 (create_cus_from_index): Likewise.
9698 (create_signatured_type_table_from_index): Likewise.
9699 (dwarf2_read_index): Likewise.
9700 (dwarf2_initialize_objfile): Likewise.
9701 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
9702 per_cu rather than get_dwarf2_per_objfile.
9704 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9706 * dwarf2read.h (struct signatured_type): Forward declare.
9707 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
9709 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
9710 (dw2_get_cutu): ...this.
9711 (dwarf2_per_objfile::get_cu): Rename from...
9712 (dw2_get_cu): ...this.
9713 (dwarf2_per_objfile::get_tu): New.
9714 (create_addrmap_from_index): Adjust.
9715 (create_addrmap_from_aranges): Adjust.
9716 (dw2_find_last_source_symtab): Adjust.
9717 (dw2_map_symtabs_matching_filename): Adjust.
9718 (dw2_symtab_iter_next): Adjust.
9719 (dw2_print_stats): Adjust.
9720 (dw2_expand_all_symtabs): Adjust.
9721 (dw2_expand_symtabs_with_fullname): Adjust.
9722 (dw2_expand_marked_cus): Adjust.
9723 (dw_expand_symtabs_matching_file_matcher): Adjust.
9724 (dw2_map_symbol_filenames): Adjust.
9725 (dw2_debug_names_iterator::next): Adjust.
9726 (dwarf2_initialize_objfile): Adjust.
9727 (set_partial_user): Adjust.
9728 (dwarf2_build_psymtabs_hard): Adjust.
9730 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9732 * dwarf2read.c (create_signatured_type_table_from_debug_names):
9733 Remove unused variables.
9734 (dw2_map_symtabs_matching_filename): Likewise.
9735 (dwarf2_record_block_ranges): Likewise.
9736 (dwarf2_read_addr_index): Likewise.
9737 (follow_die_offset): Likewise.
9739 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9741 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
9742 to symbol_file_add_main.
9744 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9747 * mi/mi-console.c (do_fputc_async_safe): New.
9748 (mi_console_file::write_async_safe): New.
9749 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
9750 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
9752 * ui-file.c (ui_file::putstrn): Adjust call to
9753 fputstrn_unfiltered.
9754 * utils.c (printchar): Replace do_fputs and do_fprintf
9755 parameters by do_fputc.
9756 (fputstr_filtered): Adjust call to printchar.
9757 (fputstr_unfiltered): Likewise.
9758 (fputstrn_filtered): Likewise.
9759 (fputstrn_unfiltered): Add do_fputc parameter, pass to
9761 * utils.h (do_fputc_ftype): New typedef.
9762 (fputstrn_unfiltered): Add do_fputc parameter.
9764 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9766 * regformats/i386/i386-avx.dat: Remove.
9768 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9771 * amd64-tdep.c (amd64_none_init_abi): New function.
9772 (amd64_x32_none_init_abi): New function.
9773 (_initialize_amd64_tdep): Register handlers for x86-64 and
9774 x64_32 with GDB_OSABI_NONE.
9775 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
9776 GDB_OSABI_NONE osabi.
9778 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9781 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
9783 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
9784 * osabi.c (gdb_osabi_names): Add "unknown" entry.
9786 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9788 * common/byte-vector.h (char_vector): New type.
9789 * target.h (target_read_alloc): Return
9790 gdb::optional<byte_vector>.
9791 (target_read_stralloc): Return gdb::optional<char_vector>.
9792 (target_get_osdata): Return gdb::optional<char_vector>.
9793 * target.c (target_read_alloc_1): Templatize. Replacement
9794 manual memory management with vector.
9795 (target_read_alloc): Change return type, adjust.
9796 (target_read_stralloc): Change return type, adjust.
9797 (target_get_osdata): Change return type, adjust.
9798 * auxv.c (struct auxv_info) <length>: Remove.
9799 <data>: Change type to gdb::optional<byte_vector>.
9800 (auxv_inferior_data_cleanup): Free auxv_info with delete.
9801 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
9802 (target_auxv_search): Adjust.
9803 (fprint_target_auxv): Adjust.
9804 * avr-tdep.c (avr_io_reg_read_command): Adjust.
9805 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
9806 (linux_make_corefile_notes): Adjust.
9807 * osdata.c (get_osdata): Adjust.
9808 * remote.c (remote_get_threads_with_qxfer): Adjust.
9809 (remote_memory_map): Adjust.
9810 (remote_traceframe_info): Adjust.
9811 (btrace_read_config): Adjust.
9812 (remote_read_btrace): Adjust.
9813 (remote_pid_to_exec_file): Adjust.
9814 * solib-aix.c (solib_aix_get_library_list): Adjust.
9815 * solib-dsbt.c (decode_loadmap): Don't free buf.
9816 (dsbt_get_initial_loadmaps): Adjust.
9817 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
9818 * solib-target.c (solib_target_current_sos): Adjust.
9819 * tracepoint.c (sdata_make_value): Adjust.
9820 * xml-support.c (xinclude_start_include): Adjust.
9821 (xml_fetch_content_from_file): Adjust.
9822 * xml-support.h (xml_fetch_another): Change return type.
9823 (xml_fetch_content_from_file): Change return type.
9824 * xml-syscall.c (xml_init_syscalls_info): Adjust.
9825 * xml-tdesc.c (file_read_description_xml): Adjust.
9826 (fetch_available_features_from_target): Change return type.
9827 (target_fetch_description_xml): Adjust.
9828 (target_read_description_xml): Adjust.
9830 2018-04-06 Tom Tromey <tom@tromey.com>
9832 * value.c (~value): Update.
9833 (struct value) <contents>: Now unique_xmalloc_ptr.
9834 (value_contents_bits_eq, allocate_value_contents)
9835 (value_contents_raw, value_contents_all_raw)
9836 (value_contents_for_printing, value_contents_for_printing_const)
9837 (set_value_enclosing_type): Update.
9839 2018-04-06 Tom Tromey <tom@tromey.com>
9841 * value.c (range_s): Remove typedef, VEC.
9842 (struct range): Add operator<.
9843 (range_lessthan): Remove.
9844 (ranges_contain): Change type.
9846 (struct value) <unavailable, optimized_out>: Now std::vector.
9847 (value_entirely_available)
9848 (value_entirely_covered_by_range_vector)
9849 (value_entirely_unavailable, value_entirely_optimized_out):
9851 (insert_into_bit_range_vector): Change argument type.
9852 (find_first_range_overlap): Likewise.
9853 (struct ranges_and_idx, value_contents_bits_eq)
9854 (require_not_optimized_out, require_available): Update.
9855 (ranges_copy_adjusted): Change argument types.
9856 (value_optimized_out, value_copy, value_fetch_lazy): Update.
9858 2018-04-06 Tom Tromey <tom@tromey.com>
9860 * value.c (~value): Update.
9861 (struct value) <parent>: Now a value_ref_ptr.
9862 (value_parent, set_value_parent, value_address, value_copy):
9865 2018-04-06 Tom Tromey <tom@tromey.com>
9867 * value.c (struct value): Add constructor, destructor, and member
9869 (allocate_value_lazy, value_decref): Update.
9871 2018-04-06 Tom Tromey <tom@tromey.com>
9873 * value.c (struct value) <released, next>: Remove.
9874 (all_values): Now a std::vector.
9875 (allocate_value_lazy): Update.
9876 (value_next): Remove.
9877 (value_mark, value_free_to_mark, release_value)
9878 (value_release_to_mark): Update.
9880 2018-04-06 Tom Tromey <tom@tromey.com>
9882 * value.h (fetch_subexp_value, value_release_to_mark): Update.
9883 (free_value_chain): Remove.
9884 * value.c (free_value_chain): Remove.
9885 (value_release_to_mark): Return a std::vector.
9886 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
9888 (check_condition): Update.
9889 * eval.c (fetch_subexp_value): Change "val_chain" to a
9891 * breakpoint.c (update_watchpoint): Update.
9892 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
9894 2018-04-06 Tom Tromey <tom@tromey.com>
9896 * value.h (free_all_values): Remove.
9897 * value.c (free_all_values): Remove.
9899 2018-04-06 Tom Tromey <tom@tromey.com>
9901 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
9902 (value_history_chain, value_history_count): Remove.
9903 (value_history): New global.
9904 (record_latest_value, access_value_history, show_values)
9905 (preserve_values): Update.
9907 2018-04-06 Tom Tromey <tom@tromey.com>
9909 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
9910 * varobj.c (varobj_set_display_format, varobj_set_value)
9911 (install_default_visualizer, construct_visualizer)
9912 (install_new_value, ~varobj, varobj_get_value_type)
9913 (my_value_of_variable, varobj_editable_p): Update.
9914 * c-varobj.c (c_describe_child, c_value_of_variable)
9915 (cplus_number_of_children, cplus_describe_child): Update.
9916 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
9917 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
9918 (ada_value_of_variable, ada_value_is_changeable_p): Update.
9920 2018-04-06 Tom Tromey <tom@tromey.com>
9922 * printcmd.c (last_examine_address): Change type to
9924 (do_examine, x_command): Update.
9926 2018-04-06 Tom Tromey <tom@tromey.com>
9928 * value.c (release_value): Update.
9929 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
9930 (struct bpstats) <val>: Now a value_ref_ptr.
9931 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
9932 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
9933 (~watchpoint, print_it_watchpoint, watch_command_1)
9934 (invalidate_bp_value_on_memory_change): Update.
9936 2018-04-06 Tom Tromey <tom@tromey.com>
9938 * varobj.c (varobj_clear_saved_item)
9939 (update_dynamic_varobj_children, install_new_value, ~varobj):
9941 * value.h (value_incref): Move declaration earlier.
9942 (value_decref): Rename from value_free.
9943 (struct value_ref_policy): New.
9944 (value_ref_ptr): New typedef.
9945 (struct value_deleter): Remove.
9946 (gdb_value_up): Remove typedef.
9947 (release_value): Change return type.
9948 (release_value_or_incref): Remove.
9949 * value.c (set_value_parent): Update.
9950 (value_incref): Change return type.
9951 (value_decref): Rename from value_free.
9952 (value_free_to_mark, free_all_values, free_value_chain): Update.
9953 (release_value): Return value_ref_ptr.
9954 (release_value_or_incref): Remove.
9955 (record_latest_value, set_internalvar, clear_internalvar):
9957 * stack.c (info_frame_command): Don't call value_free.
9958 * python/py-value.c (valpy_dealloc, valpy_new)
9959 (value_to_value_object): Update.
9960 * printcmd.c (do_examine): Update.
9961 * opencl-lang.c (lval_func_free_closure): Update.
9962 * mi/mi-main.c (register_changed_p): Don't call value_free.
9963 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
9964 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
9965 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
9967 * guile/scm-value.c (vlscm_free_value_smob)
9968 (vlscm_scm_from_value): Update.
9969 * frame.c (frame_register_unwind, frame_unwind_register_signed)
9970 (frame_unwind_register_unsigned, get_frame_register_bytes)
9971 (put_frame_register_bytes): Don't call value_free.
9972 * findvar.c (address_from_register): Don't call value_free.
9973 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
9974 * dwarf2loc.c (entry_data_value_free_closure)
9975 (value_of_dwarf_reg_entry, free_pieced_value_closure)
9976 (dwarf2_evaluate_loc_desc_full): Update.
9977 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
9978 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
9979 (~watchpoint, watch_command_1)
9980 (invalidate_bp_value_on_memory_change): Update.
9981 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
9983 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
9986 * warning.m4: Add -Wno-error=deprecated-register.
9987 * configure: Re-generate.
9989 2018-04-05 Tom Tromey <tom@tromey.com>
9991 * linespec.h: Remove include of "vec.h".
9993 2018-04-05 Tom Tromey <tom@tromey.com>
9995 * linespec.c (typep): Remove typedef.
9996 (find_methods, find_superclass_methods): Take a std::vector.
9997 (find_method): Use std::vector.
9999 2018-04-05 Tom Tromey <tom@tromey.com>
10001 * utils.c (compare_strings): Remove.
10002 * utils.h (compare_strings): Remove.
10003 * objc-lang.h (find_imps): Update.
10004 * objc-lang.c (find_methods): Take a std::vector.
10005 (uniquify_strings, find_imps): Likewise.
10006 * linespec.c (find_methods): Take a std::vector.
10007 (decode_objc): Use std::vector.
10008 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
10010 (find_method, find_function_symbols): Use std::vector.
10012 2018-04-05 Tom Tromey <tom@tromey.com>
10014 * completer.c (completion_tracker::completion_tracker): Remove
10016 (completion_tracker::discard_completions): Likewise.
10017 * breakpoint.c (ambiguous_names_p): Remove cast.
10018 * ada-lang.c (_initialize_ada_language): Remove cast.
10019 * utils.h (streq): Update.
10020 (streq_hash): Add new declaration.
10021 * utils.c (streq): Return bool.
10022 (streq_hash): New function.
10024 2018-04-05 Tom Tromey <tom@tromey.com>
10026 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
10027 Remove a string copy.
10029 2018-04-05 Tom Tromey <tom@tromey.com>
10031 * linespec.c (filter_results): Use std::vector.
10032 (decode_line_2, decode_line_full): Update.
10034 2018-04-05 Tom Tromey <tom@tromey.com>
10036 * linespec.c (canonical_to_fullform): Return std::string.
10037 (filter_results): Update.
10038 (struct decode_line_2_item): Add constructor.
10039 <fullform, displayform>: Now std::string.
10040 (decode_line_2_compare_items): Now a std::sort comparator.
10041 (decode_line_2): Update.
10043 2018-04-05 Tom Tromey <tom@tromey.com>
10045 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
10046 (unexpected_linespec_error): Update.
10047 (linespec_parse_basic, parse_linespec): Update.
10049 2018-04-05 Tom Tromey <tom@tromey.com>
10051 * linespec.c (linespec_parse_basic): Reindent.
10053 2018-04-05 Tom Tromey <tom@tromey.com>
10055 * minsyms.h (iterate_over_minimal_symbols): Update.
10056 * minsyms.c (iterate_over_minimal_symbols): Take a
10057 gdb::function_view.
10058 * linespec.c (struct collect_minsyms): Remove.
10059 (compare_msyms): Now a std::sort comparator.
10060 (add_minsym): Add parameters.
10061 (search_minsyms_for_name): Update. Use std::vector.
10063 2018-04-03 Tom Tromey <tom@tromey.com>
10065 * mipsread.c (read_alphacoff_dynamic_symtab): Use
10068 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10070 * MAINTAINERS (Write After Approval): Add Weimin Pan.
10072 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10075 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
10076 printing static type.
10078 2018-04-01 Tom Tromey <tom@tromey.com>
10080 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
10081 (rs6000_xfer_shared_libraries): Update.
10083 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
10085 * common/gdb_vecs.h (char_ptr): Remove.
10086 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
10088 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10090 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
10092 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
10094 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10096 * tracepoint.h (struct uploaded_tp): Initialize fields.
10097 <actions, step_actions, cmd_strings>: Change type to
10098 std::vector<char *>.
10099 * tracepoint.c (get_uploaded_tp): Allocate with new.
10100 (free_uploaded_tps): Free with delete.
10101 (parse_tracepoint_definition): Adjust to std::vector change.
10102 * breakpoint.c (read_uploaded_action): Likewise.
10103 (create_tracepoint_from_upload): Likewise.
10104 * ctf.c (ctf_write_uploaded_tp): Likewise.
10105 (SET_ARRAY_FIELD): Likewise.
10106 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
10108 2018-03-30 Tom Tromey <tom@tromey.com>
10110 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
10112 (svr4_keep_data_in_core): Update.
10113 (svr4_read_so_list): Update.
10115 2018-03-30 Tom Tromey <tom@tromey.com>
10117 * windows-nat.c (handle_output_debug_string, handle_exception):
10119 * target.h (target_read_string): Update.
10120 * target.c (target_read_string): Change "string" to
10121 unique_xmalloc_ptr.
10122 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
10124 * solib-frv.c (frv_current_sos): Update.
10125 * solib-dsbt.c (dsbt_current_sos): Update.
10126 * solib-darwin.c (darwin_current_sos): Update.
10127 * linux-thread-db.c (inferior_has_bug): Update.
10128 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
10129 Update. Remove alloca.
10130 * ada-lang.c (ada_main_name): Update.
10132 2018-03-30 Tom Tromey <tom@tromey.com>
10134 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
10135 (struct dwo_file_deleter): New.
10136 (dwo_file_up): New typedef.
10137 (open_and_init_dwo_file): Use dwo_file_up.
10138 (free_dwo_file_cleanup): Remove.
10140 2018-03-30 Tom Tromey <tom@tromey.com>
10142 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
10143 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
10145 2018-03-30 Tom Tromey <tom@tromey.com>
10147 * dwarf2read.c (class free_cached_comp_units): New class.
10148 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
10149 (free_cached_comp_units): Remove function.
10151 2018-03-30 Tom Tromey <tom@tromey.com>
10153 * utils.h (make_cleanup_unpush_target): Remove.
10154 * inf-ptrace.c (struct target_unpusher): New.
10155 (target_unpush_up) New typedef.
10156 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
10158 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
10160 2018-03-27 Tom Tromey <tom@tromey.com>
10162 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
10164 2018-03-27 Pedro Alves <palves@redhat.com>
10165 Tom Tromey <tom@tromey.com>
10167 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
10168 destructor. Now a class.
10169 (gdb_readline_wrapper_cleanup): Remove function.
10170 (gdb_readline_wrapper): Remove cleanups.
10172 2018-03-27 Tom Tromey <tom@tromey.com>
10174 * typeprint.h (struct type_print_options) <local_typedefs,
10175 global_typedefs>: Remove "struct" keyword.
10176 (class typedef_hash_table): New class.
10177 (recursively_update_typedef_hash, add_template_parameters)
10178 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
10179 (find_typedef_in_hash): Don't declare.
10180 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
10181 (typedef_hash_table::recursively_update): Rename from
10182 recursively_update_typedef_hash. Now a member.
10183 (typedef_hash_table::add_template_parameters): Rename from
10184 add_template_parameters. Now a member.
10185 (typedef_hash_table::typedef_hash_table): Now a constructor;
10186 rename from create_typedef_hash.
10187 (typedef_hash_table::~typedef_hash_table): Now a destructor;
10188 rename from free_typedef_hash.
10189 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
10190 (do_free_global_table): Remove.
10191 (typedef_hash_table::typedef_hash_table): New constructor; renamed
10192 from copy_type_recursive.
10193 (create_global_typedef_table): Remove.
10194 (typedef_hash_table::find_global_typedef): Now a member of
10195 typedef_hash_table.
10196 (typedef_hash_table::find_typedef): Rename from
10197 find_typedef_in_hash; now a member.
10198 (whatis_exp): Update.
10199 * extension.h (struct ext_lang_type_printers): Add constructor and
10201 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
10203 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
10204 Now a constructor; rename from start_ext_lang_type_printers.
10205 (ext_lang_type_printers): Now a destructor; rename from
10206 free_ext_lang_type_printers.
10207 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
10209 (c_type_print_base_struct_union): Update. Remove cleanups.
10211 2018-03-27 Tom Tromey <tom@tromey.com>
10213 * dwarf-index-write.c: Include <cmath>.
10215 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10217 * NEWS: Add entry describing new "set|show varsize-limit" command.
10218 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
10220 * printcmd.c (_initialize_printcmd): Add "set var" alias of
10223 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
10225 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
10226 dwarf-index-write.c
10227 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
10228 * dwarf-index-common.c: New file.
10229 * dwarf-index-common.h: New file.
10230 * dwarf-index-write.c: New file.
10231 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
10232 (struct dwarf2_section_info): Move from here.
10233 (dwarf2_section_info_def): Likewise.
10234 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
10235 (offset_type): Likewise.
10236 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
10237 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
10238 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
10239 (byte_swap): Likewise.
10240 (MAYBE_SWAP): Likewise.
10241 (dwarf2_per_cu_ptr): Likewise.
10242 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
10243 (struct tu_stats): Likewise.
10244 (struct dwarf2_per_objfile): Likewise.
10245 (struct dwarf2_per_cu_data): Likewise.
10246 (struct signatured_type): Likewise.
10247 (sig_type_ptr): Likewise.
10248 (DEF_VEC_P (sig_type_ptr)): Likewise.
10249 (INDEX4_SUFFIX): Likewise.
10250 (INDEX5_SUFFIX): Likewise.
10251 (DEBUG_STR_SUFFIX): Likewise.
10252 (dwarf2_read_section): Make non-static.
10253 (mapped_index_string_hash): Move from here.
10254 (dwarf5_djb_hash): Likewise.
10255 (file_write): Likewise.
10256 (class data_buf): Likewise.
10257 (struct symtab_index_entry): Likewise.
10258 (struct mapped_symtab): Likewise.
10259 (find_slot): Likewise.
10260 (hash_expand): Likewise.
10261 (add_index_entry): Likewise.
10262 (uniquify_cu_indices): Likewise.
10263 (class c_str_view): Likewise.
10264 (class c_str_view_hasher): Likewise.
10265 (class vector_hasher): Likewise.
10266 (write_hash_table): Likewise.
10267 (psym_index_map): Likewise.
10268 (struct addrmap_index_data): Likewise.
10269 (add_address_entry): Likewise.
10270 (add_address_entry_worker): Likewise.
10271 (write_address_map): Likewise.
10272 (symbol_kind): Likewise.
10273 (write_psymbols): Likewise.
10274 (struct signatured_type_index_data): Likewise.
10275 (write_one_signatured_type): Likewise.
10276 (recursively_count_psymbols): Likewise.
10277 (recursively_write_psymbols): Likewise.
10278 (class debug_names): Likewise.
10279 (check_dwarf64_offsets): Likewise.
10280 (psyms_seen_size): Likewise.
10281 (write_gdbindex): Likewise.
10282 (write_debug_names): Likewise.
10283 (assert_file_size): Likewise.
10284 (write_psymtabs_to_index): Likewise.
10285 (save_gdb_index_command): Likewise.
10286 (_initialize_dwarf2_read): Don't register the "save gdb-index"
10288 * dwarf2read.h: New file.
10290 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10293 * dwarf2read.c (dwarf2_physname): Do not return the demangled
10294 symbol name if the CU's language stores symbol names in linkage
10296 * language.h (struct language_defn)
10297 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
10298 all instances of this struct.
10300 2018-03-26 Tom Tromey <tom@tromey.com>
10302 * stack.c (backtrace_command_1): Remove verbose code.
10304 2018-03-26 Tom Tromey <tom@tromey.com>
10306 * python/py-framefilter.c (py_print_type): Don't catch
10307 exceptions. Return void.
10308 (py_print_value): Likewise.
10309 (py_print_single_arg): Likewise.
10310 (enumerate_args): Don't catch exceptions.
10311 (py_print_args): Likewise.
10312 (py_print_frame): Likewise.
10313 (gdbpy_apply_frame_filter): Catch exceptions here.
10315 2018-03-26 Tom Tromey <tom@tromey.com>
10317 * stack.c (_initialize_stack): Remove trailing newlines from help
10318 text. Add "Usage" line to "backtrace" help.
10320 2018-03-26 Tom Tromey <tom@tromey.com>
10323 * python/py-framefilter.c (py_print_args): Call wrap_hint.
10325 2018-03-26 Tom Tromey <tom@tromey.com>
10327 * python/py-framefilter.c (py_print_single_arg): Return
10328 EXT_LANG_BT_ERROR from catch.
10330 2018-03-26 Tom Tromey <tom@tromey.com>
10332 PR backtrace/15584:
10333 * stack.c (backtrace_command_1): Move some code into no-filters
10336 2018-03-26 Tom Tromey <tom@tromey.com>
10338 * python/py-framefilter.c (throw_quit_or_print_exception): New
10340 (gdbpy_apply_frame_filter): Use it.
10342 2018-03-26 Tom Tromey <tom@tromey.com>
10345 * python/py-framefilter.c (py_print_type, py_print_value)
10346 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
10349 2018-03-26 Tom Tromey <tom@tromey.com>
10351 * python/py-framefilter.c (enumerate_args): Use
10352 gdb::unique_xmalloc_ptr.
10354 2018-03-26 Tom Tromey <tom@tromey.com>
10356 * python/py-framefilter.c (py_print_frame): Return
10358 (gdbpy_apply_frame_filter): Update comment.
10359 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
10361 <EXT_LANG_BT_NO_FILTERS>: Change value.
10363 2018-03-26 Tom Tromey <tom@tromey.com>
10365 PR backtrace/15582:
10366 * stack.c (backtrace_command): Parse "hide" argument.
10367 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
10368 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
10371 2018-03-26 Tom Tromey <tom@tromey.com>
10373 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
10375 (backtrace_command): Remove "fulltrace", add "flags".
10377 2018-03-26 Tom Tromey <tom@tromey.com>
10379 * stack.c (backtrace_command): Rewrite command line parsing.
10381 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10383 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
10385 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10387 * filename-seen-cache.h: Add include guard.
10389 2018-03-26 Keith Seitz <keiths@redhat.com>
10391 * symfile.c (place_section): Remove "struct" from section_addr_info
10393 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
10394 "struct" keyword from section_addr_info.
10396 2018-03-26 Alan Hayward <alan.hayward@arm.com>
10398 * regformats/regdef.h (reg): Add constructors.
10400 2018-03-25 Pedro Alves <palves@redhat.com>
10402 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
10403 if then/else bodies in var_func_name extraction.
10405 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
10407 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
10408 lookup_minimal_symbol() to find symbol entry.
10409 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
10411 2018-03-23 Keith Seitz <keiths@redhat.com>
10414 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
10415 nested type definitions for C++, too.
10417 2018-03-23 Tom Tromey <tom@tromey.com>
10419 * machoread.c (struct oso_el): Add a constructor. Don't define as
10421 (macho_register_oso): Remove.
10422 (macho_symtab_read): Take a std::vector.
10423 (oso_el_compare_name): Now a std::sort comparator.
10424 (macho_symfile_read_all_oso): Take a std::vector.
10425 (macho_symfile_read): Use std::vector. Remove cleanups.
10427 2018-03-22 Tom Tromey <tom@tromey.com>
10429 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
10430 (record_full_goto_bookmark): Use std::string.
10432 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10435 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
10438 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10440 * rs6000-tdep.c (store_insn_p): New function.
10441 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
10442 and cr_reg to their unshifted values. Use store_insn_p to
10443 match LR saves using either R1 or fdata->alloca_reg. Use
10444 store_insn_p to match CR saves. Set alloca_reg_offset
10445 when alloca_reg and framep are set. Remove lr_reg shift
10446 when assigning to fdata->lr_register.
10448 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
10450 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
10451 command line args instead of emitting a warning.
10453 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10455 * tracepoint.h (struct static_tracepoint_marker): Initialize
10456 fields, define default constructor, move constructor and move
10457 assignment, disable the rest.
10458 <str_id, extra>: Make std::string.
10459 (release_static_tracepoint_marker): Remove.
10460 (free_current_marker): Remove.
10461 * tracepoint.c (free_current_marker): Remove.
10462 (parse_static_tracepoint_marker_definition): Adjust to
10463 std::string, use new hex2str overload.
10464 (release_static_tracepoint_marker): Remove.
10465 (print_one_static_tracepoint_marker): Get marker by reference
10466 and adjust to std::string.
10467 (info_static_tracepoint_markers_command): Adjust to std::vector
10469 * target.h (static_tracepoint_marker_p): Remove typedef.
10470 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
10471 (struct target_ops) <to_static_tracepoint_marker_at>: Return
10473 <to_static_tracepoint_markers_by_strid>: Return std::vector.
10475 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
10476 (target_debug_print_std_vector_static_tracepoint_marker): New.
10477 (target_debug_print_struct_static_tracepoint_marker_p): Rename
10479 (target_debug_print_static_tracepoint_marker_p): ... this.
10480 * target-delegates.c: Re-generate.
10481 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
10483 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
10484 (decode_static_tracepoint_spec): Adjust to std::vector.
10485 (tracepoint_print_one_detail): Adjust to std::string.
10486 (strace_marker_decode_location): Adjust to std::string.
10487 (update_static_tracepoint): Adjust to std::string, remove call
10488 to release_static_tracepoint_marker.
10489 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
10490 Adjust to std::vector.
10491 * remote.c (remote_static_tracepoint_marker_at): Return bool.
10492 (remote_static_tracepoint_markers_by_strid): Adjust to
10494 * common/rsp-low.h (hex2str): New overload with explicit count
10496 * common/rsp-low.c (hex2str): New overload with explicit count
10498 * unittests/rsp-low-selftests.c (test_hex2str): New function.
10499 (_initialize_rsp_low_selftests): Add test_hex2str test.
10500 * unittests/tracepoint-selftests.c
10501 (test_parse_static_tracepoint_marker_definition): Adjust to
10504 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10506 * tracepoint.c (parse_static_tracepoint_marker_definition):
10507 Consider case where the definition is followed by more
10509 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10510 tracepoint-selftests.c.
10511 * unittests/tracepoint-selftests.c: New.
10513 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10515 * MAINTAINERS (Write After Approval): Add Pedro Franco de
10518 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10520 * symtab.c (find_pc_sect_line): fixed indentation.
10522 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10524 * symtab.c (find_pc_sect_line): now uses binary search.
10526 2018-03-19 Tom Tromey <tom@tromey.com>
10528 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
10529 "IDENT" production.
10531 2018-03-19 Pedro Alves <palves@redhat.com>
10532 Tom Tromey <tom@tromey.com>
10534 * unittests/observable-selftests.c: New file.
10535 * common/observable.h: New file.
10536 * observable.h: New file.
10537 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
10538 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
10539 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
10540 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
10541 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
10542 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
10543 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
10544 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
10545 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
10546 python/py-breakpoint.c, python/py-finishbreakpoint.c,
10547 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
10548 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
10549 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
10550 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
10551 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
10552 tui/tui-interp.c, valops.c: Update all users.
10553 * tui/tui-hooks.c (tui_bp_created_observer)
10554 (tui_bp_deleted_observer, tui_bp_modified_observer)
10555 (tui_inferior_exit_observer, tui_before_prompt_observer)
10556 (tui_normal_stop_observer, tui_register_changed_observer):
10558 (tui_observers_token): New global.
10559 (attach_or_detach, tui_attach_detach_observers): New functions.
10560 (tui_install_hooks, tui_remove_hooks): Use
10561 tui_attach_detach_observers.
10562 * record-btrace.c (record_btrace_thread_observer): Remove.
10563 (record_btrace_thread_observer_token): New global.
10564 * observer.sh: Remove.
10565 * observer.c: Rename to observable.c.
10566 * observable.c (namespace gdb_observers): Define new objects.
10567 (observer_debug): Move into gdb_observers namespace.
10568 (struct observer, struct observer_list, xalloc_observer_list_node)
10569 (xfree_observer_list_node, generic_observer_attach)
10570 (generic_observer_detach, generic_observer_notify): Remove.
10571 (_initialize_observer): Update.
10572 Don't include observer.inc.
10573 * Makefile.in (generated_files): Remove observer.h, observer.inc.
10574 (clean mostlyclean): Likewise.
10575 (observer.h, observer.inc): Remove targets.
10576 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
10577 (COMMON_SFILES): Use observable.c, not observer.c.
10578 * .gitignore: Remove observer.h.
10580 2018-03-18 Tom Tromey <tom@tromey.com>
10582 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
10584 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
10586 2018-03-17 Tom Tromey <tom@tromey.com>
10588 * auto-load.c (auto_load_objfile_script_1): Use std::string.
10590 2018-03-17 Tom Tromey <tom@tromey.com>
10592 * target.c (class scoped_target_fd): New.
10593 (target_fileio_close_cleanup): Remove.
10594 (target_fileio_read_alloc_1): Use scoped_target_fd.
10596 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
10598 * silent-rules.mk: New.
10599 * Makefile.in: Include silent-rules.mk
10600 (srcdir, VPATH, top_srcdir): Move up.
10601 (COMPILE): Add ECHO_CXX.
10602 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
10603 (init.c): Add ECHO_INIT_C.
10604 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
10605 (version.c): Add ECHO_GEN.
10606 (printcmd.o): Add ECHO_CXX.
10607 (target-float.o): Add ECHO_CXX.
10608 (ada-exp.o): Add ECHO_CXX.
10609 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
10610 (insight$(EXEEXT)): Add ECHO_CXXLD.
10611 * gnulib/configure.ac: Add AM_SILENT_RULES.
10612 * gnulib/aclocal.m4: Re-generate.
10613 * gnulib/configure: Re-generate.
10614 * gnulib/import/Makefile.in: Re-generate.
10616 2018-03-16 Tom Tromey <tom@tromey.com>
10618 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
10619 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
10620 * utils.c (do_free_section_addr_info)
10621 (make_cleanup_free_section_addr_info): Remove.
10622 * symfile.h (struct other_sections): Add constructor.
10623 (struct section_addr_info): Remove.
10624 (section_addr_info): New typedef.
10625 (struct sym_fns) <sym_offsets>: Change type of parameter.
10626 (build_section_addr_info_from_objfile)
10627 (relative_addr_info_to_section_offsets, addr_info_make_relative)
10628 (default_symfile_offsets, symbol_file_add)
10629 (symbol_file_add_from_bfd)
10630 (build_section_addr_info_from_section_table): Update.
10631 (alloc_section_addr_info, free_section_addr_info): Don't declare.
10632 * symfile.c (alloc_section_addr_info): Remove.
10633 (build_section_addr_info_from_section_table): Change return type.
10635 (build_section_addr_info_from_bfd)
10636 (build_section_addr_info_from_objfile): Likewise.
10637 (free_section_addr_info): Remove.
10638 (relative_addr_info_to_section_offsets): Change type of "addrs".
10639 (addrs_section_compar): Now a std::sort comparator.
10640 (addrs_section_sort): Change return type.
10641 (addr_info_make_relative): Change type of "addrs". Update.
10642 (default_symfile_offsets, syms_from_objfile_1)
10643 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
10644 (symbol_file_add_separate): Update.
10645 (symbol_file_add): Change type of "addrs". Update.
10646 (add_symbol_file_command): Update. Remove cleanups.
10647 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
10649 * symfile-debug.c (debug_sym_offsets): Change type of "info".
10650 * solib.c (solib_read_symbols): Update.
10651 * objfiles.c (objfile_relocate): Update. Remove cleanups.
10652 * machoread.c (macho_symfile_offsets): Update.
10653 * jit.c (jit_bfd_try_read_symtab): Update.
10655 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
10657 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10658 unittests/utils-selftests.c.
10659 * unittests/utils-selftests.c: New file.
10661 2018-03-14 Tom Tromey <tom@tromey.com>
10664 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
10667 2018-03-14 Tom Tromey <tom@tromey.com>
10670 * printcmd.c (printf_pointer): Allow "-" in format.
10672 2018-03-14 Tom Tromey <tom@tromey.com>
10674 * printcmd.c (_initialize_printcmd): Add usage to printf.
10676 2018-03-14 Yao Qi <qiyao@sourceware.org>
10678 * MAINTAINERS: Update my email address.
10680 2018-03-13 Tom Tromey <tom@tromey.com>
10682 * machoread.c (macho_check_dsym): Change filenamep to a
10684 (macho_symfile_read): Update.
10685 * symfile.c (load_command): Use std::string.
10687 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
10689 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
10690 to error message string.
10691 (riscv_register_name): Use xsnprintf instead of sprintf.
10692 (riscv_insn::fetch_instruction): Use gdb_assert instead of
10694 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
10696 (riscv_push_dummy_call): Likewise.
10698 2018-03-12 Tom Tromey <tom@tromey.com>
10700 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
10701 Use gdb::byte_vector.
10702 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
10704 2018-03-12 Yao Qi <yao.qi@linaro.org>
10706 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
10707 parameter type to readable_regcache.
10708 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
10711 2018-03-11 Tom Tromey <tom@tromey.com>
10713 * dwarf2read.c (struct nextfield): Add initializers.
10714 (struct nextfnfield): Remove.
10715 (struct fnfieldlist): Add initializers. Remove "length" and
10716 "head", use std::vector.
10717 (struct decl_field_list): Remove.
10718 (struct field_info): Add initializers.
10719 <fields, baseclasses>: Now std::vector.
10720 <nbaseclasses, nfnfields, typedef_field_list_count,
10721 nested_types_list_count>: Remove.
10722 (dwarf2_add_field, dwarf2_add_type_defn)
10723 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
10724 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
10725 (process_structure_scope): Update.
10727 2018-03-11 Tom Tromey <tom@tromey.com>
10729 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
10730 for use by std::sort.
10731 (build_type_psymtabs_1): Use std::vector.
10733 2018-03-09 Eli Zaretskii <eliz@gnu.org>
10735 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
10736 and LIBMPFR in the printed configuration.
10738 2018-03-08 Tom Tromey <tom@tromey.com>
10740 * source.c (get_filename_and_charpos): Use scoped_fd.
10741 * nto-procfs.c (procfs_open_1): Use scoped_fd.
10742 (procfs_pidlist): Likewise.
10743 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
10744 (iterate_over_mappings): Likewise.
10746 2018-03-08 Tom Tromey <tom@tromey.com>
10748 * infcall.c (struct call_return_meta_info)
10749 <stack_temporaries_enabled>: Remove.
10750 (get_call_return_value, call_function_by_hand_dummy): Update.
10751 * thread.c (disable_thread_stack_temporaries): Remove.
10752 (enable_thread_stack_temporaries): Remove.
10753 (thread_stack_temporaries_enabled_p): Return bool.
10754 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
10755 (get_last_thread_stack_temporary): Update.
10756 * eval.c (evaluate_subexp): Update.
10757 * gdbthread.h (class enable_thread_stack_temporaries): Now a
10758 class, not a function.
10759 (value_ptr, value_vec): Remove typedefs.
10760 (class thread_info) <stack_temporaries_enabled>: Now bool.
10761 <stack_temporaries>: Now a std::vector.
10762 (thread_stack_temporaries_enabled_p)
10763 (value_in_thread_stack_temporaries): Return bool.
10765 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
10767 * remote.c (putpkt_binary): Fix omitted bytes reporting.
10768 (getpkt_or_notif_sane_1): Likewise.
10770 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10772 * build-id.c (build_id_to_debug_bfd): Use std::string.
10774 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10776 * build-id.c (find_separate_debug_file_by_buildid): Return
10778 * build-id.h (find_separate_debug_file_by_buildid): Return
10780 * coffread.c (coff_symfile_read): Adjust to std::string.
10781 * elfread.c (elf_symfile_read): Adjust to std::string.
10782 * symfile.c (separate_debug_file_exists): Change parameter to
10784 (find_separate_debug_file): Return std::string.
10785 (find_separate_debug_file_by_debuglink): Return std::string.
10786 * symfile.h (find_separate_debug_file_by_debuglink): Return
10789 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10791 * common/xml-utils.c (xml_escape_text): Move code to...
10792 (xml_escape_text_append): ... this new function.
10793 * common/xml-utils.h (xml_escape_text_append): New declaration.
10794 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
10796 (_initialize_xml_utils): register test_xml_escape_text_append as
10799 2018-03-07 Alan Hayward <alan.hayward@arm.com>
10801 * defs.h: Remove MAX_REGISTER_SIZE.
10802 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
10804 * python/py-unwind.c (pyuw_sniffer): Likewise.
10806 2018-03-07 Tom Tromey <tom@tromey.com>
10808 * linux-tdep.c (linux_info_proc): Update.
10809 * target.h (struct target_ops) <to_fileio_readlink>: Return
10811 (target_fileio_readlink): Return optional<string>.
10812 * remote.c (remote_hostio_readlink): Return optional<string>.
10813 * inf-child.c (inf_child_fileio_readlink): Return
10815 * target.c (target_fileio_readlink): Return optional<string>.
10817 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
10819 * regcache.c (cooked_read_test): Add riscv to the list of
10820 architectures that have a save_reggroup.
10822 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
10824 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
10825 value is not a dynamic class object.
10827 2018-03-06 Tom Tromey <tom@tromey.com>
10829 * rust-exp.y: Formatting fixes.
10831 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10833 * riscv-tdep.c (riscv_register_name): Remove target description
10835 (riscv_gdbarch_init): Remove target description check.
10837 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10839 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
10841 * riscv-tdep.h: Likewise.
10843 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10845 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
10846 (riscv_pseudo_register_write): Delete.
10847 (riscv_gdbarch_init): Remove all use of pseudo registers.
10849 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10851 * record-btrace.c (btrace_print_lines): Replace cleanup
10852 parameter with RAII equivalents.
10853 (btrace_insn_history): Replace cleanup with RAII equivalents.
10854 * ui-out.h (make_cleanup_ui_out_list_begin_end,
10855 make_cleanup_ui_out_tuple_begin_end): Remove.
10856 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
10857 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
10858 make_cleanup_ui_out_list_begin_end): Remove.
10860 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10862 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
10863 parameter types to std::vector. Use bool.
10864 (record_btrace_wait): Replace VEC(tp_t) with
10865 std::vector<thread_info *>.
10866 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
10868 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10870 * record-btrace.c (record_btrace_disable_callback): Remove.
10871 (struct scoped_btrace_disable): New.
10872 (record_btrace_open): Use scoped_btrace_disable.
10874 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10876 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
10877 reading values from registers.
10879 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10881 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
10884 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10886 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
10887 change parameter type. Use GDB's print functions, and use
10888 core_addr_to_string where appropriate.
10889 (riscv_push_dummy_call): Use core_addr_to_string where
10890 appropriate, update call to riscv_print_arg_location, and reindent
10892 (riscv_return_value): Update call to riscv_print_arg_location.
10894 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10895 Tim Newsome <tim@sifive.com>
10896 Albert Ou <a0u@eecs.berkeley.edu>
10897 Darius Rad <darius@bluespec.com>
10899 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
10900 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
10901 (ALLDEPFILES): Add riscv-tdep.c
10902 * configure.tgt: Add riscv support.
10903 * riscv-tdep.c: New file.
10904 * riscv-tdep.h: New file.
10905 * NEWS: Mention new target.
10906 * MAINTAINERS: Add entry for riscv.
10908 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10910 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
10911 fields within aggregates.
10913 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
10915 * record-btrace.c (btrace_print_lines): Change type of flags to
10916 gdb_disassembly_flags.
10918 2018-03-04 John Baldwin <jhb@FreeBSD.org>
10920 * fbsd-nat.c: Include "inf-ptrace.h".
10921 (USE_SIGTRAP_SIGINFO): Conditionally define.
10922 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
10923 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
10924 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
10926 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
10928 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
10930 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
10931 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
10932 "supports_stopped_by_hw_breakpoint" target methods.
10934 2018-03-04 John Baldwin <jhb@FreeBSD.org>
10936 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
10937 * fbsd-nat.c (debug_fbsd_nat): New variable.
10938 (show_fbsd_nat_debug): New function.
10939 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
10940 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
10942 2018-03-04 John Baldwin <jhb@FreeBSD.org>
10944 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
10945 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
10947 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
10948 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
10951 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10953 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
10954 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
10956 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10958 * charset.c (struct charset_vector): New.
10959 (charsets): Change type to charset_vector.
10960 (find_charset_names): Adjust.
10962 (_initialize_charset): Adjust.
10964 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10966 * progspace.h (struct program_space) <deleted_solibs>: Change
10967 type to std::vector<std::string>.
10968 * progspace.c (clear_program_space_solib_cache): Adjust.
10969 * breakpoint.c (print_solib_event): Adjust.
10970 (check_status_catch_solib): Adjust.
10971 * solib.c (update_solib_list): Adjust.
10972 * ui-out.h (class ui_out) <field_string>: New overload.
10973 * ui-out.c (ui_out::field_string): New overload.
10975 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10977 * progspace.h (struct program_space): Add constructor and
10978 destructor, initialize fields.
10979 (add_program_space): Remove.
10980 * progspace.c (add_program_space): Rename to...
10981 (program_space::program_space): ... this.
10982 (release_program_space): Rename to...
10983 (program_space::~program_space): ... this.
10984 (delete_program_space): Use delete to delete program_space.
10985 (initialize_progspace): Use new to allocate program_space.
10986 * inferior.c (add_inferior_with_spaces): Likewise.
10987 (clone_inferior_command): Likewise.
10988 * infrun.c (follow_fork_inferior): Likewise.
10989 (handle_vfork_child_exec_or_exit): Likewise.
10991 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10993 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
10994 (delim_string_to_char_ptr_vec): Return std::vector of
10995 gdb::unique_xmalloc_ptr.
10996 (dirnames_to_char_ptr_vec_append): Take std::vector of
10997 gdb::unique_xmalloc_ptr.
10998 (dirnames_to_char_ptr_vec): Return std::vector of
10999 gdb::unique_xmalloc_ptr.
11000 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
11001 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
11002 (delim_string_to_char_ptr_vec): Return an std::vector of
11003 gdb::unique_xmalloc_ptr, adjust the code.
11004 (dirnames_to_char_ptr_vec_append): Take an std::vector of
11005 gdb::unique_xmalloc_ptr, adjust the code.
11006 (dirnames_to_char_ptr_vec): Return an std::vector of
11007 gdb::unique_xmalloc_ptr, adjust the code.
11008 * auto-load.c (auto_load_safe_path_vec): Change type to
11009 std::vector of gdb::unique_xmalloc_ptr.
11010 (auto_load_expand_dir_vars): Return an std::vector of
11011 gdb::unique_xmalloc_ptr, adjust the code.
11012 (auto_load_safe_path_vec_update): Adjust.
11013 (filename_is_in_auto_load_safe_path_vec): Adjust.
11014 (auto_load_objfile_script_1): Adjust.
11015 * build-id.c (build_id_to_debug_bfd): Adjust.
11016 * linux-thread-db.c (thread_db_load_search): Adjust.
11017 * source.c (add_path): Adjust.
11019 * symfile.c (find_separate_debug_file): Adjust.
11020 * utils.c (do_free_char_ptr_vec): Remove.
11021 (make_cleanup_free_char_ptr_vec): Remove.
11023 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
11026 * common/pathstuff.c: Conditionally include "<windows.h>".
11028 2018-03-01 Georg Sauthoff <mail@georg.so>
11031 * gcore.in: Quote variables and switch interpreter to bash.
11033 2018-03-01 Tom Tromey <tom@tromey.com>
11035 * dwarf2read.c (alloc_discriminant_info): Fix default_index
11036 assertion. Add assertion for discriminant_index.
11037 (quirk_rust_enum): Use correct base type name in univariant case.
11039 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
11041 * record.c (get_call_history_modifiers): Return a
11042 record_print_flags.
11043 (cmd_record_call_history): Adjust.
11044 * record-btrace.c (record_btrace_call_history): Adjust.
11045 (record_btrace_call_history_range): Adjust.
11046 (record_btrace_call_history_from): Adjust.
11047 * target-debug.h (target_debug_print_record_print_flags): New.
11048 * target-delegates.c: Re-generate.
11049 * target.c (target_call_history): Change flags type.
11050 (target_call_history_from): Likewise.
11051 (target_call_history_range): Likewise.
11052 * target.h (struct target_ops) <target_call_history>: Likewise.
11053 (target_call_history_from): Likewise.
11054 (target_call_history_range): Likewise.
11056 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11057 Simon Marchi <simon.marchi@polymtl.ca>
11059 * common/common-utils.c: Include "sys/stat.h".
11060 (is_regular_file): Move here from "source.c"; change return
11062 * common/common-utils.h (is_regular_file): New prototype.
11063 * common/pathstuff.c (contains_dir_separator): New function.
11064 * common/pathstuff.h (contains_dir_separator): New prototype.
11065 * source.c: Don't include "sys/stat.h".
11066 (is_regular_file): Move to "common/common-utils.c".
11068 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11070 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
11071 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
11072 * auto-load.c: Include "common/pathstuff.h".
11073 * common/common-def.h (current_directory): Move here.
11074 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
11076 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
11078 * common/pathstuff.c: New file.
11079 * common/pathstuff.h: New file.
11080 * compile/compile.c: Include "common/pathstuff.h".
11081 * defs.h (current_directory): Move to "common/common-defs.h".
11082 * dwarf2read.c: Include "common/pathstuff.h".
11083 * exec.c: Likewise.
11084 * guile/scm-safe-call.c: Likewise.
11085 * linux-thread-db.c: Likewise.
11086 * main.c: Likewise.
11087 * nto-tdep.c: Likewise.
11088 * objfiles.c: Likewise.
11089 * source.c: Likewise.
11090 * symtab.c: Likewise.
11091 * utils.c: Include "common/pathstuff.h".
11092 (gdb_realpath): Move to "common/pathstuff.c".
11093 (gdb_realpath_keepfile): Likewise.
11094 (gdb_abspath): Likewise.
11095 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
11096 (gdb_realpath_keepfile): Likewise.
11097 (gdb_abspath): Likewise.
11099 2018-02-28 John Baldwin <jhb@FreeBSD.org>
11101 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
11102 wildcard process pid for super_resume for kernels with a
11105 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
11107 * compile/compile.c (get_args): Add additional comments
11108 explaining function.
11110 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
11111 Tom Tromey <tom@tromey.com>
11113 * target.h (memory_write_request_s): Remove typedef. Don't define
11115 (target_write_memory_blocks): Change argument to std::vector.
11116 (struct memory_write_request): Add constructor.
11117 * target-memory.c (compare_block_starting_address): Return bool.
11118 Change argument types.
11119 (claim_memory): Change arguments to use std::vector.
11120 (split_regular_and_flash_blocks, blocks_to_erase)
11121 (compute_garbled_blocks): Likewise.
11122 (cleanup_request_data, cleanup_write_requests_vector): Remove.
11123 (target_write_memory_blocks): Change argument to std::vector.
11124 * symfile.c (struct load_section_data): Add constructor and
11125 destructor. Use std::vector for "requests".
11126 (struct load_progress_data): Add initializers.
11127 (load_section_callback): Update. Use "new".
11128 (clear_memory_write_data): Remove.
11129 (generic_load): Update.
11131 2018-02-27 Alan Hayward <alan.hayward@arm.com>
11133 * arch/aarch64.h: Use common/tdesc.h.
11135 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11137 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
11138 architecture with a 64-bit ABI.
11140 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11142 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
11143 ahead of target description loading.
11145 2018-02-26 Tom Tromey <tom@tromey.com>
11147 * stack.c (backtrace_command_1): Update.
11148 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
11150 * python/py-framefilter.c (py_print_frame)
11151 (gdbpy_apply_frame_filter): Change type of "flags".
11152 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
11154 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
11155 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
11156 * extension.h (enum frame_filter_flag): Rename from
11157 frame_filter_flags.
11158 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
11159 (apply_ext_lang_frame_filter): Change type of "flags".
11160 * extension.c (apply_ext_lang_frame_filter): Change type of
11162 * extension-priv.h (struct extension_language_ops)
11163 <apply_frame_filter>: Change type of "flags".
11165 2018-02-26 Tom Tromey <tom@tromey.com>
11168 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
11169 off-by-one in py_end computation.
11170 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
11172 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
11175 2018-02-26 Tom Tromey <tom@tromey.com>
11177 * dwarf2read.c (struct variant_field): New.
11178 (struct nextfield) <variant>: New field.
11179 (dwarf2_add_field): Handle DW_TAG_variant_part.
11180 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
11181 discriminated union.
11182 (read_structure_type): Handle DW_TAG_variant_part.
11183 (handle_struct_member_die): New function, extracted from
11184 process_structure_scope. Handle DW_TAG_variant.
11185 (process_structure_scope): Handle discriminated unions. Call
11186 handle_struct_member_die.
11188 2018-02-26 Tom Tromey <tom@tromey.com>
11190 * rust-lang.h (rust_last_path_segment): Declare.
11191 * rust-lang.c (rust_last_path_segment): Now public. Change
11193 (struct disr_info): Remove.
11194 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
11195 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
11196 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
11197 (rust_enum_p, rust_enum_variant): New function.
11198 (rust_underscore_fields): Remove "offset" parameter.
11199 (rust_print_enum): New function.
11200 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
11201 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
11202 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
11204 (rust_internal_print_type): New function, from rust_print_type.
11206 (rust_print_type): Call rust_internal_print_type.
11207 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
11208 Update enum handling.
11209 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
11210 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
11211 (rust_union_quirks): New functions.
11212 (process_full_comp_unit, process_full_type_unit): Call
11214 (process_structure_scope): Update rust_unions if necessary.
11216 2018-02-26 Tom Tromey <tom@tromey.com>
11218 * value.h (value_union_variant): Declare.
11219 * valops.c (value_union_variant): New function.
11220 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
11221 (struct discriminant_info): New.
11222 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
11224 (struct main_type) <flag_discriminated_union>: New field.
11226 2018-02-26 Tom Tromey <tom@tromey.com>
11228 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11229 unittests/unpack-selftests.c.
11230 * unittests/unpack-selftests.c: New file.
11231 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
11233 2018-02-26 Yao Qi <yao.qi@linaro.org>
11235 * dwarf2read.c (struct partial_die_info) <read>: New method.
11236 (read_partial_die): Remove the declaration.
11237 (load_partial_dies): Update.
11238 (partial_die_info::partial_die_info):
11239 (read_partial_die): Change it to partial_die_info::read.
11241 2018-02-26 Yao Qi <yao.qi@linaro.org>
11243 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
11244 (fixup_partial_die): Remove declaration.
11245 (scan_partial_symbols): Update.
11246 (partial_die_parent_scope): Likewise.
11247 (partial_die_full_name): Likewise.
11248 (fixup_partial_die): Change it to partial_die_info::fixup.
11250 2018-02-26 Yao Qi <yao.qi@linaro.org>
11252 * dwarf2read.c (read_partial_die): Update the declaration.
11253 (load_partial_dies): Caller update.
11254 (read_partial_die): Remove one argument abbrev_len.
11256 2018-02-26 Yao Qi <yao.qi@linaro.org>
11258 * dwarf2read.c (struct partial_die_info): Add ctor, delete
11259 assignment operator.
11260 (load_partial_dies): Use ctor and copy ctor.
11261 (read_partial_die): Update.
11262 (dwarf2_cu::find_partial_die): Use ctor.
11264 2018-02-26 Yao Qi <yao.qi@linaro.org>
11266 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
11267 (find_partial_die_in_comp_unit): Change it to
11268 dwarf2_cu::find_partial_die.
11269 (find_partial_die): Update.
11271 2018-02-26 Yao Qi <yao.qi@linaro.org>
11273 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
11276 2018-02-26 Yao Qi <yao.qi@linaro.org>
11278 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
11280 2018-02-26 Alan Hayward <alan.hayward@arm.com>
11282 * arch/amd64.h: Use common/tdesc.h.
11283 * arch/i386.c: Likewise.
11284 * arch/i386.h: Likewise.
11285 * arch/tic6x.c: Likewise.
11286 * arch/tdesc.h: Move file from here...
11287 * common/tdesc.h: ...to here.
11288 * features/aarch64-core.c: Regenerate.
11289 * features/aarch64-fpu.c: Regenerate.
11290 * features/i386/32bit-avx.c: Regenerate.
11291 * features/i386/32bit-avx512.c: Regenerate.
11292 * features/i386/32bit-core.c: Regenerate.
11293 * features/i386/32bit-linux.c: Regenerate.
11294 * features/i386/32bit-mpx.c: Regenerate.
11295 * features/i386/32bit-pkeys.c: Regenerate.
11296 * features/i386/32bit-sse.c: Regenerate.
11297 * features/i386/64bit-avx.c: Regenerate.
11298 * features/i386/64bit-avx512.c: Regenerate.
11299 * features/i386/64bit-core.c: Regenerate.
11300 * features/i386/64bit-linux.c: Regenerate.
11301 * features/i386/64bit-mpx.c: Regenerate.
11302 * features/i386/64bit-pkeys.c: Regenerate.
11303 * features/i386/64bit-segments.c: Regenerate.
11304 * features/i386/64bit-sse.c: Regenerate.
11305 * features/i386/x32-core.c: Regenerate.
11306 * features/tic6x-c6xp.c: Regenerate.
11307 * features/tic6x-core.c: Regenerate.
11308 * features/tic6x-gp.c: Regenerate.
11309 * target-descriptions.c: Use common/tdesc.h.
11310 * target-descriptions.h: Likewise.
11312 2018-02-24 Tom Tromey <tom@tromey.com>
11314 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
11315 (try_thread_db_load_from_dir, thread_db_load_search): Use
11317 (info_auto_load_libthread_db_compare): Return bool. Change
11319 (info_auto_load_libthread_db): Use std::vector, std::string.
11322 2018-02-24 Tom Tromey <tom@tromey.com>
11324 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
11326 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
11328 * gdbarch.c: Rebuild.
11329 * gdbarch.h: Rebuild.
11330 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
11331 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
11332 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
11335 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
11337 * gdbtypes.h (sect_offset): Change type to uint64_t.
11338 (sect_offset_str): New function.
11339 * dwarf2read.c (create_addrmap_from_aranges): Use
11341 (error_check_comp_unit_head): Likewise.
11342 (create_debug_type_hash_table): Likewise.
11343 (read_cutu_die_from_dwo): Likewise.
11344 (init_cutu_and_read_dies): Likewise.
11345 (init_cutu_and_read_dies_no_follow): Likewise.
11346 (process_psymtab_comp_unit_reader): Likewise.
11347 (partial_die_parent_scope): Likewise.
11348 (peek_die_abbrev): Likewise.
11349 (process_queue): Likewise.
11350 (dwarf2_physname): Likewise.
11351 (read_namespace_alias): Likewise.
11352 (read_import_statement): Likewise.
11353 (create_dwo_cu_reader): Likewise.
11354 (create_cus_hash_table): Likewise.
11355 (lookup_dwo_cutu): Likewise.
11356 (inherit_abstract_dies): Likewise.
11357 (read_func_scope): Likewise.
11358 (read_call_site_scope): Likewise.
11359 (dwarf2_add_member_fn): Likewise.
11360 (read_common_block): Likewise.
11361 (read_module_type): Likewise.
11362 (read_typedef): Likewise.
11363 (read_subrange_type): Likewise.
11364 (load_partial_dies): Likewise.
11365 (read_partial_die): Likewise.
11366 (find_partial_die): Likewise.
11367 (read_str_index): Likewise.
11368 (dwarf2_string_attr): Likewise.
11369 (build_error_marker_type): Likewise.
11370 (lookup_die_type): Likewise.
11371 (dump_die_shallow): Likewise.
11372 (follow_die_ref): Likewise.
11373 (dwarf2_fetch_die_loc_sect_off): Likewise.
11374 (dwarf2_fetch_constant_bytes): Likewise.
11375 (follow_die_sig): Likewise.
11376 (get_signatured_type): Likewise.
11377 (get_DW_AT_signature_type): Likewise.
11378 (dwarf2_find_containing_comp_unit): Likewise.
11379 (set_die_type): Likewise.
11381 2018-02-21 John Baldwin <jhb@FreeBSD.org>
11383 * arch/aarch64.c: Include "common-defs.h".
11384 * arch/amd64.c: Likewise.
11385 * arch/i386.c: Likewise.
11387 2018-02-21 Tom Tromey <tom@tromey.com>
11389 * value.h: (extract_field_op): Update.
11390 * eval.c (extract_field_op): Return a const char *.
11391 * expression.h (parse_expression_for_completion): Update.
11392 * completer.c (complete_expression): Update.
11393 (add_struct_fields): Make fieldname const.
11394 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
11395 (mark_completion_tag, parse_exp_in_context_1): Update.
11396 (parse_expression_for_completion): Change "name" to
11397 unique_xmalloc_ptr*.
11399 2018-02-21 Tom Tromey <tom@tromey.com>
11401 * infcall.c (call_function_by_hand_dummy): Use std::vector.
11403 2018-02-21 Yao Qi <yao.qi@linaro.org>
11405 * avr-tdep.c (avr_read_pc): Change parameter type to
11407 * gdbarch.sh (read_pc): Likewise.
11408 * gdbarch.c: Re-generated.
11409 * gdbarch.h: Re-generated.
11410 * hppa-tdep.c (hppa_read_pc): Change parameter type to
11412 * ia64-tdep.c (ia64_read_pc): Likewise.
11413 * mips-tdep.c (mips_read_pc): Likewise.
11414 * spu-tdep.c (spu_read_pc): Likewise.
11416 2018-02-21 Yao Qi <yao.qi@linaro.org>
11418 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
11419 * regcache-dump.c: New file.
11420 * regcache.c: Move register_dump to regcache-dump.c.
11421 (maintenance_print_registers): Likewise.
11422 (maintenance_print_raw_registers): Likewise.
11423 (maintenance_print_cooked_registers): Likewise.
11424 (maintenance_print_register_groups): Likewise.
11425 (maintenance_print_remote_registers): Likewise.
11426 (_initialize_regcache): Likewise.
11427 * regcache.h (register_dump): Moved from regcache.c.
11429 2018-02-21 Yao Qi <yao.qi@linaro.org>
11431 * regcache.c (regcache::regcache): Update.
11432 (regcache::invalidate): Move it to detached_regcache::invalidate.
11433 (get_thread_arch_aspace_regcache): Update.
11434 (regcache::raw_update): Update.
11435 (regcache::cooked_read): Remove some code.
11436 (regcache::cooked_read_value): Likewise.
11437 (regcache::raw_write): Remove assert on m_readonly_p.
11438 (regcache::raw_supply_integer): Move it to
11439 detached_regcache::raw_supply_integer.
11440 (regcache::raw_supply_zeroed): Likewise.
11441 * regcache.h (detached_regcache) <raw_supply_integer>: New
11443 <raw_supply_zeroed, invalidate>: Likewise.
11444 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
11445 <invalidate>: Likewise.
11446 <m_readonly_p>: Removed.
11448 2018-02-21 Yao Qi <yao.qi@linaro.org>
11450 * infcmd.c (get_return_value): Let stop_regs point to
11451 get_current_regcache.
11452 * regcache.c (regcache::regcache): Remove.
11453 (register_dump_reg_buffer): New class.
11454 (regcache_print): Adjust.
11455 * regcache.h (regcache): Remove constructors.
11457 2018-02-21 Yao Qi <yao.qi@linaro.org>
11459 * regcache.c (class register_dump): New class.
11460 (register_dump_regcache, register_dump_none): New class.
11461 (register_dump_remote, register_dump_groups): New class.
11462 (regcache_print): Update.
11463 * regcache.h (regcache_dump_what): Move it to regcache.c.
11464 (regcache) <dump>: Remove.
11466 2018-02-21 Yao Qi <yao.qi@linaro.org>
11468 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
11470 (jit_unwind_reg_set_impl): Call raw_supply.
11471 (jit_frame_sniffer): Use reg_buffer_rw.
11472 * record-full.c (record_full_core_regbuf): Change its type.
11473 (record_full_core_open_1): Use reg_buffer_rw.
11474 (record_full_close): Likewise.
11475 (record_full_core_fetch_registers): Use regcache->raw_supply.
11476 (record_full_core_store_registers): Likewise.
11477 * regcache.c (regcache::get_register_status): Move it to
11479 (regcache_raw_set_cached_value): Remove.
11480 (regcache::raw_set_cached_value): Remove.
11481 (regcache::raw_write): Call raw_supply.
11482 (regcache::raw_supply): Move it to reg_buffer_rw.
11483 * regcache.h (regcache_raw_set_cached_value): Remove.
11484 (reg_buffer_rw): New class.
11486 2018-02-21 Yao Qi <yao.qi@linaro.org>
11488 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
11489 readonly_detached_regcache.
11490 (dummy_frame_prev_register): Use regcache->cooked_read.
11491 * frame.c (frame_save_as_regcache): Change return type.
11492 (frame_pop): Update.
11493 * frame.h (frame_save_as_regcache): Update declaration.
11494 * inferior.h (get_infcall_suspend_state_regcache): Update
11496 * infrun.c (infcall_suspend_state) <registers>: use
11497 readonly_detached_regcache.
11498 (save_infcall_suspend_state): Don't use regcache_dup.
11499 (get_infcall_suspend_state_regcache): Change return type.
11500 * linux-fork.c (struct fork_info) <savedregs>: Change to
11501 readonly_detached_regcache.
11503 (fork_save_infrun_state): Don't use regcache_dup.
11504 (info_checkpoints_command): Adjust.
11505 * mi/mi-main.c (register_changed_p): Update declaration.
11506 (mi_cmd_data_list_changed_registers): Use
11507 readonly_detached_regcache.
11508 (register_changed_p): Change parameter type to
11509 readonly_detached_regcache.
11510 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
11511 readonly_detached_regcache.
11512 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
11513 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
11515 (regcache::save): Move it to reg_buffer.
11516 (regcache::restore): Change parameter type.
11517 (regcache_dup): Remove.
11518 * regcache.h (reg_buffer) <save>: New method.
11519 (readonly_detached_regcache): New class.
11520 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
11521 readonly_detached_regcache.
11522 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
11524 2018-02-21 Yao Qi <yao.qi@linaro.org>
11526 * frame.c (frame_save_as_regcache): Use regcache method save.
11527 (frame_pop): Use regcache method restore.
11528 * infrun.c (restore_infcall_suspend_state): Likewise.
11529 * linux-fork.c (fork_load_infrun_state): Likewise.
11530 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
11532 * regcache.c (regcache_save): Remove.
11533 (regcache::restore): More asserts.
11534 (regcache_cpy): Remove.
11535 * regcache.h (regcache_save): Remove the declaration.
11536 (regcache::restore): Move from private to public.
11537 Remove the friend declaration of regcache_cpy.
11538 (regcache_cpy): Remove declaration.
11540 2018-02-21 Yao Qi <yao.qi@linaro.org>
11542 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
11543 parameter type to 'readable_regcache *'.
11544 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
11545 * arm-tdep.c (arm_neon_quad_read): Likewise.
11546 (arm_pseudo_read): Likewise.
11547 * avr-tdep.c (avr_pseudo_register_read): Likewise.
11548 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
11549 * frv-tdep.c (frv_pseudo_register_read): Likewise.
11550 * gdbarch.c: Re-generated.
11551 * gdbarch.h: Re-generated.
11552 * gdbarch.sh (pseudo_register_read): Change parameter type to
11553 'readable_regcache *'.
11554 (pseudo_register_read_value): Likewise.
11555 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
11556 (h8300_pseudo_register_read): Likewise.
11557 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
11558 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
11559 (i386_pseudo_register_read_into_value): Likewise.
11560 (i386_pseudo_register_read_value): Likewise.
11561 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
11563 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
11564 * m32c-tdep.c (m32c_raw_read): Likewise.
11565 (m32c_read_flg): Likewise.
11566 (m32c_banked_register): Likewise.
11567 (m32c_banked_read): Likewise.
11568 (m32c_sb_read): Likewise.
11569 (m32c_part_read): Likewise.
11570 (m32c_cat_read): Likewise.
11571 (m32c_r3r2r1r0_read): Likewise.
11572 (m32c_pseudo_register_read): Likewise.
11573 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
11574 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
11575 (mep_pseudo_cr64_read): Likewise.
11576 (mep_pseudo_register_read): Likewise.
11577 * mips-tdep.c (mips_pseudo_register_read): Likewise.
11578 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
11579 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
11580 * regcache.c (regcache::raw_read): Move it to readable_regcache.
11581 (regcache::cooked_read): Likewise.
11582 (regcache::cooked_read_value): Likewise.
11583 (regcache_cooked_read_signed):
11584 (regcache::cooked_read): Likewise.
11585 * regcache.h (readable_regcache): New class.
11586 (regcache): Inherit readable_regcache. Move some methods to
11588 * rl78-tdep.c (rl78_pseudo_register_read): Change
11589 parameter type to 'readable_regcache *'.
11590 * rs6000-tdep.c (do_regcache_raw_read): Remove.
11591 (e500_pseudo_register_read): Change parameter type to
11592 'readable_regcache *'.
11593 (dfp_pseudo_register_read): Likewise.
11594 (vsx_pseudo_register_read): Likewise.
11595 (efpr_pseudo_register_read): Likewise.
11596 * s390-tdep.c (s390_pseudo_register_read): Likewise.
11597 * sh-tdep.c (sh_pseudo_register_read): Likewise.
11598 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
11599 (sh64_pseudo_register_read): Likewise.
11600 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
11601 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
11602 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
11603 (spu_pseudo_register_read): Likewise.
11604 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
11605 (xtensa_pseudo_register_read): Likewise.
11607 2018-02-21 Yao Qi <yao.qi@linaro.org>
11609 * regcache.c (regcache::regcache): Call reg_buffer ctor.
11610 (regcache::arch): Move it to reg_buffer::arch.
11611 (regcache::register_buffer): Likewise.
11612 (regcache::assert_regnum): Likewise.
11613 (regcache::num_raw_registers): Likewise.
11614 * regcache.h (reg_buffer): New class.
11615 (regcache): Inherit reg_buffer.
11617 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
11619 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
11620 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
11622 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
11624 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
11626 2018-02-19 Alan Hayward <alan.hayward@arm.com>
11628 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
11629 (SFILES): Remove common/*.c files.
11630 (COMMON_OBS): Remove some *.o files built from common/*.c files.
11631 * common/common.host: Add common reference.
11632 * configure.ac: Likewise.
11633 * configure: Regenerate.
11635 2018-02-16 Yao Qi <yao.qi@linaro.org>
11637 * block.c (block_namespace_info): Inherit allocate_on_obstack.
11638 (block_initialize_namespace): Use new.
11639 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
11640 (dwarf2_free_objfile): Use delete.
11641 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
11642 (copy_type_recursive): Use new.
11643 * gdb_obstack.h (allocate_on_obstack): New.
11645 2018-02-15 Yao Qi <yao.qi@linaro.org>
11648 * inferior.c (exit_inferior_1): Reset inf->control.
11650 2018-02-15 Joel Brobecker <brobecker@adacore.com>
11652 * ada-lang.c (ada_to_fixed_value_create): Delete advance
11655 2018-02-14 Pedro Alves <palves@redhat.com>
11657 * frame-unwind.c (frame_unwind_try_unwinder): Always call
11658 frame_cleanup_after_sniffer on exception.
11660 2018-02-14 Tom Tromey <tom@tromey.com>
11662 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
11664 (solib_bfd_open): Make pathname const.
11665 * solib.c (solib_bfd_open): Make pathname const.
11666 * solib-spu.c (spu_bfd_fopen): Make name const.
11667 (spu_bfd_open): Make pathname const.
11668 * solib-darwin.c (darwin_bfd_open): Make pathname const.
11669 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
11671 2018-02-14 Tom Tromey <tom@tromey.com>
11673 * symfile.c (symfile_bfd_open): Update.
11674 * source.h (openp, source_full_path_of, find_and_open_source):
11675 Change argument type to unique_xmalloc_ptr.
11676 * source.c (openp): Take a unique_xmalloc_ptr.
11677 (source_full_path_of, find_and_open_source): Likewise.
11678 (open_source_file, symtab_to_fullname): Update.
11679 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
11680 unique_xmalloc_ptr.
11681 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
11682 (exec_file_find): Update.
11683 * psymtab.c (psymtab_to_fullname): Update.
11684 * nto-tdep.h (nto_find_and_open_solib): Update.
11685 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
11686 unique_xmalloc_ptr.
11687 * exec.c (exec_file_attach): Update.
11688 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
11689 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
11691 2018-02-14 Tom Tromey <tom@tromey.com>
11693 * solib.c: Include source.h.
11694 * nto-tdep.c: Include source.h.
11695 * mi/mi-cmd-env.c: Include source.h.
11696 * infcmd.c: Include source.h.
11697 * exec.c: Include source.h.
11698 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
11699 (add_path, directory_switch, source_path, init_source_path): Move
11701 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
11702 (add_path, directory_switch, source_path, init_source_path):
11705 2018-02-14 Tom Tromey <tom@tromey.com>
11707 * solist.h (exec_file_find, solib_find): Return
11708 unique_xmalloc_ptr.
11709 (solib_bfd_fopen): Take a const char *.
11710 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
11711 (exec_file_find, solib_find): Likewise.
11712 (solib_bfd_fopen): Do not take ownership of "pathname".
11713 (solib_bfd_open): Use unique_xmalloc_ptr.
11714 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
11715 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
11716 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
11717 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
11719 2018-02-14 Joel Brobecker <brobecker@adacore.com>
11721 * ada-lang.c (name_match_type_from_name): Remove reference to
11722 ada_name_for_lookup in function's documentation.
11723 * ada-lang.h (ada_name_for_lookup): Delete declaration.
11725 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
11727 * defs.h (enum openp_flags): New enum.
11728 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
11729 Move to enum openp_flags.
11730 (openp_flags): New enum flags.
11731 (openp): Change parameter type to openp_flags.
11732 * source.c (openp): Change parameter type to openp_flags.
11733 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
11734 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
11736 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
11738 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
11741 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
11743 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
11745 (class dwarf2_queue_guard): ...the destructor of this new class.
11746 (dw2_do_instantiate_symtab): Create instance of the new class
11747 dwarf2_queue_guard, remove cleanup.
11749 2018-02-09 Tom Tromey <tom@tromey.com>
11751 * source.c (find_source_lines): Don't reference past the end of
11754 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11756 * remote.c (remote_btrace_maybe_reopen): Change error message.
11757 * btrace.c (btrace_enable): Likewise.
11758 (parse_xml_btrace): Likewise.
11759 (parse_xml_btrace_conf): Likewise.
11761 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11763 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
11764 (linux_enable_pt, linux_enable_bts): Call
11765 diagnose_perf_event_open_fail.
11767 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11769 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
11770 Remove parameter and change return type. Update callers. Move it.
11771 (linux_enable_bts, linux_enable_pt): Improve error message.
11772 (linux_enable_pt): Remove zero buffer size check.
11773 (linux_enable_btrace): Improve error messages. Remove NULL return
11776 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11778 * btrace.c (btrace_enable): Remove target_supports_btrace call.
11779 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
11780 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
11781 (linux_supports_pt, linux_supports_btrace): Remove.
11782 (linux_enable_bts): Call cpu_supports_bts.
11783 * nat/linux-btrace.h (linux_supports_btrace): Remove.
11784 * remote.c (remote_supports_btrace): Remove.
11785 (init_remote_ops): Remove remote_supports_btrace.
11786 * target-delegates.c: Regenerated.
11787 * target.c (target_supports_btrace): Remove.
11788 * target.h (target_ops) <to_supports_btrace>: Remove
11789 (target_supports_btrace): Remove.
11790 * x86-linux-nat.c (x86_linux_create_target): Remove
11791 linux_supports_btrace.
11793 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11795 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
11797 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
11798 exception and use message in own exception.
11800 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11802 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
11803 (perf_event_pt_event_type): Use gdb_file_up.
11804 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
11805 scoped_fd, and scoped_mmap.
11807 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11809 * common/scoped_mmap.h: New.
11810 * unittests/scoped_mmap-selftest.c: New.
11811 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11812 unittests/scoped_mmap-selftest.c.
11814 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11816 * common/scoped_fd.h: New.
11817 * unittests/scoped_fd-selftest.c: New.
11818 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11819 unittests/scoped_fd-selftest.c.
11821 2018-02-09 Tom Tromey <tom@tromey.com>
11823 * auto-load.c (auto_load_section_scripts): Use
11824 gdb::unique_xmalloc_ptr.
11826 2018-02-09 Tom Tromey <tom@tromey.com>
11828 * auto-load.c (execute_script_contents): Use std::string.
11830 2018-02-09 Joel Brobecker <brobecker@adacore.com>
11832 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
11833 Python function, rather than a new command.
11835 2018-02-08 Tom Tromey <tom@tromey.com>
11837 * solib.c (solib_find_1): Use std::string.
11838 (solib_bfd_fopen): Use unique_xmalloc_ptr.
11840 2018-02-08 Tom Tromey <tom@tromey.com>
11842 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
11844 2018-02-08 Tom Tromey <tom@tromey.com>
11846 * source.c (find_source_lines): Use gdb::def_vector.
11848 2018-02-08 Tom Tromey <tom@tromey.com>
11850 * macrocmd.c (struct temporary_macro_definition): New.
11851 (macro_define_command): Use temporary_macro_definition. Remove
11853 (free_macro_definition_ptr): Remove.
11855 2018-02-08 Tom Tromey <tom@tromey.com>
11857 * macroexp.c (maybe_expand): Use std::string.
11859 2018-02-08 Tom Tromey <tom@tromey.com>
11861 * macroexp.c (struct macro_buffer): Add initializers for some
11863 (init_buffer, init_shared_buffer, free_buffer)
11864 (free_buffer_return_text): Remove.
11865 (macro_buffer): New constructors.
11866 (~macro_buffer): New destructor.
11867 (macro_buffer::set_shared): New method.
11868 (macro_buffer::resize_buffer, macro_buffer::appendc)
11869 (macro_buffer::appendmem): Now methods, not free functions.
11870 (set_token, append_tokens_without_splicing, stringify)
11871 (macro_stringify): Update.
11872 (gather_arguments): Change return type. Remove argc_p argument,
11873 add args_ptr argument. Use std::vector.
11874 (substitute_args): Remove argc argument. Accept std::vector.
11875 (expand): Update. Use std::vector.
11876 (scan, macro_expand, macro_expand_next): Update.
11878 2018-02-08 Tom Tromey <tom@tromey.com>
11880 * symtab.c (default_collect_symbol_completion_matches_break_on):
11881 Use unique_xmalloc_ptr.
11882 * macroscope.h: (sal_macro_scope, user_macro_scope)
11883 (default_macro_scope): Return unique_xmalloc_ptr.
11884 * macroscope.c (sal_macro_scope, user_macro_scope)
11885 (default_macro_scope): Return unique_xmalloc_ptr.
11886 * macroexp.h (macro_expand, macro_expand_once): Return
11887 unique_xmalloc_ptr.
11888 * macroexp.c (macro_expand, macro_expand_once): Return
11889 unique_xmalloc_ptr.
11890 * macrocmd.c (macro_expand_command, macro_expand_once_command)
11891 (info_macro_command, info_macros_command): Use
11892 unique_xmalloc_ptr.
11893 * compile/compile-c-support.c (write_macro_definitions): Use
11894 unique_xmalloc_ptr.
11895 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
11897 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
11899 * value.c (value_static_field): Assign field type instead of
11900 containing type when returning an optimized out value.
11902 2018-02-06 Yao Qi <yao.qi@linaro.org>
11904 * ft32-tdep.c (ft32_read_pc): Remove.
11905 (ft32_write_pc): Remove.
11906 (ft32_gdbarch_init): Update.
11907 * m32r-tdep.c (m32r_read_pc): Remove.
11908 (m32r_gdbarch_init): Update.
11909 * mep-tdep.c (mep_read_pc): Remove.
11910 (mep_gdbarch_init): Update.
11911 * microblaze-tdep.c (microblaze_write_pc): Remove.
11912 (microblaze_gdbarch_init): Update.
11913 * mn10300-tdep.c (mn10300_read_pc): Remove.
11914 (mn10300_write_pc): Remove.
11915 (mn10300_gdbarch_init): Update.
11916 * moxie-tdep.c (moxie_read_pc): Remove.
11917 (moxie_write_pc): Remove.
11918 (moxie_gdbarch_init): Update.
11920 2018-02-06 Yao Qi <yao.qi@linaro.org>
11922 * expprint.c (print_subexp_standard): Handle
11923 OP_F77_UNDETERMINED_ARGLIST.
11924 (dump_subexp_body_standard): Likewise.
11926 2018-02-05 Alan Hayward <alan.hayward@arm.com>
11928 * target-descriptions.c (tdesc_element_visitor) Add empty
11930 (tdesc_type): Move make_gdb_type from here.
11931 (tdesc_type_builtin): Likewise.
11932 (tdesc_type_vector): Likewise.
11933 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
11934 (make_gdb_type_struct): Move from tdesc_type_with_fields.
11935 (make_gdb_type_union): Likewise.
11936 (make_gdb_type_flags): Likewise.
11937 (make_gdb_type_enum): Likewise.
11938 (make_gdb_type): New function.
11939 (tdesc_register_type): Use static make_gdb_type.
11941 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
11943 * infcmd.c (default_print_one_register_info): Align natural-format
11944 column values consistently one under another.
11945 (pad_to_column): New function.
11947 2018-02-05 Joel Brobecker <brobecker@adacore.com>
11949 * dwarf2read.c (dwarf2_physname): Move commment.
11951 2018-02-01 Leszek Swirski <leszeks@google.com>
11953 * varobj.c (varobj_formatted_print_options): Allow recursive
11954 pretty printing if pretty printing is enabled.
11956 2018-02-01 Leszek Swirski <leszeks@google.com>
11958 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
11959 names after a structop as a filename.
11961 2018-02-01 Yao Qi <yao.qi@linaro.org>
11963 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
11964 (arm_record_coproc_data_proc): Likewise.
11966 2018-02-01 Yao Qi <yao.qi@linaro.org>
11968 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
11970 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
11972 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
11973 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
11975 2018-01-31 Pedro Alves <palves@redhat.com>
11977 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
11978 * inflow.c (child_terminal_save_inferior): Wrap reference to
11979 tcgetpgrp in HAVE_TERMIOS_H.
11980 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
11982 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
11983 always iterate over all inferiors.
11984 (gdbsim_cntrl_c): Adjust.
11985 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
11987 2018-01-31 Joel Brobecker <brobecker@adacore.com>
11989 * gdbtypes.c (lookup_array_range_type): Make sure the array's
11990 index type is objfile-owned if the element type is as well.
11992 2018-01-31 Joel Brobecker <brobecker@adacore.com>
11996 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
11998 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
11999 "features/s390x-linux64.c".
12000 (_initialize_s390_linux_tdep): Remove initialization of tdescs
12001 s390_linux32 and s390x_linux64.
12002 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
12004 * s390-tdep.c: Include "features/s390-linux32.c" and
12005 "features/s390x-linux64.c".
12006 (s390_tdesc_valid): Add check for tdesc_has_registers.
12007 (s390_gdbarch_init): Make sure there is always a valid tdesc.
12008 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
12009 tdesc_s390x_linux64.
12010 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
12011 tdesc_s390x_linux64 to...
12012 * s390-tdep.h: ...here.
12014 2018-01-30 Pedro Alves <palves@redhat.com>
12017 * config.in, configure: Regenerate.
12018 * configure.ac: Check for getpgid.
12019 * go32-nat.c (go32_pass_ctrlc): New.
12020 (go32_target): Install it.
12021 * inf-child.c (inf_child_target): Install
12022 child_terminal_save_inferior, child_pass_ctrlc and
12024 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
12025 (inf_ptrace_target): No longer install it.
12026 * infcmd.c (interrupt_target_1): Adjust.
12027 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
12028 (child_interrupt): Declare.
12029 (inferior::terminal_state): New.
12030 * inflow.c (struct terminal_info): Update comments.
12031 (inferior_process_group): Delete.
12032 (terminal_is_ours): Delete.
12033 (gdb_tty_state): New.
12034 (child_terminal_init): Adjust.
12035 (is_gdb_terminal, sharing_input_terminal_1)
12036 (sharing_input_terminal): New functions.
12037 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
12038 Set the process's actual process group in the foreground if
12039 possible. Handle is_ours_for_output/is_ours distinction. Don't
12040 mark terminal as the inferior's if not sharing GDB's terminal.
12041 Don't check attach_flag.
12042 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
12043 pass down a target_terminal_state.
12044 (child_terminal_save_inferior): New, factored out from ...
12045 (child_terminal_ours_1): ... this. Handle
12046 target_terminal_state::is_ours_for_output.
12047 (child_interrupt, child_pass_ctrlc): New.
12048 (inflow_inferior_exit): Clear the inferior's terminal_state.
12049 (copy_terminal_info): Copy the inferior's terminal state.
12050 (_initialize_inflow): Remove reference to terminal_is_ours.
12051 * inflow.h (inferior_process_group): Delete.
12052 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
12053 * procfs.c (procfs_target): Don't install procfs_interrupt.
12054 (procfs_interrupt): Delete.
12055 * remote.c (remote_serial_quit_handler): Adjust.
12056 (remote_interrupt): Remove ptid parameter. Adjust.
12057 * target-delegates.c: Regenerate.
12058 * target.c: Include "terminal.h".
12059 (target_terminal::terminal_state): Rename to ...
12060 (target_terminal::m_terminal_state): ... this.
12061 (target_terminal::init): Adjust.
12062 (target_terminal::inferior): Adjust to per-inferior
12064 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
12065 (target_terminal::ours, target_terminal::ours_for_output): Use
12066 target_terminal_is_ours_kind.
12067 (target_interrupt): Remove ptid parameter. Adjust.
12068 (default_target_pass_ctrlc): Adjust.
12069 * target.h (target_ops::to_terminal_save_inferior): New field.
12070 (target_ops::to_interrupt): Remove ptid_t parameter.
12071 (target_interrupt): Remove ptid_t parameter. Update comment.
12072 (target_pass_ctrlc): Update comment.
12073 * target/target.h (target_terminal_state): New scoped enum,
12074 factored out of ...
12075 (target_terminal::terminal_state): ... here.
12076 (target_terminal::inferior): Update comments.
12077 (target_terminal::restore_inferior): New.
12078 (target_terminal::is_inferior, target_terminal::is_ours)
12079 (target_terminal::is_ours_for_output): Adjust.
12080 (target_terminal::scoped_restore_terminal_state): Adjust to
12081 rename, and call restore_inferior() instead of inferior().
12082 (target_terminal::scoped_restore_terminal_state::m_state): Change
12084 (target_terminal::terminal_state): Rename to ...
12085 (target_terminal::m_terminal_state): ... this and change type.
12087 2018-01-30 Pedro Alves <palves@redhat.com>
12089 * linux-nat.c (wait_for_signal): New function.
12090 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
12092 (async_terminal_is_ours)
12093 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
12094 (linux_nat_add_target): Don't override
12095 to_terminal_inferior/to_terminal_ours.
12097 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
12099 * remote.c (remote_follow_fork): Don't call "detach_inferior".
12101 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
12103 * dwarf2read.c (free_dwo_files): Add forward-declaration.
12104 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
12105 dwarf2_per_objfile_free here.
12106 (dwarf2_per_objfile_free): Remove.
12107 (_initialize_dwarf2_read): Don't register
12108 dwarf2_per_objfile_free as a registry cleanup.
12110 2018-01-27 Eli Zaretskii <eliz@gnu.org>
12112 Avoid compilation errors in MinGW native builds
12114 The error is triggered by including python-internal.h, and the
12117 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
12118 from build-gnulib/import/math.h:27,
12119 from d:/usr/Python26/include/pyport.h:235,
12120 from d:/usr/Python26/include/Python.h:58,
12121 from python/python-internal.h:94,
12122 from python/py-arch.c:24:
12123 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
12127 This happens because Python headers define 'hypot' to expand t
12128 '_hypot' in the Windows builds.
12129 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
12130 'hypoth'. This avoids a compilation error.
12132 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12134 * MAINTAINERS (Write After Approval): Fix ordering.
12136 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12138 * MAINTAINERS (Write After Approval): Add Alan Hayward.
12140 2018-01-26 Alan Modra <amodra@gmail.com>
12142 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
12143 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
12144 Remove nop. Make const. Comment.
12145 (powerpc32_plt_stub_so_2): New.
12146 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
12147 Correct count. Update uses.
12148 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
12149 Move common code reading PLT entry word. Correct
12150 powerpc32_plt_stub PLT address calculation.
12151 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
12152 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
12153 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
12154 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
12155 (ppc64_standard_linkage8): Likewise.
12156 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
12157 Correct insns description.
12158 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
12160 2018-01-24 Pedro Alves <palves@redhat.com>
12162 GCC PR libstdc++/83906
12163 * gdbtypes.c (operator==(const dynamic_prop &,
12164 const dynamic_prop &)): New.
12165 (operator==(const range_bounds &, const range_bounds &)): New.
12166 (check_types_equal): Use them instead of memcmp.
12167 * gdbtypes.h (operator==(const dynamic_prop &,
12168 const dynamic_prop &)): Declare.
12169 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
12170 (operator==(const range_bounds &, const range_bounds &)): Declare.
12171 (operator!=(const range_bounds &, const range_bounds &)): Declare.
12173 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12175 * s390-linux-tdep.c (s390_record_address_mask)
12176 (s390_record_calc_disp_common, s390_record_calc_disp)
12177 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12178 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12179 (s390_process_record): Move to s390-tdep.c.
12180 (s390_linux_init_abi_any): Adjust.
12181 * s390-tdep.c (s390_record_address_mask)
12182 (s390_record_calc_disp_common, s390_record_calc_disp)
12183 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12184 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12185 (s390_process_record): Moved from s390-linux-tdep.c
12186 (s390_gdbarch_init): Adjust.
12188 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12190 * s390-linux-nat.c (s390-tdep.h): New include.
12191 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
12192 (HFILES_NO_SRCDIR): Add s390-tdep.h.
12193 (ALLDEPFILES): Add s390-tdep.c.
12194 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
12195 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
12196 * s390-tdep.h: ...this. New file.
12197 * s390-linux-tdep.c (s390-tdep.h): New include.
12198 (_initialize_s390_tdep): Rename to...
12199 (_initialize_s390_linux_tdep): ...this and adjust.
12200 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
12201 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
12203 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
12204 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
12205 (s390_is_partial_instruction, s390_software_single_step)
12206 (is_non_branch_ril, s390_displaced_step_copy_insn)
12207 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
12208 (s390_prologue_data, s390_addr, s390_store, s390_load)
12209 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
12210 (s390_register_call_saved, s390_guess_tracepoint_registers)
12211 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
12212 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
12213 (s390_pseudo_register_name, s390_pseudo_register_type)
12214 (s390_pseudo_register_read, s390_pseudo_register_write)
12215 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
12216 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
12217 (s390_addr_bits_remove, s390_address_class_type_flags)
12218 (s390_address_class_type_flags_to_name)
12219 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
12220 (s390_function_arg_float, s390_function_arg_vector)
12221 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
12222 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
12223 (s390_frame_align, s390_register_return_value, s390_return_value)
12224 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
12225 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
12226 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
12227 (s390_trad_frame_prev_register, s390_unwind_cache)
12228 (s390_prologue_frame_unwind_cache)
12229 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
12230 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
12231 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
12232 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
12233 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
12234 (s390_frame_base_address, s390_local_base_address)
12235 (s390_frame_base, s390_gcc_target_options)
12236 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
12237 (s390_validate_reg_range, s390_tdesc_valid)
12238 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
12239 * s390-tdep.c: ...this. New file.
12241 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12243 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
12244 (s390_process_record, s390_gdbarch_tdep_alloc)
12245 (s390_linux_init_abi_any): Use/set new hook.
12247 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12249 * s390-linux-tdep.c (osabi.h): New include.
12250 (s390_linux_init_abi_31, s390_linux_init_abi_64)
12251 (s390_linux_init_abi_any): New functions.
12252 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
12254 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12256 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
12257 tdesc_has_registers check
12259 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12261 * s390-linux-tdep.c (s390_tdesc_valid): New function.
12262 (s390_validate_reg_range): New macro.
12263 (s390_gdbarch_init): Adjust.
12265 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12267 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
12268 (s390_gdbarch_tdep_alloc): Adjust.
12269 (s390_gdbarch_init): Adjust.
12271 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12273 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
12274 <have_tdb>: Change type to bool.
12275 (s390_gdbarch_tdep_alloc): Adjust.
12276 (s390_gdbarch_init): Adjust.
12278 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12280 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
12281 (gdbarch_tdep) <have_upper, have_vx>: New fields.
12282 (s390_gdbarch_tdep_alloc): New function.
12283 (s390_gdbarch_init): Allocate tdep at start and use its fields
12284 instead of separate variables.
12286 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12288 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
12289 when looking for cached gdbarch and add comment for remaining.
12291 2018-01-22 Pedro Alves <palves@redhat.com>
12292 Sergio Durigan Junior <sergiodj@redhat.com>
12294 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
12297 2018-01-22 Maciej W. Rozycki <macro@mips.com>
12299 * MAINTAINERS: Update my company e-mail address.
12301 2018-01-22 Yao Qi <yao.qi@linaro.org>
12303 * regcache.c (cooked_write_test): New function.
12304 (_initialize_regcache): Register the test.
12306 2018-01-22 Yao Qi <yao.qi@linaro.org>
12308 * ia64-tdep.c (ia64_pseudo_register_read): Call
12309 regcache->cooked_read instead of regcache_cooked_read_unsigned.
12310 * m32c-tdep.c (m32c_cat_read): Likewise.
12311 (m32c_r3r2r1r0_read): Likewise.
12312 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
12313 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
12315 2018-01-22 Yao Qi <yao.qi@linaro.org>
12317 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
12318 method raw_read instead of regcache_raw_read.
12319 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
12320 * arm-tdep.c (arm_neon_quad_read): Likewise.
12321 * avr-tdep.c (avr_pseudo_register_read): Likewise.
12322 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
12323 * frv-tdep.c (frv_pseudo_register_read): Likewise.
12324 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
12325 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
12326 (i386_pseudo_register_read_into_value): Likewise.
12327 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
12328 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
12329 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
12330 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
12331 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
12332 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
12333 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
12334 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
12335 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
12337 2018-01-22 Yao Qi <yao.qi@linaro.org>
12339 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
12340 * configure.tgt: Remove target mt.
12341 * mt-tdep.c: Remove.
12342 * regcache.c (cooked_read_test): Remove the check for mt.
12344 2018-01-22 Yao Qi <yao.qi@linaro.org>
12346 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
12347 instead of gdbarch_pseudo_register_read_value.
12349 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12351 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
12354 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12356 * linespec.c (create_sals_line_offset): Remove code that preserved
12357 the symtab_and_line's line number.
12359 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12361 * varobj.c (varobj_create): Don't set valid_block when creating a
12364 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12366 * varobj.c (varobj_create): Remove out of date comment.
12368 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12371 * ada-exp.y (write_var_from_sym): Pass extra parameter when
12372 updating innermost block.
12373 * parse.c (innermost_block_tracker::update): Take extra type
12374 parameter, and check types match before updating innermost block.
12375 (write_dollar_variable): Update innermost block for registers.
12376 * parser-defs.h (enum innermost_block_tracker_type): New enum.
12377 (innermost_block_tracker::innermost_block_tracker): Initialise
12379 (innermost_block_tracker::reset): Take type parameter.
12380 (innermost_block_tracker::update): Take type parameter, and pass
12381 type through as needed.
12382 (innermost_block_tracker::m_types): New member.
12383 * varobj.c (varobj_create): Pass type when reseting innermost
12386 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12388 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
12389 * ada-lang.c (resolve_subexp): Likewise.
12390 * breakpoint.c (set_breakpoint_condition) Likewise.
12391 (watch_command_1) Likewise.
12392 * c-exp.y (variable): Likewise.
12393 * d-exp.y (PrimaryExpression): Likewise.
12394 * f-exp.y (variable): Likewise.
12395 * go-exp.y (variable): Likewise.
12396 * m2-exp.y (variable): Likewise.
12397 * objfiles.c (objfile::~objfile): Likewise.
12398 * p-exp.y (variable): Likewise.
12399 * parse.c (innermost_block): Change type.
12400 * parser-defs.h (class innermost_block_tracker): New.
12401 (innermost_block): Change to innermost_block_tracker.
12402 * printcmd.c (display_command): Switch to innermost_block API.
12403 (do_one_display): Likewise.
12404 * rust-exp.y (do_one_display): Likewise.
12405 * symfile.c (clear_symtab_users): Likewise.
12406 * varobj.c (varobj_create): Switch to innermost_block API, replace
12407 use of innermost_block with block stored on varobj object.
12409 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12411 * expression.h (innermost_block): Remove declaration.
12412 * varobj.c: Add 'parser-defs.h' include.
12414 2018-01-19 Tom Tromey <tom@tromey.com>
12416 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
12417 symbols in the static and global blocks.
12419 2018-01-19 James Clarke <jrtc27@jrtc27.com>
12421 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
12422 gdb_ptrace.h, and move including gdb_wait.h ...
12423 * nat/linux-ptrace.h: ... to here.
12425 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12427 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
12428 inf_ptrace_detach_success.
12429 (inf_ptrace_detach_success): Add inferior parameter, use it
12430 instead of inferior_ptid, pass it to detach_inferior.
12431 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
12433 * inferior.c (detach_inferior): Add overload that takes an
12435 * inferior.h (detach_inferior): Likewise.
12436 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
12437 use inferior_ptid, adjust call to inf_ptrace_detach_success.
12438 * linux-thread-db.c (thread_db_detach): Use inf parameter.
12440 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12442 * target.h (struct target_ops) <to_detach>: Add inferior
12444 (target_detach): Likewise.
12445 * target.c (dispose_inferior): Pass inferior down.
12446 (target_detach): Pass inferior down. Assert that it is equal to
12447 the current inferior.
12448 * aix-thread.c (aix_thread_detach): Pass inferior down.
12449 * corefile.c (core_file_command): Pass current_inferior() down.
12450 * corelow.c (core_detach): Add inferior parameter.
12451 * darwin-nat.c (darwin_detach): Likewise.
12452 * gnu-nat.c (gnu_detach): Likewise.
12453 * inf-ptrace.c (inf_ptrace_detach): Likewise.
12454 * infcmd.c (detach_command): Pass current_inferior() down to
12456 * infrun.c (follow_fork_inferior): Pass parent_inf to
12458 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
12460 * linux-nat.c (linux_nat_detach): Add inferior parameter.
12461 * linux-thread-db.c (thread_db_detach): Likewise.
12462 * nto-procfs.c (procfs_detach): Likewise.
12463 * procfs.c (procfs_detach): Likewise.
12464 * record.c (record_detach): Likewise.
12465 * record.h (struct inferior): Forward-declare.
12466 (record_detach): Add inferior parameter.
12467 * remote-sim.c (gdbsim_detach): Likewise.
12468 * remote.c (remote_detach_1): Likewise.
12469 (remote_detach): Likewise.
12470 (extended_remote_detach): Likewise.
12471 * sol-thread.c (sol_thread_detach): Likewise.
12472 * target-debug.h (target_debug_print_inferior_p): New macro.
12473 * target-delegates.c: Re-generate.
12474 * top.c (kill_or_detach): Pass inferior down to target_detach.
12475 * windows-nat.c (windows_detach): Add inferior parameter.
12477 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12479 * target.h (struct target_ops) <to_detach>: Remove args
12481 (target_detach): Likewise.
12482 * target.c (dispose_inferior): Adjust.
12483 (target_detach): Remove args parameter, adjust.
12484 * aix-thread.c (aix_thread_detach): Adjust.
12485 * corefile.c (core_file_command): Adjust.
12486 * corelow.c (core_detach): Adjust.
12487 * darwin-nat.c (darwin_detach): Adjust.
12488 * gnu-nat.c (gnu_detach): Adjust.
12489 * inf-ptrace.c (inf_ptrace_detach): Adjust.
12490 * infcmd.c (detach_command): Adjust
12491 * infrun.c (follow_fork_inferior): Adjust.
12492 (handle_vfork_child_exec_or_exit): Adjust.
12493 * linux-fork.c (linux_fork_detach): Remove args parameter.
12494 * linux-fork.h (linux_fork_detach): Likewise.
12495 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
12496 * linux-thread-db.c (thread_db_detach): Likewise.
12497 * nto-procfs.c (procfs_detach): Likewise.
12498 * procfs.c (procfs_detach): Likewise.
12499 (do_detach): Remove signo parameter.
12500 * record.c (record_detach): Remove args parameter.
12501 * record.h (record_detach): Likewise.
12502 * remote-sim.c (gdbsim_detach): Likewise.
12503 * remote.c (remote_detach_1): Likewise.
12504 (remote_detach): Likewise.
12505 (extended_remote_detach): Likewise.
12506 * sol-thread.c (sol_thread_detach): Likewise.
12507 * target-delegates.c: Re-generate.
12508 * top.c (struct qt_args) <args>: Remove field.
12509 (kill_or_detach): Don't pass args.
12510 (quit_force): Don't set args.
12511 * windows-nat.c (windows_detach): Remove args parameter.
12513 2018-01-19 Yao Qi <yao.qi@linaro.org>
12515 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
12516 (arm_linux_init_abi): Install it.
12518 2018-01-19 Yao Qi <yao.qi@linaro.org>
12520 * osabi.c (gdb_osabi_names): Extend the regexp for
12521 arm-linux-gnueabihf.
12523 2018-01-18 Yao Qi <yao.qi@linaro.org>
12525 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
12527 (abbrev_table::add_abbrev): Update.
12528 (abbrev_table::lookup_abbrev): Update.
12530 2018-01-18 Yao Qi <yao.qi@linaro.org>
12532 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
12534 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
12536 * compile/compile.c (compile_to_object): Convert "triplet_rx"
12539 2018-01-17 Tom Tromey <tom@tromey.com>
12541 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
12543 2018-01-17 Tom Tromey <tom@tromey.com>
12545 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
12546 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
12547 (create_array_type_with_stride): Update.
12548 * dwarf2read.c (set_die_type): Update.
12550 2018-01-17 Tom Tromey <tom@tromey.com>
12552 * dwarf2read.c (delayed_method_info): Remove typedef.
12553 (dwarf2_cu::method_info): Now a std::vector.
12554 (add_to_method_list): Update.
12555 (free_delayed_list): Remove.
12556 (compute_delayed_physnames): Update.
12557 (process_full_comp_unit, process_full_type_unit): Clear the method
12558 list. Remove cleanups.
12559 (psymtab_include_file_name): Add name_holder parameter. Use
12560 unique_xmalloc_ptr.
12561 (dwarf_decode_lines): Update.
12563 2018-01-17 Tom Tromey <tom@tromey.com>
12564 Simon Marchi <simon.marchi@ericsson.com>
12566 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
12567 (dwarf2_per_objfile::free_cached_comp_units)
12568 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12569 (init_cutu_and_read_dies_no_follow): Update.
12570 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
12571 (dwarf2_cu::~dwarf2_cu): New.
12572 (free_heap_comp_unit, free_stack_comp_unit): Remove.
12573 (age_cached_comp_units, free_one_cached_comp_unit): Update.
12575 2018-01-17 Tom Tromey <tom@tromey.com>
12576 Simon Marchi <simon.marchi@ericsson.com>
12578 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
12579 (struct die_reader_specs) <abbrev_table>: New member.
12580 (struct abbrev_table): Add constructor.
12581 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
12582 <abbrev_obstack>: Now an auto_obstack.
12583 (abbrev_table_up): New typedef.
12584 (init_cu_die_reader): Add abbrev_table parameter.
12585 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
12586 Add result_dwo_abbrev_table.
12587 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12588 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
12590 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
12592 (skip_children): Update.
12593 (abbrev_table::alloc_abbrev): Rename from
12594 abbrev_table_alloc_abbrev.
12595 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
12596 (abbrev_table::lookup_abbrev): Rename from
12597 abbrev_table_lookup_abbrev.
12598 (abbrev_table_read_table): Return abbrev_table_up.
12599 (abbrev_table_free, abbrev_table_free_cleanup)
12600 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
12601 (load_partial_dies): Update.
12603 2018-01-17 Tom Tromey <tom@tromey.com>
12605 * dwarf2read.c (dwarf2_compute_name): Update comment.
12606 (read_func_scope, read_variable): Update.
12607 (new_symbol): Remove.
12608 (new_symbol_full): Rename to new_symbol.
12610 2018-01-17 Mike Gulick <mgulick@mathworks.com>
12613 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
12614 a warning instead of throwing an error, set section size to 0 and return
12616 * gdb_bfd.h (gdb_bfd_map_section): Update description.
12618 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
12620 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
12622 (linux_ptrace_attach_fail_reason_string): Likewise.
12623 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
12625 (linux_ptrace_attach_fail_reason_string): Likewise.
12626 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
12628 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
12630 * linux-nat.c (linux_nat_attach): Remove xstrdup.
12632 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
12635 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
12636 checking for fs_base/gs_base fields in struct user_regs_struct.
12637 * configure: Regenerate.
12639 2018-01-17 Yao Qi <yao.qi@linaro.org>
12641 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
12643 (aarch64_linux_init_abi): Install it to gdbarch hook
12644 gcc_target_options.
12646 2018-01-15 Pedro Alves <palves@redhat.com>
12648 * common/signals-state-save-restore.c
12649 (save_original_signals_state): Fix typos.
12651 2017-01-12 Tom Tromey <tom@tromey.com>
12652 Sergio Durigan Junior <sergiodj@redhat.com>
12654 * Makefile.in (install-only): Install gdb-add-index.
12656 2018-01-12 John Baldwin <jhb@FreeBSD.org>
12658 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
12660 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
12662 * infrun.c (keep_going_pass_signal): Clear step-over info when
12663 insert_breakpoints fails.
12665 2018-01-11 Pedro Alves <palves@redhat.com>
12668 * infrun.c (resume): Rename to ...
12669 (resume_1): ... this.
12670 (resume): Reimplement as wrapper around resume_1.
12672 2018-01-11 Pedro Alves <palves@redhat.com>
12675 * remote.c (remote_parse_stop_reply): Default to the last-set
12676 general thread instead of to 'magic_null_ptid'.
12678 2018-01-10 Pedro Alves <palves@redhat.com>
12680 * language.h (language_get_symbol_name_matcher): Rename ...
12681 (get_symbol_name_matcher): ... this.
12682 * language.c (language_get_symbol_name_matcher): Ditto.
12683 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
12686 2018-01-10 Pedro Alves <palves@redhat.com>
12690 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
12691 Adjust to use language_get_symbol_name_matcher instead of
12692 language_defn::la_get_symbol_name_matcher.
12693 * language.c (language_get_symbol_name_matcher): If in Ada mode
12694 and the lookup name is a verbatim match, return Ada's matcher.
12695 * language.h (language_get_symbol_name_matcher): Adjust comment.
12696 (ada_lookup_name_info::verbatim_p):: New method.
12698 2018-01-10 Pedro Alves <palves@redhat.com>
12701 * ada-lang.c (ada_collect_symbol_completion_matches): If the
12702 minsym's language is language_auto or language_cplus, pass down
12703 language_ada instead.
12704 * symtab.c (compare_symbol_name): Don't frob symbol language here.
12706 2018-01-10 Pedro Alves <palves@redhat.com>
12709 * minsyms.c (linkage_name_str): New function.
12710 (iterate_over_minimal_symbols): Use it.
12712 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12714 * NEWS: Document that 'info proc' now works on FreeBSD.
12716 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12718 * configure.ac: Check for kinfo_getfile in libutil.
12719 * configure: Regenerate.
12720 * config.in: Regenerate.
12721 * fbsd-nat.c: Include "fbsd-tdep.h".
12722 (fbsd_fetch_cmdline): New.
12723 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
12724 rather than calling error.
12725 (fbsd_info_proc): New.
12726 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
12727 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
12728 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
12730 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12732 * fbsd-nat.c (struct free_deleter): Remove.
12733 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
12735 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12737 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
12738 NULL for an empty pathname.
12740 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12742 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
12743 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
12744 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
12745 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
12746 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
12747 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
12748 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
12749 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
12750 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
12751 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
12752 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
12753 (fbsd_core_fetch_timeval, fbsd_print_sigset)
12754 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
12755 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
12756 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
12758 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
12760 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
12761 (gnu_xfer_auxv): New function.
12762 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
12763 TARGET_OBJECT_AUXV.
12765 2018-01-08 Yao Qi <yao.qi@linaro.org>
12766 Simon Marchi <simon.marchi@ericsson.com>
12768 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
12770 (COMMON_OBS): Remove selftest.o.
12771 * configure.ac: Append selftest-arch.c and common/selftest.c to
12772 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
12773 * configure: Re-generated.
12774 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
12776 (maintenance_info_selftests): Likewise.
12778 2018-01-08 Xavier Roirand <roirand@adacore.com>
12780 * ada-valprint.c (val_print_packed_array_elements): Use
12781 proper number of elements when printing an array indexed
12782 by an enumeration type.
12784 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
12786 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
12787 (dw2_get_file_names_reader): Adjust.
12788 (lookup_dwo_signatured_type): Adjust.
12789 (lookup_dwp_signatured_type): Adjust.
12790 (lookup_signatured_type): Adjust.
12791 (create_type_unit_group): Adjust.
12792 (get_type_unit_group): Adjust.
12793 (process_psymtab_comp_unit_reader): Adjust.
12794 (build_type_psymtabs_reader): Adjust.
12795 (scan_partial_symbols): Adjust.
12796 (add_partial_symbol): Adjust.
12797 (add_partial_subprogram): Adjust.
12798 (peek_die_abbrev): Adjust.
12799 (fixup_go_packaging): Adjust.
12800 (process_imported_unit_die): Adjust.
12801 (dwarf2_compute_name): Adjust.
12802 (dwarf2_physname): Adjust.
12803 (read_import_statement): Adjust.
12804 (handle_DW_AT_stmt_list): Adjust.
12805 (read_file_scope): Adjust.
12806 (read_func_scope): Adjust.
12807 (read_lexical_block_scope): Adjust.
12808 (read_call_site_scope): Adjust.
12809 (read_variable): Adjust.
12810 (dwarf2_rnglists_process): Adjust.
12811 (dwarf2_ranges_process): Adjust.
12812 (dwarf2_ranges_read): Adjust.
12813 (dwarf2_get_pc_bounds): Adjust.
12814 (dwarf2_record_block_ranges): Adjust.
12815 (dwarf2_add_field): Adjust.
12816 (dwarf2_add_member_fn): Adjust.
12817 (read_structure_type): Adjust.
12818 (process_structure_scope): Adjust.
12819 (read_enumeration_type): Adjust.
12820 (read_array_type): Adjust.
12821 (mark_common_block_symbol_computed): Adjust.
12822 (read_common_block): Adjust.
12823 (read_namespace_type): Adjust.
12824 (read_namespace): Adjust.
12825 (read_module_type): Adjust.
12826 (read_tag_pointer_type): Adjust.
12827 (read_tag_ptr_to_member_type): Adjust.
12828 (read_tag_string_type): Adjust.
12829 (read_subroutine_type): Adjust.
12830 (read_typedef): Adjust.
12831 (read_base_type): Adjust.
12832 (attr_to_dynamic_prop): Adjust.
12833 (read_subrange_type): Adjust.
12834 (read_unspecified_type): Adjust.
12835 (dwarf2_read_abbrevs): Adjust.
12836 (load_partial_dies): Adjust.
12837 (read_partial_die): Adjust.
12838 (find_partial_die): Adjust.
12839 (guess_partial_die_structure_name): Adjust.
12840 (fixup_partial_die): Adjust.
12841 (read_attribute_value): Adjust.
12842 (read_addr_index): Adjust.
12843 (read_addr_index_from_leb128): Adjust.
12844 (read_str_index): Adjust.
12845 (dwarf2_string_attr): Adjust.
12846 (get_debug_line_section): Adjust.
12847 (dwarf_decode_line_header): Adjust.
12848 (lnp_state_machine::check_line_address): Adjust.
12849 (dwarf_decode_lines_1): Adjust.
12850 (dwarf_decode_lines): Adjust.
12851 (dwarf2_start_symtab): Adjust.
12852 (var_decode_location): Adjust.
12853 (new_symbol_full): Adjust.
12854 (dwarf2_const_value_data): Adjust.
12855 (dwarf2_const_value_attr): Adjust.
12856 (dwarf2_const_value): Adjust.
12857 (die_type): Adjust.
12858 (die_containing_type): Adjust.
12859 (build_error_marker_type): Adjust.
12860 (lookup_die_type): Adjust.
12861 (guess_full_die_structure_name): Adjust.
12862 (anonymous_struct_prefix): Adjust.
12863 (determine_prefix): Adjust.
12864 (dwarf2_name): Adjust.
12865 (follow_die_ref_or_sig): Adjust.
12866 (follow_die_offset): Adjust.
12867 (follow_die_ref): Adjust.
12868 (follow_die_sig_1): Adjust.
12869 (follow_die_sig): Adjust.
12870 (get_signatured_type): Adjust.
12871 (get_DW_AT_signature_type): Adjust.
12872 (decode_locdesc): Adjust.
12873 (dwarf_decode_macros): Adjust.
12874 (cu_debug_loc_section): Adjust.
12875 (fill_in_loclist_baton): Adjust.
12876 (dwarf2_symbol_mark_computed): Adjust.
12877 (init_one_comp_unit): Don't assign
12878 dwarf2_cu::dwarf2_per_objfile.
12879 (set_die_type): Adjust.
12881 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
12883 * dwarf2read.c (struct mapped_debug_names): Add constructor.
12884 <dwarf2_per_objfile>: New field.
12885 (dwarf2_per_objfile): Remove global.
12886 (get_dwarf2_per_objfile): New function.
12887 (set_dwarf2_per_objfile): New function.
12888 (dwarf2_build_psymtabs_hard): Change objfile parameter to
12889 dwarf2_per_objfile.
12890 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
12891 (read_abbrev_offset): Likewise.
12892 (read_indirect_string): Likewise.
12893 (read_indirect_line_string): Likewise.
12894 (read_indirect_string_at_offset): Likewise.
12895 (read_indirect_string_from_dwz): Likewise.
12896 (dwarf2_find_containing_comp_unit): Change objfile parameter to
12897 dwarf2_per_objfile.
12898 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
12899 (create_all_comp_units): Change objfile parameter to
12900 dwarf2_per_objfile.
12901 (create_all_type_units): Likewise.
12902 (process_queue): Add dwarf2_per_objfile parameter.
12903 (read_and_check_comp_unit_head): Likewise.
12904 (lookup_dwo_unit_in_dwp): Likewise.
12905 (get_dwp_file): Likewise.
12906 (process_cu_includes): Likewise.
12907 (struct free_dwo_file_cleanup_data): New struct.
12908 (dwarf2_has_info): Use get_dwarf2_per_objfile and
12909 set_dwarf2_per_objfile.
12910 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
12911 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
12912 context, adjust calls.
12913 (dw2_instantiate_symtab): Likewise.
12914 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
12915 (dw2_get_cu): Likewise.
12916 (create_cu_from_index_list): Change objfile parameter to
12917 dwarf2_per_objfile.
12918 (create_cus_from_index_list): Get dwarf2_per_objfile from
12919 context, adjust calls.
12920 (create_cus_from_index): Likewise.
12921 (create_signatured_type_table_from_index): Change objfile
12922 parameter to dwarf2_per_objfile.
12923 (create_signatured_type_table_from_debug_names): Change objfile
12924 parameter to dwarf2_per_objfile.
12925 (create_addrmap_from_index): Likewise.
12926 (create_addrmap_from_aranges): Likewise.
12927 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
12928 (dw2_setup): Remove.
12929 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
12931 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
12932 get_dwarf2_per_objfile.
12933 (dw2_forget_cached_source_info): Likewise.
12934 (dw2_map_symtabs_matching_filename): Likewise.
12935 (struct dw2_symtab_iterator) <index>: Remove.
12936 <dwarf2_per_objfile>: New field.
12937 (dw2_symtab_iter_init): Replace index parameter with
12938 dwarf2_per_objfile.
12939 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
12940 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
12941 (dw2_print_stats): Likewise.
12942 (dw2_dump): Likewise.
12943 (dw2_expand_symtabs_for_function): Likewise.
12944 (dw2_expand_all_symtabs): Likewise.
12945 (dw2_expand_symtabs_with_fullname): Likewise.
12946 (dw2_expand_marked_cus): Replace index and objfile parameters
12947 with dwarf2_per_objfile.
12948 (dw_expand_symtabs_matching_file_matcher): Add
12949 dwarf2_per_objfile parameter and adjust calls.
12950 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
12952 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
12953 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
12955 (create_cus_from_debug_names_list): Replace objfile parameter
12956 with dwarf2_per_objfile and adjust calls.
12957 (create_cus_from_debug_names): Likewise.
12958 (dwarf2_read_debug_names): Likewise.
12959 (mapped_debug_names::namei_to_name): Adjust call.
12960 (dw2_debug_names_iterator::next): Likewise.
12961 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
12962 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
12963 (dw2_debug_names_dump): Likewise.
12964 (dw2_debug_names_expand_symtabs_for_function): Likewise.
12965 (dw2_debug_names_expand_symtabs_matching): Likewise.
12966 (dwarf2_initialize_objfile): Likewise.
12967 (dwarf2_build_psymtabs): Likewise.
12968 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
12970 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
12971 (read_and_check_comp_unit_head): Likewise.
12972 (read_abbrev_offset): Likewise.
12973 (create_debug_type_hash_table): Likewise.
12974 (create_debug_types_hash_table): Likewise.
12975 (create_all_type_units): Replace objfile parameter with
12976 dwarf2_per_objfile.
12977 (add_type_unit): Add dwarf2_per_objfile parameter.
12978 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
12979 with dwarf2_per_objfile.
12980 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
12981 (lookup_dwp_signatured_type): Likewise.
12982 (lookup_signatured_type): Likewise.
12983 (read_cutu_die_from_dwo): Likewise.
12984 (init_tu_and_read_dwo_dies): Likewise.
12985 (init_cutu_and_read_dies): Likewise.
12986 (init_cutu_and_read_dies_no_follow): Likewise.
12987 (allocate_type_unit_groups_table): Add objfile parameter.
12988 (create_type_unit_group): Use dwarf2_per_objfile from cu.
12989 (get_type_unit_group): Likewise.
12990 (process_psymtab_comp_unit): Update call.
12991 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
12992 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
12993 (print_tu_stats): Likewise.
12994 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
12995 in void* parameter.
12996 (build_type_psymtabs): Change objfile parameter to
12997 dwarf2_per_objfile.
12998 (process_skeletonless_type_unit): Use dwarf2_per_objfile
12999 passed in void* parameter.
13000 (process_skeletonless_type_units): Change objfile parameter to
13001 dwarf2_per_objfile.
13002 (set_partial_user): Likewise.
13003 (dwarf2_build_psymtabs_hard): Likewise.
13004 (read_comp_units_from_section): Likewise.
13005 (create_all_comp_units): Likewise.
13006 (scan_partial_symbols): Update calls.
13007 (add_partial_symbol): Likewise.
13008 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
13009 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
13010 (process_queue): Add dwarf2_per_objfile parameter.
13011 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
13012 (compute_compunit_symtab_includes): Likewise.
13013 (process_cu_includes): Add dwarf2_per_objfile parameter.
13014 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
13015 (process_full_type_unit): Likewise.
13016 (process_imported_unit_die): Update call.
13017 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
13018 (read_file_scope): Likewise.
13019 (allocate_dwo_file_hash_table): Add objfile parameter.
13020 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
13021 (create_cus_hash_table): Likewise.
13022 (create_dwp_hash_table): Likewise.
13023 (create_dwo_unit_in_dwp_v1): Likewise.
13024 (create_dwp_v2_section): Likewise.
13025 (create_dwo_unit_in_dwp_v2): Likewise.
13026 (lookup_dwo_unit_in_dwp): Likewise.
13027 (try_open_dwop_file): Likewise.
13028 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
13029 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
13030 cleanup to include a reference to dwarf2_per_objfile.
13031 (open_dwp_file): Add dwarf2_per_objfile parameter.
13032 (open_and_init_dwp_file): Likewise.
13033 (get_dwp_file): Likewise.
13034 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
13035 (queue_and_load_all_dwo_tus): Update call.
13036 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
13038 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
13039 (dwarf2_ranges_process): Likewise.
13040 (dwarf2_get_pc_bounds): Likewise.
13041 (mark_common_block_symbol_computed): Likewise.
13042 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
13043 (dwarf2_read_abbrevs): Update call.
13044 (read_partial_die): Use dwarf2_per_objfile from cu.
13045 (find_partial_die): Likewise.
13046 (fixup_partial_die): Likewise.
13047 (read_attribute_value): Likewise.
13048 (read_indirect_string_at_offset_from): Add objfile parameter.
13049 (read_indirect_string_at_offset): Add dwarf2_per_objfile
13051 (read_indirect_string_from_dwz): Add objfile parameter.
13052 (read_indirect_string): Add objfile parameter.
13053 (read_addr_index_1): Add dwarf2_per_objfile parameter.
13054 (read_addr_index): Use dwarf2_per_objfile from cu.
13055 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
13057 (read_str_index): Use dwarf2_per_objfile from cu.
13058 (get_debug_line_section): Likewise.
13059 (read_formatted_entries): Add dwarf2_per_objfile parameter.
13060 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
13061 (new_symbol_full): Use dwarf2_per_objfile from cu.
13062 (build_error_marker_type): Likewise.
13063 (lookup_die_type): Likewise.
13064 (determine_prefix): Likewise.
13065 (follow_die_offset): Likewise.
13066 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
13067 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
13068 (dwarf2_fetch_die_type_sect_off): Likewise.
13069 (dwarf2_get_die_type): Likewise.
13070 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
13071 (get_signatured_type): Likewise.
13072 (get_DW_AT_signature_type): Likewise.
13073 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
13074 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
13075 (cu_debug_loc_section): Likewise.
13076 (fill_in_loclist_baton): Likewise.
13077 (dwarf2_symbol_mark_computed): Likewise.
13078 (dwarf2_find_containing_comp_unit): Change objfile parameter to
13079 dwarf2_per_objfile.
13080 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
13082 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
13083 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
13084 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
13085 (set_die_type): Use dwarf2_free_objfile from cu.
13086 (get_die_type_at_offset): Likewise.
13087 (dwarf2_per_objfile_free): Don't assign global variable.
13088 (debug_names) <constructor>: Add dwarf2_per_objfile
13089 parameter, update m_debugstrlookup construction.
13090 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
13092 <m_dwarf2_per_objfile>: New field.
13093 <lookup>: Use m_dwarf2_per_objfile.
13094 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
13095 (psyms_seen_size): Likewise.
13096 (write_gdbindex): Replace objfile parameter with
13097 dwarf2_per_objfile.
13098 (write_debug_names): Likewise.
13099 (write_psymtabs_to_index): Likewise.
13100 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
13103 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13105 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
13106 <dwarf2_per_objfile>: New field.
13107 (struct dwarf2_per_cu_data) <objfile>: Remove.
13108 <dwarf2_per_objfile>: New field.
13109 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
13111 (create_signatured_type_table_from_index): Likewise.
13112 (create_debug_type_hash_table): Likewise.
13113 (fill_in_sig_entry_from_dwo_entry): Likewise.
13114 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
13115 (create_type_unit_group): Assign dwarf2_per_objfile instead of
13117 (create_partial_symtab): Access objfile through
13118 dwarf2_per_objfile.
13119 (process_psymtab_comp_unit_reader): Likewise.
13120 (read_comp_units_from_section): Likewise.
13121 (scan_partial_symbols): Likewise.
13122 (add_partial_symbol): Likewise.
13123 (add_partial_subprogram): Likewise.
13124 (peek_die_abbrev): Likewise.
13125 (fixup_go_packaging): Likewise.
13126 (process_full_comp_unit): Likewise.
13127 (process_full_type_unit): Likewise.
13128 (process_imported_unit_die): Likewise.
13129 (dwarf2_compute_name): Likewise.
13130 (dwarf2_physname): Likewise.
13131 (read_import_statement): Likewise.
13132 (create_cus_hash_table): Assign dwarf2_physname instead of
13134 (read_func_scope): Access objfile through dwarf2_per_objfile.
13135 (read_lexical_block_scope): Likewise.
13136 (read_call_site_scope): Likewise.
13137 (read_variable): Likewise.
13138 (dwarf2_rnglists_process): Likewise.
13139 (dwarf2_ranges_process): Likewise.
13140 (dwarf2_ranges_read): Likewise.
13141 (dwarf2_record_block_ranges): Likewise.
13142 (dwarf2_add_field): Likewise.
13143 (dwarf2_add_member_fn): Likewise.
13144 (read_structure_type): Likewise.
13145 (process_structure_scope): Likewise.
13146 (read_enumeration_type): Likewise.
13147 (read_array_type): Likewise.
13148 (read_common_block): Likewise.
13149 (read_namespace_type): Likewise.
13150 (read_namespace): Likewise.
13151 (read_module_type): Likewise.
13152 (read_tag_pointer_type): Likewise.
13153 (read_tag_ptr_to_member_type): Likewise.
13154 (read_tag_string_type): Likewise.
13155 (read_subroutine_type): Likewise.
13156 (read_typedef): Likewise.
13157 (read_base_type): Likewise.
13158 (attr_to_dynamic_prop): Likewise.
13159 (read_subrange_type): Likewise.
13160 (read_unspecified_type): Likewise.
13161 (load_partial_dies): Likewise.
13162 (read_partial_die): Likewise.
13163 (find_partial_die): Likewise.
13164 (guess_partial_die_structure_name): Likewise.
13165 (fixup_partial_die): Likewise.
13166 (read_attribute_value): Likewise.
13167 (read_addr_index_from_leb128): Likewise.
13168 (dwarf2_read_addr_index): Likewise.
13169 (dwarf2_string_attr): Likewise.
13170 (lnp_state_machine::check_line_address): Likewise.
13171 (dwarf_decode_lines_1): Likewise.
13172 (dwarf_decode_lines): Likewise.
13173 (dwarf2_start_symtab): Likewise.
13174 (var_decode_location): Likewise.
13175 (new_symbol_full): Likewise.
13176 (dwarf2_const_value_data): Likewise.
13177 (dwarf2_const_value_attr): Likewise.
13178 (dwarf2_const_value): Likewise.
13179 (die_type): Likewise.
13180 (die_containing_type): Likewise.
13181 (lookup_die_type): Likewise.
13182 (guess_full_die_structure_name): Likewise.
13183 (anonymous_struct_prefix): Likewise.
13184 (dwarf2_name): Likewise.
13185 (follow_die_ref_or_sig): Likewise.
13186 (follow_die_offset): Likewise.
13187 (follow_die_ref): Likewise.
13188 (dwarf2_fetch_die_loc_sect_off): Likewise.
13189 (dwarf2_fetch_constant_bytes): Likewise.
13190 (dwarf2_fetch_die_type_sect_off): Likewise.
13191 (dwarf2_get_die_type): Likewise.
13192 (follow_die_sig): Likewise.
13193 (decode_locdesc): Likewise.
13194 (dwarf2_per_cu_objfile): Likewise.
13195 (dwarf2_per_cu_text_offset): Likewise.
13196 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
13198 (set_die_type): Access objfile through
13199 dwarf2_per_objfile.
13201 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13203 * valprint.c (converted_character_d): Remove typedef.
13204 (DEF_VEC_O (converted_character_d)): Remove.
13205 (count_next_character): Use std::vector.
13206 (print_converted_chars_to_obstack): Likewise.
13207 (generic_printstr): Likewise.
13209 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13211 * xml-support.h (struct gdb_xml_value): Add constructor.
13212 <value>: Change type to unique_xmalloc_ptr.
13213 (gdb_xml_value_s): Remove typedef.
13214 (DEF_VEC_O (gdb_xml_value_s)): Remove.
13215 (gdb_xml_element_start_handler): Change parameter type to
13217 (xml_find_attribute): Likewise.
13218 * xml-support.c (xml_find_attribute): Change parameter type to
13219 std::vector and adjust.
13220 (gdb_xml_values_cleanup): Remove.
13221 (gdb_xml_parser::start_element): Adjust to std::vector.
13222 (xinclude_start_include): Change paraeter type to std::vector
13224 * btrace.c (check_xml_btrace_version): Likewise.
13225 (parse_xml_btrace_block): Likewise.
13226 (parse_xml_btrace_pt_config_cpu): Likewise.
13227 (parse_xml_btrace_pt): Likewise.
13228 (parse_xml_btrace_conf_bts): Likewise.
13229 (parse_xml_btrace_conf_pt): Likewise.
13230 * memory-map.c (memory_map_start_memory): Likewise.
13231 (memory_map_start_property): Likewise.
13232 * osdata.c (osdata_start_osdata): Likewise.
13233 (osdata_start_item): Likewise.
13234 (osdata_start_column): Likewise.
13235 * remote.c (start_thread): Likewise.
13236 * solib-aix.c (library_list_start_library): Likewise.
13237 (library_list_start_list): Likewise.
13238 * solib-svr4.c (library_list_start_library): Likewise.
13239 (svr4_library_list_start_list): Likewise.
13240 * solib-target.c (library_list_start_segment): Likewise.
13241 (library_list_start_section): Likewise.
13242 (library_list_start_library): Likewise.
13243 (library_list_start_list): Likewise.
13244 * tracepoint.c (traceframe_info_start_memory): Likewise.
13245 (traceframe_info_start_tvar): Likewise.
13246 * xml-syscall.c (syscall_start_syscall): Likewise.
13247 * xml-tdesc.c (tdesc_start_target): Likewise.
13248 (tdesc_start_feature): Likewise.
13249 (tdesc_start_reg): Likewise.
13250 (tdesc_start_union): Likewise.
13251 (tdesc_start_struct): Likewise.
13252 (tdesc_start_flags): Likewise.
13253 (tdesc_start_enum): Likewise.
13254 (tdesc_start_field): Likewise.
13255 (tdesc_start_enum_value): Likewise.
13256 (tdesc_start_vector): Likewise.
13258 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13260 * extension.h (struct xmethod_worker) <clone>: Remove.
13261 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
13263 (python_xmethod_worker::clone): Remove.
13264 * valops.c (find_overload_match): Use std::move instead of
13267 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13269 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
13270 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
13271 <free_xmethod_worker_data>: Remove.
13272 <get_matching_xmethod_workers>: Chance VEC to std::vector.
13273 <get_xmethod_arg_types>: Remove.
13274 <get_xmethod_result_type>: Remove.
13275 <invoke_xmethod>: Remove.
13276 * extension.c (new_xmethod_worker): Remove.
13277 (clone_xmethod_worker): Remove.
13278 (get_matching_xmethod_workers): Return void, pass std::vector by
13280 (get_xmethod_arg_types): Rename to...
13281 (xmethod_worker::get_arg_types): ... this, and adjust.
13282 (get_xmethod_result_type): Rename to...
13283 (xmethod_worker::get_result_type): ... this, and adjust.
13284 (invoke_xmethod): Remove.
13285 (free_xmethod_worker): Remove.
13286 (free_xmethod_worker_vec): Remove.
13287 * extension.h (enum ext_lang_rc): Move here from
13289 (struct xmethod_worker): Add constructor and destructor.
13292 <invoke, clone, do_get_result_type, do_get_arg_types>: New
13293 virtual pure methods.
13294 <get_arg_types, get_result_type>: New methods.
13295 (xmethod_worker_ptr): Remove typedef.
13296 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
13297 (xmethod_worker_vec): Remove typedef.
13298 (xmethod_worker_up): New typedef.
13299 (invoke_xmethod): Remove.
13300 (clone_xmethod_worker): Remove.
13301 (free_xmethod_worker): Remove.
13302 (free_xmethod_worker_vec): Remove.
13303 (get_xmethod_arg_types): Remove.
13304 (get_xmethod_result_type): Remove.
13305 * valops.c (find_method_list): Use std::vector, don't use
13306 intermediate vector.
13307 (value_find_oload_method_list): Use std::vector.
13308 (find_overload_match): Use std::vector.
13309 (find_oload_champ): Use std::vector.
13310 * value.c (value_free): Use operator delete.
13311 (value_of_xmethod): Rename to...
13312 (value_from_xmethod): ... this. Don't assign
13313 xmethod_worker::value, take rvalue-reference.
13314 (result_type_of_xmethod): Adjust.
13315 (call_xmethod): Adjust.
13316 * value.h: Include extension.h.
13317 (struct xmethod_worker): Don't forward-declare.
13318 (value_of_xmethod): Rename to...
13319 (value_from_xmethod): ... this, take rvalue-reference.
13320 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
13321 (struct python_xmethod_worker): ... this, add constructor and
13323 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
13324 (gdbpy_free_xmethod_worker_data): Rename to...
13325 (python_xmethod_worker::~python_xmethod_worker): ... this and
13327 (gdbpy_clone_xmethod_worker_data): Rename to...
13328 (python_xmethod_worker::clone): ... this and adjust.
13329 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
13331 (gdbpy_get_xmethod_arg_types): Rename to...
13332 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
13333 (gdbpy_get_xmethod_result_type): Rename to...
13334 (python_xmethod_worker::do_get_result_type): ... this and
13336 (gdbpy_invoke_xmethod): Rename to...
13337 (python_xmethod_worker::invoke): ... this and adjust.
13338 (new_python_xmethod_worker): Rename to...
13339 (python_xmethod_worker::python_xmethod_worker): ... this and
13341 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
13343 (gdbpy_free_xmethod_worker_data): Remove.
13344 (gdbpy_get_matching_xmethod_workers): Use std::vector.
13345 (gdbpy_get_xmethod_arg_types): Remove.
13346 (gdbpy_get_xmethod_result_type): Remove.
13347 (gdbpy_invoke_xmethod): Remove.
13348 * python/python.c (python_extension_ops): Remove obsolete
13351 2018-01-05 Pedro Alves <palves@redhat.com>
13354 * common/signals-state-save-restore.c
13355 (save_original_signals_state): New parameter 'quiet'. Warn if we
13356 find a custom handler preinstalled, instead of internal erroring.
13357 But only warn if !quiet.
13358 * common/signals-state-save-restore.h
13359 (save_original_signals_state): New parameter 'quiet'.
13360 * main.c (captured_main_1): Move save_original_signals_state call
13361 after option handling, and pass QUIET.
13363 2018-01-05 Pedro Alves <palves@redhat.com>
13365 * spu-tdep.c (spu_catch_start): Pass
13366 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
13368 2018-01-05 Pedro Alves <palves@redhat.com>
13371 * ada-lang.c (literal_symbol_name_matcher): New function.
13372 (ada_get_symbol_name_matcher): Use it for
13373 symbol_name_match_type::SEARCH_NAME.
13374 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
13375 it down instead of assuming symbol_name_match_type::FULL.
13376 * block.h (block_lookup_symbol): New parameter 'match_type'.
13377 * c-valprint.c (print_unpacked_pointer): Use
13378 lookup_symbol_search_name instead of lookup_symbol.
13379 * compile/compile-object-load.c (get_out_value_type): Pass down
13380 symbol_name_match_type::SEARCH_NAME.
13381 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
13382 symbol_name_match_type::FULL.
13383 * cp-support.c (cp_get_symbol_name_matcher): Handle
13384 symbol_name_match_type::SEARCH_NAME.
13385 * infrun.c (insert_exception_resume_breakpoint): Use
13386 lookup_symbol_search_name.
13387 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
13388 * psymtab.c (maintenance_check_psymtabs): Use
13389 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
13390 * stack.c (print_frame_args): Use lookup_symbol_search_name and
13391 SYMBOL_SEARCH_NAME.
13392 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
13393 if symbol_name_match_type::SEARCH_NAME.
13394 (lookup_symbol_in_language): Pass down
13395 symbol_name_match_type::FULL.
13396 (lookup_symbol_search_name): New.
13397 (lookup_language_this): Pass down
13398 symbol_name_match_type::SEARCH_NAME.
13399 (lookup_symbol_aux, lookup_local_symbol): New parameter
13400 'match_type'. Pass it down.
13401 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
13402 (lookup_symbol_search_name): New declaration.
13403 (lookup_symbol_in_block): New 'match_type' parameter.
13405 2018-01-05 Pedro Alves <palves@redhat.com>
13408 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
13410 (ada_lookup_symbol): Reimplement in terms of
13411 ada_lookup_symbol_list, bits factored out from
13412 ada_lookup_encoded_symbol.
13414 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13416 * ada-exp.y (write_object_renaming): When subscripting an array
13417 using a symbol as the index, pass the block in call to
13418 ada_lookup_encoded_symbol when looking that symbol up.
13420 2018-01-05 Jerome Guitton <guitton@adacore.com>
13422 * ada-lang.c (ada_array_length): Use ada_index_type instead of
13425 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13427 * ada-lang.c (ada_to_fixed_value_create): Add handling of
13428 the case where VALUE_LVAL (val0) is not lval_memory.
13430 2018-01-05 Xavier Roirand <roirand@adacore.com>
13432 * ada-valprint.c (print_optional_low_bound): Handle
13433 character-indexed array printing like boolean-indexed array
13436 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13438 * NEWS: Create a new section for the next release branch.
13439 Rename the section of the current branch, now that it has
13442 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13444 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
13445 * version.in: Bump version to 8.1.50.DATE-git.
13447 2018-01-03 Xavier Roirand <roirand@adacore.com>
13449 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
13451 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
13453 (default_exception_support_info) <catch_handlers_sym>: Add field.
13454 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
13455 (ada_exception_name_addr_1): Add "catch handlers" handling.
13456 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
13457 Update all callers.
13458 (create_excep_cond_exprs) <ex>: Add parameter.
13459 (re_set_exception): Update create_excep_cond_exprs call.
13460 (print_it_exception, print_one_exception, print_mention_exception)
13461 (print_recreate_exception): Add "catch handler" handling.
13462 (allocate_location_catch_handlers, re_set_catch_handlers)
13463 (check_status_catch_handlers, print_it_catch_handlers)
13464 (print_one_catch_handlers, print_mention_catch_handlers)
13465 (print_recreate_catch_handlers): New function.
13466 (catch_handlers_breakpoint_ops): New variable.
13467 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
13468 Add parameter. Add "catch handler" handling.
13469 (ada_exception_sym_name, ada_exception_breakpoint_ops):
13470 Add "catch handler" handling.
13471 (ada_exception_catchpoint_cond_string): Add "catch handler"
13473 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
13475 (catch_ada_handlers_command): New function.
13476 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
13477 operations structure.
13478 (_initialize_ada_language): Add "catch handlers" command entry.
13479 * NEWS: Document "catch handlers" feature.
13481 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13483 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
13484 account when creating the array type of the slice.
13485 (ada_value_slice): Likewise.
13487 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13489 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
13491 (create_array_type_with_stride): Add byte_stride_prop parameter.
13492 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
13493 New parameter. Update all callers in this file.
13494 (array_type_has_dynamic_stride): New function.
13495 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
13496 of arrays with dynamic byte strides.
13497 * dwarf2read.c (read_array_type): Add support for dynamic
13498 DW_AT_byte_stride attributes.
13500 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13502 * dwarf2read.c (read_unspecified_type): Treat
13503 DW_TAG_enumeration_type DIEs from Ada units as stubs.
13505 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13507 Update copyright year range in all GDB files.
13509 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13511 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
13512 and gdb/testsuite/gdb.base/step-line.c.
13514 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13516 * copyright.py (main): Dump the contents of
13517 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
13518 even if BY_HAND is empty.
13520 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13522 * top.c (print_gdb_version): Update Copyright year in version
13525 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13527 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
13529 For older changes see ChangeLog-2017.
13535 version-control: never