1 2018-09-16 Tom Tromey <tom@tromey.com>
3 * python/python-internal.h (thread_to_thread_object): Change
5 * python/py-inferior.c (thread_to_thread_object): Return a new
7 (infpy_thread_from_thread_handle): Update.
8 * python/py-infthread.c (gdbpy_selected_thread): Update.
9 * python/py-stopevent.c (create_stop_event_object): Update.
10 * python/py-threadevent.c (py_get_event_thread): Return a new
12 (py_get_event_thread): Update.
13 * python/py-event.h (py_get_event_thread): Change return type.
14 * python/py-continueevent.c (create_continue_event_object):
17 2018-09-16 Tom Tromey <tom@tromey.com>
19 * python/py-progspace.c (pspy_get_objfiles): Update.
20 * python/python-internal.h (objfile_to_objfile_object): Change
22 * python/py-newobjfileevent.c (create_new_objfile_event_object):
24 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
26 * python/python.c (gdbpy_get_current_objfile): Update.
27 (gdbpy_objfiles): Update.
28 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
30 (objfile_to_objfile_object): Return a new reference.
31 * python/py-symtab.c (stpy_get_objfile): Update.
32 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
35 2018-09-16 Tom Tromey <tom@tromey.com>
37 * python/py-inferior.c (infpy_get_progspace): Update.
38 * python/python-internal.h (pspace_to_pspace_object): Change
40 * python/py-newobjfileevent.c
41 (create_clear_objfiles_event_object): Update.
42 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
44 * python/python.c (gdbpy_get_current_progspace): Update.
45 (gdbpy_progspaces): Update.
46 * python/py-progspace.c (pspace_to_pspace_object): Return a new
48 * python/py-objfile.c (objfpy_get_progspace): Update.
49 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
52 2018-09-16 Tom Tromey <tom@tromey.com>
54 * python/lib/gdb/__init__.py (current_progspace, objfiles)
55 (solib_name, block_for_pc, find_pc_line): New functions.
56 (execute_unwinders): Update.
57 * python/py-block.c (gdbpy_block_for_pc): Remove.
58 * python/py-inferior.c (infpy_get_progspace): New function.
59 (inferior_object_getset) <progspace>: Add.
60 * python/py-progspace.c (pspy_objfiles): Rewrite.
61 (pspy_solib_name, pspy_block_for_pc)
62 (pspy_find_pc_line, pspy_is_valid): New functions.
63 (progspace_object_methods): Add entries for solib_name,
64 block_for_pc, find_pc_line, is_valid.
65 * python/python-internal.h (gdbpy_block_for_pc)
66 (build_objfiles_list): Don't declare.
67 * python/python.c: Don't include solib.h.
68 (gdbpy_solib_name, gdbpy_find_pc_line)
69 (gdbpy_get_current_progspace, build_objfiles_list)
70 (gdbpy_objfiles): Remove.
71 (GdbMethods) <current_progspace, objfiles, block_for_pc,
72 solib_name, find_pc_line>: Remove entries.
74 2018-09-16 Tom Tromey <tom@tromey.com>
76 * top.c (new_ui_command): Use GNU style for metasyntactic
78 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
80 * maint.c (maintenance_translate_address): Remove "<>" around
82 * interps.c (interpreter_exec_cmd): Use GNU style for
83 metasyntactic variables.
84 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
85 metasyntactic variables.
86 * tracepoint.c (tfind_range_command): Use GNU style for
87 metasyntactic variables.
88 (tfind_outside_command): Likewise.
89 (_initialize_tracepoint): Likewise.
90 * remote.c (extended_remote_target::create_inferior): Use GNU
91 style for metasyntactic variables.
92 * sparc64-tdep.c (adi_examine_command): Use GNU style for
93 metasyntactic variables.
94 (adi_assign_command): Likewise.
96 2018-09-16 Tom Tromey <tom@tromey.com>
98 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
99 metasyntactic variables. Print message if no disassembler options
102 2018-09-15 Tom Tromey <tom@tromey.com>
104 * infcmd.c (get_inferior_args): Return const char *.
105 * inferior.h (get_inferior_args): Return type now const.
106 * linux-tdep.c (linux_fill_prpsinfo): Update.
107 * procfs.c (procfs_target::make_corefile_notes): Update.
109 2018-09-07 Tom Tromey <tom@tromey.com>
111 * python/python.c (execute_gdb_command): Call bpstat_do_actions
114 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
116 * nios2-tdep.c (nios2_type_align): New.
117 (nios2_gdb_arch_init): Install type_align hook.
119 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
121 * eval.c (fake_method::fake_method): Call xzalloc directly for a
122 type that is neither object file owned, nor gdbarch owned.
123 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
125 (alloc_type_instance): Allocate non-objfile owned types on the
127 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
128 using TYPE_ALLOC to ensure memory is allocated on the correct
130 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
131 obstack, or the gdbarch obstack.
132 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
134 2018-09-14 Tom Tromey <tom@tromey.com>
136 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
139 2018-09-14 Tom Tromey <tom@tromey.com>
141 * nat/fork-inferior.c (get_startup_shell): Remove "static".
143 2018-09-13 Tom Tromey <tom@tromey.com>
145 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
148 2018-09-13 Tom Tromey <tom@tromey.com>
150 * exec.c (try_open_exec_file): Use std::string.
152 2018-09-13 Tom Tromey <tom@tromey.com>
154 * utils.h (gdb_bfd_errmsg): Return std::string.
155 * exec.c (exec_file_attach): Update.
156 * compile/compile-object-load.c (compile_object_load): Update.
157 * utils.c (gdb_bfd_errmsg): Return std::string.
159 2018-09-13 Tom Tromey <tom@tromey.com>
161 * procfs.c (struct procinfo_deleter): New.
162 (procinfo_up): New typedef.
163 (do_destroy_procinfo_cleanup): Remove.
164 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
166 2018-09-13 Tom Tromey <tom@tromey.com>
168 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
170 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
171 2018-09-13 Tom Tromey <tom@tromey.com>
173 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
174 (pspy_get_objfiles): New function.
175 (progspace_object_methods): New.
176 (pspace_object_type): Add tp_methods callback.
177 * python/python-internal.h (build_objfiles_list): New
179 * python/python.c (build_objfiles_list): New function.
180 (gdbpy_objfiles): Implement using build_objfiles_list.
181 * NEWS: Mention the Progspace.objfiles method.
183 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
185 * python/py-inferior.c (infpy_get_progspace): New function.
186 (inferior_object_getset): Add progspace property.
187 * NEWS: Mention the new property.
189 2018-09-13 Tom Tromey <tom@tromey.com>
192 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
194 2018-09-13 Tom Tromey <tom@tromey.com>
197 * rust-lang.c (rust_enum_variant): Now static.
198 (rust_empty_enum_p): New function.
199 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
202 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
204 * python/py-inferior.c (infpy_repr): New.
205 (inferior_object_type): Register infpy_repr.
206 * python/py-objfile.c (objfpy_repr): New.
207 (objfile_object_type): Register objfpy_repr.
209 2018-09-12 John Baldwin <jhb@FreeBSD.org>
211 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
213 2018-09-12 John Baldwin <jhb@FreeBSD.org>
215 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
218 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
220 * common/common-utils.c: Don't include '<sys/stat.h>'.
221 (is_regular_file): Move to...
222 * common/filestuff.c (is_regular_file): ... here.
223 * common/common-utils.h (is_regular_file): Move to...
224 * common/filestuff.h (is_regular_file): ... here.
226 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
228 * skip.c (debug_skip): New variable.
229 (skiplist_entry::do_skip_file_p): Add debug output.
230 (skiplist_entry::do_skip_gfile_p): Likewise.
231 (skiplist_entry::skip_function_p): Likewise.
232 (_initialize_step_skip): Create debug command.
233 * NEWS: Mention set/show debug skip.
235 2018-09-11 Xavier Roirand <roirand@adacore.com>
237 * darwin-nat.c (should_disable_startup_with_shell):
239 (darwin_nat_target::create_inferior): Add call.
241 2018-09-11 Xavier Roirand <roirand@adacore.com>
243 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
244 inf_port, msg_state>: Initialize.
245 (struct darwin_thread_info) <signaled, single_step>: Change
247 (struct darwin_thread_info) <event>: Initialize.
249 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
253 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
256 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
259 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
263 * gnulib/aclocal.m4: Regenerate.
264 * gnulib/config.in: Regenerate.
265 * gnulib/configure: Regenerate.
266 * gnulib/import/Makefile.am: Update.
267 * gnulib/import/Makefile.in: Update.
268 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
269 * gnulib/import/_Noreturn.h: ... this.
270 * gnulib/import/alloca.in.h: Update.
271 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
272 * gnulib/import/arg-nonnull.h: ... this.
273 * gnulib/import/assure.h: Update.
274 * gnulib/import/at-func.c: Update.
275 * gnulib/import/basename-lgpl.c: Update.
276 * gnulib/import/extra/snippet/c++defs.h: Rename to...
277 * gnulib/import/c++defs.h: ... this.
278 * gnulib/import/canonicalize-lgpl.c: Update.
279 * gnulib/import/cdefs.h: Update.
280 * gnulib/import/chdir-long.c: Update.
281 * gnulib/import/chdir-long.h: Update.
282 * gnulib/import/cloexec.c: Update.
283 * gnulib/import/cloexec.h: Update.
284 * gnulib/import/close.c: Update.
285 * gnulib/import/closedir.c: Update.
286 * gnulib/import/config.charset: Update.
287 * gnulib/import/dirent-private.h: Update.
288 * gnulib/import/dirent.in.h: Update.
289 * gnulib/import/dirfd.c: Update.
290 * gnulib/import/dirname-lgpl.c: Update.
291 * gnulib/import/dirname.h: Update.
292 * gnulib/import/dosname.h: Update.
293 * gnulib/import/dup-safer-flag.c: Update.
294 * gnulib/import/dup-safer.c: Update.
295 * gnulib/import/dup.c: Update.
296 * gnulib/import/dup2.c: Update.
297 * gnulib/import/errno.in.h: Update.
298 * gnulib/import/error.c: Update.
299 * gnulib/import/error.h: Update.
300 * gnulib/import/exitfail.c: Update.
301 * gnulib/import/exitfail.h: Update.
302 * gnulib/import/extra/update-copyright: Update.
303 * gnulib/import/fchdir.c: Update.
304 * gnulib/import/fcntl.c: Update.
305 * gnulib/import/fcntl.in.h: Update.
306 * gnulib/import/fd-hook.c: Update.
307 * gnulib/import/fd-hook.h: Update.
308 * gnulib/import/fd-safer-flag.c: Update.
309 * gnulib/import/fd-safer.c: Update.
310 * gnulib/import/fdopendir.c: Update.
311 * gnulib/import/filename.h: Update.
312 * gnulib/import/filenamecat-lgpl.c: Update.
313 * gnulib/import/filenamecat.h: Update.
314 * gnulib/import/flexmember.h: Update.
315 * gnulib/import/float+.h: Update.
316 * gnulib/import/float.c: Update.
317 * gnulib/import/float.in.h: Update.
318 * gnulib/import/fnmatch.c: Update.
319 * gnulib/import/fnmatch.in.h: Update.
320 * gnulib/import/fnmatch_loop.c: Update.
321 * gnulib/import/fpucw.h: Update.
322 * gnulib/import/frexp.c: Update.
323 * gnulib/import/frexpl.c: Update.
324 * gnulib/import/fstat.c: Update.
325 * gnulib/import/fstatat.c: Update.
326 * gnulib/import/getcwd-lgpl.c: Update.
327 * gnulib/import/getcwd.c: Update.
328 * gnulib/import/getdtablesize.c: Update.
329 * gnulib/import/getlogin_r.c: Update.
330 * gnulib/import/getprogname.c: Update.
331 * gnulib/import/getprogname.h: Update.
332 * gnulib/import/gettext.h: Update.
333 * gnulib/import/gettimeofday.c: Update.
334 * gnulib/import/glob-libc.h: Update.
335 * gnulib/import/glob.c: Update.
336 * gnulib/import/glob.in.h: Update.
337 * gnulib/import/glob_internal.h: Update.
338 * gnulib/import/glob_pattern_p.c: Update.
339 * gnulib/import/globfree.c: Update.
340 * gnulib/import/hard-locale.c: Update.
341 * gnulib/import/hard-locale.h: Update.
342 * gnulib/import/intprops.h: Update.
343 * gnulib/import/inttypes.in.h: Update.
344 * gnulib/import/isnan.c: Update.
345 * gnulib/import/isnand-nolibm.h: Update.
346 * gnulib/import/isnand.c: Update.
347 * gnulib/import/isnanl-nolibm.h: Update.
348 * gnulib/import/isnanl.c: Update.
349 * gnulib/import/itold.c: Update.
350 * gnulib/import/libc-config.h: Update.
351 * gnulib/import/limits.in.h: Update.
352 * gnulib/import/localcharset.c: Update.
353 * gnulib/import/localcharset.h: Update.
354 * gnulib/import/localtime-buffer.c: Update.
355 * gnulib/import/localtime-buffer.h: Update.
356 * gnulib/import/lstat.c: Update.
357 * gnulib/import/m4/00gnulib.m4: Update.
358 * gnulib/import/m4/__inline.m4: Update.
359 * gnulib/import/m4/absolute-header.m4: Update.
360 * gnulib/import/m4/alloca.m4: Update.
361 * gnulib/import/m4/builtin-expect.m4: Update.
362 * gnulib/import/m4/canonicalize.m4: Update.
363 * gnulib/import/m4/chdir-long.m4: Update.
364 * gnulib/import/m4/close.m4: Update.
365 * gnulib/import/m4/closedir.m4: Update.
366 * gnulib/import/m4/configmake.m4: Update.
367 * gnulib/import/m4/d-ino.m4: Update.
368 * gnulib/import/m4/d-type.m4: Update.
369 * gnulib/import/m4/dirent_h.m4: Update.
370 * gnulib/import/m4/dirfd.m4: Update.
371 * gnulib/import/m4/dirname.m4: Update.
372 * gnulib/import/m4/double-slash-root.m4: Update.
373 * gnulib/import/m4/dup.m4: Update.
374 * gnulib/import/m4/dup2.m4: Update.
375 * gnulib/import/m4/eealloc.m4: Update.
376 * gnulib/import/m4/environ.m4: Update.
377 * gnulib/import/m4/errno_h.m4: Update.
378 * gnulib/import/m4/error.m4: Update.
379 * gnulib/import/m4/exponentd.m4: Update.
380 * gnulib/import/m4/exponentl.m4: Update.
381 * gnulib/import/m4/extensions.m4: Update.
382 * gnulib/import/m4/extern-inline.m4: Update.
383 * gnulib/import/m4/fchdir.m4: Update.
384 * gnulib/import/m4/fcntl-o.m4: Update.
385 * gnulib/import/m4/fcntl.m4: Update.
386 * gnulib/import/m4/fcntl_h.m4: Update.
387 * gnulib/import/m4/fdopendir.m4: Update.
388 * gnulib/import/m4/filenamecat.m4: Update.
389 * gnulib/import/m4/flexmember.m4: Update.
390 * gnulib/import/m4/float_h.m4: Update.
391 * gnulib/import/m4/fnmatch.m4: Update.
392 * gnulib/import/m4/fnmatch_h.m4: Update.
393 * gnulib/import/m4/fpieee.m4: Update.
394 * gnulib/import/m4/frexp.m4: Update.
395 * gnulib/import/m4/frexpl.m4: Update.
396 * gnulib/import/m4/fstat.m4: Update.
397 * gnulib/import/m4/fstatat.m4: Update.
398 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
399 * gnulib/import/m4/getcwd-path-max.m4: Update.
400 * gnulib/import/m4/getcwd.m4: Update.
401 * gnulib/import/m4/getdtablesize.m4: Update.
402 * gnulib/import/m4/getlogin.m4: Update.
403 * gnulib/import/m4/getlogin_r.m4: Update.
404 * gnulib/import/m4/getpagesize.m4: Update.
405 * gnulib/import/m4/getprogname.m4: Update.
406 * gnulib/import/m4/gettimeofday.m4: Update.
407 * gnulib/import/m4/glibc21.m4: Update.
408 * gnulib/import/m4/glob.m4: Update.
409 * gnulib/import/m4/glob_h.m4: Update.
410 * gnulib/import/m4/gnulib-cache.m4: Update.
411 * gnulib/import/m4/gnulib-common.m4: Update.
412 * gnulib/import/m4/gnulib-comp.m4: Update.
413 * gnulib/import/m4/gnulib-tool.m4: Update.
414 * gnulib/import/m4/hard-locale.m4: Update.
415 * gnulib/import/m4/include_next.m4: Update.
416 * gnulib/import/m4/inttypes-pri.m4: Update.
417 * gnulib/import/m4/inttypes.m4: Update.
418 * gnulib/import/m4/isnand.m4: Update.
419 * gnulib/import/m4/isnanl.m4: Update.
420 * gnulib/import/m4/largefile.m4: Update.
421 * gnulib/import/m4/limits-h.m4: Update.
422 * gnulib/import/m4/localcharset.m4: Update.
423 * gnulib/import/m4/locale-fr.m4: Update.
424 * gnulib/import/m4/locale-ja.m4: Update.
425 * gnulib/import/m4/locale-zh.m4: Update.
426 * gnulib/import/m4/localtime-buffer.m4: Update.
427 * gnulib/import/m4/longlong.m4: Update.
428 * gnulib/import/m4/lstat.m4: Update.
429 * gnulib/import/m4/malloc.m4: Update.
430 * gnulib/import/m4/malloca.m4: Update.
431 * gnulib/import/m4/math_h.m4: Update.
432 * gnulib/import/m4/mbrtowc.m4: Update.
433 * gnulib/import/m4/mbsinit.m4: Update.
434 * gnulib/import/m4/mbsrtowcs.m4: Update.
435 * gnulib/import/m4/mbstate_t.m4: Update.
436 * gnulib/import/m4/memchr.m4: Update.
437 * gnulib/import/m4/memmem.m4: Update.
438 * gnulib/import/m4/mempcpy.m4: Update.
439 * gnulib/import/m4/memrchr.m4: Update.
440 * gnulib/import/m4/mkdir.m4: Update.
441 * gnulib/import/m4/mkstemp.m4: Update.
442 * gnulib/import/m4/mmap-anon.m4: Update.
443 * gnulib/import/m4/mode_t.m4: Update.
444 * gnulib/import/m4/msvc-inval.m4: Update.
445 * gnulib/import/m4/msvc-nothrow.m4: Update.
446 * gnulib/import/m4/multiarch.m4: Update.
447 * gnulib/import/m4/nocrash.m4: Update.
448 * gnulib/import/m4/off_t.m4: Update.
449 * gnulib/import/m4/onceonly.m4: Update.
450 * gnulib/import/m4/open-cloexec.m4: Update.
451 * gnulib/import/m4/open.m4: Update.
452 * gnulib/import/m4/openat.m4: Update.
453 * gnulib/import/m4/opendir.m4: Update.
454 * gnulib/import/m4/pathmax.m4: Update.
455 * gnulib/import/m4/rawmemchr.m4: Update.
456 * gnulib/import/m4/readdir.m4: Update.
457 * gnulib/import/m4/readlink.m4: Update.
458 * gnulib/import/m4/realloc.m4: Update.
459 * gnulib/import/m4/rename.m4: Update.
460 * gnulib/import/m4/rewinddir.m4: Update.
461 * gnulib/import/m4/rmdir.m4: Update.
462 * gnulib/import/m4/save-cwd.m4: Update.
463 * gnulib/import/m4/secure_getenv.m4: Update.
464 * gnulib/import/m4/setenv.m4: Update.
465 * gnulib/import/m4/signal_h.m4: Update.
466 * gnulib/import/m4/ssize_t.m4: Update.
467 * gnulib/import/m4/stat-time.m4: Update.
468 * gnulib/import/m4/stat.m4: Update.
469 * gnulib/import/m4/std-gnu11.m4: Update.
470 * gnulib/import/m4/stdbool.m4: Update.
471 * gnulib/import/m4/stddef_h.m4: Update.
472 * gnulib/import/m4/stdint.m4: Update.
473 * gnulib/import/m4/stdio_h.m4: Update.
474 * gnulib/import/m4/stdlib_h.m4: Update.
475 * gnulib/import/m4/strchrnul.m4: Update.
476 * gnulib/import/m4/strdup.m4: Update.
477 * gnulib/import/m4/strerror.m4: Update.
478 * gnulib/import/m4/string_h.m4: Update.
479 * gnulib/import/m4/strstr.m4: Update.
480 * gnulib/import/m4/strtok_r.m4: Update.
481 * gnulib/import/m4/sys_socket_h.m4: Update.
482 * gnulib/import/m4/sys_stat_h.m4: Update.
483 * gnulib/import/m4/sys_time_h.m4: Update.
484 * gnulib/import/m4/sys_types_h.m4: Update.
485 * gnulib/import/m4/tempname.m4: Update.
486 * gnulib/import/m4/time_h.m4: Update.
487 * gnulib/import/m4/unistd-safer.m4: Update.
488 * gnulib/import/m4/unistd_h.m4: Update.
489 * gnulib/import/m4/warn-on-use.m4: Update.
490 * gnulib/import/m4/wchar_h.m4: Update.
491 * gnulib/import/m4/wchar_t.m4: Update.
492 * gnulib/import/m4/wctype_h.m4: Update.
493 * gnulib/import/m4/wint_t.m4: Update.
494 * gnulib/import/malloc.c: Update.
495 * gnulib/import/malloc/scratch_buffer.h: Update.
496 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
497 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
498 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
499 * gnulib/import/malloca.c: Update.
500 * gnulib/import/malloca.h: Update.
501 * gnulib/import/malloca.valgrind: Update.
502 * gnulib/import/math.in.h: Update.
503 * gnulib/import/mbrtowc.c: Update.
504 * gnulib/import/mbsinit.c: Update.
505 * gnulib/import/mbsrtowcs-impl.h: Update.
506 * gnulib/import/mbsrtowcs-state.c: Update.
507 * gnulib/import/mbsrtowcs.c: Update.
508 * gnulib/import/memchr.c: Update.
509 * gnulib/import/memmem.c: Update.
510 * gnulib/import/mempcpy.c: Update.
511 * gnulib/import/memrchr.c: Update.
512 * gnulib/import/mkdir.c: Update.
513 * gnulib/import/mkstemp.c: Update.
514 * gnulib/import/msvc-inval.c: Update.
515 * gnulib/import/msvc-inval.h: Update.
516 * gnulib/import/msvc-nothrow.c: Update.
517 * gnulib/import/msvc-nothrow.h: Update.
518 * gnulib/import/open.c: Update.
519 * gnulib/import/openat-die.c: Update.
520 * gnulib/import/openat-priv.h: Update.
521 * gnulib/import/openat-proc.c: Update.
522 * gnulib/import/openat.c: Update.
523 * gnulib/import/openat.h: Update.
524 * gnulib/import/opendir.c: Update.
525 * gnulib/import/pathmax.h: Update.
526 * gnulib/import/pipe-safer.c: Update.
527 * gnulib/import/rawmemchr.c: Update.
528 * gnulib/import/readdir.c: Update.
529 * gnulib/import/readlink.c: Update.
530 * gnulib/import/realloc.c: Update.
531 * gnulib/import/ref-add.sin: Update.
532 * gnulib/import/ref-del.sin: Update.
533 * gnulib/import/rename.c: Update.
534 * gnulib/import/rewinddir.c: Update.
535 * gnulib/import/rmdir.c: Update.
536 * gnulib/import/same-inode.h: Update.
537 * gnulib/import/save-cwd.c: Update.
538 * gnulib/import/save-cwd.h: Update.
539 * gnulib/import/scratch_buffer.h: Update.
540 * gnulib/import/secure_getenv.c: Update.
541 * gnulib/import/setenv.c: Update.
542 * gnulib/import/signal.in.h: Update.
543 * gnulib/import/stat-time.c: Update.
544 * gnulib/import/stat-time.h: Update.
545 * gnulib/import/stat-w32.c: Update.
546 * gnulib/import/stat-w32.h: Update.
547 * gnulib/import/stat.c: Update.
548 * gnulib/import/stdbool.in.h: Update.
549 * gnulib/import/stddef.in.h: Update.
550 * gnulib/import/stdint.in.h: Update.
551 * gnulib/import/stdio.in.h: Update.
552 * gnulib/import/stdlib.in.h: Update.
553 * gnulib/import/str-two-way.h: Update.
554 * gnulib/import/strchrnul.c: Update.
555 * gnulib/import/strdup.c: Update.
556 * gnulib/import/streq.h: Update.
557 * gnulib/import/strerror-override.c: Update.
558 * gnulib/import/strerror-override.h: Update.
559 * gnulib/import/strerror.c: Update.
560 * gnulib/import/string.in.h: Update.
561 * gnulib/import/stripslash.c: Update.
562 * gnulib/import/strnlen1.c: Update.
563 * gnulib/import/strnlen1.h: Update.
564 * gnulib/import/strstr.c: Update.
565 * gnulib/import/strtok_r.c: Update.
566 * gnulib/import/sys_stat.in.h: Update.
567 * gnulib/import/sys_time.in.h: Update.
568 * gnulib/import/sys_types.in.h: Update.
569 * gnulib/import/tempname.c: Update.
570 * gnulib/import/tempname.h: Update.
571 * gnulib/import/time.in.h: Update.
572 * gnulib/import/unistd--.h: Update.
573 * gnulib/import/unistd-safer.h: Update.
574 * gnulib/import/unistd.in.h: Update.
575 * gnulib/import/unsetenv.c: Update.
576 * gnulib/import/verify.h: Update.
577 * gnulib/import/extra/snippet/warn-on-use.h: Update.
578 * gnulib/import/wchar.in.h: Update.
579 * gnulib/import/wctype.in.h: Update.
580 * gnulib/import/xalloc-oversized.h: Update.
581 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
582 "53e2c179f26a890fa6685af4b6c1397ee370433b".
584 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
586 * record-btrace.c (get_thread_current_frame): Remove
589 2018-09-10 Jerome Guitton <guitton@adacore.com>
591 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
592 with check_tag to 1 if and only if the type is tagged and the
593 component being searched cannot been found in the current
594 view. Otherwise, always call ada_to_fixed_type with
597 2018-09-10 Xavier Roirand <roirand@adacore.com>
599 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
601 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
602 * ada-varobj.c (ada_varobj_get_number_of_children,
603 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
605 2018-09-10 Xavier Roirand <roirand@adacore.com>
607 * ada-valprint.c (ada_value_print): Use type instead of
610 2018-09-10 Xavier Roirand <roirand@adacore.com>
612 * ada-lang.c (ada_value_subscript): Handle case when parameter is
613 an array of access to unconstrained array.
615 2018-09-10 Xavier Roirand <roirand@adacore.com>
617 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
618 (ada_check_typedef): Use it.
620 2018-09-10 Xavier Roirand <roirand@adacore.com>
622 * ada-varobj.c (ada_varobj_describe_struct_child)
623 (ada_varobj_describe_child): Handle union case like struct one.
625 2018-09-10 Tom Tromey <tom@tromey.com>
628 * python/python.c (_initialize_python): Make example in "python"
629 help work in Python 3.
631 2018-09-10 Eli Zaretskii <eliz@gnu.org>
633 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
634 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
635 $(EXEEXT) to the script, as it is not a program.
637 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
639 * python/py-prettyprint.c (pretty_print_one_value): Return
641 (print_string_repr): Adjust.
642 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
643 * python/python-internal.h (apply_varobj_pretty_printer): Return
645 * varobj.c (varobj_value_get_print_value): Adjust.
647 2018-09-08 Tom Tromey <tom@tromey.com>
650 * python/py-prettyprint.c (pretty_print_one_value): Check for
653 2018-09-08 Joel Brobecker <brobecker@adacore.com>
655 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
656 replace_operator_with_call.
658 2018-09-08 Joel Brobecker <brobecker@adacore.com>
660 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
662 2018-09-08 Joel Brobecker <brobecker@adacore.com>
664 * ada-typeprint.c (print_range): Print the bounds using TYPE
665 rather than its TYPE_TARGET_TYPE.
667 2018-09-08 Joel Brobecker <brobecker@adacore.com>
669 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
670 call to ada_to_fixed_value_create.
672 2018-09-08 Jerome Guitton <guitton@adacore.com>
674 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
676 2018-09-08 Joel Brobecker <brobecker@adacore.com>
678 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
681 2018-09-08 Joel Brobecker <brobecker@adacore.com>
683 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
684 Move update of loop variable "fi".
686 2018-09-08 Joel Brobecker <brobecker@adacore.com>
688 * ada-lang.c (value_assign_to_component): In the case of
689 big-endian targets, extract the bits of the given VAL
690 using an src_offset of zero if container is not a scalar.
692 2018-09-06 Simon Ser <contact@emersion.fr>
695 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
696 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
697 * fbsd-tdep.c (fbsd_make_note_desc): New.
698 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
699 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
700 * target.h (enum target_object) Add FreeBSD-specific
701 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
703 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
705 * compile/compile-c.h (generate_c_for_variable_locations):
706 Change reference to pointer.
707 * compile/compile-c-support.c (compile_program) <compute>:
709 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
710 (generate_c_for_for_one_variable): Likewise
711 (generate_c_for_variable_locations): Likewise
712 * compile/compile-c-types.c (compile_c_instance::convert_type):
714 * compile/compile-cplus-symbols.c (convert_one_symbol):
715 std::move the scope passed to enter_scope.
716 * compile/compile-cplus-types.c
717 (compile_cplus_instance::enter_scope): Make parameter
719 (compile_cplus_instance::new_scope): Change reference to
721 (compile_cplus_instance::convert_type): Likewise
722 (compile_cplus_convert_typedef): std::move the scope passed to
724 (compile_cplus_convert_struct_or_union): Likewise.
725 (compile_cplus_convert_enum): Likewise.
726 (compile_cplus_convert_namespace): Likewise.
727 * compile/compile-cplus.h (compile_cplus_instance)
728 <enter_scope>: Make parameter rvalue-reference.
729 * compile/compile-internal.h (compile_instance)
730 <get_cached_type>: Likewise
731 * compile/compile-loc2c.c (push): Likewise
735 (print_label): Likewise
736 (pushf_register_address): Likewise
737 (pushf_register): Likewise
738 (do_compile_dwarf_expr_to_c): Likewise
739 (compile_dwarf_expr_to_c): Likewise
740 (compile_dwarf_bounds_to_c): Likewise
741 * compile/compile.c (compile_instance::get_cached_type):
743 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
744 (compile_dwarf_bounds_to_c): Likewise
745 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
746 (dwarf2_compile_property_to_c): Likewise
747 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
748 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
751 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
753 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
754 * tui/tui-data.c (init_content_element): Don't initialize it.
756 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
758 * tui/tui-data.h (struct tui_win_info)
759 <detail::opaque>: Remove.
760 * tui/tui-data.c (init_win_info): Remove assignment.
762 2018-09-05 Tom Tromey <tom@tromey.com>
764 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
766 * target-float.c (host_float_ops<T>::to_string)
767 (host_float_ops<T>::from_string): Use
768 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
769 * configure: Rebuild.
771 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
773 * printcmd.c (printf_c_string): Use
774 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
775 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
777 2018-09-05 Tom Tromey <tom@tromey.com>
779 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
781 2018-09-05 Tom de Vries <tdevries@suse.de>
783 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
784 with resolve_abstract_p == true.
785 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
786 defaulting to false. Propagate resolve_abstract_p to
787 dwarf2_fetch_die_loc_sect_off.
788 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
789 parameter, defaulting to false.
790 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
791 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
793 * dwarf2read.h (struct die_info): Forward-declare.
794 (die_info_ptr): New typedef.
795 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
797 2018-09-05 Joel Brobecker <brobecker@adacore.com>
801 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
802 Pedro Alves <palves@redhat.com>
804 * gnulib/Makefile.in (aclocal_m4_deps): Move to
805 "aclocal-m4-deps.mk". Include file here.
806 $(srcdir)/aclocal.m4: Add "configure.ac".
807 * gnulib/aclocal-m4-deps.mk: New file.
808 * gnulib/update-gnulib.sh: Automatically update
809 "aclocal-m4-deps.mk".
811 2018-09-04 Tom Tromey <tom@tromey.com>
813 * configure: Rebuild.
814 * configure.ac: Remove multi-ice code.
816 2018-09-04 Tom Tromey <tom@tromey.com>
818 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
821 2018-09-04 Tom Tromey <tom@tromey.com>
823 * Makefile.in (printcmd.o, target-float.o): Remove.
824 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
826 2018-09-04 Tom Tromey <tom@tromey.com>
828 * gnulib/Makefile.in: Remove obsolete comment.
829 * Makefile.in: Remove obsolete comment.
831 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
833 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
836 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
838 * riscv-tdep.c: Add 'prologue-value.h' include.
839 (struct riscv_unwind_cache): New struct.
840 (riscv_debug_unwinder): New global.
841 (riscv_scan_prologue): Update arguments, capture register details
843 (riscv_skip_prologue): Reformat arguments line, move end of
844 prologue calculation into riscv_scan_prologue.
845 (riscv_frame_cache): Update return type, create
846 riscv_unwind_cache, scan the prologue, and fill in remaining cache
848 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
849 (riscv_frame_prev_register): Use the trad_frame within the
851 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
854 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
856 * trad-frame.h (trad_frame_set_realreg): Declare.
857 (trad_frame_set_addr): Declare.
858 * trad-frame.c (trad_frame_set_realreg): Define new function.
859 (trad_frame_set_addr): Define new function.
860 (trad_frame_set_reg_realreg): Use new function.
861 (trad_frame_set_reg_addr): Use new function.
863 2018-09-01 Keith Seitz <keiths@redhat.com>
865 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
866 pulongest instead of "%lld".
867 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
870 2018-08-31 Tom Tromey <tom@tromey.com>
872 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
875 2018-08-31 Pedro Alves <palves@redhat.com>
877 * gdbarch.h: Regenerate.
879 2018-08-31 Pedro Alves <palves@redhat.com>
881 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
882 * target.h (Hardware watchpoint interfaces): Describe
883 continuable/steppable/non-steppable watchpoints.
884 * gdbarch.h, gdbarch.c: Regenerate.
886 2018-08-31 Pedro Alves <palves@redhat.com>
888 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
891 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
892 * target.h (target_ops::have_continuable_watchpoint): Delete.
893 (target_have_continuable_watchpoint): Delete.
894 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
895 * target-delegates.c: Regenerate.
897 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
899 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
900 the files present in "gnulib/import/m4/".
902 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
904 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
905 c.sw, c.swsp, and c.sdsp.
907 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
909 * riscv-tdep.c (struct riscv_inferior_data): Delete.
910 (riscv_read_misa_reg): Don't cache value read into inferior data.
911 (riscv_new_inferior_data): Delete.
912 (riscv_inferior_data_cleanup): Delete.
913 (riscv_inferior_data): Delete.
914 (riscv_invalidate_inferior_data): Delete.
915 (_initialize_riscv_tdep): Remove initialisation of inferior data.
917 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
919 * compile/compile-cplus-types.c
920 (compile_cplus_instance::leave_scope): Take the address of scope
922 (compile_cplus_instance::convert_qualified_base): Compare quals
925 2018-08-30 Keith Seitz <keiths@redhat.com>
927 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
928 Use "%s" and host_address_to_string instead of "%p" in printf.
930 2018-08-29 Keith Seitz <keiths@redhat.com>
932 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
933 and compile-cplus-types.c.
934 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
935 * c-lang.c (cplus_language_defn): Set C++ compile functions.
936 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
938 * compile/compile-c-support.c: Include compile-cplus.h.
939 (load_libcompile): Templatize.
940 (get_compile_context): "New" function.
941 (c_get_compile_context): Use get_compile_context.
942 (cplus_get_compile_context): New function.
943 (cplus_push_user_expression, cplus_pop_user_expression)
944 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
945 (cplus_compute_program): Define new structs/functions.
946 * compile/compile-cplus-symmbols.c: New file.
947 * compile/compile-cplus-types.c: New file.
948 * compile/compile-cplus.h: New file.
949 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
951 * compile/compile-object-load.c (get_out_value_type): Use
952 strncmp_iw when comparing symbol names.
953 (compile_object_load): Add mst_bss and mst_data.
954 * compile/compile.c (_initialize_compile): Remove
955 -Wno-implicit-function-declaration from `compile_args'.
956 * compile/gcc-cp-plugin.h: New file.
957 * NEWS: Mention C++ compile support and new debug options.
959 2018-08-29 Keith Seitz <keiths@redhat.com>
961 * linespec.c (collect_info::add_symbol): Make virtual.
962 (struct symbol_searcher_collect_info): New struct.
963 (symbol_searcher::find_all_symbols): New method.
964 * symtab.h (class symbol_searcher): New class.
966 2018-08-29 Keith Seitz <keiths@redhat.com>
968 * linespec.c (struct linespec) <function_symbols, label_symbols>:
969 Change to vector of block_symbol. Update all users.
970 (struct collect_info) <symbols>: Likewise.
971 (collect_info::add_symbol): Take block_symbol as argument.
973 (decode_compound_collector) <m_symbols>: Change type to vector
974 of block_symbol. Update all users.
975 (decode_compound_collector::operator ()): Change parameter type
977 (find_method, find_function_symbols, find_linespec_symbols)
978 (find_label_symbols_in_block, find_label_symbols): Change symbol
979 vectors to block_symbol vectors.
980 * symtab.h (symbol_found_callback_ftype): Change parameter type to
983 2018-08-29 Keith Seitz <keiths@redhat.com>
985 * linespec.c (symbolp): Remove typedef and VEC definitions.
986 (bound_minimal_symbol_d): Likewise.
988 2018-08-29 Keith Seitz <keiths@redhat.com>
990 * linespec.c (decode_compound_collector::decode_compound_collector):
991 Remove initialization for `m_symtabs'.
992 (decode_compound_collector::release_symbols): Change return type
993 to std::vector. Update all callers.
994 (class decode_compound_collector) <m_symbols>: Change type to
996 (lookup_prefix_sym): Change return type to std::vector. Update all
998 (compare_symbols): Remove.
999 (std_compare_symbols): Rename to `compare_symbols'.
1000 (find_method): Change `sym_classes' parameter to std::vector.
1001 Update all callers. Use std::sort to sort sym_classes.
1002 (find_linespec_symbols): Remove cleanup.
1004 2018-08-29 Keith Seitz <keiths@redhat.com>
1006 * linespec.c (struct linespec) <minimal_symbols>: Change type to
1007 std::vector. Update all users.
1008 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
1009 (struct collect_info) <minimal_symbols>: Likewise.
1010 (compare_msymbols): Return bool. Change parameters to const
1011 bound_minimal_symbol references.
1012 (find_method, find_function_symbols, find_linespec_symbols): Change
1013 `minsyms' parameter to std::vector. Update all callers.
1015 2018-08-29 Keith Seitz <keiths@redhat.com>
1017 * linespec.c (struct linespec) <label_symbols>: Change type to
1018 std::vector. Update all users.
1019 (find_label_symbols_in_block): Change `result' parameter to
1020 std::vector. Update all callers.
1021 (find_label_symbols): Return std::vector. Update all callers.
1023 2018-08-29 Keith Seitz <keiths@redhat.com>
1025 * linespec.c (struct linespec) <function_symbols>: Change type to
1026 std::vector. Update all users.
1027 (struct collect_info) <function_symbols>: Likewise.
1028 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
1029 (std_compare_symbols): New function.
1030 (find_method, find_function_symbols, find_linespec_symbols)
1031 (find_label_symbols_in_block): Change `symbols' parameter to
1032 std::vector. Update all callers.
1033 (find_label_symbols): Likewise for `function_symbols' and
1036 2018-08-29 Keith Seitz <keiths@redhat.com>
1038 * linespec.c (symtab_vector_up): Define.
1039 (struct linespec) <file_symtabs>: Change type to std::vector *.
1041 (struct collect_info) <file_symtabs>: Likewise.
1042 (collect_symtabs_from_filename): Return symtab_vector_up.
1044 (decode_objc): Remove cleanup.
1045 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
1046 (symtab_collector::release_symtabs): Return symtab_vector_up.
1048 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
1050 (collect_symtabs_from_filename, symtabs_from_filename): Return
1051 symtab_vector_up. Update all callers.
1053 2018-08-29 Tom Tromey <tom@tromey.com>
1055 * csky-tdep.c (csky_analyze_prologue): Use
1056 core_addr_to_string_nz.
1058 2018-08-29 Tom Tromey <tom@tromey.com>
1060 * windows-nat.c (struct xlate_exception) <them>: Change type to
1062 (xlate): Fix formatting. Remove last entry.
1063 (struct xlate_exception, xlate): Comment out.
1064 (windows_nat_target::resume): Use ranged for.
1066 2018-08-29 Jim Wilson <jimw@sifive.com>
1068 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
1069 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
1071 (riscv_linux_nat_target::store_registers): Likewise.
1073 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
1077 * gnulib/aclocal.m4: Regenerate.
1078 * gnulib/config.in: Regenerate.
1079 * gnulib/configure: Regenerate.
1080 * gnulib/import/Makefile.am: Update.
1081 * gnulib/import/Makefile.in: Update.
1082 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
1083 * gnulib/import/_Noreturn.h: ... this.
1084 * gnulib/import/alloca.in.h: Update.
1085 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
1086 * gnulib/import/arg-nonnull.h: ... this.
1087 * gnulib/import/assure.h: Update.
1088 * gnulib/import/at-func.c: Update.
1089 * gnulib/import/basename-lgpl.c: Update.
1090 * gnulib/import/extra/snippet/c++defs.h: Rename to...
1091 * gnulib/import/c++defs.h: ... this.
1092 * gnulib/import/canonicalize-lgpl.c: Update.
1093 * gnulib/import/cdefs.h: Update.
1094 * gnulib/import/chdir-long.c: Update.
1095 * gnulib/import/chdir-long.h: Update.
1096 * gnulib/import/cloexec.c: Update.
1097 * gnulib/import/cloexec.h: Update.
1098 * gnulib/import/close.c: Update.
1099 * gnulib/import/closedir.c: Update.
1100 * gnulib/import/config.charset: Update.
1101 * gnulib/import/dirent-private.h: Update.
1102 * gnulib/import/dirent.in.h: Update.
1103 * gnulib/import/dirfd.c: Update.
1104 * gnulib/import/dirname-lgpl.c: Update.
1105 * gnulib/import/dirname.h: Update.
1106 * gnulib/import/dosname.h: Update.
1107 * gnulib/import/dup-safer-flag.c: Update.
1108 * gnulib/import/dup-safer.c: Update.
1109 * gnulib/import/dup.c: Update.
1110 * gnulib/import/dup2.c: Update.
1111 * gnulib/import/errno.in.h: Update.
1112 * gnulib/import/error.c: Update.
1113 * gnulib/import/error.h: Update.
1114 * gnulib/import/exitfail.c: Update.
1115 * gnulib/import/exitfail.h: Update.
1116 * gnulib/import/extra/update-copyright: Update.
1117 * gnulib/import/fchdir.c: Update.
1118 * gnulib/import/fcntl.c: Update.
1119 * gnulib/import/fcntl.in.h: Update.
1120 * gnulib/import/fd-hook.c: Update.
1121 * gnulib/import/fd-hook.h: Update.
1122 * gnulib/import/fd-safer-flag.c: Update.
1123 * gnulib/import/fd-safer.c: Update.
1124 * gnulib/import/fdopendir.c: Update.
1125 * gnulib/import/filename.h: Update.
1126 * gnulib/import/filenamecat-lgpl.c: Update.
1127 * gnulib/import/filenamecat.h: Update.
1128 * gnulib/import/flexmember.h: Update.
1129 * gnulib/import/float+.h: Update.
1130 * gnulib/import/float.c: Update.
1131 * gnulib/import/float.in.h: Update.
1132 * gnulib/import/fnmatch.c: Update.
1133 * gnulib/import/fnmatch.in.h: Update.
1134 * gnulib/import/fnmatch_loop.c: Update.
1135 * gnulib/import/fpucw.h: Update.
1136 * gnulib/import/frexp.c: Update.
1137 * gnulib/import/frexpl.c: Update.
1138 * gnulib/import/fstat.c: Update.
1139 * gnulib/import/fstatat.c: Update.
1140 * gnulib/import/getcwd-lgpl.c: Update.
1141 * gnulib/import/getcwd.c: Update.
1142 * gnulib/import/getdtablesize.c: Update.
1143 * gnulib/import/getlogin_r.c: Update.
1144 * gnulib/import/getprogname.c: Update.
1145 * gnulib/import/getprogname.h: Update.
1146 * gnulib/import/gettext.h: Update.
1147 * gnulib/import/gettimeofday.c: Update.
1148 * gnulib/import/glob-libc.h: Update.
1149 * gnulib/import/glob.c: Update.
1150 * gnulib/import/glob.in.h: Update.
1151 * gnulib/import/glob_internal.h: Update.
1152 * gnulib/import/glob_pattern_p.c: Update.
1153 * gnulib/import/globfree.c: Update.
1154 * gnulib/import/hard-locale.c: Update.
1155 * gnulib/import/hard-locale.h: Update.
1156 * gnulib/import/intprops.h: Update.
1157 * gnulib/import/inttypes.in.h: Update.
1158 * gnulib/import/isnan.c: Update.
1159 * gnulib/import/isnand-nolibm.h: Update.
1160 * gnulib/import/isnand.c: Update.
1161 * gnulib/import/isnanl-nolibm.h: Update.
1162 * gnulib/import/isnanl.c: Update.
1163 * gnulib/import/itold.c: Update.
1164 * gnulib/import/libc-config.h: Update.
1165 * gnulib/import/limits.in.h: Update.
1166 * gnulib/import/localcharset.c: Update.
1167 * gnulib/import/localcharset.h: Update.
1168 * gnulib/import/localtime-buffer.c: Update.
1169 * gnulib/import/localtime-buffer.h: Update.
1170 * gnulib/import/lstat.c: Update.
1171 * gnulib/import/m4/00gnulib.m4: Update.
1172 * gnulib/import/m4/__inline.m4: Update.
1173 * gnulib/import/m4/absolute-header.m4: Update.
1174 * gnulib/import/m4/alloca.m4: Update.
1175 * gnulib/import/m4/builtin-expect.m4: Update.
1176 * gnulib/import/m4/canonicalize.m4: Update.
1177 * gnulib/import/m4/chdir-long.m4: Update.
1178 * gnulib/import/m4/close.m4: Update.
1179 * gnulib/import/m4/closedir.m4: Update.
1180 * gnulib/import/m4/configmake.m4: Update.
1181 * gnulib/import/m4/d-ino.m4: Update.
1182 * gnulib/import/m4/d-type.m4: Update.
1183 * gnulib/import/m4/dirent_h.m4: Update.
1184 * gnulib/import/m4/dirfd.m4: Update.
1185 * gnulib/import/m4/dirname.m4: Update.
1186 * gnulib/import/m4/double-slash-root.m4: Update.
1187 * gnulib/import/m4/dup.m4: Update.
1188 * gnulib/import/m4/dup2.m4: Update.
1189 * gnulib/import/m4/eealloc.m4: Update.
1190 * gnulib/import/m4/environ.m4: Update.
1191 * gnulib/import/m4/errno_h.m4: Update.
1192 * gnulib/import/m4/error.m4: Update.
1193 * gnulib/import/m4/exponentd.m4: Update.
1194 * gnulib/import/m4/exponentl.m4: Update.
1195 * gnulib/import/m4/extensions.m4: Update.
1196 * gnulib/import/m4/extern-inline.m4: Update.
1197 * gnulib/import/m4/fchdir.m4: Update.
1198 * gnulib/import/m4/fcntl-o.m4: Update.
1199 * gnulib/import/m4/fcntl.m4: Update.
1200 * gnulib/import/m4/fcntl_h.m4: Update.
1201 * gnulib/import/m4/fdopendir.m4: Update.
1202 * gnulib/import/m4/filenamecat.m4: Update.
1203 * gnulib/import/m4/flexmember.m4: Update.
1204 * gnulib/import/m4/float_h.m4: Update.
1205 * gnulib/import/m4/fnmatch.m4: Update.
1206 * gnulib/import/m4/fnmatch_h.m4: Update.
1207 * gnulib/import/m4/fpieee.m4: Update.
1208 * gnulib/import/m4/frexp.m4: Update.
1209 * gnulib/import/m4/frexpl.m4: Update.
1210 * gnulib/import/m4/fstat.m4: Update.
1211 * gnulib/import/m4/fstatat.m4: Update.
1212 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
1213 * gnulib/import/m4/getcwd-path-max.m4: Update.
1214 * gnulib/import/m4/getcwd.m4: Update.
1215 * gnulib/import/m4/getdtablesize.m4: Update.
1216 * gnulib/import/m4/getlogin.m4: Update.
1217 * gnulib/import/m4/getlogin_r.m4: Update.
1218 * gnulib/import/m4/getpagesize.m4: Update.
1219 * gnulib/import/m4/getprogname.m4: Update.
1220 * gnulib/import/m4/gettimeofday.m4: Update.
1221 * gnulib/import/m4/glibc21.m4: Update.
1222 * gnulib/import/m4/glob.m4: Update.
1223 * gnulib/import/m4/glob_h.m4: Update.
1224 * gnulib/import/m4/gnulib-cache.m4: Update.
1225 * gnulib/import/m4/gnulib-common.m4: Update.
1226 * gnulib/import/m4/gnulib-comp.m4: Update.
1227 * gnulib/import/m4/gnulib-tool.m4: Update.
1228 * gnulib/import/m4/hard-locale.m4: Update.
1229 * gnulib/import/m4/include_next.m4: Update.
1230 * gnulib/import/m4/inttypes-pri.m4: Update.
1231 * gnulib/import/m4/inttypes.m4: Update.
1232 * gnulib/import/m4/isnand.m4: Update.
1233 * gnulib/import/m4/isnanl.m4: Update.
1234 * gnulib/import/m4/largefile.m4: Update.
1235 * gnulib/import/m4/limits-h.m4: Update.
1236 * gnulib/import/m4/localcharset.m4: Update.
1237 * gnulib/import/m4/locale-fr.m4: Update.
1238 * gnulib/import/m4/locale-ja.m4: Update.
1239 * gnulib/import/m4/locale-zh.m4: Update.
1240 * gnulib/import/m4/localtime-buffer.m4: Update.
1241 * gnulib/import/m4/longlong.m4: Update.
1242 * gnulib/import/m4/lstat.m4: Update.
1243 * gnulib/import/m4/malloc.m4: Update.
1244 * gnulib/import/m4/malloca.m4: Update.
1245 * gnulib/import/m4/math_h.m4: Update.
1246 * gnulib/import/m4/mbrtowc.m4: Update.
1247 * gnulib/import/m4/mbsinit.m4: Update.
1248 * gnulib/import/m4/mbsrtowcs.m4: Update.
1249 * gnulib/import/m4/mbstate_t.m4: Update.
1250 * gnulib/import/m4/memchr.m4: Update.
1251 * gnulib/import/m4/memmem.m4: Update.
1252 * gnulib/import/m4/mempcpy.m4: Update.
1253 * gnulib/import/m4/memrchr.m4: Update.
1254 * gnulib/import/m4/mkdir.m4: Update.
1255 * gnulib/import/m4/mkstemp.m4: Update.
1256 * gnulib/import/m4/mmap-anon.m4: Update.
1257 * gnulib/import/m4/mode_t.m4: Update.
1258 * gnulib/import/m4/msvc-inval.m4: Update.
1259 * gnulib/import/m4/msvc-nothrow.m4: Update.
1260 * gnulib/import/m4/multiarch.m4: Update.
1261 * gnulib/import/m4/nocrash.m4: Update.
1262 * gnulib/import/m4/off_t.m4: Update.
1263 * gnulib/import/m4/onceonly.m4: Update.
1264 * gnulib/import/m4/open-cloexec.m4: Update.
1265 * gnulib/import/m4/open.m4: Update.
1266 * gnulib/import/m4/openat.m4: Update.
1267 * gnulib/import/m4/opendir.m4: Update.
1268 * gnulib/import/m4/pathmax.m4: Update.
1269 * gnulib/import/m4/rawmemchr.m4: Update.
1270 * gnulib/import/m4/readdir.m4: Update.
1271 * gnulib/import/m4/readlink.m4: Update.
1272 * gnulib/import/m4/realloc.m4: Update.
1273 * gnulib/import/m4/rename.m4: Update.
1274 * gnulib/import/m4/rewinddir.m4: Update.
1275 * gnulib/import/m4/rmdir.m4: Update.
1276 * gnulib/import/m4/save-cwd.m4: Update.
1277 * gnulib/import/m4/secure_getenv.m4: Update.
1278 * gnulib/import/m4/setenv.m4: Update.
1279 * gnulib/import/m4/signal_h.m4: Update.
1280 * gnulib/import/m4/ssize_t.m4: Update.
1281 * gnulib/import/m4/stat-time.m4: Update.
1282 * gnulib/import/m4/stat.m4: Update.
1283 * gnulib/import/m4/std-gnu11.m4: Update.
1284 * gnulib/import/m4/stdbool.m4: Update.
1285 * gnulib/import/m4/stddef_h.m4: Update.
1286 * gnulib/import/m4/stdint.m4: Update.
1287 * gnulib/import/m4/stdio_h.m4: Update.
1288 * gnulib/import/m4/stdlib_h.m4: Update.
1289 * gnulib/import/m4/strchrnul.m4: Update.
1290 * gnulib/import/m4/strdup.m4: Update.
1291 * gnulib/import/m4/strerror.m4: Update.
1292 * gnulib/import/m4/string_h.m4: Update.
1293 * gnulib/import/m4/strstr.m4: Update.
1294 * gnulib/import/m4/strtok_r.m4: Update.
1295 * gnulib/import/m4/sys_socket_h.m4: Update.
1296 * gnulib/import/m4/sys_stat_h.m4: Update.
1297 * gnulib/import/m4/sys_time_h.m4: Update.
1298 * gnulib/import/m4/sys_types_h.m4: Update.
1299 * gnulib/import/m4/tempname.m4: Update.
1300 * gnulib/import/m4/time_h.m4: Update.
1301 * gnulib/import/m4/unistd-safer.m4: Update.
1302 * gnulib/import/m4/unistd_h.m4: Update.
1303 * gnulib/import/m4/warn-on-use.m4: Update.
1304 * gnulib/import/m4/wchar_h.m4: Update.
1305 * gnulib/import/m4/wchar_t.m4: Update.
1306 * gnulib/import/m4/wctype_h.m4: Update.
1307 * gnulib/import/m4/wint_t.m4: Update.
1308 * gnulib/import/malloc.c: Update.
1309 * gnulib/import/malloc/scratch_buffer.h: Update.
1310 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
1311 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
1312 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
1313 * gnulib/import/malloca.c: Update.
1314 * gnulib/import/malloca.h: Update.
1315 * gnulib/import/malloca.valgrind: Update.
1316 * gnulib/import/math.in.h: Update.
1317 * gnulib/import/mbrtowc.c: Update.
1318 * gnulib/import/mbsinit.c: Update.
1319 * gnulib/import/mbsrtowcs-impl.h: Update.
1320 * gnulib/import/mbsrtowcs-state.c: Update.
1321 * gnulib/import/mbsrtowcs.c: Update.
1322 * gnulib/import/memchr.c: Update.
1323 * gnulib/import/memmem.c: Update.
1324 * gnulib/import/mempcpy.c: Update.
1325 * gnulib/import/memrchr.c: Update.
1326 * gnulib/import/mkdir.c: Update.
1327 * gnulib/import/mkstemp.c: Update.
1328 * gnulib/import/msvc-inval.c: Update.
1329 * gnulib/import/msvc-inval.h: Update.
1330 * gnulib/import/msvc-nothrow.c: Update.
1331 * gnulib/import/msvc-nothrow.h: Update.
1332 * gnulib/import/open.c: Update.
1333 * gnulib/import/openat-die.c: Update.
1334 * gnulib/import/openat-priv.h: Update.
1335 * gnulib/import/openat-proc.c: Update.
1336 * gnulib/import/openat.c: Update.
1337 * gnulib/import/openat.h: Update.
1338 * gnulib/import/opendir.c: Update.
1339 * gnulib/import/pathmax.h: Update.
1340 * gnulib/import/pipe-safer.c: Update.
1341 * gnulib/import/rawmemchr.c: Update.
1342 * gnulib/import/readdir.c: Update.
1343 * gnulib/import/readlink.c: Update.
1344 * gnulib/import/realloc.c: Update.
1345 * gnulib/import/ref-add.sin: Update.
1346 * gnulib/import/ref-del.sin: Update.
1347 * gnulib/import/rename.c: Update.
1348 * gnulib/import/rewinddir.c: Update.
1349 * gnulib/import/rmdir.c: Update.
1350 * gnulib/import/same-inode.h: Update.
1351 * gnulib/import/save-cwd.c: Update.
1352 * gnulib/import/save-cwd.h: Update.
1353 * gnulib/import/scratch_buffer.h: Update.
1354 * gnulib/import/secure_getenv.c: Update.
1355 * gnulib/import/setenv.c: Update.
1356 * gnulib/import/signal.in.h: Update.
1357 * gnulib/import/stat-time.c: Update.
1358 * gnulib/import/stat-time.h: Update.
1359 * gnulib/import/stat-w32.c: Update.
1360 * gnulib/import/stat-w32.h: Update.
1361 * gnulib/import/stat.c: Update.
1362 * gnulib/import/stdbool.in.h: Update.
1363 * gnulib/import/stddef.in.h: Update.
1364 * gnulib/import/stdint.in.h: Update.
1365 * gnulib/import/stdio.in.h: Update.
1366 * gnulib/import/stdlib.in.h: Update.
1367 * gnulib/import/str-two-way.h: Update.
1368 * gnulib/import/strchrnul.c: Update.
1369 * gnulib/import/strdup.c: Update.
1370 * gnulib/import/streq.h: Update.
1371 * gnulib/import/strerror-override.c: Update.
1372 * gnulib/import/strerror-override.h: Update.
1373 * gnulib/import/strerror.c: Update.
1374 * gnulib/import/string.in.h: Update.
1375 * gnulib/import/stripslash.c: Update.
1376 * gnulib/import/strnlen1.c: Update.
1377 * gnulib/import/strnlen1.h: Update.
1378 * gnulib/import/strstr.c: Update.
1379 * gnulib/import/strtok_r.c: Update.
1380 * gnulib/import/sys_stat.in.h: Update.
1381 * gnulib/import/sys_time.in.h: Update.
1382 * gnulib/import/sys_types.in.h: Update.
1383 * gnulib/import/tempname.c: Update.
1384 * gnulib/import/tempname.h: Update.
1385 * gnulib/import/time.in.h: Update.
1386 * gnulib/import/unistd--.h: Update.
1387 * gnulib/import/unistd-safer.h: Update.
1388 * gnulib/import/unistd.in.h: Update.
1389 * gnulib/import/unsetenv.c: Update.
1390 * gnulib/import/verify.h: Update.
1391 * gnulib/import/extra/snippet/warn-on-use.h: Update.
1392 * gnulib/import/wchar.in.h: Update.
1393 * gnulib/import/wctype.in.h: Update.
1394 * gnulib/import/xalloc-oversized.h: Update.
1395 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
1396 "53e2c179f26a890fa6685af4b6c1397ee370433b".
1398 2018-08-16 Gary Benson <gbenson@redhat.com>
1401 * gdb/main.c (captured_main_1): Exit with nonzero status
1402 in batch mode if the last command to be executed failed.
1403 * NEWS: Mention the above.
1405 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
1407 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
1408 end of warning message.
1410 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1413 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
1414 (aarch64_extract_return_value): Use
1415 aapcs_is_vfp_call_or_return_candidate.
1416 (aarch64_return_in_memory): Likewise.
1417 (aarch64_store_return_value): Likewise.
1419 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1422 (aapcs_is_vfp_call_or_return_candidate): Make static
1423 (pass_in_v_or_stack): Remove function.
1424 (pass_in_v_vfp_candidate): New function.
1425 (aarch64_push_dummy_call): Check for float register candidates.
1427 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1429 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
1430 (aapcs_is_vfp_call_or_return_candidate_1): New function.
1431 (aapcs_is_vfp_call_or_return_candidate): Likewise.
1433 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
1436 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
1437 (struct ipa_sym_addresses): Rename to...
1438 (struct ipa_sym_addresses_common): ... this.
1439 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
1441 2018-08-28 Tom Tromey <tom@tromey.com>
1443 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1444 (token_fifo): Now a std::vector.
1445 (yylex, c_parse): Update.
1446 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1447 (token_fifo): Now a std::vector.
1448 (yylex, d_parse): Update.
1449 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1450 (token_fifo): Now a std::vector.
1451 (yylex, go_parse): Update.
1453 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
1455 * parser-defs.h (struct type_stack) <elements>: Change type to
1456 std::vector<union type_stack_elt>.
1457 <depth, size>: Remove.
1458 * parse.c (parse_exp_in_context_1): Adjust.
1459 (type_stack_reserve): Remove.
1460 (check_type_stack_depth): Remove.
1461 (insert_into_type_stack): Adjust to std::vector.
1462 (insert_type): Likewise.
1463 (push_type): Likewise.
1464 (push_type_int): Likewise.
1465 (insert_type_address_space): Likewise.
1466 (pop_type): Likewise.
1467 (pop_type_int): Likewise.
1468 (pop_typelist): Likewise.
1469 (pop_type_stack): Likewise.
1470 (append_type_stack): Likewise.
1471 (push_type_stack): Likewise.
1472 (get_type_stack): Likewise.
1473 (type_stack_cleanup): Likewise.
1474 (push_typelist): Likewise.
1475 (follow_types): Likewise.
1476 (_initialize_parse): Likewise.
1478 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
1480 * NEWS: Mention csky target.
1482 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
1483 Hafiz Abid Qadeer <abidh@codesourcery.com>
1484 Don Breazeal <donb@codesourcery.com>
1486 * csky-linux-tdep.c: New file.
1487 * csky-tdep.c: Likewise.
1488 * csky-tdep.h: Likewise.
1489 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
1491 (HFILES_NO_SRCDIR): Add csky-tdep.h.
1492 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
1493 * configure.tgt: Add csky support.
1495 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
1497 * python/py-framefilter.c (py_print_frame): Print frame architecture
1498 when printing on an MI output.
1500 2018-08-27 Tom Tromey <tom@tromey.com>
1503 * configure: Rebuild.
1504 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
1506 2018-08-27 Tom Tromey <tom@tromey.com>
1508 * aarch64-linux-tdep.c
1509 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
1512 2018-08-27 Tom Tromey <tom@tromey.com>
1514 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
1516 (ppc64_standard_linkage1, ppc64_standard_linkage2)
1517 (ppc64_standard_linkage3, ppc64_standard_linkage4)
1518 (ppc64_standard_linkage5, ppc64_standard_linkage6)
1519 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
1522 2018-08-27 Tom Tromey <tom@tromey.com>
1524 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
1525 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
1527 2018-08-27 Tom Tromey <tom@tromey.com>
1529 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
1530 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
1532 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
1534 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
1536 * sparc-linux-tdep.c (sparc32_linux_sigframe)
1537 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
1538 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
1540 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
1541 (ppc64_linux_sigaction_tramp_frame)
1542 (ppc32_linux_sighandler_tramp_frame)
1543 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1544 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
1545 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
1546 * mn10300-linux-tdep.c (am33_linux_sigframe)
1547 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
1548 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
1549 * mips-linux-tdep.c (mips_linux_o32_sigframe)
1550 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
1551 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
1552 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
1553 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
1554 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
1555 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
1556 * microblaze-linux-tdep.c
1557 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1558 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
1559 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
1560 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
1561 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
1562 * common/common-types.h (ULONGEST_MAX): New define.
1563 (CORE_ADDR_MAX): Fix formatting.
1564 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
1565 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
1566 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
1567 (arm_linux_rt_sigreturn_tramp_frame)
1568 (arm_eabi_linux_sigreturn_tramp_frame)
1569 (arm_eabi_linux_rt_sigreturn_tramp_frame)
1570 (thumb2_eabi_linux_sigreturn_tramp_frame)
1571 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
1572 (arm_linux_restart_syscall_tramp_frame)
1573 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
1574 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
1575 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
1577 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
1579 2018-08-27 Tom Tromey <tom@tromey.com>
1581 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
1583 * mips-tdep.c (mips_deal_with_atomic_sequence)
1584 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
1585 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
1586 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
1587 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
1589 * aarch64-tdep.c (aarch64_software_single_step): Use
1592 2018-08-27 Tom Tromey <tom@tromey.com>
1594 * linespec.c (complete_linespec_component): Add cast to "char".
1595 * completer.c (completion_tracker::build_completion_result): Add
1598 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1600 * solist.h (struct solist, struct target_so_ops): Fix
1603 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1605 * ada-tasks.c (ada_task_info_s): Remove typedef.
1606 (DEF_VEC_O(ada_task_info_s)): Remove.
1607 (struct ada_tasks_inferior_data): Initialize fields.
1608 <task_list>: Make an std::vector.
1609 (get_ada_tasks_inferior_data): Allocate with new.
1610 (ada_get_task_number): Adjust.
1611 (get_task_number_from_id): Likewise.
1612 (valid_task_id): Likewise.
1613 (ada_get_task_info_from_ptid): Likewise.
1614 (iterate_over_live_ada_tasks): Likewise.
1615 (add_ada_task): Likewise.
1616 (read_known_tasks): Likewise.
1617 (ada_build_task_list): Likewise.
1618 (print_ada_task_info): Likewise.
1619 (info_task): Likewise.
1620 (task_command_1): Likewise.
1622 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1624 * ada-lang.c (add_angle_brackets): Return std::string.
1626 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
1628 * python/py-threadevent.c (py_get_event_thread): Initialize
1631 2018-08-24 Pedro Alves <palves@redhat.com>
1633 * python/py-bpevent.c (create_breakpoint_event_object): Use
1634 copy-initialization.
1635 * python/py-continueevent.c (emit_continue_event): Use
1636 copy-initialization.
1637 * python/py-exitedevent.c (create_exited_event_object): Return a
1639 (emit_exited_event): Use copy-initialization.
1640 * python/py-inferior.c (python_new_inferior)
1641 (python_inferior_deleted, add_thread_object): Use
1642 copy-initialization.
1643 * python/py-infevents.c (create_inferior_call_event_object)
1644 (create_register_changed_event_object)
1645 (create_memory_changed_event_object): Return a gdbpy_ref<>.
1646 (emit_inferior_call_event, emit_memory_changed_event)
1647 (emit_register_changed_event): Use copy-initialization.
1648 * python/py-newobjfileevent.c (create_new_objfile_event_object):
1649 Return a gdbpy_ref<>.
1650 (emit_new_objfile_event): Use copy-initialization.
1651 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
1652 (emit_clear_objfiles_event): Use copy-initialization.
1653 * python/py-signalevent.c (create_signal_event_object): Use
1654 copy-initialization.
1655 * python/py-threadevent.c (create_thread_event_object): Use
1656 copy-initialization.
1658 2018-08-24 Pedro Alves <palves@redhat.com>
1659 Simon Marchi <simon.marchi@ericsson.com>
1662 * python/py-continueevent.c: Include "gdbthread.h".
1663 (create_continue_event_object): Add intro comment. Add 'ptid'
1664 parameter. Use it to find thread to pass to
1665 create_thread_event_object.
1666 (emit_continue_event): Pass PTID down to
1667 create_continue_event_object.
1668 * python/py-event.h (py_get_event_thread): Declare.
1669 (create_thread_event_object): Remove default from 'thread'
1671 * python/py-stopevent.c (create_stop_event_object): Use
1672 py_get_event_thread.
1673 * python/py-threadevent.c (get_event_thread): Rename to ...
1674 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
1675 and use it to find the thread.
1676 (create_thread_event_object): Assert that THREAD isn't null.
1677 Don't find the event thread here.
1679 2018-08-23 Kevin Buettner <kevinb@redhat.com>
1681 * block.h (blockrange, blockranges): New struct declarations.
1682 (struct block): Add new field named `ranges'.
1683 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
1684 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
1685 macros for accessing ranges in struct block.
1686 (make_blockranges): New declaration.
1687 block.c (make_blockranges): New function.
1688 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
1690 * symtab.h (find_pc_partial_function): Add new parameter `block'.
1691 * blockframe.c (cache_pc_function_block): New static global.
1692 (clear_pc_function_cache): Clear cache_pc_function_block.
1693 (find_pc_partial_function): Move comment to symtab.h. Add
1694 support for non-contiguous blocks.
1695 * cli/cli-cmds.c (block.h): Include.
1696 (print_disassembly): Handle printing of non-contiguous blocks.
1697 (disassemble_current_function): Likewise.
1698 (disassemble_command): Likewise.
1700 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
1702 * blockframe.c (get_pc_function_start): Likewise.
1703 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
1704 (gcc_symbol_address): Likewise.
1705 * compile/compile-object-run.c (compile_object_run): Likewise.
1706 * compile/compile.c (get_expr_block_and_pc): Likewise.
1707 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
1708 (func_addr_to_tail_call_list): Likewise.
1709 * findvar.c (default_read_var_value): Likewise.
1710 * inline-frame.c (inline_frame_this_id): Likewise.
1711 (skip-inline_frames): Likewise.
1712 * infcmd.c (until_next_command): Likewise.
1713 * linespec.c (convert_linespec_to_sals): Likewise.
1714 * parse.c (parse_exp_in_context_1): Likewise.
1715 * printcmd.c (build_address_symbolic): likewise.
1716 (info_address_command): Likewise.
1717 symtab.c (find_function_start_sal): Likewise.
1718 (skip_prologue_sal): Likewise.
1719 (find_function_alias_target): Likewise.
1720 (find_gnu_ifunc): Likewise.
1721 * stack.c (find_frame_funname): Likewise.
1722 * symtab.c (fixup_symbol_section): Likewise.
1723 (find_function_start_sal): Likewise.
1724 (skip_prologue_sal): Likewsie.
1725 (find_function_alias_target): Likewise.
1726 (find_gnu_ifunc): Likewise.
1727 * tracepoint.c (info_scope_command): Likewise.
1728 * value.c (value_fn_field): Likewise.
1730 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
1731 in place of find_pc_partial_function.
1732 * blockframe.c (find_function_entry_range_from_pc): New function.
1733 * symtab.h (find_function_entry_range_from_pc): Declare and document.
1734 * objfiles.c (objfile_relocate1): Relocate start and end addresses
1735 for each range in a block.
1738 2018-08-23 Xavier Roirand <roirand@adacore.com>
1740 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
1743 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1745 * solib-svr4.c (read_program_headers_from_bfd): Return
1746 gdb::optional<gdb::byte_vector>.
1747 (svr4_exec_displacement): Adjust.
1749 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1751 * solib-svr4.c (read_program_header): Return
1752 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
1753 (find_program_interpreter): Return
1754 gdb::optional<gdb::byte_vector>.
1755 (scan_dyntag_auxv): Adjust.
1756 (enable_break): Adjust.
1757 (svr4_exec_displacement): Adjust.
1759 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1761 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
1762 * inf-child.c (inf_child_target::terminal_save_inferior): New.
1764 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1766 * guile/scm-string.c (gdbscm_scm_from_printf): Use
1768 * guile/scm-utils.c (gdbscm_printf): Likewise.
1769 * serial.c (serial_printf): Likewise.
1770 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
1772 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
1774 * stack.c (print_frame): Print frame architecture when printing on
1776 * NEWS: Mention new "arch" attribute in frame output.
1778 2018-08-21 Alan Hayward <alan.hayward@arm.com>
1780 * arch/aarch64.h (aarch64_regnum): Update comment.
1782 2018-08-21 Alan Hayward <alan.hayward@arm.com>
1784 * NEWS: Add SVE to 8.2 section.
1786 2018-08-21 Pedro Alves <palves@redhat.com>
1788 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
1789 out from gdbscm_parse_function_args.
1790 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
1791 gdbscm_parse_function_args_1.
1793 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
1796 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
1799 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
1801 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
1803 2018-08-19 Michael Spang <spang@google.com>
1806 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
1807 for PT_TLS segments.
1809 2018-08-18 Kevin Buettner <kevinb@redhat.com>
1811 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
1812 dwarf_variable_value.
1813 * dwarf2-frame.c (class dwarf_expr_executor):
1814 Add override for dwarf_variable_value.
1815 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
1816 (class symbol_needs_eval_context): Likewise.
1817 (indirect_synthetic_pointer): Add forward declaration.
1818 (sect_variable_value): New function.
1819 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
1820 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
1821 for DW_OP_GNU_variable_value.
1823 2018-08-16 Tom Tromey <tom@tromey.com>
1825 * top.c (read_command_file): Update.
1826 (command_line_input): Remove "repeat" argument.
1827 * ada-lang.c (get_selections): Update.
1828 * linespec.c (decode_line_2): Update.
1829 * defs.h (command_line_input): Remove argument.
1830 * cli/cli-script.c (read_next_line): Update.
1831 * python/py-gdb-readline.c: Update.
1833 2018-08-17 Tom Tromey <tom@tromey.com>
1835 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
1838 2018-08-15 Tom Tromey <tom@tromey.com>
1840 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
1842 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
1844 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
1845 If used, use find_pc_partial_function to find address range
1847 * mi/mi-main.c (mi_cmd_list_features): Report
1848 "data-disassemble-a-option" feature.
1849 * NEWS: Mention new -data-disassemble option -a.
1851 2018-08-13 Tom Tromey <tom@tromey.com>
1853 * common/common-defs.h (_FORTIFY_SOURCE): Define.
1855 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1857 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
1858 (aarch64_linux_collect_sve_regset): Likewise.
1859 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
1860 * regcache.h (regcache_map_entry_size): New function.
1862 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1864 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
1865 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
1866 (SVE_HEADER_VL_LENGTH): Likewise.
1867 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
1868 (SVE_HEADER_FLAGS_LENGTH): Likewise.
1869 (SVE_HEADER_RESERVED_LENGTH): Likewise.
1870 (SVE_HEADER_SIZE_OFFSET): Likewise.
1871 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
1872 (SVE_HEADER_VL_OFFSET): Likewise.
1873 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
1874 (SVE_HEADER_FLAGS_OFFSET): Likewise.
1875 (SVE_HEADER_RESERVED_OFFSET): Likewise.
1876 (SVE_HEADER_SIZE): Likewise.
1877 (aarch64_linux_core_read_vq): Add function.
1878 (aarch64_linux_core_read_description): Check for SVE section.
1880 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1882 * aarch64-fbsd-tdep.c
1883 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
1885 * aarch64-linux-tdep.c
1886 (aarch64_linux_iterate_over_regset_sections): Likewise.
1887 * alpha-linux-tdep.c
1888 (alpha_linux_iterate_over_regset_sections):
1890 (alphanbsd_iterate_over_regset_sections): Likewise.
1892 (amd64fbsd_iterate_over_regset_sections): Likewise.
1893 * amd64-linux-tdep.c
1894 (amd64_linux_iterate_over_regset_sections): Likewise.
1896 (armbsd_iterate_over_regset_sections): Likewise.
1898 (arm_fbsd_iterate_over_regset_sections): Likewise.
1900 (arm_linux_iterate_over_regset_sections): Likewise.
1901 * corelow.c (get_core_registers_cb): Likewise.
1902 (core_target::fetch_registers): Likewise.
1903 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
1904 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
1905 * gdbarch.h (void): Regenerate.
1906 * gdbarch.sh: Add supply_size and collect_size.
1907 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
1908 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
1909 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
1910 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
1911 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
1912 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
1913 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
1914 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
1915 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
1916 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
1917 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
1918 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
1919 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
1920 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
1921 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
1922 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
1923 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
1924 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
1925 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
1926 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
1927 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
1928 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
1929 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
1930 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
1931 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
1932 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
1933 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
1934 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
1935 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
1936 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
1938 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
1940 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
1943 2018-08-10 Keith Seitz <keiths@redhat.com>
1945 * compile/compile-c-support.c (add_code_header, add_code_footer):
1946 Move into policy class.
1947 (c_push_user_expression, pop_user_expression_nop)
1948 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
1949 (compile_program): New host class.
1950 (c_compile_program): New typedef.
1951 (c_compute_porgram): Use c_compile_program.
1953 2018-08-10 Keith Seitz <keiths@redhat.com>
1955 * compile/compile-internal.h (compile_instance::~compile_instance):
1956 Remove calls to htab_delete.
1957 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
1958 * compile.c (compile_instance::compile_instance): Initialize
1959 htab unique pointers.
1960 (compile_instance::get_cached_type, compile_instance::insert_type)
1961 (compile_instance::error_symbol_once): Update for unique_ptr.
1963 2018-08-10 Keith Seitz <keiths@redhat.com>
1965 * compile/compile-c-symbols.c (struct symbol_error)
1966 (hash_symbol_error, eq_symbol_error, del_symbol_error)
1967 (compile_instance::insert_symbol_error)
1968 (compile_instance::error_symbol_once): Move to ...
1969 * compile/compile.c: ... here.
1971 2018-08-10 Keith Seitz <keiths@redhat.com>
1973 * compile/compile-c-support.c (c_get_compile_context): Use `new'
1974 instead of `new_compile_instance'.
1975 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
1977 If the symbol error map is not initialized, create it.
1978 (generate_c_for_for_one_symbol): Do not check/initialize
1979 the symbol error map.
1980 * compile/compile-c-types.c (compile_c_instance): Make a class.
1982 (compile_instance::compile_instance): Initialize the type cache.
1983 (get_cached_type): New function.
1984 (insert_type): Update description.
1985 (compile_c_instance::m_default_cflags): Define.
1986 (convert_type): Update description. Use get_cached_type.
1987 (delete_instance): Moved to destructor.
1988 (new_compile_instance): Moved to constructor.
1989 * compile/compile-c.h (compile_c_instance): Make class inheriting
1990 from compile_instance.
1991 <base>: Remove field.
1992 <type_map, symbol_err_map>: Move to base class.
1993 <c_plugin>: Rename to `m_plugin' and remove pointer type.
1994 * compile/compile-internal.h (compile_instance): Make class.
1995 <type_map_t, symbol_err_map_t>: Define.
1996 <fe>: Rename to `m_gcc_fe'.
1997 <scope, block, gcc_target_options>: Add `m_' prefix.
1998 <m_type_map, m_symbol_err_map>: New fields, moved from
2001 (convert_type, new_compile_instance): Remove.
2002 * compile/compile.c (cleanup_compile_instance): Remove.
2003 (compile_to_object): Use unique_ptr to eliminate cleanups.
2004 (compile_instance::set_print_callback, compile_instance::version)
2005 (compile_instance::set_verbose)
2006 (compile_instance::set_driver_filename)
2007 (compile_instance::set_triplet_regexp)
2008 (compile_instance::set_arguments)
2009 (compile_instance::set_source_file)
2010 (compile_instance::compile): Define.
2012 2018-08-10 Keith Seitz <keiths@redhat.com>
2014 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
2015 * compile/compile-c-types.c: Define GCC_METHODN macros and include
2016 gcc-c-fe.def to define C plugin.
2017 (delete_instance): Delete `c_plugin'.
2018 (new_compile_instance): Initialize `c_plugin'.
2019 * compile/compile-c.h: Include gcc_c_plugin.h.
2020 (struct compile_c_instance) <c_plugin>: New member.
2021 * gcc-c-plugin.h: New file.
2022 Update all callers with API change.
2024 2018-08-10 Keith Seitz <keiths@redhat.com>
2026 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
2027 (HFILES_NO_SRCDIR): ... to here.
2028 Add compile-internal.h and compile-c.h.
2029 * compile/compile-c-support.c: Include compile-c.h.
2030 * compile/compile-c-symbols.c: Include compile-c.h.
2031 (generate_c_for_variable_locations): Update comment.
2032 * compile/compile-c-types.c: Include compile-c.h.
2033 * compile/compile-c.h: New file -- moved C language declarations
2034 from other files here.
2035 * compile/compile-internal.h: Do not include hashtab.h or
2036 common/enum-flags.h.
2037 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
2038 (gcc_convert_symbol, gcc_symbol_address)
2039 (generate_c_for_variable_locations, c_get_mode_for_size)
2040 (c_get_range_decl_name): Definitions moved to compile-c.h.
2041 * compile/compile-loc2c.c: Include compile-c.h.
2043 2018-08-10 Keith Seitz <keiths@redhat.com>
2045 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
2046 (c_symbol_substitution_name): ... this.
2049 2018-08-10 Keith Seitz <keiths@redhat.com>
2051 * compile/compile-c-support.c (c_compute_program): Use
2052 unique_xmalloc_ptr to eliminate cleanup.
2053 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
2054 Return a unique_xmalloc_ptr and eliminate cleanup.
2055 * compile/compile-internal.h (generate_c_for_variable_locations):
2056 Return unique_xmalloc_ptr and update description.
2058 2018-08-10 Alan Hayward <alan.hayward@arm.com>
2060 * corelow.c (core_target::get_core_register_section): Rename
2061 min_size to section_min_size.
2063 2018-08-09 Jim Wilson <jimw@sifive.com>
2065 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
2066 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
2067 * NEWS: Mention new GNU/Linux RISC-V target.
2068 * configure.host: Add riscv*-*-linux*.
2069 * configure.nat: Add riscv*.
2070 * configure.tgt: Add riscv*-*-linux*.
2071 * riscv-linux-nat.c: New file.
2072 * riscv-linux-tdep.c: New file.
2074 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2076 * infrun.c (resume): Make static, add forward declaration.
2077 (proceed): Update header comment.
2078 * infrun.h (resume): Delete declaration.
2080 2018-08-09 Tom Tromey <tom@tromey.com>
2082 * riscv-tdep.h: Minor formatting fixes.
2084 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
2086 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
2087 * dwarf-index-cache.c (create_dir_and_check): Likewise.
2088 (test_mkdir_recursive): Likewise.
2089 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
2091 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2093 * valarith.c (value_subscripted_rvalue): If an array is not in
2094 memory, and we don't know the upper bound, then we can't know that
2095 the requested element exists or not.
2097 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
2099 * target.c (str_comma_list_concat_elem): Fix typo in comment.
2100 (target_options_to_string): Add comment.
2102 2018-08-08 Tom Tromey <tom@tromey.com>
2104 * unittests/scoped_mmap-selftests.c: Check result of "write".
2106 2018-08-08 Jim Wilson <jimw@sifive.com>
2108 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
2109 (decode_register_index_short): New.
2110 (decode_j_type_insn, decode_cj_type_insn): New.
2111 (decode_b_type_insn, decode_cb_type_insn): New.
2112 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
2113 local xlen. Check xlen when decoding ambiguous compressed insns. In
2114 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
2115 is_c_sw_insn instead of is_sw_insn.
2116 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
2117 (riscv_software_single_step): New.
2118 * riscv-tdep.h (riscv_software_single_step): Declare.
2120 * riscv-tdep.c (riscv_isa_xlen): Drop static.
2121 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
2123 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
2126 * target.c (dispose_inferior): Don't dispose of inferiors that are
2129 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
2131 * remote.c (remote_target::download_tracepoint): Change char* to
2134 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
2136 * target.h (target_options_to_string): Return an std::string.
2137 * target.c (str_comma_list_concat_elem): Return void, use
2139 (do_option): Likewise.
2140 (target_options_to_string): Return an std::string.
2141 * linux-nat.c (linux_nat_target::wait): Adjust.
2142 * target-debug.h (target_debug_print_options): Adjust.
2144 2018-08-07 Tom Tromey <tom@tromey.com>
2146 * Makefile.in (CPPFLAGS): New variable.
2147 (INTERNAL_CPPFLAGS): Use it.
2149 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2151 * NEWS: Mention the index cache.
2153 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2155 * common/pathstuff.h (get_standard_cache_dir): New.
2156 * common/pathstuff.c (get_standard_cache_dir): New.
2157 * build-id.h (build_id_to_string): New.
2158 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
2159 DEBUG_STR_SUFFIX): Move to here.
2160 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
2161 DEBUG_STR_SUFFIX): Move from there.
2162 (write_psymtabs_to_index): Make non-static, add basename
2163 parameter. Write to temporary files, rename when done.
2164 (save_gdb_index_command): Adjust call to
2165 write_psymtabs_to_index.
2166 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
2168 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
2169 (get_gdb_index_contents_from_cache): New.
2170 (get_gdb_index_contents_from_cache_dwz): New.
2171 (dwarf2_initialize_objfile): Read index from cache.
2172 (dwarf2_build_psymtabs): Save to index.
2173 * dwarf-index-cache.h: New file.
2174 * dwarf-index-cache.c: New file.
2175 * dwarf-index-write.h: New file.
2177 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2179 * gnulib/aclocal.m4: Re-generate.
2180 * gnulib/config.in: Re-generate.
2181 * gnulib/configure: Re-generate.
2182 * gnulib/import/Makefile.am: Re-generate.
2183 * gnulib/import/Makefile.in: Re-generate.
2184 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
2185 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2186 * gnulib/import/m4/mkdir.m4: New file.
2187 * gnulib/import/mkdir.c: New file.
2188 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
2191 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2193 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
2194 * common/scoped_mmap.c: New file.
2195 * common/scoped_mmap.h (destroy): New method.
2196 (~scoped_mmap, reset): Use destroy.
2197 (scoped_mmap): New move constructor.
2198 (mmap_file): New declaration.
2199 * unittests/scoped_mmap-selftests.c (test_normal,
2200 test_invalid_filename, run_tests): New functions.
2201 (_initialize_scoped_mmap_selftests): Register selftest.
2203 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2205 * dwarf2read.c (read_gdb_index_from_section): Rename to...
2206 (read_gdb_index_from_buffer): ... this. Remove section
2207 parameter, add buffer parameter.
2208 (get_gdb_index_contents_ftype,
2209 get_gdb_index_contents_dwz_ftype): New typedefs.
2210 (dwarf2_read_gdb_index): Add callback parameters to get the
2212 (get_gdb_index_contents_from_section): New.
2213 (dwarf2_initialize_objfile): Update call to
2214 dwarf2_read_gdb_index.
2216 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2218 * common/filestuff.h (gdb_fopen_cloexec): New overload.
2219 (gdb_open_cloexec): Likewise.
2220 * nat/linux-osdata.c (command_from_pid): Use string_printf.
2221 (commandline_from_pid): Likewise.
2222 (linux_xfer_osdata_threads): Likewise.
2223 (linux_xfer_osdata_fds): Likewise.
2224 * ada-lang.c (is_package_name): Likewise.
2225 * auxv.c (procfs_xfer_auxv): Likewise.
2226 * breakpoint.c (print_one_breakpoint_location): Use
2228 (print_one_catch_solib): Use string_printf.
2229 * coff-pe-read.c (add_pe_exported_sym): Likewise.
2230 (add_pe_forwarded_sym): Likewise.
2231 * dwarf2read.c (create_type_unit_group): Likewise.
2232 (build_error_marker_type): Likewise.
2233 * infcall.c (get_function_name): Likewise.
2234 * valprint.c (print_converted_chars_to_obstack): Likewise.
2235 * xtensa-tdep.c (xtensa_register_type): Likewise.
2237 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
2239 * remote.c (remote_target::download_tracepoint): Fix format
2242 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2244 * tracefile.c: Include common/byte-vector.h.
2245 (trace_save): Change type of buf to gdb::byte_vector. Initialize
2246 with trace_regblock_size if needed. Update uses of buf.
2248 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2250 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
2251 std::vector<unsigned char>.
2252 * tracepoint.c (collection_list::collection_list): Remove
2253 m_regs_mask initializer from initializer list. Resize
2254 m_regs_mask using the largest remote register number.
2255 (collection_list::add_remote_register): Remove size check on
2256 m_regs_mask. Use at to access element.
2257 (collection_list::stringify): Change type of temp_buf to
2258 gdb::char_vector. Update uses of temp_buf. Resize if needed to
2259 stringify the register mask. Use pack_hex_byte for the register
2262 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2264 * tracepoint.h (class collection_list) <add_register>: Remove.
2265 <add_remote_register, add_ax_registers, add_local_register>:
2267 <add_memrange>: Add scope parameter.
2268 * tracepoint.c (encode_actions_1): Likewise.
2269 (collection_list::add_register): Rename to ...
2270 (collection_list::add_remote_register): ... this. Update
2272 (collection_list::add_ax_registers, add_local_register): New
2274 (collection_list::add_memrange): Add scope parameter. Call
2275 add_local_register instead of add_register.
2276 (finalize_tracepoint_aexpr): New function.
2277 (collection_list::collect_symbol): Update calls to add_memrange.
2278 Call add_local_register instead of add_register. Call
2279 add_ax_registers. Call finalize_tracepoint_aexpr.
2280 (encode_actions_1): Get remote regnos for $reg action. Call
2281 add_remote_register, add_ax_registers, and add_local_register.
2282 Update call to add_memrange. Call finalize_tracepoint_aexpr.
2283 (validate_actionline): Call finalize_tracepoint_aexpr.
2285 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2287 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
2288 Replace array buf with gdb::char_vector buf, of size
2289 get_remote_packet_size (). Replace references to buf and
2290 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
2291 and xsnprintf with snprintf. Raise errors if the buffer is too
2294 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2296 * remote.c (remote_target::download_tracepoint): Fix the has_more
2297 predicate in the QTDP action list iteration.
2299 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2301 * remote.c (remote_target::download_tracepoint): Fix indentation
2304 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2306 * proc-api.c (_initialize_proc_api): Remove c, unused.
2307 * procfs.c (procfs_init_inferior): Remove signals, unused.
2308 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
2311 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
2312 Andrew Burgess <andrew.burgess@embecosm.com>
2314 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
2315 'W_STOPCODE (0)' as this could be ambiguous.
2317 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
2319 * ser-tcp.c (net_open): Fix thinko when deciding whether to
2320 disable TCP's Nagle algorithm (use "ai_protocol" instead of
2323 2018-08-02 Tom Tromey <tom@tromey.com>
2326 * dwarf2read.c (read_func_scope): Set symtab on template parameter
2328 (process_structure_scope): Likewise.
2330 2018-08-02 Xavier Roirand <roirand@adacore.com>
2333 * darwin-nat.c (darwin_kill_inferior): Fix handling of
2336 2018-08-02 Tom Tromey <tom@tromey.com>
2338 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
2339 (darwin_suspend_inferior, darwin_resume_inferior)
2340 (darwin_decode_notify_message, darwin_resume_inferior_threads)
2341 (darwin_check_new_threads): Check result of get_darwin_inferior.
2343 2018-07-31 Joel Brobecker <brobecker@adacore.com>
2347 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
2349 * varobj.c (varobj_get_path_expr_parent): Report an error if
2350 parent is a dynamic varobj.
2352 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2354 * gnulib/aclocal.m4: Re-generate.
2355 * gnulib/config.in: Re-generate.
2356 * gnulib/configure: Re-generate.
2357 * gnulib/import/Makefile.in: Re-generate.
2358 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2359 * gnulib/import/m4/onceonly.m4: Re-generate.
2361 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2363 * target-descriptions.c (struct xml_test_tdesc): New.
2364 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
2365 (record_xml_tdesc): Update.
2366 (maintenance_check_xml_descriptions): Update.
2367 * target-descriptions.h (record_xml_tdesc): Update comment.
2369 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
2371 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
2372 checking array bounds are defined.
2374 2018-07-30 Tom Tromey <tom@tromey.com>
2376 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
2377 irreflexivity violation.
2379 2018-07-30 Tom Tromey <tom@tromey.com>
2381 * cli/cli-decode.c (lookup_cmd): Remove lint code.
2382 * value.c (unpack_long): Remove lint code.
2383 * valops.c (value_ind): Remove lint code.
2384 * valarith.c (value_x_binop, value_x_unop, value_equal)
2385 (value_pos): Remove lint code.
2387 2018-07-28 Tom de Vries <tdevries@suse.de>
2389 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
2390 with undefined upper bound as <optimized out>.
2392 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
2394 * gcore.in: Rename variable "name" to "prefix". Expand
2397 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
2399 * windows-nat.c (windows_nat_target::create_inferior): Update to
2400 call close() in global namespace.
2402 2018-07-26 Tom Tromey <tom@tromey.com>
2404 * dwarf-index-write.c (add_address_entry): Don't add objfile
2406 * dbxread.c (find_stab_function): Rename from
2407 find_stab_function_addr. Return a bound_minimal_symbol.
2408 (read_dbx_symtab): Use raw_text_low, raw_text_high.
2409 Don't add objfile offsets.
2410 (end_psymtab): Use raw_text_low, raw_text_high,
2411 MSYMBOL_VALUE_RAW_ADDRESS.
2412 (read_ofile_symtab): Update.
2413 (process_one_symbol): Update.
2414 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
2416 (dw2_relocate): Remove.
2417 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
2419 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
2421 (process_psymtab_comp_unit_reader, add_partial_symbol)
2422 (add_partial_subprogram, dwarf2_ranges_read): Update.
2423 (load_partial_dies): Update.
2424 (add_address_entry): Don't add objfile offsets.
2425 (dwarf2_build_include_psymtabs): Update.
2426 (create_addrmap_from_aranges): Don't add objfile offsets.
2427 (dw2_find_pc_sect_compunit_symtab): Update.
2428 * mdebugread.c (parse_symbol): Don't add objfile offsets.
2429 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
2431 (parse_partial_symbols): Don't add objfile offsets. Use
2432 raw_text_low, raw_text_high. Update.
2433 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
2434 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
2435 or call 'relocate' quick function. Clear psymbol_map.
2436 * psympriv.h (struct partial_symbol) <address>: Add section
2438 <set_unrelocated_address>: Rename from set_address.
2439 <raw_text_low, raw_text_high>: New methods.
2440 <text_low, text_high>: Add objfile parameter.
2441 (add_psymbol_to_bcache): Add 'section' parameter. Call
2442 set_unrelocated_address.
2443 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2444 (find_pc_psymbol): Update.
2445 (fixup_psymbol_section, relocate_psymtabs): Remove.
2446 (dump_psymtab, psym_functions): Update.
2447 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
2449 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
2450 (start_psymtab_common): Update.
2451 * symfile-debug.c (debug_qf_relocate): Remove.
2452 (debug_sym_quick_functions): Update.
2453 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
2454 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
2457 2018-07-26 Tom Tromey <tromey@redhat.com>
2459 * dbxread.c (end_psymtab): Use text_high_valid and
2461 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
2462 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
2463 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2465 <text_low_valid, text_high_valid>: New fields.
2466 <set_text_low, set_text_high>: Update.
2467 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
2469 2018-07-26 Tom Tromey <tom@tromey.com>
2471 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
2473 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
2474 textlow and texthigh fields.
2475 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
2477 * mdebugread.c (parse_lines, parse_partial_symbols)
2478 (psymtab_to_symtab_1): Update.
2479 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2480 Rename fields. Update comment. Now private.
2481 <text_low, text_high, set_text_low, set_text_high>: New methods.
2482 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2483 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
2484 (start_psymtab_common, maintenance_info_psymtabs)
2485 (maintenance_check_psymtabs): Update.
2486 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
2488 (scan_xcoff_symtab): Update.
2490 2018-07-26 Tom Tromey <tromey@redhat.com>
2492 * psympriv.h (struct partial_symbol) <unrelocated_address,
2493 address, set_address>: New methods.
2494 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
2495 (fixup_psymbol_section, relocate_psymtabs): Update.
2496 (print_partial_symbols): Add 'objfile' parameter. Update.
2497 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
2500 2018-07-26 Tom Tromey <tom@tromey.com>
2502 * dwarf-index-write.c (write_psymbols, debug_names::insert)
2503 (debug_names::write_psymbols): Update.
2504 * psympriv.h (struct partial_symbol): Derive from
2505 general_symbol_info.
2506 <obj_section>: New method.
2507 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
2508 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2509 (find_pc_sect_psymbol, fixup_psymbol_section)
2510 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
2511 (print_partial_symbols, recursively_search_psymtabs)
2512 (compare_psymbols, psymbol_hash, psymbol_compare)
2513 (add_psymbol_to_bcache, maintenance_check_psymtabs)
2514 (psymbol_name_matches, psym_fill_psymbol_map): Update.
2516 2018-07-26 Tom Tromey <tromey@redhat.com>
2518 * dbxread.c (end_psymtab): Remove dead code.
2520 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
2522 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
2523 DWARF unwinders are disabled.
2524 * dwarf2-frame.c: Add dwarf2read.h include.
2525 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
2527 (dwarf2_frame_unwinders_enabled_p): Define.
2528 (show_dwarf_unwinders_enabled_p): New function.
2529 (_initialize_dwarf2_frame): Register switch to control DWARF
2531 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
2532 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
2533 (show_dwarf_cmdlist): Remove static keyword.
2534 * dwarf2read.h (set_dwarf_cmdlist): Declare.
2535 (show_dwarf_cmdlist): Declare.
2536 * NEWS: Document new feature.
2538 2018-07-26 Tom de Vries <tdevries@suse.de>
2540 PR breakpoints/23366
2541 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
2543 2018-07-26 Tom de Vries <tdevries@suse.de>
2545 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
2546 DW_AT_count can't be translated to a dynamic prop.
2548 2018-07-25 Tom de Vries <tdevries@suse.de>
2550 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
2553 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
2555 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
2557 2018-07-25 Joel Brobecker <brobecker@adacore.com>
2559 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
2561 2018-07-24 Keith Seitz <keiths@redhat.comt
2564 * dwarf2read.c (dw2_add_symbol_to_list): New function.
2565 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
2566 instead of add_symbol_to_list.
2567 (read_file_scope): Call prepare_one_comp_unit before reading
2570 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
2572 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
2574 2018-07-24 Tom Tromey <tom@tromey.com>
2576 * utils.c (malloc, realloc, free): Don't declare.
2577 * configure, config.in: Rebuild.
2578 * configure.ac: Don't check for declarations of free, malloc, or
2581 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2583 * aarch64-linux-nat.c
2584 (aarch64_linux_nat_target::stopped_data_address): Remove unused
2586 * arm-linux-nat.c (fetch_regs): Likewise.
2587 (store_regs): Likewise.
2588 (fetch_vfp_regs): Likewise.
2589 (store_vfp_regs): Likewise.
2590 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
2591 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
2592 (arm_linux_nat_target::insert_watchpoint): Likewise.
2593 (arm_linux_nat_target::remove_watchpoint): Likewise.
2594 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
2596 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
2598 * ppc-linux-nat.c (fetch_register): Likewise.
2599 (fetch_all_gp_regs): Likewise.
2600 (fetch_ppc_registers): Likewise.
2601 (store_all_gp_regs): Likewise.
2602 (store_ppc_registers): Likewise.
2603 (hwdebug_insert_point): Likewise.
2604 (can_use_watchpoint_cond_accel): Likewise.
2605 * remote-sim.c (gdb_os_write_stdout): Likewise.
2607 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2608 Tom Tromey <tom@tromey.com>
2610 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
2612 * configure: Rebuild.
2614 2018-07-22 Tom Tromey <tom@tromey.com>
2616 * regformats/regdat.sh: Define xmltarget_${name} inside
2617 #ifndef IN_PROCESS_AGENT.
2619 2018-07-22 Tom Tromey <tom@tromey.com>
2621 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
2623 2018-07-22 Tom Tromey <tom@tromey.com>
2625 * symfile.c (reread_symbols): Notify iter, not objfile.
2627 2018-07-22 Tom Tromey <tom@tromey.com>
2629 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
2631 (ravenscar_thread_target::prepare_to_store): Likewise.
2633 2018-07-22 Tom Tromey <tom@tromey.com>
2635 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
2636 unused variable. Call value_fetch_lazy when needed.
2637 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
2638 Remove unused variable. Call value_fetch_lazy when needed.
2640 2018-07-22 Tom Tromey <tom@tromey.com>
2642 * m32c-tdep.c (mark_dma): Return void.
2643 (make_regs): Remove unused declarations.
2645 2018-07-22 Tom Tromey <tom@tromey.com>
2647 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
2648 cmdscm_get_valid_command_smob_arg_unsafe for effect.
2649 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
2650 bkscm_get_valid_block_smob_arg_unsafe for effect.
2652 2018-07-22 Tom Tromey <tom@tromey.com>
2654 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
2657 2018-07-22 Tom Tromey <tom@tromey.com>
2659 * windows-nat.c (saved_context): Conditionally define.
2660 * remote.c (remote_target::remote_btrace_maybe_reopen):
2661 Conditionally declare "warned".
2662 * inflow.c (sigquit_ours): Conditionally define.
2663 (new_tty): Move "tty" declaration inside #if.
2664 * guile/guile.c (guile_datadir): Conditionally define.
2665 * charset.c (set_be_le_names): Move some declarations inside #if.
2666 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
2668 (parse_xml_btrace_conf): Likewise.
2670 2018-07-22 Tom Tromey <tom@tromey.com>
2672 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
2674 2018-07-22 Tom Tromey <tom@tromey.com>
2676 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
2677 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
2678 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
2679 * buildsym-legacy.c (get_macro_table): Remove unused variable.
2680 * stack.c (frame_apply_level_command): Remove unused variable.
2681 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
2682 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
2683 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
2685 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
2686 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
2687 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
2689 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
2690 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
2692 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
2693 Remove unused variable.
2694 * cli/cli-script.c (recurse_read_control_structure): Remove unused
2696 * common/tdesc.c (print_xml_feature::visit): Remove unused
2698 * compile/compile-object-load.c (store_regs): Remove unused
2700 * complaints.c (clear_complaints): Remove unused variable.
2701 * corelow.c (core_target_open): Remove unused variable.
2702 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
2704 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
2706 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
2708 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
2710 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
2712 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
2714 * ia64-tdep.c (examine_prologue): Remove unused variable.
2715 * infcall.c (run_inferior_call): Remove unused variable.
2716 * inferior.c (exit_inferior): Remove unused variable.
2717 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
2718 * linespec.c (decode_line_2): Remove unused variable.
2719 * linux-nat.c (super_close): Remove.
2720 * linux-tdep.c (linux_info_proc): Remove unused variable.
2721 * mi/mi-main.c (mi_execute_command): Remove unused variable.
2722 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
2723 Remove unused variable.
2724 * parse.c (find_minsym_type_and_address): Remove unused variable.
2725 * printcmd.c (info_symbol_command, printf_floating): Remove unused
2727 * python/py-breakpoint.c (bppy_set_commands): Remove unused
2729 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
2731 * record-btrace.c (record_btrace_target::store_registers): Remove
2733 (cmd_show_record_btrace_cpu): Remove unused variable.
2734 * riscv-tdep.c (riscv_register_reggroup_p)
2735 (riscv_push_dummy_call, riscv_return_value): Remove unused
2737 * rust-exp.y (literal): Remove unused variable.
2738 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
2740 <STRUCTOP_ANONYMOUS>: Likewise.
2741 * s390-linux-tdep.c (s390_linux_init_abi_31)
2742 (s390_linux_init_abi_64): Remove unused variable.
2743 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
2744 (file_select_thread, net_windows_open, _initialize_ser_windows):
2745 Remove unused variables.
2746 * symtab.c (find_pc_sect_line): Remove unused variable.
2747 * target-memory.c (compute_garbled_blocks): Remove unused
2749 (target_write_memory_blocks): Remove unused variable.
2750 * target.c (target_stack::unpush): Remove unused variables.
2751 * tracepoint.c (start_tracing, all_tracepoint_actions)
2752 (merge_uploaded_trace_state_variables)
2753 (print_one_static_tracepoint_marker): Remove unused variable.
2754 * unittests/basic_string_view/element_access/char/1.cc (test01):
2755 Remove unused variable.
2756 * windows-nat.c (windows_continue, windows_add_all_dlls)
2757 (do_initial_windows_stuff, windows_nat_target::create_inferior):
2758 Remove unused variables.
2760 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
2762 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
2763 attr_profile in HAVE_ELF.
2764 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
2767 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
2769 * frame.c (frame_register_unwind): Change parameter name.
2770 (frame_unwind_register): Likewise.
2771 (frame_unwind_register_value): Likewise.
2772 (frame_unwind_register_signed): Likewise.
2773 (frame_unwind_register_unsigned): Likewise.
2774 * frame.h (frame_register_unwind): Likewise.
2775 (frame_unwind_register): Likewise.
2776 (frame_unwind_register_value): Likewise.
2777 (frame_unwind_register_signed): Likewise.
2778 (frame_unwind_register_unsigned): Likewise.
2779 (frame_unwind_arch): Likewise.
2781 2018-07-20 Maciej W. Rozycki <macro@mips.com>
2783 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
2786 2018-07-20 Maciej W. Rozycki <macro@mips.com>
2788 * mips-linux-nat.c (mips_linux_nat_target::read_description):
2789 Call `get_ptrace_pid' rather than extracting the ptrace PID by
2792 2018-07-20 Keith Seitz <keiths@redhat.com>
2794 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
2795 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
2796 m_compunit_symtab, m_language>: Add "m_" prefix.
2798 * buildsym.c: Update all uses.
2800 2018-07-20 Tom Tromey <tom@tromey.com>
2802 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
2803 * buildsym.h (record_line_ftype): Remove typedef.
2805 2018-07-20 Tom Tromey <tom@tromey.com>
2807 * buildsym-legacy.h (augment_type_symtab): Don't declare.
2808 (end_expandable_symtab): Likewise.
2809 (end_symtab_get_static_block): Likewise.
2810 (end_symtab_from_static_block): Likewise.
2811 * buildsym-legacy.c (augment_type_symtab): Remove.
2812 (end_expandable_symtab): Remove.
2813 (end_symtab_get_static_block): Remove.
2814 (end_symtab_from_static_block): Remove.
2816 2018-07-20 Tom Tromey <tom@tromey.com>
2818 * dwarf2read.c: Include buildsym.h.
2819 (struct dwarf2_cu) <builder>: New method.
2820 (fixup_go_packaging): Update.
2821 (process_full_comp_unit, process_full_type_unit): Update. Don't
2822 use scoped_free_pendings.
2823 (using_directives): Add "cu" parameter, remove "language".
2824 (read_import_statement, setup_type_unit_groups, )
2825 (read_func_scope, read_lexical_block_scope)
2826 (dwarf2_record_block_ranges, read_namespace): Update.
2827 (lnp_state_machine::lnp_state_machine): Add cu parameter.
2828 (lnp_state_machine::handle_end_sequence): Update.
2829 (class lnp_state_machine) <m_cu>: New member.
2830 <m_record_line_callback>: Remove.
2831 <m_currently_recording_lines>: New member.
2832 (lnp_state_machine::handle_set_file): Update.
2833 (noop_record_line): Remove.
2834 (dwarf_record_line_p): Add cu parameter.
2835 (dwarf_record_line_1, dwarf_finish_line): Likewise.
2836 (lnp_state_machine::record_line)
2837 (lnp_state_machine::lnp_state_machine)
2838 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
2839 (dwarf_decode_lines): Update.
2840 (dwarf2_start_subfile): Add cu parameter.
2841 (dwarf2_start_symtab, new_symbol): Update.
2842 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
2843 Remove dwarf2_per_objfile parameter.
2844 (dwarf_decode_macros): Update.
2846 2018-07-20 Tom Tromey <tom@tromey.com>
2848 * stabsread.c (define_symbol): Update.
2849 * buildsym-legacy.h (get_buildsym_compunit): Declare.
2850 * dwarf2read.c (new_symbol): Update.
2851 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
2852 * cp-namespace.c: Include buildsym.h.
2853 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
2854 * buildsym-legacy.c (get_buildsym_compunit): New function.
2856 2018-07-20 Tom Tromey <tom@tromey.com>
2858 * xcoffread.c: Include buildsym-legacy.h.
2859 * windows-nat.c: Include buildsym-legacy.h.
2860 * stabsread.c: Include buildsym-legacy.h.
2861 * mdebugread.c: Include buildsym-legacy.h.
2862 * buildsym-legacy.h: New file.
2863 * buildsym-legacy.c: New file, from buildsym.c.
2864 * go32-nat.c: Include buildsym-legacy.h.
2865 * dwarf2read.c: Include buildsym-legacy.h.
2866 * dbxread.c: Include buildsym-legacy.h.
2867 * cp-namespace.c: Include buildsym-legacy.h.
2868 * coffread.c: Include buildsym-legacy.h.
2869 * buildsym.h: Move some contents to buildsym-legacy.h.
2870 * buildsym.c: Include buildsym-legacy.h. Move many functions to
2872 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
2874 2018-07-20 Tom Tromey <tom@tromey.com>
2876 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
2877 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
2878 (buildsym_compunit::buildsym_compunit)
2879 (buildsym_compunit::~buildsym_compunit)
2880 (buildsym_compunit::get_macro_table): Define.
2882 2018-07-20 Tom Tromey <tom@tromey.com>
2884 * buildsym.c (reset_symtab_globals): Remove.
2885 (buildsym_compunit::end_symtab_from_static_block): Update.
2886 (buildsym_compunit::augment_type_symtab): Update.
2887 (end_symtab_from_static_block): Call free_buildsym_compunit.
2888 (augment_type_symtab, end_symtab, end_expandable_symtab):
2891 2018-07-20 Tom Tromey <tom@tromey.com>
2893 * arch-utils.c: Do not include buildsym.h.
2894 * mipsread.c: Do not include buildsym.h.
2895 * machoread.c: Do not include buildsym.h.
2896 * elfread.c: Do not include buildsym.h.
2898 2018-07-20 Tom Tromey <tom@tromey.com>
2900 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
2902 (buildsym_compunit): Add new constructor.
2903 (struct buildsym_compunit) <get_last_source_file, finish_block,
2904 record_block_range, start_subfile, patch_subfile_names,
2905 push_subfile, pop_subfile, record_line, get_compunit_symtab,
2906 set_last_source_start_addr, get_last_source_start_addr,
2907 get_local_using_directives, set_local_using_directives,
2908 get_global_using_directives, outermost_context_p,
2909 get_current_context_stack, get_context_stack_depth,
2910 get_current_subfile, get_local_symbols, get_file_symbols,
2911 get_global_symbols, record_debugformat, record_producer,
2912 push_context, pop_context, end_symtab_get_static_block,
2913 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
2915 <record_pending_block, finish_block_internal, make_blockvector,
2916 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
2920 2018-05-22 Tom Tromey <tom@tromey.com>
2922 * buildsym.c (record_pending_block): Move earlier. Remove objfile
2924 (finish_block_internal): Update.
2926 2018-07-20 Tom Tromey <tom@tromey.com>
2928 * buildsym.c (record_pending_block): Move earlier. Remove objfile
2930 (finish_block_internal): Update.
2932 2018-07-20 Tom Tromey <tom@tromey.com>
2934 * buildsym.h (EXTERN): Don't define or undef.
2935 * buildsym.c (EXTERN): Don't define.
2937 2018-07-20 Tom Tromey <tom@tromey.com>
2939 * buildsym.c: Remove TODO comment.
2941 2018-07-20 Tom Tromey <tom@tromey.com>
2943 * coffread.c (coff_symtab_read): Update.
2944 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
2945 (xcoff_new_init): Update.
2946 * mipsread.c (mipscoff_new_init): Update.
2947 * mdebugread.c (mdebug_build_psymtabs): Update.
2948 * elfread.c (elf_new_init): Update.
2949 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
2951 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
2952 (coffstab_build_psymtabs, elfstab_build_psymtabs)
2953 (stabsect_build_psymtabs): Update.
2954 * buildsym.h (buildsym_init): Don't declare.
2955 * buildsym.c: Update comment.
2956 (prepare_for_building): Remove.
2957 (start_symtab, restart_symtab): Update.
2958 (reset_symtab_globals): Update comment.
2959 (buildsym_init): Remove.
2961 2018-07-20 Tom Tromey <tom@tromey.com>
2963 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
2964 * stabsread.c (patch_block_stabs, define_symbol, read_type)
2965 (read_enum_type, common_block_start, common_block_end)
2966 (cleanup_undefined_types_1, finish_global_stabs): Update.
2967 * mdebugread.c (psymtab_to_symtab_1): Update.
2968 * dwarf2read.c (fixup_go_packaging, read_func_scope)
2969 (read_lexical_block_scope, new_symbol): Update.
2970 * dbxread.c (process_one_symbol): Update.
2971 * coffread.c (coff_symtab_read, process_coff_symbol)
2972 (coff_read_enum_type): Update.
2973 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
2975 (get_local_symbols, get_file_symbols, get_global_symbols): New
2977 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
2979 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
2980 (~scoped_free_pendings): Update.
2981 (finish_block, prepare_for_building, reset_symtab_globals)
2982 (end_symtab_get_static_block, end_symtab_with_blockvector)
2983 (augment_type_symtab, push_context): Update.
2984 (get_local_symbols, get_file_symbols, get_global_symbols): New
2986 (buildsym_init): Update.
2988 2018-07-20 Tom Tromey <tom@tromey.com>
2990 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
2991 (process_full_type_unit): Likewise.
2992 (dwarf2_start_symtab): Set list_in_scope.
2994 2018-07-20 Tom Tromey <tom@tromey.com>
2996 * dwarf2read.c (process_psymtab_comp_unit_reader)
2997 (build_type_psymtabs_reader): Do not set list_in_scope.
2999 2018-07-20 Tom Tromey <tom@tromey.com>
3001 * buildsym.c (free_pendings): Remove.
3002 (add_symbol_to_list, scoped_free_pendings)
3003 (finish_block_internal, buildsym_init): Update.
3005 2018-07-20 Tom Tromey <tom@tromey.com>
3007 * xcoffread.c (read_xcoff_symtab): Update.
3008 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
3010 * dbxread.c (process_one_symbol): Update.
3011 * coffread.c (coff_symtab_read): Update.
3012 * buildsym.h (finish_block): Update.
3013 * buildsym.c (finish_block): Remove "listhead" argument.
3014 (end_symtab_get_static_block): Update.
3016 2018-07-20 Tom Tromey <tom@tromey.com>
3018 * buildsym.h (class scoped_free_pendings): Remove constructor.
3019 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
3021 <m_pending_block_obstack, m_pending_blocks>: New members.
3022 (pending_block_obstack, pending_blocks): Remove.
3023 (scoped_free_pendings::scoped_free_pendings): Default.
3024 (~scoped_free_pendings): Update.
3025 (free_pending_blocks): Remove.
3026 (finish_block_internal, record_pending_block, make_blockvector)
3027 (end_symtab_get_static_block, augment_type_symtab, push_context)
3028 (buildsym_init): Update.
3030 2018-07-20 Tom Tromey <tom@tromey.com>
3032 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
3033 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
3035 (pending_addrmap, pending_addrmap_obstack)
3036 (pending_addrmap_interesting): Remove.
3037 (scoped_free_pendings, record_block_range, make_blockvector)
3038 (prepare_for_building, reset_symtab_globals, buildsym_init):
3041 2018-07-20 Tom Tromey <tom@tromey.com>
3043 * xcoffread.c (process_linenos): Update.
3044 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
3045 * mdebugread.c (psymtab_to_symtab_1): Update.
3046 * dwarf2read.c (setup_type_unit_groups)
3047 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
3048 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
3049 * dbxread.c (process_one_symbol): Update.
3050 * coffread.c (coff_symtab_read, enter_linenos)
3051 (process_coff_symbol): Update.
3052 * buildsym.h (current_subfile): Don't declare.
3053 (get_current_subfile): Declare.
3054 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
3056 (start_subfile, free_buildsym_compunit, push_subfile)
3057 (prepare_for_building, start_symtab): Update.
3058 (get_current_subfile): New function.
3060 2018-07-20 Tom Tromey <tom@tromey.com>
3062 * coffread.c (coff_symtab_read): Update.
3063 * xcoffread.c (read_xcoff_symtab): Update.
3064 * dwarf2read.c (new_symbol): Update.
3065 (read_func_scope, read_lexical_block_scope): Update.
3066 * dbxread.c (process_one_symbol): Update.
3067 * buildsym.h (context_stack, context_stack_depth): Don't declare.
3068 (outermost_context_p): Remove macro.
3069 (outermost_context_p, get_current_context_stack)
3070 (get_context_stack_depth): Declare.
3071 (pop_context): Return struct context_stack.
3072 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
3074 (context_stack_size): Remove.
3075 (INITIAL_CONTEXT_STACK_SIZE): Remove.
3076 (prepare_for_building, end_symtab_get_static_block)
3077 (augment_type_symtab, push_context): Update.
3078 (pop_context): Return struct context_stack.
3079 (outermost_context_p, get_current_context_stack)
3080 (get_context_stack_depth): New functions.
3081 (buildsym_init): Update.
3083 2018-07-20 Tom Tromey <tom@tromey.com>
3085 * rust-exp.y: Now a pure parser. Update all rules.
3086 (%union): Move earlier.
3087 (current_parser, work_obstack): Remove globals.
3088 (rust_parser, ~rust_parser): Update.
3089 (class rust_parser) <copy_name, concat3, crate_name, super_name,
3090 lex_character, lex_number, lex_string, lex_identifier,
3091 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
3092 convert_name, convert_params_to_expression,
3093 convert_ast_to_expression, ast_basic_type, ast_operation,
3094 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
3095 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
3096 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
3097 ast_array_type, ast_slice_type, ast_reference_type,
3098 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
3099 (rust_parse): Update.
3100 (rustyyerror, rustyylex): Add parser parameter.
3101 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
3102 (rust_lex_stringish_test, rust_lex_test_sequence)
3103 (rust_lex_test_trailing_dot, rust_lex_test_completion)
3104 (rust_lex_test_push_back, rust_lex_tests): Update.
3106 2018-07-19 Pedro Alves <palves@redhat.com>
3108 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
3109 gdb::unique_xmalloc_ptr.
3110 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
3111 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
3112 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
3113 copy-initialization.
3114 * guile/scm-pretty-print.c (ppscm_print_children): Use
3115 gdb::unique_xmalloc_ptr instead of cleanups.
3116 (gdbscm_apply_val_pretty_printer): Remove cleanups.
3117 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
3118 gdb::unique_xmalloc_ptr.
3119 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3120 Adjust to use gdb::unique_xmalloc_ptr.
3121 * guile/scm-utils.c (extract_arg): Adjust.
3122 * guile/scm-value.c (gdbscm_value_field): Adjust to use
3123 gdb::unique_xmalloc_ptr instead of a cleanup.
3125 2018-07-19 Tom Tromey <tom@tromey.com>
3127 * utils.c (do_value_free_to_mark)
3128 (make_cleanup_value_free_to_mark): Remove.
3129 * utils.h (make_cleanup_value_free_to_mark): Remove.
3131 2018-07-19 Pedro Alves <palves@redhat.com>
3133 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
3134 forwarding reference.
3136 2018-07-18 Pedro Alves <palves@redhat.com>
3138 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
3139 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
3142 2018-07-18 Pedro Alves <palves@redhat.com>
3144 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
3146 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
3148 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
3149 directly instead of a cleanup.
3150 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
3151 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
3152 (vlscm_binop_gdbthrow): New, factored out from ...
3153 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
3154 (vlscm_rich_compare): Use gdbscm_wrap.
3155 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
3156 instead of a cleanup.
3157 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
3159 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3160 Use xfree directly instead of a cleanup.
3161 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
3162 Adjust to use gdbscm_wrap and scoped_value_mark.
3163 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
3164 (gdbscm_value_address, gdbscm_value_dereference)
3165 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
3167 (gdbscm_value_dynamic_type): Use scoped_value_mark.
3168 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
3170 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
3171 gdbscm_wrap and scoped_value_mark.
3172 (gdbscm_value_to_string): Use xfree directly instead of a
3173 cleanup. Move 'buffer' unique_ptr to TRY scope.
3174 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
3175 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
3177 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
3178 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
3180 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
3183 2018-07-18 Tom de Vries <tdevries@suse.de>
3185 * findvar.c (default_read_var_value): Also resolve dynamic type for
3186 LOC_OPTIMIZED_OUT vars.
3188 2018-07-18 Maciej W. Rozycki <macro@mips.com>
3190 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
3193 2018-07-17 Tom Tromey <tom@tromey.com>
3195 * guile/scm-param.c (pascm_set_func, pascm_show_func)
3196 (compute_enum_list, pascm_set_param_value_x)
3197 (gdbscm_parameter_value): Update.
3198 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
3199 (gdbscm_scm_to_host_string): Update.
3200 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
3202 * guile/scm-cmd.c (cmdscm_add_completion): Update.
3203 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
3204 * guile/scm-string.c (gdbscm_scm_to_string): Return
3206 (gdbscm_scm_to_host_string): Likewise.
3208 2018-07-17 Tom Tromey <tom@tromey.com>
3210 * guile/guile.c (gdbscm_eval_from_control_command): Update.
3211 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
3212 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
3213 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
3216 2018-07-17 Tom Tromey <tom@tromey.com>
3218 * guile/scm-param.c (pascm_signal_setshow_error): Update.
3219 * guile/guile-internal.h (gdbscm_exception_message_to_string):
3221 * guile/scm-cmd.c (cmdscm_function): Update.
3222 * guile/scm-pretty-print.c
3223 (ppscm_print_exception_unless_memory_error): Update.
3224 * guile/scm-exception.c (gdbscm_exception_message_to_string):
3225 Return unique_xmalloc_ptr.
3227 2018-07-17 Tom Tromey <tom@tromey.com>
3229 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
3232 2018-07-17 Jim Wilson <jimw@sifive.com>
3234 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
3235 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
3236 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
3237 unecessary braces after EF_RISCV_RVC test. Delete call to
3238 set_gdbarch_decr_pc_after_break.
3240 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
3241 RISCV_LAST_FP_REGNUM + 1.
3242 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
3244 2018-07-17 Tom Tromey <tom@tromey.com>
3246 * configure.ac: Remove --disable-gdbcli.
3247 * configure: Rebuild.
3248 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
3249 (SUBDIR_CLI_CFLAGS): Remove.
3250 (SFILES): Use SUBDIR_CLI_SRCS.
3251 (COMMON_OBS): Use SUBDIR_CLI_OBS.
3253 2018-07-17 Tom Tromey <tom@tromey.com>
3256 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
3258 2018-07-16 Jim Wilson <jimw@sifive.com>
3260 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
3262 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3264 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
3266 (libunwind_frame_sniffer): Likewise.
3267 (libunwind_frame_prev_register): Likewise.
3268 (libunwind_sigtramp_frame_sniffer): Likewise.
3269 * ia64-tdep.c (ia64_access_reg): Likewise.
3270 (ia64_access_rse_reg): Likewise.
3271 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
3272 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
3274 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3276 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
3278 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3280 * remote-sim.c (gdbsim_target::close,
3281 gdbsim_target::mourn_inferior): Remove unused variables.
3283 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
3285 * ia64-tdep.c (ktab_buf): New global.
3286 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
3287 (get_kernel_table): Adjust.
3289 2018-07-16 Tom Tromey <tom@tromey.com>
3291 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
3292 * dwarf2read.c (using_directives, new_symbol): Use
3293 outermost_context_p.
3294 * dbxread.c (process_one_symbol): Use outermost_context_p.
3295 * coffread.c (coff_symtab_read): Use outermost_context_p.
3297 2018-07-16 Tom Tromey <tom@tromey.com>
3299 * dwarf2read.c (using_directives, read_func_scope)
3300 (read_lexical_block_scope): Update.
3301 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
3302 * buildsym.h (local_using_directives, global_using_directives):
3304 (get_local_using_directives, set_local_using_directives)
3305 (get_global_using_directives): Declare.
3306 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
3307 m_global_using_directives>: New members.
3308 (finish_block_internal, prepare_for_building)
3309 (reset_symtab_globals, end_symtab_get_static_block)
3310 (push_context): Update.
3311 (get_local_using_directives, set_local_using_directives)
3312 (get_global_using_directives): New functions.
3313 (buildsym_init): Update.
3315 2018-07-16 Tom Tromey <tom@tromey.com>
3317 * xcoffread.c (xcoff_initial_scan): Don't call
3318 free_pending_blocks.
3319 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
3320 * buildsym.h (class scoped_free_pendings): Add constructor.
3321 (free_pending_blocks): Don't declare.
3322 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
3323 (free_pending_blocks): Now static.
3325 2018-07-16 Tom Tromey <tom@tromey.com>
3327 * buildsym.h (push_subfile, pop_subfile): Update declarations.
3328 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
3330 (struct subfile_stack): Remove.
3331 (subfile_stack): Remove.
3332 (push_subfile, pop_subfile, buildsym_init): Update.
3334 2018-07-16 Tom Tromey <tom@tromey.com>
3336 * buildsym.c (push_subfile): Use gdb_assert.
3337 (pop_subfile): Use gdb_assert.
3339 2018-07-16 Tom Tromey <tom@tromey.com>
3341 * buildsym.h (merge_symbol_lists): Remove.
3342 * buildsym.c (merge_symbol_lists): Remove.
3344 2018-07-16 Tom Tromey <tom@tromey.com>
3346 * stabsread.c (scan_file_globals): Update comment.
3347 * stabsread.h (scan_file_globals): Move from buildsym.h.
3348 * buildsym.h (scan_file_globals): Move to stabsread.h.
3350 2018-07-16 Tom Tromey <tom@tromey.com>
3352 * xcoffread.c (xcoff_new_init): Update.
3353 * mipsread.c (mipscoff_new_init): Update.
3354 * mdebugread.c (mdebug_build_psymtabs): Update.
3355 * elfread.c (elf_new_init): Update.
3356 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
3357 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
3358 * buildsym.h (buildsym_new_init): Don't declare.
3359 * buildsym.c (buildsym_new_init): Remove.
3361 2018-07-16 Tom Tromey <tom@tromey.com>
3363 * stabsread.h (within_function): Move from buildsym.h.
3364 * stabsread.c (start_stabs): Clear within_function.
3365 * coffread.c (coff_start_symtab): Clear within_function.
3366 * buildsym.h (within_function): Move to stabsread.h.
3367 * buildsym.c (prepare_for_building): Update.
3369 2018-07-16 Tom Tromey <tom@tromey.com>
3371 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
3372 * dwarf2read.c (dwarf2_start_symtab): Don't set
3373 processing_gcc_compilation.
3374 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
3376 2018-07-16 Tom Tromey <tom@tromey.com>
3378 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
3379 (next_symbol_text_func): Move from buildsym.h.
3380 * stabsread.c (hashname): Move from buildsym.c.
3381 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
3382 (next_symbol_text_func, hashname): Move to stabsread.h.
3383 * buildsym.c: Don't include bcache.h
3384 (hashname): Move to stasbread.c.
3386 2018-07-16 Tom Tromey <tom@tromey.com>
3388 * buildsym.h (context_stack_size): Don't declare.
3389 * buildsym.c (context_stack_size): New global.
3391 2018-07-16 Tom Tromey <tom@tromey.com>
3393 * dbxread.c (processing_acc_compilation): New global.
3394 * buildsym.h (processing_acc_compilation): Don't declare.
3396 2018-07-16 Tom Tromey <tom@tromey.com>
3398 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
3399 * dbxread.c (read_ofile_symtab): Update.
3400 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
3401 * buildsym.h (last_source_start_addr): Remove.
3402 (set_last_source_start_addr, get_last_source_start_addr):
3404 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
3406 (struct buildsym_compunit) <m_last_source_start_addr>: New
3408 (prepare_for_building): Remove start_addr parameter.
3409 (start_symtab, restart_symtab, end_symtab_get_static_block)
3410 (end_symtab_with_blockvector): Update.
3411 (set_last_source_start_addr, get_last_source_start_addr): New
3414 2018-07-16 Tom Tromey <tom@tromey.com>
3416 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
3418 (have_line_numbers): Remove.
3419 (record_line, prepare_for_building, end_symtab_get_static_block)
3420 (augment_type_symtab): Update.
3422 2018-07-16 Tom Tromey <tom@tromey.com>
3424 * buildsym.c (~buildsym_compunit): Free the macro table.
3425 (struct buildsym_compunit) <get_macro_table, release_macros>: New
3427 <m_pending_macros>: New member.
3428 (pending_macros): Remove.
3429 (~scoped_free_pendings, get_macro_table, prepare_for_building)
3430 (reset_symtab_globals, end_symtab_get_static_block)
3431 (end_symtab_with_blockvector, augment_type_symtab)
3432 (buildsym_init): Update.
3434 2018-07-16 Tom Tromey <tom@tromey.com>
3436 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
3438 (buildsym_compunit::set_last_source_file): New method.
3439 <m_last_source_file>: New member.
3440 (prepare_for_building): Remove "name" parameter.
3441 (start_symtab, restart_symtab, reset_symtab_globals): Update.
3442 (last_source_file): Remove.
3443 (set_last_source_file, get_last_source_file): Update.
3445 2018-07-16 Tom Tromey <tom@tromey.com>
3447 * buildsym.c (prepare_for_building): Add assert.
3449 2018-07-16 Tom Tromey <tom@tromey.com>
3451 * buildsym.c (~buildsym_compunit): Update.
3452 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
3453 (start_subfile, patch_subfile_names)
3454 (end_symtab_with_blockvector): Update.
3456 2018-07-16 Tom Tromey <tom@tromey.com>
3458 * buildsym.c (struct buildsym_compunit): Add constructor,
3459 destructor, initializers.
3460 (start_buildsym_compunit): Remove.
3461 (free_buildsym_compunit): Use "delete".
3462 (start_symtab, restart_symtab): Use "new".
3464 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
3466 * symfile.c (set_objfile_default_section_offset): Remove struct
3469 2018-07-14 Stafford Horne <shorne@gmail.com>
3471 * (Responsible Maintainers): Add myself as or1k maintainer.
3473 2018-07-13 Tom Tromey <tom@tromey.com>
3475 * symfile.c (set_objfile_default_section_offset): Use extra braces
3478 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
3480 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
3483 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3485 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3486 unittests/cli-utils-selftests.c
3487 * unittests/cli-utils-selftests.c: New file.
3489 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3491 * NEWS: Mention new commands. Mention change to 'thread apply'.
3493 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3495 * thread.c (thr_try_catch_cmd): New function.
3496 (thread_apply_all_command): Handle qcs flags.
3497 (thread_apply_command): Handle qcs flags.
3498 (taas_command): New function.
3499 (tfaas_command): New function.
3500 (_initialize_thread): Update to setup the new commands 'taas
3501 and 'tfaas'. Change doc string for 'thread apply'.
3503 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3505 * stack.c: (trailing_outermost_frame): New function, mostly
3506 extracted from backtrace_command_1.
3507 (leading_innermost_frame): New function.
3508 (backtrace_command_1): Update to call trailing_outermost_frame.
3509 (frame_apply_command_count): New function.
3510 (frame_apply_level_command): New function.
3511 (frame_apply_all_command): New function.
3512 (frame_apply_command): New function.
3513 (faas_command): New function.
3514 (frame_cmd_list): New variable.
3515 (_initialize_stack): Update to setup the new commands 'frame apply'
3518 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3520 * cli-utils.c (number_or_range_parser::get_number): Only handle
3521 numbers or convenience var as numbers.
3522 (parse_flags): New function.
3523 (parse_flags_qcs): New function.
3524 (number_or_range_parser::finished): Ensure parsing end is detected
3525 before end of string.
3526 * cli-utils.h (parse_flags): New function.
3527 (parse_flags_qcs): New function.
3528 (number_or_range_parser): Remove m_finished bool.
3529 (number_or_range_parser::skip_range): Set m_in_range to false.
3531 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
3533 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
3536 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3537 Jan Kratochvil <jan.kratochvil@redhat.com>
3538 Paul Fertser <fercerpav@gmail.com>
3539 Tsutomu Seki <sekiriki@gmail.com>
3540 Pedro Alves <palves@redhat.com>
3542 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3543 'unittests/parse-connection-spec-selftests.c'.
3544 (COMMON_SFILES): Add 'common/netstuff.c'.
3545 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
3546 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
3547 * common/netstuff.c: New file.
3548 * common/netstuff.h: New file.
3549 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
3550 (wait_for_connect): Update comment. New parameter
3551 'gdb::optional<int> sock' instead of 'struct serial *scb'.
3552 Use 'sock' directly instead of 'scb->fd'.
3553 (try_connect): New function, with code from 'net_open'.
3554 (net_open): Rewrite main loop to deal with multiple
3555 sockets/addresses. Handle IPv6-style hostnames; implement
3556 support for IPv6 connections.
3557 * unittests/parse-connection-spec-selftests.c: New file.
3559 2018-07-11 Pedro Alves <palves@redhat.com>
3562 * remote.c (remote_target::remote_detach_pid): Call
3563 set_current_process.
3565 2018-07-11 Pedro Alves <palves@redhat.com>
3567 * h8300-tdep.c (h8300_gdbarch_init): Remove
3568 set_gdbarch_ecoff_reg_to_regnum calls.
3570 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3573 * c-typeprint.c (c_type_print_base_struct_union): Don't print
3574 offsets/sizes for static members of a class/struct.
3576 2018-07-11 Alan Hayward <alan.hayward@arm.com>
3578 * target-descriptions.c (tdesc_register_bitsize): Rename.
3579 * target-descriptions.h (tdesc_register_bitsize): Likewise.
3580 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
3581 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
3583 2018-07-10 Tom Tromey <tom@tromey.com>
3585 * breakpoint.c (moribund_locations): Now static and a
3587 (breakpoint_init_inferior, moribund_breakpoint_here_p)
3588 (build_bpstat_chain, update_global_location_list)
3589 (breakpoint_retire_moribund): Update.
3590 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
3593 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
3595 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
3596 (riscv_register_reggroup_p): Use new function, remove unneeded
3598 (riscv_push_dummy_call): Extend assert to compare against xlen or
3599 flen based on register type.
3601 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
3603 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
3605 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
3607 * remote.c (show_hardware_watchpoint_limit): New function.
3608 (show_hardware_watchpoint_length_limit): New function.
3609 (show_hardware_breakpoint_limit): New function.
3610 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
3611 where appropriate, update help text.
3613 2018-07-09 Tom Tromey <tom@tromey.com>
3615 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
3616 (CLIBS): Don't mention NAT_CLIBS.
3618 2018-07-09 Tom Tromey <tom@tromey.com>
3620 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
3621 (LIBGDB_OBS, clean mostlyclean): Update.
3622 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
3624 2018-07-09 Tom Tromey <tom@tromey.com>
3626 * Makefile.in (%.c: %.y): Use ECHO_YACC.
3627 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
3628 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
3630 2018-07-09 Tom Tromey <tom@tromey.com>
3632 * Makefile.in (ALLDEPFILES): Remove exec.c.
3633 (COMMON_OBS): Remove exec.o.
3634 (COMMON_SFILES): Add exec.c.
3636 2018-07-09 Tom Tromey <tom@tromey.com>
3638 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
3640 2018-07-09 Tom Tromey <tom@tromey.com>
3642 * Makefile.in (clean mostlyclean): Remove stamp-version.
3643 (version.c): Depend on stamp-version.
3644 (stamp-version): New rule, from version.c rule.
3646 2018-07-09 Tom Tromey <tom@tromey.com>
3648 * Makefile.in (init.c): Depend on stamp-init.
3649 (stamp-init): New rule, from init.c rule.
3650 (clean mostlyclean): Remove stamp-init.
3652 2018-07-09 Tom Tromey <tom@tromey.com>
3654 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
3655 SUBDIR_GCC_COMPILE_SRCS.
3657 2018-07-09 Tom Tromey <tom@tromey.com>
3659 * Makefile.in (init.c): Remove some unused sed rules.
3661 2018-07-09 Tom Tromey <tom@tromey.com>
3663 * Makefile.in (TSOBS): Remove.
3664 (INIT_FILES): Update.
3665 (LIBGDB_OBS): Update.
3666 (COMMON_SFILES): Add inflow.c.
3667 (SFILES): Remove inflow.c.
3669 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
3671 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
3673 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
3675 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
3676 get_saveloc_name, is_signal_frame_name, step_name,
3677 init_remote_name, create_addr_space_name,
3678 destroy_addr_space_name, search_unwind_table_name,
3679 find_dyn_list_name): Constify.
3681 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
3683 * darwin-nat.c (darwin_pthread_kill): New function.
3684 (darwin_resume_thread): Use darwin_pthread_kill.
3686 2018-07-05 Tom de Vries <tdevries@suse.de>
3688 * macroexp.c (macro_buffer) <operator=>: New member function.
3690 2018-07-04 Tom Tromey <tom@tromey.com>
3692 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
3694 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
3696 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
3697 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
3698 * maint.c: Likewise.
3701 2018-07-04 Joel Brobecker <brobecker@adacore.com>
3703 * NEWS: Create a new section for the next release branch.
3704 Rename the section of the current branch, now that it has
3707 2018-07-04 Joel Brobecker <brobecker@adacore.com>
3709 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
3710 * version.in: Bump version to 8.2.50.DATE-git.
3712 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
3713 Pedro Alves <palves@redhat.com>
3715 * linux-nat.c (linux_init_ptrace): Rename to ...
3716 (linux_init_ptrace_procfs): ... this. Call
3717 linux_proc_init_warnings.
3718 (linux_nat_target::post_attach)
3719 (linux_nat_target::post_startup_inferior): Adjust.
3720 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
3721 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
3723 2018-07-04 Tom de Vries <tdevries@suse.de>
3725 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
3727 (read_comp_unit_head): ... here.
3729 2018-07-03 Tom Tromey <tom@tromey.com>
3731 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
3732 (stop_tracing, tstatus_command)
3733 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
3734 (print_one_static_tracepoint_marker): Update.
3735 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
3737 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
3739 (all_tracepoints, static_tracepoints_here): Return std::vector.
3741 2018-07-03 Tom Tromey <tom@tromey.com>
3743 * common/ptid.c (ptid_equal): Remove.
3744 * common/ptid.h (ptid_equal): Don't declare.
3745 * ada-tasks.c: Update.
3746 * breakpoint.c: Update.
3747 * common/agent.c: Update.
3748 * corelow.c: Update.
3749 * darwin-nat-info.c: Update.
3750 * darwin-nat.c: Update.
3752 * dtrace-probe.c: Update.
3753 * dummy-frame.c: Update.
3754 * fbsd-nat.c: Update.
3756 * gdbthread.h: Update.
3757 * gnu-nat.c: Update.
3758 * go32-nat.c: Update.
3759 * inf-loop.c: Update.
3760 * inf-ptrace.c: Update.
3761 * infcall.c: Update.
3765 * linux-fork.c: Update.
3766 * linux-nat.c: Update.
3767 * linux-thread-db.c: Update.
3768 * mi/mi-cmd-var.c: Update.
3769 * mi/mi-interp.c: Update.
3770 * mi/mi-main.c: Update.
3771 * nto-procfs.c: Update.
3772 * ppc-linux-tdep.c: Update.
3774 * python/py-inferior.c: Update.
3775 * python/py-record-btrace.c: Update.
3776 * python/py-record.c: Update.
3777 * ravenscar-thread.c: Update.
3778 * regcache.c: Update.
3779 * remote-sim.c: Update.
3781 * sol-thread.c: Update.
3784 * tui/tui-stack.c: Update.
3786 * windows-nat.c: Update.
3787 * windows-tdep.c: Update.
3789 2018-07-03 Tom Tromey <tom@tromey.com>
3791 * common/ptid.c (ptid_match): Remove.
3792 * common/ptid.h (ptid_match): Don't declare.
3793 * fbsd-nat.c: Update.
3796 * linux-nat.c: Update.
3797 * record-btrace.c: Update.
3798 * regcache.c: Update.
3801 2018-07-03 Tom Tromey <tom@tromey.com>
3803 * common/ptid.c (ptid_tid_p): Remove.
3804 * common/ptid.h (ptid_tid_p): Don't declare.
3805 * sol-thread.c: Update.
3807 2018-07-03 Tom Tromey <tom@tromey.com>
3809 * common/ptid.c (ptid_lwp_p): Remove.
3810 * common/ptid.h (ptid_lwp_p): Don't declare.
3811 * fbsd-nat.c: Update.
3812 * linux-nat.c: Update.
3813 * nat/linux-procfs.c: Update.
3814 * nat/x86-linux-dregs.c: Update.
3815 * sol-thread.c: Update.
3817 2018-07-03 Tom Tromey <tom@tromey.com>
3819 * common/ptid.c (ptid_is_pid): Remove.
3820 * common/ptid.h (ptid_is_pid): Don't declare.
3822 * linux-nat.c: Update.
3823 * mi/mi-interp.c: Update.
3827 2018-07-03 Tom Tromey <tom@tromey.com>
3829 * common/ptid.c (ptid_get_tid): Remove.
3830 * common/ptid.h (ptid_get_tid): Don't declare.
3831 * ada-tasks.c: Update.
3832 * aix-thread.c: Update.
3833 * bsd-uthread.c: Update.
3834 * darwin-nat.c: Update.
3835 * fbsd-nat.c: Update.
3836 * i386-darwin-nat.c: Update.
3838 * linux-tdep.c: Update.
3839 * nto-procfs.c: Update.
3840 * ppc-ravenscar-thread.c: Update.
3841 * python/py-infthread.c: Update.
3842 * ravenscar-thread.c: Update.
3843 * sol-thread.c: Update.
3844 * sparc-ravenscar-thread.c: Update.
3845 * windows-nat.c: Update.
3847 2018-07-03 Tom Tromey <tom@tromey.com>
3849 * common/ptid.c (ptid_get_lwp): Remove.
3850 * common/ptid.h (ptid_get_lwp): Don't declare.
3851 * aarch64-linux-nat.c: Update.
3852 * ada-tasks.c: Update.
3853 * aix-thread.c: Update.
3854 * amd64-linux-nat.c: Update.
3855 * arm-linux-nat.c: Update.
3856 * corelow.c: Update.
3857 * fbsd-nat.c: Update.
3858 * fbsd-tdep.c: Update.
3859 * gnu-nat.c: Update.
3860 * i386-cygwin-tdep.c: Update.
3861 * i386-gnu-nat.c: Update.
3862 * i386-linux-nat.c: Update.
3863 * ia64-linux-nat.c: Update.
3864 * inf-ptrace.c: Update.
3866 * linux-fork.c: Update.
3867 * linux-nat.c: Update.
3868 * linux-tdep.c: Update.
3869 * linux-thread-db.c: Update.
3870 * mips-linux-nat.c: Update.
3871 * nat/aarch64-linux-hw-point.c: Update.
3872 * nat/aarch64-linux.c: Update.
3873 * nat/linux-btrace.c: Update.
3874 * nat/linux-osdata.c: Update.
3875 * nat/linux-procfs.c: Update.
3876 * nat/x86-linux-dregs.c: Update.
3877 * obsd-nat.c: Update.
3878 * ppc-fbsd-nat.c: Update.
3879 * ppc-linux-nat.c: Update.
3881 * python/py-infthread.c: Update.
3882 * ravenscar-thread.c: Update.
3884 * s390-linux-nat.c: Update.
3885 * sol-thread.c: Update.
3886 * sol2-tdep.c: Update.
3887 * spu-linux-nat.c: Update.
3888 * x86-linux-nat.c: Update.
3889 * xtensa-linux-nat.c: Update.
3891 2018-07-03 Tom Tromey <tom@tromey.com>
3893 * common/ptid.c (ptid_get_pid): Remove.
3894 * common/ptid.h (ptid_get_pid): Don't declare.
3895 * aarch64-linux-nat.c: Update.
3896 * ada-lang.c: Update.
3897 * aix-thread.c: Update.
3898 * alpha-bsd-nat.c: Update.
3899 * amd64-fbsd-nat.c: Update.
3900 * amd64-linux-nat.c: Update.
3901 * arm-linux-nat.c: Update.
3902 * arm-nbsd-nat.c: Update.
3904 * break-catch-syscall.c: Update.
3905 * breakpoint.c: Update.
3906 * bsd-uthread.c: Update.
3907 * corelow.c: Update.
3909 * darwin-nat.c: Update.
3910 * fbsd-nat.c: Update.
3911 * fbsd-tdep.c: Update.
3913 * gnu-nat.c: Update.
3914 * hppa-nbsd-nat.c: Update.
3915 * hppa-obsd-nat.c: Update.
3916 * i386-fbsd-nat.c: Update.
3917 * ia64-linux-nat.c: Update.
3918 * inf-ptrace.c: Update.
3920 * inferior.c: Update.
3921 * inferior.h: Update.
3924 * linux-fork.c: Update.
3925 * linux-nat.c: Update.
3926 * linux-tdep.c: Update.
3927 * linux-thread-db.c: Update.
3928 * m68k-bsd-nat.c: Update.
3929 * mi/mi-interp.c: Update.
3930 * mi/mi-main.c: Update.
3931 * mips-linux-nat.c: Update.
3932 * mips-nbsd-nat.c: Update.
3933 * mips64-obsd-nat.c: Update.
3934 * nat/aarch64-linux-hw-point.c: Update.
3935 * nat/aarch64-linux.c: Update.
3936 * nat/linux-btrace.c: Update.
3937 * nat/linux-osdata.c: Update.
3938 * nat/linux-procfs.c: Update.
3939 * nat/x86-linux-dregs.c: Update.
3940 * nto-procfs.c: Update.
3941 * obsd-nat.c: Update.
3942 * ppc-linux-nat.c: Update.
3943 * ppc-nbsd-nat.c: Update.
3944 * ppc-obsd-nat.c: Update.
3945 * proc-service.c: Update.
3947 * python/py-inferior.c: Update.
3948 * python/py-infthread.c: Update.
3949 * ravenscar-thread.c: Update.
3951 * remote-sim.c: Update.
3953 * rs6000-nat.c: Update.
3954 * s390-linux-nat.c: Update.
3955 * sh-nbsd-nat.c: Update.
3956 * sol-thread.c: Update.
3957 * sparc-nat.c: Update.
3958 * sparc64-tdep.c: Update.
3959 * spu-linux-nat.c: Update.
3960 * spu-tdep.c: Update.
3961 * target-debug.h: Update.
3964 * tid-parse.c: Update.
3965 * tracefile-tfile.c: Update.
3966 * vax-bsd-nat.c: Update.
3967 * windows-nat.c: Update.
3968 * x86-linux-nat.c: Update.
3969 * x86-nat.c: Update.
3971 2018-07-03 Tom Tromey <tom@tromey.com>
3973 * common/ptid.c (pid_to_ptid): Remove.
3974 * common/ptid.h (pid_to_ptid): Don't declare.
3975 * aix-thread.c: Update.
3976 * arm-linux-nat.c: Update.
3977 * common/ptid.c: Update.
3978 * common/ptid.h: Update.
3979 * corelow.c: Update.
3981 * darwin-nat.c: Update.
3982 * fbsd-nat.c: Update.
3983 * fork-child.c: Update.
3984 * gnu-nat.c: Update.
3985 * go32-nat.c: Update.
3986 * inf-ptrace.c: Update.
3988 * inferior.c: Update.
3990 * linux-fork.c: Update.
3991 * linux-nat.c: Update.
3992 * nat/aarch64-linux-hw-point.c: Update.
3993 * nat/fork-inferior.c: Update.
3994 * nat/x86-linux-dregs.c: Update.
3995 * nto-procfs.c: Update.
3996 * obsd-nat.c: Update.
3998 * progspace.c: Update.
4000 * rs6000-nat.c: Update.
4001 * s390-linux-nat.c: Update.
4002 * sol-thread.c: Update.
4003 * spu-linux-nat.c: Update.
4006 * tracefile-tfile.c: Update.
4007 * windows-nat.c: Update.
4009 2018-07-03 Tom Tromey <tom@tromey.com>
4011 * common/ptid.h (ptid_build): Don't declare.
4012 * common/ptid.c (ptid_build): Remove.
4013 * aix-thread.c: Update.
4014 * bsd-kvm.c: Update.
4015 * bsd-uthread.c: Update.
4016 * common/agent.c: Update.
4017 * common/ptid.c: Update.
4018 * common/ptid.h: Update.
4019 * corelow.c: Update.
4020 * darwin-nat.c: Update.
4021 * fbsd-nat.c: Update.
4022 * gnu-nat.c: Update.
4023 * linux-fork.c: Update.
4024 * linux-nat.c: Update.
4025 * linux-thread-db.c: Update.
4026 * nat/linux-osdata.c: Update.
4027 * nat/linux-procfs.c: Update.
4028 * nto-procfs.c: Update.
4029 * obsd-nat.c: Update.
4030 * proc-service.c: Update.
4032 * ravenscar-thread.c: Update.
4033 * remote-sim.c: Update.
4035 * sol-thread.c: Update.
4037 * windows-nat.c: Update.
4039 2018-07-03 Tom Tromey <tom@tromey.com>
4041 * infrun.c (follow_exec): Use exit_inferior_silent.
4042 * inferior.c (exit_inferior_num_silent): Remove.
4043 * inferior.h (exit_inferior_num_silent): Don't declare.
4045 2018-07-03 Tom Tromey <tom@tromey.com>
4048 * darwin-nat.c (darwin_attach_pid): Reset inferior and
4049 inferior_ptid on error.
4051 2018-07-02 Maciej W. Rozycki <macro@mips.com>
4052 Simon Marchi <simon.marchi@polymtl.ca>
4055 * disasm.h (gdb_disassembler): Add
4056 `m_disassembler_options_holder'. member
4057 * disasm.c (get_all_disassembler_options): New function.
4058 (gdb_disassembler::gdb_disassembler): Use it.
4059 (gdb_buffered_insn_length_init_dis): Likewise.
4060 (gdb_buffered_insn_length): Adjust accordingly.
4061 (set_disassembler_options): Handle options with arguments.
4062 (show_disassembler_options_sfunc): Likewise. Add a leading new
4063 line if showing options with descriptions.
4064 (disassembler_options_completer): Adapt to using the
4065 `disasm_options_and_args_t' structure.
4066 * mips-tdep.c (mips_disassembler_options): New variable.
4067 (mips_disassembler_options_o32): Likewise.
4068 (mips_disassembler_options_n32): Likewise.
4069 (mips_disassembler_options_n64): Likewise.
4070 (gdb_print_insn_mips): Don't set `disassembler_options'.
4071 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
4073 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
4074 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
4075 `gdbarch_disassembler_options_implicit' and
4076 `gdbarch_valid_disassembler_options'.
4077 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
4078 `disasm_options_and_args_t' structure.
4079 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
4081 (valid_disassembler_options): Switch from `disasm_options_t' to
4082 the `disasm_options_and_args_t' structure.
4083 * NEWS: Document `set disassembler-options' support for the MIPS
4085 * gdbarch.h: Regenerate.
4086 * gdbarch.c: Regenerate.
4088 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
4090 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
4092 2018-06-29 Joel Brobecker <brobecker@adacore.com>
4094 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
4095 parameter in call to amd64_target_description.
4096 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
4097 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
4098 (amd64fbsd_init_abi): Likewise.
4099 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
4100 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
4101 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
4102 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
4104 2018-06-29 Pedro Alves <palves@redhat.com>
4106 * gdb/amd64-tdep.h (amd64_create_target_description): Add
4107 "segments" parameter.
4108 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
4109 (_initialize_amd64_tdep): Update call to
4110 amd64_create_target_description.
4111 (amd64_target_description): Add "segments" parameter. Adjust
4112 the implementation to use it.
4113 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
4114 call to amd64_create_target_description.
4115 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
4116 * gdb/arch/amd64.h (amd64_create_target_description): Add
4117 "segments" register.
4118 * gdb/arch/amd64.c (amd64_create_target_description): Add
4119 "segments" parameter. Call create_feature_i386_64bit_segments
4120 only if SEGMENTS is true.
4121 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
4122 call to amd64_create_target_description.
4124 2018-06-29 Pedro Alves <palves@redhat.com>
4126 * thread.c (thread_target_id_str): New, factored out from ...
4127 (print_thread_info_1): ... here. Use it to compute the max
4128 "Target Id" column width.
4130 2018-06-29 Pedro Alves <palves@redhat.com>
4132 * remote.c (remote_target::extra_thread_info): Delete
4133 'display_buf' and 'n' locals. from the cache, regardless of
4134 packet mechanims is in use. Use cache for qThreadExtra and qP
4137 2018-06-29 Pedro Alves <palves@redhat.com>
4139 * blockframe.c (find_pc_sect_containing_function): New function.
4140 * breakpoint.c (print_breakpoint_location): Don't call
4141 find_pc_sect_function.
4142 * linespec.c (create_sals_line_offset): Record the location's
4144 * linespec.c (convert_address_location_to_sals): Fill in sal's
4145 symbol with find_pc_sect_containing_function.
4146 * symtab.c (find_function_start_sal): Rename to ...
4147 (find_function_start_sal_1): ... this.
4148 (find_function_start_sal): Reimplement as wrapper around
4149 find_function_start_sal_1, and use
4150 find_pc_sect_containing_function to fill in the sal's symbol.
4151 (find_function_start_sal(symbol*, bool)): Adjust.
4152 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
4154 (find_pc_sect_containing_function): Declare.
4156 2018-06-29 Pedro Alves <palves@redhat.com>
4158 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
4159 true if the the location has no symbol.
4161 2018-06-28 Tom Tromey <tom@tromey.com>
4163 * NEWS: Mention --enable-codesign.
4164 * silent-rules.mk (ECHO_SIGN): New variable.
4165 * configure.ac: Add --enable-codesign.
4166 * configure: Rebuild.
4167 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
4168 (gdb$(EXEEXT)): Optionally invoke codesign.
4170 2018-06-28 Pedro Alves <palves@redhat.com>
4172 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
4174 (switch_to_thread_no_regs): Adjust comment.
4175 * infcmd.c (stop_pc): Delete.
4176 (post_create_inferior, info_program_command): Replace references
4177 to stop_pc with references to thread_info->suspend.stop_pc.
4178 * inferior.h (stop_pc): Delete declaration.
4179 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
4180 (handle_inferior_event_1, handle_signal_stop)
4181 (process_event_stop_test, keep_going_stepped_thread)
4182 (handle_step_into_function, handle_step_into_function_backward)
4183 (print_stop_location): Replace references to stop_pc with
4184 references to thread_info->suspend.stop_pc.
4185 (struct infcall_suspend_state) <stop_pc>: Delete field.
4186 (save_infcall_suspend_state, restore_infcall_suspend_state):
4187 Remove references to inf_stat->stop_pc.
4188 * linux-fork.c (fork_load_infrun_state): Likewise.
4189 * record-btrace.c (record_btrace_set_replay): Likewise.
4190 * record-full.c (record_full_goto_entry): Likewise.
4191 * remote.c (print_one_stopped_thread): Likewise.
4192 * target.c (target_resume): Extend comment.
4193 * thread.c (set_executing_thread): New.
4194 (set_executing): Use it.
4195 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
4196 Remove references to stop_pc.
4198 2018-06-28 Pedro Alves <palves@redhat.com>
4200 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
4201 Moving fetching stop_pc until after ecs->event_thread is refreshed.
4203 2018-06-28 Tom Tromey <tom@tromey.com>
4205 * coffread.c (coff_symfile_finish): Update.
4206 * xcoffread.c (xcoff_symfile_finish): Update.
4207 * elfread.c (elf_symfile_finish): Update.
4208 * symfile.h (dwarf2_free_objfile): Don't declare.
4209 * dwarf2read.c (_initialize_dwarf2_read): Use
4210 register_objfile_data_with_cleanup.
4211 (dwarf2_free_objfile): Now static. Change signature.
4213 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4215 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
4216 option "-o" to add-symbol-file-load to add an offset to each
4217 section's load address.
4218 * symfile.c (set_objfile_default_section_offset): New function.
4220 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4222 * symfile.c (add_symbol_file_command): Make sure that sections
4223 with the same name are sorted in the same order.
4225 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4227 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
4228 require the second argument. If omitted, load sections at the
4229 addresses specified in the file.
4231 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4233 * symfile.c (symbol_file_command, symbol_file_add_main_1)
4234 (_initialize_symfile): Add option "-o" to symbol-file to add an
4235 offset to each section of the symbol file.
4237 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4239 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
4241 2018-06-27 Tom Tromey <tom@tromey.com>
4243 * stack.c (_initialize_stack): Update "func" help text.
4245 2018-06-27 Tom Tromey <tom@tromey.com>
4247 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
4249 (unwind_infopy_str, pyuw_create_unwind_info)
4250 (unwind_infopy_add_saved_register, pyuw_sniffer)
4251 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
4253 (struct saved_reg): Add constructor.
4254 <value>: Now a gdbpy_ref<>.
4256 2018-06-27 Tom Tromey <tom@tromey.com>
4258 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
4260 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4262 * gdb-gdb.py.in: Format using autopep8.
4264 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4266 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
4267 (type_lookup_function): Recognize CORE_ADDR values.
4269 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4271 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
4274 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4276 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
4279 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4281 * gdb-gdb.py: Move to...
4282 * gdb-gdb.py.in: ... here.
4283 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
4284 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
4286 (distclean): Remove gdb-gdb.py when cleaning.
4287 (gdb-gdb.py, gdb-gdb.gdb): New rules.
4288 * configure: Re-generate.
4290 2018-06-27 Pedro Alves <palves@redhat.com>
4292 * proc-service.c (get_ps_regcache): New.
4293 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
4294 (ps_lsetfpregs): Use it.
4296 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
4299 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
4300 (dwarf_decode_lines_1): Adjust.
4302 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4304 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
4306 <info_proc>: Likewise.
4308 2018-06-26 Joel Brobecker <brobecker@adacore.com>
4310 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
4311 to windows_fetch_one_register, and only handle the case of
4312 fetching one register. Move the code that reloads the context
4313 and iterates over all registers if R is negative to...
4314 (windows_nat_target::fetch_registers): ... here.
4315 (do_windows_store_inferior_registers): Rename to
4316 windows_store_one_register, and only handle the case of storing
4317 one register. Move the code that handles the case where r is
4319 (windows_nat_target::store_registers) ... here.
4321 2018-06-26 Tom Tromey <tom@tromey.com>
4324 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
4325 * rust-lang.c (rust_print_struct_def): Add podata parameter.
4327 (rust_internal_print_type): Add podata parameter.
4328 (rust_print_type): Update.
4330 2018-06-26 Tom Tromey <tom@tromey.com>
4332 * typeprint.h (struct print_offset_data) <update, finish,
4333 maybe_print_hole>: New methods.
4334 <indentation>: New constant.
4335 * typeprint.c (print_offset_data::indentation): Define.
4336 (print_offset_data::maybe_print_hole, print_offset_data::update)
4337 (print_offset_data::finish): Move from c-typeprint.c and rename.
4338 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
4339 (print_spaces_filtered_with_print_options): Update.
4340 (c_print_type_union_field_offset, maybe_print_hole)
4341 (c_print_type_struct_field_offset): Move to typeprint.c and
4343 (c_type_print_base_struct_union): Update.
4345 2018-06-25 Pedro Alves <palves@redhat.com>
4347 * gdbthread.h (thread_info_ref, delete_thread)
4348 (delete_thread_silent, first_thread_of_inferior)
4349 (any_thread_of_inferior, switch_to_thread)
4350 (enable_thread_stack_temporaries)
4351 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4352 (get_last_thread_stack_temporary)
4353 (value_in_thread_stack_temporaries, can_access_registers_thread):
4354 Spell out "struct thread_info" instead of just "thread_info".
4355 * inferior.h (notice_new_inferior): Likewise.
4357 2018-06-25 Pedro Alves <palves@redhat.com>
4359 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4360 pass thread_info pointer to delete_thread.
4361 (windows_nat_target::detach): Pass inferior pointer to
4363 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
4365 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
4366 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
4367 and pass a thread_info pointer to delete_thread.
4368 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
4369 pass thread_info pointer to delete_thread.
4370 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
4371 delete_thread_silent call.
4372 * procfs.c (procfs_target::detach): Pass inferior pointer to
4374 (procfs_target::wait): Pass thread_info pointer to delete_thread.
4375 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
4376 delete_thread_silent call.
4377 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4378 pass thread_info pointer to delete_thread.
4379 (windows_nat_target::detach): Pass inferior pointer to
4382 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4384 * regcache.c (readable_regcache::read_part): Fix asserts.
4385 (reg_buffer::raw_collect_part): New function.
4386 (regcache::write_part): Fix asserts.
4387 (reg_buffer::raw_supply_part): New function.
4388 (regcache::transfer_regset_register): New helper function.
4389 (regcache::transfer_regset): Call new functions.
4390 (regcache_supply_regset): Use gdb_byte*.
4391 (regcache::supply_regset): Likewise.
4392 (regcache_collect_regset): Likewise.
4393 (regcache::collect_regset): Likewise.
4394 * regcache.h (reg_buffer::raw_collect_part): New declaration.
4395 (reg_buffer::raw_supply_part): Likewise.
4396 (regcache::transfer_regset_register): Likewise.
4397 (regcache::transfer_regset): Use gdb_byte*.
4399 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4401 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
4403 2018-06-21 Pedro Alves <palves@redhat.com>
4405 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
4406 instead of a ptid_t. All callers adjusted.
4407 * ada-tasks.c (ada_get_task_number): Likewise. All callers
4409 (print_ada_task_info, display_current_task_id, task_command_1):
4411 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
4413 (breakpoint_kind): Adjust.
4414 (remove_breakpoints_pid): Rename to ...
4415 (remove_breakpoints_inf): ... this. Adjust to take an inferior
4416 pointer. All callers adjusted.
4417 (bpstat_clear_actions): Use inferior_thread.
4418 (get_bpstat_thread): New.
4419 (bpstat_do_actions): Use it.
4420 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
4421 to take a thread_info pointer. All callers adjusted.
4422 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
4423 (breakpoint_re_set_thread): Use inferior_thread.
4424 * breakpoint.h (struct inferior): Forward declare.
4425 (bpstat_stop_status): Update.
4426 (remove_breakpoints_pid): Delete.
4427 (remove_breakpoints_inf): New.
4428 * bsd-uthread.c (bsd_uthread_target::wait)
4429 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
4430 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
4431 (maint_btrace_packet_history_cmd)
4432 (maint_btrace_clear_packet_history_cmd): Adjust.
4433 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
4435 * cli/cli-interp.c: Include "inferior.h".
4436 * common/refcounted-object.h (struct
4437 refcounted_object_ref_policy): New.
4438 * compile/compile-object-load.c: Include gdbthread.h.
4439 (store_regs): Use inferior_thread.
4440 * corelow.c (core_target::close): Use current_inferior.
4441 (core_target_open): Adjust to use first_thread_of_inferior and use
4442 the current inferior.
4443 * ctf.c (ctf_target::close): Adjust to use current_inferior.
4444 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
4445 <thread>: ... this new field. All references adjusted.
4446 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
4447 Take a thread_info pointer instead of a ptid_t.
4448 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
4449 (dummy_frame_discard, register_dummy_frame_dtor): Take a
4450 thread_info pointer instead of a ptid_t.
4451 * elfread.c: Include "inferior.h".
4452 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
4453 Use inferior_thread.
4454 * eval.c (evaluate_subexp): Likewise.
4455 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
4457 * gdb_proc_service.h (struct thread_info): Forward declare.
4458 (struct ps_prochandle) <ptid>: Delete, replaced by ...
4459 <thread>: ... this new field. All references adjusted.
4460 * gdbarch.h, gdbarch.c: Regenerate.
4461 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
4462 'thread' parameter. All implementations and callers adjusted.
4463 * gdbthread.h (thread_info) <set_running>: New method.
4464 (delete_thread, delete_thread_silent): Take a thread_info pointer
4466 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
4467 (first_thread_of_process): Delete, replaced by ...
4468 (first_thread_of_inferior): ... this new function. All callers
4470 (any_live_thread_of_process): Delete, replaced by ...
4471 (any_live_thread_of_inferior): ... this new function. All callers
4473 (switch_to_thread, switch_to_no_thread): Declare.
4474 (is_executing): Delete.
4475 (enable_thread_stack_temporaries): Update comment.
4476 <enable_thread_stack_temporaries>: Take a thread_info pointer
4477 instead of a ptid_t. Incref the thread.
4478 <~enable_thread_stack_temporaries>: Decref the thread.
4481 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4482 (get_last_thread_stack_temporary)
4483 (value_in_thread_stack_temporaries, can_access_registers_thread):
4484 Take a thread_info pointer instead of a ptid_t. All callers
4486 * infcall.c (get_call_return_value): Use inferior_thread.
4487 (run_inferior_call): Work with thread pointers instead of ptid_t.
4488 (call_function_by_hand_dummy): Work with thread pointers instead
4489 of ptid_t. Use thread_info_ref.
4490 * infcmd.c (proceed_thread_callback): Access thread's state
4492 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
4493 access thread's state directly.
4494 (continue_command): Use inferior_thread.
4495 (info_program_command): Use find_thread_ptid and access thread
4497 (proceed_after_attach_callback): Use thread state directly.
4498 (notice_new_inferior): Take a thread_info pointer instead of a
4499 ptid_t. All callers adjusted.
4500 (exit_inferior): Take an inferior pointer instead of a pid. All
4502 (exit_inferior_silent): New.
4503 (detach_inferior): Delete.
4504 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
4505 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
4506 (detach_inferior_command, kill_inferior_command): Use
4507 find_inferior_id instead of valid_gdb_inferior_id and
4508 gdb_inferior_id_to_pid.
4509 (inferior_command): Use inferior and thread pointers.
4510 * inferior.h (struct thread_info): Forward declare.
4511 (notice_new_inferior): Take a thread_info pointer instead of a
4512 ptid_t. All callers adjusted.
4513 (detach_inferior): Delete declaration.
4514 (exit_inferior, exit_inferior_silent): Take an inferior pointer
4515 instead of a pid. All callers adjusted.
4516 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
4517 (valid_gdb_inferior_id): Delete.
4518 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
4519 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
4520 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
4522 <inf>: ... this new field.
4523 <step_ptid>: Delete, replaced by ...
4524 <step_thread>: ... this new field.
4525 (get_displaced_stepping_state): Take an inferior pointer instead
4526 of a pid. All callers adjusted.
4527 (displaced_step_in_progress_any_inferior): Adjust.
4528 (displaced_step_in_progress_thread): Take a thread pointer instead
4529 of a ptid_t. All callers adjusted.
4530 (displaced_step_in_progress, add_displaced_stepping_state): Take
4531 an inferior pointer instead of a pid. All callers adjusted.
4532 (get_displaced_step_closure_by_addr): Adjust.
4533 (remove_displaced_stepping_state): Take an inferior pointer
4534 instead of a pid. All callers adjusted.
4535 (displaced_step_prepare_throw, displaced_step_prepare)
4536 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
4537 All callers adjusted.
4538 (start_step_over): Adjust.
4539 (infrun_thread_ptid_changed): Remove bit updating ptids in the
4540 displaced step queue.
4541 (do_target_resume): Adjust.
4542 (fetch_inferior_event): Use inferior_thread.
4543 (context_switch, get_inferior_stop_soon): Take an
4544 execution_control_state pointer instead of a ptid_t. All callers
4546 (switch_to_thread_cleanup): Delete.
4547 (stop_all_threads): Use scoped_restore_current_thread.
4548 * inline-frame.c: Include "gdbthread.h".
4549 (inline_state) <inline_state>: Take a thread pointer instead of a
4550 ptid_t. All callers adjusted.
4551 <ptid>: Delete, replaced by ...
4552 <thread>: ... this new field.
4553 (find_inline_frame_state): Take a thread pointer instead of a
4554 ptid_t. All callers adjusted.
4555 (skip_inline_frames, step_into_inline_frame)
4556 (inline_skipped_frames, inline_skipped_symbol): Take a thread
4557 pointer instead of a ptid_t. All callers adjusted.
4558 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
4559 (inline_skipped_frames, inline_skipped_symbol): Likewise.
4560 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
4562 * linux-nat.c (get_detach_signal): Likewise.
4563 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
4564 (thread_db_notice_clone): Adjust.
4565 (thread_db_find_new_threads_silently)
4566 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
4567 a thread pointer instead of a ptid_t. All callers adjusted.
4568 * mi/mi-cmd-var.c: Include "inferior.h".
4569 (mi_cmd_var_update_iter): Update to use thread pointers.
4570 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
4572 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
4574 (mi_output_running): ... this new function.
4575 (mi_on_resume_1): Adjust to use it.
4576 (mi_user_selected_context_changed): Adjust to use inferior_thread.
4577 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
4579 (interrupt_thread_callback): : Adjust to use thread and inferior
4581 * proc-service.c: Include "gdbthread.h".
4582 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
4583 * progspace-and-thread.c: Include "inferior.h".
4584 * progspace.c: Include "inferior.h".
4585 * python/py-exitedevent.c (create_exited_event_object): Adjust to
4586 hold a reference to an inferior_object.
4587 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
4589 * python/py-inferior.c (struct inferior_object): Give the type a
4590 tag name instead of a typedef.
4591 (python_on_normal_stop): No need to check if the current thread is
4593 (inferior_to_inferior_object): Change return type to
4594 inferior_object. All callers adjusted.
4595 (find_thread_object): Delete, bits factored out to ...
4596 (thread_to_thread_object): ... this new function.
4597 * python/py-infthread.c (create_thread_object): Use
4598 inferior_to_inferior_object.
4599 (thpy_is_stopped): Use thread pointer directly.
4600 (gdbpy_selected_thread): Use inferior_thread.
4601 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
4602 field, replaced with ...
4603 <thread>: ... this new field. All users adjusted.
4604 (btpy_insn_or_gap_new): Drop const.
4605 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
4607 * python/py-record.c: Include "gdbthread.h".
4608 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4609 a ptid_t. All callers adjusted.
4610 (gdbpy_current_recording): Use inferior_thread.
4611 * python/py-record.h (recpy_record_object) <ptid>: Delete
4612 field, replaced with ...
4613 <thread>: ... this new field. All users adjusted.
4614 (recpy_element_object) <ptid>: Delete
4615 field, replaced with ...
4616 <thread>: ... this new field. All users adjusted.
4617 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4618 a ptid_t. All callers adjusted.
4619 * python/py-threadevent.c: Include "gdbthread.h".
4620 (get_event_thread): Use thread_to_thread_object.
4621 * python/python-internal.h (struct inferior_object): Forward
4623 (find_thread_object, find_inferior_object): Delete declarations.
4624 (thread_to_thread_object, inferior_to_inferior_object): New
4626 * record-btrace.c: Include "inferior.h".
4627 (require_btrace_thread): Use inferior_thread.
4628 (record_btrace_frame_sniffer)
4629 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
4630 (get_thread_current_frame): Use scoped_restore_current_thread and
4632 (get_thread_current_frame): Use thread pointer directly.
4633 (record_btrace_replay_at_breakpoint): Use thread's inferior
4635 * record-full.c: Include "inferior.h".
4636 * regcache.c: Include "gdbthread.h".
4637 (get_thread_arch_regcache): Use the inferior's address space
4639 (get_thread_regcache, registers_changed_thread): New.
4640 * regcache.h (get_thread_regcache(thread_info *thread)): New
4642 (registers_changed_thread): New.
4643 (remote_target) <remote_detach_1>: Swap order of parameters.
4644 (remote_add_thread): <remote_add_thread>: Return the new thread.
4645 (get_remote_thread_info(ptid_t)): New overload.
4646 (remote_target::remote_notice_new_inferior): Use thread pointers
4648 (remote_target::process_initial_stop_replies): Use
4649 thread_info::set_running.
4650 (remote_target::remote_detach_1, remote_target::detach)
4651 (extended_remote_target::detach): Adjust.
4652 * stack.c (frame_show_address): Use inferior_thread.
4653 * target-debug.h (target_debug_print_thread_info_pp): New.
4654 * target-delegates.c: Regenerate.
4655 * target.c (default_thread_address_space): Delete.
4656 (memory_xfer_partial_1): Use current_inferior.
4657 (target_detach): Use current_inferior.
4658 (target_thread_address_space): Delete.
4659 (generic_mourn_inferior): Use current_inferior.
4660 * target.h (struct target_ops) <thread_address_space>: Delete.
4661 (target_thread_address_space): Delete.
4662 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
4664 (delete_thread_1, delete_thread, delete_thread_silent): Take a
4665 thread pointer instead of a ptid_t. Adjust all callers.
4666 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
4667 (first_thread_of_process): Delete, replaced by ...
4668 (first_thread_of_inferior): ... this new function. All callers
4670 (any_thread_of_process): Rename to ...
4671 (any_thread_of_inferior): ... this, and take an inferior pointer.
4672 (any_live_thread_of_process): Rename to ...
4673 (any_live_thread_of_inferior): ... this, and take an inferior
4675 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4676 (value_in_thread_stack_temporaries)
4677 (get_last_thread_stack_temporary): Take a thread pointer instead
4678 of a ptid_t. Adjust all callers.
4679 (thread_info::set_running): New.
4680 (validate_registers_access): Use inferior_thread.
4681 (can_access_registers_ptid): Rename to ...
4682 (can_access_registers_thread): ... this, and take a thread
4684 (print_thread_info_1): Adjust to compare thread pointers instead
4686 (switch_to_no_thread, switch_to_thread): Make extern.
4687 (scoped_restore_current_thread::~scoped_restore_current_thread):
4688 Use m_thread pointer directly.
4689 (scoped_restore_current_thread::scoped_restore_current_thread):
4690 Use inferior_thread.
4691 (thread_command): Use thread pointer directly.
4692 (thread_num_make_value_helper): Use inferior_thread.
4693 * top.c (execute_command): Use inferior_thread.
4694 * tui/tui-interp.c: Include "inferior.h".
4695 * varobj.c (varobj_create): Use inferior_thread.
4696 (value_of_root_1): Use find_thread_global_id instead of
4697 global_thread_id_to_ptid.
4699 2018-06-21 Alan Hayward <alan.hayward@arm.com>
4701 * regcache.c (readable_regcache::read_part): Avoid memcpy when
4703 (regcache::write_part): Likewise.
4704 (readable_regcache::cooked_read_part): Update comment.
4705 (readable_regcache::cooked_write_part): Likewise.
4706 * regcache.h: (readable_regcache::read_part): Likewise.
4707 (regcache::write_part): Likewise.
4709 2018-06-21 Richard Bunt <richard.bunt@arm.com>
4710 Dirk Schubert <dirk.schubert@arm.com>
4712 * aarch64-linux-nat.c (post_attach): New.
4713 (aarch64_linux_nat_target::post_attach): Override post_attach to
4714 record the number of hardware debug registers.
4716 2018-06-20 Tom Tromey <tom@tromey.com>
4718 * python/py-param.c (add_setshow_generic): Make parameters const.
4719 (parmpy_init): Update.
4721 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
4723 * regcache.h (regcache_cooked_read_ftype): Rename to...
4724 (register_read_ftype): ...this, change type to function_view.
4725 (class reg_buffer) <save>: Remove src parameter.
4726 (readonly_detached_regcache) <readonly_detached_regcache>: Make
4727 parameter non-const in first overload. Remove src parameter in
4729 * regcache.c (do_cooked_read): Remove.
4730 (readonly_detached_regcache::readonly_detached_regcache): Make
4731 parameter non-const, adjust call to other constructor.
4732 (reg_buffer::save): Remove src parameter.
4733 * frame.c (do_frame_register_read): Remove.
4734 (frame_save_as_regcache): Use lambda function.
4735 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
4736 parameter to ppu2spu_data *.
4737 (ppu2spu_sniffer): Use lambda function.
4739 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
4741 * record-full.c (record_full_target::insert_breakpoint): Remove
4742 "struct" keyword, add const.
4744 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
4746 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
4747 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
4748 * configure.ac: Remove AC_PREREQ, add missing quoting.
4749 * gnulib/configure.ac: Modernize usage of
4750 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
4751 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
4752 (AUTOMAKE_VERSION): Bump to 1.15.1.
4753 * configure: Re-generate.
4754 * config.in: Re-generate.
4755 * aclocal.m4: Re-generate.
4756 * gnulib/aclocal.m4: Re-generate.
4757 * gnulib/config.in: Re-generate.
4758 * gnulib/configure: Re-generate.
4759 * gnulib/import/Makefile.in: Re-generate.
4761 2018-06-19 Pedro Alves <palves@redhat.com>
4763 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
4764 (lookup_minimal_symbol_by_pc_section): ... here with
4765 gdb_assert_not_reached added.
4767 2018-06-19 Pedro Alves <palves@redhat.com>
4769 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
4770 parameter with a block parameter. Compare location's block symbol
4771 with the frame's block instead of addresses.
4772 (skip_inline_frames): Pass the current block instead of the
4773 frame's address. Break out as soon as we determine the frame
4774 should not be skipped.
4776 2018-06-18 Tom Tromey <tom@tromey.com>
4778 * solib-aix.c (solib_aix_get_section_offsets): Return
4780 (solib_aix_solib_create_inferior_hook): Update.
4782 2018-06-18 Tom Tromey <tom@tromey.com>
4784 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
4786 2018-06-18 Tom Tromey <tom@tromey.com>
4788 * solib-frv.c (frv_relocate_main_executable): Use
4790 * solib-dsbt.c (dsbt_relocate_main_executable): Use
4793 2018-06-18 Tom Tromey <tom@tromey.com>
4795 * objfiles.h (inhibit_section_map_updates): Update.
4796 (resume_section_map_updates, resume_section_map_updates_cleanup):
4798 * solib-svr4.c (svr4_handle_solib_event): Update.
4799 * objfiles.c (inhibit_section_map_updates): Return
4800 scoped_restore_tmpl<int>.
4801 (resume_section_map_updates, resume_section_map_updates_cleanup):
4804 2018-06-18 Tom Tromey <tom@tromey.com>
4806 * valprint.h (read_string): Update.
4807 * valprint.c (read_string): Change type of "buffer".
4808 (val_print_string): Update.
4809 * python/py-value.c (valpy_string): Update.
4810 * language.h (struct language_defn) <la_get_string>: Change
4812 (default_get_string, c_get_string): Update.
4813 * language.c (default_get_string): Change type of "buffer".
4814 * guile/scm-value.c (gdbscm_value_to_string): Update.
4815 * c-lang.c (c_get_string): Change type of "buffer".
4817 2018-06-18 Tom Tromey <tom@tromey.com>
4819 * ser-mingw.c (struct pipe_state_destroyer): New.
4820 (pipe_state_up): New typedef.
4821 (cleanup_pipe_state): Remove.
4822 (pipe_windows_open): Use pipe_state_up. Don't release argv.
4824 2018-06-18 Tom Tromey <tom@tromey.com>
4826 * rust-lang.h (rust_yyerror): Don't declare.
4827 * rust-lang.c (rust_language_defn): Update.
4828 * rust-exp.y (yyerror): Now static.
4829 * parse.c (parse_exp_in_context_1): Update.
4830 * p-lang.h (p_yyerror): Don't declare.
4831 * p-lang.c (p_language_defn): Update.
4832 * p-exp.y (yyerror): Now static.
4833 * opencl-lang.c (opencl_language_defn): Update.
4834 * objc-lang.c (objc_language_defn): Update.
4835 * m2-lang.h (m2_yyerror): Don't declare.
4836 * m2-lang.c (m2_language_defn): Update.
4837 * m2-exp.y (yyerror): Now static.
4838 * language.h (struct language_defn) <la_error>: Remove.
4839 * language.c (unk_lang_error): Remove.
4840 (unknown_language_defn, auto_language_defn): Remove.
4841 * go-lang.h (go_yyerror): Don't declare.
4842 * go-lang.c (go_language_defn): Update.
4843 * go-exp.y (yyerror): Now static.
4844 * f-lang.h (f_yyerror): Don't declare.
4845 * f-lang.c (f_language_defn): Update.
4846 * f-exp.y (yyerror): Now static.
4847 * d-lang.h (d_yyerror): Don't declare.
4848 * d-lang.c (d_language_defn): Update.
4849 * d-exp.y (yyerror): Now static.
4850 * c-lang.h (c_yyerror): Don't declare.
4851 * c-lang.c (c_language_defn, cplus_language_defn)
4852 (asm_language_defn, minimal_language_defn): Update.
4853 * c-exp.y (yyerror): Now static.
4854 * ada-lang.h (ada_yyerror): Don't declare.
4855 * ada-lang.c (ada_language_defn): Update.
4856 * ada-exp.y (yyerror): Now static.
4858 2018-06-18 Alan Hayward <alan.hayward@arm.com>
4860 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
4861 (store_sveregs_to_thread): Likewise.
4862 (aarch64_linux_fetch_inferior_registers): Check for SVE.
4863 (aarch64_linux_store_inferior_registers): Likewise.
4864 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
4866 (aarch64_sve_regs_copy_to_regcache): Likewise.
4867 (aarch64_sve_regs_copy_from_regcache): Likewise.
4868 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
4870 (aarch64_sve_regs_copy_to_regcache): Likewise.
4871 (aarch64_sve_regs_copy_from_regcache): Likewise.
4872 (sve_context): Structure from Linux headers.
4873 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
4874 (SVE_SIG_ZREG_SIZE): Likewise.
4875 (SVE_SIG_PREG_SIZE): Likewise.
4876 (SVE_SIG_FFR_SIZE): Likewise.
4877 (SVE_SIG_REGS_OFFSET): Likewise.
4878 (SVE_SIG_ZREGS_OFFSET): Likewise.
4879 (SVE_SIG_ZREG_OFFSET): Likewise.
4880 (SVE_SIG_ZREGS_SIZE): Likewise.
4881 (SVE_SIG_PREGS_OFFSET): Likewise.
4882 (SVE_SIG_PREG_OFFSET): Likewise.
4883 (SVE_SIG_PREGS_SIZE): Likewise.
4884 (SVE_SIG_FFR_OFFSET): Likewise.
4885 (SVE_SIG_REGS_SIZE): Likewise.
4886 (SVE_SIG_CONTEXT_SIZE): Likewise.
4887 (SVE_PT_REGS_MASK): Likewise.
4888 (SVE_PT_REGS_FPSIMD): Likewise.
4889 (SVE_PT_REGS_SVE): Likewise.
4890 (SVE_PT_VL_INHERIT): Likewise.
4891 (SVE_PT_VL_ONEXEC): Likewise.
4892 (SVE_PT_REGS_OFFSET): Likewise.
4893 (SVE_PT_FPSIMD_OFFSET): Likewise.
4894 (SVE_PT_FPSIMD_SIZE): Likewise.
4895 (SVE_PT_SVE_ZREG_SIZE): Likewise.
4896 (SVE_PT_SVE_PREG_SIZE): Likewise.
4897 (SVE_PT_SVE_FFR_SIZE): Likewise.
4898 (SVE_PT_SVE_FPSR_SIZE): Likewise.
4899 (SVE_PT_SVE_FPCR_SIZE): Likewise.
4900 (__SVE_SIG_TO_PT): Likewise.
4901 (SVE_PT_SVE_OFFSET): Likewise.
4902 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
4903 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
4904 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
4905 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
4906 (SVE_PT_SVE_PREG_OFFSET): Likewise.
4907 (SVE_PT_SVE_PREGS_SIZE): Likewise.
4908 (SVE_PT_SVE_FFR_OFFSET): Likewise.
4909 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
4910 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
4911 (SVE_PT_SVE_SIZE): Likewise.
4912 (SVE_PT_SIZE): Likewise.
4913 (HAS_SVE_STATE): New define.
4915 2018-06-18 Alan Hayward <alan.hayward@arm.com>
4917 * nat/aarch64-sve-linux-sigcontext.h: New file.
4918 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
4920 (SVE_VQ_MIN): Likewise.
4921 (SVE_VQ_MAX): Likewise.
4922 (SVE_VL_MIN): Likewise.
4923 (SVE_VL_MAX): Likewise.
4924 (SVE_NUM_ZREGS): Likewise.
4925 (SVE_NUM_PREGS): Likewise.
4926 (sve_vl_valid): Likewise.
4927 (struct user_sve_header): Likewise.
4929 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
4930 Richard Bunt <Richard.Bunt@arm.com>
4932 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
4933 was requested by GDB.
4935 2018-06-15 Tom de Vries <tdevries@suse.de>
4937 * MAINTAINERS (Write After Approval): Add Tom de Vries.
4939 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
4941 * gnulib/update-gnulib.sh: Print expected versions of
4944 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
4946 * arch-utils.c (default_type_align): Use type_length_units.
4947 * gdbtypes.c (type_align): Use type_length_units.
4949 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4951 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
4952 of 'define' command.
4954 2018-06-14 Tom de Vries <tdevries@suse.de>
4957 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
4958 get_no_prettyformat_print_options.
4960 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
4962 * sparc-nat.h: Include target.h.
4963 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
4964 <fetch_registers>: Remove this argument in function call.
4965 <store_registers>: Remove this argument in function call, remove
4967 <low_forget_process>: Call sparc64_forget_process instead of
4968 sparc_forget_process.
4970 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4972 * procfs.c (_initialize_procfs): Use add_inf_child_target.
4973 (procfs_target::make_corefile_notes): Adjust to new
4974 target_read_alloc return type.
4976 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
4977 Stephen Roberts <stephen.roberts@arm.com>
4980 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
4981 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
4982 Move should_notify_stop local into more inner scope.
4984 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
4985 Stephen Roberts <stephen.roberts@arm.com>
4988 * infrun.c (resume_1): Add call to mark_async_event_handler.
4990 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
4992 * infrun.c (do_target_wait): Change old version of $pc printed.
4994 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
4996 * dwarf2read.c (read_index_from_section): Rename to...
4997 (read_gdb_index_from_section): ... this, update all callers.
4998 (dwarf2_read_index): Rename to...
4999 (dwarf2_read_gdb_index): ... this, update all callers.
5001 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
5003 * gdb/hppa-linux-nat.c
5004 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
5005 hppa_linux_nat_target::fetch_registers.
5007 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5009 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
5010 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
5011 (AARCH64_DWARF_SVE_FFR): Likewise.
5012 (AARCH64_DWARF_SVE_P0): Likewise.
5013 (AARCH64_DWARF_SVE_Z0): Likewise.
5015 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5017 * common/common-regcache.h (raw_compare): New function.
5018 * regcache.c (regcache::raw_compare): Likewise.
5019 * regcache.h (regcache::raw_compare): New declaration.
5021 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5023 * common/common-regcache.h (reg_buffer_common): New structure.
5024 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
5025 (reg_buffer::raw_supply): Likewise.
5026 (reg_buffer::raw_supply_integer): Likewise.
5027 (reg_buffer::raw_supply_zeroed): Likewise.
5028 (reg_buffer::raw_collect): Likewise.
5029 (reg_buffer::raw_collect_integer): Likewise.
5030 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
5031 (reg_buffer::raw_supply): Likewise.
5032 (reg_buffer::raw_supply_integer): Likewise.
5033 (reg_buffer::raw_supply_zeroed): Likewise.
5034 (reg_buffer::raw_collect): Likewise.
5035 (reg_buffer::raw_collect_integer): Likewise.
5037 2018-06-10 Tom Tromey <tom@tromey.com>
5039 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
5040 (class remote_state) <stop_reply_queue>: Now std::vector.
5041 (remote_state::~remote_state)
5042 (remote_target::stop_reply_queue_length): Update.
5043 (struct queue_iter_param, remove_child_of_pending_fork)
5044 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
5045 (check_pending_event_prevents_wildcard_vcont_callback)
5046 (remove_stop_reply_for_inferior)
5047 (remove_stop_reply_of_remote_state)
5048 (remote_notif_remove_once_on_match)
5049 (stop_reply_match_ptid_and_ws)
5050 (remote_kill_child_of_pending_fork): Remove.
5051 (remote_target::remove_new_fork_children)
5052 (remote_target::check_pending_events_prevent_wildcard_vcont)
5053 (remote_target::discard_pending_stop_replies)
5054 (remote_target::discard_pending_stop_replies_in_queue)
5055 (remote_target::remote_notif_remove_queued_reply)
5056 (remote_target::queued_stop_reply)
5057 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
5058 (remote_target::wait, remote_target::kill_new_fork_children)
5059 (remote_target::async): Update.
5061 2018-06-10 Tom Tromey <tom@tromey.com>
5063 * record-full.c (record_full_arch_list_cleanups): Remove.
5064 (record_full_message): Use try/catch.
5065 (record_full_wait_cleanups): Remove.
5066 (record_full_wait_1): Use try/catch.
5067 (record_full_restore): Likewise.
5069 2018-06-10 Tom Tromey <tom@tromey.com>
5071 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
5072 declare VEC. Add constructor.
5073 <in_target_beneath>: Now bool.
5074 (record_full_breakpoints): Now a std::vector, static.
5075 (record_full_sync_record_breakpoints)
5076 (record_full_init_record_breakpoints)
5077 (record_full_target::insert_breakpoint)
5078 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
5080 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
5082 * dwarf2read.c (process_cu_includes): Remove struct keyword.
5083 * serial.c (serial_interface_lookup): Remove struct keyword.
5085 2018-06-10 Tom Tromey <tom@tromey.com>
5087 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
5089 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
5091 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
5093 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
5094 "beneath" as a method.
5095 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
5096 Use "beneath" as a method.
5098 2018-06-10 Tom Tromey <tom@tromey.com>
5100 * tracefile.c (struct trace_file_writer_deleter): New.
5101 <operator()>: Rename from trace_file_writer_xfree.
5102 (trace_file_writer_up): New typedef.
5103 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
5105 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5107 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
5108 <m_registers, m_register_status>: Change type to
5110 * regcache.c (reg_buffer::reg_buffer): Use new instead of
5113 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5115 * common/common-regcache.h (enum register_status): Add
5116 underlying type "signed char".
5117 * regcache.h (reg_buffer) <m_register_status>: Change type to
5119 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
5120 register_status instead of signed char.
5121 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
5122 (reg_buffer::get_register_status): Remove cast.
5123 (readable_regcache::raw_read): Remove cast.
5124 (readable_regcache::cooked_read): Remove cast.
5126 2018-06-09 Tom Tromey <tom@tromey.com>
5128 * source.c (reverse_search_command, forward_search_command): Use
5131 2018-06-09 Tom Tromey <tom@tromey.com>
5133 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
5134 (serial_ops_list): Now static, std::vector.
5135 (serial_interface_lookup, serial_add_interface): Update.
5137 2018-06-09 Tom Tromey <tom@tromey.com>
5139 * dwarf2read.c (process_cu_includes): Update.
5140 (process_full_comp_unit): Update.
5141 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
5144 2018-06-08 Paul Koning <paul_koning@dell.com>
5148 * python/python.c (do_start_initialization):
5149 Avoid call to internal Python API.
5150 (init__gdb_module): New function.
5152 2018-06-08 Gary Benson <gbenson@redhat.com>
5154 * linux-thread-db.c (valprint.h): New include.
5155 (struct check_thread_db_info): New structure.
5156 (check_thread_db_on_load, tdb_testinfo): New static globals.
5157 (check_thread_db, check_thread_db_callback): New functions.
5158 (try_thread_db_load_1): Run integrity checks if requested.
5159 (maintenance_check_libthread_db): New function.
5160 (_initialize_thread_db): Register "maint check libthread-db"
5161 and "maint set/show check-libthread-db".
5162 * NEWS: Mention the above new commands.
5164 2018-06-08 Tom Tromey <tom@tromey.com>
5166 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
5169 2018-06-08 Tom Tromey <tom@tromey.com>
5171 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
5173 2018-06-08 Tom Tromey <tom@tromey.com>
5175 * common/btrace-common.h (struct btrace_data): Add constructor,
5176 destructor, move assignment operator.
5177 <empty, clear, fini>: New methods.
5178 <format>: Initialize.
5179 (btrace_data_init, btrace_data_fini, btrace_data_clear)
5180 (btrace_data_empty): Don't declare.
5181 * common/btrace-common.c (btrace_data_init): Remove.
5182 (btrace_data::fini): Rename from btrace_data_fini.
5183 (btrace_data::empty): Rename from btrace_data_empty.
5184 (btrace_data::clear): Rename from btrace_data_clear. Return
5186 * btrace.h (make_cleanup_btrace_data): Don't declare.
5187 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
5188 (parse_xml_btrace): Update.
5189 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
5190 (maint_btrace_clear_packet_history_cmd): Update.
5192 2018-06-07 Pedro Alves <palves@redhat.com>
5194 * target.h (target_ops) <beneath>: Now a method. All references
5196 (class target_stack): New.
5197 * target.c (g_target_stack): New.
5198 (g_current_top_target): Delete.
5199 (current_top_target): Get the top target out of g_target_stack.
5200 (target_stack::push, target_stack::unpush): New.
5201 (push_target, unpush_target): Reimplement.
5202 (target_is_pushed): Reimplement in terms of g_target_stack.
5203 (target_ops::beneath, target_stack::find_beneath): New.
5205 2018-06-07 Pedro Alves <palves@redhat.com>
5207 * target.h (find_target_beneath): Delete declaration.
5208 * target.c (find_target_beneath): Delete definition.
5209 * aix-thread.c: All callers of find_target_beneath adjusted to
5210 call target_ops::beneath instead.
5211 * bsd-uthread.c: Likewise.
5212 * linux-thread-db.c: Likewise.
5213 * ravenscar-thread.c: Likewise.
5214 * sol-thread.c: Likewise.
5215 * spu-multiarch.c: Likewise.
5217 2018-06-07 Pedro Alves <palves@redhat.com>
5219 * target.h (target_ops) <beneath>: Now a method. All references
5221 (target_ops) <m_beneath>: New.
5222 * target.c (target_ops::beneath): New.
5223 * corelow.c: Adjust all references to target_ops::beneath.
5224 * linux-thread-db.c: Likewise.
5225 * make-target-delegates: Likewise.
5226 * record-btrace.c: Likewise.
5227 * record-full.c: Likewise.
5228 * remote.c: Likewise.
5229 * target.c: Likewise.
5230 * target-delegates.c: Regenerate.
5232 2018-06-07 Pedro Alves <palves@redhat.com>
5234 * target.h (target_stack): Delete.
5235 (current_top_target): Declare function.
5236 * target.c (target_stack): Delete.
5237 (g_current_top_target): New.
5238 (current_top_target): New function.
5239 * auxv.c: Use current_top_target instead of target_stack
5241 * avr-tdep.c: Likewise.
5242 * breakpoint.c: Likewise.
5243 * corefile.c: Likewise.
5244 * elfread.c: Likewise.
5246 * exceptions.c: Likewise.
5247 * frame.c: Likewise.
5248 * gdbarch-selftests.c: Likewise.
5249 * gnu-v3-abi.c: Likewise.
5250 * ia64-tdep.c: Likewise.
5251 * ia64-vms-tdep.c: Likewise.
5252 * infcall.c: Likewise.
5253 * infcmd.c: Likewise.
5254 * infrun.c: Likewise.
5255 * linespec.c: Likewise.
5256 * linux-tdep.c: Likewise.
5257 * minsyms.c: Likewise.
5258 * ppc-linux-nat.c: Likewise.
5259 * ppc-linux-tdep.c: Likewise.
5260 * procfs.c: Likewise.
5261 * regcache.c: Likewise.
5262 * remote.c: Likewise.
5263 * rs6000-tdep.c: Likewise.
5264 * s390-linux-nat.c: Likewise.
5265 * s390-tdep.c: Likewise.
5266 * solib-aix.c: Likewise.
5267 * solib-darwin.c: Likewise.
5268 * solib-dsbt.c: Likewise.
5269 * solib-spu.c: Likewise.
5270 * solib-svr4.c: Likewise.
5271 * solib-target.c: Likewise.
5272 * sparc-tdep.c: Likewise.
5273 * sparc64-tdep.c: Likewise.
5274 * spu-tdep.c: Likewise.
5275 * symfile.c: Likewise.
5276 * symtab.c: Likewise.
5277 * target-descriptions.c: Likewise.
5278 * target-memory.c: Likewise.
5279 * target.c: Likewise.
5280 * target.h: Likewise.
5281 * tracefile-tfile.c: Likewise.
5282 * tracepoint.c: Likewise.
5283 * valops.c: Likewise.
5284 * valprint.c: Likewise.
5285 * value.c: Likewise.
5286 * windows-tdep.c: Likewise.
5287 * mi/mi-main.c: Likewise.
5289 2018-06-07 Tom Tromey <tom@tromey.com>
5291 * valprint.h (build_address_symbolic): Declare.
5292 * printcmd.c (print_address_symbolic): Update.
5293 (build_address_symbolic): Change "name" and "filename" to
5295 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
5297 * defs.h (build_address_symbolic): Remove declaration.
5299 2018-06-07 Alan Hayward <alan.hayward@arm.com>
5301 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
5302 (aarch64_vnv_type): Add function.
5303 (aarch64_pseudo_register_name): Add V regs for SVE.
5304 (aarch64_pseudo_register_type): Likewise.
5305 (aarch64_pseudo_register_reggroup_p): Likewise.
5306 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
5307 (aarch64_pseudo_read_value): Add V regs for SVE.
5308 (aarch64_pseudo_write_2): Use V0 offset for SVE
5309 (aarch64_pseudo_write): Add V regs for SVE.
5310 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
5312 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
5314 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
5315 (sve_vl_from_vq): Likewise.
5317 2018-06-05 Tom Tromey <tom@tromey.com>
5319 * cli/cli-cmds.c (show_version): Update.
5320 * top.c (print_gdb_version): Add "interactive" parameter.
5322 * main.c (captured_main_1): Update.
5323 * top.h (print_gdb_version): Add "interactive" parameter and a
5326 2018-06-05 David Malcolm <dmalcolm@redhat.com>
5328 * common/enum-flags.h: Add trailing semicolon to example in
5331 2018-06-05 Tom Tromey <tom@tromey.com>
5334 * NEWS: Add entry about pager.
5335 * utils.c (pagination_disabled_for_command): New global.
5336 (prompt_for_continue): Allow "c" response to prompt.
5337 (reinitialize_more_filter): Clear
5338 pagination_disabled_for_command.
5339 (fputs_maybe_filtered): Check pagination_disabled_for_command.
5341 2018-06-04 Tom Tromey <tom@tromey.com>
5343 * ada-lang.h (ada_lookup_symbol_list): Update.
5344 * ada-lang.c (resolve_subexp): Update.
5345 (symbols_are_identical_enums): Change type of syms. Remove nsyms
5347 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
5348 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
5349 results parameter to std::vector.
5350 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
5352 * ada-exp.y (block_lookup): Update.
5353 (select_possible_type_sym): Change type of syms. Remove nsyms
5355 (write_var_or_type, write_name_assoc): Update.
5357 2018-06-04 Joel Brobecker <brobecker@adacore.com>
5359 * windows-nat.c (windows_nat_target::xfer_partial): Return
5360 TARGET_XFER_E_IO if we need to delegate to the target beneath
5361 but BENEATH is NULL.
5363 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
5365 * Makefile.in (config.status): Add configure.nat as a
5368 2018-06-04 Tom Tromey <tom@tromey.com>
5370 * cp-name-parser.y (cpname_state): Add method declarations.
5371 (HANDLE_QUAL): Update.
5372 (cpname_state::d_grab, cpname_state::fill_comp)
5373 (cpname_state::make_operator, cpname_state::make_dtor)
5374 (cpname_state::make_builtin_type, cpname_state::make_name)
5375 (cpname_state::d_qualify, cpname_state::d_int_type)
5376 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
5377 (%union): Move earlier.
5379 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5381 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
5383 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5385 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
5386 (aarch64_pseudo_write_1): Likewise.
5387 (aarch64_pseudo_read_value): Use helper.
5388 (aarch64_pseudo_write): Likewise.
5390 2018-06-04 Pedro Alves <palves@redhat.com>
5392 * darwin-nat.c (darwin_ops): Delete.
5393 (darwin_attach_pid): Use get_native_target.
5395 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5397 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
5398 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
5400 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5402 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
5403 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
5404 (aarch64_gdbarch_init): Check for SVE.
5405 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
5407 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5409 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
5410 * aarch64-tdep.h (aarch64_read_description): Likewise.
5411 * arch/aarch64.c (aarch64_create_target_description): Likewise.
5412 * arch/aarch64.h (aarch64_create_target_description): Likewise.
5413 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
5414 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
5415 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
5417 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
5419 * value.c (value_fetch_lazy_bitfield): New.
5420 (value_fetch_lazy_memory): New.
5421 (value_fetch_lazy_register): New.
5422 (value_fetch_lazy): Factor out to smaller functions.
5424 2018-06-01 Tom Tromey <tom@tromey.com>
5426 * cp-name-parser.y (backslashable, represented): Now const.
5428 2018-06-01 Tom Tromey <tom@tromey.com>
5430 * cp-name-parser.y: Include parser-defs.h.
5431 (parser_fprintf): Remove declaration.
5433 2018-06-01 Tom Tromey <tom@tromey.com>
5435 * cp-name-parser.y: Use %pure-parser, %lex-param, and
5437 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
5438 (global_result): Remove globals.
5439 (struct cpname_state): New.
5440 (yyparse): Don't declare.
5441 (yylex, yyerror): Move declarations after %union.
5442 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
5443 (make_name): Add state parameter.
5445 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
5447 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
5449 (yylex): Add lvalp, state parameters.
5450 (yyerror): Add state parameter.
5451 (cp_demangled_name_to_comp): Update.
5453 2018-06-01 Tom Tromey <tom@tromey.com>
5455 * cp-name-parser.y (parser_fprintf): Declare.
5456 (GDB_YY_REMAP_PREFIX): Define.
5457 Include yy-remap.h. Don't redefine yy* identifiers.
5459 2018-06-01 Tom Tromey <tom@tromey.com>
5461 * python/py-type.c (typy_legacy_template_argument): Update.
5462 * cp-support.h (cp_demangled_name_to_comp): Update.
5463 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
5464 parameter to be a "std::string *".
5467 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
5469 * ada-lex.l: Include "diagnostics.h" instead of
5470 "common/diagnostics.h".
5471 * unittests/environ-selftests.c: Likewise.
5472 * common/diagnostics.h: Moved to ../include.
5474 2018-06-01 Joel Brobecker <brobecker@adacore.com>
5476 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
5477 to language_mode_manual while calling breakpoint_re_set_one.
5479 2018-06-01 Tom Tromey <tom@tromey.com>
5481 * valops.c (value_cast_structs, destructor_name_p): Update.
5482 * symtab.c (gdb_mangle_name): Update.
5483 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
5485 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
5486 (pascal_object_print_value_fields, pascal_object_print_value):
5488 * p-typeprint.c (pascal_type_print_derivation_info): Update.
5489 * linespec.c (find_methods): Update.
5490 * gdbtypes.h (type_name_no_tag): Remove.
5491 (type_name_or_error): Rename from type_name_no_tag_or_error.
5492 * gdbtypes.c (type_name_no_tag): Remove.
5493 (type_name_or_error): Rename from type_name_no_tag_or_error.
5494 (lookup_struct_elt_type, check_typedef): Update.
5495 * expprint.c (print_subexp_standard): Update.
5496 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
5497 * d-namespace.c (d_lookup_nested_symbol): Update.
5498 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
5499 (cp_print_class_member): Update.
5500 * cp-namespace.c (cp_lookup_nested_symbol): Update.
5501 * completer.c (add_struct_fields): Update.
5502 * c-typeprint.c (cp_type_print_derivation_info)
5503 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
5505 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
5506 (ada_prefer_type, ada_is_exception_sym): Update.
5508 2018-06-01 Tom Tromey <tom@tromey.com>
5510 * valops.c (enum_constant_from_type, value_namespace_elt)
5511 (value_maybe_namespace_elt): Update.
5512 * valarith.c (find_size_for_pointer_math): Update.
5513 * target-descriptions.c (make_gdb_type): Update.
5514 * symmisc.c (print_symbol): Update.
5515 * stabsread.c (define_symbol, read_type)
5516 (complain_about_struct_wipeout, add_undefined_type)
5517 (cleanup_undefined_types_1): Update.
5518 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
5519 (rust_range_type_p, val_print_struct, rust_print_struct_def)
5520 (rust_internal_print_type, rust_composite_type)
5521 (rust_evaluate_funcall, rust_evaluate_subexp)
5522 (rust_inclusive_range_type_p): Update.
5523 * python/py-type.c (typy_get_tag): Update.
5524 * p-typeprint.c (pascal_type_print_base): Update.
5525 * mdebugread.c (parse_symbol, parse_type): Update.
5526 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
5528 * guile/scm-type.c (gdbscm_type_tag): Update.
5529 * go-lang.c (sixg_string_p): Update.
5530 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
5532 * gdbtypes.h (struct main_type) <tag_name>: Remove.
5533 (TYPE_TAG_NAME): Remove.
5534 * gdbtypes.c (type_name_no_tag): Simplify.
5535 (check_typedef, check_types_equal, recursive_dump_type)
5536 (copy_type_recursive, arch_composite_type): Update.
5537 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
5538 in summary mode when needed.
5539 * eval.c (evaluate_funcall): Update.
5540 * dwarf2read.c (fixup_go_packaging, read_structure_type)
5541 (process_structure_scope, read_enumeration_type)
5542 (read_namespace_type, read_module_type, determine_prefix): Update.
5543 * cp-support.c (inspect_type): Update.
5544 * coffread.c (process_coff_symbol, decode_base_type): Update.
5545 * c-varobj.c (c_is_path_expr_parent): Update.
5546 * c-typeprint.c (c_type_print_base_struct_union): Update.
5547 (c_type_print_base_1): Update. Print struct/class/union/enum in
5548 summary when using C language.
5549 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
5550 (gen_maybe_namespace_elt): Update.
5551 * ada-lang.c (ada_type_name): Simplify.
5552 (empty_record, ada_template_to_fixed_record_type_1)
5553 (template_to_static_fixed_type)
5554 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
5556 2018-06-01 Tom Tromey <tom@tromey.com>
5558 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
5560 * c-typeprint.c (c_print_type_1): Add "language" parameter.
5561 (c_print_type): Update.
5562 (c_print_type): New overload.
5563 (c_type_print_varspec_prefix, c_type_print_args)
5564 (c_type_print_varspec_suffix, c_print_type_no_offsets)
5565 (c_type_print_base_struct_union, c_type_print_base_1)
5566 (cp_type_print_method_args): Add "language" parameter.
5567 (c_type_print_base): Update.
5568 * c-lang.h (c_print_type): Add new overload.
5570 2018-06-01 Tom Tromey <tom@tromey.com>
5572 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
5573 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
5575 2018-06-01 Alan Hayward <alan.hayward@arm.com>
5577 * aarch64-tdep.c (aarch64_sve_register_names): New const
5579 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
5580 (AARCH64_SVE_Z_REGS_NUM): New define.
5581 (AARCH64_SVE_P_REGS_NUM): Likewise.
5582 (AARCH64_SVE_NUM_REGS): Likewise.
5584 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
5586 * nat/linux-ptrace.h [__alpha__]
5587 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
5590 2018-05-31 Maciej W. Rozycki <macro@mips.com>
5592 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
5593 the endianness selected.
5594 * NEWS: Document `set endian auto' mode operation update.
5596 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5598 * Makefile.in: Add new header.
5599 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
5600 (sve_vl_from_vg): Likewise.
5601 (sve_vq_from_vl): Likewise.
5602 (sve_vl_from_vq): Likewise.
5603 (sve_vq_from_vg): Likewise.
5604 (sve_vg_from_vq): Likewise.
5605 * configure.nat: Add new c file.
5606 * nat/aarch64-sve-linux-ptrace.c: New file.
5607 * nat/aarch64-sve-linux-ptrace.h: New file.
5609 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5611 * aarch64-linux-nat.c (aarch64_linux_read_description):
5613 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
5615 * aarch64-tdep.c (tdesc_aarch64_list): Add.
5616 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
5617 (aarch64_gdbarch_init): Add parmeter zero.
5618 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
5619 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
5620 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
5622 * doc/gdb.texinfo: Describe SVE feature
5623 * features/aarch64-sve.c: New file.
5625 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
5628 * gdbarch.sh (significant_addr_bit): Default to zero when
5629 not set by target architecture.
5630 * gdbarch.c: Re-generated.
5631 * utils.c (address_significant): Update.
5633 2018-05-30 Joel Brobecker <brobecker@adacore.com>
5635 * stack.c (func_command): Remove trailing newline in call to error.
5637 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5639 * regcache.h (regcache_raw_collect): Remove, update callers to
5640 use regcache::raw_collect.
5641 * regcache.c (regcache_raw_collect): Remove.
5643 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5645 * regcache.h (regcache_raw_supply): Remove, update callers to
5646 use detached_regcache::raw_supply.
5647 * regcache.c (regcache_raw_supply): Remove.
5649 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5651 * regcache.h (regcache_cooked_write_part): Remove, update
5652 callers to use regcache::cooked_write_part.
5653 * regcache.c (regcache_cooked_write_part): Remove.
5655 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5657 * regcache.h (regcache_cooked_read_part): Remove, update callers
5658 to use readable_regcache::cooked_read_part.
5659 * regcache.c (regcache_cooked_read_part): Remove.
5661 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5663 * regcache.h (regcache_cooked_read_value): Remove, update
5664 callers to use readable_regcache::cooked_read_value.
5665 * regcache.c (regcache_cooked_read_value): Remove.
5667 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5669 * regcache.h (regcache_cooked_write): Remove, update callers to
5670 use regcache::cooked_write.
5671 * regcache.c (regcache_cooked_write): Remove.
5673 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5675 * regcache.h (regcache_invalidate): Remove, update callers to
5676 use detached_regcache::invalidate instead.
5677 * regcache.c (regcache_invalidate): Remove.
5679 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5681 * regcache.h (regcache_raw_write_part): Remove, update callers
5682 to use regcache::raw_write_part instead.
5683 * regcache.c (regcache_raw_write_part): Remove.
5685 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5687 * regcache.h (regcache_raw_read_part): Remove, update callers to
5688 use readable_regcache::raw_read_part instead.
5689 * regcache.c (regcache_raw_read_part): Remove.
5691 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5693 * regcache.h (regcache_cooked_read): Remove, update callers to
5694 use readable_regcache::cooked_read instead.
5695 * regcache.c (regcache_cooked_read): Remove.
5697 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5699 * regcache.h (regcache_raw_write): Remove, update callers to use
5700 regcache::raw_write instead.
5701 * regcache.c (regcache_raw_write): Remove.
5703 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5705 * regcache.h (regcache_raw_read): Remove, update callers to use
5706 readable_regcache::raw_read instead.
5707 * regcache.c (regcache_raw_read): Remove.
5709 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5711 * regcache.h (regcache_raw_update): Remove, update callers to
5712 use readable_regcache::raw_update instead.
5713 * regcache.c (regcache_raw_update): Remove.
5715 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5717 * regcache.h (regcache_register_status): Remove, update callers
5718 to use reg_buffer::get_register_status directly instead.
5719 * regcache.c (regcache_register_status): Remove.
5721 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5723 * regcache.h (regcache_get_ptid): Remove, update all callers to
5724 call regcache::ptid instead.
5725 * regcache.c (regcache_get_ptid): Remove.
5727 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5729 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
5731 2018-05-30 Pedro Alves <palves@redhat.com>
5733 * common/common-exceptions.h (exception_rethrow): Use
5736 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
5738 * breakpoint.c (print_solib_event, check_status_catch_solib):
5739 Remove struct keyword in range-based for loops.
5740 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
5741 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
5743 * linespec.c (find_superclass_methods, search_minsyms_for_name):
5745 * symfile.c (addr_info_make_relative): Likewise.
5746 * thread.c (value_in_thread_stack_temporaries): Likewise.
5748 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
5751 * valops.c (value_struct_elt_for_reference): Call check_typedef on
5752 aggregate type to get its real type before accessing it.
5754 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
5756 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
5757 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
5758 * coff-pe-read.c (add_pe_forwarded_sym): Replace
5759 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
5760 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
5761 * jit.c (jit_breakpoint_re_set_internal): Likewise.
5762 * printcmd.c (info_address_command): Likewise.
5764 2018-05-29 Tom Tromey <tom@tromey.com>
5766 * windows-nat.c (handle_exception): Update fall-through comment.
5768 2018-05-29 Tom Tromey <tom@tromey.com>
5770 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
5771 (struct program_space) <added_solibs>: Now a std::vector.
5772 * breakpoint.c (print_solib_event): Update.
5773 (check_status_catch_solib): Update.
5774 * progspace.c (clear_program_space_solib_cache): Update.
5775 * solib.c (update_solib_list): Update.
5777 2018-05-29 Tom Tromey <tom@tromey.com>
5779 * python/py-type.c (typy_richcompare): Update.
5780 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
5781 * gdbtypes.h (types_deeply_equal): Return bool.
5782 (types_equal): Likewise.
5783 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
5785 (check_types_equal): Change worklist to std::vector. Return
5787 (struct type_equality_entry): Add constructor.
5788 (compare_maybe_null_strings): Return bool.
5789 (check_types_worklist): Return bool. Change worklist to
5791 (types_deeply_equal): Use std::vector.
5792 (types_equal): Return bool.
5793 (compare_maybe_null_strings): Simplify.
5795 2018-05-29 Tom Tromey <tom@tromey.com>
5797 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
5799 2018-05-29 Tom Tromey <tom@tromey.com>
5801 * objc-lang.h: Don't include cp-support.h.
5802 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
5805 2018-05-27 Tom Tromey <tom@tromey.com>
5807 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
5809 2018-05-25 Tom Tromey <tom@tromey.com>
5811 * value.c (value::location): Initialize.
5813 2018-05-25 Tom Tromey <tom@tromey.com>
5815 * dbxread.c (init_bincl_list): Remove.
5816 (bincl_list): Now a std::vector.
5817 (bincls_allocated, next_bincl): Remove.
5818 (free_bincl_list, do_free_bincl_list_cleanup)
5819 (make_cleanup_free_bincl_list): Remove.
5820 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
5822 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
5823 (struct header_file_location): Add constructor.
5824 (add_bincl_to_list): Remove.
5826 2018-05-25 Tom Tromey <tom@tromey.com>
5828 * tui/tui.c (tui_enable): Update.
5829 * mi/mi-interp.c (mi_interp::init): Update.
5830 * interps.h (class interp) <name>: New method.
5831 <m_name>: Rename from name.
5832 (~scoped_restore_interp): Update.
5833 * interps.c (interp::interp): Update.
5834 (interp_add, interp_set, interp_lookup_existing)
5835 (current_interp_named_p): Update.
5837 2018-05-25 Tom Tromey <tom@tromey.com>
5839 * interps.c (interp_name): Remove.
5840 * mi/mi-interp.c (mi_interp::init): Update.
5841 * interps.h (interp_name): Remove.
5842 (~scoped_restore_interp): Update.
5843 * tui/tui.c (tui_enable): Update.
5845 2018-05-25 Tom Tromey <tom@tromey.com>
5847 * utils.c (fputs_maybe_filtered): Update.
5848 * linespec.c (decode_line_full): Update.
5849 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
5850 (mi_print_breakpoint_for_event, mi_solib_loaded)
5851 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
5852 (mi_user_selected_context_changed): Update.
5853 * mi/mi-main.c (mi_execute_command): Update.
5854 * cli/cli-script.c (execute_control_command): Update.
5855 * python/python.c (execute_gdb_command): Update.
5856 * solib.c (info_sharedlibrary_command): Update.
5857 * interps.c (interp_ui_out): Remove.
5858 * interps.h (interp_ui_out): Remove.
5860 2018-05-25 Tom Tromey <tom@tromey.com>
5862 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
5863 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
5864 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
5866 2018-05-25 Tom Tromey <tom@tromey.com>
5868 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
5869 * interps.c (interp_exec): Use scoped_restore.
5871 2018-05-25 Tom Tromey <tom@tromey.com>
5873 * remote.c (remote_target::remote_file_get): Use
5875 (remote_target::remote_file_put): Likewise.
5877 2018-05-25 Tom Tromey <tom@tromey.com>
5879 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
5881 (get_pe_section_index, add_pe_exported_sym): Update.
5882 (read_pe_exported_syms): Use gdb::def_vector.
5884 2018-05-25 Tom Tromey <tom@tromey.com>
5886 * frame.c (remove_prev_frame): Remove.
5887 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
5889 2018-05-25 Maciej W. Rozycki <macro@mips.com>
5891 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
5893 * mips-linux-nat.c (supply_fpregset): Always call
5894 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
5895 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
5896 `mips_fill_fpregset'.
5897 * mips-linux-tdep.c (mips_supply_fpregset)
5898 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
5899 (mips_fill_fpregset_wrapper): Remove functions.
5900 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
5901 (mips_linux_fpregset): Remove variable.
5902 (mips_linux_iterate_over_regset_sections): Use
5903 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
5904 (mips_linux_o32_sigframe_init): Remove comment.
5906 2018-05-25 Pedro Alves <palves@redhat.com>
5908 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
5909 (struct readahead_cache, struct packet_reg, struct
5910 remote_arch_state, class remote_state): Move higher up in the
5912 (remote_target::m_remote_state): Now an object instead of a pointer.
5913 (remote_target::get_remote_state): Adjust.
5915 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
5917 * stack.c (select_and_print_frame): Delete.
5918 (struct function_bounds): Move struct within function.
5919 (func_command): Most content moved into new function
5920 find_frame_for_function, use new function, print result, add
5922 (find_frame_for_function): New function, now returns a result.
5924 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5926 * stack.c (iterate_over_block_arg_vars): Fix comment.
5927 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
5929 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
5933 (scoped_restore_selected_frame::scoped_restore_selected_frame):
5935 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
5937 * frame.h (class scoped_restore_selected_frame): New class.
5938 * stack.c (print_frame_local_vars): Remove catching and rethrowing
5939 of any exception, use scoped_restore_selected_frame to restore the
5942 2018-05-24 Pedro Alves <palves@redhat.com>
5944 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
5947 2018-05-23 Tom Tromey <tom@tromey.com>
5949 * complaints.c (struct complaints): Remove.
5950 (symfile_complaint_book): Remove.
5951 (series): New global.
5952 (complaint_internal): Update.
5953 (clear_complaints): Update.
5955 2018-05-23 Tom Tromey <tom@tromey.com>
5957 * complaints.c (counters): New global.
5958 (struct complain): Remove.
5959 (struct complaints) <root>: Remove.
5960 (complaint_sentinel): Remove.
5961 (symfile_complaint_book): Update.
5962 (find_complaint) Remove.
5963 (complaint_internal, clear_complaints): Update.
5965 2018-05-23 Tom Tromey <tom@tromey.com>
5967 * complaints.c (struct complain) <file, line>: Remove.
5968 (find_complaint): Remove file, line parameters.
5969 (complaint_internal): Update.
5971 2018-05-23 Tom Tromey <tom@tromey.com>
5973 * complaints.c (vcomplaint): Remove.
5974 (complaint_internal) Merge in contents of vcomplaint.
5976 2018-05-23 Tom Tromey <tom@tromey.com>
5978 * complaints.c (struct complaints) <explanation>: Remove.
5979 (symfile_explanations): Remove.
5980 (symfile_complaint_book): Update.
5981 (vcomplaint): Update.
5982 (struct explanation): Remove.
5984 2018-05-23 Tom Tromey <tom@tromey.com>
5986 * complaints.c (symfile_complaints): Remove.
5987 (complaint_internal): Remove "complaints" parameter.
5988 (clear_complaints, vcomplaint): Remove "c" parameter.
5989 (get_complaints): Remove.
5990 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
5991 (dwarf2_debug_line_missing_file_complaint)
5992 (dwarf2_debug_line_missing_end_sequence_complaint)
5993 (dwarf2_complex_location_expr_complaint)
5994 (dwarf2_const_value_length_mismatch_complaint)
5995 (dwarf2_section_buffer_overflow_complaint)
5996 (dwarf2_macro_malformed_definition_complaint)
5997 (dwarf2_invalid_attrib_class_complaint)
5998 (create_addrmap_from_index, dw2_symtab_iter_next)
5999 (dw2_expand_marked_cus)
6000 (dw2_debug_names_iterator::find_vec_in_debug_names)
6001 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
6002 (create_debug_type_hash_table, init_cutu_and_read_dies)
6003 (partial_die_parent_scope, add_partial_enumeration)
6004 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
6005 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
6006 (read_import_statement, read_file_scope, create_dwo_cu_reader)
6007 (create_cus_hash_table, create_dwp_hash_table)
6008 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
6009 (dwarf2_rnglists_process, dwarf2_ranges_process)
6010 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
6011 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
6012 (handle_struct_member_die, process_structure_scope)
6013 (read_array_type, read_common_block, read_module_type)
6014 (read_tag_pointer_type, read_typedef, read_base_type)
6015 (read_subrange_type, load_partial_dies, partial_die_info::read)
6016 (partial_die_info::read, partial_die_info::read)
6017 (partial_die_info::read, read_checked_initial_length_and_offset)
6018 (dwarf2_string_attr, read_formatted_entries)
6019 (dwarf_decode_line_header)
6020 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
6021 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
6022 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
6023 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
6024 (get_signatured_type, get_DW_AT_signature_type)
6025 (decode_locdesc, file_file_name, consume_improper_spaces)
6026 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
6027 (dwarf_decode_macro_bytes, dwarf_decode_macros)
6028 (dwarf2_symbol_mark_computed, set_die_type)
6029 (read_attribute_value): Update.
6030 * stap-probe.c (handle_stap_probe, get_stap_base_address):
6032 * dbxread.c (unknown_symtype_complaint)
6033 (lbrac_mismatch_complaint, repeated_header_complaint)
6034 (set_namestring, function_outside_compilation_unit_complaint)
6035 (read_dbx_symtab, process_one_symbol): Update.
6036 * gdbtypes.c (stub_noname_complaint): Update.
6037 * windows-nat.c (handle_unload_dll): Update.
6038 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
6039 (decode_base_type): Update.
6040 * xcoffread.c (bf_notfound_complaint, ef_complaint)
6041 (eb_complaint, record_include_begin, record_include_end)
6042 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
6043 (process_xcoff_symbol, read_symbol)
6044 (function_outside_compilation_unit_complaint)
6045 (scan_xcoff_symtab): Update.
6046 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
6047 * buildsym.c (finish_block_internal, make_blockvector)
6048 (end_symtab_get_static_block, augment_type_symtab): Update.
6049 * dtrace-probe.c (dtrace_process_dof)
6050 (dtrace_static_probe_ops::get_probes): Update.
6051 * complaints.h (struct complaint): Don't declare.
6052 (symfile_complaints): Remove.
6053 (complaint_internal): Remove "complaints" parameter.
6054 (complaint): Likewise.
6055 (clear_complaints): Likewise.
6056 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6057 (reread_symbols): Update.
6058 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
6059 (dwarf2_frame_cache, decode_frame_entry): Update.
6060 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
6061 * objc-lang.c (lookup_objc_class, lookup_child_selector)
6062 (info_selectors_command): Update.
6063 * macrotab.c (macro_include, check_for_redefinition)
6064 (macro_undef): Update.
6065 * objfiles.c (filter_overlapping_sections): Update.
6066 * stabsread.c (invalid_cpp_abbrev_complaint)
6067 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
6068 (define_symbol, error_type, read_type, rs6000_builtin_type)
6069 (stabs_method_name_from_physname, read_member_functions)
6070 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
6071 (attach_fields_to_type, complain_about_struct_wipeout)
6072 (read_range_type, read_args, common_block_start)
6073 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
6075 * mdebugread.c (index_complaint, unknown_ext_complaint)
6076 (basic_type_complaint, bad_tag_guess_complaint)
6077 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
6078 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
6079 (parse_procedure, parse_lines)
6080 (function_outside_compilation_unit_complaint)
6081 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
6082 (bad_tag_guess_complaint, reg_value_complaint): Update.
6083 * cp-support.c (demangled_name_complaint): Update.
6084 * macroscope.c (sal_macro_scope): Update.
6085 * dwarf-index-write.c (class debug_names): Update.
6087 2018-05-23 Tom Tromey <tom@tromey.com>
6089 * complaints.c (clear_complaints): Remove "noisy" parameter.
6090 * complaints.h (clear_complaints): Update.
6091 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6092 (reread_symbols): Update.
6094 2018-05-23 Tom Tromey <tom@tromey.com>
6096 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
6098 (vcomplaint, clear_complaints): Update.
6099 (symfile_explanations): Remove some messages.
6101 2018-05-23 Tom Tromey <tom@tromey.com>
6103 * complaints.c (internal_complaint): Remove.
6104 * complaints.h (internal_complaint): Remove.
6106 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6108 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
6110 2018-05-22 Pedro Alves <palves@redhat.com>
6112 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
6113 (remote_fileio_badfd, remote_fileio_return_errno)
6114 (remote_fileio_return_success, remote_fileio_func_open)
6115 (remote_fileio_func_open, remote_fileio_func_close)
6116 (remote_fileio_func_read, remote_fileio_func_write)
6117 (remote_fileio_func_lseek, remote_fileio_func_rename)
6118 (remote_fileio_func_unlink, remote_fileio_func_stat)
6119 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
6120 (remote_fileio_func_isatty, remote_fileio_func_system): Add
6121 remote_target parameter.
6122 (remote_fio_func_map) <func>: Add remote_target parameter.
6123 (do_remote_fileio_request, remote_fileio_request):
6124 * remote-fileio.h (remote_fileio_request):
6125 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
6126 remote_target parameter.
6127 (remote_notif_process, handle_notification): Adjust to pass down
6129 (remote_notif_state_allocate): Add remote_target parameter. Save
6131 * remote-notif.h (struct remote_target): Forward declare.
6132 (struct notif_client) <parse, ack, can_get_pending_events>: Add
6133 remote_target parameter.
6134 (struct remote_notif_state) <remote>: New field.
6135 (remote_notif_ack, remote_notif_parse): Add remote_target
6137 (remote_notif_state_allocate, remote_notif_state_allocate): Add
6138 remote_target parameter.
6139 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
6140 (threads_listing_context, rmt_thread_action, protocol_feature)
6141 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
6142 (packet_result, struct threads_listing_context, remote_state):
6143 Move definitions and declarations higher up.
6144 (remote_target) <~remote_target>: Declare.
6145 (remote_download_command_source, remote_file_put, remote_file_get)
6146 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
6147 (remote_hostio_pread_vFile, remote_hostio_send_command)
6148 (remote_hostio_set_filesystem, remote_hostio_open)
6149 (remote_hostio_close, remote_hostio_unlink, remote_state)
6150 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
6151 (get_memory_write_packet_size, get_memory_read_packet_size)
6152 (append_pending_thread_resumptions, remote_detach_1)
6153 (append_resumption, remote_resume_with_vcont)
6154 (add_current_inferior_and_thread, wait_ns, wait_as)
6155 (process_stop_reply, remote_notice_new_inferior)
6156 (process_initial_stop_replies, remote_add_thread)
6157 (btrace_sync_conf, remote_btrace_maybe_reopen)
6158 (remove_new_fork_children, kill_new_fork_children)
6159 (discard_pending_stop_replies, stop_reply_queue_length)
6160 (check_pending_events_prevent_wildcard_vcont)
6161 (discard_pending_stop_replies_in_queue, stop_reply)
6162 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
6163 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
6164 (remote_interrupt_as, remote_interrupt_ns)
6165 (remote_get_noisy_reply, remote_query_attached)
6166 (remote_add_inferior, remote_current_thread, get_current_thread)
6167 (set_thread, set_general_thread, set_continue_thread)
6168 (set_general_process, write_ptid)
6169 (remote_unpack_thread_info_response, remote_get_threadinfo)
6170 (parse_threadlist_response, remote_get_threadlist)
6171 (remote_threadlist_iterator, remote_get_threads_with_ql)
6172 (remote_get_threads_with_qxfer)
6173 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
6174 (get_offsets, remote_check_symbols, remote_supported_packet)
6175 (remote_query_supported, remote_packet_size)
6176 (remote_serial_quit_handler, remote_detach_pid)
6177 (remote_vcont_probe, remote_resume_with_hc)
6178 (send_interrupt_sequence, interrupt_query)
6179 (remote_notif_get_pending_events, fetch_register_using_p)
6180 (send_g_packet, process_g_packet, fetch_registers_using_g)
6181 (store_register_using_P, store_registers_using_G)
6182 (set_remote_traceframe, check_binary_download)
6183 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
6184 (remote_xfer_live_readonly_partial, remote_read_bytes)
6185 (remote_send_printf, remote_flash_write, readchar)
6186 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
6187 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
6188 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
6189 (extended_remote_disable_randomization, extended_remote_run)
6190 (send_environment_packet, extended_remote_environment_support)
6191 (extended_remote_set_inferior_cwd, remote_write_qxfer)
6192 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
6193 (packet_command): Now methods of ...
6194 (remote_target): ... this class.
6195 (m_remote_state) <remote_target>: New field.
6196 (struct remote_state) <stop_reply_queue,
6197 remote_async_inferior_event_token, wait_forever_enabled_p>: New
6199 (remote_state::remote_state): Allocate stop_reply_queue.
6200 (remote_state): Delete global.
6201 (get_remote_state_raw): Delete.
6202 (remote_target::get_remote_state): Allocate m_remote_state on
6204 (get_current_remote_target): New.
6205 (remote_ops, extended_remote_ops): Delete.
6206 (wait_forever_enabled_p, remote_async_inferior_event_token):
6207 Delete, moved to struct remote_state.
6208 (remote_target::close): Delete self. Destruction bits split to
6210 (remote_target::~remote_target): ... this.
6211 (show_memory_packet_size): Adjust to use
6212 get_current_remote_target.
6213 (struct protocol_feature) <func>: Add remote_target parameter.
6214 All callers adjusted.
6215 (curr_quit_handler_target): New.
6216 (remote_serial_quit_handler): Reimplement.
6217 (remote_target::open_1): Adjust to use get_current_remote_target.
6218 Heap-allocate remote_target/extended_remote_target instances.
6219 (vcont_builder::vcont_builder): Add remote_target parameter, and
6220 save it in m_remote. All callers adjusted.
6221 (vcont_builder::m_remote): New field.
6222 (vcont_builder::restart, vcont_builder::flush)
6223 (vcont_builder::push_action): Use it.
6224 (remote_target::commit_resume): Use it.
6225 (struct queue_iter_param) <remote>: New field.
6226 (remote_target::remove_new_fork_children): Fill in 'remote' field.
6227 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
6228 (check_pending_event_prevents_wildcard_vcont_callback)
6229 (remote_target::check_pending_events_prevent_wildcard_vcont)
6230 (remote_target::discard_pending_stop_replies)
6231 (remote_target::discard_pending_stop_replies_in_queue)
6232 (remote_target::remote_notif_remove_queued_reply): Fill in
6234 (remote_notif_get_pending_events): New.
6235 (remote_target::readchar, remote_target::remote_serial_write):
6236 Save/restore curr_quit_handler_target.
6238 (kill_new_fork_children): Fill in 'remote' field.
6239 (packet_command): Use get_current_remote_target, defer to
6240 remote_target method of same name.
6241 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
6242 parameter, and save it in m_remote. All callers adjusted.
6243 (scoped_remote_fd::release): Use m_remote.
6244 (scoped_remote_fd::m_remote): New field.
6245 (remote_file_put, remote_file_get, remote_file_delete): Use
6246 get_current_remote_target, defer to remote_target method of same
6248 (remote_btrace_reset): Add remote_state paremeter. Update all
6250 (remote_async_inferior_event_handler). Pass down 'data'.
6251 (remote_new_objfile): Use get_current_remote_target.
6252 (remote_target::vcont_r_supported): New.
6253 (set_range_stepping): Use get_current_remote_target and
6254 remote_target::vcont_r_supported.
6255 (_initialize_remote): Don't allocate 'remote_state' and
6256 'stop_reply_queue' globals.
6257 * remote.h (struct remote_target): Forward declare.
6258 (getpkt, putpkt, remote_notif_get_pending_events): Add
6259 'remote_target' parameter.
6261 2018-05-22 Pedro Alves <palves@redhat.com>
6263 * remote.c (vcont_builder): Now a class. Make all data members
6265 (vcont_builder) <vcont_builder, restart, flush, push_action>:
6267 (vcont_builder_restart): Rename to ...
6268 (vcont_builder::restart): ... this.
6269 (vcont_builder_flush): Rename to ...
6270 (vcont_builder::flush): ... this.
6271 (vcont_builder_push_action): Rename to ...
6272 (vcont_builder::push_action): ... this.
6273 (remote_target::commit_resume): Adjust.
6275 2018-05-22 Pedro Alves <palves@redhat.com>
6277 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
6278 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
6279 (get_fixed_memory_packet_size): New.
6280 (get_memory_packet_size): Use it.
6281 (set_memory_packet_size): Don't override the config size with
6282 DEFAULT_MAX_MEMORY_PACKET_SIZE.
6283 (show_memory_packet_size): Use get_fixed_memory_packet_size.
6284 Don't refer to get_memory_packet_size if not connected to a remote
6285 target. Show "(default)" if configured size is 0.
6287 2018-05-22 Pedro Alves <palves@redhat.com>
6289 * remote.c (remote_target::mourn_inferior): Move
6290 discard_pending_stop_replies call here from ...
6291 (_initialize_remote): ... here.
6293 2018-05-22 Pedro Alves <palves@redhat.com>
6295 * remote.c (compare_section_command): Remove set_general_process
6298 2018-05-22 Pedro Alves <palves@redhat.com>
6300 * remote.c (struct packet_reg, struct remote_arch_state):
6301 Move higher up in the file.
6302 (remote_state) <m_arch_states>: Store remote_arch_state values
6303 instead of remote_arch_state pointers.
6304 (remote_state::get_remote_arch_state): Adjust.
6306 2018-05-22 Pedro Alves <palves@redhat.com>
6308 * remote.c: Include <unordered_map>.
6309 (remote_state): Now a class.
6310 (remote_state) <get_remote_arch_state>: Declare method.
6311 <get_remote_arch_state>: New field.
6312 (remote_arch_state) <remote_arch_state>: Declare ctor.
6313 <regs>: Now a unique_ptr.
6314 (remote_gdbarch_data_handle): Delete.
6315 (get_remote_arch_state): Delete.
6316 (remote_state::get_remote_arch_state): New.
6317 (get_remote_state): Adjust to call remote_state's
6318 get_remote_arch_state method.
6319 (init_remote_state): Delete, bits factored out to ...
6320 (remote_arch_state::remote_arch_state): ... this new method.
6321 (get_remote_packet_size, get_memory_packet_size)
6322 (process_g_packet, remote_target::fetch_registers)
6323 (remote_target::prepare_to_store, store_registers_using_G)
6324 (remote_target::store_registers, remote_target::get_trace_status):
6325 Adjust to call remote_state's method.
6326 (_initialize_remote): Remove reference to
6327 remote_gdbarch_data_handle.
6329 2018-05-22 Pedro Alves <palves@redhat.com>
6331 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
6332 pread>: New method declarations.
6333 (remote_target::open_1): Adjust.
6334 (readahead_cache_invalidate): Rename to ...
6335 (readahead_cache::invalidate): ... this, and adjust to be a class
6337 (readahead_cache_invalidate_fd): Rename to ...
6338 (readahead_cache::invalidate_fd): ... this, and adjust to be a
6340 (remote_hostio_pwrite): Adjust.
6341 (remote_hostio_pread_from_cache): Rename to ...
6342 (readahead_cache::pread): ... this, and adjust to be a class
6344 (remote_hostio_close): Adjust.
6346 2018-05-22 Pedro Alves <palves@redhat.com>
6348 * remote.c (remote_hostio_close_cleanup): Delete.
6349 (class scoped_remote_fd): New.
6350 (remote_file_put, remote_file_get): Use it.
6352 2018-05-22 Pedro Alves <palves@redhat.com>
6354 (struct vCont_action_support): Use bool and initialize all fields.
6355 (struct readahead_cache): Initialize all fields.
6356 (remote_state): Use bool and initialize all fields.
6357 (remote_state::remote_state, remote_state::~remote_state): New.
6358 (new_remote_state): Delete.
6359 (_initialize_remote): Use new to allocate remote_state.
6361 2018-05-22 Pedro Alves <palves@redhat.com>
6365 * c-exp.y: Include "c-support.h".
6366 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
6367 of tolower. Use c_ident_is_alpha to scan names.
6368 * c-lang.c: Include "c-support.h".
6369 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
6370 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
6371 * c-support.h: New file, with bits factored out from ...
6372 * cp-name-parser.y: ... this file.
6373 Include "c-support.h".
6374 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
6375 c-support.h and renamed.
6376 (symbol_end, yylex): Adjust.
6378 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6380 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
6381 parameter type to CORE_ADDR.
6382 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
6383 parameter type in declaration to CORE_ADDR.
6384 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
6385 target_auxv_search to get AT_HWCAP and use the result to get the
6387 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
6388 to CORE_ADDR. Remove the cast of the return value to unsigned
6389 long. Fix error predicate of target_auxv_search.
6390 (ppc_linux_nat_target::read_description): Change the type of the
6391 hwcap variable to CORE_ADDR.
6393 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6395 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
6396 if the size of fpscr is larger than 32 bits.
6398 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6400 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
6401 (ppc32_linux_vsxregmap): New global.
6402 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
6403 regcache_supply_regset, and regcache_collect_regset.
6404 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
6405 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
6406 (fetch_vsx_register, store_vsx_register): Remove.
6407 (fetch_vsx_registers): Add regno parameter. Get regset using
6408 ppc_linux_vsxregset. Use regset to supply registers.
6409 (store_vsx_registers): Add regno parameter. Get regset using
6410 ppc_linux_vsxregset. Use regset to collect registers.
6411 (fetch_register): Call fetch_vsx_registers instead of
6413 (store_register): Call store_vsx_registers instead of
6415 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
6416 new regno parameter.
6417 (store_ppc_registers): Call store_vsx_registers with -1 for the
6418 new regno parameter.
6419 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
6420 (ppc_collect_vsxregset): Remove.
6422 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6424 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
6426 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
6427 for vector register offset fields.
6428 (ppc64_fbsd_reg_offsets): Likewise.
6429 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6430 to vector register offset fields.
6431 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6432 to vector register offset fields.
6433 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
6434 vector register offset fields.
6435 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
6436 initializers for vector register offset fields.
6437 (rs6000_aix64_reg_offsets): Likewise.
6438 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
6439 (ppc_supply_vrregset): Remove.
6440 (ppc_collect_vrregset): Remove.
6441 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
6442 (ppc_linux_vrregset) : New function.
6443 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
6444 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
6445 (ppc32_linux_vrregset): Remove.
6446 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
6447 and use result instead of ppc32_linux_vrregset.
6448 (ppc32_linux_reg_offsets): Remove initializers for vector register
6450 (ppc64_linux_reg_offsets): Likewise.
6451 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
6452 * ppc-linux-nat.c: Include regset.h.
6453 (gdb_vrregset_t): Adjust comment to account for little-endian
6455 (supply_vrregset, fill_vrregset): Remove.
6456 (fetch_altivec_register, store_altivec_register): Remove.
6457 (fetch_altivec_registers): Add regno parameter. Get regset using
6458 ppc_linux_vrregset. Use regset to supply registers.
6459 (store_altivec_registers): Add regno parameter. Get regset using
6460 ppc_linux_vrregset. Use regset to collect registers.
6461 (fetch_register): Call fetch_altivec_registers instead of
6462 fetch_altivec_register.
6463 (store_register): Call store_altivec_registers instead of
6464 store_altivec_register.
6465 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
6466 the new regno parameter.
6467 (store_ppc_registers): Call store_altivec_registers with -1 for
6468 the new regno parameter.
6470 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6472 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
6473 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
6474 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
6475 (gdb_vrregset_t): Change array type size to
6476 PPC_LINUX_SIZEOF_VRREGSET.
6477 (gdb_vsxregset_t): Change array type size to
6478 PPC_LINUX_SIZEOF_VSXREGSET.
6479 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
6480 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
6481 PPC_LINUX_SIZEOF_VSXREGSET.
6483 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6485 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
6486 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
6488 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
6489 ppc_linux_target_wordsize with tid.
6490 (ppc_linux_nat_target::read_description): Call ppc_linux_target
6492 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
6493 (ppc64_64bit_inferior_p): Add static and inline specifiers.
6494 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
6495 tid parameter. Remove static specifier.
6496 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
6497 (ppc_linux_target_wordsize): New declaration.
6499 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6501 * arch/ppc-linux-common.c: New file.
6502 * arch/ppc-linux-common.h: New file.
6503 * arch/ppc-linux-tdesc.h: New file.
6504 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
6505 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
6506 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
6507 arch/ppc-linux-tdesc.h.
6508 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
6509 arch/ppc-linux-tdesc.h.
6510 (ppc_linux_nat_target::read_description): Remove target
6511 description matching code. Fill a ppc_linux_features struct and
6512 call ppc_linux_match_description with it. Move comment about ISA
6513 2.05 to ppc-linux-common.c.
6514 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
6515 arch/ppc-linux-tdesc.h.
6516 (ppc_linux_core_read_description): Remove target description
6517 matching code. Fill a ppc_linux_features struct and call
6518 ppc_linux_match_description with it.
6519 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
6520 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
6521 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
6522 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
6523 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
6524 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
6525 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
6526 (tdesc_powerpc_e500l): Remove.
6528 2018-05-22 Joel Brobecker <brobecker@adacore.com>
6530 * ada-lang.c (catch_assert_command): Pass empty string instead
6531 of NULL for excep_string argument.
6533 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6535 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
6536 the width of the requested register exceeds the width of the
6539 2018-05-21 Tom Tromey <tom@tromey.com>
6541 * printcmd.c (output_command): Remove.
6542 (output_command_const): Rename to output_command.
6543 * valprint.h (output_command): Rename from output_command_const.
6544 * tracepoint.c (trace_dump_actions): Call output_command.
6546 2018-05-21 Tom Tromey <tom@tromey.com>
6548 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
6549 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
6550 * ada-lang.h (create_ada_exception_catchpoint): Update.
6551 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
6553 (create_excep_cond_exprs, ~ada_catchpoint)
6554 (should_stop_exception, print_one_exception)
6555 (print_mention_exception, print_recreate_exception): Update.
6556 (ada_get_next_arg): Remove.
6557 (catch_ada_exception_command_split): Use std::string. Change type
6558 of "excep_string", "cond_string".
6559 (catch_ada_exception_command): Update.
6560 (create_ada_exception_catchpoint): Change type of excep_string.
6561 (ada_exception_sal): Remove excep_string parameter.
6562 (~ada_catchpoint): Remove.
6564 2018-05-21 Tom Tromey <tom@tromey.com>
6566 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
6569 2018-05-21 Tom Tromey <tom@tromey.com>
6571 * ada-lang.c (ada_exception_message_1, ada_exception_message):
6572 Return unique_xmalloc_ptr.
6573 (print_it_exception): Update.
6575 2018-05-21 Tom Tromey <tom@tromey.com>
6577 * tracepoint.c (trace_dump_actions): Use std::string.
6579 2018-05-21 Tom Tromey <tom@tromey.com>
6581 * symfile.c (reread_symbols): Use std::string for original_name.
6583 2018-05-21 Tom Tromey <tom@tromey.com>
6585 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
6586 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
6589 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
6591 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
6593 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
6594 * objfiles.c (get_objfile_bfd_data): Allocate
6595 objfile_per_bfd_storage with obstack_new when allocating on
6598 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
6600 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
6602 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
6603 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
6604 * mdebugread.c (mdebug_build_psymtabs): Likewise.
6605 (add_pending): Likewise.
6606 (parse_symbol): Likewise.
6607 (parse_partial_symbols): Likewise.
6608 (psymtab_to_symtab_1): Likewise.
6609 (new_psymtab): Likewise.
6610 (elfmdebug_build_psymtabs): Likewise.
6611 * minsyms.c (terminate_minimal_symbol_table): Likewise.
6612 * objfiles.c (get_objfile_bfd_data): Likewise.
6613 (objfile_register_static_link): Likewise.
6614 * psymtab.c (allocate_psymtab): Likewise.
6615 * stabsread.c (read_member_functions): Likewise.
6616 * xcoffread.c (xcoff_end_psymtab): Likewise.
6618 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
6620 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
6621 compiler supports std::is_trivially_constructible.
6622 * common/poison.h: Include obstack.h.
6623 (IsMallocable): Define to is_trivially_constructible if the
6624 compiler supports it, define to true_type otherwise.
6628 (XOBNEWVEC): Redefine.
6629 * gdb_obstack.h (obstack_zalloc): New.
6630 (OBSTACK_ZALLOC): Redefine.
6631 (obstack_calloc): New.
6632 (OBSTACK_CALLOC): Redefine.
6634 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
6635 (gdbarch_obstack): New declaration in gdbarch.h, definition in
6637 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
6638 obstack_calloc/obstack_zalloc.
6639 (gdbarch_obstack_zalloc): Remove.
6640 * target-descriptions.c (tdesc_data_init): Use obstack_new.
6642 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6644 * stack.c (backtrace_command_1): Remove useless variable int i.
6646 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6648 * stack.c (print_frame_info): Fix comment.
6650 2018-05-18 Tom Tromey <tom@tromey.com>
6652 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
6653 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
6654 (~dwarf2_per_objfile): Update
6655 (dwarf2_get_dwz_file): Use new.
6656 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
6659 2018-05-18 Tom Tromey <tom@tromey.com>
6661 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
6663 * dwarf2read.c (struct dwp_file): Add constructor and
6665 (open_and_init_dwp_file): Return a unique_ptr.
6666 (dwarf2_per_objfile, create_dwp_hash_table)
6667 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
6668 (lookup_dwo_unit_in_dwp): Update.
6669 (open_and_init_dwp_file, get_dwp_file): Update.
6671 2018-05-18 Tom Tromey <tom@tromey.com>
6673 * dwarf2read.c (dwarf2_per_objfile): Update.
6674 (struct mapped_index): Add initializers.
6675 (dwarf2_read_index): Use new.
6676 (dw2_symtab_iter_init): Update.
6677 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
6680 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6682 * dwarf2read.c (mapped_index) <total_size>: Remove.
6684 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6686 * unittests/format_pieces-selftests.c (test_format_specifier):
6689 2018-05-18 Tom Tromey <tom@tromey.com>
6691 * c-typeprint.c (maybe_print_hole): New function.
6692 (c_print_type_struct_field_offset): Update.
6693 (c_type_print_base_struct_union): Call maybe_print_hole.
6695 2018-05-17 Keith Seitz <keiths@redhat.com>
6697 * breakpoint.c (build_bpstat_chain): New function, moved from
6699 (bpstat_stop_status): Add optional parameter, `stop_chain'.
6700 If no stop chain is passed, call build_bpstat_chain to build it.
6701 * breakpoint.h (build_bpstat_chain): Declare.
6702 (bpstat_stop_status): Move documentation here from breakpoint.c.
6703 * infrun.c (handle_signal_stop): Before eliding inlined frames,
6704 build the stop chain and pass it to skip_inline_frames.
6705 Pass this stop chain to bpstat_stop_status.
6706 * inline-frame.c: Include breakpoint.h.
6707 (stopped_by_user_bp_inline_frame): New function.
6708 (skip_inline_frames): Add parameter `stop_chain'.
6709 Move documention to inline-frame.h.
6710 If non-NULL, use stopped_by_user_bp_inline_frame to determine
6711 whether the frame should be elided.
6712 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
6713 Add moved documentation and update for new parameter.
6715 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
6718 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6719 unittests/format_pieces-selftests.c.
6720 * common/format.h (format_piece) <operator==>: New.
6721 (format_pieces) <operator[]>: Remove.
6722 * common/format.c (format_pieces::format_pieces): Handle \e.
6723 * unittests/format_pieces-selftests.c: New.
6725 2018-05-17 Tom Tromey <tom@tromey.com>
6728 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
6729 (dw2_instantiate_symtab): Add skip_partial parameter.
6730 (dw2_find_last_source_symtab, dw2_map_expand_apply)
6731 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
6732 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
6733 (dw2_expand_symtabs_matching_one)
6734 (dw2_find_pc_sect_compunit_symtab)
6735 (dw2_debug_names_lookup_symbol)
6736 (dw2_debug_names_expand_symtabs_for_function): Update.
6737 (init_cutu_and_read_dies): Add skip_partial parameter.
6738 (process_psymtab_comp_unit, build_type_psymtabs_1)
6739 (process_skeletonless_type_unit, load_partial_comp_unit)
6740 (psymtab_to_symtab_1): Update.
6741 (load_full_comp_unit): Add skip_partial parameter.
6742 (process_imported_unit_die, dwarf2_read_addr_index)
6743 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
6744 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
6745 (read_signatured_type): Update.
6747 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
6749 * value.c (release_value): Remove unused variable.
6750 (record_latest_value): Likewise.
6751 (access_value_history): Likewise.
6752 (preserve_values): Likewise.
6754 2018-05-17 Tom Tromey <tom@tromey.com>
6756 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
6759 2018-05-16 Maciej W. Rozycki <macro@mips.com>
6762 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
6763 Also handle registers whose width is not a multiple of
6765 (linux_nat_trad_target::store_register): Likewise.
6767 2018-05-16 Tom Tromey <tom@tromey.com>
6769 * gdbcore.h (core_bfd): Redefine.
6770 * corelow.c (core_target::close): Update.
6771 (core_target_open): Update.
6772 * progspace.h (struct program_space) <cbfd>: Now a
6775 2018-05-16 Tom Tromey <tom@tromey.com>
6778 * symfile-add-flags.h (enum symfile_add_flags)
6779 <SYMFILE_NOT_FILENAME>: New constant.
6780 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
6781 objfile name from BFD.
6782 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
6783 * minidebug.c (find_separate_debug_file_in_section): Put
6784 ".gnu_debugdata" into BFD's file name.
6786 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
6788 * regcache.c (regcache_read_ftype, regcache_write_ftype):
6791 2018-05-15 Tamar Christina <tamar.christina@arm.com>
6794 * aarch64-tdep.c (aarch64_analyze_prologue,
6795 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
6796 Indicate not interested in errors.
6798 2018-05-15 Maciej W. Rozycki <macro@mips.com>
6800 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
6801 Supply the MIPS_ZERO_REGNUM register.
6803 2018-05-15 Maciej W. Rozycki <macro@mips.com>
6805 * mips-tdep.c (mask_address_var): Make variable static.
6807 2018-05-14 Tom Tromey <tom@tromey.com>
6809 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
6811 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
6813 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
6814 FXSAVE_ADDR for the mxcsr register.
6816 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
6818 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
6820 2018-05-11 Pedro Alves <palves@redhat.com>
6822 * corelow.c (core_target) <core_target>: No longer inline.
6823 Initialize m_core_gdbarch, m_core_vec and build the section table
6825 <~core_target>: New.
6826 <core_gdbarch, get_core_register_section>: New methods.
6827 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
6828 factored out from ...
6829 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
6831 (sniff_core_bfd): Add gdbarch parameter.
6832 (core_close): Delete, merged into ...
6833 (core_target::close): ... here. Delete self.
6834 (core_close_cleanup): Delete.
6835 (core_target_open): Allocate a core_target on the heap. Use a
6836 unique_ptr instead of a cleanup. Bits moved into the core_target
6837 ctor. Adjust to use core_target methods instead of globals.
6838 (get_core_register_section): Rename to ...
6839 (core_target::get_core_register_section): ... this and adjust.
6840 (struct get_core_registers_cb_data): New.
6841 (get_core_registers_cb): Use it. Use bool.
6842 (core_target::fetch_registers, core_target::files_info)
6843 (core_target::xfer_partial, core_target::read_description)
6844 (core_target::pid_to, core_target::thread_name): Adjust to
6845 reference class fields instead of globals.
6846 * target.h (struct target_ops_deleter, target_ops_up): New.
6848 2018-05-11 Pedro Alves <palves@redhat.com>
6850 * corefile.c (core_file_command): Move to corelow.c.
6851 * corelow.c (the_core_target): Delete.
6852 (core_file_command): Moved from corefile.c. Check exec_bfd
6853 instead of the_core_target. Use target_detach instead of calling
6854 into the_core_target directly.
6855 (maybe_say_no_core_file_now): New.
6856 (core_target::detach): Use it.
6857 (_initialize_corelow): Remove references to the_core_target.
6858 * gdbcore.h (the_core_target): Delete.
6860 2018-05-11 Tom Tromey <tromey@redhat.com>
6861 Pedro Alves <palves@redhat.com>
6863 * corefile.c (core_bfd): Remove.
6864 * gdbcore.h (core_bfd): Now a macro.
6865 * progspace.h (struct program_space) <cbfd>: New field.
6867 2018-05-11 Tom Tromey <tom@tromey.com>
6869 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
6872 2018-05-10 Tom Tromey <tom@tromey.com>
6874 * configure: Rebuild.
6875 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
6877 2018-05-10 Joel Brobecker <brobecker@adacore.com>
6880 * regformats/regdat.sh: Adjust script, following the addition
6881 of the new expedite_regs parameter to init_target_desc.
6883 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
6886 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
6887 set_gdbarch_significant_addr_bit.
6888 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
6889 set_gdbarch_significant_addr_bit.
6890 * utils.c (address_significant): Update to sign extend addr.
6892 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
6894 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
6895 (xtensa_linux_init_abi): Limit tdep->num_regs by
6896 tdep->num_nopriv_regs.
6897 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
6898 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
6901 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
6903 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
6905 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
6907 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
6908 (I387_MXCSR_INIT_VAL): New constant.
6909 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
6910 buffer if it was supplied by the inferior.
6911 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
6912 (i387_xsave_get_clear_bv): New function.
6913 (i387_supply_xsave): Only read x87 control registers from the
6914 xsave buffer if the feature is enabled, and the state will have
6915 been written, otherwise, provide a suitable default.
6916 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
6917 including x87 control registers. Update control registers if they
6918 have changed from the default value, and mark features as enabled
6920 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
6922 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
6924 * spu-tdep.c (info_spu_event_command): Fix output formatting.
6926 2018-05-07 Tom Tromey <tom@tromey.com>
6928 * configure: Rebuild.
6929 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
6931 2018-05-07 Tom Tromey <tom@tromey.com>
6934 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
6935 bit. Use correct value for VDIV.
6937 2018-05-04 Tom Tromey <tom@tromey.com>
6939 * configure: Rebuild.
6940 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
6942 2018-05-04 Tom Tromey <tom@tromey.com>
6944 * linux-record.c (record_linux_system_call) <case
6945 RECORD_SYS_RECVFROM>: Add "break".
6947 2018-05-04 Tom Tromey <tom@tromey.com>
6949 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
6950 Add missing "break".
6951 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
6952 Add missing "break".
6954 2018-05-04 Tom Tromey <tom@tromey.com>
6956 * rs6000-tdep.c (ppc_process_record_op4)
6957 (ppc_process_record_op63): Add fall-through comment.
6959 2018-05-04 Tom Tromey <tom@tromey.com>
6961 * i386-tdep.c (i386_process_record): Add fall-through comment.
6963 2018-05-04 Tom Tromey <tom@tromey.com>
6965 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
6968 2018-05-04 Tom Tromey <tom@tromey.com>
6970 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
6971 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
6972 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
6974 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
6976 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
6979 2018-05-04 Tom Tromey <tom@tromey.com>
6981 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
6983 2018-05-04 Tom Tromey <tom@tromey.com>
6985 * s390-tdep.c (s390_process_record): Fix fall-through comments.
6986 * xcoffread.c (scan_xcoff_symtab): Move comment later.
6987 * symfile.c (section_is_mapped): Fix fall-through comment.
6988 * stabsread.c (define_symbol, read_member_functions): Fix
6989 fall-through comment.
6990 * s390-linux-tdep.c (s390_process_record): Fix fall-through
6992 * remote.c (remote_wait_as): Fix fall-through comment.
6993 * p-exp.y (yylex): Fix fall-through comment.
6994 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
6996 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
6997 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
6998 * jv-exp.y (yylex): Fix fall-through comment.
6999 * go-exp.y (lex_one_token): Fix fall-through comment.
7000 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
7001 fall-through comment.
7002 * f-exp.y (yylex): Fix fall-through comment.
7003 * dwarf2read.c (process_die): Fix fall-through comments.
7004 * dbxread.c (process_one_symbol): Fix fall-through comment.
7005 * d-exp.y (lex_one_token): Fix fall-through comment.
7006 * cp-name-parser.y (yylex): Fix fall-through comment.
7007 * coffread.c (coff_symtab_read): Fix fall-through comment.
7008 * c-exp.y (lex_one_token): Fix fall-through comment.
7009 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
7011 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
7014 2018-05-04 Tom Tromey <tom@tromey.com>
7017 * NEWS: Mention gdb.execute change.
7018 * gdbcmd.h (execute_control_command): Don't declare.
7019 * python/python.c (execute_gdb_command): Use read_command_lines_1,
7020 execute_control_commands, execute_control_commands_to_string.
7021 * cli/cli-script.h (execute_control_commands)
7022 (execute_control_commands_to_string): Declare.
7023 (execute_control_command): Add from_tty parameter.
7024 * cli/cli-script.c (execute_control_commands)
7025 (execute_control_commands_to_string): New functions.
7026 (execute_user_command): Use execute_control_commands.
7027 (execute_control_command_1): Add "from_tty" parameter. Update.
7028 (execute_control_command): Likewise.
7030 2018-05-04 Tom Tromey <tom@tromey.com>
7033 * NEWS: Mention that breakpoint commands are writable.
7034 * python/py-breakpoint.c (bppy_set_commands): New function.
7035 (breakpoint_object_getset) <"commands">: Use it.
7037 2018-05-04 Tom Tromey <tom@tromey.com>
7039 * tracepoint.c (actions_command): Update.
7040 * mi/mi-cmd-break.c (mi_command_line_array)
7041 (mi_command_line_array_cnt, mi_command_line_array_ptr)
7042 (mi_read_next_line): Remove.
7043 (mi_cmd_break_commands): Update.
7044 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
7046 * cli/cli-script.c (get_command_line): Update.
7047 (process_next_line): Use function_view. Constify.
7048 (recurse_read_control_structure, read_command_lines)
7049 (read_command_lines_1): Change argument types to function_view.
7050 (do_define_command, document_command): Update.
7051 * breakpoint.h (check_tracepoint_command): Don't declare.
7052 * breakpoint.c (check_tracepoint_command): Remove.
7053 (commands_command_1, create_tracepoint_from_upload): Update.
7055 2018-05-04 Tom Tromey <tom@tromey.com>
7058 * cli/cli-script.h (enum command_control_type) <define_control>:
7060 * cli/cli-script.c (multi_line_command_p): Handle define_control.
7061 (build_command_line, execute_control_command_1)
7062 (process_next_line): Likewise.
7063 (do_define_command): New function, extracted from define_command.
7064 (define_command): Use it.
7066 2018-05-04 Tom Tromey <tom@tromey.com>
7068 * tracepoint.c (actions_command): Update.
7069 * cli/cli-script.h (read_command_lines): Update.
7070 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
7071 (MAX_TMPBUF): Remove define.
7072 (define_command): Use string_printf.
7073 (document_command): Likewise.
7074 * breakpoint.c (commands_command_1): Update.
7076 2018-05-04 Tom Tromey <tom@tromey.com>
7078 * top.c (execute_command): Update.
7079 * cli/cli-script.h (print_command_lines): Now varargs.
7080 * cli/cli-script.c (print_command_lines): Now varargs.
7081 (execute_control_command_1) <case while_control, case if_control>:
7084 2018-05-04 Tom Tromey <tom@tromey.com>
7086 * tracepoint.c (all_tracepoint_actions): Rename from
7087 all_tracepoint_actions_and_cleanup. Change return type.
7088 (actions_command, encode_actions_1, encode_actions)
7089 (trace_dump_actions, tdump_command): Update.
7090 * remote.c (remote_download_command_source): Update.
7091 * python/python.c (gdbpy_eval_from_control_command)
7092 (python_command, python_interactive_command): Update.
7093 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
7094 * guile/guile.c (guile_command)
7095 (gdbscm_eval_from_control_command, guile_command): Update.
7096 * compile/compile.c (compile_code_command)
7097 (compile_print_command, compile_to_object): Update.
7098 * cli/cli-script.h (struct command_lines_deleter): New.
7099 (counted_command_line): New typedef.
7100 (struct command_line): Add constructor, destructor.
7101 <body_list>: Remove.
7102 <body_list_0, body_list_1>: New members.
7103 (command_line_up): Remove typedef.
7104 (read_command_lines, read_command_lines_1, get_command_line):
7106 (copy_command_lines): Don't declare.
7107 * cli/cli-script.c (build_command_line): Use "new".
7108 (get_command_line): Return counted_command_line.
7109 (print_command_lines, execute_user_command)
7110 (execute_control_command_1, while_command, if_command): Update.
7111 (realloc_body_list): Remove.
7112 (process_next_line, recurse_read_control_structure): Update.
7113 (read_command_lines, read_command_lines_1): Return counted_command_line.
7114 (free_command_lines): Use "delete".
7115 (copy_command_lines): Remove.
7116 (define_command, document_command, show_user_1): Update.
7117 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
7118 a counted_command_line.
7119 * breakpoint.h (counted_command_line): Remove typedef.
7120 (breakpoint_set_commands): Update.
7121 * breakpoint.c (check_no_tracepoint_commands)
7122 (validate_commands_for_breakpoint): Update.
7123 (breakpoint_set_commands): Change commands to be a
7124 counted_command_line.
7125 (commands_command_1, update_dprintf_command_list)
7126 (create_tracepoint_from_upload): Update.
7128 2018-05-04 Tom Tromey <tom@tromey.com>
7130 * cli/cli-decode.h (cmd_list_element): New constructor.
7131 (~cmd_list_element): New destructor.
7132 (struct cmd_list_element): Add initializers.
7133 * cli/cli-decode.c (do_add_cmd): Use "new".
7134 (delete_cmd): Use "delete".
7136 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
7137 Pedro Alves <palves@redhat.com>
7139 PR breakpoints/19806 and support for PR external/20207.
7140 * NEWS: Mention Aarch64 watchpoint improvements.
7141 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
7142 watchpoints and PR external/20207 watchpoints.
7143 * nat/aarch64-linux-hw-point.c
7144 (kernel_supports_any_contiguous_range): New.
7145 (aarch64_watchpoint_offset): New.
7146 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
7147 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
7148 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
7149 (aarch64_align_watchpoint): New parameters aligned_offset_p and
7150 next_addr_orig_p. Support PR external/20207 watchpoints.
7151 (aarch64_downgrade_regs): New.
7152 (aarch64_dr_state_insert_one_point): New parameters offset and
7154 (aarch64_dr_state_remove_one_point): Likewise.
7155 (aarch64_handle_breakpoint): Update caller.
7156 (aarch64_handle_aligned_watchpoint): Likewise.
7157 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
7159 (aarch64_linux_set_debug_regs): Remove const from state. Call
7160 aarch64_downgrade_regs.
7161 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
7162 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
7163 (DR_CONTROL_MASK): ... this.
7164 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
7165 (unsigned int aarch64_watchpoint_offset): New prototype.
7166 (aarch64_linux_set_debug_regs): Remove const from state.
7167 * utils.c (align_up, align_down): Move to ...
7168 * common/common-utils.c (align_up, align_down): ... here.
7169 * utils.h (align_up, align_down): Move to ...
7170 * common/common-utils.h (align_up, align_down): ... here.
7172 2018-05-04 Joel Brobecker <brobecker@adacore.com>
7174 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
7175 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
7176 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
7177 Re-implement to match the ABI as summarized in GCC's
7178 gcc/config/sparc/sparc.c. All callers updated.
7179 (sparc32_store_arguments): Remove assertion.
7181 2018-05-04 Tom Tromey <tom@tromey.com>
7183 * printcmd.c: Don't include tui.h.
7184 (decode_format): Use skip_spaces.
7186 2018-05-04 Tom Tromey <tom@tromey.com>
7189 * printcmd.c (last_count): New global.
7190 (x_command): Use saved count when repeating.
7192 2018-05-04 Tom Tromey <tom@tromey.com>
7194 * nto-procfs.c (do_closedir_cleanup): Remove.
7195 (procfs_pidlist): Use gdb_dir_up.
7196 * procfs.c (do_closedir_cleanup): Remove.
7197 (proc_update_threads): Use gdb_dir_up.
7198 * common/filestuff.h (struct gdb_dir_deleter): New.
7199 (gdb_dir_up): New typedef.
7201 2018-05-04 Tom Tromey <tom@tromey.com>
7203 * ada-lang.c (print_mention_exception): Use std::string.
7205 2018-05-04 Tom Tromey <tom@tromey.com>
7207 * ada-lang.c (create_excep_cond_exprs): Update.
7208 (ada_exception_catchpoint_cond_string): Use std::string.
7210 2018-05-04 Tom Tromey <tom@tromey.com>
7212 * ada-lang.c (xget_renaming_scope): Return std::string.
7213 (old_renaming_is_invisible): Update.
7215 2018-05-04 Tom Tromey <tom@tromey.com>
7217 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
7218 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
7220 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
7222 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
7224 2018-05-04 Tom Tromey <tom@tromey.com>
7226 * remote.c (remote_query_supported_append): Change type.
7227 (remote_check_symbols): Update.
7229 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
7232 * configure.ac: Prepend libpython.
7233 * python/python-config.py: Likewise.
7234 * configure: Regenerate.
7236 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
7238 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
7240 2018-05-03 Pedro Alves <palves@redhat.com>
7243 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
7244 override. Write 'true' instead of '1'.
7245 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
7248 2018-05-02 Pedro Alves <palves@redhat.com>
7250 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
7251 add_inf_child_target.
7252 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
7253 add_inf_child_target.
7254 * aix-thread.c (aix_thread_target_info): New.
7255 (aix_thread_target) <shortname, longname, doc>: Delete.
7257 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
7258 add_inf_child_target.
7259 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
7260 add_inf_child_target.
7261 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
7262 add_inf_child_target.
7263 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
7264 add_inf_child_target.
7265 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
7266 add_inf_child_target.
7267 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
7268 add_inf_child_target.
7269 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
7270 add_inf_child_target.
7271 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
7272 add_inf_child_target.
7273 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
7274 add_inf_child_target.
7275 * bfd-target.c (target_bfd_target_info): New.
7276 (target_bfd) <shortname, longname, doc>: Delete.
7278 * bsd-kvm.c (bsd_kvm_target_info): New.
7279 (bsd_kvm_target) <shortname, longname, doc>: Delete.
7281 (bsd_kvm_target::open): Rename to ...
7282 (bsd_kvm_target_open): ... this. Adjust.
7283 * bsd-uthread.c (bsd_uthread_target_info): New.
7284 (bsd_uthread_target) <shortname, longname, doc>: Delete.
7286 * corefile.c (core_file_command): Adjust.
7287 * corelow.c (core_target_info): New.
7288 (core_target) <shortname, longname, doc>: Delete.
7290 (core_target::open): Rename to ...
7291 (core_target_open): ... this. Adjust.
7292 * ctf.c (ctf_target_info): New.
7293 (ctf_target) <shortname, longname, doc>: Delete.
7295 (ctf_target::open): Rename to ...
7296 (ctf_target_open): ... this.
7297 (_initialize_ctf): Adjust.
7298 * exec.c (exec_target_info): New.
7299 (exec_target) <shortname, longname, doc>: Delete.
7301 (exec_target::open): Rename to ...
7302 (exec_target_open): ... this.
7303 * gdbcore.h (core_target_open): Declare.
7304 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
7305 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
7306 add_inf_child_target.
7307 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
7308 add_inf_child_target.
7309 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
7310 add_inf_child_target.
7311 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
7312 add_inf_child_target.
7313 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
7314 add_inf_child_target.
7315 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
7316 add_inf_child_target.
7317 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
7318 add_inf_child_target.
7319 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
7320 add_inf_child_target.
7321 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
7322 add_inf_child_target.
7323 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
7324 add_inf_child_target.
7325 * inf-child.c (inf_child_target_info): New.
7326 (inf_child_target::info): New.
7327 (inf_child_open_target): Remove 'target' parameter. Use
7328 get_native_target instead.
7329 (inf_child_target::open): Delete.
7330 (add_inf_child_target): New.
7331 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
7334 (add_inf_child_target): Declare.
7335 (inf_child_open_target): Declare.
7336 * linux-thread-db.c (thread_db_target_info): New.
7337 (thread_db_target) <shortname, longname, doc>: Delete.
7339 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
7340 add_inf_child_target.
7341 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
7342 add_inf_child_target.
7343 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
7344 add_inf_child_target.
7345 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
7346 add_inf_child_target.
7347 * make-target-delegates (print_class): Adjust.
7348 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
7349 add_inf_child_target.
7350 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
7351 add_inf_child_target.
7352 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
7353 add_inf_child_target.
7354 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
7355 add_inf_child_target.
7356 * nto-procfs.c (nto_native_target_info): New.
7357 (nto_procfs_target_native) <shortname, longname, doc>:
7360 (nto_procfs_target_info): New.
7361 (nto_procfs_target_procfs) <shortname, longname, doc>:
7364 (init_procfs_targets): Adjust.
7365 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
7366 add_inf_child_target.
7367 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
7368 add_inf_child_target.
7369 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
7370 add_inf_child_target.
7371 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
7372 add_inf_child_target.
7373 * ravenscar-thread.c (ravenscar_target_info): New.
7374 (ravenscar_thread_target) <shortname, longname, doc>:
7377 * record-btrace.c (record_btrace_target_info):
7378 (record_btrace_target) <shortname, longname, doc>: Delete.
7380 (record_btrace_target::open): Rename to ...
7381 (record_btrace_target_open): ... this. Adjust.
7382 * record-full.c (record_longname, record_doc): New.
7383 (record_full_base_target) <shortname, longname, doc>: Delete.
7385 (record_full_target_info): New.
7386 (record_full_target): <shortname>: Delete.
7388 (record_full_core_open_1, record_full_open_1): Update comments.
7389 (record_full_base_target::open): Rename to ...
7390 (record_full_open): ... this.
7391 (cmd_record_full_restore): Update.
7392 (_initialize_record_full): Update.
7393 * remote-sim.c (remote_sim_target_info): New.
7394 (gdbsim_target) <shortname, longname, doc>: Delete.
7396 (gdbsim_target::open): Rename to ...
7397 (gdbsim_target_open): ... this.
7398 (_initialize_remote_sim): Adjust.
7399 * remote.c (remote_doc): New.
7400 (remote_target_info): New.
7401 (remote_target) <shortname, longname, doc>: Delete.
7403 (extended_remote_target_info): New.
7404 (extended_remote_target) <shortname, longname, doc>: Delete.
7406 (remote_target::open_1): Make static. Adjust.
7407 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
7408 * s390-linux-nat.c (_initialize_s390_nat): Use
7409 add_inf_child_target.
7410 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
7411 add_inf_child_target.
7412 * sol-thread.c (thread_db_target_info): New.
7413 (sol_thread_target) <shortname, longname, doc>: Delete.
7415 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
7416 add_inf_child_target.
7417 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
7418 add_inf_child_target.
7419 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
7420 add_inf_child_target.
7421 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
7422 add_inf_child_target.
7423 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
7424 add_inf_child_target.
7425 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
7426 add_inf_child_target.
7427 * spu-linux-nat.c (_initialize_spu_nat): Use
7428 add_inf_child_target.
7429 * spu-multiarch.c (spu_multiarch_target_info): New.
7430 (spu_multiarch_target) <shortname, longname, doc>: Delete.
7432 * target-delegates.c: Regenerate.
7433 * target.c: Include <unordered_map>.
7434 (target_ops_p): Delete.
7435 (DEF_VEC_P(target_ops_p)): Delete.
7436 (target_factories): New.
7437 (test_target_info): New.
7438 (test_target_ops::info): New.
7439 (open_target): Adjust to use target_factories.
7440 (add_target_with_completer): Rename to ...
7441 (add_target): ... this. Change prototype. Register target_info
7442 and open callback in target_factories. Register target_info in
7443 command context instead of target_ops.
7444 (add_target): Delete old implementation.
7445 (add_deprecated_target_alias): Change prototype. Adjust.
7446 (the_native_target): New.
7447 (set_native_target, get_native_target): New.
7448 (find_default_run_target): Use the_native_target.
7449 (find_attach_target, find_run_target): Simplify.
7450 (target_ops::open): Delete.
7451 (dummy_target_info): New.
7452 (dummy_target::shortname, dummy_target::longname)
7453 (dummy_target::doc): Delete.
7454 (dummy_target::info): New.
7455 (debug_target::shortname, debug_target::longname)
7456 (debug_target::doc): Delete.
7457 (debug_target::info): New.
7458 * target.h (struct target_info): New.
7459 (target_ops::~target_ops): Add comment.
7460 (target_ops::info): New.
7461 (target_ops::shortname, target_ops::longname, target_ops::doc): No
7462 longer virtual. Implement in terms of target_info.
7463 (set_native_target, get_native_target): Declare.
7464 (target_open_ftype): New.
7465 (add_target, add_target_with_completer)
7466 (add_deprecated_target_alias): Change prototype.
7467 (test_target) <shortname, longname, doc>: Delete.
7469 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
7470 add_inf_child_target.
7471 * tracefile-tfile.c (tfile_target_info): New.
7472 (tfile_target) <shortname, longname, doc>: Delete.
7474 (tfile_target::open): Rename to ...
7475 (tfile_target_open): ... this.
7476 (_initialize_tracefile_tfile): Adjust.
7477 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
7478 add_inf_child_target.
7479 * windows-nat.c (_initialize_windows_nat): Use
7480 add_inf_child_target.
7481 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
7482 add_inf_child_target.
7484 2018-05-02 Pedro Alves <palves@redhat.com>
7486 * linux-nat.h (linux_nat_target) <low_new_thread,
7487 low_delete_thread, low_new_fork, low_forget_process,
7488 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
7489 New virtual methods.
7490 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7491 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
7492 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
7493 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7494 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
7496 * linux-fork.c (delete_fork): Adjust to call low method.
7497 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
7498 (linux_nat_new_fork, linux_nat_forget_process_hook)
7499 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
7500 (linux_nat_status_is_event):
7501 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
7502 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
7504 (sigtrap_is_event): Rename to ...
7505 (linux_nat_target::low_status_is_event): ... this.
7506 (linux_nat_set_status_is_event): Delete.
7507 (save_stop_reason, linux_nat_wait_1)
7508 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
7510 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7511 (linux_nat_set_new_fork, linux_nat_set_forget_process)
7512 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7513 (linux_nat_set_prepare_to_resume): Delete.
7514 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
7515 low virtual methods.
7516 * amd64-linux-nat.c: Likewise.
7517 * arm-linux-nat.c: Likewise.
7518 * i386-linux-nat.c: Likewise.
7519 * ia64-linux-nat.c: Likewise.
7520 * mips-linux-nat.c: Likewise.
7521 * ppc-linux-nat.c: Likewise.
7522 * s390-linux-nat.c: Likewise.
7523 * sparc64-linux-nat.c: Likewise.
7524 * x86-linux-nat.c: Likewise.
7525 * x86-linux-nat.h: Include "nat/x86-linux.h".
7526 (x86_linux_nat_target) <low_new_fork, low_forget_process,
7527 low_prepare_to_resume, low_new_thread, low_delete_thread>:
7530 2018-05-02 Pedro Alves <palves@redhat.com>
7532 * target.h (target_ops)
7533 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
7534 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
7535 stopped_by_watchpoint, have_continuable_watchpoint,
7536 stopped_data_address, watchpoint_addr_within_range,
7537 can_accel_watchpoint_condition, can_run, thread_alive,
7538 has_all_memory, has_memory, has_stack, has_registers,
7539 has_execution, can_async_p, is_async_p, supports_non_stop,
7540 always_non_stop_p, can_execute_reverse, supports_multi_process,
7541 supports_enable_disable_tracepoint,
7542 supports_disable_randomization, supports_string_tracing,
7543 supports_evaluation_of_breakpoint_conditions,
7544 can_run_breakpoint_commands, filesystem_is_local,
7545 can_download_tracepoint, get_trace_state_variable_value,
7546 set_trace_notes, get_tib_address, use_agent, can_use_agent,
7547 record_is_replaying, record_will_replay,
7548 augmented_libraries_svr4_read>: Adjust to return bool.
7549 * aarch64-linux-nat.c: All implementations adjusted.
7550 * aix-thread.c: All implementations adjusted.
7551 * arm-linux-nat.c: All implementations adjusted.
7552 * breakpoint.c: All implementations adjusted.
7553 * bsd-kvm.c: All implementations adjusted.
7554 * bsd-uthread.c: All implementations adjusted.
7555 * corelow.c: All implementations adjusted.
7556 * ctf.c: All implementations adjusted.
7557 * darwin-nat.c: All implementations adjusted.
7558 * darwin-nat.h: All implementations adjusted.
7559 * exec.c: All implementations adjusted.
7560 * fbsd-nat.c: All implementations adjusted.
7561 * fbsd-nat.h: All implementations adjusted.
7562 * gnu-nat.c: All implementations adjusted.
7563 * gnu-nat.h: All implementations adjusted.
7564 * go32-nat.c: All implementations adjusted.
7565 * ia64-linux-nat.c: All implementations adjusted.
7566 * inf-child.c: All implementations adjusted.
7567 * inf-child.h: All implementations adjusted.
7568 * inf-ptrace.c: All implementations adjusted.
7569 * inf-ptrace.h: All implementations adjusted.
7570 * linux-nat.c: All implementations adjusted.
7571 * linux-nat.h: All implementations adjusted.
7572 * mips-linux-nat.c: All implementations adjusted.
7573 * nto-procfs.c: All implementations adjusted.
7574 * ppc-linux-nat.c: All implementations adjusted.
7575 * procfs.c: All implementations adjusted.
7576 * ravenscar-thread.c: All implementations adjusted.
7577 * record-btrace.c: All implementations adjusted.
7578 * record-full.c: All implementations adjusted.
7579 * remote-sim.c: All implementations adjusted.
7580 * remote.c: All implementations adjusted.
7581 * s390-linux-nat.c: All implementations adjusted.
7582 * sol-thread.c: All implementations adjusted.
7583 * spu-multiarch.c: All implementations adjusted.
7584 * target-delegates.c: All implementations adjusted.
7585 * target.c: All implementations adjusted.
7586 * target.h: All implementations adjusted.
7587 * tracefile-tfile.c: All implementations adjusted.
7588 * tracefile.c: All implementations adjusted.
7589 * tracefile.h: All implementations adjusted.
7590 * windows-nat.c: All implementations adjusted.
7591 * x86-linux-nat.h: All implementations adjusted.
7592 * x86-nat.h: All implementations adjusted.
7594 2018-05-02 Pedro Alves <palves@redhat.com>
7596 * make-target-delegates (scan_target_h): Don't trim lines here.
7597 Replace sequences of tabs and/or whitespace with a single
7599 (top level, parsing methods): Trim each line before processing it
7602 2018-05-02 Pedro Alves <palves@redhat.com>
7603 John Baldwin <jhb@freebsd.org>
7605 * target.h (enum strata) <debug_stratum>: New.
7606 (struct target_ops) <all delegation methods>: Replace by C++
7607 virtual methods, and drop "to_" prefix. All references updated
7609 <to_shortname, to_longname, to_doc, to_data,
7610 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
7611 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
7612 virtual methods. All references updated throughout.
7613 <can_attach, supports_terminal_ours, can_create_inferior,
7614 get_thread_control_capabilities, attach_no_wait>: New
7616 <insert_breakpoint, remove_breakpoint>: Now
7617 TARGET_DEFAULT_NORETURN methods.
7618 <info_proc>: Now returns bool.
7620 (OPS_MAGIC): Delete.
7621 (current_target): Delete. All references replaced by references
7623 (target_stack): ... this. New.
7624 (target_shortname, target_longname): Adjust.
7625 (target_can_run): Now a function declaration.
7626 (default_child_has_all_memory, default_child_has_memory)
7627 (default_child_has_stack, default_child_has_registers)
7628 (default_child_has_execution): Remove target_ops parameter.
7629 (complete_target_initialization): Delete.
7630 (memory_breakpoint_target): New template class.
7631 (test_target_ops): Refactor as a C++ class with virtual methods.
7632 * make-target-delegates (NAME_PART): Tighten.
7633 (POINTER_PART, CP_SYMBOL): New.
7634 (SIMPLE_RETURN_PART): Reimplement.
7635 (VEC_RETURN_PART): Expect less.
7636 (RETURN_PART, VIRTUAL_PART): New.
7637 (METHOD): Adjust to C++ virtual methods.
7638 (scan_target_h): Remove reference to C99.
7639 (dname): Output "target_ops::" prefix.
7640 (write_function_header): Adjust to output a C++ class method.
7641 (write_declaration): New.
7642 (write_delegator): Adjust to output a C++ class method.
7643 (tdname): Output "dummy_target::" prefix.
7644 (write_tdefault, write_debugmethod): Adjust to output a C++ class
7646 (tdefault_names, debug_names): Delete.
7647 (return_types, tdefaults, styles, argtypes_array): New.
7648 (top level): All methods are delegators.
7650 (top level): Print dummy_target and debug_target classes.
7651 * target-delegates.c: Regenerate.
7652 * target-debug.h (target_debug_print_enum_info_proc_what)
7653 (target_debug_print_thread_control_capabilities)
7654 (target_debug_print_thread_info_p): New.
7655 * target.c (dummy_target): Delete.
7656 (the_dummy_target, the_debug_target): New.
7657 (target_stack): Now extern.
7658 (set_targetdebug): Push/unpush debug target.
7659 (default_child_has_all_memory, default_child_has_memory)
7660 (default_child_has_stack, default_child_has_registers)
7661 (default_child_has_execution): Remove target_ops parameter.
7662 (complete_target_initialization): Delete.
7663 (add_target_with_completer): No longer call
7664 complete_target_initialization.
7665 (target_supports_terminal_ours): Use regular delegation.
7666 (update_current_target): Delete.
7667 (push_target): No longer check magic number. Don't call
7668 update_current_target.
7669 (unpush_target): Don't call update_current_target.
7670 (target_is_pushed): No longer check magic number.
7671 (target_require_runnable): Skip for all stratums over
7673 (target_ops::info_proc): New.
7674 (target_info_proc): Use find_target_at and
7675 find_default_run_target.
7676 (target_supports_disable_randomization): Use regular delegation.
7677 (target_get_osdata): Use find_target_at.
7678 (target_ops::open, target_ops::close, target_ops::can_attach)
7679 (target_ops::attach, target_ops::can_create_inferior)
7680 (target_ops::create_inferior, target_ops::can_run)
7681 (target_can_run): New.
7682 (default_fileio_target): Use regular delegation.
7683 (target_ops::fileio_open, target_ops::fileio_pwrite)
7684 (target_ops::fileio_pread, target_ops::fileio_fstat)
7685 (target_ops::fileio_close, target_ops::fileio_unlink)
7686 (target_ops::fileio_readlink): New.
7687 (target_fileio_open_1, target_fileio_unlink)
7688 (target_fileio_readlink): Always call the target method. Handle
7690 (return_zero, return_zero_has_execution): Delete.
7691 (init_dummy_target): Delete.
7692 (dummy_target::dummy_target, dummy_target::shortname)
7693 (dummy_target::longname, dummy_target::doc)
7694 (debug_target::debug_target, debug_target::shortname)
7695 (debug_target::longname, debug_target::doc): New.
7696 (target_supports_delete_record): Use regular delegation.
7697 (setup_target_debug): Delete.
7698 (maintenance_print_target_stack): Skip debug_stratum.
7699 (initialize_targets): Instantiate the_dummy_target and
7701 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
7703 (target_auxv_search, fprint_target_auxv): Adjust.
7704 (info_auxv_command): Adjust to use target_stack.
7705 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
7706 * exceptions.c (print_flush): Handle a NULL target_stack.
7707 * regcache.c (target_ops_no_register): Refactor as class with
7710 * exec.c (exec_target): New class.
7711 (exec_ops): Now an exec_target.
7712 (exec_open, exec_close_1, exec_get_section_table)
7713 (exec_xfer_partial, exec_files_info, exec_has_memory)
7714 (exec_make_note_section): Refactor as exec_target methods.
7715 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
7717 (exec_target::find_memory_regions): New.
7718 (_initialize_exec): Don't call init_exec_ops.
7719 * gdbcore.h (exec_file_clear): Delete.
7721 * corefile.c (core_target): Delete.
7722 (core_file_command): Adjust.
7723 * corelow.c (core_target): New class.
7724 (the_core_target): New.
7725 (core_close): Remove target_ops parameter.
7726 (core_close_cleanup): Adjust.
7727 (core_target::close): New.
7728 (core_open, core_detach, get_core_registers, core_files_info)
7729 (core_xfer_partial, core_thread_alive, core_read_description)
7730 (core_pid_to_str, core_thread_name, core_has_memory)
7731 (core_has_stack, core_has_registers, core_info_proc): Rework as
7732 core_target methods.
7733 (ignore, core_remove_breakpoint, init_core_ops): Delete.
7734 (_initialize_corelow): Initialize the_core_target.
7735 * gdbcore.h (core_target): Delete.
7736 (the_core_target): New.
7738 * ctf.c: (ctf_target): New class.
7739 (ctf_ops): Now a ctf_target.
7740 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
7741 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
7742 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
7744 (init_ctf_ops): Delete.
7745 (_initialize_ctf): Don't call it.
7746 * tracefile-tfile.c (tfile_target): New class.
7747 (tfile_ops): Now a tfile_target.
7748 (tfile_open, tfile_close, tfile_files_info)
7749 (tfile_get_tracepoint_status, tfile_trace_find)
7750 (tfile_fetch_registers, tfile_xfer_partial)
7751 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
7752 Refactor as tfile_target methods.
7753 (tfile_xfer_partial_features): Remove target_ops parameter.
7754 (init_tfile_ops): Delete.
7755 (_initialize_tracefile_tfile): Don't call it.
7756 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
7757 (tracefile_has_stack, tracefile_has_registers)
7758 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
7759 tracefile_target methods.
7760 (init_tracefile_ops): Delete.
7761 (tracefile_target::tracefile_target): New.
7762 * tracefile.h: Include "target.h".
7763 (tracefile_target): New class.
7764 (init_tracefile_ops): Delete.
7766 * spu-multiarch.c (spu_multiarch_target): New class.
7767 (spu_ops): Now a spu_multiarch_target.
7768 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
7769 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
7770 (spu_search_memory, spu_mourn_inferior): Refactor as
7771 spu_multiarch_target methods.
7772 (init_spu_ops): Delete.
7773 (_initialize_spu_multiarch): Remove references to init_spu_ops,
7774 complete_target_initialization.
7776 * ravenscar-thread.c (ravenscar_thread_target): New class.
7777 (ravenscar_ops): Now a ravenscar_thread_target.
7778 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
7779 (ravenscar_thread_alive, ravenscar_pid_to_str)
7780 (ravenscar_fetch_registers, ravenscar_store_registers)
7781 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
7782 (ravenscar_stopped_by_hw_breakpoint)
7783 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
7784 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
7785 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
7787 (init_ravenscar_thread_ops): Delete.
7788 (_initialize_ravenscar): Remove references to
7789 init_ravenscar_thread_ops and complete_target_initialization.
7791 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
7792 (bsd_uthread_target): New class.
7793 (bsd_uthread_ops): Now a bsd_uthread_target.
7794 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
7795 (bsd_uthread_close, bsd_uthread_mourn_inferior)
7796 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
7797 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
7798 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
7799 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
7800 (bsd_uthread_target): Delete function.
7801 (_initialize_bsd_uthread): Remove reference to
7802 complete_target_initialization.
7804 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
7805 (target_bfd): ... this new class.
7806 (target_bfd_xfer_partial, target_bfd_get_section_table)
7807 (target_bfd_close): Refactor as target_bfd methods.
7808 (target_bfd::~target_bfd): New.
7809 (target_bfd_reopen): Adjust.
7810 (target_bfd::close): New.
7812 * record-btrace.c (record_btrace_target): New class.
7813 (record_btrace_ops): Now a record_btrace_target.
7814 (record_btrace_open, record_btrace_stop_recording)
7815 (record_btrace_disconnect, record_btrace_close)
7816 (record_btrace_async, record_btrace_info)
7817 (record_btrace_insn_history, record_btrace_insn_history_range)
7818 (record_btrace_insn_history_from, record_btrace_call_history)
7819 (record_btrace_call_history_range)
7820 (record_btrace_call_history_from, record_btrace_record_method)
7821 (record_btrace_is_replaying, record_btrace_will_replay)
7822 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
7823 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
7824 (record_btrace_store_registers, record_btrace_prepare_to_store)
7825 (record_btrace_to_get_unwinder)
7826 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
7827 (record_btrace_commit_resume, record_btrace_wait)
7828 (record_btrace_stop, record_btrace_can_execute_reverse)
7829 (record_btrace_stopped_by_sw_breakpoint)
7830 (record_btrace_supports_stopped_by_sw_breakpoint)
7831 (record_btrace_stopped_by_hw_breakpoint)
7832 (record_btrace_supports_stopped_by_hw_breakpoint)
7833 (record_btrace_update_thread_list, record_btrace_thread_alive)
7834 (record_btrace_goto_begin, record_btrace_goto_end)
7835 (record_btrace_goto, record_btrace_stop_replaying_all)
7836 (record_btrace_execution_direction)
7837 (record_btrace_prepare_to_generate_core)
7838 (record_btrace_done_generating_core): Refactor as
7839 record_btrace_target methods.
7840 (init_record_btrace_ops): Delete.
7841 (_initialize_record_btrace): Remove reference to
7842 init_record_btrace_ops.
7843 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
7844 the execution_direction global.
7845 (record_full_base_target, record_full_target)
7846 (record_full_core_target): New classes.
7847 (record_full_ops): Now a record_full_target.
7848 (record_full_core_ops): Now a record_full_core_target.
7849 (record_full_target::detach, record_full_target::disconnect)
7850 (record_full_core_target::disconnect)
7851 (record_full_target::mourn_inferior, record_full_target::kill):
7853 (record_full_open, record_full_close, record_full_async): Refactor
7854 as methods of the record_full_base_target class.
7855 (record_full_resume, record_full_commit_resume): Refactor
7856 as methods of the record_full_target class.
7857 (record_full_wait, record_full_stopped_by_watchpoint)
7858 (record_full_stopped_data_address)
7859 (record_full_stopped_by_sw_breakpoint)
7860 (record_full_supports_stopped_by_sw_breakpoint)
7861 (record_full_stopped_by_hw_breakpoint)
7862 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
7863 methods of the record_full_base_target class.
7864 (record_full_store_registers, record_full_xfer_partial)
7865 (record_full_insert_breakpoint, record_full_remove_breakpoint):
7866 Refactor as methods of the record_full_target class.
7867 (record_full_can_execute_reverse, record_full_get_bookmark)
7868 (record_full_goto_bookmark, record_full_execution_direction)
7869 (record_full_record_method, record_full_info, record_full_delete)
7870 (record_full_is_replaying, record_full_will_replay)
7871 (record_full_goto_begin, record_full_goto_end, record_full_goto)
7872 (record_full_stop_replaying): Refactor as methods of the
7873 record_full_base_target class.
7874 (record_full_core_resume, record_full_core_kill)
7875 (record_full_core_fetch_registers)
7876 (record_full_core_prepare_to_store)
7877 (record_full_core_store_registers, record_full_core_xfer_partial)
7878 (record_full_core_insert_breakpoint)
7879 (record_full_core_remove_breakpoint)
7880 (record_full_core_has_execution): Refactor
7881 as methods of the record_full_core_target class.
7882 (record_full_base_target::supports_delete_record): New.
7883 (init_record_full_ops): Delete.
7884 (init_record_full_core_ops): Delete.
7885 (record_full_save): Refactor as method of the
7886 record_full_base_target class.
7887 (_initialize_record_full): Remove references to
7888 init_record_full_ops and init_record_full_core_ops.
7890 * remote.c (remote_target, extended_remote_target): New classes.
7891 (remote_ops): Now a remote_target.
7892 (extended_remote_ops): Now an extended_remote_target.
7893 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
7894 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
7895 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
7896 (remote_pass_signals, remote_set_syscall_catchpoint)
7897 (remote_program_signals, )
7898 (remote_thread_always_alive): Remove target_ops parameter.
7899 (remote_thread_alive, remote_thread_name)
7900 (remote_update_thread_list, remote_threads_extra_info)
7901 (remote_static_tracepoint_marker_at)
7902 (remote_static_tracepoint_markers_by_strid)
7903 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
7904 (remote_open): Refactor as methods of remote_target.
7905 (extended_remote_open, extended_remote_detach)
7906 (extended_remote_attach, extended_remote_post_attach):
7907 (extended_remote_supports_disable_randomization)
7908 (extended_remote_create_inferior): : Refactor as method of
7909 extended_remote_target.
7910 (remote_set_permissions, remote_open_1, remote_detach)
7911 (remote_follow_fork, remote_follow_exec, remote_disconnect)
7912 (remote_resume, remote_commit_resume, remote_stop)
7913 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
7914 (remote_terminal_ours, remote_wait, remote_fetch_registers)
7915 (remote_prepare_to_store, remote_store_registers)
7916 (remote_flash_erase, remote_flash_done, remote_files_info)
7917 (remote_kill, remote_mourn, remote_insert_breakpoint)
7918 (remote_remove_breakpoint, remote_insert_watchpoint)
7919 (remote_watchpoint_addr_within_range)
7920 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
7921 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
7922 (remote_supports_stopped_by_sw_breakpoint)
7923 (remote_stopped_by_hw_breakpoint)
7924 (remote_supports_stopped_by_hw_breakpoint)
7925 (remote_stopped_by_watchpoint, remote_stopped_data_address)
7926 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
7927 (remote_verify_memory): Refactor as methods of remote_target.
7928 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
7930 (remote_xfer_partial, remote_get_memory_xfer_limit)
7931 (remote_search_memory, remote_rcmd, remote_memory_map)
7932 (remote_pid_to_str, remote_get_thread_local_address)
7933 (remote_get_tib_address, remote_read_description): Refactor as
7934 methods of remote_target.
7935 (remote_target::fileio_open, remote_target::fileio_pwrite)
7936 (remote_target::fileio_pread, remote_target::fileio_close): New.
7937 (remote_hostio_readlink, remote_hostio_fstat)
7938 (remote_filesystem_is_local, remote_can_execute_reverse)
7939 (remote_supports_non_stop, remote_supports_disable_randomization)
7940 (remote_supports_multi_process, remote_supports_cond_breakpoints)
7941 (remote_supports_enable_disable_tracepoint)
7942 (remote_supports_string_tracing)
7943 (remote_can_run_breakpoint_commands, remote_trace_init)
7944 (remote_download_tracepoint, remote_can_download_tracepoint)
7945 (remote_download_trace_state_variable, remote_enable_tracepoint)
7946 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
7947 (remote_trace_start, remote_get_trace_status)
7948 (remote_get_tracepoint_status, remote_trace_stop)
7949 (remote_trace_find, remote_get_trace_state_variable_value)
7950 (remote_save_trace_data, remote_get_raw_trace_data)
7951 (remote_set_disconnected_tracing, remote_core_of_thread)
7952 (remote_set_circular_trace_buffer, remote_traceframe_info)
7953 (remote_get_min_fast_tracepoint_insn_len)
7954 (remote_set_trace_buffer_size, remote_set_trace_notes)
7955 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
7956 (remote_disable_btrace, remote_teardown_btrace)
7957 (remote_read_btrace, remote_btrace_conf)
7958 (remote_augmented_libraries_svr4_read, remote_load)
7959 (remote_pid_to_exec_file, remote_can_do_single_step)
7960 (remote_execution_direction, remote_thread_handle_to_thread_info):
7961 Refactor as methods of remote_target.
7962 (init_remote_ops, init_extended_remote_ops): Delete.
7963 (remote_can_async_p, remote_is_async_p, remote_async)
7964 (remote_thread_events, remote_upload_tracepoints)
7965 (remote_upload_trace_state_variables): Refactor as methods of
7967 (_initialize_remote): Remove references to init_remote_ops and
7968 init_extended_remote_ops.
7970 * remote-sim.c (gdbsim_target): New class.
7971 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
7972 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
7973 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
7974 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
7975 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
7976 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
7977 Refactor as methods of gdbsim_target.
7978 (gdbsim_ops): Now a gdbsim_target.
7979 (init_gdbsim_ops): Delete.
7980 (gdbsim_cntrl_c): Adjust.
7981 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
7983 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
7984 (the_amd64_linux_nat_target): New.
7985 (amd64_linux_fetch_inferior_registers)
7986 (amd64_linux_store_inferior_registers): Refactor as methods of
7987 amd64_linux_nat_target.
7988 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
7989 * i386-linux-nat.c: Don't include "linux-nat.h".
7990 (i386_linux_nat_target): New class.
7991 (the_i386_linux_nat_target): New.
7992 (i386_linux_fetch_inferior_registers)
7993 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
7994 as methods of i386_linux_nat_target.
7995 (_initialize_i386_linux_nat): Adjust. Set linux_target.
7996 * inf-child.c (inf_child_ops): Delete.
7997 (inf_child_fetch_inferior_registers)
7998 (inf_child_store_inferior_registers): Delete.
7999 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
8000 methods of inf_child_target.
8001 (inf_child_target::supports_terminal_ours)
8002 (inf_child_target::terminal_init)
8003 (inf_child_target::terminal_inferior)
8004 (inf_child_target::terminal_ours_for_output)
8005 (inf_child_target::terminal_ours, inf_child_target::interrupt)
8006 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
8008 (inf_child_open, inf_child_disconnect, inf_child_close)
8009 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
8010 (inf_child_post_startup_inferior, inf_child_can_run)
8011 (inf_child_pid_to_exec_file): Refactor as methods of
8013 (inf_child_follow_fork): Delete.
8014 (inf_child_target::can_create_inferior)
8015 (inf_child_target::can_attach): New.
8016 (inf_child_target::has_all_memory, inf_child_target::has_memory)
8017 (inf_child_target::has_stack, inf_child_target::has_registers)
8018 (inf_child_target::has_execution): New.
8019 (inf_child_fileio_open, inf_child_fileio_pwrite)
8020 (inf_child_fileio_pread, inf_child_fileio_fstat)
8021 (inf_child_fileio_close, inf_child_fileio_unlink)
8022 (inf_child_fileio_readlink, inf_child_use_agent)
8023 (inf_child_can_use_agent): Refactor as methods of
8025 (return_zero, inf_child_target): Delete.
8026 (inf_child_target::inf_child_target): New.
8027 * inf-child.h: Include "target.h".
8028 (inf_child_target): Delete function prototype.
8029 (inf_child_target): New class.
8030 (inf_child_open_target, inf_child_mourn_inferior)
8031 (inf_child_maybe_unpush_target): Delete.
8032 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
8033 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
8034 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
8035 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
8036 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
8037 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
8038 (inf_ptrace_wait, inf_ptrace_xfer_partial)
8039 (inf_ptrace_thread_alive, inf_ptrace_files_info)
8040 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
8041 methods of inf_ptrace_target.
8042 (inf_ptrace_target): Delete function.
8043 * inf-ptrace.h: Include "inf-child.h".
8044 (inf_ptrace_target): Delete function declaration.
8045 (inf_ptrace_target): New class.
8046 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
8047 * linux-nat.c (linux_target): New.
8048 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
8049 (linux_nat_target::~linux_nat_target): New.
8050 (linux_child_post_attach, linux_child_post_startup_inferior)
8051 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
8052 (linux_child_remove_fork_catchpoint)
8053 (linux_child_insert_vfork_catchpoint)
8054 (linux_child_remove_vfork_catchpoint)
8055 (linux_child_insert_exec_catchpoint)
8056 (linux_child_remove_exec_catchpoint)
8057 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
8058 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
8059 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
8060 (linux_nat_stopped_data_address)
8061 (linux_nat_stopped_by_sw_breakpoint)
8062 (linux_nat_supports_stopped_by_sw_breakpoint)
8063 (linux_nat_stopped_by_hw_breakpoint)
8064 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
8065 (linux_nat_kill, linux_nat_mourn_inferior)
8066 (linux_nat_xfer_partial, linux_nat_thread_alive)
8067 (linux_nat_update_thread_list, linux_nat_pid_to_str)
8068 (linux_nat_thread_name, linux_child_pid_to_exec_file)
8069 (linux_child_static_tracepoint_markers_by_strid)
8070 (linux_nat_is_async_p, linux_nat_can_async_p)
8071 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
8072 (linux_nat_supports_multi_process)
8073 (linux_nat_supports_disable_randomization, linux_nat_async)
8074 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
8075 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
8076 (linux_nat_fileio_open, linux_nat_fileio_readlink)
8077 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
8078 methods of linux_nat_target.
8079 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
8080 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
8082 (check_stopped_by_watchpoint): Adjust.
8083 (linux_xfer_partial): Delete.
8084 (linux_target_install_ops, linux_target, linux_nat_add_target):
8086 (linux_nat_target::linux_nat_target): New.
8087 * linux-nat.h: Include "inf-ptrace.h".
8088 (linux_nat_target): New.
8089 (linux_target, linux_target_install_ops, linux_nat_add_target):
8090 Delete function declarations.
8091 (linux_target): Declare global.
8092 * linux-thread-db.c (thread_db_target): New.
8093 (thread_db_target::thread_db_target): New.
8094 (thread_db_ops): Delete.
8095 (the_thread_db_target): New.
8096 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
8097 (thread_db_update_thread_list, thread_db_pid_to_str)
8098 (thread_db_extra_thread_info)
8099 (thread_db_thread_handle_to_thread_info)
8100 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
8101 (thread_db_resume): Refactor as methods of thread_db_target.
8102 (init_thread_db_ops): Delete.
8103 (_initialize_thread_db): Remove reference to init_thread_db_ops.
8104 * x86-linux-nat.c: Don't include "linux-nat.h".
8105 (super_post_startup_inferior): Delete.
8106 (x86_linux_nat_target::~x86_linux_nat_target): New.
8107 (x86_linux_child_post_startup_inferior)
8108 (x86_linux_read_description, x86_linux_enable_btrace)
8109 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
8110 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
8111 methods of x86_linux_nat_target.
8112 (x86_linux_create_target): Delete. Bits folded ...
8113 (x86_linux_add_target): ... here. Now takes a linux_nat_target
8115 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
8116 (x86_linux_nat_target): New class.
8117 (x86_linux_create_target): Delete.
8118 (x86_linux_add_target): Now takes a linux_nat_target pointer.
8119 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
8120 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
8121 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
8122 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
8123 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
8125 (x86_use_watchpoints): Delete.
8126 * x86-nat.h: Include "breakpoint.h" and "target.h".
8127 (x86_use_watchpoints): Delete.
8128 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
8129 (x86_stopped_by_watchpoint, x86_stopped_data_address)
8130 (x86_insert_watchpoint, x86_remove_watchpoint)
8131 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
8132 (x86_stopped_by_hw_breakpoint): New declarations.
8133 (x86_nat_target): New template class.
8135 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
8136 (the_ppc_linux_nat_target): New.
8137 (ppc_linux_fetch_inferior_registers)
8138 (ppc_linux_can_use_hw_breakpoint)
8139 (ppc_linux_region_ok_for_hw_watchpoint)
8140 (ppc_linux_ranged_break_num_registers)
8141 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
8142 (ppc_linux_insert_mask_watchpoint)
8143 (ppc_linux_remove_mask_watchpoint)
8144 (ppc_linux_can_accel_watchpoint_condition)
8145 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
8146 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
8147 (ppc_linux_watchpoint_addr_within_range)
8148 (ppc_linux_masked_watch_num_registers)
8149 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
8150 (ppc_linux_read_description): Refactor as methods of
8151 ppc_linux_nat_target.
8152 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
8154 * procfs.c (procfs_xfer_partial): Delete forward declaration.
8155 (procfs_target): New class.
8156 (the_procfs_target): New.
8157 (procfs_target): Delete function.
8158 (procfs_auxv_parse, procfs_attach, procfs_detach)
8159 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
8160 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
8161 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
8162 (procfs_create_inferior, procfs_update_thread_list)
8163 (procfs_thread_alive, procfs_pid_to_str)
8164 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
8165 (procfs_stopped_data_address, procfs_insert_watchpoint)
8166 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
8167 (proc_find_memory_regions, procfs_info_proc)
8168 (procfs_make_note_section): Refactor as methods of procfs_target.
8169 (_initialize_procfs): Adjust.
8170 * sol-thread.c (sol_thread_target): New class.
8171 (sol_thread_ops): Now a sol_thread_target.
8172 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
8173 (sol_thread_fetch_registers, sol_thread_store_registers)
8174 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
8175 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
8176 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
8177 (init_sol_thread_ops): Delete.
8178 (_initialize_sol_thread): Adjust. Remove references to
8179 init_sol_thread_ops and complete_target_initialization.
8181 * windows-nat.c (windows_nat_target): New class.
8182 (windows_fetch_inferior_registers)
8183 (windows_store_inferior_registers, windows_resume, windows_wait)
8184 (windows_attach, windows_detach, windows_pid_to_exec_file)
8185 (windows_files_info, windows_create_inferior)
8186 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
8187 (windows_close, windows_pid_to_str, windows_xfer_partial)
8188 (windows_get_tib_address, windows_get_ada_task_ptid)
8189 (windows_thread_name, windows_thread_alive): Refactor as
8190 windows_nat_target methods.
8191 (do_initial_windows_stuff): Adjust.
8192 (windows_target): Delete function.
8193 (_initialize_windows_nat): Adjust.
8195 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
8196 (darwin_mourn_inferior, darwin_kill_inferior)
8197 (darwin_create_inferior, darwin_attach, darwin_detach)
8198 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
8199 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
8200 (darwin_supports_multi_process): Refactor as darwin_nat_target
8202 (darwin_resume_to, darwin_files_info): Delete.
8203 (_initialize_darwin_inferior): Rename to ...
8204 (_initialize_darwin_nat): ... this. Adjust to C++ification.
8205 * darwin-nat.h: Include "inf-child.h".
8206 (darwin_nat_target): New class.
8207 (darwin_complete_target): Delete.
8208 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
8209 (darwin_target): New.
8210 (i386_darwin_fetch_inferior_registers)
8211 (i386_darwin_store_inferior_registers): Refactor as methods of
8213 (darwin_complete_target): Delete, with ...
8214 (_initialize_i386_darwin_nat): ... bits factored out here.
8216 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
8217 (the_alpha_linux_nat_target): New.
8218 (alpha_linux_register_u_offset): Refactor as
8219 alpha_linux_nat_target method.
8220 (_initialize_alpha_linux_nat): Adjust.
8221 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
8222 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8223 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
8224 methods of linux_nat_trad_target.
8225 (linux_trad_target): Delete.
8226 * linux-nat-trad.h (linux_trad_target): Delete function.
8227 (linux_nat_trad_target): New class.
8228 * mips-linux-nat.c (mips_linux_nat_target): New class.
8229 (super_fetch_registers, super_store_registers, super_close):
8231 (the_mips_linux_nat_target): New.
8232 (mips64_linux_regsets_fetch_registers)
8233 (mips64_linux_regsets_store_registers)
8234 (mips64_linux_fetch_registers, mips64_linux_store_registers)
8235 (mips_linux_register_u_offset, mips_linux_read_description)
8236 (mips_linux_can_use_hw_breakpoint)
8237 (mips_linux_stopped_by_watchpoint)
8238 (mips_linux_stopped_data_address)
8239 (mips_linux_region_ok_for_hw_watchpoint)
8240 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
8241 (mips_linux_close): Refactor as methods of mips_linux_nat.
8242 (_initialize_mips_linux_nat): Adjust to C++ification.
8244 * aix-thread.c (aix_thread_target): New class.
8245 (aix_thread_ops): Now an aix_thread_target.
8246 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
8247 (aix_thread_fetch_registers, aix_thread_store_registers)
8248 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
8249 (aix_thread_thread_alive, aix_thread_pid_to_str)
8250 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
8251 Refactor as methods of aix_thread_target.
8252 (init_aix_thread_ops): Delete.
8253 (_initialize_aix_thread): Remove references to init_aix_thread_ops
8254 and complete_target_initialization.
8255 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
8256 (rs6000_nat_target): New class.
8257 (the_rs6000_nat_target): New.
8258 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
8259 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
8260 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
8261 (super_create_inferior): Delete.
8262 (_initialize_rs6000_nat): Adjust to C++ification.
8264 * arm-linux-nat.c (arm_linux_nat_target): New class.
8265 (the_arm_linux_nat_target): New.
8266 (arm_linux_fetch_inferior_registers)
8267 (arm_linux_store_inferior_registers, arm_linux_read_description)
8268 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
8269 (arm_linux_remove_hw_breakpoint)
8270 (arm_linux_region_ok_for_hw_watchpoint)
8271 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
8272 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
8273 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
8274 arm_linux_nat_target.
8275 (_initialize_arm_linux_nat): Adjust to C++ification.
8277 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
8278 (the_aarch64_linux_nat_target): New.
8279 (aarch64_linux_fetch_inferior_registers)
8280 (aarch64_linux_store_inferior_registers)
8281 (aarch64_linux_child_post_startup_inferior)
8282 (aarch64_linux_read_description)
8283 (aarch64_linux_can_use_hw_breakpoint)
8284 (aarch64_linux_insert_hw_breakpoint)
8285 (aarch64_linux_remove_hw_breakpoint)
8286 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
8287 (aarch64_linux_region_ok_for_hw_watchpoint)
8288 (aarch64_linux_stopped_data_address)
8289 (aarch64_linux_stopped_by_watchpoint)
8290 (aarch64_linux_watchpoint_addr_within_range)
8291 (aarch64_linux_can_do_single_step): Refactor as methods of
8292 aarch64_linux_nat_target.
8293 (super_post_startup_inferior): Delete.
8294 (_initialize_aarch64_linux_nat): Adjust to C++ification.
8296 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
8297 (the_hppa_linux_nat_target): New.
8298 (hppa_linux_fetch_inferior_registers)
8299 (hppa_linux_store_inferior_registers): Refactor as methods of
8300 hppa_linux_nat_target.
8301 (_initialize_hppa_linux_nat): Adjust to C++ification.
8303 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
8304 (the_ia64_linux_nat_target): New.
8305 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
8306 (ia64_linux_stopped_data_address)
8307 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
8308 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
8309 ia64_linux_nat_target methods.
8310 (super_xfer_partial): Delete.
8311 (_initialize_ia64_linux_nat): Adjust to C++ification.
8313 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
8314 (the_m32r_linux_nat_target): New.
8315 (m32r_linux_fetch_inferior_registers)
8316 (m32r_linux_store_inferior_registers): Refactor as
8317 m32r_linux_nat_target methods.
8318 (_initialize_m32r_linux_nat): Adjust to C++ification.
8320 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
8321 (the_m68k_linux_nat_target): New.
8322 (m68k_linux_fetch_inferior_registers)
8323 (m68k_linux_store_inferior_registers): Refactor as
8324 m68k_linux_nat_target methods.
8325 (_initialize_m68k_linux_nat): Adjust to C++ification.
8327 * s390-linux-nat.c (s390_linux_nat_target): New class.
8328 (the_s390_linux_nat_target): New.
8329 (s390_linux_fetch_inferior_registers)
8330 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
8331 (s390_insert_watchpoint, s390_remove_watchpoint)
8332 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
8333 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
8334 (s390_auxv_parse, s390_read_description): Refactor as methods of
8335 s390_linux_nat_target.
8336 (_initialize_s390_nat): Adjust to C++ification.
8338 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
8339 (the_sparc_linux_nat_target): New.
8340 (_initialize_sparc_linux_nat): Adjust to C++ification.
8341 * sparc-nat.c (sparc_fetch_inferior_registers)
8342 (sparc_store_inferior_registers): Remove target_ops parameter.
8343 * sparc-nat.h (sparc_fetch_inferior_registers)
8344 (sparc_store_inferior_registers): Remove target_ops parameter.
8345 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
8346 (the_sparc64_linux_nat_target): New.
8347 (_initialize_sparc64_linux_nat): Adjust to C++ification.
8349 * spu-linux-nat.c (spu_linux_nat_target): New class.
8350 (the_spu_linux_nat_target): New.
8351 (spu_child_post_startup_inferior, spu_child_post_attach)
8352 (spu_child_wait, spu_fetch_inferior_registers)
8353 (spu_store_inferior_registers, spu_xfer_partial)
8354 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
8356 (_initialize_spu_nat): Adjust to C++ification.
8358 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
8359 (the_tilegx_linux_nat_target): New.
8360 (fetch_inferior_registers, store_inferior_registers):
8361 Refactor as methods.
8362 (_initialize_tile_linux_nat): Adjust to C++ification.
8364 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
8365 (the_xtensa_linux_nat_target): New.
8366 (xtensa_linux_fetch_inferior_registers)
8367 (xtensa_linux_store_inferior_registers): Refactor as
8368 xtensa_linux_nat_target methods.
8369 (_initialize_xtensa_linux_nat): Adjust to C++ification.
8371 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
8372 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
8373 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
8374 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
8375 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
8376 (fbsd_stopped_by_sw_breakpoint)
8377 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
8378 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
8379 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
8380 (fbsd_post_startup_inferior, fbsd_post_attach)
8381 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
8382 (fbsd_set_syscall_catchpoint)
8383 (super_xfer_partial, super_resume, super_wait)
8384 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
8385 (fbsd_handle_debug_trap): Remove target_ops parameter.
8386 (fbsd_nat_add_target): Delete.
8387 * fbsd-nat.h: Include "inf-ptrace.h".
8388 (fbsd_nat_add_target): Delete.
8389 (USE_SIGTRAP_SIGINFO): Define.
8390 (fbsd_nat_target): New class.
8392 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
8393 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
8394 (amd64bsd_target): Delete.
8395 * amd64-bsd-nat.h: New file.
8396 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
8398 (amd64_fbsd_nat_target): New class.
8399 (the_amd64_fbsd_nat_target): New.
8400 (amd64fbsd_read_description): Refactor as method of
8401 amd64_fbsd_nat_target.
8402 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8403 (_initialize_amd64fbsd_nat): Adjust to C++ification.
8404 * amd64-nat.h (amd64bsd_target): Delete function declaration.
8405 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
8406 (i386bsd_store_inferior_registers): Remove target_ops parameter.
8407 (i386bsd_target): Delete.
8408 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
8409 (i386bsd_fetch_inferior_registers)
8410 (i386bsd_store_inferior_registers): Declare.
8411 (i386_bsd_nat_target): New class.
8412 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
8413 (the_i386_fbsd_nat_target): New.
8414 (i386fbsd_resume, i386fbsd_read_description): Refactor as
8415 i386_fbsd_nat_target methods.
8416 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8417 (_initialize_i386fbsd_nat): Adjust to C++ification.
8418 * x86-bsd-nat.c (super_mourn_inferior): Delete.
8419 (x86bsd_mourn_inferior, x86bsd_target): Delete.
8420 (_initialize_x86_bsd_nat): Adjust to C++ification.
8421 * x86-bsd-nat.h: Include "x86-nat.h".
8422 (x86bsd_target): Delete declaration.
8423 (x86bsd_nat_target): New class.
8425 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
8426 (the_aarch64_fbsd_nat_target): New.
8427 (aarch64_fbsd_fetch_inferior_registers)
8428 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
8429 aarch64_fbsd_nat_target.
8430 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
8431 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
8432 (the_alpha_bsd_nat_target): New.
8433 (alphabsd_fetch_inferior_registers)
8434 (alphabsd_store_inferior_registers): Refactor as
8435 alpha_bsd_nat_target methods.
8436 (_initialize_alphabsd_nat): Refactor as methods of
8437 alpha_bsd_nat_target.
8438 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
8439 (the_amd64_nbsd_nat_target): New.
8440 (_initialize_amd64nbsd_nat): Adjust to C++ification.
8441 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
8442 (the_amd64_obsd_nat_target): New.
8443 (_initialize_amd64obsd_nat): Adjust to C++ification.
8444 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
8445 (the_arm_fbsd_nat_target): New.
8446 (arm_fbsd_fetch_inferior_registers)
8447 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
8448 (_initialize_arm_fbsd_nat): Refactor as methods of
8449 arm_fbsd_nat_target.
8450 (_initialize_arm_fbsd_nat): Adjust to C++ification.
8451 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
8452 (the_arm_netbsd_nat_target): New.
8453 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
8454 arm_netbsd_nat_target.
8455 (_initialize_arm_netbsd_nat): Adjust to C++ification.
8456 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
8457 (the_hppa_nbsd_nat_target): New.
8458 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
8459 hppa_nbsd_nat_target methods.
8460 (_initialize_hppanbsd_nat): Adjust to C++ification.
8461 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
8462 (the_hppa_obsd_nat_target): New.
8463 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
8464 methods of hppa_obsd_nat_target.
8465 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
8467 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
8468 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
8470 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
8471 (_initialize_i386obsd_nat): Use add_target.
8472 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
8473 (the_m68k_bsd_nat_target): New.
8474 (m68kbsd_fetch_inferior_registers)
8475 (m68kbsd_store_inferior_registers): Refactor as methods of
8476 m68k_bsd_nat_target.
8477 (_initialize_m68kbsd_nat): Adjust to C++ification.
8478 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
8479 (the_mips_fbsd_nat_target): New.
8480 (mips_fbsd_fetch_inferior_registers)
8481 (mips_fbsd_store_inferior_registers): Refactor as methods of
8482 mips_fbsd_nat_target.
8483 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
8485 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
8486 (the_mips_nbsd_nat_target): New.
8487 (mipsnbsd_fetch_inferior_registers)
8488 (mipsnbsd_store_inferior_registers): Refactor as methods of
8489 mips_nbsd_nat_target.
8490 (_initialize_mipsnbsd_nat): Adjust to C++ification.
8491 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
8492 (the_mips64_obsd_nat_target): New.
8493 (mips64obsd_fetch_inferior_registers)
8494 (mips64obsd_store_inferior_registers): Refactor as methods of
8495 mips64_obsd_nat_target.
8496 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
8498 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
8500 * nbsd-nat.h: Include "inf-ptrace.h".
8501 (nbsd_nat_target): New class.
8502 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
8503 (obsd_wait): Refactor as methods of obsd_nat_target.
8504 (obsd_add_target): Delete.
8505 * obsd-nat.h: Include "inf-ptrace.h".
8506 (obsd_nat_target): New class.
8507 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
8508 (the_ppc_fbsd_nat_target): New.
8509 (ppcfbsd_fetch_inferior_registers)
8510 (ppcfbsd_store_inferior_registers): Refactor as methods of
8511 ppc_fbsd_nat_target.
8512 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
8514 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
8515 (the_ppc_nbsd_nat_target): New.
8516 (ppcnbsd_fetch_inferior_registers)
8517 (ppcnbsd_store_inferior_registers): Refactor as methods of
8518 ppc_nbsd_nat_target.
8519 (_initialize_ppcnbsd_nat): Adjust to C++ification.
8520 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
8521 (the_ppc_obsd_nat_target): New.
8522 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
8523 methods of ppc_obsd_nat_target.
8524 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
8526 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
8527 (the_sh_nbsd_nat_target): New.
8528 (shnbsd_fetch_inferior_registers)
8529 (shnbsd_store_inferior_registers): Refactor as methods of
8531 (_initialize_shnbsd_nat): Adjust to C++ification.
8532 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
8533 (inf_ptrace_xfer_partial): Delete.
8534 (sparc_xfer_partial, sparc_target): Delete.
8535 * sparc-nat.h (sparc_fetch_inferior_registers)
8536 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
8537 (sparc_target): Delete function declaration.
8538 (sparc_target): New template class.
8539 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
8540 (_initialize_sparcnbsd_nat): Adjust to C++ification.
8541 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
8542 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
8544 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
8545 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
8546 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
8547 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
8549 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
8550 (the_vax_bsd_nat_target): New.
8551 (vaxbsd_fetch_inferior_registers)
8552 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
8554 (_initialize_vaxbsd_nat): Adjust to C++ification.
8556 * bsd-kvm.c (bsd_kvm_target): New class.
8557 (bsd_kvm_ops): Now a bsd_kvm_target.
8558 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
8559 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
8560 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
8562 (bsd_kvm_return_one): Delete.
8563 (bsd_kvm_add_target): Adjust to C++ification.
8565 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
8566 (nto_procfs_target_procfs): New classes.
8567 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
8568 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
8569 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
8570 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
8571 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
8572 (procfs_remove_hw_breakpoint, procfs_resume)
8573 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
8574 (procfs_kill_inferior, procfs_store_registers)
8575 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
8576 as methods of nto_procfs_target.
8577 (nto_procfs_ops): Now an nto_procfs_target_procfs.
8578 (nto_native_ops): Delete.
8579 (procfs_open, procfs_native_open): Delete.
8580 (nto_native_ops): Now an nto_procfs_target_native.
8581 (init_procfs_targets): Adjust to C++ification.
8582 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
8583 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
8584 Refactor as methods of nto_procfs_target.
8586 * go32-nat.c (go32_nat_target): New class.
8587 (the_go32_nat_target): New.
8588 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
8589 (go32_store_registers, go32_xfer_partial, go32_files_info)
8590 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
8591 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
8592 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
8593 (go32_pid_to_str): Refactor as methods of go32_nat_target.
8594 (go32_target): Delete.
8595 (_initialize_go32_nat): Adjust to C++ification.
8597 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
8598 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
8599 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
8600 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
8602 (gnu_target): Delete.
8603 * gnu-nat.h (gnu_target): Delete.
8604 (gnu_nat_target): New class.
8605 * i386-gnu-nat.c (gnu_base_target): New.
8606 (i386_gnu_nat_target): New class.
8607 (the_i386_gnu_nat_target): New.
8608 (_initialize_i386gnu_nat): Adjust to C++ification.
8610 2018-05-02 Pedro Alves <palves@redhat.com>
8612 * bfd-target.c (target_bfd_xclose): Rename to ...
8613 (target_bfd_close): ... this.
8614 (target_bfd_reopen): Adjust.
8615 * target.c (target_close): Remove references to to_xclose.
8616 * target.h (target_ops::to_xclose): Delete.
8617 (target_ops::to_close): Update comments.
8619 2018-05-02 Pedro Alves <palves@redhat.com>
8621 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
8623 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
8624 * inf-ptrace.c (inf_ptrace_register_u_offset)
8625 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8626 (inf_ptrace_store_register, inf_ptrace_store_registers)
8627 (inf_ptrace_trad_target): Move to ...
8628 * linux-nat-trad.c: ... this new file.
8629 * linux-nat-trad.h: New file.
8630 * linux-nat.c (linux_target_install_ops): Make extern.
8631 (linux_trad_target): Delete.
8632 * linux-nat.h (linux_trad_target): Delete declaration.
8633 (linux_target_install_ops): Declare.
8634 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
8637 2018-05-02 Pedro Alves <palves@redhat.com>
8639 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8640 procfs_target/add_target here.
8641 * procfs.c (procfs_target): Make static.
8642 (_initialize_procfs): Call add_target here.
8643 * procfs.h (struct target_ops): Remove forward declaration.
8644 (procfs_target): Remove declaration.
8645 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
8647 2018-05-02 Pedro Alves <palves@redhat.com>
8649 * procfs.c (procfs_stopped_by_watchpoint)
8650 (procfs_insert_watchpoint, procfs_remove_watchpoint)
8651 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
8653 (procfs_use_watchpoints): Delete, move contents...
8654 (procfs_target): ... here.
8655 * procfs.h (procfs_use_watchpoints): Delete declaration.
8656 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8657 procfs_use_watchpoints.
8658 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
8659 procfs_use_watchpoints.
8661 2018-05-02 Tom Tromey <tom@tromey.com>
8664 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
8665 and var_zuinteger_unlimited.
8666 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
8667 and PARAM_ZUINTEGER_UNLIMITED.
8668 (set_parameter_value): Handle var_zuinteger and
8669 var_zuinteger_unlimited.
8670 (add_setshow_generic): Likewise.
8671 (parmpy_init): Likewise.
8673 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
8676 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
8677 pointer is not null before dereferencing it.
8679 2018-04-30 Tom Tromey <tom@tromey.com>
8681 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
8684 2018-04-30 Tom Tromey <tom@tromey.com>
8686 * breakpoint.c (mention): Remove use of is_mi_like_p.
8687 (print_mention_ranged_breakpoint): Likewise.
8688 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
8691 2018-04-30 Tom Tromey <tom@tromey.com>
8693 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
8695 2018-04-30 Tom Tromey <tom@tromey.com>
8697 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
8698 (info_spu_event_command): Remove some uses of is_mi_like_p.
8700 2018-04-30 Tom Tromey <tom@tromey.com>
8702 * python/py-framefilter.c (py_print_single_arg)
8703 (enumerate_locals, py_print_args, py_print_frame): Remove some
8704 uses of is_mi_like_p.
8706 2018-04-30 Tom Tromey <tom@tromey.com>
8709 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
8710 * ui-out.h (ui_out::is_mi_like_p): Now const.
8711 (ui_out::do_is_mi_like_p): Now const.
8712 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
8714 2018-04-30 Tom Tromey <tom@tromey.com>
8716 * varobj.c (varobj_set_visualizer): Use new_reference.
8717 * python/python.c (gdbpy_decode_line): Use new_reference.
8718 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
8721 2018-04-30 Tom Tromey <tom@tromey.com>
8723 * varobj.c (install_new_value): Use new_reference.
8724 * value.h (value_incref): Return void. Swap intro comment with
8726 * value.c (set_value_parent): Use new_reference.
8727 (value_incref): Return void. Update intro comment.
8728 (release_value): Use new_reference.
8729 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
8731 2018-04-30 Tom Tromey <tom@tromey.com>
8733 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
8734 * gdb_bfd.h (new_bfd_ref): Remove.
8735 (gdb_bfd_open): Update comment.
8736 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
8737 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
8738 (gdb_bfd_fdopenr): Use new_reference.
8739 * exec.c (exec_file_attach): Use new_reference.
8741 2018-04-30 Tom Tromey <tom@tromey.com>
8743 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
8746 2018-04-30 Tom Tromey <tom@tromey.com>
8748 * jit.c (jit_read_code_entry): Use type_align.
8749 * i386-tdep.c (i386_gdbarch_init): Don't call
8750 set_gdbarch_long_long_align_bit.
8751 * gdbarch.sh: Remove long_long_align_bit.
8752 * gdbarch.c, gdbarch.h: Rebuild.
8753 * arc-tdep.c (arc_type_align): New function.
8754 (arc_gdbarch_init): Use arc_type_align. Don't call
8755 set_gdbarch_long_long_align_bit.
8757 2018-04-30 Tom Tromey <tom@tromey.com>
8759 * rust-lang.c (rust_type_alignment): Remove.
8760 (rust_composite_type): Use type_align.
8762 2018-04-30 Tom Tromey <tom@tromey.com>
8764 * NEWS: Mention Type.align.
8765 * python/py-type.c (typy_get_alignof): New function.
8766 (type_object_getset): Add "alignof".
8768 2018-04-30 Tom Tromey <tom@tromey.com>
8772 * std-operator.def (UNOP_ALIGNOF): New operator.
8773 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
8775 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
8776 * c-lang.c (c_op_print_tab): Add alignof.
8777 * c-exp.y (ALIGNOF): New token.
8778 (exp): Add "ALIGNOF" production.
8779 (ident_tokens): Add _Alignof and alignof.
8781 2018-04-30 Tom Tromey <tom@tromey.com>
8783 * i386-tdep.c (i386_type_align): New function.
8784 (i386_gdbarch_init): Update.
8785 * gdbarch.sh (type_align): New method.
8786 * gdbarch.c, gdbarch.h: Rebuild.
8787 * arch-utils.h (default_type_align): Declare.
8788 * arch-utils.c (default_type_align): New function.
8789 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
8790 (struct type) <align_log2>: New field.
8791 <instance_flags>: Now a bitfield.
8792 (TYPE_RAW_ALIGN): New macro.
8793 (type_align, type_raw_align, set_type_align): Declare.
8794 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
8796 * dwarf2read.c (quirk_rust_enum): Set type alignment.
8797 (get_alignment, maybe_set_alignment): New functions.
8798 (read_structure_type, read_enumeration_type, read_array_type)
8799 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
8800 (read_subrange_type, read_base_type): Set type alignment.
8802 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
8804 * dwarf2read.c (read_index_from_section): Use bool.
8806 2018-04-29 Fabian Groffen <grobian@gentoo.org>
8809 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
8812 2018-04-29 John Reiser <jreiser@BitWagon.com>
8815 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
8816 last step, and do it atomically.
8818 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
8820 * compile/compile-c-types.c (convert_int, convert_float):
8823 2018-04-27 Tom Tromey <tom@tromey.com>
8826 * rust-lang.c (rust_inclusive_range_type_p): New function.
8827 (rust_range): Handle inclusive ranges.
8828 (rust_compute_range): Likewise.
8829 * rust-exp.y (struct rust_op) <inclusive>: New field.
8830 (DOTDOTEQ): New constant.
8831 (range_expr): Add "..=" productions.
8832 (operator_tokens): Add "..=" token.
8833 (ast_range): Add "inclusive" parameter.
8834 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
8836 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
8838 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
8839 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
8841 * expprint.c (print_subexp_standard): Handle new bounds values.
8842 (dump_subexp_body_standard): Likewise.
8844 2018-04-27 Tom Tromey <tom@tromey.com>
8846 * configure: Rebuild.
8847 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
8848 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
8850 (class symbol_needs_eval_context): Likewise.
8851 * dwarf2read.c (mock_mapped_index::symbol_name_count)
8852 (mock_mapped_index::symbol_name_at): Use "override". Remove
8854 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
8856 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
8857 * aarch64-tdep.c (instruction_reader::read): Use "override".
8858 (instruction_reader_test::read): Likewise.
8859 * arm-tdep.c (instruction_reader::read): Use "override".
8860 (instruction_reader_thumb::read): Likewise.
8862 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
8865 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
8866 instead of remote_send.
8867 (remote_send): Remove.
8869 2018-04-26 Pedro Alves <palves@redhat.com>
8871 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
8872 find_function_start_sal instead of find_pc_line.
8874 2018-04-26 Pedro Alves <palves@redhat.com>
8876 * breakpoint.c (set_breakpoint_location_function): Handle
8878 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
8879 * elfread.c (elf_symtab_read): Give data symbols with
8880 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
8881 (elf_rel_plt_read): Update comment.
8882 * linespec.c (convert_linespec_to_sals): Handle
8884 (minsym_found): Handle mst_data_gnu_ifunc.
8885 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
8886 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
8887 * parse.c (find_minsym_type_and_address): Handle
8889 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
8890 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
8891 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
8893 <mst_data_gnu_ifunc>: New enumerator.
8895 2018-04-26 Pedro Alves <palves@redhat.com>
8897 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
8898 (lookup_minimal_symbol_by_pc_section): ... this. Replace
8899 'want_trampoline' parameter by a lookup_msym_prefer parameter.
8901 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
8902 (lookup_minimal_symbol_by_pc): Adjust.
8903 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
8904 (lookup_solib_trampoline_symbol_by_pc): Adjust.
8905 * minsyms.h (lookup_msym_prefer): New enum.
8906 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
8907 parameter by a lookup_msym_prefer parameter.
8909 2018-04-26 Pedro Alves <palves@redhat.com>
8911 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
8912 ends in "@plt" instead of looking at the symbol's section.
8914 2018-04-26 Pedro Alves <palves@redhat.com>
8916 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
8918 (find_pc_partial_function_gnu_ifunc): Rename to ...
8919 (find_pc_partial_function): ... this, and remove references to
8921 (find_pc_partial_function): Delete old implementation.
8922 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
8924 2018-04-26 Pedro Alves <palves@redhat.com>
8926 * linespec.c (struct bound_minimal_symbol_search_key): New.
8927 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
8928 skip first line if we found a GNU ifunc minimal symbol by name.
8929 (compare_msymbols): Change parameters to work with a destructured
8931 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
8934 2018-04-26 Pedro Alves <palves@redhat.com>
8936 * breakpoint.c (set_breakpoint_location_function): Don't resolve
8937 ifunc targets here. Instead, if we have an ifunc minsym, use its
8939 (add_location_to_breakpoint): Store the minsym and the objfile in
8940 the breakpoint location.
8941 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
8942 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
8943 Record the minsym in the sal.
8944 * symtab.h (symtab_and_line) <msymbol>: New field.
8946 2018-04-26 Pedro Alves <palves@redhat.com>
8948 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
8949 unless we actually resolved the ifunc.
8951 2018-04-26 Pedro Alves <palves@redhat.com>
8953 * c-exp.y (variable production): Prefer ifunc minsyms over
8954 regular function symbols.
8955 * symtab.c (find_gnu_ifunc): New function.
8956 * minsyms.h (lookup_msym_prefer): New enum.
8957 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
8958 parameter by a lookup_msym_prefer parameter.
8959 * symtab.h (find_gnu_ifunc): New declaration.
8961 2018-04-26 Pedro Alves <palves@redhat.com>
8963 * blockframe.c (find_gnu_ifunc_target_type): New function.
8964 (find_function_type): New.
8965 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
8966 return a value with a memory address.
8967 (eval_call): For calls to GNU ifunc functions, try to find the
8968 type of the target function from the type that the resolver
8970 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
8972 * infcall.c (find_function_return_type): Delete.
8973 (find_function_addr): Add 'function_type' parameter. For calls to
8974 GNU ifunc functions, try to find the type of the target function
8975 from the type that the resolver returns, and return it via
8977 (call_function_by_hand_dummy): Adjust to use the function type
8978 returned by find_function_addr.
8979 (find_function_addr): Add 'function_type' parameter and move
8981 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
8984 2018-04-26 Pedro Alves <palves@redhat.com>
8986 * c-exp.y (variable production): Skip finding an alias for ifunc
8989 2018-04-26 Pedro Alves <palves@redhat.com>
8991 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
8993 2018-04-25 Pedro Alves <palves@redhat.com>
8995 * infcmd.c (kill_command): Print the pid as string, not the whole
8996 thread's ptid. Add comment. s/has been killed/killed/ in output
8998 * remote.c (remote_detach_1): Print the pid as string, not the
8999 whole thread's ptid.
9001 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9002 Sergio Durigan Junior <sergiodj@redhat.com>
9003 Pedro Alves <palves@redhat.com>
9005 * infcmd.c (kill_command): Print message when inferior has
9007 * inferior.c (print_inferior_events): Remove 'static'. Set as
9009 (add_inferior): Improve message printed when
9010 'print_inferior_events' is on.
9011 (exit_inferior): Remove message printed when
9012 'print_inferior_events' is on.
9013 (detach_inferior): Improve message printed when
9014 'print_inferior_events' is on.
9015 (initialize_inferiors): Use 'add_inferior_silent' to set
9016 'current_inferior_'.
9017 * inferior.h (print_inferior_events): Declare here as
9019 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
9020 '[Detaching...]' messages when 'print_inferior_events' is on.
9021 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
9022 as prefix/suffix for messages. Remove periods. Fix erroneous
9023 'Detaching after fork from child...', replace it by '... from
9025 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
9026 prefix/suffix when printing 'Detaching...' messages. Print
9027 them when 'print_inferior_events' is on.
9028 * remote.c (remote_detach_1): Print message when detaching
9029 from inferior and '!is_fork_parent'.
9031 2018-04-24 Tom Tromey <tom@tromey.com>
9033 * cli-out.h: Reindent.
9035 2018-04-24 Tom Tromey <tom@tromey.com>
9037 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
9038 (cli_ui_out::do_field_string): Use fputs_filtered.
9039 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
9041 2018-04-23 Tom Tromey <tom@tromey.com>
9043 * guile/scm-frame.c (gdbscm_frame_read_var): Use
9044 gdb::unique_xmalloc_ptr.
9046 2018-04-23 Tom Tromey <tom@tromey.com>
9048 * configure: Rebuild.
9050 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
9053 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
9054 prepare_for_testing. Set normal_bp to r_debug_state if target
9057 2018-04-21 Pedro Alves <palves@redhat.com>
9058 Rajendra SY <rajendra.sy@gmail.com>
9060 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
9061 * remote.c (extended_remote_attach): In all-stop mode, mark the
9062 thread as executing.
9064 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9066 * thread.c (thread_apply_all_command): Fix comment.
9067 (thread_command): Fix comment.
9069 2018-04-10 Alan Hayward <alan.hayward@arm.com>
9071 * common/tdesc.h (tdesc_create_feature): Remove xml filename
9073 * features/aarch64-core.c (create_feature_aarch64_core):
9075 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
9077 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
9079 * features/i386/32bit-avx512.c
9080 (create_feature_i386_32bit_avx512): Likewise.
9081 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
9083 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
9085 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
9087 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
9089 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
9091 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
9093 * features/i386/64bit-avx512.c
9094 (create_feature_i386_64bit_avx512): Likewise.
9095 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
9097 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
9099 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
9101 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
9103 * features/i386/64bit-segments.c
9104 (create_feature_i386_64bit_segments): Likewise.
9105 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
9107 * features/i386/x32-core.c
9108 (create_feature_i386_x32_core): Likewise.
9109 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
9110 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
9111 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
9112 * target-descriptions.c: In generated code, don't pass xml
9115 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9117 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
9118 (print_xml_feature::visit_post): Likewise.
9119 (print_xml_feature::visit): Likewise.
9120 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
9121 (print_xml_feature): Add new class.
9122 * regformats/regdat.sh: Null xmltarget on feature targets.
9123 * target-descriptions.c (struct target_desc): Add xmltarget.
9124 (maintenance_check_tdesc_xml_convert): Add unittest function.
9125 (tdesc_get_features_xml): Add function to get xml.
9126 (maintenance_check_xml_descriptions): Test xml generation.
9127 * xml-tdesc.c (string_read_description_xml): Add function.
9128 * xml-tdesc.h (string_read_description_xml): Add declaration.
9130 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9132 * features/Makefile: Add feature marker to targets with new style
9133 target descriptions.
9134 * regformats/aarch64.dat: Regenerate.
9135 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
9136 * regformats/i386/amd64-avx-linux.dat: Likewise.
9137 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
9138 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
9139 * regformats/i386/amd64-linux.dat: Likewise.
9140 * regformats/i386/amd64-mpx-linux.dat: Likewise.
9141 * regformats/i386/amd64.dat: Likewise.
9142 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
9143 * regformats/i386/i386-avx-linux.dat: Likewise.
9144 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
9145 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
9146 * regformats/i386/i386-linux.dat: Likewise.
9147 * regformats/i386/i386-mmx-linux.dat: Likewise.
9148 * regformats/i386/i386-mpx-linux.dat: Likewise.
9149 * regformats/i386/i386.dat: Likewise.
9150 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
9151 * regformats/i386/x32-avx-linux.dat: Likewise.
9152 * regformats/i386/x32-linux.dat: Likewise.
9153 * regformats/tic6x-c62x-linux.dat: Likewise.
9154 * regformats/tic6x-c64x-linux.dat: Likewise.
9155 * regformats/tic6x-c64xp-linux.dat: Likewise.
9156 * regformats/regdat.sh: Parse feature marker.
9158 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9160 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
9161 (tdesc_osabi_name): Likewise.
9162 * target-descriptions.c (tdesc_architecture_name): Add new
9164 (tdesc_osabi_name): Likewise.
9166 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9168 * common/tdesc.c (tdesc_predefined_type): Move to here.
9169 (tdesc_named_type): Likewise.
9170 (tdesc_create_vector): Likewise.
9171 (tdesc_create_struct): Likewise.
9172 (tdesc_set_struct_size): Likewise.
9173 (tdesc_create_union): Likewise.
9174 (tdesc_create_flags): Likewise.
9175 (tdesc_create_enum): Likewise.
9176 (tdesc_add_field): Likewise.
9177 (tdesc_add_typed_bitfield): Likewise.
9178 (tdesc_add_bitfield): Likewise.
9179 (tdesc_add_flag): Likewise.
9180 (tdesc_add_enum_value): Likewise.
9181 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
9182 (struct tdesc_type_vector): Likewise.
9183 (struct tdesc_type_field): Likewise.
9184 (struct tdesc_type_with_fields): Likewise.
9185 (tdesc_create_enum): Add declaration.
9186 (tdesc_add_typed_bitfield): Likewise.
9187 (tdesc_add_enum_value): Likewise.
9188 * target-descriptions.c (tdesc_type_field): Move from here.
9189 (tdesc_type_builtin): Likewise.
9190 (tdesc_type_vector): Likewise.
9191 (tdesc_type_with_fields): Likewise.
9192 (tdesc_predefined_types): Likewise.
9193 (tdesc_named_type): Likewise.
9194 (tdesc_create_vector): Likewise.
9195 (tdesc_create_struct): Likewise.
9196 (tdesc_set_struct_size): Likewise.
9197 (tdesc_create_union): Likewise.
9198 (tdesc_create_flags): Likewise.
9199 (tdesc_create_enum): Likewise.
9200 (tdesc_add_field): Likewise.
9201 (tdesc_add_typed_bitfield): Likewise.
9202 (tdesc_add_bitfield): Likewise.
9203 (tdesc_add_flag): Likewise.
9204 (tdesc_add_enum_value): Likewise.
9205 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
9206 (tdesc_add_typed_bitfield): Likewise.
9207 (tdesc_add_enum_value): Likewise.
9209 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9211 * common/tdesc.c (tdesc_feature::accept): Move to here.
9212 (tdesc_feature::operator==): Likewise.
9213 (tdesc_create_reg): Likewise.
9214 * common/tdesc.h (tdesc_type_kind): Likewise.
9215 (struct tdesc_type): Likewise.
9216 (struct tdesc_feature): Likewise.
9217 * regformats/regdat.sh: Create a feature.
9218 * target-descriptions.c (tdesc_type_kind): Move from here.
9219 (tdesc_type): Likewise.
9220 (tdesc_type_up): Likewise.
9221 (tdesc_feature): Likewise.
9222 (tdesc_create_reg): Likewise.
9224 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9226 * Makefile.in: Add arch/tdesc.c
9227 * common/tdesc.c: New file.
9228 * common/tdesc.h (tdesc_element_visitor): Move to here.
9229 (tdesc_element): Likewise.
9230 (tdesc_reg): Likewise.
9231 (tdesc_reg_up): Likewise.
9232 * regformats/regdef.h (reg): Add offset to constructors.
9233 * target-descriptions.c (tdesc_element_visitor): Move from here.
9234 (tdesc_element): Likewise.
9235 (tdesc_reg): Likewise.
9236 (tdesc_reg_up): Likewise.
9238 2018-04-17 Tom Tromey <tom@tromey.com>
9240 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
9243 2018-04-17 Tom Tromey <tom@tromey.com>
9245 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
9247 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
9249 * symtab.c (print_symbol_info): Skip printing filename and line
9250 number when `last' is NULL.
9251 (symtab_symbol_info): Use empty string instead of NULL for first
9252 invocation of print_symbol_info.
9253 (rbreak_command): Pass NULL to `last' parameter of
9256 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
9258 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
9261 2018-04-16 Pedro Alves <palves@redhat.com>
9263 * MAINTAINERS (sh): Remove.
9264 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
9265 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
9266 (ALLDEPFILES): Remove sh64-tdep.c.
9267 * NEWS: Mentions that support for SH-5/SH64 is removed.
9268 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
9269 (sh*-*-openbsd*): Ditto.
9270 (sh64-*-elf*): Remove.
9272 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
9273 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
9274 * sh-tdep.c: No longer include "sh64-tdep.h".
9275 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
9276 * sh64-tdep.c, sh64-tdep.h: Remove files.
9278 2018-04-16 Pedro Alves <palves@redhat.com>
9280 * MAINTAINERS: Remove m88k.
9281 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
9282 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
9283 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
9284 * NEWS: Mention that support for m88k was removed.
9285 * configure.host (m88*-*-*): Remove support.
9286 * configure.nat (m88k-*-*): Remove support.
9287 * configure.tgt (m88*-*-openbsd*): Remove.
9288 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
9290 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
9292 * configure.tgt (x86_tobjs): New variable.
9293 (amd64_tobjs, i386_tobjs): Use it.
9295 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9297 * symtab.c (print_symbol_info): Precede the symbol definition by
9298 the line number when available.
9299 * NEWS: Advertise this enhancement.
9301 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9303 * NEWS (New options): announce set/show record btrace cpu.
9304 * btrace.c: Include record-btrace.h.
9305 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
9306 the vendor is unknown.
9307 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
9308 Maybe overwrite the btrace configuration's cpu.
9309 (btrace_compute_ftrace): Add cpu parameter. Update callers.
9310 (btrace_fetch): Add cpu parameter. Update callers.
9311 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
9312 Maybe overwrite the btrace configuration's cpu. Skip enabling
9313 errata workarounds if the vendor is unknown.
9314 * python/py-record-btrace.c: Include record-btrace.h.
9315 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
9316 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
9317 * record-btrace.c (record_btrace_cpu_state_kind): New.
9318 (record_btrace_cpu): New.
9319 (set_record_btrace_cpu_cmdlist): New.
9320 (record_btrace_get_cpu): New.
9321 (require_btrace_thread, record_btrace_info)
9322 (record_btrace_resume_thread): Call record_btrace_get_cpu.
9323 (cmd_set_record_btrace_cpu_none): New.
9324 (cmd_set_record_btrace_cpu_auto): New.
9325 (cmd_set_record_btrace_cpu): New.
9326 (cmd_show_record_btrace_cpu): New.
9327 (_initialize_record_btrace): Initialize set/show record btrace cpu
9329 * record-btrace.h (record_btrace_get_cpu): New.
9331 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9333 * record.c (set_record_command): Fix typo in message.
9335 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9337 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
9339 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9341 * infrun.c (process_event_stop_test): Call
9342 gdbarch_in_indirect_branch_thunk.
9343 * gdbarch.sh (in_indirect_branch_thunk): New.
9344 * gdbarch.c: Regenerated.
9345 * gdbarch.h: Regenerated.
9348 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
9349 (HFILES_NO_SRCDIR): Add x86-tdep.h.
9350 (ALLDEPFILES): Add x86-tdep.c.
9351 * arch-utils.h (default_in_indirect_branch_thunk): New.
9352 * arch-utils.c (default_in_indirect_branch_thunk): New.
9353 * i386-tdep: Include x86-tdep.h.
9354 (i386_in_indirect_branch_thunk): New.
9355 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
9357 * amd64-tdep: Include x86-tdep.h.
9358 (amd64_in_indirect_branch_thunk): New.
9359 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
9361 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
9364 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
9365 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
9366 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
9369 2018-04-12 Tom Tromey <tom@tromey.com>
9371 * rust-lang.c (rust_print_struct_def): Remove univariant code.
9372 (rust_evaluate_subexp): Likewise.
9374 2018-04-12 Pedro Alves <palves@redhat.com>
9376 * procfs.c (procfs_detach): Make forward declaration's prototype
9377 match definition's protototype.
9378 (proc_get_LDT_entry): Remove stale do_cleanups call.
9380 2018-04-12 Pedro Alves <palves@redhat.com>
9382 * target.h (target_ops::to_has_exited): Delete.
9383 (target_has_exited): Delete.
9384 * target-delegates.c: Regenerate.
9386 2018-04-11 Pedro Alves <palves@redhat.com>
9388 * target.c (fileio_fh_t::t): Add comment.
9389 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9390 (target_fileio_close): Handle a NULL target.
9391 (invalidate_fileio_fh): New.
9392 (target_close): Call it.
9393 * remote.c (remote_hostio_send_command): No longer check whether
9394 remote_desc is open.
9396 2018-04-11 Pedro Alves <palves@redhat.com>
9398 * target.c (fileio_fh_t): Make it a named struct instead of a
9400 (fileio_fh_t::is_closed): New method.
9401 (DEF_VEC_O (fileio_fh_t)): Remove.
9402 (fileio_fhandles): Now a std::vector.
9403 (is_closed_fileio_fh): Delete.
9404 (acquire_fileio_fd): Adjust. Rename parameters.
9405 (release_fileio_fd): Adjust.
9406 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
9407 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9408 (target_fileio_close): Adjust.
9410 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
9412 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
9415 2018-04-10 Pedro Alves <palves@redhat.com>
9417 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
9418 (scoped_finish_thread_state): New class.
9419 * infcmd.c (run_command_1): Use it instead of finish_thread_state
9421 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
9422 (fetch_inferior_event, normal_stop): Likewise.
9423 * thread.c (finish_thread_state_cleanup): Delete.
9425 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9426 Pedro Alves <palves@redhat.com>
9428 * value.c: Include "selftest.h" and "common/array-view.h".
9429 (struct range) <operator ==>: New.
9430 (test_ranges_contain): New.
9431 (check_ranges_vector): New.
9432 (test_insert_into_bit_range_vector): New.
9433 (_initialize_values): Register selftests.
9434 * common/array-view.h (operator==, operator!=): New.
9436 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9438 * common/gdb_vecs.h (unordered_remove): Add overload that takes
9440 * inline-frame.c: Include <algorithm>.
9441 (struct inline_state): Add constructor.
9442 (inline_state_s): Remove.
9443 (DEF_VEC_O(inline_state_s)): Remove.
9444 (inline_states): Change type to std::vector.
9445 (find_inline_frame_state): Adjust to std::vector.
9446 (allocate_inline_frame_state): Remove.
9447 (clear_inline_frame_state): Adjust to std::vector.
9448 (skip_inline_frames): Adjust to std::vector.
9450 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9452 * tracepoint.h (struct trace_state_variable): Add constructor.
9453 <name>: Change type to std::string.
9454 * tracepoint.c (tsv_s): Remove.
9455 (DEF_VEC_O(tsv_s)): Remove.
9456 (tvariables): Change to std::vector.
9457 (create_trace_state_variable): Adjust to std::vector.
9458 (find_trace_state_variable): Likewise.
9459 (find_trace_state_variable_by_number): Likewise.
9460 (delete_trace_state_variable): Likewise.
9461 (trace_variable_command): Adjust to std::string.
9462 (delete_trace_variable_command): Likewise.
9463 (tvariables_info_1): Adjust to std::vector.
9464 (save_trace_state_variables): Likewise.
9465 (start_tracing): Likewise.
9466 (merge_uploaded_trace_state_variables): Adjust to std::vector
9468 * target.h (struct target_ops)
9469 <to_download_trace_state_variable>: Pass reference to
9470 trace_state_variable.
9471 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
9472 * target-delegates.c: Re-generate.
9473 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
9474 (mi_tsv_deleted): Likewise.
9475 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
9476 * remote.c (remote_download_trace_state_variable): Change
9477 pointer to reference and adjust.
9478 * make-target-delegates (parse_argtypes): Handle references.
9479 (write_function_header): Likewise.
9480 (munge_type): Likewise.
9482 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9484 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9485 string_view-selftests.c.
9486 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
9488 * unittests/basic_string_view/cons/char/1.cc: Likewise.
9489 * unittests/basic_string_view/cons/char/2.cc: Likewise.
9490 * unittests/basic_string_view/cons/char/3.cc: Likewise.
9491 * unittests/basic_string_view/element_access/char/1.cc:
9493 * unittests/basic_string_view/element_access/char/empty.cc:
9495 * unittests/basic_string_view/element_access/char/front_back.cc:
9497 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
9498 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
9500 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
9502 * unittests/basic_string_view/modifiers/swap/char/1.cc:
9504 * unittests/basic_string_view/operations/compare/char/1.cc:
9506 * unittests/basic_string_view/operations/compare/char/13650.cc:
9508 * unittests/basic_string_view/operations/copy/char/1.cc:
9510 * unittests/basic_string_view/operations/data/char/1.cc:
9512 * unittests/basic_string_view/operations/find/char/1.cc:
9514 * unittests/basic_string_view/operations/find/char/2.cc:
9516 * unittests/basic_string_view/operations/find/char/3.cc:
9518 * unittests/basic_string_view/operations/find/char/4.cc:
9520 * unittests/basic_string_view/operations/rfind/char/1.cc:
9522 * unittests/basic_string_view/operations/rfind/char/2.cc:
9524 * unittests/basic_string_view/operations/rfind/char/3.cc:
9526 * unittests/basic_string_view/operations/substr/char/1.cc:
9528 * unittests/basic_string_view/operators/char/2.cc: Likewise.
9529 * unittests/string_view-selftests.c: New file.
9531 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9533 * unittests/basic_string_view/capacity/1.cc: New file.
9534 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
9535 * unittests/basic_string_view/cons/char/1.cc: New file.
9536 * unittests/basic_string_view/cons/char/2.cc: New file.
9537 * unittests/basic_string_view/cons/char/3.cc: New file.
9538 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
9539 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
9540 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
9541 * unittests/basic_string_view/element_access/char/1.cc: New file.
9542 * unittests/basic_string_view/element_access/char/2.cc: New file.
9543 * unittests/basic_string_view/element_access/char/empty.cc: New file.
9544 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
9545 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
9546 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
9547 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
9548 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
9549 * unittests/basic_string_view/include.cc: New file.
9550 * unittests/basic_string_view/inserters/char/1.cc: New file.
9551 * unittests/basic_string_view/inserters/char/2.cc: New file.
9552 * unittests/basic_string_view/inserters/char/3.cc: New file.
9553 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
9554 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
9555 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
9556 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
9557 * unittests/basic_string_view/literals/types.cc: New file.
9558 * unittests/basic_string_view/literals/values.cc: New file.
9559 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
9560 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
9561 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
9562 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
9563 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
9564 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
9565 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
9566 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
9567 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
9568 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
9569 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
9570 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
9571 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
9572 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
9573 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
9574 * unittests/basic_string_view/operations/data/char/1.cc: New file.
9575 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
9576 * unittests/basic_string_view/operations/find/char/1.cc: New file.
9577 * unittests/basic_string_view/operations/find/char/2.cc: New file.
9578 * unittests/basic_string_view/operations/find/char/3.cc: New file.
9579 * unittests/basic_string_view/operations/find/char/4.cc: New file.
9580 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
9581 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
9582 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
9583 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
9584 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
9585 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
9586 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
9587 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
9588 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
9589 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
9590 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
9591 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
9592 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
9593 * unittests/basic_string_view/operators/char/2.cc: New file.
9594 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
9595 * unittests/basic_string_view/range_access/char/1.cc: New file.
9596 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
9597 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
9598 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
9599 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
9600 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
9601 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
9602 * unittests/basic_string_view/requirements/typedefs.cc: New file.
9603 * unittests/basic_string_view/typedefs.cc: New file.
9604 * unittests/basic_string_view/types/1.cc: New file.
9606 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9608 * common/gdb_string_view.h: Remove libstdc++ implementation
9609 details, adjust to gdb reality.
9610 * common/gdb_string_view.tcc: Likewise.
9611 * cli/cli-script.c (struct string_view): Remove.
9612 (user_args) <m_args>: Change element type to gdb::string_view.
9613 (user_args::insert_args): Adjust.
9615 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9617 * common/gdb_string_view.h: New file.
9618 * common/gdb_string_view.tcc: New file.
9620 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9622 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
9623 * configure: Re-generate.
9625 2018-04-09 Pedro Alves <palves@redhat.com>
9627 * gdbarch.sh: Include "observable.h" instead of "observer.h".
9628 (set_target_gdbarch): Call
9629 gdb::observers::architecture_changed.notify instead of
9630 observer_notify_architecture_changed.
9632 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9634 * tracepoint.c (struct current_traceframe_cleanup): Remove.
9635 (do_restore_current_traceframe_cleanup): Remove.
9636 (restore_current_traceframe_cleanup_dtor): Remove.
9637 (make_cleanup_restore_current_traceframe): Remove.
9638 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
9640 * tracepoint.h (struct scoped_restore_current_traceframe): New.
9641 * infrun.c (fetch_inferior_event): Use
9642 scoped_restore_current_traceframe.
9644 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9646 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
9648 <n_allocated_type_units>: Remove.
9649 <all_type_units>: Change to std::vector.
9650 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9651 to std::vector change.
9652 (dwarf2_per_objfile::get_cutu): Likewise.
9653 (dwarf2_per_objfile::get_tu): Likewise.
9654 (create_signatured_type_table_from_index): Likewise.
9655 (create_signatured_type_table_from_debug_names): Likewise.
9656 (dw2_symtab_iter_next): Likewise.
9657 (dw2_print_stats): Likewise.
9658 (dw2_expand_all_symtabs): Likewise.
9659 (dw2_expand_marked_cus): Likewise.
9660 (dw2_debug_names_iterator::next): Likewise.
9661 (dwarf2_initialize_objfile): Likewise.
9662 (add_signatured_type_cu_to_table): Likewise.
9663 (create_all_type_units): Likewise.
9664 (add_type_unit): Likewise.
9665 (struct tu_abbrev_offset): Add constructor.
9666 (build_type_psymtabs_1): Adjust to std::vector change.
9667 (print_tu_stats): Likewise.
9668 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9669 (write_debug_names): Likewise.
9671 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9673 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
9674 Make an std::vector.
9675 <n_comp_units>: Remove.
9676 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9677 to std::vector change.
9678 (dwarf2_per_objfile::get_cutu): Likewise.
9679 (dwarf2_per_objfile::get_cu): Likewise.
9680 (create_cus_from_index): Likewise.
9681 (create_addrmap_from_index): Likewise.
9682 (create_addrmap_from_aranges): Likewise.
9683 (dwarf2_read_index): Likewise.
9684 (dw2_find_last_source_symtab): Likewise.
9685 (dw2_map_symtabs_matching_filename): Likewise.
9686 (dw2_symtab_iter_next): Likewise.
9687 (dw2_print_stats): Likewise.
9688 (dw2_expand_all_symtabs): Likewise.
9689 (dw2_expand_symtabs_with_fullname): Likewise.
9690 (dw2_expand_marked_cus): Likewise.
9691 (dw2_map_symbol_filenames): Likewise.
9692 (create_cus_from_debug_names): Likewise.
9693 (dwarf2_read_debug_names): Likewise.
9694 (dw2_debug_names_iterator::next): Likewise.
9695 (dwarf2_initialize_objfile): Likewise.
9696 (set_partial_user): Likewise.
9697 (dwarf2_build_psymtabs_hard): Likewise.
9698 (read_comp_units_from_section): Remove arguments, adjust to
9700 (create_all_comp_units): Adjust to std::vector and
9701 read_comp_units_from_section changes.
9702 (dwarf2_find_containing_comp_unit): Adjust to std::vector
9704 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9705 (psyms_seen_size): Likewise.
9706 (write_gdbindex): Likewise.
9707 (write_debug_names): Likewise.
9709 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9711 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
9712 with dwarf2_per_objfile.
9713 (create_cus_from_index): Likewise.
9714 (create_signatured_type_table_from_index): Likewise.
9715 (dwarf2_read_index): Likewise.
9716 (dwarf2_initialize_objfile): Likewise.
9717 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
9718 per_cu rather than get_dwarf2_per_objfile.
9720 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9722 * dwarf2read.h (struct signatured_type): Forward declare.
9723 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
9725 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
9726 (dw2_get_cutu): ...this.
9727 (dwarf2_per_objfile::get_cu): Rename from...
9728 (dw2_get_cu): ...this.
9729 (dwarf2_per_objfile::get_tu): New.
9730 (create_addrmap_from_index): Adjust.
9731 (create_addrmap_from_aranges): Adjust.
9732 (dw2_find_last_source_symtab): Adjust.
9733 (dw2_map_symtabs_matching_filename): Adjust.
9734 (dw2_symtab_iter_next): Adjust.
9735 (dw2_print_stats): Adjust.
9736 (dw2_expand_all_symtabs): Adjust.
9737 (dw2_expand_symtabs_with_fullname): Adjust.
9738 (dw2_expand_marked_cus): Adjust.
9739 (dw_expand_symtabs_matching_file_matcher): Adjust.
9740 (dw2_map_symbol_filenames): Adjust.
9741 (dw2_debug_names_iterator::next): Adjust.
9742 (dwarf2_initialize_objfile): Adjust.
9743 (set_partial_user): Adjust.
9744 (dwarf2_build_psymtabs_hard): Adjust.
9746 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9748 * dwarf2read.c (create_signatured_type_table_from_debug_names):
9749 Remove unused variables.
9750 (dw2_map_symtabs_matching_filename): Likewise.
9751 (dwarf2_record_block_ranges): Likewise.
9752 (dwarf2_read_addr_index): Likewise.
9753 (follow_die_offset): Likewise.
9755 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9757 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
9758 to symbol_file_add_main.
9760 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9763 * mi/mi-console.c (do_fputc_async_safe): New.
9764 (mi_console_file::write_async_safe): New.
9765 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
9766 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
9768 * ui-file.c (ui_file::putstrn): Adjust call to
9769 fputstrn_unfiltered.
9770 * utils.c (printchar): Replace do_fputs and do_fprintf
9771 parameters by do_fputc.
9772 (fputstr_filtered): Adjust call to printchar.
9773 (fputstr_unfiltered): Likewise.
9774 (fputstrn_filtered): Likewise.
9775 (fputstrn_unfiltered): Add do_fputc parameter, pass to
9777 * utils.h (do_fputc_ftype): New typedef.
9778 (fputstrn_unfiltered): Add do_fputc parameter.
9780 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9782 * regformats/i386/i386-avx.dat: Remove.
9784 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9787 * amd64-tdep.c (amd64_none_init_abi): New function.
9788 (amd64_x32_none_init_abi): New function.
9789 (_initialize_amd64_tdep): Register handlers for x86-64 and
9790 x64_32 with GDB_OSABI_NONE.
9791 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
9792 GDB_OSABI_NONE osabi.
9794 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9797 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
9799 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
9800 * osabi.c (gdb_osabi_names): Add "unknown" entry.
9802 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9804 * common/byte-vector.h (char_vector): New type.
9805 * target.h (target_read_alloc): Return
9806 gdb::optional<byte_vector>.
9807 (target_read_stralloc): Return gdb::optional<char_vector>.
9808 (target_get_osdata): Return gdb::optional<char_vector>.
9809 * target.c (target_read_alloc_1): Templatize. Replacement
9810 manual memory management with vector.
9811 (target_read_alloc): Change return type, adjust.
9812 (target_read_stralloc): Change return type, adjust.
9813 (target_get_osdata): Change return type, adjust.
9814 * auxv.c (struct auxv_info) <length>: Remove.
9815 <data>: Change type to gdb::optional<byte_vector>.
9816 (auxv_inferior_data_cleanup): Free auxv_info with delete.
9817 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
9818 (target_auxv_search): Adjust.
9819 (fprint_target_auxv): Adjust.
9820 * avr-tdep.c (avr_io_reg_read_command): Adjust.
9821 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
9822 (linux_make_corefile_notes): Adjust.
9823 * osdata.c (get_osdata): Adjust.
9824 * remote.c (remote_get_threads_with_qxfer): Adjust.
9825 (remote_memory_map): Adjust.
9826 (remote_traceframe_info): Adjust.
9827 (btrace_read_config): Adjust.
9828 (remote_read_btrace): Adjust.
9829 (remote_pid_to_exec_file): Adjust.
9830 * solib-aix.c (solib_aix_get_library_list): Adjust.
9831 * solib-dsbt.c (decode_loadmap): Don't free buf.
9832 (dsbt_get_initial_loadmaps): Adjust.
9833 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
9834 * solib-target.c (solib_target_current_sos): Adjust.
9835 * tracepoint.c (sdata_make_value): Adjust.
9836 * xml-support.c (xinclude_start_include): Adjust.
9837 (xml_fetch_content_from_file): Adjust.
9838 * xml-support.h (xml_fetch_another): Change return type.
9839 (xml_fetch_content_from_file): Change return type.
9840 * xml-syscall.c (xml_init_syscalls_info): Adjust.
9841 * xml-tdesc.c (file_read_description_xml): Adjust.
9842 (fetch_available_features_from_target): Change return type.
9843 (target_fetch_description_xml): Adjust.
9844 (target_read_description_xml): Adjust.
9846 2018-04-06 Tom Tromey <tom@tromey.com>
9848 * value.c (~value): Update.
9849 (struct value) <contents>: Now unique_xmalloc_ptr.
9850 (value_contents_bits_eq, allocate_value_contents)
9851 (value_contents_raw, value_contents_all_raw)
9852 (value_contents_for_printing, value_contents_for_printing_const)
9853 (set_value_enclosing_type): Update.
9855 2018-04-06 Tom Tromey <tom@tromey.com>
9857 * value.c (range_s): Remove typedef, VEC.
9858 (struct range): Add operator<.
9859 (range_lessthan): Remove.
9860 (ranges_contain): Change type.
9862 (struct value) <unavailable, optimized_out>: Now std::vector.
9863 (value_entirely_available)
9864 (value_entirely_covered_by_range_vector)
9865 (value_entirely_unavailable, value_entirely_optimized_out):
9867 (insert_into_bit_range_vector): Change argument type.
9868 (find_first_range_overlap): Likewise.
9869 (struct ranges_and_idx, value_contents_bits_eq)
9870 (require_not_optimized_out, require_available): Update.
9871 (ranges_copy_adjusted): Change argument types.
9872 (value_optimized_out, value_copy, value_fetch_lazy): Update.
9874 2018-04-06 Tom Tromey <tom@tromey.com>
9876 * value.c (~value): Update.
9877 (struct value) <parent>: Now a value_ref_ptr.
9878 (value_parent, set_value_parent, value_address, value_copy):
9881 2018-04-06 Tom Tromey <tom@tromey.com>
9883 * value.c (struct value): Add constructor, destructor, and member
9885 (allocate_value_lazy, value_decref): Update.
9887 2018-04-06 Tom Tromey <tom@tromey.com>
9889 * value.c (struct value) <released, next>: Remove.
9890 (all_values): Now a std::vector.
9891 (allocate_value_lazy): Update.
9892 (value_next): Remove.
9893 (value_mark, value_free_to_mark, release_value)
9894 (value_release_to_mark): Update.
9896 2018-04-06 Tom Tromey <tom@tromey.com>
9898 * value.h (fetch_subexp_value, value_release_to_mark): Update.
9899 (free_value_chain): Remove.
9900 * value.c (free_value_chain): Remove.
9901 (value_release_to_mark): Return a std::vector.
9902 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
9904 (check_condition): Update.
9905 * eval.c (fetch_subexp_value): Change "val_chain" to a
9907 * breakpoint.c (update_watchpoint): Update.
9908 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
9910 2018-04-06 Tom Tromey <tom@tromey.com>
9912 * value.h (free_all_values): Remove.
9913 * value.c (free_all_values): Remove.
9915 2018-04-06 Tom Tromey <tom@tromey.com>
9917 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
9918 (value_history_chain, value_history_count): Remove.
9919 (value_history): New global.
9920 (record_latest_value, access_value_history, show_values)
9921 (preserve_values): Update.
9923 2018-04-06 Tom Tromey <tom@tromey.com>
9925 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
9926 * varobj.c (varobj_set_display_format, varobj_set_value)
9927 (install_default_visualizer, construct_visualizer)
9928 (install_new_value, ~varobj, varobj_get_value_type)
9929 (my_value_of_variable, varobj_editable_p): Update.
9930 * c-varobj.c (c_describe_child, c_value_of_variable)
9931 (cplus_number_of_children, cplus_describe_child): Update.
9932 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
9933 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
9934 (ada_value_of_variable, ada_value_is_changeable_p): Update.
9936 2018-04-06 Tom Tromey <tom@tromey.com>
9938 * printcmd.c (last_examine_address): Change type to
9940 (do_examine, x_command): Update.
9942 2018-04-06 Tom Tromey <tom@tromey.com>
9944 * value.c (release_value): Update.
9945 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
9946 (struct bpstats) <val>: Now a value_ref_ptr.
9947 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
9948 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
9949 (~watchpoint, print_it_watchpoint, watch_command_1)
9950 (invalidate_bp_value_on_memory_change): Update.
9952 2018-04-06 Tom Tromey <tom@tromey.com>
9954 * varobj.c (varobj_clear_saved_item)
9955 (update_dynamic_varobj_children, install_new_value, ~varobj):
9957 * value.h (value_incref): Move declaration earlier.
9958 (value_decref): Rename from value_free.
9959 (struct value_ref_policy): New.
9960 (value_ref_ptr): New typedef.
9961 (struct value_deleter): Remove.
9962 (gdb_value_up): Remove typedef.
9963 (release_value): Change return type.
9964 (release_value_or_incref): Remove.
9965 * value.c (set_value_parent): Update.
9966 (value_incref): Change return type.
9967 (value_decref): Rename from value_free.
9968 (value_free_to_mark, free_all_values, free_value_chain): Update.
9969 (release_value): Return value_ref_ptr.
9970 (release_value_or_incref): Remove.
9971 (record_latest_value, set_internalvar, clear_internalvar):
9973 * stack.c (info_frame_command): Don't call value_free.
9974 * python/py-value.c (valpy_dealloc, valpy_new)
9975 (value_to_value_object): Update.
9976 * printcmd.c (do_examine): Update.
9977 * opencl-lang.c (lval_func_free_closure): Update.
9978 * mi/mi-main.c (register_changed_p): Don't call value_free.
9979 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
9980 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
9981 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
9983 * guile/scm-value.c (vlscm_free_value_smob)
9984 (vlscm_scm_from_value): Update.
9985 * frame.c (frame_register_unwind, frame_unwind_register_signed)
9986 (frame_unwind_register_unsigned, get_frame_register_bytes)
9987 (put_frame_register_bytes): Don't call value_free.
9988 * findvar.c (address_from_register): Don't call value_free.
9989 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
9990 * dwarf2loc.c (entry_data_value_free_closure)
9991 (value_of_dwarf_reg_entry, free_pieced_value_closure)
9992 (dwarf2_evaluate_loc_desc_full): Update.
9993 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
9994 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
9995 (~watchpoint, watch_command_1)
9996 (invalidate_bp_value_on_memory_change): Update.
9997 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
9999 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
10002 * warning.m4: Add -Wno-error=deprecated-register.
10003 * configure: Re-generate.
10005 2018-04-05 Tom Tromey <tom@tromey.com>
10007 * linespec.h: Remove include of "vec.h".
10009 2018-04-05 Tom Tromey <tom@tromey.com>
10011 * linespec.c (typep): Remove typedef.
10012 (find_methods, find_superclass_methods): Take a std::vector.
10013 (find_method): Use std::vector.
10015 2018-04-05 Tom Tromey <tom@tromey.com>
10017 * utils.c (compare_strings): Remove.
10018 * utils.h (compare_strings): Remove.
10019 * objc-lang.h (find_imps): Update.
10020 * objc-lang.c (find_methods): Take a std::vector.
10021 (uniquify_strings, find_imps): Likewise.
10022 * linespec.c (find_methods): Take a std::vector.
10023 (decode_objc): Use std::vector.
10024 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
10026 (find_method, find_function_symbols): Use std::vector.
10028 2018-04-05 Tom Tromey <tom@tromey.com>
10030 * completer.c (completion_tracker::completion_tracker): Remove
10032 (completion_tracker::discard_completions): Likewise.
10033 * breakpoint.c (ambiguous_names_p): Remove cast.
10034 * ada-lang.c (_initialize_ada_language): Remove cast.
10035 * utils.h (streq): Update.
10036 (streq_hash): Add new declaration.
10037 * utils.c (streq): Return bool.
10038 (streq_hash): New function.
10040 2018-04-05 Tom Tromey <tom@tromey.com>
10042 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
10043 Remove a string copy.
10045 2018-04-05 Tom Tromey <tom@tromey.com>
10047 * linespec.c (filter_results): Use std::vector.
10048 (decode_line_2, decode_line_full): Update.
10050 2018-04-05 Tom Tromey <tom@tromey.com>
10052 * linespec.c (canonical_to_fullform): Return std::string.
10053 (filter_results): Update.
10054 (struct decode_line_2_item): Add constructor.
10055 <fullform, displayform>: Now std::string.
10056 (decode_line_2_compare_items): Now a std::sort comparator.
10057 (decode_line_2): Update.
10059 2018-04-05 Tom Tromey <tom@tromey.com>
10061 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
10062 (unexpected_linespec_error): Update.
10063 (linespec_parse_basic, parse_linespec): Update.
10065 2018-04-05 Tom Tromey <tom@tromey.com>
10067 * linespec.c (linespec_parse_basic): Reindent.
10069 2018-04-05 Tom Tromey <tom@tromey.com>
10071 * minsyms.h (iterate_over_minimal_symbols): Update.
10072 * minsyms.c (iterate_over_minimal_symbols): Take a
10073 gdb::function_view.
10074 * linespec.c (struct collect_minsyms): Remove.
10075 (compare_msyms): Now a std::sort comparator.
10076 (add_minsym): Add parameters.
10077 (search_minsyms_for_name): Update. Use std::vector.
10079 2018-04-03 Tom Tromey <tom@tromey.com>
10081 * mipsread.c (read_alphacoff_dynamic_symtab): Use
10084 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10086 * MAINTAINERS (Write After Approval): Add Weimin Pan.
10088 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10091 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
10092 printing static type.
10094 2018-04-01 Tom Tromey <tom@tromey.com>
10096 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
10097 (rs6000_xfer_shared_libraries): Update.
10099 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
10101 * common/gdb_vecs.h (char_ptr): Remove.
10102 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
10104 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10106 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
10108 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
10110 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10112 * tracepoint.h (struct uploaded_tp): Initialize fields.
10113 <actions, step_actions, cmd_strings>: Change type to
10114 std::vector<char *>.
10115 * tracepoint.c (get_uploaded_tp): Allocate with new.
10116 (free_uploaded_tps): Free with delete.
10117 (parse_tracepoint_definition): Adjust to std::vector change.
10118 * breakpoint.c (read_uploaded_action): Likewise.
10119 (create_tracepoint_from_upload): Likewise.
10120 * ctf.c (ctf_write_uploaded_tp): Likewise.
10121 (SET_ARRAY_FIELD): Likewise.
10122 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
10124 2018-03-30 Tom Tromey <tom@tromey.com>
10126 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
10128 (svr4_keep_data_in_core): Update.
10129 (svr4_read_so_list): Update.
10131 2018-03-30 Tom Tromey <tom@tromey.com>
10133 * windows-nat.c (handle_output_debug_string, handle_exception):
10135 * target.h (target_read_string): Update.
10136 * target.c (target_read_string): Change "string" to
10137 unique_xmalloc_ptr.
10138 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
10140 * solib-frv.c (frv_current_sos): Update.
10141 * solib-dsbt.c (dsbt_current_sos): Update.
10142 * solib-darwin.c (darwin_current_sos): Update.
10143 * linux-thread-db.c (inferior_has_bug): Update.
10144 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
10145 Update. Remove alloca.
10146 * ada-lang.c (ada_main_name): Update.
10148 2018-03-30 Tom Tromey <tom@tromey.com>
10150 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
10151 (struct dwo_file_deleter): New.
10152 (dwo_file_up): New typedef.
10153 (open_and_init_dwo_file): Use dwo_file_up.
10154 (free_dwo_file_cleanup): Remove.
10156 2018-03-30 Tom Tromey <tom@tromey.com>
10158 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
10159 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
10161 2018-03-30 Tom Tromey <tom@tromey.com>
10163 * dwarf2read.c (class free_cached_comp_units): New class.
10164 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
10165 (free_cached_comp_units): Remove function.
10167 2018-03-30 Tom Tromey <tom@tromey.com>
10169 * utils.h (make_cleanup_unpush_target): Remove.
10170 * inf-ptrace.c (struct target_unpusher): New.
10171 (target_unpush_up) New typedef.
10172 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
10174 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
10176 2018-03-27 Tom Tromey <tom@tromey.com>
10178 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
10180 2018-03-27 Pedro Alves <palves@redhat.com>
10181 Tom Tromey <tom@tromey.com>
10183 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
10184 destructor. Now a class.
10185 (gdb_readline_wrapper_cleanup): Remove function.
10186 (gdb_readline_wrapper): Remove cleanups.
10188 2018-03-27 Tom Tromey <tom@tromey.com>
10190 * typeprint.h (struct type_print_options) <local_typedefs,
10191 global_typedefs>: Remove "struct" keyword.
10192 (class typedef_hash_table): New class.
10193 (recursively_update_typedef_hash, add_template_parameters)
10194 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
10195 (find_typedef_in_hash): Don't declare.
10196 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
10197 (typedef_hash_table::recursively_update): Rename from
10198 recursively_update_typedef_hash. Now a member.
10199 (typedef_hash_table::add_template_parameters): Rename from
10200 add_template_parameters. Now a member.
10201 (typedef_hash_table::typedef_hash_table): Now a constructor;
10202 rename from create_typedef_hash.
10203 (typedef_hash_table::~typedef_hash_table): Now a destructor;
10204 rename from free_typedef_hash.
10205 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
10206 (do_free_global_table): Remove.
10207 (typedef_hash_table::typedef_hash_table): New constructor; renamed
10208 from copy_type_recursive.
10209 (create_global_typedef_table): Remove.
10210 (typedef_hash_table::find_global_typedef): Now a member of
10211 typedef_hash_table.
10212 (typedef_hash_table::find_typedef): Rename from
10213 find_typedef_in_hash; now a member.
10214 (whatis_exp): Update.
10215 * extension.h (struct ext_lang_type_printers): Add constructor and
10217 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
10219 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
10220 Now a constructor; rename from start_ext_lang_type_printers.
10221 (ext_lang_type_printers): Now a destructor; rename from
10222 free_ext_lang_type_printers.
10223 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
10225 (c_type_print_base_struct_union): Update. Remove cleanups.
10227 2018-03-27 Tom Tromey <tom@tromey.com>
10229 * dwarf-index-write.c: Include <cmath>.
10231 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10233 * NEWS: Add entry describing new "set|show varsize-limit" command.
10234 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
10236 * printcmd.c (_initialize_printcmd): Add "set var" alias of
10239 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
10241 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
10242 dwarf-index-write.c
10243 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
10244 * dwarf-index-common.c: New file.
10245 * dwarf-index-common.h: New file.
10246 * dwarf-index-write.c: New file.
10247 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
10248 (struct dwarf2_section_info): Move from here.
10249 (dwarf2_section_info_def): Likewise.
10250 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
10251 (offset_type): Likewise.
10252 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
10253 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
10254 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
10255 (byte_swap): Likewise.
10256 (MAYBE_SWAP): Likewise.
10257 (dwarf2_per_cu_ptr): Likewise.
10258 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
10259 (struct tu_stats): Likewise.
10260 (struct dwarf2_per_objfile): Likewise.
10261 (struct dwarf2_per_cu_data): Likewise.
10262 (struct signatured_type): Likewise.
10263 (sig_type_ptr): Likewise.
10264 (DEF_VEC_P (sig_type_ptr)): Likewise.
10265 (INDEX4_SUFFIX): Likewise.
10266 (INDEX5_SUFFIX): Likewise.
10267 (DEBUG_STR_SUFFIX): Likewise.
10268 (dwarf2_read_section): Make non-static.
10269 (mapped_index_string_hash): Move from here.
10270 (dwarf5_djb_hash): Likewise.
10271 (file_write): Likewise.
10272 (class data_buf): Likewise.
10273 (struct symtab_index_entry): Likewise.
10274 (struct mapped_symtab): Likewise.
10275 (find_slot): Likewise.
10276 (hash_expand): Likewise.
10277 (add_index_entry): Likewise.
10278 (uniquify_cu_indices): Likewise.
10279 (class c_str_view): Likewise.
10280 (class c_str_view_hasher): Likewise.
10281 (class vector_hasher): Likewise.
10282 (write_hash_table): Likewise.
10283 (psym_index_map): Likewise.
10284 (struct addrmap_index_data): Likewise.
10285 (add_address_entry): Likewise.
10286 (add_address_entry_worker): Likewise.
10287 (write_address_map): Likewise.
10288 (symbol_kind): Likewise.
10289 (write_psymbols): Likewise.
10290 (struct signatured_type_index_data): Likewise.
10291 (write_one_signatured_type): Likewise.
10292 (recursively_count_psymbols): Likewise.
10293 (recursively_write_psymbols): Likewise.
10294 (class debug_names): Likewise.
10295 (check_dwarf64_offsets): Likewise.
10296 (psyms_seen_size): Likewise.
10297 (write_gdbindex): Likewise.
10298 (write_debug_names): Likewise.
10299 (assert_file_size): Likewise.
10300 (write_psymtabs_to_index): Likewise.
10301 (save_gdb_index_command): Likewise.
10302 (_initialize_dwarf2_read): Don't register the "save gdb-index"
10304 * dwarf2read.h: New file.
10306 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10309 * dwarf2read.c (dwarf2_physname): Do not return the demangled
10310 symbol name if the CU's language stores symbol names in linkage
10312 * language.h (struct language_defn)
10313 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
10314 all instances of this struct.
10316 2018-03-26 Tom Tromey <tom@tromey.com>
10318 * stack.c (backtrace_command_1): Remove verbose code.
10320 2018-03-26 Tom Tromey <tom@tromey.com>
10322 * python/py-framefilter.c (py_print_type): Don't catch
10323 exceptions. Return void.
10324 (py_print_value): Likewise.
10325 (py_print_single_arg): Likewise.
10326 (enumerate_args): Don't catch exceptions.
10327 (py_print_args): Likewise.
10328 (py_print_frame): Likewise.
10329 (gdbpy_apply_frame_filter): Catch exceptions here.
10331 2018-03-26 Tom Tromey <tom@tromey.com>
10333 * stack.c (_initialize_stack): Remove trailing newlines from help
10334 text. Add "Usage" line to "backtrace" help.
10336 2018-03-26 Tom Tromey <tom@tromey.com>
10339 * python/py-framefilter.c (py_print_args): Call wrap_hint.
10341 2018-03-26 Tom Tromey <tom@tromey.com>
10343 * python/py-framefilter.c (py_print_single_arg): Return
10344 EXT_LANG_BT_ERROR from catch.
10346 2018-03-26 Tom Tromey <tom@tromey.com>
10348 PR backtrace/15584:
10349 * stack.c (backtrace_command_1): Move some code into no-filters
10352 2018-03-26 Tom Tromey <tom@tromey.com>
10354 * python/py-framefilter.c (throw_quit_or_print_exception): New
10356 (gdbpy_apply_frame_filter): Use it.
10358 2018-03-26 Tom Tromey <tom@tromey.com>
10361 * python/py-framefilter.c (py_print_type, py_print_value)
10362 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
10365 2018-03-26 Tom Tromey <tom@tromey.com>
10367 * python/py-framefilter.c (enumerate_args): Use
10368 gdb::unique_xmalloc_ptr.
10370 2018-03-26 Tom Tromey <tom@tromey.com>
10372 * python/py-framefilter.c (py_print_frame): Return
10374 (gdbpy_apply_frame_filter): Update comment.
10375 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
10377 <EXT_LANG_BT_NO_FILTERS>: Change value.
10379 2018-03-26 Tom Tromey <tom@tromey.com>
10381 PR backtrace/15582:
10382 * stack.c (backtrace_command): Parse "hide" argument.
10383 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
10384 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
10387 2018-03-26 Tom Tromey <tom@tromey.com>
10389 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
10391 (backtrace_command): Remove "fulltrace", add "flags".
10393 2018-03-26 Tom Tromey <tom@tromey.com>
10395 * stack.c (backtrace_command): Rewrite command line parsing.
10397 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10399 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
10401 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10403 * filename-seen-cache.h: Add include guard.
10405 2018-03-26 Keith Seitz <keiths@redhat.com>
10407 * symfile.c (place_section): Remove "struct" from section_addr_info
10409 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
10410 "struct" keyword from section_addr_info.
10412 2018-03-26 Alan Hayward <alan.hayward@arm.com>
10414 * regformats/regdef.h (reg): Add constructors.
10416 2018-03-25 Pedro Alves <palves@redhat.com>
10418 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
10419 if then/else bodies in var_func_name extraction.
10421 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
10423 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
10424 lookup_minimal_symbol() to find symbol entry.
10425 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
10427 2018-03-23 Keith Seitz <keiths@redhat.com>
10430 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
10431 nested type definitions for C++, too.
10433 2018-03-23 Tom Tromey <tom@tromey.com>
10435 * machoread.c (struct oso_el): Add a constructor. Don't define as
10437 (macho_register_oso): Remove.
10438 (macho_symtab_read): Take a std::vector.
10439 (oso_el_compare_name): Now a std::sort comparator.
10440 (macho_symfile_read_all_oso): Take a std::vector.
10441 (macho_symfile_read): Use std::vector. Remove cleanups.
10443 2018-03-22 Tom Tromey <tom@tromey.com>
10445 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
10446 (record_full_goto_bookmark): Use std::string.
10448 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10451 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
10454 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10456 * rs6000-tdep.c (store_insn_p): New function.
10457 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
10458 and cr_reg to their unshifted values. Use store_insn_p to
10459 match LR saves using either R1 or fdata->alloca_reg. Use
10460 store_insn_p to match CR saves. Set alloca_reg_offset
10461 when alloca_reg and framep are set. Remove lr_reg shift
10462 when assigning to fdata->lr_register.
10464 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
10466 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
10467 command line args instead of emitting a warning.
10469 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10471 * tracepoint.h (struct static_tracepoint_marker): Initialize
10472 fields, define default constructor, move constructor and move
10473 assignment, disable the rest.
10474 <str_id, extra>: Make std::string.
10475 (release_static_tracepoint_marker): Remove.
10476 (free_current_marker): Remove.
10477 * tracepoint.c (free_current_marker): Remove.
10478 (parse_static_tracepoint_marker_definition): Adjust to
10479 std::string, use new hex2str overload.
10480 (release_static_tracepoint_marker): Remove.
10481 (print_one_static_tracepoint_marker): Get marker by reference
10482 and adjust to std::string.
10483 (info_static_tracepoint_markers_command): Adjust to std::vector
10485 * target.h (static_tracepoint_marker_p): Remove typedef.
10486 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
10487 (struct target_ops) <to_static_tracepoint_marker_at>: Return
10489 <to_static_tracepoint_markers_by_strid>: Return std::vector.
10491 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
10492 (target_debug_print_std_vector_static_tracepoint_marker): New.
10493 (target_debug_print_struct_static_tracepoint_marker_p): Rename
10495 (target_debug_print_static_tracepoint_marker_p): ... this.
10496 * target-delegates.c: Re-generate.
10497 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
10499 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
10500 (decode_static_tracepoint_spec): Adjust to std::vector.
10501 (tracepoint_print_one_detail): Adjust to std::string.
10502 (strace_marker_decode_location): Adjust to std::string.
10503 (update_static_tracepoint): Adjust to std::string, remove call
10504 to release_static_tracepoint_marker.
10505 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
10506 Adjust to std::vector.
10507 * remote.c (remote_static_tracepoint_marker_at): Return bool.
10508 (remote_static_tracepoint_markers_by_strid): Adjust to
10510 * common/rsp-low.h (hex2str): New overload with explicit count
10512 * common/rsp-low.c (hex2str): New overload with explicit count
10514 * unittests/rsp-low-selftests.c (test_hex2str): New function.
10515 (_initialize_rsp_low_selftests): Add test_hex2str test.
10516 * unittests/tracepoint-selftests.c
10517 (test_parse_static_tracepoint_marker_definition): Adjust to
10520 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10522 * tracepoint.c (parse_static_tracepoint_marker_definition):
10523 Consider case where the definition is followed by more
10525 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10526 tracepoint-selftests.c.
10527 * unittests/tracepoint-selftests.c: New.
10529 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10531 * MAINTAINERS (Write After Approval): Add Pedro Franco de
10534 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10536 * symtab.c (find_pc_sect_line): fixed indentation.
10538 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10540 * symtab.c (find_pc_sect_line): now uses binary search.
10542 2018-03-19 Tom Tromey <tom@tromey.com>
10544 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
10545 "IDENT" production.
10547 2018-03-19 Pedro Alves <palves@redhat.com>
10548 Tom Tromey <tom@tromey.com>
10550 * unittests/observable-selftests.c: New file.
10551 * common/observable.h: New file.
10552 * observable.h: New file.
10553 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
10554 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
10555 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
10556 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
10557 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
10558 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
10559 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
10560 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
10561 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
10562 python/py-breakpoint.c, python/py-finishbreakpoint.c,
10563 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
10564 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
10565 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
10566 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
10567 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
10568 tui/tui-interp.c, valops.c: Update all users.
10569 * tui/tui-hooks.c (tui_bp_created_observer)
10570 (tui_bp_deleted_observer, tui_bp_modified_observer)
10571 (tui_inferior_exit_observer, tui_before_prompt_observer)
10572 (tui_normal_stop_observer, tui_register_changed_observer):
10574 (tui_observers_token): New global.
10575 (attach_or_detach, tui_attach_detach_observers): New functions.
10576 (tui_install_hooks, tui_remove_hooks): Use
10577 tui_attach_detach_observers.
10578 * record-btrace.c (record_btrace_thread_observer): Remove.
10579 (record_btrace_thread_observer_token): New global.
10580 * observer.sh: Remove.
10581 * observer.c: Rename to observable.c.
10582 * observable.c (namespace gdb_observers): Define new objects.
10583 (observer_debug): Move into gdb_observers namespace.
10584 (struct observer, struct observer_list, xalloc_observer_list_node)
10585 (xfree_observer_list_node, generic_observer_attach)
10586 (generic_observer_detach, generic_observer_notify): Remove.
10587 (_initialize_observer): Update.
10588 Don't include observer.inc.
10589 * Makefile.in (generated_files): Remove observer.h, observer.inc.
10590 (clean mostlyclean): Likewise.
10591 (observer.h, observer.inc): Remove targets.
10592 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
10593 (COMMON_SFILES): Use observable.c, not observer.c.
10594 * .gitignore: Remove observer.h.
10596 2018-03-18 Tom Tromey <tom@tromey.com>
10598 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
10600 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
10602 2018-03-17 Tom Tromey <tom@tromey.com>
10604 * auto-load.c (auto_load_objfile_script_1): Use std::string.
10606 2018-03-17 Tom Tromey <tom@tromey.com>
10608 * target.c (class scoped_target_fd): New.
10609 (target_fileio_close_cleanup): Remove.
10610 (target_fileio_read_alloc_1): Use scoped_target_fd.
10612 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
10614 * silent-rules.mk: New.
10615 * Makefile.in: Include silent-rules.mk
10616 (srcdir, VPATH, top_srcdir): Move up.
10617 (COMPILE): Add ECHO_CXX.
10618 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
10619 (init.c): Add ECHO_INIT_C.
10620 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
10621 (version.c): Add ECHO_GEN.
10622 (printcmd.o): Add ECHO_CXX.
10623 (target-float.o): Add ECHO_CXX.
10624 (ada-exp.o): Add ECHO_CXX.
10625 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
10626 (insight$(EXEEXT)): Add ECHO_CXXLD.
10627 * gnulib/configure.ac: Add AM_SILENT_RULES.
10628 * gnulib/aclocal.m4: Re-generate.
10629 * gnulib/configure: Re-generate.
10630 * gnulib/import/Makefile.in: Re-generate.
10632 2018-03-16 Tom Tromey <tom@tromey.com>
10634 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
10635 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
10636 * utils.c (do_free_section_addr_info)
10637 (make_cleanup_free_section_addr_info): Remove.
10638 * symfile.h (struct other_sections): Add constructor.
10639 (struct section_addr_info): Remove.
10640 (section_addr_info): New typedef.
10641 (struct sym_fns) <sym_offsets>: Change type of parameter.
10642 (build_section_addr_info_from_objfile)
10643 (relative_addr_info_to_section_offsets, addr_info_make_relative)
10644 (default_symfile_offsets, symbol_file_add)
10645 (symbol_file_add_from_bfd)
10646 (build_section_addr_info_from_section_table): Update.
10647 (alloc_section_addr_info, free_section_addr_info): Don't declare.
10648 * symfile.c (alloc_section_addr_info): Remove.
10649 (build_section_addr_info_from_section_table): Change return type.
10651 (build_section_addr_info_from_bfd)
10652 (build_section_addr_info_from_objfile): Likewise.
10653 (free_section_addr_info): Remove.
10654 (relative_addr_info_to_section_offsets): Change type of "addrs".
10655 (addrs_section_compar): Now a std::sort comparator.
10656 (addrs_section_sort): Change return type.
10657 (addr_info_make_relative): Change type of "addrs". Update.
10658 (default_symfile_offsets, syms_from_objfile_1)
10659 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
10660 (symbol_file_add_separate): Update.
10661 (symbol_file_add): Change type of "addrs". Update.
10662 (add_symbol_file_command): Update. Remove cleanups.
10663 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
10665 * symfile-debug.c (debug_sym_offsets): Change type of "info".
10666 * solib.c (solib_read_symbols): Update.
10667 * objfiles.c (objfile_relocate): Update. Remove cleanups.
10668 * machoread.c (macho_symfile_offsets): Update.
10669 * jit.c (jit_bfd_try_read_symtab): Update.
10671 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
10673 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10674 unittests/utils-selftests.c.
10675 * unittests/utils-selftests.c: New file.
10677 2018-03-14 Tom Tromey <tom@tromey.com>
10680 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
10683 2018-03-14 Tom Tromey <tom@tromey.com>
10686 * printcmd.c (printf_pointer): Allow "-" in format.
10688 2018-03-14 Tom Tromey <tom@tromey.com>
10690 * printcmd.c (_initialize_printcmd): Add usage to printf.
10692 2018-03-14 Yao Qi <qiyao@sourceware.org>
10694 * MAINTAINERS: Update my email address.
10696 2018-03-13 Tom Tromey <tom@tromey.com>
10698 * machoread.c (macho_check_dsym): Change filenamep to a
10700 (macho_symfile_read): Update.
10701 * symfile.c (load_command): Use std::string.
10703 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
10705 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
10706 to error message string.
10707 (riscv_register_name): Use xsnprintf instead of sprintf.
10708 (riscv_insn::fetch_instruction): Use gdb_assert instead of
10710 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
10712 (riscv_push_dummy_call): Likewise.
10714 2018-03-12 Tom Tromey <tom@tromey.com>
10716 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
10717 Use gdb::byte_vector.
10718 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
10720 2018-03-12 Yao Qi <yao.qi@linaro.org>
10722 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
10723 parameter type to readable_regcache.
10724 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
10727 2018-03-11 Tom Tromey <tom@tromey.com>
10729 * dwarf2read.c (struct nextfield): Add initializers.
10730 (struct nextfnfield): Remove.
10731 (struct fnfieldlist): Add initializers. Remove "length" and
10732 "head", use std::vector.
10733 (struct decl_field_list): Remove.
10734 (struct field_info): Add initializers.
10735 <fields, baseclasses>: Now std::vector.
10736 <nbaseclasses, nfnfields, typedef_field_list_count,
10737 nested_types_list_count>: Remove.
10738 (dwarf2_add_field, dwarf2_add_type_defn)
10739 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
10740 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
10741 (process_structure_scope): Update.
10743 2018-03-11 Tom Tromey <tom@tromey.com>
10745 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
10746 for use by std::sort.
10747 (build_type_psymtabs_1): Use std::vector.
10749 2018-03-09 Eli Zaretskii <eliz@gnu.org>
10751 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
10752 and LIBMPFR in the printed configuration.
10754 2018-03-08 Tom Tromey <tom@tromey.com>
10756 * source.c (get_filename_and_charpos): Use scoped_fd.
10757 * nto-procfs.c (procfs_open_1): Use scoped_fd.
10758 (procfs_pidlist): Likewise.
10759 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
10760 (iterate_over_mappings): Likewise.
10762 2018-03-08 Tom Tromey <tom@tromey.com>
10764 * infcall.c (struct call_return_meta_info)
10765 <stack_temporaries_enabled>: Remove.
10766 (get_call_return_value, call_function_by_hand_dummy): Update.
10767 * thread.c (disable_thread_stack_temporaries): Remove.
10768 (enable_thread_stack_temporaries): Remove.
10769 (thread_stack_temporaries_enabled_p): Return bool.
10770 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
10771 (get_last_thread_stack_temporary): Update.
10772 * eval.c (evaluate_subexp): Update.
10773 * gdbthread.h (class enable_thread_stack_temporaries): Now a
10774 class, not a function.
10775 (value_ptr, value_vec): Remove typedefs.
10776 (class thread_info) <stack_temporaries_enabled>: Now bool.
10777 <stack_temporaries>: Now a std::vector.
10778 (thread_stack_temporaries_enabled_p)
10779 (value_in_thread_stack_temporaries): Return bool.
10781 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
10783 * remote.c (putpkt_binary): Fix omitted bytes reporting.
10784 (getpkt_or_notif_sane_1): Likewise.
10786 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10788 * build-id.c (build_id_to_debug_bfd): Use std::string.
10790 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10792 * build-id.c (find_separate_debug_file_by_buildid): Return
10794 * build-id.h (find_separate_debug_file_by_buildid): Return
10796 * coffread.c (coff_symfile_read): Adjust to std::string.
10797 * elfread.c (elf_symfile_read): Adjust to std::string.
10798 * symfile.c (separate_debug_file_exists): Change parameter to
10800 (find_separate_debug_file): Return std::string.
10801 (find_separate_debug_file_by_debuglink): Return std::string.
10802 * symfile.h (find_separate_debug_file_by_debuglink): Return
10805 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10807 * common/xml-utils.c (xml_escape_text): Move code to...
10808 (xml_escape_text_append): ... this new function.
10809 * common/xml-utils.h (xml_escape_text_append): New declaration.
10810 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
10812 (_initialize_xml_utils): register test_xml_escape_text_append as
10815 2018-03-07 Alan Hayward <alan.hayward@arm.com>
10817 * defs.h: Remove MAX_REGISTER_SIZE.
10818 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
10820 * python/py-unwind.c (pyuw_sniffer): Likewise.
10822 2018-03-07 Tom Tromey <tom@tromey.com>
10824 * linux-tdep.c (linux_info_proc): Update.
10825 * target.h (struct target_ops) <to_fileio_readlink>: Return
10827 (target_fileio_readlink): Return optional<string>.
10828 * remote.c (remote_hostio_readlink): Return optional<string>.
10829 * inf-child.c (inf_child_fileio_readlink): Return
10831 * target.c (target_fileio_readlink): Return optional<string>.
10833 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
10835 * regcache.c (cooked_read_test): Add riscv to the list of
10836 architectures that have a save_reggroup.
10838 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
10840 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
10841 value is not a dynamic class object.
10843 2018-03-06 Tom Tromey <tom@tromey.com>
10845 * rust-exp.y: Formatting fixes.
10847 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10849 * riscv-tdep.c (riscv_register_name): Remove target description
10851 (riscv_gdbarch_init): Remove target description check.
10853 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10855 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
10857 * riscv-tdep.h: Likewise.
10859 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10861 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
10862 (riscv_pseudo_register_write): Delete.
10863 (riscv_gdbarch_init): Remove all use of pseudo registers.
10865 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10867 * record-btrace.c (btrace_print_lines): Replace cleanup
10868 parameter with RAII equivalents.
10869 (btrace_insn_history): Replace cleanup with RAII equivalents.
10870 * ui-out.h (make_cleanup_ui_out_list_begin_end,
10871 make_cleanup_ui_out_tuple_begin_end): Remove.
10872 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
10873 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
10874 make_cleanup_ui_out_list_begin_end): Remove.
10876 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10878 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
10879 parameter types to std::vector. Use bool.
10880 (record_btrace_wait): Replace VEC(tp_t) with
10881 std::vector<thread_info *>.
10882 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
10884 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10886 * record-btrace.c (record_btrace_disable_callback): Remove.
10887 (struct scoped_btrace_disable): New.
10888 (record_btrace_open): Use scoped_btrace_disable.
10890 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10892 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
10893 reading values from registers.
10895 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10897 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
10900 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10902 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
10903 change parameter type. Use GDB's print functions, and use
10904 core_addr_to_string where appropriate.
10905 (riscv_push_dummy_call): Use core_addr_to_string where
10906 appropriate, update call to riscv_print_arg_location, and reindent
10908 (riscv_return_value): Update call to riscv_print_arg_location.
10910 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10911 Tim Newsome <tim@sifive.com>
10912 Albert Ou <a0u@eecs.berkeley.edu>
10913 Darius Rad <darius@bluespec.com>
10915 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
10916 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
10917 (ALLDEPFILES): Add riscv-tdep.c
10918 * configure.tgt: Add riscv support.
10919 * riscv-tdep.c: New file.
10920 * riscv-tdep.h: New file.
10921 * NEWS: Mention new target.
10922 * MAINTAINERS: Add entry for riscv.
10924 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10926 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
10927 fields within aggregates.
10929 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
10931 * record-btrace.c (btrace_print_lines): Change type of flags to
10932 gdb_disassembly_flags.
10934 2018-03-04 John Baldwin <jhb@FreeBSD.org>
10936 * fbsd-nat.c: Include "inf-ptrace.h".
10937 (USE_SIGTRAP_SIGINFO): Conditionally define.
10938 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
10939 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
10940 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
10942 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
10944 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
10946 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
10947 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
10948 "supports_stopped_by_hw_breakpoint" target methods.
10950 2018-03-04 John Baldwin <jhb@FreeBSD.org>
10952 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
10953 * fbsd-nat.c (debug_fbsd_nat): New variable.
10954 (show_fbsd_nat_debug): New function.
10955 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
10956 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
10958 2018-03-04 John Baldwin <jhb@FreeBSD.org>
10960 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
10961 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
10963 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
10964 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
10967 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10969 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
10970 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
10972 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10974 * charset.c (struct charset_vector): New.
10975 (charsets): Change type to charset_vector.
10976 (find_charset_names): Adjust.
10978 (_initialize_charset): Adjust.
10980 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10982 * progspace.h (struct program_space) <deleted_solibs>: Change
10983 type to std::vector<std::string>.
10984 * progspace.c (clear_program_space_solib_cache): Adjust.
10985 * breakpoint.c (print_solib_event): Adjust.
10986 (check_status_catch_solib): Adjust.
10987 * solib.c (update_solib_list): Adjust.
10988 * ui-out.h (class ui_out) <field_string>: New overload.
10989 * ui-out.c (ui_out::field_string): New overload.
10991 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10993 * progspace.h (struct program_space): Add constructor and
10994 destructor, initialize fields.
10995 (add_program_space): Remove.
10996 * progspace.c (add_program_space): Rename to...
10997 (program_space::program_space): ... this.
10998 (release_program_space): Rename to...
10999 (program_space::~program_space): ... this.
11000 (delete_program_space): Use delete to delete program_space.
11001 (initialize_progspace): Use new to allocate program_space.
11002 * inferior.c (add_inferior_with_spaces): Likewise.
11003 (clone_inferior_command): Likewise.
11004 * infrun.c (follow_fork_inferior): Likewise.
11005 (handle_vfork_child_exec_or_exit): Likewise.
11007 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11009 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
11010 (delim_string_to_char_ptr_vec): Return std::vector of
11011 gdb::unique_xmalloc_ptr.
11012 (dirnames_to_char_ptr_vec_append): Take std::vector of
11013 gdb::unique_xmalloc_ptr.
11014 (dirnames_to_char_ptr_vec): Return std::vector of
11015 gdb::unique_xmalloc_ptr.
11016 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
11017 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
11018 (delim_string_to_char_ptr_vec): Return an std::vector of
11019 gdb::unique_xmalloc_ptr, adjust the code.
11020 (dirnames_to_char_ptr_vec_append): Take an std::vector of
11021 gdb::unique_xmalloc_ptr, adjust the code.
11022 (dirnames_to_char_ptr_vec): Return an std::vector of
11023 gdb::unique_xmalloc_ptr, adjust the code.
11024 * auto-load.c (auto_load_safe_path_vec): Change type to
11025 std::vector of gdb::unique_xmalloc_ptr.
11026 (auto_load_expand_dir_vars): Return an std::vector of
11027 gdb::unique_xmalloc_ptr, adjust the code.
11028 (auto_load_safe_path_vec_update): Adjust.
11029 (filename_is_in_auto_load_safe_path_vec): Adjust.
11030 (auto_load_objfile_script_1): Adjust.
11031 * build-id.c (build_id_to_debug_bfd): Adjust.
11032 * linux-thread-db.c (thread_db_load_search): Adjust.
11033 * source.c (add_path): Adjust.
11035 * symfile.c (find_separate_debug_file): Adjust.
11036 * utils.c (do_free_char_ptr_vec): Remove.
11037 (make_cleanup_free_char_ptr_vec): Remove.
11039 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
11042 * common/pathstuff.c: Conditionally include "<windows.h>".
11044 2018-03-01 Georg Sauthoff <mail@georg.so>
11047 * gcore.in: Quote variables and switch interpreter to bash.
11049 2018-03-01 Tom Tromey <tom@tromey.com>
11051 * dwarf2read.c (alloc_discriminant_info): Fix default_index
11052 assertion. Add assertion for discriminant_index.
11053 (quirk_rust_enum): Use correct base type name in univariant case.
11055 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
11057 * record.c (get_call_history_modifiers): Return a
11058 record_print_flags.
11059 (cmd_record_call_history): Adjust.
11060 * record-btrace.c (record_btrace_call_history): Adjust.
11061 (record_btrace_call_history_range): Adjust.
11062 (record_btrace_call_history_from): Adjust.
11063 * target-debug.h (target_debug_print_record_print_flags): New.
11064 * target-delegates.c: Re-generate.
11065 * target.c (target_call_history): Change flags type.
11066 (target_call_history_from): Likewise.
11067 (target_call_history_range): Likewise.
11068 * target.h (struct target_ops) <target_call_history>: Likewise.
11069 (target_call_history_from): Likewise.
11070 (target_call_history_range): Likewise.
11072 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11073 Simon Marchi <simon.marchi@polymtl.ca>
11075 * common/common-utils.c: Include "sys/stat.h".
11076 (is_regular_file): Move here from "source.c"; change return
11078 * common/common-utils.h (is_regular_file): New prototype.
11079 * common/pathstuff.c (contains_dir_separator): New function.
11080 * common/pathstuff.h (contains_dir_separator): New prototype.
11081 * source.c: Don't include "sys/stat.h".
11082 (is_regular_file): Move to "common/common-utils.c".
11084 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11086 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
11087 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
11088 * auto-load.c: Include "common/pathstuff.h".
11089 * common/common-def.h (current_directory): Move here.
11090 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
11092 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
11094 * common/pathstuff.c: New file.
11095 * common/pathstuff.h: New file.
11096 * compile/compile.c: Include "common/pathstuff.h".
11097 * defs.h (current_directory): Move to "common/common-defs.h".
11098 * dwarf2read.c: Include "common/pathstuff.h".
11099 * exec.c: Likewise.
11100 * guile/scm-safe-call.c: Likewise.
11101 * linux-thread-db.c: Likewise.
11102 * main.c: Likewise.
11103 * nto-tdep.c: Likewise.
11104 * objfiles.c: Likewise.
11105 * source.c: Likewise.
11106 * symtab.c: Likewise.
11107 * utils.c: Include "common/pathstuff.h".
11108 (gdb_realpath): Move to "common/pathstuff.c".
11109 (gdb_realpath_keepfile): Likewise.
11110 (gdb_abspath): Likewise.
11111 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
11112 (gdb_realpath_keepfile): Likewise.
11113 (gdb_abspath): Likewise.
11115 2018-02-28 John Baldwin <jhb@FreeBSD.org>
11117 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
11118 wildcard process pid for super_resume for kernels with a
11121 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
11123 * compile/compile.c (get_args): Add additional comments
11124 explaining function.
11126 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
11127 Tom Tromey <tom@tromey.com>
11129 * target.h (memory_write_request_s): Remove typedef. Don't define
11131 (target_write_memory_blocks): Change argument to std::vector.
11132 (struct memory_write_request): Add constructor.
11133 * target-memory.c (compare_block_starting_address): Return bool.
11134 Change argument types.
11135 (claim_memory): Change arguments to use std::vector.
11136 (split_regular_and_flash_blocks, blocks_to_erase)
11137 (compute_garbled_blocks): Likewise.
11138 (cleanup_request_data, cleanup_write_requests_vector): Remove.
11139 (target_write_memory_blocks): Change argument to std::vector.
11140 * symfile.c (struct load_section_data): Add constructor and
11141 destructor. Use std::vector for "requests".
11142 (struct load_progress_data): Add initializers.
11143 (load_section_callback): Update. Use "new".
11144 (clear_memory_write_data): Remove.
11145 (generic_load): Update.
11147 2018-02-27 Alan Hayward <alan.hayward@arm.com>
11149 * arch/aarch64.h: Use common/tdesc.h.
11151 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11153 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
11154 architecture with a 64-bit ABI.
11156 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11158 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
11159 ahead of target description loading.
11161 2018-02-26 Tom Tromey <tom@tromey.com>
11163 * stack.c (backtrace_command_1): Update.
11164 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
11166 * python/py-framefilter.c (py_print_frame)
11167 (gdbpy_apply_frame_filter): Change type of "flags".
11168 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
11170 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
11171 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
11172 * extension.h (enum frame_filter_flag): Rename from
11173 frame_filter_flags.
11174 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
11175 (apply_ext_lang_frame_filter): Change type of "flags".
11176 * extension.c (apply_ext_lang_frame_filter): Change type of
11178 * extension-priv.h (struct extension_language_ops)
11179 <apply_frame_filter>: Change type of "flags".
11181 2018-02-26 Tom Tromey <tom@tromey.com>
11184 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
11185 off-by-one in py_end computation.
11186 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
11188 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
11191 2018-02-26 Tom Tromey <tom@tromey.com>
11193 * dwarf2read.c (struct variant_field): New.
11194 (struct nextfield) <variant>: New field.
11195 (dwarf2_add_field): Handle DW_TAG_variant_part.
11196 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
11197 discriminated union.
11198 (read_structure_type): Handle DW_TAG_variant_part.
11199 (handle_struct_member_die): New function, extracted from
11200 process_structure_scope. Handle DW_TAG_variant.
11201 (process_structure_scope): Handle discriminated unions. Call
11202 handle_struct_member_die.
11204 2018-02-26 Tom Tromey <tom@tromey.com>
11206 * rust-lang.h (rust_last_path_segment): Declare.
11207 * rust-lang.c (rust_last_path_segment): Now public. Change
11209 (struct disr_info): Remove.
11210 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
11211 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
11212 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
11213 (rust_enum_p, rust_enum_variant): New function.
11214 (rust_underscore_fields): Remove "offset" parameter.
11215 (rust_print_enum): New function.
11216 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
11217 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
11218 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
11220 (rust_internal_print_type): New function, from rust_print_type.
11222 (rust_print_type): Call rust_internal_print_type.
11223 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
11224 Update enum handling.
11225 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
11226 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
11227 (rust_union_quirks): New functions.
11228 (process_full_comp_unit, process_full_type_unit): Call
11230 (process_structure_scope): Update rust_unions if necessary.
11232 2018-02-26 Tom Tromey <tom@tromey.com>
11234 * value.h (value_union_variant): Declare.
11235 * valops.c (value_union_variant): New function.
11236 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
11237 (struct discriminant_info): New.
11238 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
11240 (struct main_type) <flag_discriminated_union>: New field.
11242 2018-02-26 Tom Tromey <tom@tromey.com>
11244 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11245 unittests/unpack-selftests.c.
11246 * unittests/unpack-selftests.c: New file.
11247 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
11249 2018-02-26 Yao Qi <yao.qi@linaro.org>
11251 * dwarf2read.c (struct partial_die_info) <read>: New method.
11252 (read_partial_die): Remove the declaration.
11253 (load_partial_dies): Update.
11254 (partial_die_info::partial_die_info):
11255 (read_partial_die): Change it to partial_die_info::read.
11257 2018-02-26 Yao Qi <yao.qi@linaro.org>
11259 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
11260 (fixup_partial_die): Remove declaration.
11261 (scan_partial_symbols): Update.
11262 (partial_die_parent_scope): Likewise.
11263 (partial_die_full_name): Likewise.
11264 (fixup_partial_die): Change it to partial_die_info::fixup.
11266 2018-02-26 Yao Qi <yao.qi@linaro.org>
11268 * dwarf2read.c (read_partial_die): Update the declaration.
11269 (load_partial_dies): Caller update.
11270 (read_partial_die): Remove one argument abbrev_len.
11272 2018-02-26 Yao Qi <yao.qi@linaro.org>
11274 * dwarf2read.c (struct partial_die_info): Add ctor, delete
11275 assignment operator.
11276 (load_partial_dies): Use ctor and copy ctor.
11277 (read_partial_die): Update.
11278 (dwarf2_cu::find_partial_die): Use ctor.
11280 2018-02-26 Yao Qi <yao.qi@linaro.org>
11282 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
11283 (find_partial_die_in_comp_unit): Change it to
11284 dwarf2_cu::find_partial_die.
11285 (find_partial_die): Update.
11287 2018-02-26 Yao Qi <yao.qi@linaro.org>
11289 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
11292 2018-02-26 Yao Qi <yao.qi@linaro.org>
11294 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
11296 2018-02-26 Alan Hayward <alan.hayward@arm.com>
11298 * arch/amd64.h: Use common/tdesc.h.
11299 * arch/i386.c: Likewise.
11300 * arch/i386.h: Likewise.
11301 * arch/tic6x.c: Likewise.
11302 * arch/tdesc.h: Move file from here...
11303 * common/tdesc.h: ...to here.
11304 * features/aarch64-core.c: Regenerate.
11305 * features/aarch64-fpu.c: Regenerate.
11306 * features/i386/32bit-avx.c: Regenerate.
11307 * features/i386/32bit-avx512.c: Regenerate.
11308 * features/i386/32bit-core.c: Regenerate.
11309 * features/i386/32bit-linux.c: Regenerate.
11310 * features/i386/32bit-mpx.c: Regenerate.
11311 * features/i386/32bit-pkeys.c: Regenerate.
11312 * features/i386/32bit-sse.c: Regenerate.
11313 * features/i386/64bit-avx.c: Regenerate.
11314 * features/i386/64bit-avx512.c: Regenerate.
11315 * features/i386/64bit-core.c: Regenerate.
11316 * features/i386/64bit-linux.c: Regenerate.
11317 * features/i386/64bit-mpx.c: Regenerate.
11318 * features/i386/64bit-pkeys.c: Regenerate.
11319 * features/i386/64bit-segments.c: Regenerate.
11320 * features/i386/64bit-sse.c: Regenerate.
11321 * features/i386/x32-core.c: Regenerate.
11322 * features/tic6x-c6xp.c: Regenerate.
11323 * features/tic6x-core.c: Regenerate.
11324 * features/tic6x-gp.c: Regenerate.
11325 * target-descriptions.c: Use common/tdesc.h.
11326 * target-descriptions.h: Likewise.
11328 2018-02-24 Tom Tromey <tom@tromey.com>
11330 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
11331 (try_thread_db_load_from_dir, thread_db_load_search): Use
11333 (info_auto_load_libthread_db_compare): Return bool. Change
11335 (info_auto_load_libthread_db): Use std::vector, std::string.
11338 2018-02-24 Tom Tromey <tom@tromey.com>
11340 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
11342 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
11344 * gdbarch.c: Rebuild.
11345 * gdbarch.h: Rebuild.
11346 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
11347 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
11348 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
11351 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
11353 * gdbtypes.h (sect_offset): Change type to uint64_t.
11354 (sect_offset_str): New function.
11355 * dwarf2read.c (create_addrmap_from_aranges): Use
11357 (error_check_comp_unit_head): Likewise.
11358 (create_debug_type_hash_table): Likewise.
11359 (read_cutu_die_from_dwo): Likewise.
11360 (init_cutu_and_read_dies): Likewise.
11361 (init_cutu_and_read_dies_no_follow): Likewise.
11362 (process_psymtab_comp_unit_reader): Likewise.
11363 (partial_die_parent_scope): Likewise.
11364 (peek_die_abbrev): Likewise.
11365 (process_queue): Likewise.
11366 (dwarf2_physname): Likewise.
11367 (read_namespace_alias): Likewise.
11368 (read_import_statement): Likewise.
11369 (create_dwo_cu_reader): Likewise.
11370 (create_cus_hash_table): Likewise.
11371 (lookup_dwo_cutu): Likewise.
11372 (inherit_abstract_dies): Likewise.
11373 (read_func_scope): Likewise.
11374 (read_call_site_scope): Likewise.
11375 (dwarf2_add_member_fn): Likewise.
11376 (read_common_block): Likewise.
11377 (read_module_type): Likewise.
11378 (read_typedef): Likewise.
11379 (read_subrange_type): Likewise.
11380 (load_partial_dies): Likewise.
11381 (read_partial_die): Likewise.
11382 (find_partial_die): Likewise.
11383 (read_str_index): Likewise.
11384 (dwarf2_string_attr): Likewise.
11385 (build_error_marker_type): Likewise.
11386 (lookup_die_type): Likewise.
11387 (dump_die_shallow): Likewise.
11388 (follow_die_ref): Likewise.
11389 (dwarf2_fetch_die_loc_sect_off): Likewise.
11390 (dwarf2_fetch_constant_bytes): Likewise.
11391 (follow_die_sig): Likewise.
11392 (get_signatured_type): Likewise.
11393 (get_DW_AT_signature_type): Likewise.
11394 (dwarf2_find_containing_comp_unit): Likewise.
11395 (set_die_type): Likewise.
11397 2018-02-21 John Baldwin <jhb@FreeBSD.org>
11399 * arch/aarch64.c: Include "common-defs.h".
11400 * arch/amd64.c: Likewise.
11401 * arch/i386.c: Likewise.
11403 2018-02-21 Tom Tromey <tom@tromey.com>
11405 * value.h: (extract_field_op): Update.
11406 * eval.c (extract_field_op): Return a const char *.
11407 * expression.h (parse_expression_for_completion): Update.
11408 * completer.c (complete_expression): Update.
11409 (add_struct_fields): Make fieldname const.
11410 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
11411 (mark_completion_tag, parse_exp_in_context_1): Update.
11412 (parse_expression_for_completion): Change "name" to
11413 unique_xmalloc_ptr*.
11415 2018-02-21 Tom Tromey <tom@tromey.com>
11417 * infcall.c (call_function_by_hand_dummy): Use std::vector.
11419 2018-02-21 Yao Qi <yao.qi@linaro.org>
11421 * avr-tdep.c (avr_read_pc): Change parameter type to
11423 * gdbarch.sh (read_pc): Likewise.
11424 * gdbarch.c: Re-generated.
11425 * gdbarch.h: Re-generated.
11426 * hppa-tdep.c (hppa_read_pc): Change parameter type to
11428 * ia64-tdep.c (ia64_read_pc): Likewise.
11429 * mips-tdep.c (mips_read_pc): Likewise.
11430 * spu-tdep.c (spu_read_pc): Likewise.
11432 2018-02-21 Yao Qi <yao.qi@linaro.org>
11434 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
11435 * regcache-dump.c: New file.
11436 * regcache.c: Move register_dump to regcache-dump.c.
11437 (maintenance_print_registers): Likewise.
11438 (maintenance_print_raw_registers): Likewise.
11439 (maintenance_print_cooked_registers): Likewise.
11440 (maintenance_print_register_groups): Likewise.
11441 (maintenance_print_remote_registers): Likewise.
11442 (_initialize_regcache): Likewise.
11443 * regcache.h (register_dump): Moved from regcache.c.
11445 2018-02-21 Yao Qi <yao.qi@linaro.org>
11447 * regcache.c (regcache::regcache): Update.
11448 (regcache::invalidate): Move it to detached_regcache::invalidate.
11449 (get_thread_arch_aspace_regcache): Update.
11450 (regcache::raw_update): Update.
11451 (regcache::cooked_read): Remove some code.
11452 (regcache::cooked_read_value): Likewise.
11453 (regcache::raw_write): Remove assert on m_readonly_p.
11454 (regcache::raw_supply_integer): Move it to
11455 detached_regcache::raw_supply_integer.
11456 (regcache::raw_supply_zeroed): Likewise.
11457 * regcache.h (detached_regcache) <raw_supply_integer>: New
11459 <raw_supply_zeroed, invalidate>: Likewise.
11460 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
11461 <invalidate>: Likewise.
11462 <m_readonly_p>: Removed.
11464 2018-02-21 Yao Qi <yao.qi@linaro.org>
11466 * infcmd.c (get_return_value): Let stop_regs point to
11467 get_current_regcache.
11468 * regcache.c (regcache::regcache): Remove.
11469 (register_dump_reg_buffer): New class.
11470 (regcache_print): Adjust.
11471 * regcache.h (regcache): Remove constructors.
11473 2018-02-21 Yao Qi <yao.qi@linaro.org>
11475 * regcache.c (class register_dump): New class.
11476 (register_dump_regcache, register_dump_none): New class.
11477 (register_dump_remote, register_dump_groups): New class.
11478 (regcache_print): Update.
11479 * regcache.h (regcache_dump_what): Move it to regcache.c.
11480 (regcache) <dump>: Remove.
11482 2018-02-21 Yao Qi <yao.qi@linaro.org>
11484 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
11486 (jit_unwind_reg_set_impl): Call raw_supply.
11487 (jit_frame_sniffer): Use reg_buffer_rw.
11488 * record-full.c (record_full_core_regbuf): Change its type.
11489 (record_full_core_open_1): Use reg_buffer_rw.
11490 (record_full_close): Likewise.
11491 (record_full_core_fetch_registers): Use regcache->raw_supply.
11492 (record_full_core_store_registers): Likewise.
11493 * regcache.c (regcache::get_register_status): Move it to
11495 (regcache_raw_set_cached_value): Remove.
11496 (regcache::raw_set_cached_value): Remove.
11497 (regcache::raw_write): Call raw_supply.
11498 (regcache::raw_supply): Move it to reg_buffer_rw.
11499 * regcache.h (regcache_raw_set_cached_value): Remove.
11500 (reg_buffer_rw): New class.
11502 2018-02-21 Yao Qi <yao.qi@linaro.org>
11504 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
11505 readonly_detached_regcache.
11506 (dummy_frame_prev_register): Use regcache->cooked_read.
11507 * frame.c (frame_save_as_regcache): Change return type.
11508 (frame_pop): Update.
11509 * frame.h (frame_save_as_regcache): Update declaration.
11510 * inferior.h (get_infcall_suspend_state_regcache): Update
11512 * infrun.c (infcall_suspend_state) <registers>: use
11513 readonly_detached_regcache.
11514 (save_infcall_suspend_state): Don't use regcache_dup.
11515 (get_infcall_suspend_state_regcache): Change return type.
11516 * linux-fork.c (struct fork_info) <savedregs>: Change to
11517 readonly_detached_regcache.
11519 (fork_save_infrun_state): Don't use regcache_dup.
11520 (info_checkpoints_command): Adjust.
11521 * mi/mi-main.c (register_changed_p): Update declaration.
11522 (mi_cmd_data_list_changed_registers): Use
11523 readonly_detached_regcache.
11524 (register_changed_p): Change parameter type to
11525 readonly_detached_regcache.
11526 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
11527 readonly_detached_regcache.
11528 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
11529 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
11531 (regcache::save): Move it to reg_buffer.
11532 (regcache::restore): Change parameter type.
11533 (regcache_dup): Remove.
11534 * regcache.h (reg_buffer) <save>: New method.
11535 (readonly_detached_regcache): New class.
11536 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
11537 readonly_detached_regcache.
11538 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
11540 2018-02-21 Yao Qi <yao.qi@linaro.org>
11542 * frame.c (frame_save_as_regcache): Use regcache method save.
11543 (frame_pop): Use regcache method restore.
11544 * infrun.c (restore_infcall_suspend_state): Likewise.
11545 * linux-fork.c (fork_load_infrun_state): Likewise.
11546 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
11548 * regcache.c (regcache_save): Remove.
11549 (regcache::restore): More asserts.
11550 (regcache_cpy): Remove.
11551 * regcache.h (regcache_save): Remove the declaration.
11552 (regcache::restore): Move from private to public.
11553 Remove the friend declaration of regcache_cpy.
11554 (regcache_cpy): Remove declaration.
11556 2018-02-21 Yao Qi <yao.qi@linaro.org>
11558 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
11559 parameter type to 'readable_regcache *'.
11560 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
11561 * arm-tdep.c (arm_neon_quad_read): Likewise.
11562 (arm_pseudo_read): Likewise.
11563 * avr-tdep.c (avr_pseudo_register_read): Likewise.
11564 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
11565 * frv-tdep.c (frv_pseudo_register_read): Likewise.
11566 * gdbarch.c: Re-generated.
11567 * gdbarch.h: Re-generated.
11568 * gdbarch.sh (pseudo_register_read): Change parameter type to
11569 'readable_regcache *'.
11570 (pseudo_register_read_value): Likewise.
11571 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
11572 (h8300_pseudo_register_read): Likewise.
11573 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
11574 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
11575 (i386_pseudo_register_read_into_value): Likewise.
11576 (i386_pseudo_register_read_value): Likewise.
11577 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
11579 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
11580 * m32c-tdep.c (m32c_raw_read): Likewise.
11581 (m32c_read_flg): Likewise.
11582 (m32c_banked_register): Likewise.
11583 (m32c_banked_read): Likewise.
11584 (m32c_sb_read): Likewise.
11585 (m32c_part_read): Likewise.
11586 (m32c_cat_read): Likewise.
11587 (m32c_r3r2r1r0_read): Likewise.
11588 (m32c_pseudo_register_read): Likewise.
11589 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
11590 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
11591 (mep_pseudo_cr64_read): Likewise.
11592 (mep_pseudo_register_read): Likewise.
11593 * mips-tdep.c (mips_pseudo_register_read): Likewise.
11594 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
11595 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
11596 * regcache.c (regcache::raw_read): Move it to readable_regcache.
11597 (regcache::cooked_read): Likewise.
11598 (regcache::cooked_read_value): Likewise.
11599 (regcache_cooked_read_signed):
11600 (regcache::cooked_read): Likewise.
11601 * regcache.h (readable_regcache): New class.
11602 (regcache): Inherit readable_regcache. Move some methods to
11604 * rl78-tdep.c (rl78_pseudo_register_read): Change
11605 parameter type to 'readable_regcache *'.
11606 * rs6000-tdep.c (do_regcache_raw_read): Remove.
11607 (e500_pseudo_register_read): Change parameter type to
11608 'readable_regcache *'.
11609 (dfp_pseudo_register_read): Likewise.
11610 (vsx_pseudo_register_read): Likewise.
11611 (efpr_pseudo_register_read): Likewise.
11612 * s390-tdep.c (s390_pseudo_register_read): Likewise.
11613 * sh-tdep.c (sh_pseudo_register_read): Likewise.
11614 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
11615 (sh64_pseudo_register_read): Likewise.
11616 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
11617 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
11618 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
11619 (spu_pseudo_register_read): Likewise.
11620 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
11621 (xtensa_pseudo_register_read): Likewise.
11623 2018-02-21 Yao Qi <yao.qi@linaro.org>
11625 * regcache.c (regcache::regcache): Call reg_buffer ctor.
11626 (regcache::arch): Move it to reg_buffer::arch.
11627 (regcache::register_buffer): Likewise.
11628 (regcache::assert_regnum): Likewise.
11629 (regcache::num_raw_registers): Likewise.
11630 * regcache.h (reg_buffer): New class.
11631 (regcache): Inherit reg_buffer.
11633 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
11635 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
11636 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
11638 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
11640 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
11642 2018-02-19 Alan Hayward <alan.hayward@arm.com>
11644 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
11645 (SFILES): Remove common/*.c files.
11646 (COMMON_OBS): Remove some *.o files built from common/*.c files.
11647 * common/common.host: Add common reference.
11648 * configure.ac: Likewise.
11649 * configure: Regenerate.
11651 2018-02-16 Yao Qi <yao.qi@linaro.org>
11653 * block.c (block_namespace_info): Inherit allocate_on_obstack.
11654 (block_initialize_namespace): Use new.
11655 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
11656 (dwarf2_free_objfile): Use delete.
11657 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
11658 (copy_type_recursive): Use new.
11659 * gdb_obstack.h (allocate_on_obstack): New.
11661 2018-02-15 Yao Qi <yao.qi@linaro.org>
11664 * inferior.c (exit_inferior_1): Reset inf->control.
11666 2018-02-15 Joel Brobecker <brobecker@adacore.com>
11668 * ada-lang.c (ada_to_fixed_value_create): Delete advance
11671 2018-02-14 Pedro Alves <palves@redhat.com>
11673 * frame-unwind.c (frame_unwind_try_unwinder): Always call
11674 frame_cleanup_after_sniffer on exception.
11676 2018-02-14 Tom Tromey <tom@tromey.com>
11678 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
11680 (solib_bfd_open): Make pathname const.
11681 * solib.c (solib_bfd_open): Make pathname const.
11682 * solib-spu.c (spu_bfd_fopen): Make name const.
11683 (spu_bfd_open): Make pathname const.
11684 * solib-darwin.c (darwin_bfd_open): Make pathname const.
11685 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
11687 2018-02-14 Tom Tromey <tom@tromey.com>
11689 * symfile.c (symfile_bfd_open): Update.
11690 * source.h (openp, source_full_path_of, find_and_open_source):
11691 Change argument type to unique_xmalloc_ptr.
11692 * source.c (openp): Take a unique_xmalloc_ptr.
11693 (source_full_path_of, find_and_open_source): Likewise.
11694 (open_source_file, symtab_to_fullname): Update.
11695 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
11696 unique_xmalloc_ptr.
11697 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
11698 (exec_file_find): Update.
11699 * psymtab.c (psymtab_to_fullname): Update.
11700 * nto-tdep.h (nto_find_and_open_solib): Update.
11701 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
11702 unique_xmalloc_ptr.
11703 * exec.c (exec_file_attach): Update.
11704 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
11705 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
11707 2018-02-14 Tom Tromey <tom@tromey.com>
11709 * solib.c: Include source.h.
11710 * nto-tdep.c: Include source.h.
11711 * mi/mi-cmd-env.c: Include source.h.
11712 * infcmd.c: Include source.h.
11713 * exec.c: Include source.h.
11714 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
11715 (add_path, directory_switch, source_path, init_source_path): Move
11717 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
11718 (add_path, directory_switch, source_path, init_source_path):
11721 2018-02-14 Tom Tromey <tom@tromey.com>
11723 * solist.h (exec_file_find, solib_find): Return
11724 unique_xmalloc_ptr.
11725 (solib_bfd_fopen): Take a const char *.
11726 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
11727 (exec_file_find, solib_find): Likewise.
11728 (solib_bfd_fopen): Do not take ownership of "pathname".
11729 (solib_bfd_open): Use unique_xmalloc_ptr.
11730 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
11731 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
11732 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
11733 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
11735 2018-02-14 Joel Brobecker <brobecker@adacore.com>
11737 * ada-lang.c (name_match_type_from_name): Remove reference to
11738 ada_name_for_lookup in function's documentation.
11739 * ada-lang.h (ada_name_for_lookup): Delete declaration.
11741 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
11743 * defs.h (enum openp_flags): New enum.
11744 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
11745 Move to enum openp_flags.
11746 (openp_flags): New enum flags.
11747 (openp): Change parameter type to openp_flags.
11748 * source.c (openp): Change parameter type to openp_flags.
11749 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
11750 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
11752 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
11754 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
11757 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
11759 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
11761 (class dwarf2_queue_guard): ...the destructor of this new class.
11762 (dw2_do_instantiate_symtab): Create instance of the new class
11763 dwarf2_queue_guard, remove cleanup.
11765 2018-02-09 Tom Tromey <tom@tromey.com>
11767 * source.c (find_source_lines): Don't reference past the end of
11770 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11772 * remote.c (remote_btrace_maybe_reopen): Change error message.
11773 * btrace.c (btrace_enable): Likewise.
11774 (parse_xml_btrace): Likewise.
11775 (parse_xml_btrace_conf): Likewise.
11777 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11779 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
11780 (linux_enable_pt, linux_enable_bts): Call
11781 diagnose_perf_event_open_fail.
11783 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11785 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
11786 Remove parameter and change return type. Update callers. Move it.
11787 (linux_enable_bts, linux_enable_pt): Improve error message.
11788 (linux_enable_pt): Remove zero buffer size check.
11789 (linux_enable_btrace): Improve error messages. Remove NULL return
11792 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11794 * btrace.c (btrace_enable): Remove target_supports_btrace call.
11795 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
11796 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
11797 (linux_supports_pt, linux_supports_btrace): Remove.
11798 (linux_enable_bts): Call cpu_supports_bts.
11799 * nat/linux-btrace.h (linux_supports_btrace): Remove.
11800 * remote.c (remote_supports_btrace): Remove.
11801 (init_remote_ops): Remove remote_supports_btrace.
11802 * target-delegates.c: Regenerated.
11803 * target.c (target_supports_btrace): Remove.
11804 * target.h (target_ops) <to_supports_btrace>: Remove
11805 (target_supports_btrace): Remove.
11806 * x86-linux-nat.c (x86_linux_create_target): Remove
11807 linux_supports_btrace.
11809 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11811 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
11813 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
11814 exception and use message in own exception.
11816 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11818 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
11819 (perf_event_pt_event_type): Use gdb_file_up.
11820 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
11821 scoped_fd, and scoped_mmap.
11823 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11825 * common/scoped_mmap.h: New.
11826 * unittests/scoped_mmap-selftest.c: New.
11827 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11828 unittests/scoped_mmap-selftest.c.
11830 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11832 * common/scoped_fd.h: New.
11833 * unittests/scoped_fd-selftest.c: New.
11834 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11835 unittests/scoped_fd-selftest.c.
11837 2018-02-09 Tom Tromey <tom@tromey.com>
11839 * auto-load.c (auto_load_section_scripts): Use
11840 gdb::unique_xmalloc_ptr.
11842 2018-02-09 Tom Tromey <tom@tromey.com>
11844 * auto-load.c (execute_script_contents): Use std::string.
11846 2018-02-09 Joel Brobecker <brobecker@adacore.com>
11848 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
11849 Python function, rather than a new command.
11851 2018-02-08 Tom Tromey <tom@tromey.com>
11853 * solib.c (solib_find_1): Use std::string.
11854 (solib_bfd_fopen): Use unique_xmalloc_ptr.
11856 2018-02-08 Tom Tromey <tom@tromey.com>
11858 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
11860 2018-02-08 Tom Tromey <tom@tromey.com>
11862 * source.c (find_source_lines): Use gdb::def_vector.
11864 2018-02-08 Tom Tromey <tom@tromey.com>
11866 * macrocmd.c (struct temporary_macro_definition): New.
11867 (macro_define_command): Use temporary_macro_definition. Remove
11869 (free_macro_definition_ptr): Remove.
11871 2018-02-08 Tom Tromey <tom@tromey.com>
11873 * macroexp.c (maybe_expand): Use std::string.
11875 2018-02-08 Tom Tromey <tom@tromey.com>
11877 * macroexp.c (struct macro_buffer): Add initializers for some
11879 (init_buffer, init_shared_buffer, free_buffer)
11880 (free_buffer_return_text): Remove.
11881 (macro_buffer): New constructors.
11882 (~macro_buffer): New destructor.
11883 (macro_buffer::set_shared): New method.
11884 (macro_buffer::resize_buffer, macro_buffer::appendc)
11885 (macro_buffer::appendmem): Now methods, not free functions.
11886 (set_token, append_tokens_without_splicing, stringify)
11887 (macro_stringify): Update.
11888 (gather_arguments): Change return type. Remove argc_p argument,
11889 add args_ptr argument. Use std::vector.
11890 (substitute_args): Remove argc argument. Accept std::vector.
11891 (expand): Update. Use std::vector.
11892 (scan, macro_expand, macro_expand_next): Update.
11894 2018-02-08 Tom Tromey <tom@tromey.com>
11896 * symtab.c (default_collect_symbol_completion_matches_break_on):
11897 Use unique_xmalloc_ptr.
11898 * macroscope.h: (sal_macro_scope, user_macro_scope)
11899 (default_macro_scope): Return unique_xmalloc_ptr.
11900 * macroscope.c (sal_macro_scope, user_macro_scope)
11901 (default_macro_scope): Return unique_xmalloc_ptr.
11902 * macroexp.h (macro_expand, macro_expand_once): Return
11903 unique_xmalloc_ptr.
11904 * macroexp.c (macro_expand, macro_expand_once): Return
11905 unique_xmalloc_ptr.
11906 * macrocmd.c (macro_expand_command, macro_expand_once_command)
11907 (info_macro_command, info_macros_command): Use
11908 unique_xmalloc_ptr.
11909 * compile/compile-c-support.c (write_macro_definitions): Use
11910 unique_xmalloc_ptr.
11911 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
11913 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
11915 * value.c (value_static_field): Assign field type instead of
11916 containing type when returning an optimized out value.
11918 2018-02-06 Yao Qi <yao.qi@linaro.org>
11920 * ft32-tdep.c (ft32_read_pc): Remove.
11921 (ft32_write_pc): Remove.
11922 (ft32_gdbarch_init): Update.
11923 * m32r-tdep.c (m32r_read_pc): Remove.
11924 (m32r_gdbarch_init): Update.
11925 * mep-tdep.c (mep_read_pc): Remove.
11926 (mep_gdbarch_init): Update.
11927 * microblaze-tdep.c (microblaze_write_pc): Remove.
11928 (microblaze_gdbarch_init): Update.
11929 * mn10300-tdep.c (mn10300_read_pc): Remove.
11930 (mn10300_write_pc): Remove.
11931 (mn10300_gdbarch_init): Update.
11932 * moxie-tdep.c (moxie_read_pc): Remove.
11933 (moxie_write_pc): Remove.
11934 (moxie_gdbarch_init): Update.
11936 2018-02-06 Yao Qi <yao.qi@linaro.org>
11938 * expprint.c (print_subexp_standard): Handle
11939 OP_F77_UNDETERMINED_ARGLIST.
11940 (dump_subexp_body_standard): Likewise.
11942 2018-02-05 Alan Hayward <alan.hayward@arm.com>
11944 * target-descriptions.c (tdesc_element_visitor) Add empty
11946 (tdesc_type): Move make_gdb_type from here.
11947 (tdesc_type_builtin): Likewise.
11948 (tdesc_type_vector): Likewise.
11949 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
11950 (make_gdb_type_struct): Move from tdesc_type_with_fields.
11951 (make_gdb_type_union): Likewise.
11952 (make_gdb_type_flags): Likewise.
11953 (make_gdb_type_enum): Likewise.
11954 (make_gdb_type): New function.
11955 (tdesc_register_type): Use static make_gdb_type.
11957 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
11959 * infcmd.c (default_print_one_register_info): Align natural-format
11960 column values consistently one under another.
11961 (pad_to_column): New function.
11963 2018-02-05 Joel Brobecker <brobecker@adacore.com>
11965 * dwarf2read.c (dwarf2_physname): Move commment.
11967 2018-02-01 Leszek Swirski <leszeks@google.com>
11969 * varobj.c (varobj_formatted_print_options): Allow recursive
11970 pretty printing if pretty printing is enabled.
11972 2018-02-01 Leszek Swirski <leszeks@google.com>
11974 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
11975 names after a structop as a filename.
11977 2018-02-01 Yao Qi <yao.qi@linaro.org>
11979 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
11980 (arm_record_coproc_data_proc): Likewise.
11982 2018-02-01 Yao Qi <yao.qi@linaro.org>
11984 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
11986 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
11988 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
11989 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
11991 2018-01-31 Pedro Alves <palves@redhat.com>
11993 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
11994 * inflow.c (child_terminal_save_inferior): Wrap reference to
11995 tcgetpgrp in HAVE_TERMIOS_H.
11996 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
11998 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
11999 always iterate over all inferiors.
12000 (gdbsim_cntrl_c): Adjust.
12001 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
12003 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12005 * gdbtypes.c (lookup_array_range_type): Make sure the array's
12006 index type is objfile-owned if the element type is as well.
12008 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12012 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
12014 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
12015 "features/s390x-linux64.c".
12016 (_initialize_s390_linux_tdep): Remove initialization of tdescs
12017 s390_linux32 and s390x_linux64.
12018 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
12020 * s390-tdep.c: Include "features/s390-linux32.c" and
12021 "features/s390x-linux64.c".
12022 (s390_tdesc_valid): Add check for tdesc_has_registers.
12023 (s390_gdbarch_init): Make sure there is always a valid tdesc.
12024 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
12025 tdesc_s390x_linux64.
12026 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
12027 tdesc_s390x_linux64 to...
12028 * s390-tdep.h: ...here.
12030 2018-01-30 Pedro Alves <palves@redhat.com>
12033 * config.in, configure: Regenerate.
12034 * configure.ac: Check for getpgid.
12035 * go32-nat.c (go32_pass_ctrlc): New.
12036 (go32_target): Install it.
12037 * inf-child.c (inf_child_target): Install
12038 child_terminal_save_inferior, child_pass_ctrlc and
12040 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
12041 (inf_ptrace_target): No longer install it.
12042 * infcmd.c (interrupt_target_1): Adjust.
12043 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
12044 (child_interrupt): Declare.
12045 (inferior::terminal_state): New.
12046 * inflow.c (struct terminal_info): Update comments.
12047 (inferior_process_group): Delete.
12048 (terminal_is_ours): Delete.
12049 (gdb_tty_state): New.
12050 (child_terminal_init): Adjust.
12051 (is_gdb_terminal, sharing_input_terminal_1)
12052 (sharing_input_terminal): New functions.
12053 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
12054 Set the process's actual process group in the foreground if
12055 possible. Handle is_ours_for_output/is_ours distinction. Don't
12056 mark terminal as the inferior's if not sharing GDB's terminal.
12057 Don't check attach_flag.
12058 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
12059 pass down a target_terminal_state.
12060 (child_terminal_save_inferior): New, factored out from ...
12061 (child_terminal_ours_1): ... this. Handle
12062 target_terminal_state::is_ours_for_output.
12063 (child_interrupt, child_pass_ctrlc): New.
12064 (inflow_inferior_exit): Clear the inferior's terminal_state.
12065 (copy_terminal_info): Copy the inferior's terminal state.
12066 (_initialize_inflow): Remove reference to terminal_is_ours.
12067 * inflow.h (inferior_process_group): Delete.
12068 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
12069 * procfs.c (procfs_target): Don't install procfs_interrupt.
12070 (procfs_interrupt): Delete.
12071 * remote.c (remote_serial_quit_handler): Adjust.
12072 (remote_interrupt): Remove ptid parameter. Adjust.
12073 * target-delegates.c: Regenerate.
12074 * target.c: Include "terminal.h".
12075 (target_terminal::terminal_state): Rename to ...
12076 (target_terminal::m_terminal_state): ... this.
12077 (target_terminal::init): Adjust.
12078 (target_terminal::inferior): Adjust to per-inferior
12080 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
12081 (target_terminal::ours, target_terminal::ours_for_output): Use
12082 target_terminal_is_ours_kind.
12083 (target_interrupt): Remove ptid parameter. Adjust.
12084 (default_target_pass_ctrlc): Adjust.
12085 * target.h (target_ops::to_terminal_save_inferior): New field.
12086 (target_ops::to_interrupt): Remove ptid_t parameter.
12087 (target_interrupt): Remove ptid_t parameter. Update comment.
12088 (target_pass_ctrlc): Update comment.
12089 * target/target.h (target_terminal_state): New scoped enum,
12090 factored out of ...
12091 (target_terminal::terminal_state): ... here.
12092 (target_terminal::inferior): Update comments.
12093 (target_terminal::restore_inferior): New.
12094 (target_terminal::is_inferior, target_terminal::is_ours)
12095 (target_terminal::is_ours_for_output): Adjust.
12096 (target_terminal::scoped_restore_terminal_state): Adjust to
12097 rename, and call restore_inferior() instead of inferior().
12098 (target_terminal::scoped_restore_terminal_state::m_state): Change
12100 (target_terminal::terminal_state): Rename to ...
12101 (target_terminal::m_terminal_state): ... this and change type.
12103 2018-01-30 Pedro Alves <palves@redhat.com>
12105 * linux-nat.c (wait_for_signal): New function.
12106 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
12108 (async_terminal_is_ours)
12109 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
12110 (linux_nat_add_target): Don't override
12111 to_terminal_inferior/to_terminal_ours.
12113 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
12115 * remote.c (remote_follow_fork): Don't call "detach_inferior".
12117 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
12119 * dwarf2read.c (free_dwo_files): Add forward-declaration.
12120 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
12121 dwarf2_per_objfile_free here.
12122 (dwarf2_per_objfile_free): Remove.
12123 (_initialize_dwarf2_read): Don't register
12124 dwarf2_per_objfile_free as a registry cleanup.
12126 2018-01-27 Eli Zaretskii <eliz@gnu.org>
12128 Avoid compilation errors in MinGW native builds
12130 The error is triggered by including python-internal.h, and the
12133 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
12134 from build-gnulib/import/math.h:27,
12135 from d:/usr/Python26/include/pyport.h:235,
12136 from d:/usr/Python26/include/Python.h:58,
12137 from python/python-internal.h:94,
12138 from python/py-arch.c:24:
12139 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
12143 This happens because Python headers define 'hypot' to expand t
12144 '_hypot' in the Windows builds.
12145 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
12146 'hypoth'. This avoids a compilation error.
12148 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12150 * MAINTAINERS (Write After Approval): Fix ordering.
12152 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12154 * MAINTAINERS (Write After Approval): Add Alan Hayward.
12156 2018-01-26 Alan Modra <amodra@gmail.com>
12158 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
12159 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
12160 Remove nop. Make const. Comment.
12161 (powerpc32_plt_stub_so_2): New.
12162 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
12163 Correct count. Update uses.
12164 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
12165 Move common code reading PLT entry word. Correct
12166 powerpc32_plt_stub PLT address calculation.
12167 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
12168 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
12169 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
12170 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
12171 (ppc64_standard_linkage8): Likewise.
12172 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
12173 Correct insns description.
12174 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
12176 2018-01-24 Pedro Alves <palves@redhat.com>
12178 GCC PR libstdc++/83906
12179 * gdbtypes.c (operator==(const dynamic_prop &,
12180 const dynamic_prop &)): New.
12181 (operator==(const range_bounds &, const range_bounds &)): New.
12182 (check_types_equal): Use them instead of memcmp.
12183 * gdbtypes.h (operator==(const dynamic_prop &,
12184 const dynamic_prop &)): Declare.
12185 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
12186 (operator==(const range_bounds &, const range_bounds &)): Declare.
12187 (operator!=(const range_bounds &, const range_bounds &)): Declare.
12189 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12191 * s390-linux-tdep.c (s390_record_address_mask)
12192 (s390_record_calc_disp_common, s390_record_calc_disp)
12193 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12194 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12195 (s390_process_record): Move to s390-tdep.c.
12196 (s390_linux_init_abi_any): Adjust.
12197 * s390-tdep.c (s390_record_address_mask)
12198 (s390_record_calc_disp_common, s390_record_calc_disp)
12199 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12200 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12201 (s390_process_record): Moved from s390-linux-tdep.c
12202 (s390_gdbarch_init): Adjust.
12204 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12206 * s390-linux-nat.c (s390-tdep.h): New include.
12207 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
12208 (HFILES_NO_SRCDIR): Add s390-tdep.h.
12209 (ALLDEPFILES): Add s390-tdep.c.
12210 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
12211 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
12212 * s390-tdep.h: ...this. New file.
12213 * s390-linux-tdep.c (s390-tdep.h): New include.
12214 (_initialize_s390_tdep): Rename to...
12215 (_initialize_s390_linux_tdep): ...this and adjust.
12216 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
12217 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
12219 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
12220 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
12221 (s390_is_partial_instruction, s390_software_single_step)
12222 (is_non_branch_ril, s390_displaced_step_copy_insn)
12223 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
12224 (s390_prologue_data, s390_addr, s390_store, s390_load)
12225 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
12226 (s390_register_call_saved, s390_guess_tracepoint_registers)
12227 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
12228 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
12229 (s390_pseudo_register_name, s390_pseudo_register_type)
12230 (s390_pseudo_register_read, s390_pseudo_register_write)
12231 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
12232 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
12233 (s390_addr_bits_remove, s390_address_class_type_flags)
12234 (s390_address_class_type_flags_to_name)
12235 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
12236 (s390_function_arg_float, s390_function_arg_vector)
12237 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
12238 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
12239 (s390_frame_align, s390_register_return_value, s390_return_value)
12240 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
12241 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
12242 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
12243 (s390_trad_frame_prev_register, s390_unwind_cache)
12244 (s390_prologue_frame_unwind_cache)
12245 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
12246 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
12247 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
12248 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
12249 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
12250 (s390_frame_base_address, s390_local_base_address)
12251 (s390_frame_base, s390_gcc_target_options)
12252 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
12253 (s390_validate_reg_range, s390_tdesc_valid)
12254 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
12255 * s390-tdep.c: ...this. New file.
12257 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12259 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
12260 (s390_process_record, s390_gdbarch_tdep_alloc)
12261 (s390_linux_init_abi_any): Use/set new hook.
12263 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12265 * s390-linux-tdep.c (osabi.h): New include.
12266 (s390_linux_init_abi_31, s390_linux_init_abi_64)
12267 (s390_linux_init_abi_any): New functions.
12268 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
12270 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12272 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
12273 tdesc_has_registers check
12275 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12277 * s390-linux-tdep.c (s390_tdesc_valid): New function.
12278 (s390_validate_reg_range): New macro.
12279 (s390_gdbarch_init): Adjust.
12281 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12283 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
12284 (s390_gdbarch_tdep_alloc): Adjust.
12285 (s390_gdbarch_init): Adjust.
12287 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12289 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
12290 <have_tdb>: Change type to bool.
12291 (s390_gdbarch_tdep_alloc): Adjust.
12292 (s390_gdbarch_init): Adjust.
12294 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12296 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
12297 (gdbarch_tdep) <have_upper, have_vx>: New fields.
12298 (s390_gdbarch_tdep_alloc): New function.
12299 (s390_gdbarch_init): Allocate tdep at start and use its fields
12300 instead of separate variables.
12302 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12304 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
12305 when looking for cached gdbarch and add comment for remaining.
12307 2018-01-22 Pedro Alves <palves@redhat.com>
12308 Sergio Durigan Junior <sergiodj@redhat.com>
12310 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
12313 2018-01-22 Maciej W. Rozycki <macro@mips.com>
12315 * MAINTAINERS: Update my company e-mail address.
12317 2018-01-22 Yao Qi <yao.qi@linaro.org>
12319 * regcache.c (cooked_write_test): New function.
12320 (_initialize_regcache): Register the test.
12322 2018-01-22 Yao Qi <yao.qi@linaro.org>
12324 * ia64-tdep.c (ia64_pseudo_register_read): Call
12325 regcache->cooked_read instead of regcache_cooked_read_unsigned.
12326 * m32c-tdep.c (m32c_cat_read): Likewise.
12327 (m32c_r3r2r1r0_read): Likewise.
12328 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
12329 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
12331 2018-01-22 Yao Qi <yao.qi@linaro.org>
12333 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
12334 method raw_read instead of regcache_raw_read.
12335 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
12336 * arm-tdep.c (arm_neon_quad_read): Likewise.
12337 * avr-tdep.c (avr_pseudo_register_read): Likewise.
12338 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
12339 * frv-tdep.c (frv_pseudo_register_read): Likewise.
12340 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
12341 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
12342 (i386_pseudo_register_read_into_value): Likewise.
12343 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
12344 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
12345 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
12346 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
12347 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
12348 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
12349 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
12350 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
12351 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
12353 2018-01-22 Yao Qi <yao.qi@linaro.org>
12355 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
12356 * configure.tgt: Remove target mt.
12357 * mt-tdep.c: Remove.
12358 * regcache.c (cooked_read_test): Remove the check for mt.
12360 2018-01-22 Yao Qi <yao.qi@linaro.org>
12362 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
12363 instead of gdbarch_pseudo_register_read_value.
12365 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12367 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
12370 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12372 * linespec.c (create_sals_line_offset): Remove code that preserved
12373 the symtab_and_line's line number.
12375 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12377 * varobj.c (varobj_create): Don't set valid_block when creating a
12380 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12382 * varobj.c (varobj_create): Remove out of date comment.
12384 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12387 * ada-exp.y (write_var_from_sym): Pass extra parameter when
12388 updating innermost block.
12389 * parse.c (innermost_block_tracker::update): Take extra type
12390 parameter, and check types match before updating innermost block.
12391 (write_dollar_variable): Update innermost block for registers.
12392 * parser-defs.h (enum innermost_block_tracker_type): New enum.
12393 (innermost_block_tracker::innermost_block_tracker): Initialise
12395 (innermost_block_tracker::reset): Take type parameter.
12396 (innermost_block_tracker::update): Take type parameter, and pass
12397 type through as needed.
12398 (innermost_block_tracker::m_types): New member.
12399 * varobj.c (varobj_create): Pass type when reseting innermost
12402 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12404 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
12405 * ada-lang.c (resolve_subexp): Likewise.
12406 * breakpoint.c (set_breakpoint_condition) Likewise.
12407 (watch_command_1) Likewise.
12408 * c-exp.y (variable): Likewise.
12409 * d-exp.y (PrimaryExpression): Likewise.
12410 * f-exp.y (variable): Likewise.
12411 * go-exp.y (variable): Likewise.
12412 * m2-exp.y (variable): Likewise.
12413 * objfiles.c (objfile::~objfile): Likewise.
12414 * p-exp.y (variable): Likewise.
12415 * parse.c (innermost_block): Change type.
12416 * parser-defs.h (class innermost_block_tracker): New.
12417 (innermost_block): Change to innermost_block_tracker.
12418 * printcmd.c (display_command): Switch to innermost_block API.
12419 (do_one_display): Likewise.
12420 * rust-exp.y (do_one_display): Likewise.
12421 * symfile.c (clear_symtab_users): Likewise.
12422 * varobj.c (varobj_create): Switch to innermost_block API, replace
12423 use of innermost_block with block stored on varobj object.
12425 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12427 * expression.h (innermost_block): Remove declaration.
12428 * varobj.c: Add 'parser-defs.h' include.
12430 2018-01-19 Tom Tromey <tom@tromey.com>
12432 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
12433 symbols in the static and global blocks.
12435 2018-01-19 James Clarke <jrtc27@jrtc27.com>
12437 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
12438 gdb_ptrace.h, and move including gdb_wait.h ...
12439 * nat/linux-ptrace.h: ... to here.
12441 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12443 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
12444 inf_ptrace_detach_success.
12445 (inf_ptrace_detach_success): Add inferior parameter, use it
12446 instead of inferior_ptid, pass it to detach_inferior.
12447 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
12449 * inferior.c (detach_inferior): Add overload that takes an
12451 * inferior.h (detach_inferior): Likewise.
12452 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
12453 use inferior_ptid, adjust call to inf_ptrace_detach_success.
12454 * linux-thread-db.c (thread_db_detach): Use inf parameter.
12456 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12458 * target.h (struct target_ops) <to_detach>: Add inferior
12460 (target_detach): Likewise.
12461 * target.c (dispose_inferior): Pass inferior down.
12462 (target_detach): Pass inferior down. Assert that it is equal to
12463 the current inferior.
12464 * aix-thread.c (aix_thread_detach): Pass inferior down.
12465 * corefile.c (core_file_command): Pass current_inferior() down.
12466 * corelow.c (core_detach): Add inferior parameter.
12467 * darwin-nat.c (darwin_detach): Likewise.
12468 * gnu-nat.c (gnu_detach): Likewise.
12469 * inf-ptrace.c (inf_ptrace_detach): Likewise.
12470 * infcmd.c (detach_command): Pass current_inferior() down to
12472 * infrun.c (follow_fork_inferior): Pass parent_inf to
12474 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
12476 * linux-nat.c (linux_nat_detach): Add inferior parameter.
12477 * linux-thread-db.c (thread_db_detach): Likewise.
12478 * nto-procfs.c (procfs_detach): Likewise.
12479 * procfs.c (procfs_detach): Likewise.
12480 * record.c (record_detach): Likewise.
12481 * record.h (struct inferior): Forward-declare.
12482 (record_detach): Add inferior parameter.
12483 * remote-sim.c (gdbsim_detach): Likewise.
12484 * remote.c (remote_detach_1): Likewise.
12485 (remote_detach): Likewise.
12486 (extended_remote_detach): Likewise.
12487 * sol-thread.c (sol_thread_detach): Likewise.
12488 * target-debug.h (target_debug_print_inferior_p): New macro.
12489 * target-delegates.c: Re-generate.
12490 * top.c (kill_or_detach): Pass inferior down to target_detach.
12491 * windows-nat.c (windows_detach): Add inferior parameter.
12493 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12495 * target.h (struct target_ops) <to_detach>: Remove args
12497 (target_detach): Likewise.
12498 * target.c (dispose_inferior): Adjust.
12499 (target_detach): Remove args parameter, adjust.
12500 * aix-thread.c (aix_thread_detach): Adjust.
12501 * corefile.c (core_file_command): Adjust.
12502 * corelow.c (core_detach): Adjust.
12503 * darwin-nat.c (darwin_detach): Adjust.
12504 * gnu-nat.c (gnu_detach): Adjust.
12505 * inf-ptrace.c (inf_ptrace_detach): Adjust.
12506 * infcmd.c (detach_command): Adjust
12507 * infrun.c (follow_fork_inferior): Adjust.
12508 (handle_vfork_child_exec_or_exit): Adjust.
12509 * linux-fork.c (linux_fork_detach): Remove args parameter.
12510 * linux-fork.h (linux_fork_detach): Likewise.
12511 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
12512 * linux-thread-db.c (thread_db_detach): Likewise.
12513 * nto-procfs.c (procfs_detach): Likewise.
12514 * procfs.c (procfs_detach): Likewise.
12515 (do_detach): Remove signo parameter.
12516 * record.c (record_detach): Remove args parameter.
12517 * record.h (record_detach): Likewise.
12518 * remote-sim.c (gdbsim_detach): Likewise.
12519 * remote.c (remote_detach_1): Likewise.
12520 (remote_detach): Likewise.
12521 (extended_remote_detach): Likewise.
12522 * sol-thread.c (sol_thread_detach): Likewise.
12523 * target-delegates.c: Re-generate.
12524 * top.c (struct qt_args) <args>: Remove field.
12525 (kill_or_detach): Don't pass args.
12526 (quit_force): Don't set args.
12527 * windows-nat.c (windows_detach): Remove args parameter.
12529 2018-01-19 Yao Qi <yao.qi@linaro.org>
12531 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
12532 (arm_linux_init_abi): Install it.
12534 2018-01-19 Yao Qi <yao.qi@linaro.org>
12536 * osabi.c (gdb_osabi_names): Extend the regexp for
12537 arm-linux-gnueabihf.
12539 2018-01-18 Yao Qi <yao.qi@linaro.org>
12541 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
12543 (abbrev_table::add_abbrev): Update.
12544 (abbrev_table::lookup_abbrev): Update.
12546 2018-01-18 Yao Qi <yao.qi@linaro.org>
12548 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
12550 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
12552 * compile/compile.c (compile_to_object): Convert "triplet_rx"
12555 2018-01-17 Tom Tromey <tom@tromey.com>
12557 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
12559 2018-01-17 Tom Tromey <tom@tromey.com>
12561 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
12562 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
12563 (create_array_type_with_stride): Update.
12564 * dwarf2read.c (set_die_type): Update.
12566 2018-01-17 Tom Tromey <tom@tromey.com>
12568 * dwarf2read.c (delayed_method_info): Remove typedef.
12569 (dwarf2_cu::method_info): Now a std::vector.
12570 (add_to_method_list): Update.
12571 (free_delayed_list): Remove.
12572 (compute_delayed_physnames): Update.
12573 (process_full_comp_unit, process_full_type_unit): Clear the method
12574 list. Remove cleanups.
12575 (psymtab_include_file_name): Add name_holder parameter. Use
12576 unique_xmalloc_ptr.
12577 (dwarf_decode_lines): Update.
12579 2018-01-17 Tom Tromey <tom@tromey.com>
12580 Simon Marchi <simon.marchi@ericsson.com>
12582 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
12583 (dwarf2_per_objfile::free_cached_comp_units)
12584 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12585 (init_cutu_and_read_dies_no_follow): Update.
12586 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
12587 (dwarf2_cu::~dwarf2_cu): New.
12588 (free_heap_comp_unit, free_stack_comp_unit): Remove.
12589 (age_cached_comp_units, free_one_cached_comp_unit): Update.
12591 2018-01-17 Tom Tromey <tom@tromey.com>
12592 Simon Marchi <simon.marchi@ericsson.com>
12594 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
12595 (struct die_reader_specs) <abbrev_table>: New member.
12596 (struct abbrev_table): Add constructor.
12597 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
12598 <abbrev_obstack>: Now an auto_obstack.
12599 (abbrev_table_up): New typedef.
12600 (init_cu_die_reader): Add abbrev_table parameter.
12601 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
12602 Add result_dwo_abbrev_table.
12603 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12604 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
12606 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
12608 (skip_children): Update.
12609 (abbrev_table::alloc_abbrev): Rename from
12610 abbrev_table_alloc_abbrev.
12611 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
12612 (abbrev_table::lookup_abbrev): Rename from
12613 abbrev_table_lookup_abbrev.
12614 (abbrev_table_read_table): Return abbrev_table_up.
12615 (abbrev_table_free, abbrev_table_free_cleanup)
12616 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
12617 (load_partial_dies): Update.
12619 2018-01-17 Tom Tromey <tom@tromey.com>
12621 * dwarf2read.c (dwarf2_compute_name): Update comment.
12622 (read_func_scope, read_variable): Update.
12623 (new_symbol): Remove.
12624 (new_symbol_full): Rename to new_symbol.
12626 2018-01-17 Mike Gulick <mgulick@mathworks.com>
12629 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
12630 a warning instead of throwing an error, set section size to 0 and return
12632 * gdb_bfd.h (gdb_bfd_map_section): Update description.
12634 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
12636 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
12638 (linux_ptrace_attach_fail_reason_string): Likewise.
12639 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
12641 (linux_ptrace_attach_fail_reason_string): Likewise.
12642 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
12644 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
12646 * linux-nat.c (linux_nat_attach): Remove xstrdup.
12648 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
12651 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
12652 checking for fs_base/gs_base fields in struct user_regs_struct.
12653 * configure: Regenerate.
12655 2018-01-17 Yao Qi <yao.qi@linaro.org>
12657 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
12659 (aarch64_linux_init_abi): Install it to gdbarch hook
12660 gcc_target_options.
12662 2018-01-15 Pedro Alves <palves@redhat.com>
12664 * common/signals-state-save-restore.c
12665 (save_original_signals_state): Fix typos.
12667 2017-01-12 Tom Tromey <tom@tromey.com>
12668 Sergio Durigan Junior <sergiodj@redhat.com>
12670 * Makefile.in (install-only): Install gdb-add-index.
12672 2018-01-12 John Baldwin <jhb@FreeBSD.org>
12674 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
12676 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
12678 * infrun.c (keep_going_pass_signal): Clear step-over info when
12679 insert_breakpoints fails.
12681 2018-01-11 Pedro Alves <palves@redhat.com>
12684 * infrun.c (resume): Rename to ...
12685 (resume_1): ... this.
12686 (resume): Reimplement as wrapper around resume_1.
12688 2018-01-11 Pedro Alves <palves@redhat.com>
12691 * remote.c (remote_parse_stop_reply): Default to the last-set
12692 general thread instead of to 'magic_null_ptid'.
12694 2018-01-10 Pedro Alves <palves@redhat.com>
12696 * language.h (language_get_symbol_name_matcher): Rename ...
12697 (get_symbol_name_matcher): ... this.
12698 * language.c (language_get_symbol_name_matcher): Ditto.
12699 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
12702 2018-01-10 Pedro Alves <palves@redhat.com>
12706 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
12707 Adjust to use language_get_symbol_name_matcher instead of
12708 language_defn::la_get_symbol_name_matcher.
12709 * language.c (language_get_symbol_name_matcher): If in Ada mode
12710 and the lookup name is a verbatim match, return Ada's matcher.
12711 * language.h (language_get_symbol_name_matcher): Adjust comment.
12712 (ada_lookup_name_info::verbatim_p):: New method.
12714 2018-01-10 Pedro Alves <palves@redhat.com>
12717 * ada-lang.c (ada_collect_symbol_completion_matches): If the
12718 minsym's language is language_auto or language_cplus, pass down
12719 language_ada instead.
12720 * symtab.c (compare_symbol_name): Don't frob symbol language here.
12722 2018-01-10 Pedro Alves <palves@redhat.com>
12725 * minsyms.c (linkage_name_str): New function.
12726 (iterate_over_minimal_symbols): Use it.
12728 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12730 * NEWS: Document that 'info proc' now works on FreeBSD.
12732 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12734 * configure.ac: Check for kinfo_getfile in libutil.
12735 * configure: Regenerate.
12736 * config.in: Regenerate.
12737 * fbsd-nat.c: Include "fbsd-tdep.h".
12738 (fbsd_fetch_cmdline): New.
12739 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
12740 rather than calling error.
12741 (fbsd_info_proc): New.
12742 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
12743 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
12744 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
12746 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12748 * fbsd-nat.c (struct free_deleter): Remove.
12749 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
12751 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12753 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
12754 NULL for an empty pathname.
12756 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12758 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
12759 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
12760 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
12761 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
12762 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
12763 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
12764 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
12765 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
12766 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
12767 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
12768 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
12769 (fbsd_core_fetch_timeval, fbsd_print_sigset)
12770 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
12771 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
12772 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
12774 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
12776 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
12777 (gnu_xfer_auxv): New function.
12778 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
12779 TARGET_OBJECT_AUXV.
12781 2018-01-08 Yao Qi <yao.qi@linaro.org>
12782 Simon Marchi <simon.marchi@ericsson.com>
12784 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
12786 (COMMON_OBS): Remove selftest.o.
12787 * configure.ac: Append selftest-arch.c and common/selftest.c to
12788 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
12789 * configure: Re-generated.
12790 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
12792 (maintenance_info_selftests): Likewise.
12794 2018-01-08 Xavier Roirand <roirand@adacore.com>
12796 * ada-valprint.c (val_print_packed_array_elements): Use
12797 proper number of elements when printing an array indexed
12798 by an enumeration type.
12800 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
12802 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
12803 (dw2_get_file_names_reader): Adjust.
12804 (lookup_dwo_signatured_type): Adjust.
12805 (lookup_dwp_signatured_type): Adjust.
12806 (lookup_signatured_type): Adjust.
12807 (create_type_unit_group): Adjust.
12808 (get_type_unit_group): Adjust.
12809 (process_psymtab_comp_unit_reader): Adjust.
12810 (build_type_psymtabs_reader): Adjust.
12811 (scan_partial_symbols): Adjust.
12812 (add_partial_symbol): Adjust.
12813 (add_partial_subprogram): Adjust.
12814 (peek_die_abbrev): Adjust.
12815 (fixup_go_packaging): Adjust.
12816 (process_imported_unit_die): Adjust.
12817 (dwarf2_compute_name): Adjust.
12818 (dwarf2_physname): Adjust.
12819 (read_import_statement): Adjust.
12820 (handle_DW_AT_stmt_list): Adjust.
12821 (read_file_scope): Adjust.
12822 (read_func_scope): Adjust.
12823 (read_lexical_block_scope): Adjust.
12824 (read_call_site_scope): Adjust.
12825 (read_variable): Adjust.
12826 (dwarf2_rnglists_process): Adjust.
12827 (dwarf2_ranges_process): Adjust.
12828 (dwarf2_ranges_read): Adjust.
12829 (dwarf2_get_pc_bounds): Adjust.
12830 (dwarf2_record_block_ranges): Adjust.
12831 (dwarf2_add_field): Adjust.
12832 (dwarf2_add_member_fn): Adjust.
12833 (read_structure_type): Adjust.
12834 (process_structure_scope): Adjust.
12835 (read_enumeration_type): Adjust.
12836 (read_array_type): Adjust.
12837 (mark_common_block_symbol_computed): Adjust.
12838 (read_common_block): Adjust.
12839 (read_namespace_type): Adjust.
12840 (read_namespace): Adjust.
12841 (read_module_type): Adjust.
12842 (read_tag_pointer_type): Adjust.
12843 (read_tag_ptr_to_member_type): Adjust.
12844 (read_tag_string_type): Adjust.
12845 (read_subroutine_type): Adjust.
12846 (read_typedef): Adjust.
12847 (read_base_type): Adjust.
12848 (attr_to_dynamic_prop): Adjust.
12849 (read_subrange_type): Adjust.
12850 (read_unspecified_type): Adjust.
12851 (dwarf2_read_abbrevs): Adjust.
12852 (load_partial_dies): Adjust.
12853 (read_partial_die): Adjust.
12854 (find_partial_die): Adjust.
12855 (guess_partial_die_structure_name): Adjust.
12856 (fixup_partial_die): Adjust.
12857 (read_attribute_value): Adjust.
12858 (read_addr_index): Adjust.
12859 (read_addr_index_from_leb128): Adjust.
12860 (read_str_index): Adjust.
12861 (dwarf2_string_attr): Adjust.
12862 (get_debug_line_section): Adjust.
12863 (dwarf_decode_line_header): Adjust.
12864 (lnp_state_machine::check_line_address): Adjust.
12865 (dwarf_decode_lines_1): Adjust.
12866 (dwarf_decode_lines): Adjust.
12867 (dwarf2_start_symtab): Adjust.
12868 (var_decode_location): Adjust.
12869 (new_symbol_full): Adjust.
12870 (dwarf2_const_value_data): Adjust.
12871 (dwarf2_const_value_attr): Adjust.
12872 (dwarf2_const_value): Adjust.
12873 (die_type): Adjust.
12874 (die_containing_type): Adjust.
12875 (build_error_marker_type): Adjust.
12876 (lookup_die_type): Adjust.
12877 (guess_full_die_structure_name): Adjust.
12878 (anonymous_struct_prefix): Adjust.
12879 (determine_prefix): Adjust.
12880 (dwarf2_name): Adjust.
12881 (follow_die_ref_or_sig): Adjust.
12882 (follow_die_offset): Adjust.
12883 (follow_die_ref): Adjust.
12884 (follow_die_sig_1): Adjust.
12885 (follow_die_sig): Adjust.
12886 (get_signatured_type): Adjust.
12887 (get_DW_AT_signature_type): Adjust.
12888 (decode_locdesc): Adjust.
12889 (dwarf_decode_macros): Adjust.
12890 (cu_debug_loc_section): Adjust.
12891 (fill_in_loclist_baton): Adjust.
12892 (dwarf2_symbol_mark_computed): Adjust.
12893 (init_one_comp_unit): Don't assign
12894 dwarf2_cu::dwarf2_per_objfile.
12895 (set_die_type): Adjust.
12897 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
12899 * dwarf2read.c (struct mapped_debug_names): Add constructor.
12900 <dwarf2_per_objfile>: New field.
12901 (dwarf2_per_objfile): Remove global.
12902 (get_dwarf2_per_objfile): New function.
12903 (set_dwarf2_per_objfile): New function.
12904 (dwarf2_build_psymtabs_hard): Change objfile parameter to
12905 dwarf2_per_objfile.
12906 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
12907 (read_abbrev_offset): Likewise.
12908 (read_indirect_string): Likewise.
12909 (read_indirect_line_string): Likewise.
12910 (read_indirect_string_at_offset): Likewise.
12911 (read_indirect_string_from_dwz): Likewise.
12912 (dwarf2_find_containing_comp_unit): Change objfile parameter to
12913 dwarf2_per_objfile.
12914 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
12915 (create_all_comp_units): Change objfile parameter to
12916 dwarf2_per_objfile.
12917 (create_all_type_units): Likewise.
12918 (process_queue): Add dwarf2_per_objfile parameter.
12919 (read_and_check_comp_unit_head): Likewise.
12920 (lookup_dwo_unit_in_dwp): Likewise.
12921 (get_dwp_file): Likewise.
12922 (process_cu_includes): Likewise.
12923 (struct free_dwo_file_cleanup_data): New struct.
12924 (dwarf2_has_info): Use get_dwarf2_per_objfile and
12925 set_dwarf2_per_objfile.
12926 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
12927 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
12928 context, adjust calls.
12929 (dw2_instantiate_symtab): Likewise.
12930 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
12931 (dw2_get_cu): Likewise.
12932 (create_cu_from_index_list): Change objfile parameter to
12933 dwarf2_per_objfile.
12934 (create_cus_from_index_list): Get dwarf2_per_objfile from
12935 context, adjust calls.
12936 (create_cus_from_index): Likewise.
12937 (create_signatured_type_table_from_index): Change objfile
12938 parameter to dwarf2_per_objfile.
12939 (create_signatured_type_table_from_debug_names): Change objfile
12940 parameter to dwarf2_per_objfile.
12941 (create_addrmap_from_index): Likewise.
12942 (create_addrmap_from_aranges): Likewise.
12943 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
12944 (dw2_setup): Remove.
12945 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
12947 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
12948 get_dwarf2_per_objfile.
12949 (dw2_forget_cached_source_info): Likewise.
12950 (dw2_map_symtabs_matching_filename): Likewise.
12951 (struct dw2_symtab_iterator) <index>: Remove.
12952 <dwarf2_per_objfile>: New field.
12953 (dw2_symtab_iter_init): Replace index parameter with
12954 dwarf2_per_objfile.
12955 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
12956 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
12957 (dw2_print_stats): Likewise.
12958 (dw2_dump): Likewise.
12959 (dw2_expand_symtabs_for_function): Likewise.
12960 (dw2_expand_all_symtabs): Likewise.
12961 (dw2_expand_symtabs_with_fullname): Likewise.
12962 (dw2_expand_marked_cus): Replace index and objfile parameters
12963 with dwarf2_per_objfile.
12964 (dw_expand_symtabs_matching_file_matcher): Add
12965 dwarf2_per_objfile parameter and adjust calls.
12966 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
12968 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
12969 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
12971 (create_cus_from_debug_names_list): Replace objfile parameter
12972 with dwarf2_per_objfile and adjust calls.
12973 (create_cus_from_debug_names): Likewise.
12974 (dwarf2_read_debug_names): Likewise.
12975 (mapped_debug_names::namei_to_name): Adjust call.
12976 (dw2_debug_names_iterator::next): Likewise.
12977 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
12978 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
12979 (dw2_debug_names_dump): Likewise.
12980 (dw2_debug_names_expand_symtabs_for_function): Likewise.
12981 (dw2_debug_names_expand_symtabs_matching): Likewise.
12982 (dwarf2_initialize_objfile): Likewise.
12983 (dwarf2_build_psymtabs): Likewise.
12984 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
12986 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
12987 (read_and_check_comp_unit_head): Likewise.
12988 (read_abbrev_offset): Likewise.
12989 (create_debug_type_hash_table): Likewise.
12990 (create_debug_types_hash_table): Likewise.
12991 (create_all_type_units): Replace objfile parameter with
12992 dwarf2_per_objfile.
12993 (add_type_unit): Add dwarf2_per_objfile parameter.
12994 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
12995 with dwarf2_per_objfile.
12996 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
12997 (lookup_dwp_signatured_type): Likewise.
12998 (lookup_signatured_type): Likewise.
12999 (read_cutu_die_from_dwo): Likewise.
13000 (init_tu_and_read_dwo_dies): Likewise.
13001 (init_cutu_and_read_dies): Likewise.
13002 (init_cutu_and_read_dies_no_follow): Likewise.
13003 (allocate_type_unit_groups_table): Add objfile parameter.
13004 (create_type_unit_group): Use dwarf2_per_objfile from cu.
13005 (get_type_unit_group): Likewise.
13006 (process_psymtab_comp_unit): Update call.
13007 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
13008 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
13009 (print_tu_stats): Likewise.
13010 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
13011 in void* parameter.
13012 (build_type_psymtabs): Change objfile parameter to
13013 dwarf2_per_objfile.
13014 (process_skeletonless_type_unit): Use dwarf2_per_objfile
13015 passed in void* parameter.
13016 (process_skeletonless_type_units): Change objfile parameter to
13017 dwarf2_per_objfile.
13018 (set_partial_user): Likewise.
13019 (dwarf2_build_psymtabs_hard): Likewise.
13020 (read_comp_units_from_section): Likewise.
13021 (create_all_comp_units): Likewise.
13022 (scan_partial_symbols): Update calls.
13023 (add_partial_symbol): Likewise.
13024 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
13025 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
13026 (process_queue): Add dwarf2_per_objfile parameter.
13027 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
13028 (compute_compunit_symtab_includes): Likewise.
13029 (process_cu_includes): Add dwarf2_per_objfile parameter.
13030 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
13031 (process_full_type_unit): Likewise.
13032 (process_imported_unit_die): Update call.
13033 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
13034 (read_file_scope): Likewise.
13035 (allocate_dwo_file_hash_table): Add objfile parameter.
13036 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
13037 (create_cus_hash_table): Likewise.
13038 (create_dwp_hash_table): Likewise.
13039 (create_dwo_unit_in_dwp_v1): Likewise.
13040 (create_dwp_v2_section): Likewise.
13041 (create_dwo_unit_in_dwp_v2): Likewise.
13042 (lookup_dwo_unit_in_dwp): Likewise.
13043 (try_open_dwop_file): Likewise.
13044 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
13045 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
13046 cleanup to include a reference to dwarf2_per_objfile.
13047 (open_dwp_file): Add dwarf2_per_objfile parameter.
13048 (open_and_init_dwp_file): Likewise.
13049 (get_dwp_file): Likewise.
13050 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
13051 (queue_and_load_all_dwo_tus): Update call.
13052 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
13054 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
13055 (dwarf2_ranges_process): Likewise.
13056 (dwarf2_get_pc_bounds): Likewise.
13057 (mark_common_block_symbol_computed): Likewise.
13058 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
13059 (dwarf2_read_abbrevs): Update call.
13060 (read_partial_die): Use dwarf2_per_objfile from cu.
13061 (find_partial_die): Likewise.
13062 (fixup_partial_die): Likewise.
13063 (read_attribute_value): Likewise.
13064 (read_indirect_string_at_offset_from): Add objfile parameter.
13065 (read_indirect_string_at_offset): Add dwarf2_per_objfile
13067 (read_indirect_string_from_dwz): Add objfile parameter.
13068 (read_indirect_string): Add objfile parameter.
13069 (read_addr_index_1): Add dwarf2_per_objfile parameter.
13070 (read_addr_index): Use dwarf2_per_objfile from cu.
13071 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
13073 (read_str_index): Use dwarf2_per_objfile from cu.
13074 (get_debug_line_section): Likewise.
13075 (read_formatted_entries): Add dwarf2_per_objfile parameter.
13076 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
13077 (new_symbol_full): Use dwarf2_per_objfile from cu.
13078 (build_error_marker_type): Likewise.
13079 (lookup_die_type): Likewise.
13080 (determine_prefix): Likewise.
13081 (follow_die_offset): Likewise.
13082 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
13083 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
13084 (dwarf2_fetch_die_type_sect_off): Likewise.
13085 (dwarf2_get_die_type): Likewise.
13086 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
13087 (get_signatured_type): Likewise.
13088 (get_DW_AT_signature_type): Likewise.
13089 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
13090 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
13091 (cu_debug_loc_section): Likewise.
13092 (fill_in_loclist_baton): Likewise.
13093 (dwarf2_symbol_mark_computed): Likewise.
13094 (dwarf2_find_containing_comp_unit): Change objfile parameter to
13095 dwarf2_per_objfile.
13096 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
13098 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
13099 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
13100 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
13101 (set_die_type): Use dwarf2_free_objfile from cu.
13102 (get_die_type_at_offset): Likewise.
13103 (dwarf2_per_objfile_free): Don't assign global variable.
13104 (debug_names) <constructor>: Add dwarf2_per_objfile
13105 parameter, update m_debugstrlookup construction.
13106 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
13108 <m_dwarf2_per_objfile>: New field.
13109 <lookup>: Use m_dwarf2_per_objfile.
13110 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
13111 (psyms_seen_size): Likewise.
13112 (write_gdbindex): Replace objfile parameter with
13113 dwarf2_per_objfile.
13114 (write_debug_names): Likewise.
13115 (write_psymtabs_to_index): Likewise.
13116 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
13119 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13121 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
13122 <dwarf2_per_objfile>: New field.
13123 (struct dwarf2_per_cu_data) <objfile>: Remove.
13124 <dwarf2_per_objfile>: New field.
13125 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
13127 (create_signatured_type_table_from_index): Likewise.
13128 (create_debug_type_hash_table): Likewise.
13129 (fill_in_sig_entry_from_dwo_entry): Likewise.
13130 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
13131 (create_type_unit_group): Assign dwarf2_per_objfile instead of
13133 (create_partial_symtab): Access objfile through
13134 dwarf2_per_objfile.
13135 (process_psymtab_comp_unit_reader): Likewise.
13136 (read_comp_units_from_section): Likewise.
13137 (scan_partial_symbols): Likewise.
13138 (add_partial_symbol): Likewise.
13139 (add_partial_subprogram): Likewise.
13140 (peek_die_abbrev): Likewise.
13141 (fixup_go_packaging): Likewise.
13142 (process_full_comp_unit): Likewise.
13143 (process_full_type_unit): Likewise.
13144 (process_imported_unit_die): Likewise.
13145 (dwarf2_compute_name): Likewise.
13146 (dwarf2_physname): Likewise.
13147 (read_import_statement): Likewise.
13148 (create_cus_hash_table): Assign dwarf2_physname instead of
13150 (read_func_scope): Access objfile through dwarf2_per_objfile.
13151 (read_lexical_block_scope): Likewise.
13152 (read_call_site_scope): Likewise.
13153 (read_variable): Likewise.
13154 (dwarf2_rnglists_process): Likewise.
13155 (dwarf2_ranges_process): Likewise.
13156 (dwarf2_ranges_read): Likewise.
13157 (dwarf2_record_block_ranges): Likewise.
13158 (dwarf2_add_field): Likewise.
13159 (dwarf2_add_member_fn): Likewise.
13160 (read_structure_type): Likewise.
13161 (process_structure_scope): Likewise.
13162 (read_enumeration_type): Likewise.
13163 (read_array_type): Likewise.
13164 (read_common_block): Likewise.
13165 (read_namespace_type): Likewise.
13166 (read_namespace): Likewise.
13167 (read_module_type): Likewise.
13168 (read_tag_pointer_type): Likewise.
13169 (read_tag_ptr_to_member_type): Likewise.
13170 (read_tag_string_type): Likewise.
13171 (read_subroutine_type): Likewise.
13172 (read_typedef): Likewise.
13173 (read_base_type): Likewise.
13174 (attr_to_dynamic_prop): Likewise.
13175 (read_subrange_type): Likewise.
13176 (read_unspecified_type): Likewise.
13177 (load_partial_dies): Likewise.
13178 (read_partial_die): Likewise.
13179 (find_partial_die): Likewise.
13180 (guess_partial_die_structure_name): Likewise.
13181 (fixup_partial_die): Likewise.
13182 (read_attribute_value): Likewise.
13183 (read_addr_index_from_leb128): Likewise.
13184 (dwarf2_read_addr_index): Likewise.
13185 (dwarf2_string_attr): Likewise.
13186 (lnp_state_machine::check_line_address): Likewise.
13187 (dwarf_decode_lines_1): Likewise.
13188 (dwarf_decode_lines): Likewise.
13189 (dwarf2_start_symtab): Likewise.
13190 (var_decode_location): Likewise.
13191 (new_symbol_full): Likewise.
13192 (dwarf2_const_value_data): Likewise.
13193 (dwarf2_const_value_attr): Likewise.
13194 (dwarf2_const_value): Likewise.
13195 (die_type): Likewise.
13196 (die_containing_type): Likewise.
13197 (lookup_die_type): Likewise.
13198 (guess_full_die_structure_name): Likewise.
13199 (anonymous_struct_prefix): Likewise.
13200 (dwarf2_name): Likewise.
13201 (follow_die_ref_or_sig): Likewise.
13202 (follow_die_offset): Likewise.
13203 (follow_die_ref): Likewise.
13204 (dwarf2_fetch_die_loc_sect_off): Likewise.
13205 (dwarf2_fetch_constant_bytes): Likewise.
13206 (dwarf2_fetch_die_type_sect_off): Likewise.
13207 (dwarf2_get_die_type): Likewise.
13208 (follow_die_sig): Likewise.
13209 (decode_locdesc): Likewise.
13210 (dwarf2_per_cu_objfile): Likewise.
13211 (dwarf2_per_cu_text_offset): Likewise.
13212 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
13214 (set_die_type): Access objfile through
13215 dwarf2_per_objfile.
13217 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13219 * valprint.c (converted_character_d): Remove typedef.
13220 (DEF_VEC_O (converted_character_d)): Remove.
13221 (count_next_character): Use std::vector.
13222 (print_converted_chars_to_obstack): Likewise.
13223 (generic_printstr): Likewise.
13225 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13227 * xml-support.h (struct gdb_xml_value): Add constructor.
13228 <value>: Change type to unique_xmalloc_ptr.
13229 (gdb_xml_value_s): Remove typedef.
13230 (DEF_VEC_O (gdb_xml_value_s)): Remove.
13231 (gdb_xml_element_start_handler): Change parameter type to
13233 (xml_find_attribute): Likewise.
13234 * xml-support.c (xml_find_attribute): Change parameter type to
13235 std::vector and adjust.
13236 (gdb_xml_values_cleanup): Remove.
13237 (gdb_xml_parser::start_element): Adjust to std::vector.
13238 (xinclude_start_include): Change paraeter type to std::vector
13240 * btrace.c (check_xml_btrace_version): Likewise.
13241 (parse_xml_btrace_block): Likewise.
13242 (parse_xml_btrace_pt_config_cpu): Likewise.
13243 (parse_xml_btrace_pt): Likewise.
13244 (parse_xml_btrace_conf_bts): Likewise.
13245 (parse_xml_btrace_conf_pt): Likewise.
13246 * memory-map.c (memory_map_start_memory): Likewise.
13247 (memory_map_start_property): Likewise.
13248 * osdata.c (osdata_start_osdata): Likewise.
13249 (osdata_start_item): Likewise.
13250 (osdata_start_column): Likewise.
13251 * remote.c (start_thread): Likewise.
13252 * solib-aix.c (library_list_start_library): Likewise.
13253 (library_list_start_list): Likewise.
13254 * solib-svr4.c (library_list_start_library): Likewise.
13255 (svr4_library_list_start_list): Likewise.
13256 * solib-target.c (library_list_start_segment): Likewise.
13257 (library_list_start_section): Likewise.
13258 (library_list_start_library): Likewise.
13259 (library_list_start_list): Likewise.
13260 * tracepoint.c (traceframe_info_start_memory): Likewise.
13261 (traceframe_info_start_tvar): Likewise.
13262 * xml-syscall.c (syscall_start_syscall): Likewise.
13263 * xml-tdesc.c (tdesc_start_target): Likewise.
13264 (tdesc_start_feature): Likewise.
13265 (tdesc_start_reg): Likewise.
13266 (tdesc_start_union): Likewise.
13267 (tdesc_start_struct): Likewise.
13268 (tdesc_start_flags): Likewise.
13269 (tdesc_start_enum): Likewise.
13270 (tdesc_start_field): Likewise.
13271 (tdesc_start_enum_value): Likewise.
13272 (tdesc_start_vector): Likewise.
13274 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13276 * extension.h (struct xmethod_worker) <clone>: Remove.
13277 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
13279 (python_xmethod_worker::clone): Remove.
13280 * valops.c (find_overload_match): Use std::move instead of
13283 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13285 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
13286 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
13287 <free_xmethod_worker_data>: Remove.
13288 <get_matching_xmethod_workers>: Chance VEC to std::vector.
13289 <get_xmethod_arg_types>: Remove.
13290 <get_xmethod_result_type>: Remove.
13291 <invoke_xmethod>: Remove.
13292 * extension.c (new_xmethod_worker): Remove.
13293 (clone_xmethod_worker): Remove.
13294 (get_matching_xmethod_workers): Return void, pass std::vector by
13296 (get_xmethod_arg_types): Rename to...
13297 (xmethod_worker::get_arg_types): ... this, and adjust.
13298 (get_xmethod_result_type): Rename to...
13299 (xmethod_worker::get_result_type): ... this, and adjust.
13300 (invoke_xmethod): Remove.
13301 (free_xmethod_worker): Remove.
13302 (free_xmethod_worker_vec): Remove.
13303 * extension.h (enum ext_lang_rc): Move here from
13305 (struct xmethod_worker): Add constructor and destructor.
13308 <invoke, clone, do_get_result_type, do_get_arg_types>: New
13309 virtual pure methods.
13310 <get_arg_types, get_result_type>: New methods.
13311 (xmethod_worker_ptr): Remove typedef.
13312 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
13313 (xmethod_worker_vec): Remove typedef.
13314 (xmethod_worker_up): New typedef.
13315 (invoke_xmethod): Remove.
13316 (clone_xmethod_worker): Remove.
13317 (free_xmethod_worker): Remove.
13318 (free_xmethod_worker_vec): Remove.
13319 (get_xmethod_arg_types): Remove.
13320 (get_xmethod_result_type): Remove.
13321 * valops.c (find_method_list): Use std::vector, don't use
13322 intermediate vector.
13323 (value_find_oload_method_list): Use std::vector.
13324 (find_overload_match): Use std::vector.
13325 (find_oload_champ): Use std::vector.
13326 * value.c (value_free): Use operator delete.
13327 (value_of_xmethod): Rename to...
13328 (value_from_xmethod): ... this. Don't assign
13329 xmethod_worker::value, take rvalue-reference.
13330 (result_type_of_xmethod): Adjust.
13331 (call_xmethod): Adjust.
13332 * value.h: Include extension.h.
13333 (struct xmethod_worker): Don't forward-declare.
13334 (value_of_xmethod): Rename to...
13335 (value_from_xmethod): ... this, take rvalue-reference.
13336 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
13337 (struct python_xmethod_worker): ... this, add constructor and
13339 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
13340 (gdbpy_free_xmethod_worker_data): Rename to...
13341 (python_xmethod_worker::~python_xmethod_worker): ... this and
13343 (gdbpy_clone_xmethod_worker_data): Rename to...
13344 (python_xmethod_worker::clone): ... this and adjust.
13345 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
13347 (gdbpy_get_xmethod_arg_types): Rename to...
13348 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
13349 (gdbpy_get_xmethod_result_type): Rename to...
13350 (python_xmethod_worker::do_get_result_type): ... this and
13352 (gdbpy_invoke_xmethod): Rename to...
13353 (python_xmethod_worker::invoke): ... this and adjust.
13354 (new_python_xmethod_worker): Rename to...
13355 (python_xmethod_worker::python_xmethod_worker): ... this and
13357 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
13359 (gdbpy_free_xmethod_worker_data): Remove.
13360 (gdbpy_get_matching_xmethod_workers): Use std::vector.
13361 (gdbpy_get_xmethod_arg_types): Remove.
13362 (gdbpy_get_xmethod_result_type): Remove.
13363 (gdbpy_invoke_xmethod): Remove.
13364 * python/python.c (python_extension_ops): Remove obsolete
13367 2018-01-05 Pedro Alves <palves@redhat.com>
13370 * common/signals-state-save-restore.c
13371 (save_original_signals_state): New parameter 'quiet'. Warn if we
13372 find a custom handler preinstalled, instead of internal erroring.
13373 But only warn if !quiet.
13374 * common/signals-state-save-restore.h
13375 (save_original_signals_state): New parameter 'quiet'.
13376 * main.c (captured_main_1): Move save_original_signals_state call
13377 after option handling, and pass QUIET.
13379 2018-01-05 Pedro Alves <palves@redhat.com>
13381 * spu-tdep.c (spu_catch_start): Pass
13382 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
13384 2018-01-05 Pedro Alves <palves@redhat.com>
13387 * ada-lang.c (literal_symbol_name_matcher): New function.
13388 (ada_get_symbol_name_matcher): Use it for
13389 symbol_name_match_type::SEARCH_NAME.
13390 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
13391 it down instead of assuming symbol_name_match_type::FULL.
13392 * block.h (block_lookup_symbol): New parameter 'match_type'.
13393 * c-valprint.c (print_unpacked_pointer): Use
13394 lookup_symbol_search_name instead of lookup_symbol.
13395 * compile/compile-object-load.c (get_out_value_type): Pass down
13396 symbol_name_match_type::SEARCH_NAME.
13397 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
13398 symbol_name_match_type::FULL.
13399 * cp-support.c (cp_get_symbol_name_matcher): Handle
13400 symbol_name_match_type::SEARCH_NAME.
13401 * infrun.c (insert_exception_resume_breakpoint): Use
13402 lookup_symbol_search_name.
13403 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
13404 * psymtab.c (maintenance_check_psymtabs): Use
13405 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
13406 * stack.c (print_frame_args): Use lookup_symbol_search_name and
13407 SYMBOL_SEARCH_NAME.
13408 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
13409 if symbol_name_match_type::SEARCH_NAME.
13410 (lookup_symbol_in_language): Pass down
13411 symbol_name_match_type::FULL.
13412 (lookup_symbol_search_name): New.
13413 (lookup_language_this): Pass down
13414 symbol_name_match_type::SEARCH_NAME.
13415 (lookup_symbol_aux, lookup_local_symbol): New parameter
13416 'match_type'. Pass it down.
13417 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
13418 (lookup_symbol_search_name): New declaration.
13419 (lookup_symbol_in_block): New 'match_type' parameter.
13421 2018-01-05 Pedro Alves <palves@redhat.com>
13424 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
13426 (ada_lookup_symbol): Reimplement in terms of
13427 ada_lookup_symbol_list, bits factored out from
13428 ada_lookup_encoded_symbol.
13430 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13432 * ada-exp.y (write_object_renaming): When subscripting an array
13433 using a symbol as the index, pass the block in call to
13434 ada_lookup_encoded_symbol when looking that symbol up.
13436 2018-01-05 Jerome Guitton <guitton@adacore.com>
13438 * ada-lang.c (ada_array_length): Use ada_index_type instead of
13441 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13443 * ada-lang.c (ada_to_fixed_value_create): Add handling of
13444 the case where VALUE_LVAL (val0) is not lval_memory.
13446 2018-01-05 Xavier Roirand <roirand@adacore.com>
13448 * ada-valprint.c (print_optional_low_bound): Handle
13449 character-indexed array printing like boolean-indexed array
13452 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13454 * NEWS: Create a new section for the next release branch.
13455 Rename the section of the current branch, now that it has
13458 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13460 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
13461 * version.in: Bump version to 8.1.50.DATE-git.
13463 2018-01-03 Xavier Roirand <roirand@adacore.com>
13465 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
13467 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
13469 (default_exception_support_info) <catch_handlers_sym>: Add field.
13470 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
13471 (ada_exception_name_addr_1): Add "catch handlers" handling.
13472 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
13473 Update all callers.
13474 (create_excep_cond_exprs) <ex>: Add parameter.
13475 (re_set_exception): Update create_excep_cond_exprs call.
13476 (print_it_exception, print_one_exception, print_mention_exception)
13477 (print_recreate_exception): Add "catch handler" handling.
13478 (allocate_location_catch_handlers, re_set_catch_handlers)
13479 (check_status_catch_handlers, print_it_catch_handlers)
13480 (print_one_catch_handlers, print_mention_catch_handlers)
13481 (print_recreate_catch_handlers): New function.
13482 (catch_handlers_breakpoint_ops): New variable.
13483 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
13484 Add parameter. Add "catch handler" handling.
13485 (ada_exception_sym_name, ada_exception_breakpoint_ops):
13486 Add "catch handler" handling.
13487 (ada_exception_catchpoint_cond_string): Add "catch handler"
13489 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
13491 (catch_ada_handlers_command): New function.
13492 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
13493 operations structure.
13494 (_initialize_ada_language): Add "catch handlers" command entry.
13495 * NEWS: Document "catch handlers" feature.
13497 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13499 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
13500 account when creating the array type of the slice.
13501 (ada_value_slice): Likewise.
13503 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13505 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
13507 (create_array_type_with_stride): Add byte_stride_prop parameter.
13508 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
13509 New parameter. Update all callers in this file.
13510 (array_type_has_dynamic_stride): New function.
13511 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
13512 of arrays with dynamic byte strides.
13513 * dwarf2read.c (read_array_type): Add support for dynamic
13514 DW_AT_byte_stride attributes.
13516 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13518 * dwarf2read.c (read_unspecified_type): Treat
13519 DW_TAG_enumeration_type DIEs from Ada units as stubs.
13521 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13523 Update copyright year range in all GDB files.
13525 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13527 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
13528 and gdb/testsuite/gdb.base/step-line.c.
13530 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13532 * copyright.py (main): Dump the contents of
13533 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
13534 even if BY_HAND is empty.
13536 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13538 * top.c (print_gdb_version): Update Copyright year in version
13541 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13543 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
13545 For older changes see ChangeLog-2017.
13551 version-control: never