1 2018-09-17 Tom Tromey <tom@tromey.com>
3 * gdbthread.h (struct thread_suspend_state): Add initializers.
4 (class thread_info) <suspend>: Remove initializer.
5 * infrun.c (struct infcall_suspend_state): Add initializers.
6 (save_infcall_suspend_state): Use new.
7 (discard_infcall_suspend_state): Use delete.
9 2018-09-16 Tom Tromey <tom@tromey.com>
11 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
13 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
14 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
15 (py_varobj_iter_new): Likewise.
16 (py_varobj_get_iterator): Use gdbpy_ref.
18 2018-09-16 Tom Tromey <tom@tromey.com>
20 * python/py-threadevent.c (py_get_event_thread): Simplify.
21 * python/py-inferior.c (infpy_thread_from_thread_handle):
22 Return immediately after calling thread_to_thread_object. Use
24 (thread_to_thread_object): Set the exception on a NULL return.
26 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
28 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
30 2018-09-16 Tom Tromey <tom@tromey.com>
32 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
35 2018-09-16 Tom Tromey <tom@tromey.com>
37 * python/python-internal.h (thread_to_thread_object): Change
39 * python/py-inferior.c (thread_to_thread_object): Return a new
41 (infpy_thread_from_thread_handle): Update.
42 * python/py-infthread.c (gdbpy_selected_thread): Update.
43 * python/py-stopevent.c (create_stop_event_object): Update.
44 * python/py-threadevent.c (py_get_event_thread): Return a new
46 (py_get_event_thread): Update.
47 * python/py-event.h (py_get_event_thread): Change return type.
48 * python/py-continueevent.c (create_continue_event_object):
51 2018-09-16 Tom Tromey <tom@tromey.com>
53 * python/py-progspace.c (pspy_get_objfiles): Update.
54 * python/python-internal.h (objfile_to_objfile_object): Change
56 * python/py-newobjfileevent.c (create_new_objfile_event_object):
58 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
60 * python/python.c (gdbpy_get_current_objfile): Update.
61 (gdbpy_objfiles): Update.
62 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
64 (objfile_to_objfile_object): Return a new reference.
65 * python/py-symtab.c (stpy_get_objfile): Update.
66 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
69 2018-09-16 Tom Tromey <tom@tromey.com>
71 * python/py-inferior.c (infpy_get_progspace): Update.
72 * python/python-internal.h (pspace_to_pspace_object): Change
74 * python/py-newobjfileevent.c
75 (create_clear_objfiles_event_object): Update.
76 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
78 * python/python.c (gdbpy_get_current_progspace): Update.
79 (gdbpy_progspaces): Update.
80 * python/py-progspace.c (pspace_to_pspace_object): Return a new
82 * python/py-objfile.c (objfpy_get_progspace): Update.
83 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
86 2018-09-16 Tom Tromey <tom@tromey.com>
88 * python/lib/gdb/__init__.py (current_progspace, objfiles)
89 (solib_name, block_for_pc, find_pc_line): New functions.
90 (execute_unwinders): Update.
91 * python/py-block.c (gdbpy_block_for_pc): Remove.
92 * python/py-inferior.c (infpy_get_progspace): New function.
93 (inferior_object_getset) <progspace>: Add.
94 * python/py-progspace.c (pspy_objfiles): Rewrite.
95 (pspy_solib_name, pspy_block_for_pc)
96 (pspy_find_pc_line, pspy_is_valid): New functions.
97 (progspace_object_methods): Add entries for solib_name,
98 block_for_pc, find_pc_line, is_valid.
99 * python/python-internal.h (gdbpy_block_for_pc)
100 (build_objfiles_list): Don't declare.
101 * python/python.c: Don't include solib.h.
102 (gdbpy_solib_name, gdbpy_find_pc_line)
103 (gdbpy_get_current_progspace, build_objfiles_list)
104 (gdbpy_objfiles): Remove.
105 (GdbMethods) <current_progspace, objfiles, block_for_pc,
106 solib_name, find_pc_line>: Remove entries.
108 2018-09-16 Tom Tromey <tom@tromey.com>
110 * top.c (new_ui_command): Use GNU style for metasyntactic
112 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
114 * maint.c (maintenance_translate_address): Remove "<>" around
116 * interps.c (interpreter_exec_cmd): Use GNU style for
117 metasyntactic variables.
118 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
119 metasyntactic variables.
120 * tracepoint.c (tfind_range_command): Use GNU style for
121 metasyntactic variables.
122 (tfind_outside_command): Likewise.
123 (_initialize_tracepoint): Likewise.
124 * remote.c (extended_remote_target::create_inferior): Use GNU
125 style for metasyntactic variables.
126 * sparc64-tdep.c (adi_examine_command): Use GNU style for
127 metasyntactic variables.
128 (adi_assign_command): Likewise.
130 2018-09-16 Tom Tromey <tom@tromey.com>
132 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
133 metasyntactic variables. Print message if no disassembler options
136 2018-09-15 Tom Tromey <tom@tromey.com>
138 * infcmd.c (get_inferior_args): Return const char *.
139 * inferior.h (get_inferior_args): Return type now const.
140 * linux-tdep.c (linux_fill_prpsinfo): Update.
141 * procfs.c (procfs_target::make_corefile_notes): Update.
143 2018-09-07 Tom Tromey <tom@tromey.com>
145 * python/python.c (execute_gdb_command): Call bpstat_do_actions
148 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
150 * nios2-tdep.c (nios2_type_align): New.
151 (nios2_gdb_arch_init): Install type_align hook.
153 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
155 * eval.c (fake_method::fake_method): Call xzalloc directly for a
156 type that is neither object file owned, nor gdbarch owned.
157 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
159 (alloc_type_instance): Allocate non-objfile owned types on the
161 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
162 using TYPE_ALLOC to ensure memory is allocated on the correct
164 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
165 obstack, or the gdbarch obstack.
166 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
168 2018-09-14 Tom Tromey <tom@tromey.com>
170 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
173 2018-09-14 Tom Tromey <tom@tromey.com>
175 * nat/fork-inferior.c (get_startup_shell): Remove "static".
177 2018-09-13 Tom Tromey <tom@tromey.com>
179 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
182 2018-09-13 Tom Tromey <tom@tromey.com>
184 * exec.c (try_open_exec_file): Use std::string.
186 2018-09-13 Tom Tromey <tom@tromey.com>
188 * utils.h (gdb_bfd_errmsg): Return std::string.
189 * exec.c (exec_file_attach): Update.
190 * compile/compile-object-load.c (compile_object_load): Update.
191 * utils.c (gdb_bfd_errmsg): Return std::string.
193 2018-09-13 Tom Tromey <tom@tromey.com>
195 * procfs.c (struct procinfo_deleter): New.
196 (procinfo_up): New typedef.
197 (do_destroy_procinfo_cleanup): Remove.
198 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
200 2018-09-13 Tom Tromey <tom@tromey.com>
202 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
204 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
205 2018-09-13 Tom Tromey <tom@tromey.com>
207 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
208 (pspy_get_objfiles): New function.
209 (progspace_object_methods): New.
210 (pspace_object_type): Add tp_methods callback.
211 * python/python-internal.h (build_objfiles_list): New
213 * python/python.c (build_objfiles_list): New function.
214 (gdbpy_objfiles): Implement using build_objfiles_list.
215 * NEWS: Mention the Progspace.objfiles method.
217 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
219 * python/py-inferior.c (infpy_get_progspace): New function.
220 (inferior_object_getset): Add progspace property.
221 * NEWS: Mention the new property.
223 2018-09-13 Tom Tromey <tom@tromey.com>
226 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
228 2018-09-13 Tom Tromey <tom@tromey.com>
231 * rust-lang.c (rust_enum_variant): Now static.
232 (rust_empty_enum_p): New function.
233 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
236 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
238 * python/py-inferior.c (infpy_repr): New.
239 (inferior_object_type): Register infpy_repr.
240 * python/py-objfile.c (objfpy_repr): New.
241 (objfile_object_type): Register objfpy_repr.
243 2018-09-12 John Baldwin <jhb@FreeBSD.org>
245 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
247 2018-09-12 John Baldwin <jhb@FreeBSD.org>
249 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
252 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
254 * common/common-utils.c: Don't include '<sys/stat.h>'.
255 (is_regular_file): Move to...
256 * common/filestuff.c (is_regular_file): ... here.
257 * common/common-utils.h (is_regular_file): Move to...
258 * common/filestuff.h (is_regular_file): ... here.
260 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
262 * skip.c (debug_skip): New variable.
263 (skiplist_entry::do_skip_file_p): Add debug output.
264 (skiplist_entry::do_skip_gfile_p): Likewise.
265 (skiplist_entry::skip_function_p): Likewise.
266 (_initialize_step_skip): Create debug command.
267 * NEWS: Mention set/show debug skip.
269 2018-09-11 Xavier Roirand <roirand@adacore.com>
271 * darwin-nat.c (should_disable_startup_with_shell):
273 (darwin_nat_target::create_inferior): Add call.
275 2018-09-11 Xavier Roirand <roirand@adacore.com>
277 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
278 inf_port, msg_state>: Initialize.
279 (struct darwin_thread_info) <signaled, single_step>: Change
281 (struct darwin_thread_info) <event>: Initialize.
283 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
287 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
290 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
293 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
297 * gnulib/aclocal.m4: Regenerate.
298 * gnulib/config.in: Regenerate.
299 * gnulib/configure: Regenerate.
300 * gnulib/import/Makefile.am: Update.
301 * gnulib/import/Makefile.in: Update.
302 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
303 * gnulib/import/_Noreturn.h: ... this.
304 * gnulib/import/alloca.in.h: Update.
305 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
306 * gnulib/import/arg-nonnull.h: ... this.
307 * gnulib/import/assure.h: Update.
308 * gnulib/import/at-func.c: Update.
309 * gnulib/import/basename-lgpl.c: Update.
310 * gnulib/import/extra/snippet/c++defs.h: Rename to...
311 * gnulib/import/c++defs.h: ... this.
312 * gnulib/import/canonicalize-lgpl.c: Update.
313 * gnulib/import/cdefs.h: Update.
314 * gnulib/import/chdir-long.c: Update.
315 * gnulib/import/chdir-long.h: Update.
316 * gnulib/import/cloexec.c: Update.
317 * gnulib/import/cloexec.h: Update.
318 * gnulib/import/close.c: Update.
319 * gnulib/import/closedir.c: Update.
320 * gnulib/import/config.charset: Update.
321 * gnulib/import/dirent-private.h: Update.
322 * gnulib/import/dirent.in.h: Update.
323 * gnulib/import/dirfd.c: Update.
324 * gnulib/import/dirname-lgpl.c: Update.
325 * gnulib/import/dirname.h: Update.
326 * gnulib/import/dosname.h: Update.
327 * gnulib/import/dup-safer-flag.c: Update.
328 * gnulib/import/dup-safer.c: Update.
329 * gnulib/import/dup.c: Update.
330 * gnulib/import/dup2.c: Update.
331 * gnulib/import/errno.in.h: Update.
332 * gnulib/import/error.c: Update.
333 * gnulib/import/error.h: Update.
334 * gnulib/import/exitfail.c: Update.
335 * gnulib/import/exitfail.h: Update.
336 * gnulib/import/extra/update-copyright: Update.
337 * gnulib/import/fchdir.c: Update.
338 * gnulib/import/fcntl.c: Update.
339 * gnulib/import/fcntl.in.h: Update.
340 * gnulib/import/fd-hook.c: Update.
341 * gnulib/import/fd-hook.h: Update.
342 * gnulib/import/fd-safer-flag.c: Update.
343 * gnulib/import/fd-safer.c: Update.
344 * gnulib/import/fdopendir.c: Update.
345 * gnulib/import/filename.h: Update.
346 * gnulib/import/filenamecat-lgpl.c: Update.
347 * gnulib/import/filenamecat.h: Update.
348 * gnulib/import/flexmember.h: Update.
349 * gnulib/import/float+.h: Update.
350 * gnulib/import/float.c: Update.
351 * gnulib/import/float.in.h: Update.
352 * gnulib/import/fnmatch.c: Update.
353 * gnulib/import/fnmatch.in.h: Update.
354 * gnulib/import/fnmatch_loop.c: Update.
355 * gnulib/import/fpucw.h: Update.
356 * gnulib/import/frexp.c: Update.
357 * gnulib/import/frexpl.c: Update.
358 * gnulib/import/fstat.c: Update.
359 * gnulib/import/fstatat.c: Update.
360 * gnulib/import/getcwd-lgpl.c: Update.
361 * gnulib/import/getcwd.c: Update.
362 * gnulib/import/getdtablesize.c: Update.
363 * gnulib/import/getlogin_r.c: Update.
364 * gnulib/import/getprogname.c: Update.
365 * gnulib/import/getprogname.h: Update.
366 * gnulib/import/gettext.h: Update.
367 * gnulib/import/gettimeofday.c: Update.
368 * gnulib/import/glob-libc.h: Update.
369 * gnulib/import/glob.c: Update.
370 * gnulib/import/glob.in.h: Update.
371 * gnulib/import/glob_internal.h: Update.
372 * gnulib/import/glob_pattern_p.c: Update.
373 * gnulib/import/globfree.c: Update.
374 * gnulib/import/hard-locale.c: Update.
375 * gnulib/import/hard-locale.h: Update.
376 * gnulib/import/intprops.h: Update.
377 * gnulib/import/inttypes.in.h: Update.
378 * gnulib/import/isnan.c: Update.
379 * gnulib/import/isnand-nolibm.h: Update.
380 * gnulib/import/isnand.c: Update.
381 * gnulib/import/isnanl-nolibm.h: Update.
382 * gnulib/import/isnanl.c: Update.
383 * gnulib/import/itold.c: Update.
384 * gnulib/import/libc-config.h: Update.
385 * gnulib/import/limits.in.h: Update.
386 * gnulib/import/localcharset.c: Update.
387 * gnulib/import/localcharset.h: Update.
388 * gnulib/import/localtime-buffer.c: Update.
389 * gnulib/import/localtime-buffer.h: Update.
390 * gnulib/import/lstat.c: Update.
391 * gnulib/import/m4/00gnulib.m4: Update.
392 * gnulib/import/m4/__inline.m4: Update.
393 * gnulib/import/m4/absolute-header.m4: Update.
394 * gnulib/import/m4/alloca.m4: Update.
395 * gnulib/import/m4/builtin-expect.m4: Update.
396 * gnulib/import/m4/canonicalize.m4: Update.
397 * gnulib/import/m4/chdir-long.m4: Update.
398 * gnulib/import/m4/close.m4: Update.
399 * gnulib/import/m4/closedir.m4: Update.
400 * gnulib/import/m4/configmake.m4: Update.
401 * gnulib/import/m4/d-ino.m4: Update.
402 * gnulib/import/m4/d-type.m4: Update.
403 * gnulib/import/m4/dirent_h.m4: Update.
404 * gnulib/import/m4/dirfd.m4: Update.
405 * gnulib/import/m4/dirname.m4: Update.
406 * gnulib/import/m4/double-slash-root.m4: Update.
407 * gnulib/import/m4/dup.m4: Update.
408 * gnulib/import/m4/dup2.m4: Update.
409 * gnulib/import/m4/eealloc.m4: Update.
410 * gnulib/import/m4/environ.m4: Update.
411 * gnulib/import/m4/errno_h.m4: Update.
412 * gnulib/import/m4/error.m4: Update.
413 * gnulib/import/m4/exponentd.m4: Update.
414 * gnulib/import/m4/exponentl.m4: Update.
415 * gnulib/import/m4/extensions.m4: Update.
416 * gnulib/import/m4/extern-inline.m4: Update.
417 * gnulib/import/m4/fchdir.m4: Update.
418 * gnulib/import/m4/fcntl-o.m4: Update.
419 * gnulib/import/m4/fcntl.m4: Update.
420 * gnulib/import/m4/fcntl_h.m4: Update.
421 * gnulib/import/m4/fdopendir.m4: Update.
422 * gnulib/import/m4/filenamecat.m4: Update.
423 * gnulib/import/m4/flexmember.m4: Update.
424 * gnulib/import/m4/float_h.m4: Update.
425 * gnulib/import/m4/fnmatch.m4: Update.
426 * gnulib/import/m4/fnmatch_h.m4: Update.
427 * gnulib/import/m4/fpieee.m4: Update.
428 * gnulib/import/m4/frexp.m4: Update.
429 * gnulib/import/m4/frexpl.m4: Update.
430 * gnulib/import/m4/fstat.m4: Update.
431 * gnulib/import/m4/fstatat.m4: Update.
432 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
433 * gnulib/import/m4/getcwd-path-max.m4: Update.
434 * gnulib/import/m4/getcwd.m4: Update.
435 * gnulib/import/m4/getdtablesize.m4: Update.
436 * gnulib/import/m4/getlogin.m4: Update.
437 * gnulib/import/m4/getlogin_r.m4: Update.
438 * gnulib/import/m4/getpagesize.m4: Update.
439 * gnulib/import/m4/getprogname.m4: Update.
440 * gnulib/import/m4/gettimeofday.m4: Update.
441 * gnulib/import/m4/glibc21.m4: Update.
442 * gnulib/import/m4/glob.m4: Update.
443 * gnulib/import/m4/glob_h.m4: Update.
444 * gnulib/import/m4/gnulib-cache.m4: Update.
445 * gnulib/import/m4/gnulib-common.m4: Update.
446 * gnulib/import/m4/gnulib-comp.m4: Update.
447 * gnulib/import/m4/gnulib-tool.m4: Update.
448 * gnulib/import/m4/hard-locale.m4: Update.
449 * gnulib/import/m4/include_next.m4: Update.
450 * gnulib/import/m4/inttypes-pri.m4: Update.
451 * gnulib/import/m4/inttypes.m4: Update.
452 * gnulib/import/m4/isnand.m4: Update.
453 * gnulib/import/m4/isnanl.m4: Update.
454 * gnulib/import/m4/largefile.m4: Update.
455 * gnulib/import/m4/limits-h.m4: Update.
456 * gnulib/import/m4/localcharset.m4: Update.
457 * gnulib/import/m4/locale-fr.m4: Update.
458 * gnulib/import/m4/locale-ja.m4: Update.
459 * gnulib/import/m4/locale-zh.m4: Update.
460 * gnulib/import/m4/localtime-buffer.m4: Update.
461 * gnulib/import/m4/longlong.m4: Update.
462 * gnulib/import/m4/lstat.m4: Update.
463 * gnulib/import/m4/malloc.m4: Update.
464 * gnulib/import/m4/malloca.m4: Update.
465 * gnulib/import/m4/math_h.m4: Update.
466 * gnulib/import/m4/mbrtowc.m4: Update.
467 * gnulib/import/m4/mbsinit.m4: Update.
468 * gnulib/import/m4/mbsrtowcs.m4: Update.
469 * gnulib/import/m4/mbstate_t.m4: Update.
470 * gnulib/import/m4/memchr.m4: Update.
471 * gnulib/import/m4/memmem.m4: Update.
472 * gnulib/import/m4/mempcpy.m4: Update.
473 * gnulib/import/m4/memrchr.m4: Update.
474 * gnulib/import/m4/mkdir.m4: Update.
475 * gnulib/import/m4/mkstemp.m4: Update.
476 * gnulib/import/m4/mmap-anon.m4: Update.
477 * gnulib/import/m4/mode_t.m4: Update.
478 * gnulib/import/m4/msvc-inval.m4: Update.
479 * gnulib/import/m4/msvc-nothrow.m4: Update.
480 * gnulib/import/m4/multiarch.m4: Update.
481 * gnulib/import/m4/nocrash.m4: Update.
482 * gnulib/import/m4/off_t.m4: Update.
483 * gnulib/import/m4/onceonly.m4: Update.
484 * gnulib/import/m4/open-cloexec.m4: Update.
485 * gnulib/import/m4/open.m4: Update.
486 * gnulib/import/m4/openat.m4: Update.
487 * gnulib/import/m4/opendir.m4: Update.
488 * gnulib/import/m4/pathmax.m4: Update.
489 * gnulib/import/m4/rawmemchr.m4: Update.
490 * gnulib/import/m4/readdir.m4: Update.
491 * gnulib/import/m4/readlink.m4: Update.
492 * gnulib/import/m4/realloc.m4: Update.
493 * gnulib/import/m4/rename.m4: Update.
494 * gnulib/import/m4/rewinddir.m4: Update.
495 * gnulib/import/m4/rmdir.m4: Update.
496 * gnulib/import/m4/save-cwd.m4: Update.
497 * gnulib/import/m4/secure_getenv.m4: Update.
498 * gnulib/import/m4/setenv.m4: Update.
499 * gnulib/import/m4/signal_h.m4: Update.
500 * gnulib/import/m4/ssize_t.m4: Update.
501 * gnulib/import/m4/stat-time.m4: Update.
502 * gnulib/import/m4/stat.m4: Update.
503 * gnulib/import/m4/std-gnu11.m4: Update.
504 * gnulib/import/m4/stdbool.m4: Update.
505 * gnulib/import/m4/stddef_h.m4: Update.
506 * gnulib/import/m4/stdint.m4: Update.
507 * gnulib/import/m4/stdio_h.m4: Update.
508 * gnulib/import/m4/stdlib_h.m4: Update.
509 * gnulib/import/m4/strchrnul.m4: Update.
510 * gnulib/import/m4/strdup.m4: Update.
511 * gnulib/import/m4/strerror.m4: Update.
512 * gnulib/import/m4/string_h.m4: Update.
513 * gnulib/import/m4/strstr.m4: Update.
514 * gnulib/import/m4/strtok_r.m4: Update.
515 * gnulib/import/m4/sys_socket_h.m4: Update.
516 * gnulib/import/m4/sys_stat_h.m4: Update.
517 * gnulib/import/m4/sys_time_h.m4: Update.
518 * gnulib/import/m4/sys_types_h.m4: Update.
519 * gnulib/import/m4/tempname.m4: Update.
520 * gnulib/import/m4/time_h.m4: Update.
521 * gnulib/import/m4/unistd-safer.m4: Update.
522 * gnulib/import/m4/unistd_h.m4: Update.
523 * gnulib/import/m4/warn-on-use.m4: Update.
524 * gnulib/import/m4/wchar_h.m4: Update.
525 * gnulib/import/m4/wchar_t.m4: Update.
526 * gnulib/import/m4/wctype_h.m4: Update.
527 * gnulib/import/m4/wint_t.m4: Update.
528 * gnulib/import/malloc.c: Update.
529 * gnulib/import/malloc/scratch_buffer.h: Update.
530 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
531 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
532 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
533 * gnulib/import/malloca.c: Update.
534 * gnulib/import/malloca.h: Update.
535 * gnulib/import/malloca.valgrind: Update.
536 * gnulib/import/math.in.h: Update.
537 * gnulib/import/mbrtowc.c: Update.
538 * gnulib/import/mbsinit.c: Update.
539 * gnulib/import/mbsrtowcs-impl.h: Update.
540 * gnulib/import/mbsrtowcs-state.c: Update.
541 * gnulib/import/mbsrtowcs.c: Update.
542 * gnulib/import/memchr.c: Update.
543 * gnulib/import/memmem.c: Update.
544 * gnulib/import/mempcpy.c: Update.
545 * gnulib/import/memrchr.c: Update.
546 * gnulib/import/mkdir.c: Update.
547 * gnulib/import/mkstemp.c: Update.
548 * gnulib/import/msvc-inval.c: Update.
549 * gnulib/import/msvc-inval.h: Update.
550 * gnulib/import/msvc-nothrow.c: Update.
551 * gnulib/import/msvc-nothrow.h: Update.
552 * gnulib/import/open.c: Update.
553 * gnulib/import/openat-die.c: Update.
554 * gnulib/import/openat-priv.h: Update.
555 * gnulib/import/openat-proc.c: Update.
556 * gnulib/import/openat.c: Update.
557 * gnulib/import/openat.h: Update.
558 * gnulib/import/opendir.c: Update.
559 * gnulib/import/pathmax.h: Update.
560 * gnulib/import/pipe-safer.c: Update.
561 * gnulib/import/rawmemchr.c: Update.
562 * gnulib/import/readdir.c: Update.
563 * gnulib/import/readlink.c: Update.
564 * gnulib/import/realloc.c: Update.
565 * gnulib/import/ref-add.sin: Update.
566 * gnulib/import/ref-del.sin: Update.
567 * gnulib/import/rename.c: Update.
568 * gnulib/import/rewinddir.c: Update.
569 * gnulib/import/rmdir.c: Update.
570 * gnulib/import/same-inode.h: Update.
571 * gnulib/import/save-cwd.c: Update.
572 * gnulib/import/save-cwd.h: Update.
573 * gnulib/import/scratch_buffer.h: Update.
574 * gnulib/import/secure_getenv.c: Update.
575 * gnulib/import/setenv.c: Update.
576 * gnulib/import/signal.in.h: Update.
577 * gnulib/import/stat-time.c: Update.
578 * gnulib/import/stat-time.h: Update.
579 * gnulib/import/stat-w32.c: Update.
580 * gnulib/import/stat-w32.h: Update.
581 * gnulib/import/stat.c: Update.
582 * gnulib/import/stdbool.in.h: Update.
583 * gnulib/import/stddef.in.h: Update.
584 * gnulib/import/stdint.in.h: Update.
585 * gnulib/import/stdio.in.h: Update.
586 * gnulib/import/stdlib.in.h: Update.
587 * gnulib/import/str-two-way.h: Update.
588 * gnulib/import/strchrnul.c: Update.
589 * gnulib/import/strdup.c: Update.
590 * gnulib/import/streq.h: Update.
591 * gnulib/import/strerror-override.c: Update.
592 * gnulib/import/strerror-override.h: Update.
593 * gnulib/import/strerror.c: Update.
594 * gnulib/import/string.in.h: Update.
595 * gnulib/import/stripslash.c: Update.
596 * gnulib/import/strnlen1.c: Update.
597 * gnulib/import/strnlen1.h: Update.
598 * gnulib/import/strstr.c: Update.
599 * gnulib/import/strtok_r.c: Update.
600 * gnulib/import/sys_stat.in.h: Update.
601 * gnulib/import/sys_time.in.h: Update.
602 * gnulib/import/sys_types.in.h: Update.
603 * gnulib/import/tempname.c: Update.
604 * gnulib/import/tempname.h: Update.
605 * gnulib/import/time.in.h: Update.
606 * gnulib/import/unistd--.h: Update.
607 * gnulib/import/unistd-safer.h: Update.
608 * gnulib/import/unistd.in.h: Update.
609 * gnulib/import/unsetenv.c: Update.
610 * gnulib/import/verify.h: Update.
611 * gnulib/import/extra/snippet/warn-on-use.h: Update.
612 * gnulib/import/wchar.in.h: Update.
613 * gnulib/import/wctype.in.h: Update.
614 * gnulib/import/xalloc-oversized.h: Update.
615 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
616 "53e2c179f26a890fa6685af4b6c1397ee370433b".
618 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
620 * record-btrace.c (get_thread_current_frame): Remove
623 2018-09-10 Jerome Guitton <guitton@adacore.com>
625 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
626 with check_tag to 1 if and only if the type is tagged and the
627 component being searched cannot been found in the current
628 view. Otherwise, always call ada_to_fixed_type with
631 2018-09-10 Xavier Roirand <roirand@adacore.com>
633 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
635 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
636 * ada-varobj.c (ada_varobj_get_number_of_children,
637 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
639 2018-09-10 Xavier Roirand <roirand@adacore.com>
641 * ada-valprint.c (ada_value_print): Use type instead of
644 2018-09-10 Xavier Roirand <roirand@adacore.com>
646 * ada-lang.c (ada_value_subscript): Handle case when parameter is
647 an array of access to unconstrained array.
649 2018-09-10 Xavier Roirand <roirand@adacore.com>
651 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
652 (ada_check_typedef): Use it.
654 2018-09-10 Xavier Roirand <roirand@adacore.com>
656 * ada-varobj.c (ada_varobj_describe_struct_child)
657 (ada_varobj_describe_child): Handle union case like struct one.
659 2018-09-10 Tom Tromey <tom@tromey.com>
662 * python/python.c (_initialize_python): Make example in "python"
663 help work in Python 3.
665 2018-09-10 Eli Zaretskii <eliz@gnu.org>
667 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
668 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
669 $(EXEEXT) to the script, as it is not a program.
671 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
673 * python/py-prettyprint.c (pretty_print_one_value): Return
675 (print_string_repr): Adjust.
676 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
677 * python/python-internal.h (apply_varobj_pretty_printer): Return
679 * varobj.c (varobj_value_get_print_value): Adjust.
681 2018-09-08 Tom Tromey <tom@tromey.com>
684 * python/py-prettyprint.c (pretty_print_one_value): Check for
687 2018-09-08 Joel Brobecker <brobecker@adacore.com>
689 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
690 replace_operator_with_call.
692 2018-09-08 Joel Brobecker <brobecker@adacore.com>
694 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
696 2018-09-08 Joel Brobecker <brobecker@adacore.com>
698 * ada-typeprint.c (print_range): Print the bounds using TYPE
699 rather than its TYPE_TARGET_TYPE.
701 2018-09-08 Joel Brobecker <brobecker@adacore.com>
703 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
704 call to ada_to_fixed_value_create.
706 2018-09-08 Jerome Guitton <guitton@adacore.com>
708 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
710 2018-09-08 Joel Brobecker <brobecker@adacore.com>
712 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
715 2018-09-08 Joel Brobecker <brobecker@adacore.com>
717 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
718 Move update of loop variable "fi".
720 2018-09-08 Joel Brobecker <brobecker@adacore.com>
722 * ada-lang.c (value_assign_to_component): In the case of
723 big-endian targets, extract the bits of the given VAL
724 using an src_offset of zero if container is not a scalar.
726 2018-09-06 Simon Ser <contact@emersion.fr>
729 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
730 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
731 * fbsd-tdep.c (fbsd_make_note_desc): New.
732 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
733 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
734 * target.h (enum target_object) Add FreeBSD-specific
735 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
737 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
739 * compile/compile-c.h (generate_c_for_variable_locations):
740 Change reference to pointer.
741 * compile/compile-c-support.c (compile_program) <compute>:
743 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
744 (generate_c_for_for_one_variable): Likewise
745 (generate_c_for_variable_locations): Likewise
746 * compile/compile-c-types.c (compile_c_instance::convert_type):
748 * compile/compile-cplus-symbols.c (convert_one_symbol):
749 std::move the scope passed to enter_scope.
750 * compile/compile-cplus-types.c
751 (compile_cplus_instance::enter_scope): Make parameter
753 (compile_cplus_instance::new_scope): Change reference to
755 (compile_cplus_instance::convert_type): Likewise
756 (compile_cplus_convert_typedef): std::move the scope passed to
758 (compile_cplus_convert_struct_or_union): Likewise.
759 (compile_cplus_convert_enum): Likewise.
760 (compile_cplus_convert_namespace): Likewise.
761 * compile/compile-cplus.h (compile_cplus_instance)
762 <enter_scope>: Make parameter rvalue-reference.
763 * compile/compile-internal.h (compile_instance)
764 <get_cached_type>: Likewise
765 * compile/compile-loc2c.c (push): Likewise
769 (print_label): Likewise
770 (pushf_register_address): Likewise
771 (pushf_register): Likewise
772 (do_compile_dwarf_expr_to_c): Likewise
773 (compile_dwarf_expr_to_c): Likewise
774 (compile_dwarf_bounds_to_c): Likewise
775 * compile/compile.c (compile_instance::get_cached_type):
777 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
778 (compile_dwarf_bounds_to_c): Likewise
779 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
780 (dwarf2_compile_property_to_c): Likewise
781 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
782 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
785 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
787 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
788 * tui/tui-data.c (init_content_element): Don't initialize it.
790 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
792 * tui/tui-data.h (struct tui_win_info)
793 <detail::opaque>: Remove.
794 * tui/tui-data.c (init_win_info): Remove assignment.
796 2018-09-05 Tom Tromey <tom@tromey.com>
798 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
800 * target-float.c (host_float_ops<T>::to_string)
801 (host_float_ops<T>::from_string): Use
802 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
803 * configure: Rebuild.
805 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
807 * printcmd.c (printf_c_string): Use
808 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
809 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
811 2018-09-05 Tom Tromey <tom@tromey.com>
813 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
815 2018-09-05 Tom de Vries <tdevries@suse.de>
817 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
818 with resolve_abstract_p == true.
819 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
820 defaulting to false. Propagate resolve_abstract_p to
821 dwarf2_fetch_die_loc_sect_off.
822 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
823 parameter, defaulting to false.
824 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
825 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
827 * dwarf2read.h (struct die_info): Forward-declare.
828 (die_info_ptr): New typedef.
829 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
831 2018-09-05 Joel Brobecker <brobecker@adacore.com>
835 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
836 Pedro Alves <palves@redhat.com>
838 * gnulib/Makefile.in (aclocal_m4_deps): Move to
839 "aclocal-m4-deps.mk". Include file here.
840 $(srcdir)/aclocal.m4: Add "configure.ac".
841 * gnulib/aclocal-m4-deps.mk: New file.
842 * gnulib/update-gnulib.sh: Automatically update
843 "aclocal-m4-deps.mk".
845 2018-09-04 Tom Tromey <tom@tromey.com>
847 * configure: Rebuild.
848 * configure.ac: Remove multi-ice code.
850 2018-09-04 Tom Tromey <tom@tromey.com>
852 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
855 2018-09-04 Tom Tromey <tom@tromey.com>
857 * Makefile.in (printcmd.o, target-float.o): Remove.
858 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
860 2018-09-04 Tom Tromey <tom@tromey.com>
862 * gnulib/Makefile.in: Remove obsolete comment.
863 * Makefile.in: Remove obsolete comment.
865 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
867 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
870 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
872 * riscv-tdep.c: Add 'prologue-value.h' include.
873 (struct riscv_unwind_cache): New struct.
874 (riscv_debug_unwinder): New global.
875 (riscv_scan_prologue): Update arguments, capture register details
877 (riscv_skip_prologue): Reformat arguments line, move end of
878 prologue calculation into riscv_scan_prologue.
879 (riscv_frame_cache): Update return type, create
880 riscv_unwind_cache, scan the prologue, and fill in remaining cache
882 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
883 (riscv_frame_prev_register): Use the trad_frame within the
885 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
888 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
890 * trad-frame.h (trad_frame_set_realreg): Declare.
891 (trad_frame_set_addr): Declare.
892 * trad-frame.c (trad_frame_set_realreg): Define new function.
893 (trad_frame_set_addr): Define new function.
894 (trad_frame_set_reg_realreg): Use new function.
895 (trad_frame_set_reg_addr): Use new function.
897 2018-09-01 Keith Seitz <keiths@redhat.com>
899 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
900 pulongest instead of "%lld".
901 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
904 2018-08-31 Tom Tromey <tom@tromey.com>
906 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
909 2018-08-31 Pedro Alves <palves@redhat.com>
911 * gdbarch.h: Regenerate.
913 2018-08-31 Pedro Alves <palves@redhat.com>
915 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
916 * target.h (Hardware watchpoint interfaces): Describe
917 continuable/steppable/non-steppable watchpoints.
918 * gdbarch.h, gdbarch.c: Regenerate.
920 2018-08-31 Pedro Alves <palves@redhat.com>
922 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
925 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
926 * target.h (target_ops::have_continuable_watchpoint): Delete.
927 (target_have_continuable_watchpoint): Delete.
928 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
929 * target-delegates.c: Regenerate.
931 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
933 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
934 the files present in "gnulib/import/m4/".
936 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
938 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
939 c.sw, c.swsp, and c.sdsp.
941 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
943 * riscv-tdep.c (struct riscv_inferior_data): Delete.
944 (riscv_read_misa_reg): Don't cache value read into inferior data.
945 (riscv_new_inferior_data): Delete.
946 (riscv_inferior_data_cleanup): Delete.
947 (riscv_inferior_data): Delete.
948 (riscv_invalidate_inferior_data): Delete.
949 (_initialize_riscv_tdep): Remove initialisation of inferior data.
951 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
953 * compile/compile-cplus-types.c
954 (compile_cplus_instance::leave_scope): Take the address of scope
956 (compile_cplus_instance::convert_qualified_base): Compare quals
959 2018-08-30 Keith Seitz <keiths@redhat.com>
961 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
962 Use "%s" and host_address_to_string instead of "%p" in printf.
964 2018-08-29 Keith Seitz <keiths@redhat.com>
966 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
967 and compile-cplus-types.c.
968 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
969 * c-lang.c (cplus_language_defn): Set C++ compile functions.
970 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
972 * compile/compile-c-support.c: Include compile-cplus.h.
973 (load_libcompile): Templatize.
974 (get_compile_context): "New" function.
975 (c_get_compile_context): Use get_compile_context.
976 (cplus_get_compile_context): New function.
977 (cplus_push_user_expression, cplus_pop_user_expression)
978 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
979 (cplus_compute_program): Define new structs/functions.
980 * compile/compile-cplus-symmbols.c: New file.
981 * compile/compile-cplus-types.c: New file.
982 * compile/compile-cplus.h: New file.
983 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
985 * compile/compile-object-load.c (get_out_value_type): Use
986 strncmp_iw when comparing symbol names.
987 (compile_object_load): Add mst_bss and mst_data.
988 * compile/compile.c (_initialize_compile): Remove
989 -Wno-implicit-function-declaration from `compile_args'.
990 * compile/gcc-cp-plugin.h: New file.
991 * NEWS: Mention C++ compile support and new debug options.
993 2018-08-29 Keith Seitz <keiths@redhat.com>
995 * linespec.c (collect_info::add_symbol): Make virtual.
996 (struct symbol_searcher_collect_info): New struct.
997 (symbol_searcher::find_all_symbols): New method.
998 * symtab.h (class symbol_searcher): New class.
1000 2018-08-29 Keith Seitz <keiths@redhat.com>
1002 * linespec.c (struct linespec) <function_symbols, label_symbols>:
1003 Change to vector of block_symbol. Update all users.
1004 (struct collect_info) <symbols>: Likewise.
1005 (collect_info::add_symbol): Take block_symbol as argument.
1007 (decode_compound_collector) <m_symbols>: Change type to vector
1008 of block_symbol. Update all users.
1009 (decode_compound_collector::operator ()): Change parameter type
1011 (find_method, find_function_symbols, find_linespec_symbols)
1012 (find_label_symbols_in_block, find_label_symbols): Change symbol
1013 vectors to block_symbol vectors.
1014 * symtab.h (symbol_found_callback_ftype): Change parameter type to
1017 2018-08-29 Keith Seitz <keiths@redhat.com>
1019 * linespec.c (symbolp): Remove typedef and VEC definitions.
1020 (bound_minimal_symbol_d): Likewise.
1022 2018-08-29 Keith Seitz <keiths@redhat.com>
1024 * linespec.c (decode_compound_collector::decode_compound_collector):
1025 Remove initialization for `m_symtabs'.
1026 (decode_compound_collector::release_symbols): Change return type
1027 to std::vector. Update all callers.
1028 (class decode_compound_collector) <m_symbols>: Change type to
1030 (lookup_prefix_sym): Change return type to std::vector. Update all
1032 (compare_symbols): Remove.
1033 (std_compare_symbols): Rename to `compare_symbols'.
1034 (find_method): Change `sym_classes' parameter to std::vector.
1035 Update all callers. Use std::sort to sort sym_classes.
1036 (find_linespec_symbols): Remove cleanup.
1038 2018-08-29 Keith Seitz <keiths@redhat.com>
1040 * linespec.c (struct linespec) <minimal_symbols>: Change type to
1041 std::vector. Update all users.
1042 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
1043 (struct collect_info) <minimal_symbols>: Likewise.
1044 (compare_msymbols): Return bool. Change parameters to const
1045 bound_minimal_symbol references.
1046 (find_method, find_function_symbols, find_linespec_symbols): Change
1047 `minsyms' parameter to std::vector. Update all callers.
1049 2018-08-29 Keith Seitz <keiths@redhat.com>
1051 * linespec.c (struct linespec) <label_symbols>: Change type to
1052 std::vector. Update all users.
1053 (find_label_symbols_in_block): Change `result' parameter to
1054 std::vector. Update all callers.
1055 (find_label_symbols): Return std::vector. Update all callers.
1057 2018-08-29 Keith Seitz <keiths@redhat.com>
1059 * linespec.c (struct linespec) <function_symbols>: Change type to
1060 std::vector. Update all users.
1061 (struct collect_info) <function_symbols>: Likewise.
1062 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
1063 (std_compare_symbols): New function.
1064 (find_method, find_function_symbols, find_linespec_symbols)
1065 (find_label_symbols_in_block): Change `symbols' parameter to
1066 std::vector. Update all callers.
1067 (find_label_symbols): Likewise for `function_symbols' and
1070 2018-08-29 Keith Seitz <keiths@redhat.com>
1072 * linespec.c (symtab_vector_up): Define.
1073 (struct linespec) <file_symtabs>: Change type to std::vector *.
1075 (struct collect_info) <file_symtabs>: Likewise.
1076 (collect_symtabs_from_filename): Return symtab_vector_up.
1078 (decode_objc): Remove cleanup.
1079 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
1080 (symtab_collector::release_symtabs): Return symtab_vector_up.
1082 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
1084 (collect_symtabs_from_filename, symtabs_from_filename): Return
1085 symtab_vector_up. Update all callers.
1087 2018-08-29 Tom Tromey <tom@tromey.com>
1089 * csky-tdep.c (csky_analyze_prologue): Use
1090 core_addr_to_string_nz.
1092 2018-08-29 Tom Tromey <tom@tromey.com>
1094 * windows-nat.c (struct xlate_exception) <them>: Change type to
1096 (xlate): Fix formatting. Remove last entry.
1097 (struct xlate_exception, xlate): Comment out.
1098 (windows_nat_target::resume): Use ranged for.
1100 2018-08-29 Jim Wilson <jimw@sifive.com>
1102 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
1103 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
1105 (riscv_linux_nat_target::store_registers): Likewise.
1107 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
1111 * gnulib/aclocal.m4: Regenerate.
1112 * gnulib/config.in: Regenerate.
1113 * gnulib/configure: Regenerate.
1114 * gnulib/import/Makefile.am: Update.
1115 * gnulib/import/Makefile.in: Update.
1116 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
1117 * gnulib/import/_Noreturn.h: ... this.
1118 * gnulib/import/alloca.in.h: Update.
1119 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
1120 * gnulib/import/arg-nonnull.h: ... this.
1121 * gnulib/import/assure.h: Update.
1122 * gnulib/import/at-func.c: Update.
1123 * gnulib/import/basename-lgpl.c: Update.
1124 * gnulib/import/extra/snippet/c++defs.h: Rename to...
1125 * gnulib/import/c++defs.h: ... this.
1126 * gnulib/import/canonicalize-lgpl.c: Update.
1127 * gnulib/import/cdefs.h: Update.
1128 * gnulib/import/chdir-long.c: Update.
1129 * gnulib/import/chdir-long.h: Update.
1130 * gnulib/import/cloexec.c: Update.
1131 * gnulib/import/cloexec.h: Update.
1132 * gnulib/import/close.c: Update.
1133 * gnulib/import/closedir.c: Update.
1134 * gnulib/import/config.charset: Update.
1135 * gnulib/import/dirent-private.h: Update.
1136 * gnulib/import/dirent.in.h: Update.
1137 * gnulib/import/dirfd.c: Update.
1138 * gnulib/import/dirname-lgpl.c: Update.
1139 * gnulib/import/dirname.h: Update.
1140 * gnulib/import/dosname.h: Update.
1141 * gnulib/import/dup-safer-flag.c: Update.
1142 * gnulib/import/dup-safer.c: Update.
1143 * gnulib/import/dup.c: Update.
1144 * gnulib/import/dup2.c: Update.
1145 * gnulib/import/errno.in.h: Update.
1146 * gnulib/import/error.c: Update.
1147 * gnulib/import/error.h: Update.
1148 * gnulib/import/exitfail.c: Update.
1149 * gnulib/import/exitfail.h: Update.
1150 * gnulib/import/extra/update-copyright: Update.
1151 * gnulib/import/fchdir.c: Update.
1152 * gnulib/import/fcntl.c: Update.
1153 * gnulib/import/fcntl.in.h: Update.
1154 * gnulib/import/fd-hook.c: Update.
1155 * gnulib/import/fd-hook.h: Update.
1156 * gnulib/import/fd-safer-flag.c: Update.
1157 * gnulib/import/fd-safer.c: Update.
1158 * gnulib/import/fdopendir.c: Update.
1159 * gnulib/import/filename.h: Update.
1160 * gnulib/import/filenamecat-lgpl.c: Update.
1161 * gnulib/import/filenamecat.h: Update.
1162 * gnulib/import/flexmember.h: Update.
1163 * gnulib/import/float+.h: Update.
1164 * gnulib/import/float.c: Update.
1165 * gnulib/import/float.in.h: Update.
1166 * gnulib/import/fnmatch.c: Update.
1167 * gnulib/import/fnmatch.in.h: Update.
1168 * gnulib/import/fnmatch_loop.c: Update.
1169 * gnulib/import/fpucw.h: Update.
1170 * gnulib/import/frexp.c: Update.
1171 * gnulib/import/frexpl.c: Update.
1172 * gnulib/import/fstat.c: Update.
1173 * gnulib/import/fstatat.c: Update.
1174 * gnulib/import/getcwd-lgpl.c: Update.
1175 * gnulib/import/getcwd.c: Update.
1176 * gnulib/import/getdtablesize.c: Update.
1177 * gnulib/import/getlogin_r.c: Update.
1178 * gnulib/import/getprogname.c: Update.
1179 * gnulib/import/getprogname.h: Update.
1180 * gnulib/import/gettext.h: Update.
1181 * gnulib/import/gettimeofday.c: Update.
1182 * gnulib/import/glob-libc.h: Update.
1183 * gnulib/import/glob.c: Update.
1184 * gnulib/import/glob.in.h: Update.
1185 * gnulib/import/glob_internal.h: Update.
1186 * gnulib/import/glob_pattern_p.c: Update.
1187 * gnulib/import/globfree.c: Update.
1188 * gnulib/import/hard-locale.c: Update.
1189 * gnulib/import/hard-locale.h: Update.
1190 * gnulib/import/intprops.h: Update.
1191 * gnulib/import/inttypes.in.h: Update.
1192 * gnulib/import/isnan.c: Update.
1193 * gnulib/import/isnand-nolibm.h: Update.
1194 * gnulib/import/isnand.c: Update.
1195 * gnulib/import/isnanl-nolibm.h: Update.
1196 * gnulib/import/isnanl.c: Update.
1197 * gnulib/import/itold.c: Update.
1198 * gnulib/import/libc-config.h: Update.
1199 * gnulib/import/limits.in.h: Update.
1200 * gnulib/import/localcharset.c: Update.
1201 * gnulib/import/localcharset.h: Update.
1202 * gnulib/import/localtime-buffer.c: Update.
1203 * gnulib/import/localtime-buffer.h: Update.
1204 * gnulib/import/lstat.c: Update.
1205 * gnulib/import/m4/00gnulib.m4: Update.
1206 * gnulib/import/m4/__inline.m4: Update.
1207 * gnulib/import/m4/absolute-header.m4: Update.
1208 * gnulib/import/m4/alloca.m4: Update.
1209 * gnulib/import/m4/builtin-expect.m4: Update.
1210 * gnulib/import/m4/canonicalize.m4: Update.
1211 * gnulib/import/m4/chdir-long.m4: Update.
1212 * gnulib/import/m4/close.m4: Update.
1213 * gnulib/import/m4/closedir.m4: Update.
1214 * gnulib/import/m4/configmake.m4: Update.
1215 * gnulib/import/m4/d-ino.m4: Update.
1216 * gnulib/import/m4/d-type.m4: Update.
1217 * gnulib/import/m4/dirent_h.m4: Update.
1218 * gnulib/import/m4/dirfd.m4: Update.
1219 * gnulib/import/m4/dirname.m4: Update.
1220 * gnulib/import/m4/double-slash-root.m4: Update.
1221 * gnulib/import/m4/dup.m4: Update.
1222 * gnulib/import/m4/dup2.m4: Update.
1223 * gnulib/import/m4/eealloc.m4: Update.
1224 * gnulib/import/m4/environ.m4: Update.
1225 * gnulib/import/m4/errno_h.m4: Update.
1226 * gnulib/import/m4/error.m4: Update.
1227 * gnulib/import/m4/exponentd.m4: Update.
1228 * gnulib/import/m4/exponentl.m4: Update.
1229 * gnulib/import/m4/extensions.m4: Update.
1230 * gnulib/import/m4/extern-inline.m4: Update.
1231 * gnulib/import/m4/fchdir.m4: Update.
1232 * gnulib/import/m4/fcntl-o.m4: Update.
1233 * gnulib/import/m4/fcntl.m4: Update.
1234 * gnulib/import/m4/fcntl_h.m4: Update.
1235 * gnulib/import/m4/fdopendir.m4: Update.
1236 * gnulib/import/m4/filenamecat.m4: Update.
1237 * gnulib/import/m4/flexmember.m4: Update.
1238 * gnulib/import/m4/float_h.m4: Update.
1239 * gnulib/import/m4/fnmatch.m4: Update.
1240 * gnulib/import/m4/fnmatch_h.m4: Update.
1241 * gnulib/import/m4/fpieee.m4: Update.
1242 * gnulib/import/m4/frexp.m4: Update.
1243 * gnulib/import/m4/frexpl.m4: Update.
1244 * gnulib/import/m4/fstat.m4: Update.
1245 * gnulib/import/m4/fstatat.m4: Update.
1246 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
1247 * gnulib/import/m4/getcwd-path-max.m4: Update.
1248 * gnulib/import/m4/getcwd.m4: Update.
1249 * gnulib/import/m4/getdtablesize.m4: Update.
1250 * gnulib/import/m4/getlogin.m4: Update.
1251 * gnulib/import/m4/getlogin_r.m4: Update.
1252 * gnulib/import/m4/getpagesize.m4: Update.
1253 * gnulib/import/m4/getprogname.m4: Update.
1254 * gnulib/import/m4/gettimeofday.m4: Update.
1255 * gnulib/import/m4/glibc21.m4: Update.
1256 * gnulib/import/m4/glob.m4: Update.
1257 * gnulib/import/m4/glob_h.m4: Update.
1258 * gnulib/import/m4/gnulib-cache.m4: Update.
1259 * gnulib/import/m4/gnulib-common.m4: Update.
1260 * gnulib/import/m4/gnulib-comp.m4: Update.
1261 * gnulib/import/m4/gnulib-tool.m4: Update.
1262 * gnulib/import/m4/hard-locale.m4: Update.
1263 * gnulib/import/m4/include_next.m4: Update.
1264 * gnulib/import/m4/inttypes-pri.m4: Update.
1265 * gnulib/import/m4/inttypes.m4: Update.
1266 * gnulib/import/m4/isnand.m4: Update.
1267 * gnulib/import/m4/isnanl.m4: Update.
1268 * gnulib/import/m4/largefile.m4: Update.
1269 * gnulib/import/m4/limits-h.m4: Update.
1270 * gnulib/import/m4/localcharset.m4: Update.
1271 * gnulib/import/m4/locale-fr.m4: Update.
1272 * gnulib/import/m4/locale-ja.m4: Update.
1273 * gnulib/import/m4/locale-zh.m4: Update.
1274 * gnulib/import/m4/localtime-buffer.m4: Update.
1275 * gnulib/import/m4/longlong.m4: Update.
1276 * gnulib/import/m4/lstat.m4: Update.
1277 * gnulib/import/m4/malloc.m4: Update.
1278 * gnulib/import/m4/malloca.m4: Update.
1279 * gnulib/import/m4/math_h.m4: Update.
1280 * gnulib/import/m4/mbrtowc.m4: Update.
1281 * gnulib/import/m4/mbsinit.m4: Update.
1282 * gnulib/import/m4/mbsrtowcs.m4: Update.
1283 * gnulib/import/m4/mbstate_t.m4: Update.
1284 * gnulib/import/m4/memchr.m4: Update.
1285 * gnulib/import/m4/memmem.m4: Update.
1286 * gnulib/import/m4/mempcpy.m4: Update.
1287 * gnulib/import/m4/memrchr.m4: Update.
1288 * gnulib/import/m4/mkdir.m4: Update.
1289 * gnulib/import/m4/mkstemp.m4: Update.
1290 * gnulib/import/m4/mmap-anon.m4: Update.
1291 * gnulib/import/m4/mode_t.m4: Update.
1292 * gnulib/import/m4/msvc-inval.m4: Update.
1293 * gnulib/import/m4/msvc-nothrow.m4: Update.
1294 * gnulib/import/m4/multiarch.m4: Update.
1295 * gnulib/import/m4/nocrash.m4: Update.
1296 * gnulib/import/m4/off_t.m4: Update.
1297 * gnulib/import/m4/onceonly.m4: Update.
1298 * gnulib/import/m4/open-cloexec.m4: Update.
1299 * gnulib/import/m4/open.m4: Update.
1300 * gnulib/import/m4/openat.m4: Update.
1301 * gnulib/import/m4/opendir.m4: Update.
1302 * gnulib/import/m4/pathmax.m4: Update.
1303 * gnulib/import/m4/rawmemchr.m4: Update.
1304 * gnulib/import/m4/readdir.m4: Update.
1305 * gnulib/import/m4/readlink.m4: Update.
1306 * gnulib/import/m4/realloc.m4: Update.
1307 * gnulib/import/m4/rename.m4: Update.
1308 * gnulib/import/m4/rewinddir.m4: Update.
1309 * gnulib/import/m4/rmdir.m4: Update.
1310 * gnulib/import/m4/save-cwd.m4: Update.
1311 * gnulib/import/m4/secure_getenv.m4: Update.
1312 * gnulib/import/m4/setenv.m4: Update.
1313 * gnulib/import/m4/signal_h.m4: Update.
1314 * gnulib/import/m4/ssize_t.m4: Update.
1315 * gnulib/import/m4/stat-time.m4: Update.
1316 * gnulib/import/m4/stat.m4: Update.
1317 * gnulib/import/m4/std-gnu11.m4: Update.
1318 * gnulib/import/m4/stdbool.m4: Update.
1319 * gnulib/import/m4/stddef_h.m4: Update.
1320 * gnulib/import/m4/stdint.m4: Update.
1321 * gnulib/import/m4/stdio_h.m4: Update.
1322 * gnulib/import/m4/stdlib_h.m4: Update.
1323 * gnulib/import/m4/strchrnul.m4: Update.
1324 * gnulib/import/m4/strdup.m4: Update.
1325 * gnulib/import/m4/strerror.m4: Update.
1326 * gnulib/import/m4/string_h.m4: Update.
1327 * gnulib/import/m4/strstr.m4: Update.
1328 * gnulib/import/m4/strtok_r.m4: Update.
1329 * gnulib/import/m4/sys_socket_h.m4: Update.
1330 * gnulib/import/m4/sys_stat_h.m4: Update.
1331 * gnulib/import/m4/sys_time_h.m4: Update.
1332 * gnulib/import/m4/sys_types_h.m4: Update.
1333 * gnulib/import/m4/tempname.m4: Update.
1334 * gnulib/import/m4/time_h.m4: Update.
1335 * gnulib/import/m4/unistd-safer.m4: Update.
1336 * gnulib/import/m4/unistd_h.m4: Update.
1337 * gnulib/import/m4/warn-on-use.m4: Update.
1338 * gnulib/import/m4/wchar_h.m4: Update.
1339 * gnulib/import/m4/wchar_t.m4: Update.
1340 * gnulib/import/m4/wctype_h.m4: Update.
1341 * gnulib/import/m4/wint_t.m4: Update.
1342 * gnulib/import/malloc.c: Update.
1343 * gnulib/import/malloc/scratch_buffer.h: Update.
1344 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
1345 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
1346 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
1347 * gnulib/import/malloca.c: Update.
1348 * gnulib/import/malloca.h: Update.
1349 * gnulib/import/malloca.valgrind: Update.
1350 * gnulib/import/math.in.h: Update.
1351 * gnulib/import/mbrtowc.c: Update.
1352 * gnulib/import/mbsinit.c: Update.
1353 * gnulib/import/mbsrtowcs-impl.h: Update.
1354 * gnulib/import/mbsrtowcs-state.c: Update.
1355 * gnulib/import/mbsrtowcs.c: Update.
1356 * gnulib/import/memchr.c: Update.
1357 * gnulib/import/memmem.c: Update.
1358 * gnulib/import/mempcpy.c: Update.
1359 * gnulib/import/memrchr.c: Update.
1360 * gnulib/import/mkdir.c: Update.
1361 * gnulib/import/mkstemp.c: Update.
1362 * gnulib/import/msvc-inval.c: Update.
1363 * gnulib/import/msvc-inval.h: Update.
1364 * gnulib/import/msvc-nothrow.c: Update.
1365 * gnulib/import/msvc-nothrow.h: Update.
1366 * gnulib/import/open.c: Update.
1367 * gnulib/import/openat-die.c: Update.
1368 * gnulib/import/openat-priv.h: Update.
1369 * gnulib/import/openat-proc.c: Update.
1370 * gnulib/import/openat.c: Update.
1371 * gnulib/import/openat.h: Update.
1372 * gnulib/import/opendir.c: Update.
1373 * gnulib/import/pathmax.h: Update.
1374 * gnulib/import/pipe-safer.c: Update.
1375 * gnulib/import/rawmemchr.c: Update.
1376 * gnulib/import/readdir.c: Update.
1377 * gnulib/import/readlink.c: Update.
1378 * gnulib/import/realloc.c: Update.
1379 * gnulib/import/ref-add.sin: Update.
1380 * gnulib/import/ref-del.sin: Update.
1381 * gnulib/import/rename.c: Update.
1382 * gnulib/import/rewinddir.c: Update.
1383 * gnulib/import/rmdir.c: Update.
1384 * gnulib/import/same-inode.h: Update.
1385 * gnulib/import/save-cwd.c: Update.
1386 * gnulib/import/save-cwd.h: Update.
1387 * gnulib/import/scratch_buffer.h: Update.
1388 * gnulib/import/secure_getenv.c: Update.
1389 * gnulib/import/setenv.c: Update.
1390 * gnulib/import/signal.in.h: Update.
1391 * gnulib/import/stat-time.c: Update.
1392 * gnulib/import/stat-time.h: Update.
1393 * gnulib/import/stat-w32.c: Update.
1394 * gnulib/import/stat-w32.h: Update.
1395 * gnulib/import/stat.c: Update.
1396 * gnulib/import/stdbool.in.h: Update.
1397 * gnulib/import/stddef.in.h: Update.
1398 * gnulib/import/stdint.in.h: Update.
1399 * gnulib/import/stdio.in.h: Update.
1400 * gnulib/import/stdlib.in.h: Update.
1401 * gnulib/import/str-two-way.h: Update.
1402 * gnulib/import/strchrnul.c: Update.
1403 * gnulib/import/strdup.c: Update.
1404 * gnulib/import/streq.h: Update.
1405 * gnulib/import/strerror-override.c: Update.
1406 * gnulib/import/strerror-override.h: Update.
1407 * gnulib/import/strerror.c: Update.
1408 * gnulib/import/string.in.h: Update.
1409 * gnulib/import/stripslash.c: Update.
1410 * gnulib/import/strnlen1.c: Update.
1411 * gnulib/import/strnlen1.h: Update.
1412 * gnulib/import/strstr.c: Update.
1413 * gnulib/import/strtok_r.c: Update.
1414 * gnulib/import/sys_stat.in.h: Update.
1415 * gnulib/import/sys_time.in.h: Update.
1416 * gnulib/import/sys_types.in.h: Update.
1417 * gnulib/import/tempname.c: Update.
1418 * gnulib/import/tempname.h: Update.
1419 * gnulib/import/time.in.h: Update.
1420 * gnulib/import/unistd--.h: Update.
1421 * gnulib/import/unistd-safer.h: Update.
1422 * gnulib/import/unistd.in.h: Update.
1423 * gnulib/import/unsetenv.c: Update.
1424 * gnulib/import/verify.h: Update.
1425 * gnulib/import/extra/snippet/warn-on-use.h: Update.
1426 * gnulib/import/wchar.in.h: Update.
1427 * gnulib/import/wctype.in.h: Update.
1428 * gnulib/import/xalloc-oversized.h: Update.
1429 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
1430 "53e2c179f26a890fa6685af4b6c1397ee370433b".
1432 2018-08-16 Gary Benson <gbenson@redhat.com>
1435 * gdb/main.c (captured_main_1): Exit with nonzero status
1436 in batch mode if the last command to be executed failed.
1437 * NEWS: Mention the above.
1439 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
1441 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
1442 end of warning message.
1444 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1447 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
1448 (aarch64_extract_return_value): Use
1449 aapcs_is_vfp_call_or_return_candidate.
1450 (aarch64_return_in_memory): Likewise.
1451 (aarch64_store_return_value): Likewise.
1453 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1456 (aapcs_is_vfp_call_or_return_candidate): Make static
1457 (pass_in_v_or_stack): Remove function.
1458 (pass_in_v_vfp_candidate): New function.
1459 (aarch64_push_dummy_call): Check for float register candidates.
1461 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1463 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
1464 (aapcs_is_vfp_call_or_return_candidate_1): New function.
1465 (aapcs_is_vfp_call_or_return_candidate): Likewise.
1467 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
1470 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
1471 (struct ipa_sym_addresses): Rename to...
1472 (struct ipa_sym_addresses_common): ... this.
1473 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
1475 2018-08-28 Tom Tromey <tom@tromey.com>
1477 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1478 (token_fifo): Now a std::vector.
1479 (yylex, c_parse): Update.
1480 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1481 (token_fifo): Now a std::vector.
1482 (yylex, d_parse): Update.
1483 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1484 (token_fifo): Now a std::vector.
1485 (yylex, go_parse): Update.
1487 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
1489 * parser-defs.h (struct type_stack) <elements>: Change type to
1490 std::vector<union type_stack_elt>.
1491 <depth, size>: Remove.
1492 * parse.c (parse_exp_in_context_1): Adjust.
1493 (type_stack_reserve): Remove.
1494 (check_type_stack_depth): Remove.
1495 (insert_into_type_stack): Adjust to std::vector.
1496 (insert_type): Likewise.
1497 (push_type): Likewise.
1498 (push_type_int): Likewise.
1499 (insert_type_address_space): Likewise.
1500 (pop_type): Likewise.
1501 (pop_type_int): Likewise.
1502 (pop_typelist): Likewise.
1503 (pop_type_stack): Likewise.
1504 (append_type_stack): Likewise.
1505 (push_type_stack): Likewise.
1506 (get_type_stack): Likewise.
1507 (type_stack_cleanup): Likewise.
1508 (push_typelist): Likewise.
1509 (follow_types): Likewise.
1510 (_initialize_parse): Likewise.
1512 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
1514 * NEWS: Mention csky target.
1516 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
1517 Hafiz Abid Qadeer <abidh@codesourcery.com>
1518 Don Breazeal <donb@codesourcery.com>
1520 * csky-linux-tdep.c: New file.
1521 * csky-tdep.c: Likewise.
1522 * csky-tdep.h: Likewise.
1523 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
1525 (HFILES_NO_SRCDIR): Add csky-tdep.h.
1526 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
1527 * configure.tgt: Add csky support.
1529 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
1531 * python/py-framefilter.c (py_print_frame): Print frame architecture
1532 when printing on an MI output.
1534 2018-08-27 Tom Tromey <tom@tromey.com>
1537 * configure: Rebuild.
1538 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
1540 2018-08-27 Tom Tromey <tom@tromey.com>
1542 * aarch64-linux-tdep.c
1543 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
1546 2018-08-27 Tom Tromey <tom@tromey.com>
1548 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
1550 (ppc64_standard_linkage1, ppc64_standard_linkage2)
1551 (ppc64_standard_linkage3, ppc64_standard_linkage4)
1552 (ppc64_standard_linkage5, ppc64_standard_linkage6)
1553 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
1556 2018-08-27 Tom Tromey <tom@tromey.com>
1558 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
1559 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
1561 2018-08-27 Tom Tromey <tom@tromey.com>
1563 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
1564 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
1566 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
1568 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
1570 * sparc-linux-tdep.c (sparc32_linux_sigframe)
1571 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
1572 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
1574 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
1575 (ppc64_linux_sigaction_tramp_frame)
1576 (ppc32_linux_sighandler_tramp_frame)
1577 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1578 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
1579 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
1580 * mn10300-linux-tdep.c (am33_linux_sigframe)
1581 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
1582 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
1583 * mips-linux-tdep.c (mips_linux_o32_sigframe)
1584 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
1585 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
1586 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
1587 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
1588 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
1589 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
1590 * microblaze-linux-tdep.c
1591 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1592 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
1593 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
1594 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
1595 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
1596 * common/common-types.h (ULONGEST_MAX): New define.
1597 (CORE_ADDR_MAX): Fix formatting.
1598 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
1599 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
1600 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
1601 (arm_linux_rt_sigreturn_tramp_frame)
1602 (arm_eabi_linux_sigreturn_tramp_frame)
1603 (arm_eabi_linux_rt_sigreturn_tramp_frame)
1604 (thumb2_eabi_linux_sigreturn_tramp_frame)
1605 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
1606 (arm_linux_restart_syscall_tramp_frame)
1607 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
1608 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
1609 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
1611 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
1613 2018-08-27 Tom Tromey <tom@tromey.com>
1615 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
1617 * mips-tdep.c (mips_deal_with_atomic_sequence)
1618 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
1619 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
1620 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
1621 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
1623 * aarch64-tdep.c (aarch64_software_single_step): Use
1626 2018-08-27 Tom Tromey <tom@tromey.com>
1628 * linespec.c (complete_linespec_component): Add cast to "char".
1629 * completer.c (completion_tracker::build_completion_result): Add
1632 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1634 * solist.h (struct solist, struct target_so_ops): Fix
1637 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1639 * ada-tasks.c (ada_task_info_s): Remove typedef.
1640 (DEF_VEC_O(ada_task_info_s)): Remove.
1641 (struct ada_tasks_inferior_data): Initialize fields.
1642 <task_list>: Make an std::vector.
1643 (get_ada_tasks_inferior_data): Allocate with new.
1644 (ada_get_task_number): Adjust.
1645 (get_task_number_from_id): Likewise.
1646 (valid_task_id): Likewise.
1647 (ada_get_task_info_from_ptid): Likewise.
1648 (iterate_over_live_ada_tasks): Likewise.
1649 (add_ada_task): Likewise.
1650 (read_known_tasks): Likewise.
1651 (ada_build_task_list): Likewise.
1652 (print_ada_task_info): Likewise.
1653 (info_task): Likewise.
1654 (task_command_1): Likewise.
1656 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1658 * ada-lang.c (add_angle_brackets): Return std::string.
1660 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
1662 * python/py-threadevent.c (py_get_event_thread): Initialize
1665 2018-08-24 Pedro Alves <palves@redhat.com>
1667 * python/py-bpevent.c (create_breakpoint_event_object): Use
1668 copy-initialization.
1669 * python/py-continueevent.c (emit_continue_event): Use
1670 copy-initialization.
1671 * python/py-exitedevent.c (create_exited_event_object): Return a
1673 (emit_exited_event): Use copy-initialization.
1674 * python/py-inferior.c (python_new_inferior)
1675 (python_inferior_deleted, add_thread_object): Use
1676 copy-initialization.
1677 * python/py-infevents.c (create_inferior_call_event_object)
1678 (create_register_changed_event_object)
1679 (create_memory_changed_event_object): Return a gdbpy_ref<>.
1680 (emit_inferior_call_event, emit_memory_changed_event)
1681 (emit_register_changed_event): Use copy-initialization.
1682 * python/py-newobjfileevent.c (create_new_objfile_event_object):
1683 Return a gdbpy_ref<>.
1684 (emit_new_objfile_event): Use copy-initialization.
1685 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
1686 (emit_clear_objfiles_event): Use copy-initialization.
1687 * python/py-signalevent.c (create_signal_event_object): Use
1688 copy-initialization.
1689 * python/py-threadevent.c (create_thread_event_object): Use
1690 copy-initialization.
1692 2018-08-24 Pedro Alves <palves@redhat.com>
1693 Simon Marchi <simon.marchi@ericsson.com>
1696 * python/py-continueevent.c: Include "gdbthread.h".
1697 (create_continue_event_object): Add intro comment. Add 'ptid'
1698 parameter. Use it to find thread to pass to
1699 create_thread_event_object.
1700 (emit_continue_event): Pass PTID down to
1701 create_continue_event_object.
1702 * python/py-event.h (py_get_event_thread): Declare.
1703 (create_thread_event_object): Remove default from 'thread'
1705 * python/py-stopevent.c (create_stop_event_object): Use
1706 py_get_event_thread.
1707 * python/py-threadevent.c (get_event_thread): Rename to ...
1708 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
1709 and use it to find the thread.
1710 (create_thread_event_object): Assert that THREAD isn't null.
1711 Don't find the event thread here.
1713 2018-08-23 Kevin Buettner <kevinb@redhat.com>
1715 * block.h (blockrange, blockranges): New struct declarations.
1716 (struct block): Add new field named `ranges'.
1717 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
1718 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
1719 macros for accessing ranges in struct block.
1720 (make_blockranges): New declaration.
1721 block.c (make_blockranges): New function.
1722 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
1724 * symtab.h (find_pc_partial_function): Add new parameter `block'.
1725 * blockframe.c (cache_pc_function_block): New static global.
1726 (clear_pc_function_cache): Clear cache_pc_function_block.
1727 (find_pc_partial_function): Move comment to symtab.h. Add
1728 support for non-contiguous blocks.
1729 * cli/cli-cmds.c (block.h): Include.
1730 (print_disassembly): Handle printing of non-contiguous blocks.
1731 (disassemble_current_function): Likewise.
1732 (disassemble_command): Likewise.
1734 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
1736 * blockframe.c (get_pc_function_start): Likewise.
1737 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
1738 (gcc_symbol_address): Likewise.
1739 * compile/compile-object-run.c (compile_object_run): Likewise.
1740 * compile/compile.c (get_expr_block_and_pc): Likewise.
1741 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
1742 (func_addr_to_tail_call_list): Likewise.
1743 * findvar.c (default_read_var_value): Likewise.
1744 * inline-frame.c (inline_frame_this_id): Likewise.
1745 (skip-inline_frames): Likewise.
1746 * infcmd.c (until_next_command): Likewise.
1747 * linespec.c (convert_linespec_to_sals): Likewise.
1748 * parse.c (parse_exp_in_context_1): Likewise.
1749 * printcmd.c (build_address_symbolic): likewise.
1750 (info_address_command): Likewise.
1751 symtab.c (find_function_start_sal): Likewise.
1752 (skip_prologue_sal): Likewise.
1753 (find_function_alias_target): Likewise.
1754 (find_gnu_ifunc): Likewise.
1755 * stack.c (find_frame_funname): Likewise.
1756 * symtab.c (fixup_symbol_section): Likewise.
1757 (find_function_start_sal): Likewise.
1758 (skip_prologue_sal): Likewsie.
1759 (find_function_alias_target): Likewise.
1760 (find_gnu_ifunc): Likewise.
1761 * tracepoint.c (info_scope_command): Likewise.
1762 * value.c (value_fn_field): Likewise.
1764 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
1765 in place of find_pc_partial_function.
1766 * blockframe.c (find_function_entry_range_from_pc): New function.
1767 * symtab.h (find_function_entry_range_from_pc): Declare and document.
1768 * objfiles.c (objfile_relocate1): Relocate start and end addresses
1769 for each range in a block.
1772 2018-08-23 Xavier Roirand <roirand@adacore.com>
1774 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
1777 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1779 * solib-svr4.c (read_program_headers_from_bfd): Return
1780 gdb::optional<gdb::byte_vector>.
1781 (svr4_exec_displacement): Adjust.
1783 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1785 * solib-svr4.c (read_program_header): Return
1786 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
1787 (find_program_interpreter): Return
1788 gdb::optional<gdb::byte_vector>.
1789 (scan_dyntag_auxv): Adjust.
1790 (enable_break): Adjust.
1791 (svr4_exec_displacement): Adjust.
1793 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1795 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
1796 * inf-child.c (inf_child_target::terminal_save_inferior): New.
1798 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1800 * guile/scm-string.c (gdbscm_scm_from_printf): Use
1802 * guile/scm-utils.c (gdbscm_printf): Likewise.
1803 * serial.c (serial_printf): Likewise.
1804 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
1806 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
1808 * stack.c (print_frame): Print frame architecture when printing on
1810 * NEWS: Mention new "arch" attribute in frame output.
1812 2018-08-21 Alan Hayward <alan.hayward@arm.com>
1814 * arch/aarch64.h (aarch64_regnum): Update comment.
1816 2018-08-21 Alan Hayward <alan.hayward@arm.com>
1818 * NEWS: Add SVE to 8.2 section.
1820 2018-08-21 Pedro Alves <palves@redhat.com>
1822 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
1823 out from gdbscm_parse_function_args.
1824 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
1825 gdbscm_parse_function_args_1.
1827 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
1830 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
1833 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
1835 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
1837 2018-08-19 Michael Spang <spang@google.com>
1840 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
1841 for PT_TLS segments.
1843 2018-08-18 Kevin Buettner <kevinb@redhat.com>
1845 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
1846 dwarf_variable_value.
1847 * dwarf2-frame.c (class dwarf_expr_executor):
1848 Add override for dwarf_variable_value.
1849 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
1850 (class symbol_needs_eval_context): Likewise.
1851 (indirect_synthetic_pointer): Add forward declaration.
1852 (sect_variable_value): New function.
1853 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
1854 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
1855 for DW_OP_GNU_variable_value.
1857 2018-08-16 Tom Tromey <tom@tromey.com>
1859 * top.c (read_command_file): Update.
1860 (command_line_input): Remove "repeat" argument.
1861 * ada-lang.c (get_selections): Update.
1862 * linespec.c (decode_line_2): Update.
1863 * defs.h (command_line_input): Remove argument.
1864 * cli/cli-script.c (read_next_line): Update.
1865 * python/py-gdb-readline.c: Update.
1867 2018-08-17 Tom Tromey <tom@tromey.com>
1869 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
1872 2018-08-15 Tom Tromey <tom@tromey.com>
1874 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
1876 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
1878 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
1879 If used, use find_pc_partial_function to find address range
1881 * mi/mi-main.c (mi_cmd_list_features): Report
1882 "data-disassemble-a-option" feature.
1883 * NEWS: Mention new -data-disassemble option -a.
1885 2018-08-13 Tom Tromey <tom@tromey.com>
1887 * common/common-defs.h (_FORTIFY_SOURCE): Define.
1889 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1891 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
1892 (aarch64_linux_collect_sve_regset): Likewise.
1893 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
1894 * regcache.h (regcache_map_entry_size): New function.
1896 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1898 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
1899 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
1900 (SVE_HEADER_VL_LENGTH): Likewise.
1901 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
1902 (SVE_HEADER_FLAGS_LENGTH): Likewise.
1903 (SVE_HEADER_RESERVED_LENGTH): Likewise.
1904 (SVE_HEADER_SIZE_OFFSET): Likewise.
1905 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
1906 (SVE_HEADER_VL_OFFSET): Likewise.
1907 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
1908 (SVE_HEADER_FLAGS_OFFSET): Likewise.
1909 (SVE_HEADER_RESERVED_OFFSET): Likewise.
1910 (SVE_HEADER_SIZE): Likewise.
1911 (aarch64_linux_core_read_vq): Add function.
1912 (aarch64_linux_core_read_description): Check for SVE section.
1914 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1916 * aarch64-fbsd-tdep.c
1917 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
1919 * aarch64-linux-tdep.c
1920 (aarch64_linux_iterate_over_regset_sections): Likewise.
1921 * alpha-linux-tdep.c
1922 (alpha_linux_iterate_over_regset_sections):
1924 (alphanbsd_iterate_over_regset_sections): Likewise.
1926 (amd64fbsd_iterate_over_regset_sections): Likewise.
1927 * amd64-linux-tdep.c
1928 (amd64_linux_iterate_over_regset_sections): Likewise.
1930 (armbsd_iterate_over_regset_sections): Likewise.
1932 (arm_fbsd_iterate_over_regset_sections): Likewise.
1934 (arm_linux_iterate_over_regset_sections): Likewise.
1935 * corelow.c (get_core_registers_cb): Likewise.
1936 (core_target::fetch_registers): Likewise.
1937 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
1938 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
1939 * gdbarch.h (void): Regenerate.
1940 * gdbarch.sh: Add supply_size and collect_size.
1941 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
1942 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
1943 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
1944 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
1945 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
1946 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
1947 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
1948 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
1949 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
1950 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
1951 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
1952 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
1953 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
1954 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
1955 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
1956 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
1957 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
1958 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
1959 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
1960 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
1961 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
1962 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
1963 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
1964 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
1965 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
1966 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
1967 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
1968 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
1969 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
1970 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
1972 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
1974 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
1977 2018-08-10 Keith Seitz <keiths@redhat.com>
1979 * compile/compile-c-support.c (add_code_header, add_code_footer):
1980 Move into policy class.
1981 (c_push_user_expression, pop_user_expression_nop)
1982 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
1983 (compile_program): New host class.
1984 (c_compile_program): New typedef.
1985 (c_compute_porgram): Use c_compile_program.
1987 2018-08-10 Keith Seitz <keiths@redhat.com>
1989 * compile/compile-internal.h (compile_instance::~compile_instance):
1990 Remove calls to htab_delete.
1991 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
1992 * compile.c (compile_instance::compile_instance): Initialize
1993 htab unique pointers.
1994 (compile_instance::get_cached_type, compile_instance::insert_type)
1995 (compile_instance::error_symbol_once): Update for unique_ptr.
1997 2018-08-10 Keith Seitz <keiths@redhat.com>
1999 * compile/compile-c-symbols.c (struct symbol_error)
2000 (hash_symbol_error, eq_symbol_error, del_symbol_error)
2001 (compile_instance::insert_symbol_error)
2002 (compile_instance::error_symbol_once): Move to ...
2003 * compile/compile.c: ... here.
2005 2018-08-10 Keith Seitz <keiths@redhat.com>
2007 * compile/compile-c-support.c (c_get_compile_context): Use `new'
2008 instead of `new_compile_instance'.
2009 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
2011 If the symbol error map is not initialized, create it.
2012 (generate_c_for_for_one_symbol): Do not check/initialize
2013 the symbol error map.
2014 * compile/compile-c-types.c (compile_c_instance): Make a class.
2016 (compile_instance::compile_instance): Initialize the type cache.
2017 (get_cached_type): New function.
2018 (insert_type): Update description.
2019 (compile_c_instance::m_default_cflags): Define.
2020 (convert_type): Update description. Use get_cached_type.
2021 (delete_instance): Moved to destructor.
2022 (new_compile_instance): Moved to constructor.
2023 * compile/compile-c.h (compile_c_instance): Make class inheriting
2024 from compile_instance.
2025 <base>: Remove field.
2026 <type_map, symbol_err_map>: Move to base class.
2027 <c_plugin>: Rename to `m_plugin' and remove pointer type.
2028 * compile/compile-internal.h (compile_instance): Make class.
2029 <type_map_t, symbol_err_map_t>: Define.
2030 <fe>: Rename to `m_gcc_fe'.
2031 <scope, block, gcc_target_options>: Add `m_' prefix.
2032 <m_type_map, m_symbol_err_map>: New fields, moved from
2035 (convert_type, new_compile_instance): Remove.
2036 * compile/compile.c (cleanup_compile_instance): Remove.
2037 (compile_to_object): Use unique_ptr to eliminate cleanups.
2038 (compile_instance::set_print_callback, compile_instance::version)
2039 (compile_instance::set_verbose)
2040 (compile_instance::set_driver_filename)
2041 (compile_instance::set_triplet_regexp)
2042 (compile_instance::set_arguments)
2043 (compile_instance::set_source_file)
2044 (compile_instance::compile): Define.
2046 2018-08-10 Keith Seitz <keiths@redhat.com>
2048 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
2049 * compile/compile-c-types.c: Define GCC_METHODN macros and include
2050 gcc-c-fe.def to define C plugin.
2051 (delete_instance): Delete `c_plugin'.
2052 (new_compile_instance): Initialize `c_plugin'.
2053 * compile/compile-c.h: Include gcc_c_plugin.h.
2054 (struct compile_c_instance) <c_plugin>: New member.
2055 * gcc-c-plugin.h: New file.
2056 Update all callers with API change.
2058 2018-08-10 Keith Seitz <keiths@redhat.com>
2060 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
2061 (HFILES_NO_SRCDIR): ... to here.
2062 Add compile-internal.h and compile-c.h.
2063 * compile/compile-c-support.c: Include compile-c.h.
2064 * compile/compile-c-symbols.c: Include compile-c.h.
2065 (generate_c_for_variable_locations): Update comment.
2066 * compile/compile-c-types.c: Include compile-c.h.
2067 * compile/compile-c.h: New file -- moved C language declarations
2068 from other files here.
2069 * compile/compile-internal.h: Do not include hashtab.h or
2070 common/enum-flags.h.
2071 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
2072 (gcc_convert_symbol, gcc_symbol_address)
2073 (generate_c_for_variable_locations, c_get_mode_for_size)
2074 (c_get_range_decl_name): Definitions moved to compile-c.h.
2075 * compile/compile-loc2c.c: Include compile-c.h.
2077 2018-08-10 Keith Seitz <keiths@redhat.com>
2079 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
2080 (c_symbol_substitution_name): ... this.
2083 2018-08-10 Keith Seitz <keiths@redhat.com>
2085 * compile/compile-c-support.c (c_compute_program): Use
2086 unique_xmalloc_ptr to eliminate cleanup.
2087 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
2088 Return a unique_xmalloc_ptr and eliminate cleanup.
2089 * compile/compile-internal.h (generate_c_for_variable_locations):
2090 Return unique_xmalloc_ptr and update description.
2092 2018-08-10 Alan Hayward <alan.hayward@arm.com>
2094 * corelow.c (core_target::get_core_register_section): Rename
2095 min_size to section_min_size.
2097 2018-08-09 Jim Wilson <jimw@sifive.com>
2099 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
2100 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
2101 * NEWS: Mention new GNU/Linux RISC-V target.
2102 * configure.host: Add riscv*-*-linux*.
2103 * configure.nat: Add riscv*.
2104 * configure.tgt: Add riscv*-*-linux*.
2105 * riscv-linux-nat.c: New file.
2106 * riscv-linux-tdep.c: New file.
2108 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2110 * infrun.c (resume): Make static, add forward declaration.
2111 (proceed): Update header comment.
2112 * infrun.h (resume): Delete declaration.
2114 2018-08-09 Tom Tromey <tom@tromey.com>
2116 * riscv-tdep.h: Minor formatting fixes.
2118 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
2120 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
2121 * dwarf-index-cache.c (create_dir_and_check): Likewise.
2122 (test_mkdir_recursive): Likewise.
2123 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
2125 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2127 * valarith.c (value_subscripted_rvalue): If an array is not in
2128 memory, and we don't know the upper bound, then we can't know that
2129 the requested element exists or not.
2131 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
2133 * target.c (str_comma_list_concat_elem): Fix typo in comment.
2134 (target_options_to_string): Add comment.
2136 2018-08-08 Tom Tromey <tom@tromey.com>
2138 * unittests/scoped_mmap-selftests.c: Check result of "write".
2140 2018-08-08 Jim Wilson <jimw@sifive.com>
2142 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
2143 (decode_register_index_short): New.
2144 (decode_j_type_insn, decode_cj_type_insn): New.
2145 (decode_b_type_insn, decode_cb_type_insn): New.
2146 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
2147 local xlen. Check xlen when decoding ambiguous compressed insns. In
2148 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
2149 is_c_sw_insn instead of is_sw_insn.
2150 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
2151 (riscv_software_single_step): New.
2152 * riscv-tdep.h (riscv_software_single_step): Declare.
2154 * riscv-tdep.c (riscv_isa_xlen): Drop static.
2155 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
2157 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
2160 * target.c (dispose_inferior): Don't dispose of inferiors that are
2163 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
2165 * remote.c (remote_target::download_tracepoint): Change char* to
2168 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
2170 * target.h (target_options_to_string): Return an std::string.
2171 * target.c (str_comma_list_concat_elem): Return void, use
2173 (do_option): Likewise.
2174 (target_options_to_string): Return an std::string.
2175 * linux-nat.c (linux_nat_target::wait): Adjust.
2176 * target-debug.h (target_debug_print_options): Adjust.
2178 2018-08-07 Tom Tromey <tom@tromey.com>
2180 * Makefile.in (CPPFLAGS): New variable.
2181 (INTERNAL_CPPFLAGS): Use it.
2183 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2185 * NEWS: Mention the index cache.
2187 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2189 * common/pathstuff.h (get_standard_cache_dir): New.
2190 * common/pathstuff.c (get_standard_cache_dir): New.
2191 * build-id.h (build_id_to_string): New.
2192 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
2193 DEBUG_STR_SUFFIX): Move to here.
2194 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
2195 DEBUG_STR_SUFFIX): Move from there.
2196 (write_psymtabs_to_index): Make non-static, add basename
2197 parameter. Write to temporary files, rename when done.
2198 (save_gdb_index_command): Adjust call to
2199 write_psymtabs_to_index.
2200 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
2202 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
2203 (get_gdb_index_contents_from_cache): New.
2204 (get_gdb_index_contents_from_cache_dwz): New.
2205 (dwarf2_initialize_objfile): Read index from cache.
2206 (dwarf2_build_psymtabs): Save to index.
2207 * dwarf-index-cache.h: New file.
2208 * dwarf-index-cache.c: New file.
2209 * dwarf-index-write.h: New file.
2211 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2213 * gnulib/aclocal.m4: Re-generate.
2214 * gnulib/config.in: Re-generate.
2215 * gnulib/configure: Re-generate.
2216 * gnulib/import/Makefile.am: Re-generate.
2217 * gnulib/import/Makefile.in: Re-generate.
2218 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
2219 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2220 * gnulib/import/m4/mkdir.m4: New file.
2221 * gnulib/import/mkdir.c: New file.
2222 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
2225 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2227 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
2228 * common/scoped_mmap.c: New file.
2229 * common/scoped_mmap.h (destroy): New method.
2230 (~scoped_mmap, reset): Use destroy.
2231 (scoped_mmap): New move constructor.
2232 (mmap_file): New declaration.
2233 * unittests/scoped_mmap-selftests.c (test_normal,
2234 test_invalid_filename, run_tests): New functions.
2235 (_initialize_scoped_mmap_selftests): Register selftest.
2237 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2239 * dwarf2read.c (read_gdb_index_from_section): Rename to...
2240 (read_gdb_index_from_buffer): ... this. Remove section
2241 parameter, add buffer parameter.
2242 (get_gdb_index_contents_ftype,
2243 get_gdb_index_contents_dwz_ftype): New typedefs.
2244 (dwarf2_read_gdb_index): Add callback parameters to get the
2246 (get_gdb_index_contents_from_section): New.
2247 (dwarf2_initialize_objfile): Update call to
2248 dwarf2_read_gdb_index.
2250 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2252 * common/filestuff.h (gdb_fopen_cloexec): New overload.
2253 (gdb_open_cloexec): Likewise.
2254 * nat/linux-osdata.c (command_from_pid): Use string_printf.
2255 (commandline_from_pid): Likewise.
2256 (linux_xfer_osdata_threads): Likewise.
2257 (linux_xfer_osdata_fds): Likewise.
2258 * ada-lang.c (is_package_name): Likewise.
2259 * auxv.c (procfs_xfer_auxv): Likewise.
2260 * breakpoint.c (print_one_breakpoint_location): Use
2262 (print_one_catch_solib): Use string_printf.
2263 * coff-pe-read.c (add_pe_exported_sym): Likewise.
2264 (add_pe_forwarded_sym): Likewise.
2265 * dwarf2read.c (create_type_unit_group): Likewise.
2266 (build_error_marker_type): Likewise.
2267 * infcall.c (get_function_name): Likewise.
2268 * valprint.c (print_converted_chars_to_obstack): Likewise.
2269 * xtensa-tdep.c (xtensa_register_type): Likewise.
2271 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
2273 * remote.c (remote_target::download_tracepoint): Fix format
2276 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2278 * tracefile.c: Include common/byte-vector.h.
2279 (trace_save): Change type of buf to gdb::byte_vector. Initialize
2280 with trace_regblock_size if needed. Update uses of buf.
2282 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2284 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
2285 std::vector<unsigned char>.
2286 * tracepoint.c (collection_list::collection_list): Remove
2287 m_regs_mask initializer from initializer list. Resize
2288 m_regs_mask using the largest remote register number.
2289 (collection_list::add_remote_register): Remove size check on
2290 m_regs_mask. Use at to access element.
2291 (collection_list::stringify): Change type of temp_buf to
2292 gdb::char_vector. Update uses of temp_buf. Resize if needed to
2293 stringify the register mask. Use pack_hex_byte for the register
2296 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2298 * tracepoint.h (class collection_list) <add_register>: Remove.
2299 <add_remote_register, add_ax_registers, add_local_register>:
2301 <add_memrange>: Add scope parameter.
2302 * tracepoint.c (encode_actions_1): Likewise.
2303 (collection_list::add_register): Rename to ...
2304 (collection_list::add_remote_register): ... this. Update
2306 (collection_list::add_ax_registers, add_local_register): New
2308 (collection_list::add_memrange): Add scope parameter. Call
2309 add_local_register instead of add_register.
2310 (finalize_tracepoint_aexpr): New function.
2311 (collection_list::collect_symbol): Update calls to add_memrange.
2312 Call add_local_register instead of add_register. Call
2313 add_ax_registers. Call finalize_tracepoint_aexpr.
2314 (encode_actions_1): Get remote regnos for $reg action. Call
2315 add_remote_register, add_ax_registers, and add_local_register.
2316 Update call to add_memrange. Call finalize_tracepoint_aexpr.
2317 (validate_actionline): Call finalize_tracepoint_aexpr.
2319 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2321 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
2322 Replace array buf with gdb::char_vector buf, of size
2323 get_remote_packet_size (). Replace references to buf and
2324 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
2325 and xsnprintf with snprintf. Raise errors if the buffer is too
2328 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2330 * remote.c (remote_target::download_tracepoint): Fix the has_more
2331 predicate in the QTDP action list iteration.
2333 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2335 * remote.c (remote_target::download_tracepoint): Fix indentation
2338 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2340 * proc-api.c (_initialize_proc_api): Remove c, unused.
2341 * procfs.c (procfs_init_inferior): Remove signals, unused.
2342 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
2345 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
2346 Andrew Burgess <andrew.burgess@embecosm.com>
2348 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
2349 'W_STOPCODE (0)' as this could be ambiguous.
2351 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
2353 * ser-tcp.c (net_open): Fix thinko when deciding whether to
2354 disable TCP's Nagle algorithm (use "ai_protocol" instead of
2357 2018-08-02 Tom Tromey <tom@tromey.com>
2360 * dwarf2read.c (read_func_scope): Set symtab on template parameter
2362 (process_structure_scope): Likewise.
2364 2018-08-02 Xavier Roirand <roirand@adacore.com>
2367 * darwin-nat.c (darwin_kill_inferior): Fix handling of
2370 2018-08-02 Tom Tromey <tom@tromey.com>
2372 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
2373 (darwin_suspend_inferior, darwin_resume_inferior)
2374 (darwin_decode_notify_message, darwin_resume_inferior_threads)
2375 (darwin_check_new_threads): Check result of get_darwin_inferior.
2377 2018-07-31 Joel Brobecker <brobecker@adacore.com>
2381 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
2383 * varobj.c (varobj_get_path_expr_parent): Report an error if
2384 parent is a dynamic varobj.
2386 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2388 * gnulib/aclocal.m4: Re-generate.
2389 * gnulib/config.in: Re-generate.
2390 * gnulib/configure: Re-generate.
2391 * gnulib/import/Makefile.in: Re-generate.
2392 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2393 * gnulib/import/m4/onceonly.m4: Re-generate.
2395 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2397 * target-descriptions.c (struct xml_test_tdesc): New.
2398 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
2399 (record_xml_tdesc): Update.
2400 (maintenance_check_xml_descriptions): Update.
2401 * target-descriptions.h (record_xml_tdesc): Update comment.
2403 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
2405 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
2406 checking array bounds are defined.
2408 2018-07-30 Tom Tromey <tom@tromey.com>
2410 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
2411 irreflexivity violation.
2413 2018-07-30 Tom Tromey <tom@tromey.com>
2415 * cli/cli-decode.c (lookup_cmd): Remove lint code.
2416 * value.c (unpack_long): Remove lint code.
2417 * valops.c (value_ind): Remove lint code.
2418 * valarith.c (value_x_binop, value_x_unop, value_equal)
2419 (value_pos): Remove lint code.
2421 2018-07-28 Tom de Vries <tdevries@suse.de>
2423 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
2424 with undefined upper bound as <optimized out>.
2426 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
2428 * gcore.in: Rename variable "name" to "prefix". Expand
2431 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
2433 * windows-nat.c (windows_nat_target::create_inferior): Update to
2434 call close() in global namespace.
2436 2018-07-26 Tom Tromey <tom@tromey.com>
2438 * dwarf-index-write.c (add_address_entry): Don't add objfile
2440 * dbxread.c (find_stab_function): Rename from
2441 find_stab_function_addr. Return a bound_minimal_symbol.
2442 (read_dbx_symtab): Use raw_text_low, raw_text_high.
2443 Don't add objfile offsets.
2444 (end_psymtab): Use raw_text_low, raw_text_high,
2445 MSYMBOL_VALUE_RAW_ADDRESS.
2446 (read_ofile_symtab): Update.
2447 (process_one_symbol): Update.
2448 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
2450 (dw2_relocate): Remove.
2451 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
2453 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
2455 (process_psymtab_comp_unit_reader, add_partial_symbol)
2456 (add_partial_subprogram, dwarf2_ranges_read): Update.
2457 (load_partial_dies): Update.
2458 (add_address_entry): Don't add objfile offsets.
2459 (dwarf2_build_include_psymtabs): Update.
2460 (create_addrmap_from_aranges): Don't add objfile offsets.
2461 (dw2_find_pc_sect_compunit_symtab): Update.
2462 * mdebugread.c (parse_symbol): Don't add objfile offsets.
2463 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
2465 (parse_partial_symbols): Don't add objfile offsets. Use
2466 raw_text_low, raw_text_high. Update.
2467 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
2468 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
2469 or call 'relocate' quick function. Clear psymbol_map.
2470 * psympriv.h (struct partial_symbol) <address>: Add section
2472 <set_unrelocated_address>: Rename from set_address.
2473 <raw_text_low, raw_text_high>: New methods.
2474 <text_low, text_high>: Add objfile parameter.
2475 (add_psymbol_to_bcache): Add 'section' parameter. Call
2476 set_unrelocated_address.
2477 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2478 (find_pc_psymbol): Update.
2479 (fixup_psymbol_section, relocate_psymtabs): Remove.
2480 (dump_psymtab, psym_functions): Update.
2481 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
2483 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
2484 (start_psymtab_common): Update.
2485 * symfile-debug.c (debug_qf_relocate): Remove.
2486 (debug_sym_quick_functions): Update.
2487 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
2488 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
2491 2018-07-26 Tom Tromey <tromey@redhat.com>
2493 * dbxread.c (end_psymtab): Use text_high_valid and
2495 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
2496 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
2497 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2499 <text_low_valid, text_high_valid>: New fields.
2500 <set_text_low, set_text_high>: Update.
2501 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
2503 2018-07-26 Tom Tromey <tom@tromey.com>
2505 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
2507 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
2508 textlow and texthigh fields.
2509 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
2511 * mdebugread.c (parse_lines, parse_partial_symbols)
2512 (psymtab_to_symtab_1): Update.
2513 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2514 Rename fields. Update comment. Now private.
2515 <text_low, text_high, set_text_low, set_text_high>: New methods.
2516 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2517 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
2518 (start_psymtab_common, maintenance_info_psymtabs)
2519 (maintenance_check_psymtabs): Update.
2520 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
2522 (scan_xcoff_symtab): Update.
2524 2018-07-26 Tom Tromey <tromey@redhat.com>
2526 * psympriv.h (struct partial_symbol) <unrelocated_address,
2527 address, set_address>: New methods.
2528 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
2529 (fixup_psymbol_section, relocate_psymtabs): Update.
2530 (print_partial_symbols): Add 'objfile' parameter. Update.
2531 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
2534 2018-07-26 Tom Tromey <tom@tromey.com>
2536 * dwarf-index-write.c (write_psymbols, debug_names::insert)
2537 (debug_names::write_psymbols): Update.
2538 * psympriv.h (struct partial_symbol): Derive from
2539 general_symbol_info.
2540 <obj_section>: New method.
2541 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
2542 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2543 (find_pc_sect_psymbol, fixup_psymbol_section)
2544 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
2545 (print_partial_symbols, recursively_search_psymtabs)
2546 (compare_psymbols, psymbol_hash, psymbol_compare)
2547 (add_psymbol_to_bcache, maintenance_check_psymtabs)
2548 (psymbol_name_matches, psym_fill_psymbol_map): Update.
2550 2018-07-26 Tom Tromey <tromey@redhat.com>
2552 * dbxread.c (end_psymtab): Remove dead code.
2554 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
2556 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
2557 DWARF unwinders are disabled.
2558 * dwarf2-frame.c: Add dwarf2read.h include.
2559 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
2561 (dwarf2_frame_unwinders_enabled_p): Define.
2562 (show_dwarf_unwinders_enabled_p): New function.
2563 (_initialize_dwarf2_frame): Register switch to control DWARF
2565 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
2566 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
2567 (show_dwarf_cmdlist): Remove static keyword.
2568 * dwarf2read.h (set_dwarf_cmdlist): Declare.
2569 (show_dwarf_cmdlist): Declare.
2570 * NEWS: Document new feature.
2572 2018-07-26 Tom de Vries <tdevries@suse.de>
2574 PR breakpoints/23366
2575 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
2577 2018-07-26 Tom de Vries <tdevries@suse.de>
2579 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
2580 DW_AT_count can't be translated to a dynamic prop.
2582 2018-07-25 Tom de Vries <tdevries@suse.de>
2584 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
2587 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
2589 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
2591 2018-07-25 Joel Brobecker <brobecker@adacore.com>
2593 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
2595 2018-07-24 Keith Seitz <keiths@redhat.comt
2598 * dwarf2read.c (dw2_add_symbol_to_list): New function.
2599 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
2600 instead of add_symbol_to_list.
2601 (read_file_scope): Call prepare_one_comp_unit before reading
2604 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
2606 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
2608 2018-07-24 Tom Tromey <tom@tromey.com>
2610 * utils.c (malloc, realloc, free): Don't declare.
2611 * configure, config.in: Rebuild.
2612 * configure.ac: Don't check for declarations of free, malloc, or
2615 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2617 * aarch64-linux-nat.c
2618 (aarch64_linux_nat_target::stopped_data_address): Remove unused
2620 * arm-linux-nat.c (fetch_regs): Likewise.
2621 (store_regs): Likewise.
2622 (fetch_vfp_regs): Likewise.
2623 (store_vfp_regs): Likewise.
2624 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
2625 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
2626 (arm_linux_nat_target::insert_watchpoint): Likewise.
2627 (arm_linux_nat_target::remove_watchpoint): Likewise.
2628 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
2630 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
2632 * ppc-linux-nat.c (fetch_register): Likewise.
2633 (fetch_all_gp_regs): Likewise.
2634 (fetch_ppc_registers): Likewise.
2635 (store_all_gp_regs): Likewise.
2636 (store_ppc_registers): Likewise.
2637 (hwdebug_insert_point): Likewise.
2638 (can_use_watchpoint_cond_accel): Likewise.
2639 * remote-sim.c (gdb_os_write_stdout): Likewise.
2641 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2642 Tom Tromey <tom@tromey.com>
2644 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
2646 * configure: Rebuild.
2648 2018-07-22 Tom Tromey <tom@tromey.com>
2650 * regformats/regdat.sh: Define xmltarget_${name} inside
2651 #ifndef IN_PROCESS_AGENT.
2653 2018-07-22 Tom Tromey <tom@tromey.com>
2655 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
2657 2018-07-22 Tom Tromey <tom@tromey.com>
2659 * symfile.c (reread_symbols): Notify iter, not objfile.
2661 2018-07-22 Tom Tromey <tom@tromey.com>
2663 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
2665 (ravenscar_thread_target::prepare_to_store): Likewise.
2667 2018-07-22 Tom Tromey <tom@tromey.com>
2669 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
2670 unused variable. Call value_fetch_lazy when needed.
2671 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
2672 Remove unused variable. Call value_fetch_lazy when needed.
2674 2018-07-22 Tom Tromey <tom@tromey.com>
2676 * m32c-tdep.c (mark_dma): Return void.
2677 (make_regs): Remove unused declarations.
2679 2018-07-22 Tom Tromey <tom@tromey.com>
2681 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
2682 cmdscm_get_valid_command_smob_arg_unsafe for effect.
2683 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
2684 bkscm_get_valid_block_smob_arg_unsafe for effect.
2686 2018-07-22 Tom Tromey <tom@tromey.com>
2688 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
2691 2018-07-22 Tom Tromey <tom@tromey.com>
2693 * windows-nat.c (saved_context): Conditionally define.
2694 * remote.c (remote_target::remote_btrace_maybe_reopen):
2695 Conditionally declare "warned".
2696 * inflow.c (sigquit_ours): Conditionally define.
2697 (new_tty): Move "tty" declaration inside #if.
2698 * guile/guile.c (guile_datadir): Conditionally define.
2699 * charset.c (set_be_le_names): Move some declarations inside #if.
2700 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
2702 (parse_xml_btrace_conf): Likewise.
2704 2018-07-22 Tom Tromey <tom@tromey.com>
2706 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
2708 2018-07-22 Tom Tromey <tom@tromey.com>
2710 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
2711 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
2712 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
2713 * buildsym-legacy.c (get_macro_table): Remove unused variable.
2714 * stack.c (frame_apply_level_command): Remove unused variable.
2715 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
2716 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
2717 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
2719 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
2720 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
2721 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
2723 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
2724 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
2726 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
2727 Remove unused variable.
2728 * cli/cli-script.c (recurse_read_control_structure): Remove unused
2730 * common/tdesc.c (print_xml_feature::visit): Remove unused
2732 * compile/compile-object-load.c (store_regs): Remove unused
2734 * complaints.c (clear_complaints): Remove unused variable.
2735 * corelow.c (core_target_open): Remove unused variable.
2736 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
2738 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
2740 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
2742 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
2744 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
2746 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
2748 * ia64-tdep.c (examine_prologue): Remove unused variable.
2749 * infcall.c (run_inferior_call): Remove unused variable.
2750 * inferior.c (exit_inferior): Remove unused variable.
2751 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
2752 * linespec.c (decode_line_2): Remove unused variable.
2753 * linux-nat.c (super_close): Remove.
2754 * linux-tdep.c (linux_info_proc): Remove unused variable.
2755 * mi/mi-main.c (mi_execute_command): Remove unused variable.
2756 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
2757 Remove unused variable.
2758 * parse.c (find_minsym_type_and_address): Remove unused variable.
2759 * printcmd.c (info_symbol_command, printf_floating): Remove unused
2761 * python/py-breakpoint.c (bppy_set_commands): Remove unused
2763 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
2765 * record-btrace.c (record_btrace_target::store_registers): Remove
2767 (cmd_show_record_btrace_cpu): Remove unused variable.
2768 * riscv-tdep.c (riscv_register_reggroup_p)
2769 (riscv_push_dummy_call, riscv_return_value): Remove unused
2771 * rust-exp.y (literal): Remove unused variable.
2772 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
2774 <STRUCTOP_ANONYMOUS>: Likewise.
2775 * s390-linux-tdep.c (s390_linux_init_abi_31)
2776 (s390_linux_init_abi_64): Remove unused variable.
2777 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
2778 (file_select_thread, net_windows_open, _initialize_ser_windows):
2779 Remove unused variables.
2780 * symtab.c (find_pc_sect_line): Remove unused variable.
2781 * target-memory.c (compute_garbled_blocks): Remove unused
2783 (target_write_memory_blocks): Remove unused variable.
2784 * target.c (target_stack::unpush): Remove unused variables.
2785 * tracepoint.c (start_tracing, all_tracepoint_actions)
2786 (merge_uploaded_trace_state_variables)
2787 (print_one_static_tracepoint_marker): Remove unused variable.
2788 * unittests/basic_string_view/element_access/char/1.cc (test01):
2789 Remove unused variable.
2790 * windows-nat.c (windows_continue, windows_add_all_dlls)
2791 (do_initial_windows_stuff, windows_nat_target::create_inferior):
2792 Remove unused variables.
2794 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
2796 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
2797 attr_profile in HAVE_ELF.
2798 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
2801 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
2803 * frame.c (frame_register_unwind): Change parameter name.
2804 (frame_unwind_register): Likewise.
2805 (frame_unwind_register_value): Likewise.
2806 (frame_unwind_register_signed): Likewise.
2807 (frame_unwind_register_unsigned): Likewise.
2808 * frame.h (frame_register_unwind): Likewise.
2809 (frame_unwind_register): Likewise.
2810 (frame_unwind_register_value): Likewise.
2811 (frame_unwind_register_signed): Likewise.
2812 (frame_unwind_register_unsigned): Likewise.
2813 (frame_unwind_arch): Likewise.
2815 2018-07-20 Maciej W. Rozycki <macro@mips.com>
2817 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
2820 2018-07-20 Maciej W. Rozycki <macro@mips.com>
2822 * mips-linux-nat.c (mips_linux_nat_target::read_description):
2823 Call `get_ptrace_pid' rather than extracting the ptrace PID by
2826 2018-07-20 Keith Seitz <keiths@redhat.com>
2828 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
2829 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
2830 m_compunit_symtab, m_language>: Add "m_" prefix.
2832 * buildsym.c: Update all uses.
2834 2018-07-20 Tom Tromey <tom@tromey.com>
2836 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
2837 * buildsym.h (record_line_ftype): Remove typedef.
2839 2018-07-20 Tom Tromey <tom@tromey.com>
2841 * buildsym-legacy.h (augment_type_symtab): Don't declare.
2842 (end_expandable_symtab): Likewise.
2843 (end_symtab_get_static_block): Likewise.
2844 (end_symtab_from_static_block): Likewise.
2845 * buildsym-legacy.c (augment_type_symtab): Remove.
2846 (end_expandable_symtab): Remove.
2847 (end_symtab_get_static_block): Remove.
2848 (end_symtab_from_static_block): Remove.
2850 2018-07-20 Tom Tromey <tom@tromey.com>
2852 * dwarf2read.c: Include buildsym.h.
2853 (struct dwarf2_cu) <builder>: New method.
2854 (fixup_go_packaging): Update.
2855 (process_full_comp_unit, process_full_type_unit): Update. Don't
2856 use scoped_free_pendings.
2857 (using_directives): Add "cu" parameter, remove "language".
2858 (read_import_statement, setup_type_unit_groups, )
2859 (read_func_scope, read_lexical_block_scope)
2860 (dwarf2_record_block_ranges, read_namespace): Update.
2861 (lnp_state_machine::lnp_state_machine): Add cu parameter.
2862 (lnp_state_machine::handle_end_sequence): Update.
2863 (class lnp_state_machine) <m_cu>: New member.
2864 <m_record_line_callback>: Remove.
2865 <m_currently_recording_lines>: New member.
2866 (lnp_state_machine::handle_set_file): Update.
2867 (noop_record_line): Remove.
2868 (dwarf_record_line_p): Add cu parameter.
2869 (dwarf_record_line_1, dwarf_finish_line): Likewise.
2870 (lnp_state_machine::record_line)
2871 (lnp_state_machine::lnp_state_machine)
2872 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
2873 (dwarf_decode_lines): Update.
2874 (dwarf2_start_subfile): Add cu parameter.
2875 (dwarf2_start_symtab, new_symbol): Update.
2876 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
2877 Remove dwarf2_per_objfile parameter.
2878 (dwarf_decode_macros): Update.
2880 2018-07-20 Tom Tromey <tom@tromey.com>
2882 * stabsread.c (define_symbol): Update.
2883 * buildsym-legacy.h (get_buildsym_compunit): Declare.
2884 * dwarf2read.c (new_symbol): Update.
2885 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
2886 * cp-namespace.c: Include buildsym.h.
2887 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
2888 * buildsym-legacy.c (get_buildsym_compunit): New function.
2890 2018-07-20 Tom Tromey <tom@tromey.com>
2892 * xcoffread.c: Include buildsym-legacy.h.
2893 * windows-nat.c: Include buildsym-legacy.h.
2894 * stabsread.c: Include buildsym-legacy.h.
2895 * mdebugread.c: Include buildsym-legacy.h.
2896 * buildsym-legacy.h: New file.
2897 * buildsym-legacy.c: New file, from buildsym.c.
2898 * go32-nat.c: Include buildsym-legacy.h.
2899 * dwarf2read.c: Include buildsym-legacy.h.
2900 * dbxread.c: Include buildsym-legacy.h.
2901 * cp-namespace.c: Include buildsym-legacy.h.
2902 * coffread.c: Include buildsym-legacy.h.
2903 * buildsym.h: Move some contents to buildsym-legacy.h.
2904 * buildsym.c: Include buildsym-legacy.h. Move many functions to
2906 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
2908 2018-07-20 Tom Tromey <tom@tromey.com>
2910 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
2911 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
2912 (buildsym_compunit::buildsym_compunit)
2913 (buildsym_compunit::~buildsym_compunit)
2914 (buildsym_compunit::get_macro_table): Define.
2916 2018-07-20 Tom Tromey <tom@tromey.com>
2918 * buildsym.c (reset_symtab_globals): Remove.
2919 (buildsym_compunit::end_symtab_from_static_block): Update.
2920 (buildsym_compunit::augment_type_symtab): Update.
2921 (end_symtab_from_static_block): Call free_buildsym_compunit.
2922 (augment_type_symtab, end_symtab, end_expandable_symtab):
2925 2018-07-20 Tom Tromey <tom@tromey.com>
2927 * arch-utils.c: Do not include buildsym.h.
2928 * mipsread.c: Do not include buildsym.h.
2929 * machoread.c: Do not include buildsym.h.
2930 * elfread.c: Do not include buildsym.h.
2932 2018-07-20 Tom Tromey <tom@tromey.com>
2934 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
2936 (buildsym_compunit): Add new constructor.
2937 (struct buildsym_compunit) <get_last_source_file, finish_block,
2938 record_block_range, start_subfile, patch_subfile_names,
2939 push_subfile, pop_subfile, record_line, get_compunit_symtab,
2940 set_last_source_start_addr, get_last_source_start_addr,
2941 get_local_using_directives, set_local_using_directives,
2942 get_global_using_directives, outermost_context_p,
2943 get_current_context_stack, get_context_stack_depth,
2944 get_current_subfile, get_local_symbols, get_file_symbols,
2945 get_global_symbols, record_debugformat, record_producer,
2946 push_context, pop_context, end_symtab_get_static_block,
2947 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
2949 <record_pending_block, finish_block_internal, make_blockvector,
2950 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
2954 2018-05-22 Tom Tromey <tom@tromey.com>
2956 * buildsym.c (record_pending_block): Move earlier. Remove objfile
2958 (finish_block_internal): Update.
2960 2018-07-20 Tom Tromey <tom@tromey.com>
2962 * buildsym.c (record_pending_block): Move earlier. Remove objfile
2964 (finish_block_internal): Update.
2966 2018-07-20 Tom Tromey <tom@tromey.com>
2968 * buildsym.h (EXTERN): Don't define or undef.
2969 * buildsym.c (EXTERN): Don't define.
2971 2018-07-20 Tom Tromey <tom@tromey.com>
2973 * buildsym.c: Remove TODO comment.
2975 2018-07-20 Tom Tromey <tom@tromey.com>
2977 * coffread.c (coff_symtab_read): Update.
2978 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
2979 (xcoff_new_init): Update.
2980 * mipsread.c (mipscoff_new_init): Update.
2981 * mdebugread.c (mdebug_build_psymtabs): Update.
2982 * elfread.c (elf_new_init): Update.
2983 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
2985 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
2986 (coffstab_build_psymtabs, elfstab_build_psymtabs)
2987 (stabsect_build_psymtabs): Update.
2988 * buildsym.h (buildsym_init): Don't declare.
2989 * buildsym.c: Update comment.
2990 (prepare_for_building): Remove.
2991 (start_symtab, restart_symtab): Update.
2992 (reset_symtab_globals): Update comment.
2993 (buildsym_init): Remove.
2995 2018-07-20 Tom Tromey <tom@tromey.com>
2997 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
2998 * stabsread.c (patch_block_stabs, define_symbol, read_type)
2999 (read_enum_type, common_block_start, common_block_end)
3000 (cleanup_undefined_types_1, finish_global_stabs): Update.
3001 * mdebugread.c (psymtab_to_symtab_1): Update.
3002 * dwarf2read.c (fixup_go_packaging, read_func_scope)
3003 (read_lexical_block_scope, new_symbol): Update.
3004 * dbxread.c (process_one_symbol): Update.
3005 * coffread.c (coff_symtab_read, process_coff_symbol)
3006 (coff_read_enum_type): Update.
3007 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
3009 (get_local_symbols, get_file_symbols, get_global_symbols): New
3011 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
3013 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
3014 (~scoped_free_pendings): Update.
3015 (finish_block, prepare_for_building, reset_symtab_globals)
3016 (end_symtab_get_static_block, end_symtab_with_blockvector)
3017 (augment_type_symtab, push_context): Update.
3018 (get_local_symbols, get_file_symbols, get_global_symbols): New
3020 (buildsym_init): Update.
3022 2018-07-20 Tom Tromey <tom@tromey.com>
3024 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
3025 (process_full_type_unit): Likewise.
3026 (dwarf2_start_symtab): Set list_in_scope.
3028 2018-07-20 Tom Tromey <tom@tromey.com>
3030 * dwarf2read.c (process_psymtab_comp_unit_reader)
3031 (build_type_psymtabs_reader): Do not set list_in_scope.
3033 2018-07-20 Tom Tromey <tom@tromey.com>
3035 * buildsym.c (free_pendings): Remove.
3036 (add_symbol_to_list, scoped_free_pendings)
3037 (finish_block_internal, buildsym_init): Update.
3039 2018-07-20 Tom Tromey <tom@tromey.com>
3041 * xcoffread.c (read_xcoff_symtab): Update.
3042 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
3044 * dbxread.c (process_one_symbol): Update.
3045 * coffread.c (coff_symtab_read): Update.
3046 * buildsym.h (finish_block): Update.
3047 * buildsym.c (finish_block): Remove "listhead" argument.
3048 (end_symtab_get_static_block): Update.
3050 2018-07-20 Tom Tromey <tom@tromey.com>
3052 * buildsym.h (class scoped_free_pendings): Remove constructor.
3053 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
3055 <m_pending_block_obstack, m_pending_blocks>: New members.
3056 (pending_block_obstack, pending_blocks): Remove.
3057 (scoped_free_pendings::scoped_free_pendings): Default.
3058 (~scoped_free_pendings): Update.
3059 (free_pending_blocks): Remove.
3060 (finish_block_internal, record_pending_block, make_blockvector)
3061 (end_symtab_get_static_block, augment_type_symtab, push_context)
3062 (buildsym_init): Update.
3064 2018-07-20 Tom Tromey <tom@tromey.com>
3066 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
3067 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
3069 (pending_addrmap, pending_addrmap_obstack)
3070 (pending_addrmap_interesting): Remove.
3071 (scoped_free_pendings, record_block_range, make_blockvector)
3072 (prepare_for_building, reset_symtab_globals, buildsym_init):
3075 2018-07-20 Tom Tromey <tom@tromey.com>
3077 * xcoffread.c (process_linenos): Update.
3078 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
3079 * mdebugread.c (psymtab_to_symtab_1): Update.
3080 * dwarf2read.c (setup_type_unit_groups)
3081 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
3082 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
3083 * dbxread.c (process_one_symbol): Update.
3084 * coffread.c (coff_symtab_read, enter_linenos)
3085 (process_coff_symbol): Update.
3086 * buildsym.h (current_subfile): Don't declare.
3087 (get_current_subfile): Declare.
3088 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
3090 (start_subfile, free_buildsym_compunit, push_subfile)
3091 (prepare_for_building, start_symtab): Update.
3092 (get_current_subfile): New function.
3094 2018-07-20 Tom Tromey <tom@tromey.com>
3096 * coffread.c (coff_symtab_read): Update.
3097 * xcoffread.c (read_xcoff_symtab): Update.
3098 * dwarf2read.c (new_symbol): Update.
3099 (read_func_scope, read_lexical_block_scope): Update.
3100 * dbxread.c (process_one_symbol): Update.
3101 * buildsym.h (context_stack, context_stack_depth): Don't declare.
3102 (outermost_context_p): Remove macro.
3103 (outermost_context_p, get_current_context_stack)
3104 (get_context_stack_depth): Declare.
3105 (pop_context): Return struct context_stack.
3106 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
3108 (context_stack_size): Remove.
3109 (INITIAL_CONTEXT_STACK_SIZE): Remove.
3110 (prepare_for_building, end_symtab_get_static_block)
3111 (augment_type_symtab, push_context): Update.
3112 (pop_context): Return struct context_stack.
3113 (outermost_context_p, get_current_context_stack)
3114 (get_context_stack_depth): New functions.
3115 (buildsym_init): Update.
3117 2018-07-20 Tom Tromey <tom@tromey.com>
3119 * rust-exp.y: Now a pure parser. Update all rules.
3120 (%union): Move earlier.
3121 (current_parser, work_obstack): Remove globals.
3122 (rust_parser, ~rust_parser): Update.
3123 (class rust_parser) <copy_name, concat3, crate_name, super_name,
3124 lex_character, lex_number, lex_string, lex_identifier,
3125 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
3126 convert_name, convert_params_to_expression,
3127 convert_ast_to_expression, ast_basic_type, ast_operation,
3128 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
3129 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
3130 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
3131 ast_array_type, ast_slice_type, ast_reference_type,
3132 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
3133 (rust_parse): Update.
3134 (rustyyerror, rustyylex): Add parser parameter.
3135 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
3136 (rust_lex_stringish_test, rust_lex_test_sequence)
3137 (rust_lex_test_trailing_dot, rust_lex_test_completion)
3138 (rust_lex_test_push_back, rust_lex_tests): Update.
3140 2018-07-19 Pedro Alves <palves@redhat.com>
3142 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
3143 gdb::unique_xmalloc_ptr.
3144 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
3145 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
3146 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
3147 copy-initialization.
3148 * guile/scm-pretty-print.c (ppscm_print_children): Use
3149 gdb::unique_xmalloc_ptr instead of cleanups.
3150 (gdbscm_apply_val_pretty_printer): Remove cleanups.
3151 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
3152 gdb::unique_xmalloc_ptr.
3153 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3154 Adjust to use gdb::unique_xmalloc_ptr.
3155 * guile/scm-utils.c (extract_arg): Adjust.
3156 * guile/scm-value.c (gdbscm_value_field): Adjust to use
3157 gdb::unique_xmalloc_ptr instead of a cleanup.
3159 2018-07-19 Tom Tromey <tom@tromey.com>
3161 * utils.c (do_value_free_to_mark)
3162 (make_cleanup_value_free_to_mark): Remove.
3163 * utils.h (make_cleanup_value_free_to_mark): Remove.
3165 2018-07-19 Pedro Alves <palves@redhat.com>
3167 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
3168 forwarding reference.
3170 2018-07-18 Pedro Alves <palves@redhat.com>
3172 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
3173 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
3176 2018-07-18 Pedro Alves <palves@redhat.com>
3178 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
3180 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
3182 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
3183 directly instead of a cleanup.
3184 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
3185 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
3186 (vlscm_binop_gdbthrow): New, factored out from ...
3187 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
3188 (vlscm_rich_compare): Use gdbscm_wrap.
3189 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
3190 instead of a cleanup.
3191 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
3193 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3194 Use xfree directly instead of a cleanup.
3195 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
3196 Adjust to use gdbscm_wrap and scoped_value_mark.
3197 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
3198 (gdbscm_value_address, gdbscm_value_dereference)
3199 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
3201 (gdbscm_value_dynamic_type): Use scoped_value_mark.
3202 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
3204 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
3205 gdbscm_wrap and scoped_value_mark.
3206 (gdbscm_value_to_string): Use xfree directly instead of a
3207 cleanup. Move 'buffer' unique_ptr to TRY scope.
3208 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
3209 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
3211 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
3212 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
3214 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
3217 2018-07-18 Tom de Vries <tdevries@suse.de>
3219 * findvar.c (default_read_var_value): Also resolve dynamic type for
3220 LOC_OPTIMIZED_OUT vars.
3222 2018-07-18 Maciej W. Rozycki <macro@mips.com>
3224 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
3227 2018-07-17 Tom Tromey <tom@tromey.com>
3229 * guile/scm-param.c (pascm_set_func, pascm_show_func)
3230 (compute_enum_list, pascm_set_param_value_x)
3231 (gdbscm_parameter_value): Update.
3232 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
3233 (gdbscm_scm_to_host_string): Update.
3234 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
3236 * guile/scm-cmd.c (cmdscm_add_completion): Update.
3237 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
3238 * guile/scm-string.c (gdbscm_scm_to_string): Return
3240 (gdbscm_scm_to_host_string): Likewise.
3242 2018-07-17 Tom Tromey <tom@tromey.com>
3244 * guile/guile.c (gdbscm_eval_from_control_command): Update.
3245 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
3246 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
3247 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
3250 2018-07-17 Tom Tromey <tom@tromey.com>
3252 * guile/scm-param.c (pascm_signal_setshow_error): Update.
3253 * guile/guile-internal.h (gdbscm_exception_message_to_string):
3255 * guile/scm-cmd.c (cmdscm_function): Update.
3256 * guile/scm-pretty-print.c
3257 (ppscm_print_exception_unless_memory_error): Update.
3258 * guile/scm-exception.c (gdbscm_exception_message_to_string):
3259 Return unique_xmalloc_ptr.
3261 2018-07-17 Tom Tromey <tom@tromey.com>
3263 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
3266 2018-07-17 Jim Wilson <jimw@sifive.com>
3268 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
3269 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
3270 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
3271 unecessary braces after EF_RISCV_RVC test. Delete call to
3272 set_gdbarch_decr_pc_after_break.
3274 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
3275 RISCV_LAST_FP_REGNUM + 1.
3276 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
3278 2018-07-17 Tom Tromey <tom@tromey.com>
3280 * configure.ac: Remove --disable-gdbcli.
3281 * configure: Rebuild.
3282 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
3283 (SUBDIR_CLI_CFLAGS): Remove.
3284 (SFILES): Use SUBDIR_CLI_SRCS.
3285 (COMMON_OBS): Use SUBDIR_CLI_OBS.
3287 2018-07-17 Tom Tromey <tom@tromey.com>
3290 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
3292 2018-07-16 Jim Wilson <jimw@sifive.com>
3294 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
3296 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3298 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
3300 (libunwind_frame_sniffer): Likewise.
3301 (libunwind_frame_prev_register): Likewise.
3302 (libunwind_sigtramp_frame_sniffer): Likewise.
3303 * ia64-tdep.c (ia64_access_reg): Likewise.
3304 (ia64_access_rse_reg): Likewise.
3305 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
3306 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
3308 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3310 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
3312 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3314 * remote-sim.c (gdbsim_target::close,
3315 gdbsim_target::mourn_inferior): Remove unused variables.
3317 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
3319 * ia64-tdep.c (ktab_buf): New global.
3320 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
3321 (get_kernel_table): Adjust.
3323 2018-07-16 Tom Tromey <tom@tromey.com>
3325 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
3326 * dwarf2read.c (using_directives, new_symbol): Use
3327 outermost_context_p.
3328 * dbxread.c (process_one_symbol): Use outermost_context_p.
3329 * coffread.c (coff_symtab_read): Use outermost_context_p.
3331 2018-07-16 Tom Tromey <tom@tromey.com>
3333 * dwarf2read.c (using_directives, read_func_scope)
3334 (read_lexical_block_scope): Update.
3335 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
3336 * buildsym.h (local_using_directives, global_using_directives):
3338 (get_local_using_directives, set_local_using_directives)
3339 (get_global_using_directives): Declare.
3340 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
3341 m_global_using_directives>: New members.
3342 (finish_block_internal, prepare_for_building)
3343 (reset_symtab_globals, end_symtab_get_static_block)
3344 (push_context): Update.
3345 (get_local_using_directives, set_local_using_directives)
3346 (get_global_using_directives): New functions.
3347 (buildsym_init): Update.
3349 2018-07-16 Tom Tromey <tom@tromey.com>
3351 * xcoffread.c (xcoff_initial_scan): Don't call
3352 free_pending_blocks.
3353 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
3354 * buildsym.h (class scoped_free_pendings): Add constructor.
3355 (free_pending_blocks): Don't declare.
3356 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
3357 (free_pending_blocks): Now static.
3359 2018-07-16 Tom Tromey <tom@tromey.com>
3361 * buildsym.h (push_subfile, pop_subfile): Update declarations.
3362 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
3364 (struct subfile_stack): Remove.
3365 (subfile_stack): Remove.
3366 (push_subfile, pop_subfile, buildsym_init): Update.
3368 2018-07-16 Tom Tromey <tom@tromey.com>
3370 * buildsym.c (push_subfile): Use gdb_assert.
3371 (pop_subfile): Use gdb_assert.
3373 2018-07-16 Tom Tromey <tom@tromey.com>
3375 * buildsym.h (merge_symbol_lists): Remove.
3376 * buildsym.c (merge_symbol_lists): Remove.
3378 2018-07-16 Tom Tromey <tom@tromey.com>
3380 * stabsread.c (scan_file_globals): Update comment.
3381 * stabsread.h (scan_file_globals): Move from buildsym.h.
3382 * buildsym.h (scan_file_globals): Move to stabsread.h.
3384 2018-07-16 Tom Tromey <tom@tromey.com>
3386 * xcoffread.c (xcoff_new_init): Update.
3387 * mipsread.c (mipscoff_new_init): Update.
3388 * mdebugread.c (mdebug_build_psymtabs): Update.
3389 * elfread.c (elf_new_init): Update.
3390 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
3391 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
3392 * buildsym.h (buildsym_new_init): Don't declare.
3393 * buildsym.c (buildsym_new_init): Remove.
3395 2018-07-16 Tom Tromey <tom@tromey.com>
3397 * stabsread.h (within_function): Move from buildsym.h.
3398 * stabsread.c (start_stabs): Clear within_function.
3399 * coffread.c (coff_start_symtab): Clear within_function.
3400 * buildsym.h (within_function): Move to stabsread.h.
3401 * buildsym.c (prepare_for_building): Update.
3403 2018-07-16 Tom Tromey <tom@tromey.com>
3405 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
3406 * dwarf2read.c (dwarf2_start_symtab): Don't set
3407 processing_gcc_compilation.
3408 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
3410 2018-07-16 Tom Tromey <tom@tromey.com>
3412 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
3413 (next_symbol_text_func): Move from buildsym.h.
3414 * stabsread.c (hashname): Move from buildsym.c.
3415 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
3416 (next_symbol_text_func, hashname): Move to stabsread.h.
3417 * buildsym.c: Don't include bcache.h
3418 (hashname): Move to stasbread.c.
3420 2018-07-16 Tom Tromey <tom@tromey.com>
3422 * buildsym.h (context_stack_size): Don't declare.
3423 * buildsym.c (context_stack_size): New global.
3425 2018-07-16 Tom Tromey <tom@tromey.com>
3427 * dbxread.c (processing_acc_compilation): New global.
3428 * buildsym.h (processing_acc_compilation): Don't declare.
3430 2018-07-16 Tom Tromey <tom@tromey.com>
3432 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
3433 * dbxread.c (read_ofile_symtab): Update.
3434 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
3435 * buildsym.h (last_source_start_addr): Remove.
3436 (set_last_source_start_addr, get_last_source_start_addr):
3438 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
3440 (struct buildsym_compunit) <m_last_source_start_addr>: New
3442 (prepare_for_building): Remove start_addr parameter.
3443 (start_symtab, restart_symtab, end_symtab_get_static_block)
3444 (end_symtab_with_blockvector): Update.
3445 (set_last_source_start_addr, get_last_source_start_addr): New
3448 2018-07-16 Tom Tromey <tom@tromey.com>
3450 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
3452 (have_line_numbers): Remove.
3453 (record_line, prepare_for_building, end_symtab_get_static_block)
3454 (augment_type_symtab): Update.
3456 2018-07-16 Tom Tromey <tom@tromey.com>
3458 * buildsym.c (~buildsym_compunit): Free the macro table.
3459 (struct buildsym_compunit) <get_macro_table, release_macros>: New
3461 <m_pending_macros>: New member.
3462 (pending_macros): Remove.
3463 (~scoped_free_pendings, get_macro_table, prepare_for_building)
3464 (reset_symtab_globals, end_symtab_get_static_block)
3465 (end_symtab_with_blockvector, augment_type_symtab)
3466 (buildsym_init): Update.
3468 2018-07-16 Tom Tromey <tom@tromey.com>
3470 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
3472 (buildsym_compunit::set_last_source_file): New method.
3473 <m_last_source_file>: New member.
3474 (prepare_for_building): Remove "name" parameter.
3475 (start_symtab, restart_symtab, reset_symtab_globals): Update.
3476 (last_source_file): Remove.
3477 (set_last_source_file, get_last_source_file): Update.
3479 2018-07-16 Tom Tromey <tom@tromey.com>
3481 * buildsym.c (prepare_for_building): Add assert.
3483 2018-07-16 Tom Tromey <tom@tromey.com>
3485 * buildsym.c (~buildsym_compunit): Update.
3486 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
3487 (start_subfile, patch_subfile_names)
3488 (end_symtab_with_blockvector): Update.
3490 2018-07-16 Tom Tromey <tom@tromey.com>
3492 * buildsym.c (struct buildsym_compunit): Add constructor,
3493 destructor, initializers.
3494 (start_buildsym_compunit): Remove.
3495 (free_buildsym_compunit): Use "delete".
3496 (start_symtab, restart_symtab): Use "new".
3498 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
3500 * symfile.c (set_objfile_default_section_offset): Remove struct
3503 2018-07-14 Stafford Horne <shorne@gmail.com>
3505 * (Responsible Maintainers): Add myself as or1k maintainer.
3507 2018-07-13 Tom Tromey <tom@tromey.com>
3509 * symfile.c (set_objfile_default_section_offset): Use extra braces
3512 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
3514 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
3517 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3519 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3520 unittests/cli-utils-selftests.c
3521 * unittests/cli-utils-selftests.c: New file.
3523 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3525 * NEWS: Mention new commands. Mention change to 'thread apply'.
3527 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3529 * thread.c (thr_try_catch_cmd): New function.
3530 (thread_apply_all_command): Handle qcs flags.
3531 (thread_apply_command): Handle qcs flags.
3532 (taas_command): New function.
3533 (tfaas_command): New function.
3534 (_initialize_thread): Update to setup the new commands 'taas
3535 and 'tfaas'. Change doc string for 'thread apply'.
3537 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3539 * stack.c: (trailing_outermost_frame): New function, mostly
3540 extracted from backtrace_command_1.
3541 (leading_innermost_frame): New function.
3542 (backtrace_command_1): Update to call trailing_outermost_frame.
3543 (frame_apply_command_count): New function.
3544 (frame_apply_level_command): New function.
3545 (frame_apply_all_command): New function.
3546 (frame_apply_command): New function.
3547 (faas_command): New function.
3548 (frame_cmd_list): New variable.
3549 (_initialize_stack): Update to setup the new commands 'frame apply'
3552 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3554 * cli-utils.c (number_or_range_parser::get_number): Only handle
3555 numbers or convenience var as numbers.
3556 (parse_flags): New function.
3557 (parse_flags_qcs): New function.
3558 (number_or_range_parser::finished): Ensure parsing end is detected
3559 before end of string.
3560 * cli-utils.h (parse_flags): New function.
3561 (parse_flags_qcs): New function.
3562 (number_or_range_parser): Remove m_finished bool.
3563 (number_or_range_parser::skip_range): Set m_in_range to false.
3565 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
3567 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
3570 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3571 Jan Kratochvil <jan.kratochvil@redhat.com>
3572 Paul Fertser <fercerpav@gmail.com>
3573 Tsutomu Seki <sekiriki@gmail.com>
3574 Pedro Alves <palves@redhat.com>
3576 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3577 'unittests/parse-connection-spec-selftests.c'.
3578 (COMMON_SFILES): Add 'common/netstuff.c'.
3579 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
3580 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
3581 * common/netstuff.c: New file.
3582 * common/netstuff.h: New file.
3583 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
3584 (wait_for_connect): Update comment. New parameter
3585 'gdb::optional<int> sock' instead of 'struct serial *scb'.
3586 Use 'sock' directly instead of 'scb->fd'.
3587 (try_connect): New function, with code from 'net_open'.
3588 (net_open): Rewrite main loop to deal with multiple
3589 sockets/addresses. Handle IPv6-style hostnames; implement
3590 support for IPv6 connections.
3591 * unittests/parse-connection-spec-selftests.c: New file.
3593 2018-07-11 Pedro Alves <palves@redhat.com>
3596 * remote.c (remote_target::remote_detach_pid): Call
3597 set_current_process.
3599 2018-07-11 Pedro Alves <palves@redhat.com>
3601 * h8300-tdep.c (h8300_gdbarch_init): Remove
3602 set_gdbarch_ecoff_reg_to_regnum calls.
3604 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3607 * c-typeprint.c (c_type_print_base_struct_union): Don't print
3608 offsets/sizes for static members of a class/struct.
3610 2018-07-11 Alan Hayward <alan.hayward@arm.com>
3612 * target-descriptions.c (tdesc_register_bitsize): Rename.
3613 * target-descriptions.h (tdesc_register_bitsize): Likewise.
3614 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
3615 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
3617 2018-07-10 Tom Tromey <tom@tromey.com>
3619 * breakpoint.c (moribund_locations): Now static and a
3621 (breakpoint_init_inferior, moribund_breakpoint_here_p)
3622 (build_bpstat_chain, update_global_location_list)
3623 (breakpoint_retire_moribund): Update.
3624 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
3627 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
3629 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
3630 (riscv_register_reggroup_p): Use new function, remove unneeded
3632 (riscv_push_dummy_call): Extend assert to compare against xlen or
3633 flen based on register type.
3635 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
3637 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
3639 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
3641 * remote.c (show_hardware_watchpoint_limit): New function.
3642 (show_hardware_watchpoint_length_limit): New function.
3643 (show_hardware_breakpoint_limit): New function.
3644 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
3645 where appropriate, update help text.
3647 2018-07-09 Tom Tromey <tom@tromey.com>
3649 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
3650 (CLIBS): Don't mention NAT_CLIBS.
3652 2018-07-09 Tom Tromey <tom@tromey.com>
3654 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
3655 (LIBGDB_OBS, clean mostlyclean): Update.
3656 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
3658 2018-07-09 Tom Tromey <tom@tromey.com>
3660 * Makefile.in (%.c: %.y): Use ECHO_YACC.
3661 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
3662 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
3664 2018-07-09 Tom Tromey <tom@tromey.com>
3666 * Makefile.in (ALLDEPFILES): Remove exec.c.
3667 (COMMON_OBS): Remove exec.o.
3668 (COMMON_SFILES): Add exec.c.
3670 2018-07-09 Tom Tromey <tom@tromey.com>
3672 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
3674 2018-07-09 Tom Tromey <tom@tromey.com>
3676 * Makefile.in (clean mostlyclean): Remove stamp-version.
3677 (version.c): Depend on stamp-version.
3678 (stamp-version): New rule, from version.c rule.
3680 2018-07-09 Tom Tromey <tom@tromey.com>
3682 * Makefile.in (init.c): Depend on stamp-init.
3683 (stamp-init): New rule, from init.c rule.
3684 (clean mostlyclean): Remove stamp-init.
3686 2018-07-09 Tom Tromey <tom@tromey.com>
3688 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
3689 SUBDIR_GCC_COMPILE_SRCS.
3691 2018-07-09 Tom Tromey <tom@tromey.com>
3693 * Makefile.in (init.c): Remove some unused sed rules.
3695 2018-07-09 Tom Tromey <tom@tromey.com>
3697 * Makefile.in (TSOBS): Remove.
3698 (INIT_FILES): Update.
3699 (LIBGDB_OBS): Update.
3700 (COMMON_SFILES): Add inflow.c.
3701 (SFILES): Remove inflow.c.
3703 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
3705 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
3707 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
3709 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
3710 get_saveloc_name, is_signal_frame_name, step_name,
3711 init_remote_name, create_addr_space_name,
3712 destroy_addr_space_name, search_unwind_table_name,
3713 find_dyn_list_name): Constify.
3715 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
3717 * darwin-nat.c (darwin_pthread_kill): New function.
3718 (darwin_resume_thread): Use darwin_pthread_kill.
3720 2018-07-05 Tom de Vries <tdevries@suse.de>
3722 * macroexp.c (macro_buffer) <operator=>: New member function.
3724 2018-07-04 Tom Tromey <tom@tromey.com>
3726 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
3728 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
3730 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
3731 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
3732 * maint.c: Likewise.
3735 2018-07-04 Joel Brobecker <brobecker@adacore.com>
3737 * NEWS: Create a new section for the next release branch.
3738 Rename the section of the current branch, now that it has
3741 2018-07-04 Joel Brobecker <brobecker@adacore.com>
3743 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
3744 * version.in: Bump version to 8.2.50.DATE-git.
3746 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
3747 Pedro Alves <palves@redhat.com>
3749 * linux-nat.c (linux_init_ptrace): Rename to ...
3750 (linux_init_ptrace_procfs): ... this. Call
3751 linux_proc_init_warnings.
3752 (linux_nat_target::post_attach)
3753 (linux_nat_target::post_startup_inferior): Adjust.
3754 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
3755 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
3757 2018-07-04 Tom de Vries <tdevries@suse.de>
3759 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
3761 (read_comp_unit_head): ... here.
3763 2018-07-03 Tom Tromey <tom@tromey.com>
3765 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
3766 (stop_tracing, tstatus_command)
3767 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
3768 (print_one_static_tracepoint_marker): Update.
3769 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
3771 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
3773 (all_tracepoints, static_tracepoints_here): Return std::vector.
3775 2018-07-03 Tom Tromey <tom@tromey.com>
3777 * common/ptid.c (ptid_equal): Remove.
3778 * common/ptid.h (ptid_equal): Don't declare.
3779 * ada-tasks.c: Update.
3780 * breakpoint.c: Update.
3781 * common/agent.c: Update.
3782 * corelow.c: Update.
3783 * darwin-nat-info.c: Update.
3784 * darwin-nat.c: Update.
3786 * dtrace-probe.c: Update.
3787 * dummy-frame.c: Update.
3788 * fbsd-nat.c: Update.
3790 * gdbthread.h: Update.
3791 * gnu-nat.c: Update.
3792 * go32-nat.c: Update.
3793 * inf-loop.c: Update.
3794 * inf-ptrace.c: Update.
3795 * infcall.c: Update.
3799 * linux-fork.c: Update.
3800 * linux-nat.c: Update.
3801 * linux-thread-db.c: Update.
3802 * mi/mi-cmd-var.c: Update.
3803 * mi/mi-interp.c: Update.
3804 * mi/mi-main.c: Update.
3805 * nto-procfs.c: Update.
3806 * ppc-linux-tdep.c: Update.
3808 * python/py-inferior.c: Update.
3809 * python/py-record-btrace.c: Update.
3810 * python/py-record.c: Update.
3811 * ravenscar-thread.c: Update.
3812 * regcache.c: Update.
3813 * remote-sim.c: Update.
3815 * sol-thread.c: Update.
3818 * tui/tui-stack.c: Update.
3820 * windows-nat.c: Update.
3821 * windows-tdep.c: Update.
3823 2018-07-03 Tom Tromey <tom@tromey.com>
3825 * common/ptid.c (ptid_match): Remove.
3826 * common/ptid.h (ptid_match): Don't declare.
3827 * fbsd-nat.c: Update.
3830 * linux-nat.c: Update.
3831 * record-btrace.c: Update.
3832 * regcache.c: Update.
3835 2018-07-03 Tom Tromey <tom@tromey.com>
3837 * common/ptid.c (ptid_tid_p): Remove.
3838 * common/ptid.h (ptid_tid_p): Don't declare.
3839 * sol-thread.c: Update.
3841 2018-07-03 Tom Tromey <tom@tromey.com>
3843 * common/ptid.c (ptid_lwp_p): Remove.
3844 * common/ptid.h (ptid_lwp_p): Don't declare.
3845 * fbsd-nat.c: Update.
3846 * linux-nat.c: Update.
3847 * nat/linux-procfs.c: Update.
3848 * nat/x86-linux-dregs.c: Update.
3849 * sol-thread.c: Update.
3851 2018-07-03 Tom Tromey <tom@tromey.com>
3853 * common/ptid.c (ptid_is_pid): Remove.
3854 * common/ptid.h (ptid_is_pid): Don't declare.
3856 * linux-nat.c: Update.
3857 * mi/mi-interp.c: Update.
3861 2018-07-03 Tom Tromey <tom@tromey.com>
3863 * common/ptid.c (ptid_get_tid): Remove.
3864 * common/ptid.h (ptid_get_tid): Don't declare.
3865 * ada-tasks.c: Update.
3866 * aix-thread.c: Update.
3867 * bsd-uthread.c: Update.
3868 * darwin-nat.c: Update.
3869 * fbsd-nat.c: Update.
3870 * i386-darwin-nat.c: Update.
3872 * linux-tdep.c: Update.
3873 * nto-procfs.c: Update.
3874 * ppc-ravenscar-thread.c: Update.
3875 * python/py-infthread.c: Update.
3876 * ravenscar-thread.c: Update.
3877 * sol-thread.c: Update.
3878 * sparc-ravenscar-thread.c: Update.
3879 * windows-nat.c: Update.
3881 2018-07-03 Tom Tromey <tom@tromey.com>
3883 * common/ptid.c (ptid_get_lwp): Remove.
3884 * common/ptid.h (ptid_get_lwp): Don't declare.
3885 * aarch64-linux-nat.c: Update.
3886 * ada-tasks.c: Update.
3887 * aix-thread.c: Update.
3888 * amd64-linux-nat.c: Update.
3889 * arm-linux-nat.c: Update.
3890 * corelow.c: Update.
3891 * fbsd-nat.c: Update.
3892 * fbsd-tdep.c: Update.
3893 * gnu-nat.c: Update.
3894 * i386-cygwin-tdep.c: Update.
3895 * i386-gnu-nat.c: Update.
3896 * i386-linux-nat.c: Update.
3897 * ia64-linux-nat.c: Update.
3898 * inf-ptrace.c: Update.
3900 * linux-fork.c: Update.
3901 * linux-nat.c: Update.
3902 * linux-tdep.c: Update.
3903 * linux-thread-db.c: Update.
3904 * mips-linux-nat.c: Update.
3905 * nat/aarch64-linux-hw-point.c: Update.
3906 * nat/aarch64-linux.c: Update.
3907 * nat/linux-btrace.c: Update.
3908 * nat/linux-osdata.c: Update.
3909 * nat/linux-procfs.c: Update.
3910 * nat/x86-linux-dregs.c: Update.
3911 * obsd-nat.c: Update.
3912 * ppc-fbsd-nat.c: Update.
3913 * ppc-linux-nat.c: Update.
3915 * python/py-infthread.c: Update.
3916 * ravenscar-thread.c: Update.
3918 * s390-linux-nat.c: Update.
3919 * sol-thread.c: Update.
3920 * sol2-tdep.c: Update.
3921 * spu-linux-nat.c: Update.
3922 * x86-linux-nat.c: Update.
3923 * xtensa-linux-nat.c: Update.
3925 2018-07-03 Tom Tromey <tom@tromey.com>
3927 * common/ptid.c (ptid_get_pid): Remove.
3928 * common/ptid.h (ptid_get_pid): Don't declare.
3929 * aarch64-linux-nat.c: Update.
3930 * ada-lang.c: Update.
3931 * aix-thread.c: Update.
3932 * alpha-bsd-nat.c: Update.
3933 * amd64-fbsd-nat.c: Update.
3934 * amd64-linux-nat.c: Update.
3935 * arm-linux-nat.c: Update.
3936 * arm-nbsd-nat.c: Update.
3938 * break-catch-syscall.c: Update.
3939 * breakpoint.c: Update.
3940 * bsd-uthread.c: Update.
3941 * corelow.c: Update.
3943 * darwin-nat.c: Update.
3944 * fbsd-nat.c: Update.
3945 * fbsd-tdep.c: Update.
3947 * gnu-nat.c: Update.
3948 * hppa-nbsd-nat.c: Update.
3949 * hppa-obsd-nat.c: Update.
3950 * i386-fbsd-nat.c: Update.
3951 * ia64-linux-nat.c: Update.
3952 * inf-ptrace.c: Update.
3954 * inferior.c: Update.
3955 * inferior.h: Update.
3958 * linux-fork.c: Update.
3959 * linux-nat.c: Update.
3960 * linux-tdep.c: Update.
3961 * linux-thread-db.c: Update.
3962 * m68k-bsd-nat.c: Update.
3963 * mi/mi-interp.c: Update.
3964 * mi/mi-main.c: Update.
3965 * mips-linux-nat.c: Update.
3966 * mips-nbsd-nat.c: Update.
3967 * mips64-obsd-nat.c: Update.
3968 * nat/aarch64-linux-hw-point.c: Update.
3969 * nat/aarch64-linux.c: Update.
3970 * nat/linux-btrace.c: Update.
3971 * nat/linux-osdata.c: Update.
3972 * nat/linux-procfs.c: Update.
3973 * nat/x86-linux-dregs.c: Update.
3974 * nto-procfs.c: Update.
3975 * obsd-nat.c: Update.
3976 * ppc-linux-nat.c: Update.
3977 * ppc-nbsd-nat.c: Update.
3978 * ppc-obsd-nat.c: Update.
3979 * proc-service.c: Update.
3981 * python/py-inferior.c: Update.
3982 * python/py-infthread.c: Update.
3983 * ravenscar-thread.c: Update.
3985 * remote-sim.c: Update.
3987 * rs6000-nat.c: Update.
3988 * s390-linux-nat.c: Update.
3989 * sh-nbsd-nat.c: Update.
3990 * sol-thread.c: Update.
3991 * sparc-nat.c: Update.
3992 * sparc64-tdep.c: Update.
3993 * spu-linux-nat.c: Update.
3994 * spu-tdep.c: Update.
3995 * target-debug.h: Update.
3998 * tid-parse.c: Update.
3999 * tracefile-tfile.c: Update.
4000 * vax-bsd-nat.c: Update.
4001 * windows-nat.c: Update.
4002 * x86-linux-nat.c: Update.
4003 * x86-nat.c: Update.
4005 2018-07-03 Tom Tromey <tom@tromey.com>
4007 * common/ptid.c (pid_to_ptid): Remove.
4008 * common/ptid.h (pid_to_ptid): Don't declare.
4009 * aix-thread.c: Update.
4010 * arm-linux-nat.c: Update.
4011 * common/ptid.c: Update.
4012 * common/ptid.h: Update.
4013 * corelow.c: Update.
4015 * darwin-nat.c: Update.
4016 * fbsd-nat.c: Update.
4017 * fork-child.c: Update.
4018 * gnu-nat.c: Update.
4019 * go32-nat.c: Update.
4020 * inf-ptrace.c: Update.
4022 * inferior.c: Update.
4024 * linux-fork.c: Update.
4025 * linux-nat.c: Update.
4026 * nat/aarch64-linux-hw-point.c: Update.
4027 * nat/fork-inferior.c: Update.
4028 * nat/x86-linux-dregs.c: Update.
4029 * nto-procfs.c: Update.
4030 * obsd-nat.c: Update.
4032 * progspace.c: Update.
4034 * rs6000-nat.c: Update.
4035 * s390-linux-nat.c: Update.
4036 * sol-thread.c: Update.
4037 * spu-linux-nat.c: Update.
4040 * tracefile-tfile.c: Update.
4041 * windows-nat.c: Update.
4043 2018-07-03 Tom Tromey <tom@tromey.com>
4045 * common/ptid.h (ptid_build): Don't declare.
4046 * common/ptid.c (ptid_build): Remove.
4047 * aix-thread.c: Update.
4048 * bsd-kvm.c: Update.
4049 * bsd-uthread.c: Update.
4050 * common/agent.c: Update.
4051 * common/ptid.c: Update.
4052 * common/ptid.h: Update.
4053 * corelow.c: Update.
4054 * darwin-nat.c: Update.
4055 * fbsd-nat.c: Update.
4056 * gnu-nat.c: Update.
4057 * linux-fork.c: Update.
4058 * linux-nat.c: Update.
4059 * linux-thread-db.c: Update.
4060 * nat/linux-osdata.c: Update.
4061 * nat/linux-procfs.c: Update.
4062 * nto-procfs.c: Update.
4063 * obsd-nat.c: Update.
4064 * proc-service.c: Update.
4066 * ravenscar-thread.c: Update.
4067 * remote-sim.c: Update.
4069 * sol-thread.c: Update.
4071 * windows-nat.c: Update.
4073 2018-07-03 Tom Tromey <tom@tromey.com>
4075 * infrun.c (follow_exec): Use exit_inferior_silent.
4076 * inferior.c (exit_inferior_num_silent): Remove.
4077 * inferior.h (exit_inferior_num_silent): Don't declare.
4079 2018-07-03 Tom Tromey <tom@tromey.com>
4082 * darwin-nat.c (darwin_attach_pid): Reset inferior and
4083 inferior_ptid on error.
4085 2018-07-02 Maciej W. Rozycki <macro@mips.com>
4086 Simon Marchi <simon.marchi@polymtl.ca>
4089 * disasm.h (gdb_disassembler): Add
4090 `m_disassembler_options_holder'. member
4091 * disasm.c (get_all_disassembler_options): New function.
4092 (gdb_disassembler::gdb_disassembler): Use it.
4093 (gdb_buffered_insn_length_init_dis): Likewise.
4094 (gdb_buffered_insn_length): Adjust accordingly.
4095 (set_disassembler_options): Handle options with arguments.
4096 (show_disassembler_options_sfunc): Likewise. Add a leading new
4097 line if showing options with descriptions.
4098 (disassembler_options_completer): Adapt to using the
4099 `disasm_options_and_args_t' structure.
4100 * mips-tdep.c (mips_disassembler_options): New variable.
4101 (mips_disassembler_options_o32): Likewise.
4102 (mips_disassembler_options_n32): Likewise.
4103 (mips_disassembler_options_n64): Likewise.
4104 (gdb_print_insn_mips): Don't set `disassembler_options'.
4105 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
4107 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
4108 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
4109 `gdbarch_disassembler_options_implicit' and
4110 `gdbarch_valid_disassembler_options'.
4111 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
4112 `disasm_options_and_args_t' structure.
4113 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
4115 (valid_disassembler_options): Switch from `disasm_options_t' to
4116 the `disasm_options_and_args_t' structure.
4117 * NEWS: Document `set disassembler-options' support for the MIPS
4119 * gdbarch.h: Regenerate.
4120 * gdbarch.c: Regenerate.
4122 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
4124 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
4126 2018-06-29 Joel Brobecker <brobecker@adacore.com>
4128 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
4129 parameter in call to amd64_target_description.
4130 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
4131 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
4132 (amd64fbsd_init_abi): Likewise.
4133 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
4134 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
4135 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
4136 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
4138 2018-06-29 Pedro Alves <palves@redhat.com>
4140 * gdb/amd64-tdep.h (amd64_create_target_description): Add
4141 "segments" parameter.
4142 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
4143 (_initialize_amd64_tdep): Update call to
4144 amd64_create_target_description.
4145 (amd64_target_description): Add "segments" parameter. Adjust
4146 the implementation to use it.
4147 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
4148 call to amd64_create_target_description.
4149 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
4150 * gdb/arch/amd64.h (amd64_create_target_description): Add
4151 "segments" register.
4152 * gdb/arch/amd64.c (amd64_create_target_description): Add
4153 "segments" parameter. Call create_feature_i386_64bit_segments
4154 only if SEGMENTS is true.
4155 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
4156 call to amd64_create_target_description.
4158 2018-06-29 Pedro Alves <palves@redhat.com>
4160 * thread.c (thread_target_id_str): New, factored out from ...
4161 (print_thread_info_1): ... here. Use it to compute the max
4162 "Target Id" column width.
4164 2018-06-29 Pedro Alves <palves@redhat.com>
4166 * remote.c (remote_target::extra_thread_info): Delete
4167 'display_buf' and 'n' locals. from the cache, regardless of
4168 packet mechanims is in use. Use cache for qThreadExtra and qP
4171 2018-06-29 Pedro Alves <palves@redhat.com>
4173 * blockframe.c (find_pc_sect_containing_function): New function.
4174 * breakpoint.c (print_breakpoint_location): Don't call
4175 find_pc_sect_function.
4176 * linespec.c (create_sals_line_offset): Record the location's
4178 * linespec.c (convert_address_location_to_sals): Fill in sal's
4179 symbol with find_pc_sect_containing_function.
4180 * symtab.c (find_function_start_sal): Rename to ...
4181 (find_function_start_sal_1): ... this.
4182 (find_function_start_sal): Reimplement as wrapper around
4183 find_function_start_sal_1, and use
4184 find_pc_sect_containing_function to fill in the sal's symbol.
4185 (find_function_start_sal(symbol*, bool)): Adjust.
4186 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
4188 (find_pc_sect_containing_function): Declare.
4190 2018-06-29 Pedro Alves <palves@redhat.com>
4192 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
4193 true if the the location has no symbol.
4195 2018-06-28 Tom Tromey <tom@tromey.com>
4197 * NEWS: Mention --enable-codesign.
4198 * silent-rules.mk (ECHO_SIGN): New variable.
4199 * configure.ac: Add --enable-codesign.
4200 * configure: Rebuild.
4201 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
4202 (gdb$(EXEEXT)): Optionally invoke codesign.
4204 2018-06-28 Pedro Alves <palves@redhat.com>
4206 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
4208 (switch_to_thread_no_regs): Adjust comment.
4209 * infcmd.c (stop_pc): Delete.
4210 (post_create_inferior, info_program_command): Replace references
4211 to stop_pc with references to thread_info->suspend.stop_pc.
4212 * inferior.h (stop_pc): Delete declaration.
4213 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
4214 (handle_inferior_event_1, handle_signal_stop)
4215 (process_event_stop_test, keep_going_stepped_thread)
4216 (handle_step_into_function, handle_step_into_function_backward)
4217 (print_stop_location): Replace references to stop_pc with
4218 references to thread_info->suspend.stop_pc.
4219 (struct infcall_suspend_state) <stop_pc>: Delete field.
4220 (save_infcall_suspend_state, restore_infcall_suspend_state):
4221 Remove references to inf_stat->stop_pc.
4222 * linux-fork.c (fork_load_infrun_state): Likewise.
4223 * record-btrace.c (record_btrace_set_replay): Likewise.
4224 * record-full.c (record_full_goto_entry): Likewise.
4225 * remote.c (print_one_stopped_thread): Likewise.
4226 * target.c (target_resume): Extend comment.
4227 * thread.c (set_executing_thread): New.
4228 (set_executing): Use it.
4229 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
4230 Remove references to stop_pc.
4232 2018-06-28 Pedro Alves <palves@redhat.com>
4234 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
4235 Moving fetching stop_pc until after ecs->event_thread is refreshed.
4237 2018-06-28 Tom Tromey <tom@tromey.com>
4239 * coffread.c (coff_symfile_finish): Update.
4240 * xcoffread.c (xcoff_symfile_finish): Update.
4241 * elfread.c (elf_symfile_finish): Update.
4242 * symfile.h (dwarf2_free_objfile): Don't declare.
4243 * dwarf2read.c (_initialize_dwarf2_read): Use
4244 register_objfile_data_with_cleanup.
4245 (dwarf2_free_objfile): Now static. Change signature.
4247 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4249 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
4250 option "-o" to add-symbol-file-load to add an offset to each
4251 section's load address.
4252 * symfile.c (set_objfile_default_section_offset): New function.
4254 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4256 * symfile.c (add_symbol_file_command): Make sure that sections
4257 with the same name are sorted in the same order.
4259 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4261 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
4262 require the second argument. If omitted, load sections at the
4263 addresses specified in the file.
4265 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4267 * symfile.c (symbol_file_command, symbol_file_add_main_1)
4268 (_initialize_symfile): Add option "-o" to symbol-file to add an
4269 offset to each section of the symbol file.
4271 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4273 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
4275 2018-06-27 Tom Tromey <tom@tromey.com>
4277 * stack.c (_initialize_stack): Update "func" help text.
4279 2018-06-27 Tom Tromey <tom@tromey.com>
4281 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
4283 (unwind_infopy_str, pyuw_create_unwind_info)
4284 (unwind_infopy_add_saved_register, pyuw_sniffer)
4285 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
4287 (struct saved_reg): Add constructor.
4288 <value>: Now a gdbpy_ref<>.
4290 2018-06-27 Tom Tromey <tom@tromey.com>
4292 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
4294 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4296 * gdb-gdb.py.in: Format using autopep8.
4298 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4300 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
4301 (type_lookup_function): Recognize CORE_ADDR values.
4303 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4305 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
4308 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4310 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
4313 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4315 * gdb-gdb.py: Move to...
4316 * gdb-gdb.py.in: ... here.
4317 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
4318 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
4320 (distclean): Remove gdb-gdb.py when cleaning.
4321 (gdb-gdb.py, gdb-gdb.gdb): New rules.
4322 * configure: Re-generate.
4324 2018-06-27 Pedro Alves <palves@redhat.com>
4326 * proc-service.c (get_ps_regcache): New.
4327 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
4328 (ps_lsetfpregs): Use it.
4330 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
4333 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
4334 (dwarf_decode_lines_1): Adjust.
4336 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4338 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
4340 <info_proc>: Likewise.
4342 2018-06-26 Joel Brobecker <brobecker@adacore.com>
4344 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
4345 to windows_fetch_one_register, and only handle the case of
4346 fetching one register. Move the code that reloads the context
4347 and iterates over all registers if R is negative to...
4348 (windows_nat_target::fetch_registers): ... here.
4349 (do_windows_store_inferior_registers): Rename to
4350 windows_store_one_register, and only handle the case of storing
4351 one register. Move the code that handles the case where r is
4353 (windows_nat_target::store_registers) ... here.
4355 2018-06-26 Tom Tromey <tom@tromey.com>
4358 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
4359 * rust-lang.c (rust_print_struct_def): Add podata parameter.
4361 (rust_internal_print_type): Add podata parameter.
4362 (rust_print_type): Update.
4364 2018-06-26 Tom Tromey <tom@tromey.com>
4366 * typeprint.h (struct print_offset_data) <update, finish,
4367 maybe_print_hole>: New methods.
4368 <indentation>: New constant.
4369 * typeprint.c (print_offset_data::indentation): Define.
4370 (print_offset_data::maybe_print_hole, print_offset_data::update)
4371 (print_offset_data::finish): Move from c-typeprint.c and rename.
4372 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
4373 (print_spaces_filtered_with_print_options): Update.
4374 (c_print_type_union_field_offset, maybe_print_hole)
4375 (c_print_type_struct_field_offset): Move to typeprint.c and
4377 (c_type_print_base_struct_union): Update.
4379 2018-06-25 Pedro Alves <palves@redhat.com>
4381 * gdbthread.h (thread_info_ref, delete_thread)
4382 (delete_thread_silent, first_thread_of_inferior)
4383 (any_thread_of_inferior, switch_to_thread)
4384 (enable_thread_stack_temporaries)
4385 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4386 (get_last_thread_stack_temporary)
4387 (value_in_thread_stack_temporaries, can_access_registers_thread):
4388 Spell out "struct thread_info" instead of just "thread_info".
4389 * inferior.h (notice_new_inferior): Likewise.
4391 2018-06-25 Pedro Alves <palves@redhat.com>
4393 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4394 pass thread_info pointer to delete_thread.
4395 (windows_nat_target::detach): Pass inferior pointer to
4397 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
4399 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
4400 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
4401 and pass a thread_info pointer to delete_thread.
4402 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
4403 pass thread_info pointer to delete_thread.
4404 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
4405 delete_thread_silent call.
4406 * procfs.c (procfs_target::detach): Pass inferior pointer to
4408 (procfs_target::wait): Pass thread_info pointer to delete_thread.
4409 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
4410 delete_thread_silent call.
4411 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4412 pass thread_info pointer to delete_thread.
4413 (windows_nat_target::detach): Pass inferior pointer to
4416 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4418 * regcache.c (readable_regcache::read_part): Fix asserts.
4419 (reg_buffer::raw_collect_part): New function.
4420 (regcache::write_part): Fix asserts.
4421 (reg_buffer::raw_supply_part): New function.
4422 (regcache::transfer_regset_register): New helper function.
4423 (regcache::transfer_regset): Call new functions.
4424 (regcache_supply_regset): Use gdb_byte*.
4425 (regcache::supply_regset): Likewise.
4426 (regcache_collect_regset): Likewise.
4427 (regcache::collect_regset): Likewise.
4428 * regcache.h (reg_buffer::raw_collect_part): New declaration.
4429 (reg_buffer::raw_supply_part): Likewise.
4430 (regcache::transfer_regset_register): Likewise.
4431 (regcache::transfer_regset): Use gdb_byte*.
4433 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4435 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
4437 2018-06-21 Pedro Alves <palves@redhat.com>
4439 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
4440 instead of a ptid_t. All callers adjusted.
4441 * ada-tasks.c (ada_get_task_number): Likewise. All callers
4443 (print_ada_task_info, display_current_task_id, task_command_1):
4445 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
4447 (breakpoint_kind): Adjust.
4448 (remove_breakpoints_pid): Rename to ...
4449 (remove_breakpoints_inf): ... this. Adjust to take an inferior
4450 pointer. All callers adjusted.
4451 (bpstat_clear_actions): Use inferior_thread.
4452 (get_bpstat_thread): New.
4453 (bpstat_do_actions): Use it.
4454 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
4455 to take a thread_info pointer. All callers adjusted.
4456 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
4457 (breakpoint_re_set_thread): Use inferior_thread.
4458 * breakpoint.h (struct inferior): Forward declare.
4459 (bpstat_stop_status): Update.
4460 (remove_breakpoints_pid): Delete.
4461 (remove_breakpoints_inf): New.
4462 * bsd-uthread.c (bsd_uthread_target::wait)
4463 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
4464 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
4465 (maint_btrace_packet_history_cmd)
4466 (maint_btrace_clear_packet_history_cmd): Adjust.
4467 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
4469 * cli/cli-interp.c: Include "inferior.h".
4470 * common/refcounted-object.h (struct
4471 refcounted_object_ref_policy): New.
4472 * compile/compile-object-load.c: Include gdbthread.h.
4473 (store_regs): Use inferior_thread.
4474 * corelow.c (core_target::close): Use current_inferior.
4475 (core_target_open): Adjust to use first_thread_of_inferior and use
4476 the current inferior.
4477 * ctf.c (ctf_target::close): Adjust to use current_inferior.
4478 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
4479 <thread>: ... this new field. All references adjusted.
4480 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
4481 Take a thread_info pointer instead of a ptid_t.
4482 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
4483 (dummy_frame_discard, register_dummy_frame_dtor): Take a
4484 thread_info pointer instead of a ptid_t.
4485 * elfread.c: Include "inferior.h".
4486 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
4487 Use inferior_thread.
4488 * eval.c (evaluate_subexp): Likewise.
4489 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
4491 * gdb_proc_service.h (struct thread_info): Forward declare.
4492 (struct ps_prochandle) <ptid>: Delete, replaced by ...
4493 <thread>: ... this new field. All references adjusted.
4494 * gdbarch.h, gdbarch.c: Regenerate.
4495 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
4496 'thread' parameter. All implementations and callers adjusted.
4497 * gdbthread.h (thread_info) <set_running>: New method.
4498 (delete_thread, delete_thread_silent): Take a thread_info pointer
4500 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
4501 (first_thread_of_process): Delete, replaced by ...
4502 (first_thread_of_inferior): ... this new function. All callers
4504 (any_live_thread_of_process): Delete, replaced by ...
4505 (any_live_thread_of_inferior): ... this new function. All callers
4507 (switch_to_thread, switch_to_no_thread): Declare.
4508 (is_executing): Delete.
4509 (enable_thread_stack_temporaries): Update comment.
4510 <enable_thread_stack_temporaries>: Take a thread_info pointer
4511 instead of a ptid_t. Incref the thread.
4512 <~enable_thread_stack_temporaries>: Decref the thread.
4515 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4516 (get_last_thread_stack_temporary)
4517 (value_in_thread_stack_temporaries, can_access_registers_thread):
4518 Take a thread_info pointer instead of a ptid_t. All callers
4520 * infcall.c (get_call_return_value): Use inferior_thread.
4521 (run_inferior_call): Work with thread pointers instead of ptid_t.
4522 (call_function_by_hand_dummy): Work with thread pointers instead
4523 of ptid_t. Use thread_info_ref.
4524 * infcmd.c (proceed_thread_callback): Access thread's state
4526 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
4527 access thread's state directly.
4528 (continue_command): Use inferior_thread.
4529 (info_program_command): Use find_thread_ptid and access thread
4531 (proceed_after_attach_callback): Use thread state directly.
4532 (notice_new_inferior): Take a thread_info pointer instead of a
4533 ptid_t. All callers adjusted.
4534 (exit_inferior): Take an inferior pointer instead of a pid. All
4536 (exit_inferior_silent): New.
4537 (detach_inferior): Delete.
4538 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
4539 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
4540 (detach_inferior_command, kill_inferior_command): Use
4541 find_inferior_id instead of valid_gdb_inferior_id and
4542 gdb_inferior_id_to_pid.
4543 (inferior_command): Use inferior and thread pointers.
4544 * inferior.h (struct thread_info): Forward declare.
4545 (notice_new_inferior): Take a thread_info pointer instead of a
4546 ptid_t. All callers adjusted.
4547 (detach_inferior): Delete declaration.
4548 (exit_inferior, exit_inferior_silent): Take an inferior pointer
4549 instead of a pid. All callers adjusted.
4550 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
4551 (valid_gdb_inferior_id): Delete.
4552 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
4553 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
4554 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
4556 <inf>: ... this new field.
4557 <step_ptid>: Delete, replaced by ...
4558 <step_thread>: ... this new field.
4559 (get_displaced_stepping_state): Take an inferior pointer instead
4560 of a pid. All callers adjusted.
4561 (displaced_step_in_progress_any_inferior): Adjust.
4562 (displaced_step_in_progress_thread): Take a thread pointer instead
4563 of a ptid_t. All callers adjusted.
4564 (displaced_step_in_progress, add_displaced_stepping_state): Take
4565 an inferior pointer instead of a pid. All callers adjusted.
4566 (get_displaced_step_closure_by_addr): Adjust.
4567 (remove_displaced_stepping_state): Take an inferior pointer
4568 instead of a pid. All callers adjusted.
4569 (displaced_step_prepare_throw, displaced_step_prepare)
4570 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
4571 All callers adjusted.
4572 (start_step_over): Adjust.
4573 (infrun_thread_ptid_changed): Remove bit updating ptids in the
4574 displaced step queue.
4575 (do_target_resume): Adjust.
4576 (fetch_inferior_event): Use inferior_thread.
4577 (context_switch, get_inferior_stop_soon): Take an
4578 execution_control_state pointer instead of a ptid_t. All callers
4580 (switch_to_thread_cleanup): Delete.
4581 (stop_all_threads): Use scoped_restore_current_thread.
4582 * inline-frame.c: Include "gdbthread.h".
4583 (inline_state) <inline_state>: Take a thread pointer instead of a
4584 ptid_t. All callers adjusted.
4585 <ptid>: Delete, replaced by ...
4586 <thread>: ... this new field.
4587 (find_inline_frame_state): Take a thread pointer instead of a
4588 ptid_t. All callers adjusted.
4589 (skip_inline_frames, step_into_inline_frame)
4590 (inline_skipped_frames, inline_skipped_symbol): Take a thread
4591 pointer instead of a ptid_t. All callers adjusted.
4592 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
4593 (inline_skipped_frames, inline_skipped_symbol): Likewise.
4594 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
4596 * linux-nat.c (get_detach_signal): Likewise.
4597 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
4598 (thread_db_notice_clone): Adjust.
4599 (thread_db_find_new_threads_silently)
4600 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
4601 a thread pointer instead of a ptid_t. All callers adjusted.
4602 * mi/mi-cmd-var.c: Include "inferior.h".
4603 (mi_cmd_var_update_iter): Update to use thread pointers.
4604 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
4606 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
4608 (mi_output_running): ... this new function.
4609 (mi_on_resume_1): Adjust to use it.
4610 (mi_user_selected_context_changed): Adjust to use inferior_thread.
4611 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
4613 (interrupt_thread_callback): : Adjust to use thread and inferior
4615 * proc-service.c: Include "gdbthread.h".
4616 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
4617 * progspace-and-thread.c: Include "inferior.h".
4618 * progspace.c: Include "inferior.h".
4619 * python/py-exitedevent.c (create_exited_event_object): Adjust to
4620 hold a reference to an inferior_object.
4621 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
4623 * python/py-inferior.c (struct inferior_object): Give the type a
4624 tag name instead of a typedef.
4625 (python_on_normal_stop): No need to check if the current thread is
4627 (inferior_to_inferior_object): Change return type to
4628 inferior_object. All callers adjusted.
4629 (find_thread_object): Delete, bits factored out to ...
4630 (thread_to_thread_object): ... this new function.
4631 * python/py-infthread.c (create_thread_object): Use
4632 inferior_to_inferior_object.
4633 (thpy_is_stopped): Use thread pointer directly.
4634 (gdbpy_selected_thread): Use inferior_thread.
4635 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
4636 field, replaced with ...
4637 <thread>: ... this new field. All users adjusted.
4638 (btpy_insn_or_gap_new): Drop const.
4639 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
4641 * python/py-record.c: Include "gdbthread.h".
4642 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4643 a ptid_t. All callers adjusted.
4644 (gdbpy_current_recording): Use inferior_thread.
4645 * python/py-record.h (recpy_record_object) <ptid>: Delete
4646 field, replaced with ...
4647 <thread>: ... this new field. All users adjusted.
4648 (recpy_element_object) <ptid>: Delete
4649 field, replaced with ...
4650 <thread>: ... this new field. All users adjusted.
4651 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4652 a ptid_t. All callers adjusted.
4653 * python/py-threadevent.c: Include "gdbthread.h".
4654 (get_event_thread): Use thread_to_thread_object.
4655 * python/python-internal.h (struct inferior_object): Forward
4657 (find_thread_object, find_inferior_object): Delete declarations.
4658 (thread_to_thread_object, inferior_to_inferior_object): New
4660 * record-btrace.c: Include "inferior.h".
4661 (require_btrace_thread): Use inferior_thread.
4662 (record_btrace_frame_sniffer)
4663 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
4664 (get_thread_current_frame): Use scoped_restore_current_thread and
4666 (get_thread_current_frame): Use thread pointer directly.
4667 (record_btrace_replay_at_breakpoint): Use thread's inferior
4669 * record-full.c: Include "inferior.h".
4670 * regcache.c: Include "gdbthread.h".
4671 (get_thread_arch_regcache): Use the inferior's address space
4673 (get_thread_regcache, registers_changed_thread): New.
4674 * regcache.h (get_thread_regcache(thread_info *thread)): New
4676 (registers_changed_thread): New.
4677 (remote_target) <remote_detach_1>: Swap order of parameters.
4678 (remote_add_thread): <remote_add_thread>: Return the new thread.
4679 (get_remote_thread_info(ptid_t)): New overload.
4680 (remote_target::remote_notice_new_inferior): Use thread pointers
4682 (remote_target::process_initial_stop_replies): Use
4683 thread_info::set_running.
4684 (remote_target::remote_detach_1, remote_target::detach)
4685 (extended_remote_target::detach): Adjust.
4686 * stack.c (frame_show_address): Use inferior_thread.
4687 * target-debug.h (target_debug_print_thread_info_pp): New.
4688 * target-delegates.c: Regenerate.
4689 * target.c (default_thread_address_space): Delete.
4690 (memory_xfer_partial_1): Use current_inferior.
4691 (target_detach): Use current_inferior.
4692 (target_thread_address_space): Delete.
4693 (generic_mourn_inferior): Use current_inferior.
4694 * target.h (struct target_ops) <thread_address_space>: Delete.
4695 (target_thread_address_space): Delete.
4696 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
4698 (delete_thread_1, delete_thread, delete_thread_silent): Take a
4699 thread pointer instead of a ptid_t. Adjust all callers.
4700 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
4701 (first_thread_of_process): Delete, replaced by ...
4702 (first_thread_of_inferior): ... this new function. All callers
4704 (any_thread_of_process): Rename to ...
4705 (any_thread_of_inferior): ... this, and take an inferior pointer.
4706 (any_live_thread_of_process): Rename to ...
4707 (any_live_thread_of_inferior): ... this, and take an inferior
4709 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4710 (value_in_thread_stack_temporaries)
4711 (get_last_thread_stack_temporary): Take a thread pointer instead
4712 of a ptid_t. Adjust all callers.
4713 (thread_info::set_running): New.
4714 (validate_registers_access): Use inferior_thread.
4715 (can_access_registers_ptid): Rename to ...
4716 (can_access_registers_thread): ... this, and take a thread
4718 (print_thread_info_1): Adjust to compare thread pointers instead
4720 (switch_to_no_thread, switch_to_thread): Make extern.
4721 (scoped_restore_current_thread::~scoped_restore_current_thread):
4722 Use m_thread pointer directly.
4723 (scoped_restore_current_thread::scoped_restore_current_thread):
4724 Use inferior_thread.
4725 (thread_command): Use thread pointer directly.
4726 (thread_num_make_value_helper): Use inferior_thread.
4727 * top.c (execute_command): Use inferior_thread.
4728 * tui/tui-interp.c: Include "inferior.h".
4729 * varobj.c (varobj_create): Use inferior_thread.
4730 (value_of_root_1): Use find_thread_global_id instead of
4731 global_thread_id_to_ptid.
4733 2018-06-21 Alan Hayward <alan.hayward@arm.com>
4735 * regcache.c (readable_regcache::read_part): Avoid memcpy when
4737 (regcache::write_part): Likewise.
4738 (readable_regcache::cooked_read_part): Update comment.
4739 (readable_regcache::cooked_write_part): Likewise.
4740 * regcache.h: (readable_regcache::read_part): Likewise.
4741 (regcache::write_part): Likewise.
4743 2018-06-21 Richard Bunt <richard.bunt@arm.com>
4744 Dirk Schubert <dirk.schubert@arm.com>
4746 * aarch64-linux-nat.c (post_attach): New.
4747 (aarch64_linux_nat_target::post_attach): Override post_attach to
4748 record the number of hardware debug registers.
4750 2018-06-20 Tom Tromey <tom@tromey.com>
4752 * python/py-param.c (add_setshow_generic): Make parameters const.
4753 (parmpy_init): Update.
4755 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
4757 * regcache.h (regcache_cooked_read_ftype): Rename to...
4758 (register_read_ftype): ...this, change type to function_view.
4759 (class reg_buffer) <save>: Remove src parameter.
4760 (readonly_detached_regcache) <readonly_detached_regcache>: Make
4761 parameter non-const in first overload. Remove src parameter in
4763 * regcache.c (do_cooked_read): Remove.
4764 (readonly_detached_regcache::readonly_detached_regcache): Make
4765 parameter non-const, adjust call to other constructor.
4766 (reg_buffer::save): Remove src parameter.
4767 * frame.c (do_frame_register_read): Remove.
4768 (frame_save_as_regcache): Use lambda function.
4769 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
4770 parameter to ppu2spu_data *.
4771 (ppu2spu_sniffer): Use lambda function.
4773 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
4775 * record-full.c (record_full_target::insert_breakpoint): Remove
4776 "struct" keyword, add const.
4778 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
4780 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
4781 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
4782 * configure.ac: Remove AC_PREREQ, add missing quoting.
4783 * gnulib/configure.ac: Modernize usage of
4784 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
4785 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
4786 (AUTOMAKE_VERSION): Bump to 1.15.1.
4787 * configure: Re-generate.
4788 * config.in: Re-generate.
4789 * aclocal.m4: Re-generate.
4790 * gnulib/aclocal.m4: Re-generate.
4791 * gnulib/config.in: Re-generate.
4792 * gnulib/configure: Re-generate.
4793 * gnulib/import/Makefile.in: Re-generate.
4795 2018-06-19 Pedro Alves <palves@redhat.com>
4797 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
4798 (lookup_minimal_symbol_by_pc_section): ... here with
4799 gdb_assert_not_reached added.
4801 2018-06-19 Pedro Alves <palves@redhat.com>
4803 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
4804 parameter with a block parameter. Compare location's block symbol
4805 with the frame's block instead of addresses.
4806 (skip_inline_frames): Pass the current block instead of the
4807 frame's address. Break out as soon as we determine the frame
4808 should not be skipped.
4810 2018-06-18 Tom Tromey <tom@tromey.com>
4812 * solib-aix.c (solib_aix_get_section_offsets): Return
4814 (solib_aix_solib_create_inferior_hook): Update.
4816 2018-06-18 Tom Tromey <tom@tromey.com>
4818 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
4820 2018-06-18 Tom Tromey <tom@tromey.com>
4822 * solib-frv.c (frv_relocate_main_executable): Use
4824 * solib-dsbt.c (dsbt_relocate_main_executable): Use
4827 2018-06-18 Tom Tromey <tom@tromey.com>
4829 * objfiles.h (inhibit_section_map_updates): Update.
4830 (resume_section_map_updates, resume_section_map_updates_cleanup):
4832 * solib-svr4.c (svr4_handle_solib_event): Update.
4833 * objfiles.c (inhibit_section_map_updates): Return
4834 scoped_restore_tmpl<int>.
4835 (resume_section_map_updates, resume_section_map_updates_cleanup):
4838 2018-06-18 Tom Tromey <tom@tromey.com>
4840 * valprint.h (read_string): Update.
4841 * valprint.c (read_string): Change type of "buffer".
4842 (val_print_string): Update.
4843 * python/py-value.c (valpy_string): Update.
4844 * language.h (struct language_defn) <la_get_string>: Change
4846 (default_get_string, c_get_string): Update.
4847 * language.c (default_get_string): Change type of "buffer".
4848 * guile/scm-value.c (gdbscm_value_to_string): Update.
4849 * c-lang.c (c_get_string): Change type of "buffer".
4851 2018-06-18 Tom Tromey <tom@tromey.com>
4853 * ser-mingw.c (struct pipe_state_destroyer): New.
4854 (pipe_state_up): New typedef.
4855 (cleanup_pipe_state): Remove.
4856 (pipe_windows_open): Use pipe_state_up. Don't release argv.
4858 2018-06-18 Tom Tromey <tom@tromey.com>
4860 * rust-lang.h (rust_yyerror): Don't declare.
4861 * rust-lang.c (rust_language_defn): Update.
4862 * rust-exp.y (yyerror): Now static.
4863 * parse.c (parse_exp_in_context_1): Update.
4864 * p-lang.h (p_yyerror): Don't declare.
4865 * p-lang.c (p_language_defn): Update.
4866 * p-exp.y (yyerror): Now static.
4867 * opencl-lang.c (opencl_language_defn): Update.
4868 * objc-lang.c (objc_language_defn): Update.
4869 * m2-lang.h (m2_yyerror): Don't declare.
4870 * m2-lang.c (m2_language_defn): Update.
4871 * m2-exp.y (yyerror): Now static.
4872 * language.h (struct language_defn) <la_error>: Remove.
4873 * language.c (unk_lang_error): Remove.
4874 (unknown_language_defn, auto_language_defn): Remove.
4875 * go-lang.h (go_yyerror): Don't declare.
4876 * go-lang.c (go_language_defn): Update.
4877 * go-exp.y (yyerror): Now static.
4878 * f-lang.h (f_yyerror): Don't declare.
4879 * f-lang.c (f_language_defn): Update.
4880 * f-exp.y (yyerror): Now static.
4881 * d-lang.h (d_yyerror): Don't declare.
4882 * d-lang.c (d_language_defn): Update.
4883 * d-exp.y (yyerror): Now static.
4884 * c-lang.h (c_yyerror): Don't declare.
4885 * c-lang.c (c_language_defn, cplus_language_defn)
4886 (asm_language_defn, minimal_language_defn): Update.
4887 * c-exp.y (yyerror): Now static.
4888 * ada-lang.h (ada_yyerror): Don't declare.
4889 * ada-lang.c (ada_language_defn): Update.
4890 * ada-exp.y (yyerror): Now static.
4892 2018-06-18 Alan Hayward <alan.hayward@arm.com>
4894 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
4895 (store_sveregs_to_thread): Likewise.
4896 (aarch64_linux_fetch_inferior_registers): Check for SVE.
4897 (aarch64_linux_store_inferior_registers): Likewise.
4898 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
4900 (aarch64_sve_regs_copy_to_regcache): Likewise.
4901 (aarch64_sve_regs_copy_from_regcache): Likewise.
4902 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
4904 (aarch64_sve_regs_copy_to_regcache): Likewise.
4905 (aarch64_sve_regs_copy_from_regcache): Likewise.
4906 (sve_context): Structure from Linux headers.
4907 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
4908 (SVE_SIG_ZREG_SIZE): Likewise.
4909 (SVE_SIG_PREG_SIZE): Likewise.
4910 (SVE_SIG_FFR_SIZE): Likewise.
4911 (SVE_SIG_REGS_OFFSET): Likewise.
4912 (SVE_SIG_ZREGS_OFFSET): Likewise.
4913 (SVE_SIG_ZREG_OFFSET): Likewise.
4914 (SVE_SIG_ZREGS_SIZE): Likewise.
4915 (SVE_SIG_PREGS_OFFSET): Likewise.
4916 (SVE_SIG_PREG_OFFSET): Likewise.
4917 (SVE_SIG_PREGS_SIZE): Likewise.
4918 (SVE_SIG_FFR_OFFSET): Likewise.
4919 (SVE_SIG_REGS_SIZE): Likewise.
4920 (SVE_SIG_CONTEXT_SIZE): Likewise.
4921 (SVE_PT_REGS_MASK): Likewise.
4922 (SVE_PT_REGS_FPSIMD): Likewise.
4923 (SVE_PT_REGS_SVE): Likewise.
4924 (SVE_PT_VL_INHERIT): Likewise.
4925 (SVE_PT_VL_ONEXEC): Likewise.
4926 (SVE_PT_REGS_OFFSET): Likewise.
4927 (SVE_PT_FPSIMD_OFFSET): Likewise.
4928 (SVE_PT_FPSIMD_SIZE): Likewise.
4929 (SVE_PT_SVE_ZREG_SIZE): Likewise.
4930 (SVE_PT_SVE_PREG_SIZE): Likewise.
4931 (SVE_PT_SVE_FFR_SIZE): Likewise.
4932 (SVE_PT_SVE_FPSR_SIZE): Likewise.
4933 (SVE_PT_SVE_FPCR_SIZE): Likewise.
4934 (__SVE_SIG_TO_PT): Likewise.
4935 (SVE_PT_SVE_OFFSET): Likewise.
4936 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
4937 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
4938 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
4939 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
4940 (SVE_PT_SVE_PREG_OFFSET): Likewise.
4941 (SVE_PT_SVE_PREGS_SIZE): Likewise.
4942 (SVE_PT_SVE_FFR_OFFSET): Likewise.
4943 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
4944 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
4945 (SVE_PT_SVE_SIZE): Likewise.
4946 (SVE_PT_SIZE): Likewise.
4947 (HAS_SVE_STATE): New define.
4949 2018-06-18 Alan Hayward <alan.hayward@arm.com>
4951 * nat/aarch64-sve-linux-sigcontext.h: New file.
4952 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
4954 (SVE_VQ_MIN): Likewise.
4955 (SVE_VQ_MAX): Likewise.
4956 (SVE_VL_MIN): Likewise.
4957 (SVE_VL_MAX): Likewise.
4958 (SVE_NUM_ZREGS): Likewise.
4959 (SVE_NUM_PREGS): Likewise.
4960 (sve_vl_valid): Likewise.
4961 (struct user_sve_header): Likewise.
4963 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
4964 Richard Bunt <Richard.Bunt@arm.com>
4966 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
4967 was requested by GDB.
4969 2018-06-15 Tom de Vries <tdevries@suse.de>
4971 * MAINTAINERS (Write After Approval): Add Tom de Vries.
4973 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
4975 * gnulib/update-gnulib.sh: Print expected versions of
4978 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
4980 * arch-utils.c (default_type_align): Use type_length_units.
4981 * gdbtypes.c (type_align): Use type_length_units.
4983 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4985 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
4986 of 'define' command.
4988 2018-06-14 Tom de Vries <tdevries@suse.de>
4991 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
4992 get_no_prettyformat_print_options.
4994 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
4996 * sparc-nat.h: Include target.h.
4997 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
4998 <fetch_registers>: Remove this argument in function call.
4999 <store_registers>: Remove this argument in function call, remove
5001 <low_forget_process>: Call sparc64_forget_process instead of
5002 sparc_forget_process.
5004 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5006 * procfs.c (_initialize_procfs): Use add_inf_child_target.
5007 (procfs_target::make_corefile_notes): Adjust to new
5008 target_read_alloc return type.
5010 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5011 Stephen Roberts <stephen.roberts@arm.com>
5014 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
5015 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
5016 Move should_notify_stop local into more inner scope.
5018 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5019 Stephen Roberts <stephen.roberts@arm.com>
5022 * infrun.c (resume_1): Add call to mark_async_event_handler.
5024 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5026 * infrun.c (do_target_wait): Change old version of $pc printed.
5028 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
5030 * dwarf2read.c (read_index_from_section): Rename to...
5031 (read_gdb_index_from_section): ... this, update all callers.
5032 (dwarf2_read_index): Rename to...
5033 (dwarf2_read_gdb_index): ... this, update all callers.
5035 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
5037 * gdb/hppa-linux-nat.c
5038 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
5039 hppa_linux_nat_target::fetch_registers.
5041 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5043 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
5044 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
5045 (AARCH64_DWARF_SVE_FFR): Likewise.
5046 (AARCH64_DWARF_SVE_P0): Likewise.
5047 (AARCH64_DWARF_SVE_Z0): Likewise.
5049 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5051 * common/common-regcache.h (raw_compare): New function.
5052 * regcache.c (regcache::raw_compare): Likewise.
5053 * regcache.h (regcache::raw_compare): New declaration.
5055 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5057 * common/common-regcache.h (reg_buffer_common): New structure.
5058 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
5059 (reg_buffer::raw_supply): Likewise.
5060 (reg_buffer::raw_supply_integer): Likewise.
5061 (reg_buffer::raw_supply_zeroed): Likewise.
5062 (reg_buffer::raw_collect): Likewise.
5063 (reg_buffer::raw_collect_integer): Likewise.
5064 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
5065 (reg_buffer::raw_supply): Likewise.
5066 (reg_buffer::raw_supply_integer): Likewise.
5067 (reg_buffer::raw_supply_zeroed): Likewise.
5068 (reg_buffer::raw_collect): Likewise.
5069 (reg_buffer::raw_collect_integer): Likewise.
5071 2018-06-10 Tom Tromey <tom@tromey.com>
5073 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
5074 (class remote_state) <stop_reply_queue>: Now std::vector.
5075 (remote_state::~remote_state)
5076 (remote_target::stop_reply_queue_length): Update.
5077 (struct queue_iter_param, remove_child_of_pending_fork)
5078 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
5079 (check_pending_event_prevents_wildcard_vcont_callback)
5080 (remove_stop_reply_for_inferior)
5081 (remove_stop_reply_of_remote_state)
5082 (remote_notif_remove_once_on_match)
5083 (stop_reply_match_ptid_and_ws)
5084 (remote_kill_child_of_pending_fork): Remove.
5085 (remote_target::remove_new_fork_children)
5086 (remote_target::check_pending_events_prevent_wildcard_vcont)
5087 (remote_target::discard_pending_stop_replies)
5088 (remote_target::discard_pending_stop_replies_in_queue)
5089 (remote_target::remote_notif_remove_queued_reply)
5090 (remote_target::queued_stop_reply)
5091 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
5092 (remote_target::wait, remote_target::kill_new_fork_children)
5093 (remote_target::async): Update.
5095 2018-06-10 Tom Tromey <tom@tromey.com>
5097 * record-full.c (record_full_arch_list_cleanups): Remove.
5098 (record_full_message): Use try/catch.
5099 (record_full_wait_cleanups): Remove.
5100 (record_full_wait_1): Use try/catch.
5101 (record_full_restore): Likewise.
5103 2018-06-10 Tom Tromey <tom@tromey.com>
5105 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
5106 declare VEC. Add constructor.
5107 <in_target_beneath>: Now bool.
5108 (record_full_breakpoints): Now a std::vector, static.
5109 (record_full_sync_record_breakpoints)
5110 (record_full_init_record_breakpoints)
5111 (record_full_target::insert_breakpoint)
5112 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
5114 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
5116 * dwarf2read.c (process_cu_includes): Remove struct keyword.
5117 * serial.c (serial_interface_lookup): Remove struct keyword.
5119 2018-06-10 Tom Tromey <tom@tromey.com>
5121 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
5123 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
5125 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
5127 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
5128 "beneath" as a method.
5129 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
5130 Use "beneath" as a method.
5132 2018-06-10 Tom Tromey <tom@tromey.com>
5134 * tracefile.c (struct trace_file_writer_deleter): New.
5135 <operator()>: Rename from trace_file_writer_xfree.
5136 (trace_file_writer_up): New typedef.
5137 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
5139 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5141 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
5142 <m_registers, m_register_status>: Change type to
5144 * regcache.c (reg_buffer::reg_buffer): Use new instead of
5147 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5149 * common/common-regcache.h (enum register_status): Add
5150 underlying type "signed char".
5151 * regcache.h (reg_buffer) <m_register_status>: Change type to
5153 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
5154 register_status instead of signed char.
5155 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
5156 (reg_buffer::get_register_status): Remove cast.
5157 (readable_regcache::raw_read): Remove cast.
5158 (readable_regcache::cooked_read): Remove cast.
5160 2018-06-09 Tom Tromey <tom@tromey.com>
5162 * source.c (reverse_search_command, forward_search_command): Use
5165 2018-06-09 Tom Tromey <tom@tromey.com>
5167 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
5168 (serial_ops_list): Now static, std::vector.
5169 (serial_interface_lookup, serial_add_interface): Update.
5171 2018-06-09 Tom Tromey <tom@tromey.com>
5173 * dwarf2read.c (process_cu_includes): Update.
5174 (process_full_comp_unit): Update.
5175 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
5178 2018-06-08 Paul Koning <paul_koning@dell.com>
5182 * python/python.c (do_start_initialization):
5183 Avoid call to internal Python API.
5184 (init__gdb_module): New function.
5186 2018-06-08 Gary Benson <gbenson@redhat.com>
5188 * linux-thread-db.c (valprint.h): New include.
5189 (struct check_thread_db_info): New structure.
5190 (check_thread_db_on_load, tdb_testinfo): New static globals.
5191 (check_thread_db, check_thread_db_callback): New functions.
5192 (try_thread_db_load_1): Run integrity checks if requested.
5193 (maintenance_check_libthread_db): New function.
5194 (_initialize_thread_db): Register "maint check libthread-db"
5195 and "maint set/show check-libthread-db".
5196 * NEWS: Mention the above new commands.
5198 2018-06-08 Tom Tromey <tom@tromey.com>
5200 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
5203 2018-06-08 Tom Tromey <tom@tromey.com>
5205 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
5207 2018-06-08 Tom Tromey <tom@tromey.com>
5209 * common/btrace-common.h (struct btrace_data): Add constructor,
5210 destructor, move assignment operator.
5211 <empty, clear, fini>: New methods.
5212 <format>: Initialize.
5213 (btrace_data_init, btrace_data_fini, btrace_data_clear)
5214 (btrace_data_empty): Don't declare.
5215 * common/btrace-common.c (btrace_data_init): Remove.
5216 (btrace_data::fini): Rename from btrace_data_fini.
5217 (btrace_data::empty): Rename from btrace_data_empty.
5218 (btrace_data::clear): Rename from btrace_data_clear. Return
5220 * btrace.h (make_cleanup_btrace_data): Don't declare.
5221 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
5222 (parse_xml_btrace): Update.
5223 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
5224 (maint_btrace_clear_packet_history_cmd): Update.
5226 2018-06-07 Pedro Alves <palves@redhat.com>
5228 * target.h (target_ops) <beneath>: Now a method. All references
5230 (class target_stack): New.
5231 * target.c (g_target_stack): New.
5232 (g_current_top_target): Delete.
5233 (current_top_target): Get the top target out of g_target_stack.
5234 (target_stack::push, target_stack::unpush): New.
5235 (push_target, unpush_target): Reimplement.
5236 (target_is_pushed): Reimplement in terms of g_target_stack.
5237 (target_ops::beneath, target_stack::find_beneath): New.
5239 2018-06-07 Pedro Alves <palves@redhat.com>
5241 * target.h (find_target_beneath): Delete declaration.
5242 * target.c (find_target_beneath): Delete definition.
5243 * aix-thread.c: All callers of find_target_beneath adjusted to
5244 call target_ops::beneath instead.
5245 * bsd-uthread.c: Likewise.
5246 * linux-thread-db.c: Likewise.
5247 * ravenscar-thread.c: Likewise.
5248 * sol-thread.c: Likewise.
5249 * spu-multiarch.c: Likewise.
5251 2018-06-07 Pedro Alves <palves@redhat.com>
5253 * target.h (target_ops) <beneath>: Now a method. All references
5255 (target_ops) <m_beneath>: New.
5256 * target.c (target_ops::beneath): New.
5257 * corelow.c: Adjust all references to target_ops::beneath.
5258 * linux-thread-db.c: Likewise.
5259 * make-target-delegates: Likewise.
5260 * record-btrace.c: Likewise.
5261 * record-full.c: Likewise.
5262 * remote.c: Likewise.
5263 * target.c: Likewise.
5264 * target-delegates.c: Regenerate.
5266 2018-06-07 Pedro Alves <palves@redhat.com>
5268 * target.h (target_stack): Delete.
5269 (current_top_target): Declare function.
5270 * target.c (target_stack): Delete.
5271 (g_current_top_target): New.
5272 (current_top_target): New function.
5273 * auxv.c: Use current_top_target instead of target_stack
5275 * avr-tdep.c: Likewise.
5276 * breakpoint.c: Likewise.
5277 * corefile.c: Likewise.
5278 * elfread.c: Likewise.
5280 * exceptions.c: Likewise.
5281 * frame.c: Likewise.
5282 * gdbarch-selftests.c: Likewise.
5283 * gnu-v3-abi.c: Likewise.
5284 * ia64-tdep.c: Likewise.
5285 * ia64-vms-tdep.c: Likewise.
5286 * infcall.c: Likewise.
5287 * infcmd.c: Likewise.
5288 * infrun.c: Likewise.
5289 * linespec.c: Likewise.
5290 * linux-tdep.c: Likewise.
5291 * minsyms.c: Likewise.
5292 * ppc-linux-nat.c: Likewise.
5293 * ppc-linux-tdep.c: Likewise.
5294 * procfs.c: Likewise.
5295 * regcache.c: Likewise.
5296 * remote.c: Likewise.
5297 * rs6000-tdep.c: Likewise.
5298 * s390-linux-nat.c: Likewise.
5299 * s390-tdep.c: Likewise.
5300 * solib-aix.c: Likewise.
5301 * solib-darwin.c: Likewise.
5302 * solib-dsbt.c: Likewise.
5303 * solib-spu.c: Likewise.
5304 * solib-svr4.c: Likewise.
5305 * solib-target.c: Likewise.
5306 * sparc-tdep.c: Likewise.
5307 * sparc64-tdep.c: Likewise.
5308 * spu-tdep.c: Likewise.
5309 * symfile.c: Likewise.
5310 * symtab.c: Likewise.
5311 * target-descriptions.c: Likewise.
5312 * target-memory.c: Likewise.
5313 * target.c: Likewise.
5314 * target.h: Likewise.
5315 * tracefile-tfile.c: Likewise.
5316 * tracepoint.c: Likewise.
5317 * valops.c: Likewise.
5318 * valprint.c: Likewise.
5319 * value.c: Likewise.
5320 * windows-tdep.c: Likewise.
5321 * mi/mi-main.c: Likewise.
5323 2018-06-07 Tom Tromey <tom@tromey.com>
5325 * valprint.h (build_address_symbolic): Declare.
5326 * printcmd.c (print_address_symbolic): Update.
5327 (build_address_symbolic): Change "name" and "filename" to
5329 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
5331 * defs.h (build_address_symbolic): Remove declaration.
5333 2018-06-07 Alan Hayward <alan.hayward@arm.com>
5335 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
5336 (aarch64_vnv_type): Add function.
5337 (aarch64_pseudo_register_name): Add V regs for SVE.
5338 (aarch64_pseudo_register_type): Likewise.
5339 (aarch64_pseudo_register_reggroup_p): Likewise.
5340 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
5341 (aarch64_pseudo_read_value): Add V regs for SVE.
5342 (aarch64_pseudo_write_2): Use V0 offset for SVE
5343 (aarch64_pseudo_write): Add V regs for SVE.
5344 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
5346 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
5348 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
5349 (sve_vl_from_vq): Likewise.
5351 2018-06-05 Tom Tromey <tom@tromey.com>
5353 * cli/cli-cmds.c (show_version): Update.
5354 * top.c (print_gdb_version): Add "interactive" parameter.
5356 * main.c (captured_main_1): Update.
5357 * top.h (print_gdb_version): Add "interactive" parameter and a
5360 2018-06-05 David Malcolm <dmalcolm@redhat.com>
5362 * common/enum-flags.h: Add trailing semicolon to example in
5365 2018-06-05 Tom Tromey <tom@tromey.com>
5368 * NEWS: Add entry about pager.
5369 * utils.c (pagination_disabled_for_command): New global.
5370 (prompt_for_continue): Allow "c" response to prompt.
5371 (reinitialize_more_filter): Clear
5372 pagination_disabled_for_command.
5373 (fputs_maybe_filtered): Check pagination_disabled_for_command.
5375 2018-06-04 Tom Tromey <tom@tromey.com>
5377 * ada-lang.h (ada_lookup_symbol_list): Update.
5378 * ada-lang.c (resolve_subexp): Update.
5379 (symbols_are_identical_enums): Change type of syms. Remove nsyms
5381 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
5382 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
5383 results parameter to std::vector.
5384 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
5386 * ada-exp.y (block_lookup): Update.
5387 (select_possible_type_sym): Change type of syms. Remove nsyms
5389 (write_var_or_type, write_name_assoc): Update.
5391 2018-06-04 Joel Brobecker <brobecker@adacore.com>
5393 * windows-nat.c (windows_nat_target::xfer_partial): Return
5394 TARGET_XFER_E_IO if we need to delegate to the target beneath
5395 but BENEATH is NULL.
5397 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
5399 * Makefile.in (config.status): Add configure.nat as a
5402 2018-06-04 Tom Tromey <tom@tromey.com>
5404 * cp-name-parser.y (cpname_state): Add method declarations.
5405 (HANDLE_QUAL): Update.
5406 (cpname_state::d_grab, cpname_state::fill_comp)
5407 (cpname_state::make_operator, cpname_state::make_dtor)
5408 (cpname_state::make_builtin_type, cpname_state::make_name)
5409 (cpname_state::d_qualify, cpname_state::d_int_type)
5410 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
5411 (%union): Move earlier.
5413 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5415 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
5417 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5419 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
5420 (aarch64_pseudo_write_1): Likewise.
5421 (aarch64_pseudo_read_value): Use helper.
5422 (aarch64_pseudo_write): Likewise.
5424 2018-06-04 Pedro Alves <palves@redhat.com>
5426 * darwin-nat.c (darwin_ops): Delete.
5427 (darwin_attach_pid): Use get_native_target.
5429 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5431 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
5432 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
5434 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5436 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
5437 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
5438 (aarch64_gdbarch_init): Check for SVE.
5439 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
5441 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5443 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
5444 * aarch64-tdep.h (aarch64_read_description): Likewise.
5445 * arch/aarch64.c (aarch64_create_target_description): Likewise.
5446 * arch/aarch64.h (aarch64_create_target_description): Likewise.
5447 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
5448 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
5449 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
5451 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
5453 * value.c (value_fetch_lazy_bitfield): New.
5454 (value_fetch_lazy_memory): New.
5455 (value_fetch_lazy_register): New.
5456 (value_fetch_lazy): Factor out to smaller functions.
5458 2018-06-01 Tom Tromey <tom@tromey.com>
5460 * cp-name-parser.y (backslashable, represented): Now const.
5462 2018-06-01 Tom Tromey <tom@tromey.com>
5464 * cp-name-parser.y: Include parser-defs.h.
5465 (parser_fprintf): Remove declaration.
5467 2018-06-01 Tom Tromey <tom@tromey.com>
5469 * cp-name-parser.y: Use %pure-parser, %lex-param, and
5471 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
5472 (global_result): Remove globals.
5473 (struct cpname_state): New.
5474 (yyparse): Don't declare.
5475 (yylex, yyerror): Move declarations after %union.
5476 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
5477 (make_name): Add state parameter.
5479 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
5481 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
5483 (yylex): Add lvalp, state parameters.
5484 (yyerror): Add state parameter.
5485 (cp_demangled_name_to_comp): Update.
5487 2018-06-01 Tom Tromey <tom@tromey.com>
5489 * cp-name-parser.y (parser_fprintf): Declare.
5490 (GDB_YY_REMAP_PREFIX): Define.
5491 Include yy-remap.h. Don't redefine yy* identifiers.
5493 2018-06-01 Tom Tromey <tom@tromey.com>
5495 * python/py-type.c (typy_legacy_template_argument): Update.
5496 * cp-support.h (cp_demangled_name_to_comp): Update.
5497 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
5498 parameter to be a "std::string *".
5501 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
5503 * ada-lex.l: Include "diagnostics.h" instead of
5504 "common/diagnostics.h".
5505 * unittests/environ-selftests.c: Likewise.
5506 * common/diagnostics.h: Moved to ../include.
5508 2018-06-01 Joel Brobecker <brobecker@adacore.com>
5510 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
5511 to language_mode_manual while calling breakpoint_re_set_one.
5513 2018-06-01 Tom Tromey <tom@tromey.com>
5515 * valops.c (value_cast_structs, destructor_name_p): Update.
5516 * symtab.c (gdb_mangle_name): Update.
5517 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
5519 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
5520 (pascal_object_print_value_fields, pascal_object_print_value):
5522 * p-typeprint.c (pascal_type_print_derivation_info): Update.
5523 * linespec.c (find_methods): Update.
5524 * gdbtypes.h (type_name_no_tag): Remove.
5525 (type_name_or_error): Rename from type_name_no_tag_or_error.
5526 * gdbtypes.c (type_name_no_tag): Remove.
5527 (type_name_or_error): Rename from type_name_no_tag_or_error.
5528 (lookup_struct_elt_type, check_typedef): Update.
5529 * expprint.c (print_subexp_standard): Update.
5530 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
5531 * d-namespace.c (d_lookup_nested_symbol): Update.
5532 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
5533 (cp_print_class_member): Update.
5534 * cp-namespace.c (cp_lookup_nested_symbol): Update.
5535 * completer.c (add_struct_fields): Update.
5536 * c-typeprint.c (cp_type_print_derivation_info)
5537 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
5539 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
5540 (ada_prefer_type, ada_is_exception_sym): Update.
5542 2018-06-01 Tom Tromey <tom@tromey.com>
5544 * valops.c (enum_constant_from_type, value_namespace_elt)
5545 (value_maybe_namespace_elt): Update.
5546 * valarith.c (find_size_for_pointer_math): Update.
5547 * target-descriptions.c (make_gdb_type): Update.
5548 * symmisc.c (print_symbol): Update.
5549 * stabsread.c (define_symbol, read_type)
5550 (complain_about_struct_wipeout, add_undefined_type)
5551 (cleanup_undefined_types_1): Update.
5552 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
5553 (rust_range_type_p, val_print_struct, rust_print_struct_def)
5554 (rust_internal_print_type, rust_composite_type)
5555 (rust_evaluate_funcall, rust_evaluate_subexp)
5556 (rust_inclusive_range_type_p): Update.
5557 * python/py-type.c (typy_get_tag): Update.
5558 * p-typeprint.c (pascal_type_print_base): Update.
5559 * mdebugread.c (parse_symbol, parse_type): Update.
5560 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
5562 * guile/scm-type.c (gdbscm_type_tag): Update.
5563 * go-lang.c (sixg_string_p): Update.
5564 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
5566 * gdbtypes.h (struct main_type) <tag_name>: Remove.
5567 (TYPE_TAG_NAME): Remove.
5568 * gdbtypes.c (type_name_no_tag): Simplify.
5569 (check_typedef, check_types_equal, recursive_dump_type)
5570 (copy_type_recursive, arch_composite_type): Update.
5571 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
5572 in summary mode when needed.
5573 * eval.c (evaluate_funcall): Update.
5574 * dwarf2read.c (fixup_go_packaging, read_structure_type)
5575 (process_structure_scope, read_enumeration_type)
5576 (read_namespace_type, read_module_type, determine_prefix): Update.
5577 * cp-support.c (inspect_type): Update.
5578 * coffread.c (process_coff_symbol, decode_base_type): Update.
5579 * c-varobj.c (c_is_path_expr_parent): Update.
5580 * c-typeprint.c (c_type_print_base_struct_union): Update.
5581 (c_type_print_base_1): Update. Print struct/class/union/enum in
5582 summary when using C language.
5583 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
5584 (gen_maybe_namespace_elt): Update.
5585 * ada-lang.c (ada_type_name): Simplify.
5586 (empty_record, ada_template_to_fixed_record_type_1)
5587 (template_to_static_fixed_type)
5588 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
5590 2018-06-01 Tom Tromey <tom@tromey.com>
5592 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
5594 * c-typeprint.c (c_print_type_1): Add "language" parameter.
5595 (c_print_type): Update.
5596 (c_print_type): New overload.
5597 (c_type_print_varspec_prefix, c_type_print_args)
5598 (c_type_print_varspec_suffix, c_print_type_no_offsets)
5599 (c_type_print_base_struct_union, c_type_print_base_1)
5600 (cp_type_print_method_args): Add "language" parameter.
5601 (c_type_print_base): Update.
5602 * c-lang.h (c_print_type): Add new overload.
5604 2018-06-01 Tom Tromey <tom@tromey.com>
5606 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
5607 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
5609 2018-06-01 Alan Hayward <alan.hayward@arm.com>
5611 * aarch64-tdep.c (aarch64_sve_register_names): New const
5613 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
5614 (AARCH64_SVE_Z_REGS_NUM): New define.
5615 (AARCH64_SVE_P_REGS_NUM): Likewise.
5616 (AARCH64_SVE_NUM_REGS): Likewise.
5618 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
5620 * nat/linux-ptrace.h [__alpha__]
5621 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
5624 2018-05-31 Maciej W. Rozycki <macro@mips.com>
5626 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
5627 the endianness selected.
5628 * NEWS: Document `set endian auto' mode operation update.
5630 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5632 * Makefile.in: Add new header.
5633 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
5634 (sve_vl_from_vg): Likewise.
5635 (sve_vq_from_vl): Likewise.
5636 (sve_vl_from_vq): Likewise.
5637 (sve_vq_from_vg): Likewise.
5638 (sve_vg_from_vq): Likewise.
5639 * configure.nat: Add new c file.
5640 * nat/aarch64-sve-linux-ptrace.c: New file.
5641 * nat/aarch64-sve-linux-ptrace.h: New file.
5643 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5645 * aarch64-linux-nat.c (aarch64_linux_read_description):
5647 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
5649 * aarch64-tdep.c (tdesc_aarch64_list): Add.
5650 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
5651 (aarch64_gdbarch_init): Add parmeter zero.
5652 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
5653 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
5654 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
5656 * doc/gdb.texinfo: Describe SVE feature
5657 * features/aarch64-sve.c: New file.
5659 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
5662 * gdbarch.sh (significant_addr_bit): Default to zero when
5663 not set by target architecture.
5664 * gdbarch.c: Re-generated.
5665 * utils.c (address_significant): Update.
5667 2018-05-30 Joel Brobecker <brobecker@adacore.com>
5669 * stack.c (func_command): Remove trailing newline in call to error.
5671 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5673 * regcache.h (regcache_raw_collect): Remove, update callers to
5674 use regcache::raw_collect.
5675 * regcache.c (regcache_raw_collect): Remove.
5677 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5679 * regcache.h (regcache_raw_supply): Remove, update callers to
5680 use detached_regcache::raw_supply.
5681 * regcache.c (regcache_raw_supply): Remove.
5683 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5685 * regcache.h (regcache_cooked_write_part): Remove, update
5686 callers to use regcache::cooked_write_part.
5687 * regcache.c (regcache_cooked_write_part): Remove.
5689 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5691 * regcache.h (regcache_cooked_read_part): Remove, update callers
5692 to use readable_regcache::cooked_read_part.
5693 * regcache.c (regcache_cooked_read_part): Remove.
5695 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5697 * regcache.h (regcache_cooked_read_value): Remove, update
5698 callers to use readable_regcache::cooked_read_value.
5699 * regcache.c (regcache_cooked_read_value): Remove.
5701 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5703 * regcache.h (regcache_cooked_write): Remove, update callers to
5704 use regcache::cooked_write.
5705 * regcache.c (regcache_cooked_write): Remove.
5707 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5709 * regcache.h (regcache_invalidate): Remove, update callers to
5710 use detached_regcache::invalidate instead.
5711 * regcache.c (regcache_invalidate): Remove.
5713 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5715 * regcache.h (regcache_raw_write_part): Remove, update callers
5716 to use regcache::raw_write_part instead.
5717 * regcache.c (regcache_raw_write_part): Remove.
5719 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5721 * regcache.h (regcache_raw_read_part): Remove, update callers to
5722 use readable_regcache::raw_read_part instead.
5723 * regcache.c (regcache_raw_read_part): Remove.
5725 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5727 * regcache.h (regcache_cooked_read): Remove, update callers to
5728 use readable_regcache::cooked_read instead.
5729 * regcache.c (regcache_cooked_read): Remove.
5731 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5733 * regcache.h (regcache_raw_write): Remove, update callers to use
5734 regcache::raw_write instead.
5735 * regcache.c (regcache_raw_write): Remove.
5737 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5739 * regcache.h (regcache_raw_read): Remove, update callers to use
5740 readable_regcache::raw_read instead.
5741 * regcache.c (regcache_raw_read): Remove.
5743 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5745 * regcache.h (regcache_raw_update): Remove, update callers to
5746 use readable_regcache::raw_update instead.
5747 * regcache.c (regcache_raw_update): Remove.
5749 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5751 * regcache.h (regcache_register_status): Remove, update callers
5752 to use reg_buffer::get_register_status directly instead.
5753 * regcache.c (regcache_register_status): Remove.
5755 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5757 * regcache.h (regcache_get_ptid): Remove, update all callers to
5758 call regcache::ptid instead.
5759 * regcache.c (regcache_get_ptid): Remove.
5761 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5763 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
5765 2018-05-30 Pedro Alves <palves@redhat.com>
5767 * common/common-exceptions.h (exception_rethrow): Use
5770 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
5772 * breakpoint.c (print_solib_event, check_status_catch_solib):
5773 Remove struct keyword in range-based for loops.
5774 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
5775 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
5777 * linespec.c (find_superclass_methods, search_minsyms_for_name):
5779 * symfile.c (addr_info_make_relative): Likewise.
5780 * thread.c (value_in_thread_stack_temporaries): Likewise.
5782 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
5785 * valops.c (value_struct_elt_for_reference): Call check_typedef on
5786 aggregate type to get its real type before accessing it.
5788 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
5790 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
5791 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
5792 * coff-pe-read.c (add_pe_forwarded_sym): Replace
5793 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
5794 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
5795 * jit.c (jit_breakpoint_re_set_internal): Likewise.
5796 * printcmd.c (info_address_command): Likewise.
5798 2018-05-29 Tom Tromey <tom@tromey.com>
5800 * windows-nat.c (handle_exception): Update fall-through comment.
5802 2018-05-29 Tom Tromey <tom@tromey.com>
5804 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
5805 (struct program_space) <added_solibs>: Now a std::vector.
5806 * breakpoint.c (print_solib_event): Update.
5807 (check_status_catch_solib): Update.
5808 * progspace.c (clear_program_space_solib_cache): Update.
5809 * solib.c (update_solib_list): Update.
5811 2018-05-29 Tom Tromey <tom@tromey.com>
5813 * python/py-type.c (typy_richcompare): Update.
5814 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
5815 * gdbtypes.h (types_deeply_equal): Return bool.
5816 (types_equal): Likewise.
5817 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
5819 (check_types_equal): Change worklist to std::vector. Return
5821 (struct type_equality_entry): Add constructor.
5822 (compare_maybe_null_strings): Return bool.
5823 (check_types_worklist): Return bool. Change worklist to
5825 (types_deeply_equal): Use std::vector.
5826 (types_equal): Return bool.
5827 (compare_maybe_null_strings): Simplify.
5829 2018-05-29 Tom Tromey <tom@tromey.com>
5831 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
5833 2018-05-29 Tom Tromey <tom@tromey.com>
5835 * objc-lang.h: Don't include cp-support.h.
5836 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
5839 2018-05-27 Tom Tromey <tom@tromey.com>
5841 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
5843 2018-05-25 Tom Tromey <tom@tromey.com>
5845 * value.c (value::location): Initialize.
5847 2018-05-25 Tom Tromey <tom@tromey.com>
5849 * dbxread.c (init_bincl_list): Remove.
5850 (bincl_list): Now a std::vector.
5851 (bincls_allocated, next_bincl): Remove.
5852 (free_bincl_list, do_free_bincl_list_cleanup)
5853 (make_cleanup_free_bincl_list): Remove.
5854 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
5856 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
5857 (struct header_file_location): Add constructor.
5858 (add_bincl_to_list): Remove.
5860 2018-05-25 Tom Tromey <tom@tromey.com>
5862 * tui/tui.c (tui_enable): Update.
5863 * mi/mi-interp.c (mi_interp::init): Update.
5864 * interps.h (class interp) <name>: New method.
5865 <m_name>: Rename from name.
5866 (~scoped_restore_interp): Update.
5867 * interps.c (interp::interp): Update.
5868 (interp_add, interp_set, interp_lookup_existing)
5869 (current_interp_named_p): Update.
5871 2018-05-25 Tom Tromey <tom@tromey.com>
5873 * interps.c (interp_name): Remove.
5874 * mi/mi-interp.c (mi_interp::init): Update.
5875 * interps.h (interp_name): Remove.
5876 (~scoped_restore_interp): Update.
5877 * tui/tui.c (tui_enable): Update.
5879 2018-05-25 Tom Tromey <tom@tromey.com>
5881 * utils.c (fputs_maybe_filtered): Update.
5882 * linespec.c (decode_line_full): Update.
5883 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
5884 (mi_print_breakpoint_for_event, mi_solib_loaded)
5885 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
5886 (mi_user_selected_context_changed): Update.
5887 * mi/mi-main.c (mi_execute_command): Update.
5888 * cli/cli-script.c (execute_control_command): Update.
5889 * python/python.c (execute_gdb_command): Update.
5890 * solib.c (info_sharedlibrary_command): Update.
5891 * interps.c (interp_ui_out): Remove.
5892 * interps.h (interp_ui_out): Remove.
5894 2018-05-25 Tom Tromey <tom@tromey.com>
5896 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
5897 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
5898 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
5900 2018-05-25 Tom Tromey <tom@tromey.com>
5902 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
5903 * interps.c (interp_exec): Use scoped_restore.
5905 2018-05-25 Tom Tromey <tom@tromey.com>
5907 * remote.c (remote_target::remote_file_get): Use
5909 (remote_target::remote_file_put): Likewise.
5911 2018-05-25 Tom Tromey <tom@tromey.com>
5913 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
5915 (get_pe_section_index, add_pe_exported_sym): Update.
5916 (read_pe_exported_syms): Use gdb::def_vector.
5918 2018-05-25 Tom Tromey <tom@tromey.com>
5920 * frame.c (remove_prev_frame): Remove.
5921 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
5923 2018-05-25 Maciej W. Rozycki <macro@mips.com>
5925 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
5927 * mips-linux-nat.c (supply_fpregset): Always call
5928 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
5929 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
5930 `mips_fill_fpregset'.
5931 * mips-linux-tdep.c (mips_supply_fpregset)
5932 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
5933 (mips_fill_fpregset_wrapper): Remove functions.
5934 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
5935 (mips_linux_fpregset): Remove variable.
5936 (mips_linux_iterate_over_regset_sections): Use
5937 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
5938 (mips_linux_o32_sigframe_init): Remove comment.
5940 2018-05-25 Pedro Alves <palves@redhat.com>
5942 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
5943 (struct readahead_cache, struct packet_reg, struct
5944 remote_arch_state, class remote_state): Move higher up in the
5946 (remote_target::m_remote_state): Now an object instead of a pointer.
5947 (remote_target::get_remote_state): Adjust.
5949 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
5951 * stack.c (select_and_print_frame): Delete.
5952 (struct function_bounds): Move struct within function.
5953 (func_command): Most content moved into new function
5954 find_frame_for_function, use new function, print result, add
5956 (find_frame_for_function): New function, now returns a result.
5958 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5960 * stack.c (iterate_over_block_arg_vars): Fix comment.
5961 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
5963 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
5967 (scoped_restore_selected_frame::scoped_restore_selected_frame):
5969 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
5971 * frame.h (class scoped_restore_selected_frame): New class.
5972 * stack.c (print_frame_local_vars): Remove catching and rethrowing
5973 of any exception, use scoped_restore_selected_frame to restore the
5976 2018-05-24 Pedro Alves <palves@redhat.com>
5978 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
5981 2018-05-23 Tom Tromey <tom@tromey.com>
5983 * complaints.c (struct complaints): Remove.
5984 (symfile_complaint_book): Remove.
5985 (series): New global.
5986 (complaint_internal): Update.
5987 (clear_complaints): Update.
5989 2018-05-23 Tom Tromey <tom@tromey.com>
5991 * complaints.c (counters): New global.
5992 (struct complain): Remove.
5993 (struct complaints) <root>: Remove.
5994 (complaint_sentinel): Remove.
5995 (symfile_complaint_book): Update.
5996 (find_complaint) Remove.
5997 (complaint_internal, clear_complaints): Update.
5999 2018-05-23 Tom Tromey <tom@tromey.com>
6001 * complaints.c (struct complain) <file, line>: Remove.
6002 (find_complaint): Remove file, line parameters.
6003 (complaint_internal): Update.
6005 2018-05-23 Tom Tromey <tom@tromey.com>
6007 * complaints.c (vcomplaint): Remove.
6008 (complaint_internal) Merge in contents of vcomplaint.
6010 2018-05-23 Tom Tromey <tom@tromey.com>
6012 * complaints.c (struct complaints) <explanation>: Remove.
6013 (symfile_explanations): Remove.
6014 (symfile_complaint_book): Update.
6015 (vcomplaint): Update.
6016 (struct explanation): Remove.
6018 2018-05-23 Tom Tromey <tom@tromey.com>
6020 * complaints.c (symfile_complaints): Remove.
6021 (complaint_internal): Remove "complaints" parameter.
6022 (clear_complaints, vcomplaint): Remove "c" parameter.
6023 (get_complaints): Remove.
6024 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
6025 (dwarf2_debug_line_missing_file_complaint)
6026 (dwarf2_debug_line_missing_end_sequence_complaint)
6027 (dwarf2_complex_location_expr_complaint)
6028 (dwarf2_const_value_length_mismatch_complaint)
6029 (dwarf2_section_buffer_overflow_complaint)
6030 (dwarf2_macro_malformed_definition_complaint)
6031 (dwarf2_invalid_attrib_class_complaint)
6032 (create_addrmap_from_index, dw2_symtab_iter_next)
6033 (dw2_expand_marked_cus)
6034 (dw2_debug_names_iterator::find_vec_in_debug_names)
6035 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
6036 (create_debug_type_hash_table, init_cutu_and_read_dies)
6037 (partial_die_parent_scope, add_partial_enumeration)
6038 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
6039 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
6040 (read_import_statement, read_file_scope, create_dwo_cu_reader)
6041 (create_cus_hash_table, create_dwp_hash_table)
6042 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
6043 (dwarf2_rnglists_process, dwarf2_ranges_process)
6044 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
6045 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
6046 (handle_struct_member_die, process_structure_scope)
6047 (read_array_type, read_common_block, read_module_type)
6048 (read_tag_pointer_type, read_typedef, read_base_type)
6049 (read_subrange_type, load_partial_dies, partial_die_info::read)
6050 (partial_die_info::read, partial_die_info::read)
6051 (partial_die_info::read, read_checked_initial_length_and_offset)
6052 (dwarf2_string_attr, read_formatted_entries)
6053 (dwarf_decode_line_header)
6054 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
6055 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
6056 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
6057 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
6058 (get_signatured_type, get_DW_AT_signature_type)
6059 (decode_locdesc, file_file_name, consume_improper_spaces)
6060 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
6061 (dwarf_decode_macro_bytes, dwarf_decode_macros)
6062 (dwarf2_symbol_mark_computed, set_die_type)
6063 (read_attribute_value): Update.
6064 * stap-probe.c (handle_stap_probe, get_stap_base_address):
6066 * dbxread.c (unknown_symtype_complaint)
6067 (lbrac_mismatch_complaint, repeated_header_complaint)
6068 (set_namestring, function_outside_compilation_unit_complaint)
6069 (read_dbx_symtab, process_one_symbol): Update.
6070 * gdbtypes.c (stub_noname_complaint): Update.
6071 * windows-nat.c (handle_unload_dll): Update.
6072 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
6073 (decode_base_type): Update.
6074 * xcoffread.c (bf_notfound_complaint, ef_complaint)
6075 (eb_complaint, record_include_begin, record_include_end)
6076 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
6077 (process_xcoff_symbol, read_symbol)
6078 (function_outside_compilation_unit_complaint)
6079 (scan_xcoff_symtab): Update.
6080 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
6081 * buildsym.c (finish_block_internal, make_blockvector)
6082 (end_symtab_get_static_block, augment_type_symtab): Update.
6083 * dtrace-probe.c (dtrace_process_dof)
6084 (dtrace_static_probe_ops::get_probes): Update.
6085 * complaints.h (struct complaint): Don't declare.
6086 (symfile_complaints): Remove.
6087 (complaint_internal): Remove "complaints" parameter.
6088 (complaint): Likewise.
6089 (clear_complaints): Likewise.
6090 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6091 (reread_symbols): Update.
6092 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
6093 (dwarf2_frame_cache, decode_frame_entry): Update.
6094 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
6095 * objc-lang.c (lookup_objc_class, lookup_child_selector)
6096 (info_selectors_command): Update.
6097 * macrotab.c (macro_include, check_for_redefinition)
6098 (macro_undef): Update.
6099 * objfiles.c (filter_overlapping_sections): Update.
6100 * stabsread.c (invalid_cpp_abbrev_complaint)
6101 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
6102 (define_symbol, error_type, read_type, rs6000_builtin_type)
6103 (stabs_method_name_from_physname, read_member_functions)
6104 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
6105 (attach_fields_to_type, complain_about_struct_wipeout)
6106 (read_range_type, read_args, common_block_start)
6107 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
6109 * mdebugread.c (index_complaint, unknown_ext_complaint)
6110 (basic_type_complaint, bad_tag_guess_complaint)
6111 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
6112 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
6113 (parse_procedure, parse_lines)
6114 (function_outside_compilation_unit_complaint)
6115 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
6116 (bad_tag_guess_complaint, reg_value_complaint): Update.
6117 * cp-support.c (demangled_name_complaint): Update.
6118 * macroscope.c (sal_macro_scope): Update.
6119 * dwarf-index-write.c (class debug_names): Update.
6121 2018-05-23 Tom Tromey <tom@tromey.com>
6123 * complaints.c (clear_complaints): Remove "noisy" parameter.
6124 * complaints.h (clear_complaints): Update.
6125 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6126 (reread_symbols): Update.
6128 2018-05-23 Tom Tromey <tom@tromey.com>
6130 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
6132 (vcomplaint, clear_complaints): Update.
6133 (symfile_explanations): Remove some messages.
6135 2018-05-23 Tom Tromey <tom@tromey.com>
6137 * complaints.c (internal_complaint): Remove.
6138 * complaints.h (internal_complaint): Remove.
6140 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6142 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
6144 2018-05-22 Pedro Alves <palves@redhat.com>
6146 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
6147 (remote_fileio_badfd, remote_fileio_return_errno)
6148 (remote_fileio_return_success, remote_fileio_func_open)
6149 (remote_fileio_func_open, remote_fileio_func_close)
6150 (remote_fileio_func_read, remote_fileio_func_write)
6151 (remote_fileio_func_lseek, remote_fileio_func_rename)
6152 (remote_fileio_func_unlink, remote_fileio_func_stat)
6153 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
6154 (remote_fileio_func_isatty, remote_fileio_func_system): Add
6155 remote_target parameter.
6156 (remote_fio_func_map) <func>: Add remote_target parameter.
6157 (do_remote_fileio_request, remote_fileio_request):
6158 * remote-fileio.h (remote_fileio_request):
6159 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
6160 remote_target parameter.
6161 (remote_notif_process, handle_notification): Adjust to pass down
6163 (remote_notif_state_allocate): Add remote_target parameter. Save
6165 * remote-notif.h (struct remote_target): Forward declare.
6166 (struct notif_client) <parse, ack, can_get_pending_events>: Add
6167 remote_target parameter.
6168 (struct remote_notif_state) <remote>: New field.
6169 (remote_notif_ack, remote_notif_parse): Add remote_target
6171 (remote_notif_state_allocate, remote_notif_state_allocate): Add
6172 remote_target parameter.
6173 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
6174 (threads_listing_context, rmt_thread_action, protocol_feature)
6175 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
6176 (packet_result, struct threads_listing_context, remote_state):
6177 Move definitions and declarations higher up.
6178 (remote_target) <~remote_target>: Declare.
6179 (remote_download_command_source, remote_file_put, remote_file_get)
6180 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
6181 (remote_hostio_pread_vFile, remote_hostio_send_command)
6182 (remote_hostio_set_filesystem, remote_hostio_open)
6183 (remote_hostio_close, remote_hostio_unlink, remote_state)
6184 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
6185 (get_memory_write_packet_size, get_memory_read_packet_size)
6186 (append_pending_thread_resumptions, remote_detach_1)
6187 (append_resumption, remote_resume_with_vcont)
6188 (add_current_inferior_and_thread, wait_ns, wait_as)
6189 (process_stop_reply, remote_notice_new_inferior)
6190 (process_initial_stop_replies, remote_add_thread)
6191 (btrace_sync_conf, remote_btrace_maybe_reopen)
6192 (remove_new_fork_children, kill_new_fork_children)
6193 (discard_pending_stop_replies, stop_reply_queue_length)
6194 (check_pending_events_prevent_wildcard_vcont)
6195 (discard_pending_stop_replies_in_queue, stop_reply)
6196 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
6197 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
6198 (remote_interrupt_as, remote_interrupt_ns)
6199 (remote_get_noisy_reply, remote_query_attached)
6200 (remote_add_inferior, remote_current_thread, get_current_thread)
6201 (set_thread, set_general_thread, set_continue_thread)
6202 (set_general_process, write_ptid)
6203 (remote_unpack_thread_info_response, remote_get_threadinfo)
6204 (parse_threadlist_response, remote_get_threadlist)
6205 (remote_threadlist_iterator, remote_get_threads_with_ql)
6206 (remote_get_threads_with_qxfer)
6207 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
6208 (get_offsets, remote_check_symbols, remote_supported_packet)
6209 (remote_query_supported, remote_packet_size)
6210 (remote_serial_quit_handler, remote_detach_pid)
6211 (remote_vcont_probe, remote_resume_with_hc)
6212 (send_interrupt_sequence, interrupt_query)
6213 (remote_notif_get_pending_events, fetch_register_using_p)
6214 (send_g_packet, process_g_packet, fetch_registers_using_g)
6215 (store_register_using_P, store_registers_using_G)
6216 (set_remote_traceframe, check_binary_download)
6217 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
6218 (remote_xfer_live_readonly_partial, remote_read_bytes)
6219 (remote_send_printf, remote_flash_write, readchar)
6220 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
6221 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
6222 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
6223 (extended_remote_disable_randomization, extended_remote_run)
6224 (send_environment_packet, extended_remote_environment_support)
6225 (extended_remote_set_inferior_cwd, remote_write_qxfer)
6226 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
6227 (packet_command): Now methods of ...
6228 (remote_target): ... this class.
6229 (m_remote_state) <remote_target>: New field.
6230 (struct remote_state) <stop_reply_queue,
6231 remote_async_inferior_event_token, wait_forever_enabled_p>: New
6233 (remote_state::remote_state): Allocate stop_reply_queue.
6234 (remote_state): Delete global.
6235 (get_remote_state_raw): Delete.
6236 (remote_target::get_remote_state): Allocate m_remote_state on
6238 (get_current_remote_target): New.
6239 (remote_ops, extended_remote_ops): Delete.
6240 (wait_forever_enabled_p, remote_async_inferior_event_token):
6241 Delete, moved to struct remote_state.
6242 (remote_target::close): Delete self. Destruction bits split to
6244 (remote_target::~remote_target): ... this.
6245 (show_memory_packet_size): Adjust to use
6246 get_current_remote_target.
6247 (struct protocol_feature) <func>: Add remote_target parameter.
6248 All callers adjusted.
6249 (curr_quit_handler_target): New.
6250 (remote_serial_quit_handler): Reimplement.
6251 (remote_target::open_1): Adjust to use get_current_remote_target.
6252 Heap-allocate remote_target/extended_remote_target instances.
6253 (vcont_builder::vcont_builder): Add remote_target parameter, and
6254 save it in m_remote. All callers adjusted.
6255 (vcont_builder::m_remote): New field.
6256 (vcont_builder::restart, vcont_builder::flush)
6257 (vcont_builder::push_action): Use it.
6258 (remote_target::commit_resume): Use it.
6259 (struct queue_iter_param) <remote>: New field.
6260 (remote_target::remove_new_fork_children): Fill in 'remote' field.
6261 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
6262 (check_pending_event_prevents_wildcard_vcont_callback)
6263 (remote_target::check_pending_events_prevent_wildcard_vcont)
6264 (remote_target::discard_pending_stop_replies)
6265 (remote_target::discard_pending_stop_replies_in_queue)
6266 (remote_target::remote_notif_remove_queued_reply): Fill in
6268 (remote_notif_get_pending_events): New.
6269 (remote_target::readchar, remote_target::remote_serial_write):
6270 Save/restore curr_quit_handler_target.
6272 (kill_new_fork_children): Fill in 'remote' field.
6273 (packet_command): Use get_current_remote_target, defer to
6274 remote_target method of same name.
6275 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
6276 parameter, and save it in m_remote. All callers adjusted.
6277 (scoped_remote_fd::release): Use m_remote.
6278 (scoped_remote_fd::m_remote): New field.
6279 (remote_file_put, remote_file_get, remote_file_delete): Use
6280 get_current_remote_target, defer to remote_target method of same
6282 (remote_btrace_reset): Add remote_state paremeter. Update all
6284 (remote_async_inferior_event_handler). Pass down 'data'.
6285 (remote_new_objfile): Use get_current_remote_target.
6286 (remote_target::vcont_r_supported): New.
6287 (set_range_stepping): Use get_current_remote_target and
6288 remote_target::vcont_r_supported.
6289 (_initialize_remote): Don't allocate 'remote_state' and
6290 'stop_reply_queue' globals.
6291 * remote.h (struct remote_target): Forward declare.
6292 (getpkt, putpkt, remote_notif_get_pending_events): Add
6293 'remote_target' parameter.
6295 2018-05-22 Pedro Alves <palves@redhat.com>
6297 * remote.c (vcont_builder): Now a class. Make all data members
6299 (vcont_builder) <vcont_builder, restart, flush, push_action>:
6301 (vcont_builder_restart): Rename to ...
6302 (vcont_builder::restart): ... this.
6303 (vcont_builder_flush): Rename to ...
6304 (vcont_builder::flush): ... this.
6305 (vcont_builder_push_action): Rename to ...
6306 (vcont_builder::push_action): ... this.
6307 (remote_target::commit_resume): Adjust.
6309 2018-05-22 Pedro Alves <palves@redhat.com>
6311 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
6312 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
6313 (get_fixed_memory_packet_size): New.
6314 (get_memory_packet_size): Use it.
6315 (set_memory_packet_size): Don't override the config size with
6316 DEFAULT_MAX_MEMORY_PACKET_SIZE.
6317 (show_memory_packet_size): Use get_fixed_memory_packet_size.
6318 Don't refer to get_memory_packet_size if not connected to a remote
6319 target. Show "(default)" if configured size is 0.
6321 2018-05-22 Pedro Alves <palves@redhat.com>
6323 * remote.c (remote_target::mourn_inferior): Move
6324 discard_pending_stop_replies call here from ...
6325 (_initialize_remote): ... here.
6327 2018-05-22 Pedro Alves <palves@redhat.com>
6329 * remote.c (compare_section_command): Remove set_general_process
6332 2018-05-22 Pedro Alves <palves@redhat.com>
6334 * remote.c (struct packet_reg, struct remote_arch_state):
6335 Move higher up in the file.
6336 (remote_state) <m_arch_states>: Store remote_arch_state values
6337 instead of remote_arch_state pointers.
6338 (remote_state::get_remote_arch_state): Adjust.
6340 2018-05-22 Pedro Alves <palves@redhat.com>
6342 * remote.c: Include <unordered_map>.
6343 (remote_state): Now a class.
6344 (remote_state) <get_remote_arch_state>: Declare method.
6345 <get_remote_arch_state>: New field.
6346 (remote_arch_state) <remote_arch_state>: Declare ctor.
6347 <regs>: Now a unique_ptr.
6348 (remote_gdbarch_data_handle): Delete.
6349 (get_remote_arch_state): Delete.
6350 (remote_state::get_remote_arch_state): New.
6351 (get_remote_state): Adjust to call remote_state's
6352 get_remote_arch_state method.
6353 (init_remote_state): Delete, bits factored out to ...
6354 (remote_arch_state::remote_arch_state): ... this new method.
6355 (get_remote_packet_size, get_memory_packet_size)
6356 (process_g_packet, remote_target::fetch_registers)
6357 (remote_target::prepare_to_store, store_registers_using_G)
6358 (remote_target::store_registers, remote_target::get_trace_status):
6359 Adjust to call remote_state's method.
6360 (_initialize_remote): Remove reference to
6361 remote_gdbarch_data_handle.
6363 2018-05-22 Pedro Alves <palves@redhat.com>
6365 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
6366 pread>: New method declarations.
6367 (remote_target::open_1): Adjust.
6368 (readahead_cache_invalidate): Rename to ...
6369 (readahead_cache::invalidate): ... this, and adjust to be a class
6371 (readahead_cache_invalidate_fd): Rename to ...
6372 (readahead_cache::invalidate_fd): ... this, and adjust to be a
6374 (remote_hostio_pwrite): Adjust.
6375 (remote_hostio_pread_from_cache): Rename to ...
6376 (readahead_cache::pread): ... this, and adjust to be a class
6378 (remote_hostio_close): Adjust.
6380 2018-05-22 Pedro Alves <palves@redhat.com>
6382 * remote.c (remote_hostio_close_cleanup): Delete.
6383 (class scoped_remote_fd): New.
6384 (remote_file_put, remote_file_get): Use it.
6386 2018-05-22 Pedro Alves <palves@redhat.com>
6388 (struct vCont_action_support): Use bool and initialize all fields.
6389 (struct readahead_cache): Initialize all fields.
6390 (remote_state): Use bool and initialize all fields.
6391 (remote_state::remote_state, remote_state::~remote_state): New.
6392 (new_remote_state): Delete.
6393 (_initialize_remote): Use new to allocate remote_state.
6395 2018-05-22 Pedro Alves <palves@redhat.com>
6399 * c-exp.y: Include "c-support.h".
6400 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
6401 of tolower. Use c_ident_is_alpha to scan names.
6402 * c-lang.c: Include "c-support.h".
6403 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
6404 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
6405 * c-support.h: New file, with bits factored out from ...
6406 * cp-name-parser.y: ... this file.
6407 Include "c-support.h".
6408 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
6409 c-support.h and renamed.
6410 (symbol_end, yylex): Adjust.
6412 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6414 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
6415 parameter type to CORE_ADDR.
6416 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
6417 parameter type in declaration to CORE_ADDR.
6418 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
6419 target_auxv_search to get AT_HWCAP and use the result to get the
6421 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
6422 to CORE_ADDR. Remove the cast of the return value to unsigned
6423 long. Fix error predicate of target_auxv_search.
6424 (ppc_linux_nat_target::read_description): Change the type of the
6425 hwcap variable to CORE_ADDR.
6427 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6429 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
6430 if the size of fpscr is larger than 32 bits.
6432 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6434 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
6435 (ppc32_linux_vsxregmap): New global.
6436 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
6437 regcache_supply_regset, and regcache_collect_regset.
6438 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
6439 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
6440 (fetch_vsx_register, store_vsx_register): Remove.
6441 (fetch_vsx_registers): Add regno parameter. Get regset using
6442 ppc_linux_vsxregset. Use regset to supply registers.
6443 (store_vsx_registers): Add regno parameter. Get regset using
6444 ppc_linux_vsxregset. Use regset to collect registers.
6445 (fetch_register): Call fetch_vsx_registers instead of
6447 (store_register): Call store_vsx_registers instead of
6449 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
6450 new regno parameter.
6451 (store_ppc_registers): Call store_vsx_registers with -1 for the
6452 new regno parameter.
6453 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
6454 (ppc_collect_vsxregset): Remove.
6456 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6458 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
6460 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
6461 for vector register offset fields.
6462 (ppc64_fbsd_reg_offsets): Likewise.
6463 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6464 to vector register offset fields.
6465 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6466 to vector register offset fields.
6467 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
6468 vector register offset fields.
6469 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
6470 initializers for vector register offset fields.
6471 (rs6000_aix64_reg_offsets): Likewise.
6472 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
6473 (ppc_supply_vrregset): Remove.
6474 (ppc_collect_vrregset): Remove.
6475 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
6476 (ppc_linux_vrregset) : New function.
6477 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
6478 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
6479 (ppc32_linux_vrregset): Remove.
6480 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
6481 and use result instead of ppc32_linux_vrregset.
6482 (ppc32_linux_reg_offsets): Remove initializers for vector register
6484 (ppc64_linux_reg_offsets): Likewise.
6485 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
6486 * ppc-linux-nat.c: Include regset.h.
6487 (gdb_vrregset_t): Adjust comment to account for little-endian
6489 (supply_vrregset, fill_vrregset): Remove.
6490 (fetch_altivec_register, store_altivec_register): Remove.
6491 (fetch_altivec_registers): Add regno parameter. Get regset using
6492 ppc_linux_vrregset. Use regset to supply registers.
6493 (store_altivec_registers): Add regno parameter. Get regset using
6494 ppc_linux_vrregset. Use regset to collect registers.
6495 (fetch_register): Call fetch_altivec_registers instead of
6496 fetch_altivec_register.
6497 (store_register): Call store_altivec_registers instead of
6498 store_altivec_register.
6499 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
6500 the new regno parameter.
6501 (store_ppc_registers): Call store_altivec_registers with -1 for
6502 the new regno parameter.
6504 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6506 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
6507 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
6508 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
6509 (gdb_vrregset_t): Change array type size to
6510 PPC_LINUX_SIZEOF_VRREGSET.
6511 (gdb_vsxregset_t): Change array type size to
6512 PPC_LINUX_SIZEOF_VSXREGSET.
6513 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
6514 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
6515 PPC_LINUX_SIZEOF_VSXREGSET.
6517 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6519 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
6520 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
6522 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
6523 ppc_linux_target_wordsize with tid.
6524 (ppc_linux_nat_target::read_description): Call ppc_linux_target
6526 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
6527 (ppc64_64bit_inferior_p): Add static and inline specifiers.
6528 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
6529 tid parameter. Remove static specifier.
6530 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
6531 (ppc_linux_target_wordsize): New declaration.
6533 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6535 * arch/ppc-linux-common.c: New file.
6536 * arch/ppc-linux-common.h: New file.
6537 * arch/ppc-linux-tdesc.h: New file.
6538 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
6539 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
6540 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
6541 arch/ppc-linux-tdesc.h.
6542 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
6543 arch/ppc-linux-tdesc.h.
6544 (ppc_linux_nat_target::read_description): Remove target
6545 description matching code. Fill a ppc_linux_features struct and
6546 call ppc_linux_match_description with it. Move comment about ISA
6547 2.05 to ppc-linux-common.c.
6548 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
6549 arch/ppc-linux-tdesc.h.
6550 (ppc_linux_core_read_description): Remove target description
6551 matching code. Fill a ppc_linux_features struct and call
6552 ppc_linux_match_description with it.
6553 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
6554 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
6555 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
6556 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
6557 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
6558 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
6559 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
6560 (tdesc_powerpc_e500l): Remove.
6562 2018-05-22 Joel Brobecker <brobecker@adacore.com>
6564 * ada-lang.c (catch_assert_command): Pass empty string instead
6565 of NULL for excep_string argument.
6567 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6569 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
6570 the width of the requested register exceeds the width of the
6573 2018-05-21 Tom Tromey <tom@tromey.com>
6575 * printcmd.c (output_command): Remove.
6576 (output_command_const): Rename to output_command.
6577 * valprint.h (output_command): Rename from output_command_const.
6578 * tracepoint.c (trace_dump_actions): Call output_command.
6580 2018-05-21 Tom Tromey <tom@tromey.com>
6582 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
6583 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
6584 * ada-lang.h (create_ada_exception_catchpoint): Update.
6585 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
6587 (create_excep_cond_exprs, ~ada_catchpoint)
6588 (should_stop_exception, print_one_exception)
6589 (print_mention_exception, print_recreate_exception): Update.
6590 (ada_get_next_arg): Remove.
6591 (catch_ada_exception_command_split): Use std::string. Change type
6592 of "excep_string", "cond_string".
6593 (catch_ada_exception_command): Update.
6594 (create_ada_exception_catchpoint): Change type of excep_string.
6595 (ada_exception_sal): Remove excep_string parameter.
6596 (~ada_catchpoint): Remove.
6598 2018-05-21 Tom Tromey <tom@tromey.com>
6600 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
6603 2018-05-21 Tom Tromey <tom@tromey.com>
6605 * ada-lang.c (ada_exception_message_1, ada_exception_message):
6606 Return unique_xmalloc_ptr.
6607 (print_it_exception): Update.
6609 2018-05-21 Tom Tromey <tom@tromey.com>
6611 * tracepoint.c (trace_dump_actions): Use std::string.
6613 2018-05-21 Tom Tromey <tom@tromey.com>
6615 * symfile.c (reread_symbols): Use std::string for original_name.
6617 2018-05-21 Tom Tromey <tom@tromey.com>
6619 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
6620 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
6623 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
6625 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
6627 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
6628 * objfiles.c (get_objfile_bfd_data): Allocate
6629 objfile_per_bfd_storage with obstack_new when allocating on
6632 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
6634 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
6636 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
6637 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
6638 * mdebugread.c (mdebug_build_psymtabs): Likewise.
6639 (add_pending): Likewise.
6640 (parse_symbol): Likewise.
6641 (parse_partial_symbols): Likewise.
6642 (psymtab_to_symtab_1): Likewise.
6643 (new_psymtab): Likewise.
6644 (elfmdebug_build_psymtabs): Likewise.
6645 * minsyms.c (terminate_minimal_symbol_table): Likewise.
6646 * objfiles.c (get_objfile_bfd_data): Likewise.
6647 (objfile_register_static_link): Likewise.
6648 * psymtab.c (allocate_psymtab): Likewise.
6649 * stabsread.c (read_member_functions): Likewise.
6650 * xcoffread.c (xcoff_end_psymtab): Likewise.
6652 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
6654 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
6655 compiler supports std::is_trivially_constructible.
6656 * common/poison.h: Include obstack.h.
6657 (IsMallocable): Define to is_trivially_constructible if the
6658 compiler supports it, define to true_type otherwise.
6662 (XOBNEWVEC): Redefine.
6663 * gdb_obstack.h (obstack_zalloc): New.
6664 (OBSTACK_ZALLOC): Redefine.
6665 (obstack_calloc): New.
6666 (OBSTACK_CALLOC): Redefine.
6668 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
6669 (gdbarch_obstack): New declaration in gdbarch.h, definition in
6671 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
6672 obstack_calloc/obstack_zalloc.
6673 (gdbarch_obstack_zalloc): Remove.
6674 * target-descriptions.c (tdesc_data_init): Use obstack_new.
6676 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6678 * stack.c (backtrace_command_1): Remove useless variable int i.
6680 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6682 * stack.c (print_frame_info): Fix comment.
6684 2018-05-18 Tom Tromey <tom@tromey.com>
6686 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
6687 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
6688 (~dwarf2_per_objfile): Update
6689 (dwarf2_get_dwz_file): Use new.
6690 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
6693 2018-05-18 Tom Tromey <tom@tromey.com>
6695 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
6697 * dwarf2read.c (struct dwp_file): Add constructor and
6699 (open_and_init_dwp_file): Return a unique_ptr.
6700 (dwarf2_per_objfile, create_dwp_hash_table)
6701 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
6702 (lookup_dwo_unit_in_dwp): Update.
6703 (open_and_init_dwp_file, get_dwp_file): Update.
6705 2018-05-18 Tom Tromey <tom@tromey.com>
6707 * dwarf2read.c (dwarf2_per_objfile): Update.
6708 (struct mapped_index): Add initializers.
6709 (dwarf2_read_index): Use new.
6710 (dw2_symtab_iter_init): Update.
6711 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
6714 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6716 * dwarf2read.c (mapped_index) <total_size>: Remove.
6718 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6720 * unittests/format_pieces-selftests.c (test_format_specifier):
6723 2018-05-18 Tom Tromey <tom@tromey.com>
6725 * c-typeprint.c (maybe_print_hole): New function.
6726 (c_print_type_struct_field_offset): Update.
6727 (c_type_print_base_struct_union): Call maybe_print_hole.
6729 2018-05-17 Keith Seitz <keiths@redhat.com>
6731 * breakpoint.c (build_bpstat_chain): New function, moved from
6733 (bpstat_stop_status): Add optional parameter, `stop_chain'.
6734 If no stop chain is passed, call build_bpstat_chain to build it.
6735 * breakpoint.h (build_bpstat_chain): Declare.
6736 (bpstat_stop_status): Move documentation here from breakpoint.c.
6737 * infrun.c (handle_signal_stop): Before eliding inlined frames,
6738 build the stop chain and pass it to skip_inline_frames.
6739 Pass this stop chain to bpstat_stop_status.
6740 * inline-frame.c: Include breakpoint.h.
6741 (stopped_by_user_bp_inline_frame): New function.
6742 (skip_inline_frames): Add parameter `stop_chain'.
6743 Move documention to inline-frame.h.
6744 If non-NULL, use stopped_by_user_bp_inline_frame to determine
6745 whether the frame should be elided.
6746 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
6747 Add moved documentation and update for new parameter.
6749 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
6752 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6753 unittests/format_pieces-selftests.c.
6754 * common/format.h (format_piece) <operator==>: New.
6755 (format_pieces) <operator[]>: Remove.
6756 * common/format.c (format_pieces::format_pieces): Handle \e.
6757 * unittests/format_pieces-selftests.c: New.
6759 2018-05-17 Tom Tromey <tom@tromey.com>
6762 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
6763 (dw2_instantiate_symtab): Add skip_partial parameter.
6764 (dw2_find_last_source_symtab, dw2_map_expand_apply)
6765 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
6766 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
6767 (dw2_expand_symtabs_matching_one)
6768 (dw2_find_pc_sect_compunit_symtab)
6769 (dw2_debug_names_lookup_symbol)
6770 (dw2_debug_names_expand_symtabs_for_function): Update.
6771 (init_cutu_and_read_dies): Add skip_partial parameter.
6772 (process_psymtab_comp_unit, build_type_psymtabs_1)
6773 (process_skeletonless_type_unit, load_partial_comp_unit)
6774 (psymtab_to_symtab_1): Update.
6775 (load_full_comp_unit): Add skip_partial parameter.
6776 (process_imported_unit_die, dwarf2_read_addr_index)
6777 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
6778 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
6779 (read_signatured_type): Update.
6781 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
6783 * value.c (release_value): Remove unused variable.
6784 (record_latest_value): Likewise.
6785 (access_value_history): Likewise.
6786 (preserve_values): Likewise.
6788 2018-05-17 Tom Tromey <tom@tromey.com>
6790 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
6793 2018-05-16 Maciej W. Rozycki <macro@mips.com>
6796 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
6797 Also handle registers whose width is not a multiple of
6799 (linux_nat_trad_target::store_register): Likewise.
6801 2018-05-16 Tom Tromey <tom@tromey.com>
6803 * gdbcore.h (core_bfd): Redefine.
6804 * corelow.c (core_target::close): Update.
6805 (core_target_open): Update.
6806 * progspace.h (struct program_space) <cbfd>: Now a
6809 2018-05-16 Tom Tromey <tom@tromey.com>
6812 * symfile-add-flags.h (enum symfile_add_flags)
6813 <SYMFILE_NOT_FILENAME>: New constant.
6814 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
6815 objfile name from BFD.
6816 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
6817 * minidebug.c (find_separate_debug_file_in_section): Put
6818 ".gnu_debugdata" into BFD's file name.
6820 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
6822 * regcache.c (regcache_read_ftype, regcache_write_ftype):
6825 2018-05-15 Tamar Christina <tamar.christina@arm.com>
6828 * aarch64-tdep.c (aarch64_analyze_prologue,
6829 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
6830 Indicate not interested in errors.
6832 2018-05-15 Maciej W. Rozycki <macro@mips.com>
6834 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
6835 Supply the MIPS_ZERO_REGNUM register.
6837 2018-05-15 Maciej W. Rozycki <macro@mips.com>
6839 * mips-tdep.c (mask_address_var): Make variable static.
6841 2018-05-14 Tom Tromey <tom@tromey.com>
6843 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
6845 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
6847 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
6848 FXSAVE_ADDR for the mxcsr register.
6850 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
6852 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
6854 2018-05-11 Pedro Alves <palves@redhat.com>
6856 * corelow.c (core_target) <core_target>: No longer inline.
6857 Initialize m_core_gdbarch, m_core_vec and build the section table
6859 <~core_target>: New.
6860 <core_gdbarch, get_core_register_section>: New methods.
6861 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
6862 factored out from ...
6863 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
6865 (sniff_core_bfd): Add gdbarch parameter.
6866 (core_close): Delete, merged into ...
6867 (core_target::close): ... here. Delete self.
6868 (core_close_cleanup): Delete.
6869 (core_target_open): Allocate a core_target on the heap. Use a
6870 unique_ptr instead of a cleanup. Bits moved into the core_target
6871 ctor. Adjust to use core_target methods instead of globals.
6872 (get_core_register_section): Rename to ...
6873 (core_target::get_core_register_section): ... this and adjust.
6874 (struct get_core_registers_cb_data): New.
6875 (get_core_registers_cb): Use it. Use bool.
6876 (core_target::fetch_registers, core_target::files_info)
6877 (core_target::xfer_partial, core_target::read_description)
6878 (core_target::pid_to, core_target::thread_name): Adjust to
6879 reference class fields instead of globals.
6880 * target.h (struct target_ops_deleter, target_ops_up): New.
6882 2018-05-11 Pedro Alves <palves@redhat.com>
6884 * corefile.c (core_file_command): Move to corelow.c.
6885 * corelow.c (the_core_target): Delete.
6886 (core_file_command): Moved from corefile.c. Check exec_bfd
6887 instead of the_core_target. Use target_detach instead of calling
6888 into the_core_target directly.
6889 (maybe_say_no_core_file_now): New.
6890 (core_target::detach): Use it.
6891 (_initialize_corelow): Remove references to the_core_target.
6892 * gdbcore.h (the_core_target): Delete.
6894 2018-05-11 Tom Tromey <tromey@redhat.com>
6895 Pedro Alves <palves@redhat.com>
6897 * corefile.c (core_bfd): Remove.
6898 * gdbcore.h (core_bfd): Now a macro.
6899 * progspace.h (struct program_space) <cbfd>: New field.
6901 2018-05-11 Tom Tromey <tom@tromey.com>
6903 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
6906 2018-05-10 Tom Tromey <tom@tromey.com>
6908 * configure: Rebuild.
6909 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
6911 2018-05-10 Joel Brobecker <brobecker@adacore.com>
6914 * regformats/regdat.sh: Adjust script, following the addition
6915 of the new expedite_regs parameter to init_target_desc.
6917 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
6920 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
6921 set_gdbarch_significant_addr_bit.
6922 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
6923 set_gdbarch_significant_addr_bit.
6924 * utils.c (address_significant): Update to sign extend addr.
6926 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
6928 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
6929 (xtensa_linux_init_abi): Limit tdep->num_regs by
6930 tdep->num_nopriv_regs.
6931 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
6932 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
6935 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
6937 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
6939 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
6941 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
6942 (I387_MXCSR_INIT_VAL): New constant.
6943 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
6944 buffer if it was supplied by the inferior.
6945 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
6946 (i387_xsave_get_clear_bv): New function.
6947 (i387_supply_xsave): Only read x87 control registers from the
6948 xsave buffer if the feature is enabled, and the state will have
6949 been written, otherwise, provide a suitable default.
6950 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
6951 including x87 control registers. Update control registers if they
6952 have changed from the default value, and mark features as enabled
6954 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
6956 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
6958 * spu-tdep.c (info_spu_event_command): Fix output formatting.
6960 2018-05-07 Tom Tromey <tom@tromey.com>
6962 * configure: Rebuild.
6963 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
6965 2018-05-07 Tom Tromey <tom@tromey.com>
6968 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
6969 bit. Use correct value for VDIV.
6971 2018-05-04 Tom Tromey <tom@tromey.com>
6973 * configure: Rebuild.
6974 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
6976 2018-05-04 Tom Tromey <tom@tromey.com>
6978 * linux-record.c (record_linux_system_call) <case
6979 RECORD_SYS_RECVFROM>: Add "break".
6981 2018-05-04 Tom Tromey <tom@tromey.com>
6983 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
6984 Add missing "break".
6985 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
6986 Add missing "break".
6988 2018-05-04 Tom Tromey <tom@tromey.com>
6990 * rs6000-tdep.c (ppc_process_record_op4)
6991 (ppc_process_record_op63): Add fall-through comment.
6993 2018-05-04 Tom Tromey <tom@tromey.com>
6995 * i386-tdep.c (i386_process_record): Add fall-through comment.
6997 2018-05-04 Tom Tromey <tom@tromey.com>
6999 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
7002 2018-05-04 Tom Tromey <tom@tromey.com>
7004 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
7005 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
7006 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
7008 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
7010 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
7013 2018-05-04 Tom Tromey <tom@tromey.com>
7015 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
7017 2018-05-04 Tom Tromey <tom@tromey.com>
7019 * s390-tdep.c (s390_process_record): Fix fall-through comments.
7020 * xcoffread.c (scan_xcoff_symtab): Move comment later.
7021 * symfile.c (section_is_mapped): Fix fall-through comment.
7022 * stabsread.c (define_symbol, read_member_functions): Fix
7023 fall-through comment.
7024 * s390-linux-tdep.c (s390_process_record): Fix fall-through
7026 * remote.c (remote_wait_as): Fix fall-through comment.
7027 * p-exp.y (yylex): Fix fall-through comment.
7028 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
7030 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
7031 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
7032 * jv-exp.y (yylex): Fix fall-through comment.
7033 * go-exp.y (lex_one_token): Fix fall-through comment.
7034 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
7035 fall-through comment.
7036 * f-exp.y (yylex): Fix fall-through comment.
7037 * dwarf2read.c (process_die): Fix fall-through comments.
7038 * dbxread.c (process_one_symbol): Fix fall-through comment.
7039 * d-exp.y (lex_one_token): Fix fall-through comment.
7040 * cp-name-parser.y (yylex): Fix fall-through comment.
7041 * coffread.c (coff_symtab_read): Fix fall-through comment.
7042 * c-exp.y (lex_one_token): Fix fall-through comment.
7043 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
7045 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
7048 2018-05-04 Tom Tromey <tom@tromey.com>
7051 * NEWS: Mention gdb.execute change.
7052 * gdbcmd.h (execute_control_command): Don't declare.
7053 * python/python.c (execute_gdb_command): Use read_command_lines_1,
7054 execute_control_commands, execute_control_commands_to_string.
7055 * cli/cli-script.h (execute_control_commands)
7056 (execute_control_commands_to_string): Declare.
7057 (execute_control_command): Add from_tty parameter.
7058 * cli/cli-script.c (execute_control_commands)
7059 (execute_control_commands_to_string): New functions.
7060 (execute_user_command): Use execute_control_commands.
7061 (execute_control_command_1): Add "from_tty" parameter. Update.
7062 (execute_control_command): Likewise.
7064 2018-05-04 Tom Tromey <tom@tromey.com>
7067 * NEWS: Mention that breakpoint commands are writable.
7068 * python/py-breakpoint.c (bppy_set_commands): New function.
7069 (breakpoint_object_getset) <"commands">: Use it.
7071 2018-05-04 Tom Tromey <tom@tromey.com>
7073 * tracepoint.c (actions_command): Update.
7074 * mi/mi-cmd-break.c (mi_command_line_array)
7075 (mi_command_line_array_cnt, mi_command_line_array_ptr)
7076 (mi_read_next_line): Remove.
7077 (mi_cmd_break_commands): Update.
7078 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
7080 * cli/cli-script.c (get_command_line): Update.
7081 (process_next_line): Use function_view. Constify.
7082 (recurse_read_control_structure, read_command_lines)
7083 (read_command_lines_1): Change argument types to function_view.
7084 (do_define_command, document_command): Update.
7085 * breakpoint.h (check_tracepoint_command): Don't declare.
7086 * breakpoint.c (check_tracepoint_command): Remove.
7087 (commands_command_1, create_tracepoint_from_upload): Update.
7089 2018-05-04 Tom Tromey <tom@tromey.com>
7092 * cli/cli-script.h (enum command_control_type) <define_control>:
7094 * cli/cli-script.c (multi_line_command_p): Handle define_control.
7095 (build_command_line, execute_control_command_1)
7096 (process_next_line): Likewise.
7097 (do_define_command): New function, extracted from define_command.
7098 (define_command): Use it.
7100 2018-05-04 Tom Tromey <tom@tromey.com>
7102 * tracepoint.c (actions_command): Update.
7103 * cli/cli-script.h (read_command_lines): Update.
7104 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
7105 (MAX_TMPBUF): Remove define.
7106 (define_command): Use string_printf.
7107 (document_command): Likewise.
7108 * breakpoint.c (commands_command_1): Update.
7110 2018-05-04 Tom Tromey <tom@tromey.com>
7112 * top.c (execute_command): Update.
7113 * cli/cli-script.h (print_command_lines): Now varargs.
7114 * cli/cli-script.c (print_command_lines): Now varargs.
7115 (execute_control_command_1) <case while_control, case if_control>:
7118 2018-05-04 Tom Tromey <tom@tromey.com>
7120 * tracepoint.c (all_tracepoint_actions): Rename from
7121 all_tracepoint_actions_and_cleanup. Change return type.
7122 (actions_command, encode_actions_1, encode_actions)
7123 (trace_dump_actions, tdump_command): Update.
7124 * remote.c (remote_download_command_source): Update.
7125 * python/python.c (gdbpy_eval_from_control_command)
7126 (python_command, python_interactive_command): Update.
7127 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
7128 * guile/guile.c (guile_command)
7129 (gdbscm_eval_from_control_command, guile_command): Update.
7130 * compile/compile.c (compile_code_command)
7131 (compile_print_command, compile_to_object): Update.
7132 * cli/cli-script.h (struct command_lines_deleter): New.
7133 (counted_command_line): New typedef.
7134 (struct command_line): Add constructor, destructor.
7135 <body_list>: Remove.
7136 <body_list_0, body_list_1>: New members.
7137 (command_line_up): Remove typedef.
7138 (read_command_lines, read_command_lines_1, get_command_line):
7140 (copy_command_lines): Don't declare.
7141 * cli/cli-script.c (build_command_line): Use "new".
7142 (get_command_line): Return counted_command_line.
7143 (print_command_lines, execute_user_command)
7144 (execute_control_command_1, while_command, if_command): Update.
7145 (realloc_body_list): Remove.
7146 (process_next_line, recurse_read_control_structure): Update.
7147 (read_command_lines, read_command_lines_1): Return counted_command_line.
7148 (free_command_lines): Use "delete".
7149 (copy_command_lines): Remove.
7150 (define_command, document_command, show_user_1): Update.
7151 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
7152 a counted_command_line.
7153 * breakpoint.h (counted_command_line): Remove typedef.
7154 (breakpoint_set_commands): Update.
7155 * breakpoint.c (check_no_tracepoint_commands)
7156 (validate_commands_for_breakpoint): Update.
7157 (breakpoint_set_commands): Change commands to be a
7158 counted_command_line.
7159 (commands_command_1, update_dprintf_command_list)
7160 (create_tracepoint_from_upload): Update.
7162 2018-05-04 Tom Tromey <tom@tromey.com>
7164 * cli/cli-decode.h (cmd_list_element): New constructor.
7165 (~cmd_list_element): New destructor.
7166 (struct cmd_list_element): Add initializers.
7167 * cli/cli-decode.c (do_add_cmd): Use "new".
7168 (delete_cmd): Use "delete".
7170 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
7171 Pedro Alves <palves@redhat.com>
7173 PR breakpoints/19806 and support for PR external/20207.
7174 * NEWS: Mention Aarch64 watchpoint improvements.
7175 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
7176 watchpoints and PR external/20207 watchpoints.
7177 * nat/aarch64-linux-hw-point.c
7178 (kernel_supports_any_contiguous_range): New.
7179 (aarch64_watchpoint_offset): New.
7180 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
7181 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
7182 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
7183 (aarch64_align_watchpoint): New parameters aligned_offset_p and
7184 next_addr_orig_p. Support PR external/20207 watchpoints.
7185 (aarch64_downgrade_regs): New.
7186 (aarch64_dr_state_insert_one_point): New parameters offset and
7188 (aarch64_dr_state_remove_one_point): Likewise.
7189 (aarch64_handle_breakpoint): Update caller.
7190 (aarch64_handle_aligned_watchpoint): Likewise.
7191 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
7193 (aarch64_linux_set_debug_regs): Remove const from state. Call
7194 aarch64_downgrade_regs.
7195 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
7196 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
7197 (DR_CONTROL_MASK): ... this.
7198 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
7199 (unsigned int aarch64_watchpoint_offset): New prototype.
7200 (aarch64_linux_set_debug_regs): Remove const from state.
7201 * utils.c (align_up, align_down): Move to ...
7202 * common/common-utils.c (align_up, align_down): ... here.
7203 * utils.h (align_up, align_down): Move to ...
7204 * common/common-utils.h (align_up, align_down): ... here.
7206 2018-05-04 Joel Brobecker <brobecker@adacore.com>
7208 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
7209 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
7210 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
7211 Re-implement to match the ABI as summarized in GCC's
7212 gcc/config/sparc/sparc.c. All callers updated.
7213 (sparc32_store_arguments): Remove assertion.
7215 2018-05-04 Tom Tromey <tom@tromey.com>
7217 * printcmd.c: Don't include tui.h.
7218 (decode_format): Use skip_spaces.
7220 2018-05-04 Tom Tromey <tom@tromey.com>
7223 * printcmd.c (last_count): New global.
7224 (x_command): Use saved count when repeating.
7226 2018-05-04 Tom Tromey <tom@tromey.com>
7228 * nto-procfs.c (do_closedir_cleanup): Remove.
7229 (procfs_pidlist): Use gdb_dir_up.
7230 * procfs.c (do_closedir_cleanup): Remove.
7231 (proc_update_threads): Use gdb_dir_up.
7232 * common/filestuff.h (struct gdb_dir_deleter): New.
7233 (gdb_dir_up): New typedef.
7235 2018-05-04 Tom Tromey <tom@tromey.com>
7237 * ada-lang.c (print_mention_exception): Use std::string.
7239 2018-05-04 Tom Tromey <tom@tromey.com>
7241 * ada-lang.c (create_excep_cond_exprs): Update.
7242 (ada_exception_catchpoint_cond_string): Use std::string.
7244 2018-05-04 Tom Tromey <tom@tromey.com>
7246 * ada-lang.c (xget_renaming_scope): Return std::string.
7247 (old_renaming_is_invisible): Update.
7249 2018-05-04 Tom Tromey <tom@tromey.com>
7251 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
7252 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
7254 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
7256 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
7258 2018-05-04 Tom Tromey <tom@tromey.com>
7260 * remote.c (remote_query_supported_append): Change type.
7261 (remote_check_symbols): Update.
7263 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
7266 * configure.ac: Prepend libpython.
7267 * python/python-config.py: Likewise.
7268 * configure: Regenerate.
7270 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
7272 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
7274 2018-05-03 Pedro Alves <palves@redhat.com>
7277 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
7278 override. Write 'true' instead of '1'.
7279 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
7282 2018-05-02 Pedro Alves <palves@redhat.com>
7284 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
7285 add_inf_child_target.
7286 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
7287 add_inf_child_target.
7288 * aix-thread.c (aix_thread_target_info): New.
7289 (aix_thread_target) <shortname, longname, doc>: Delete.
7291 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
7292 add_inf_child_target.
7293 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
7294 add_inf_child_target.
7295 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
7296 add_inf_child_target.
7297 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
7298 add_inf_child_target.
7299 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
7300 add_inf_child_target.
7301 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
7302 add_inf_child_target.
7303 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
7304 add_inf_child_target.
7305 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
7306 add_inf_child_target.
7307 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
7308 add_inf_child_target.
7309 * bfd-target.c (target_bfd_target_info): New.
7310 (target_bfd) <shortname, longname, doc>: Delete.
7312 * bsd-kvm.c (bsd_kvm_target_info): New.
7313 (bsd_kvm_target) <shortname, longname, doc>: Delete.
7315 (bsd_kvm_target::open): Rename to ...
7316 (bsd_kvm_target_open): ... this. Adjust.
7317 * bsd-uthread.c (bsd_uthread_target_info): New.
7318 (bsd_uthread_target) <shortname, longname, doc>: Delete.
7320 * corefile.c (core_file_command): Adjust.
7321 * corelow.c (core_target_info): New.
7322 (core_target) <shortname, longname, doc>: Delete.
7324 (core_target::open): Rename to ...
7325 (core_target_open): ... this. Adjust.
7326 * ctf.c (ctf_target_info): New.
7327 (ctf_target) <shortname, longname, doc>: Delete.
7329 (ctf_target::open): Rename to ...
7330 (ctf_target_open): ... this.
7331 (_initialize_ctf): Adjust.
7332 * exec.c (exec_target_info): New.
7333 (exec_target) <shortname, longname, doc>: Delete.
7335 (exec_target::open): Rename to ...
7336 (exec_target_open): ... this.
7337 * gdbcore.h (core_target_open): Declare.
7338 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
7339 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
7340 add_inf_child_target.
7341 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
7342 add_inf_child_target.
7343 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
7344 add_inf_child_target.
7345 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
7346 add_inf_child_target.
7347 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
7348 add_inf_child_target.
7349 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
7350 add_inf_child_target.
7351 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
7352 add_inf_child_target.
7353 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
7354 add_inf_child_target.
7355 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
7356 add_inf_child_target.
7357 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
7358 add_inf_child_target.
7359 * inf-child.c (inf_child_target_info): New.
7360 (inf_child_target::info): New.
7361 (inf_child_open_target): Remove 'target' parameter. Use
7362 get_native_target instead.
7363 (inf_child_target::open): Delete.
7364 (add_inf_child_target): New.
7365 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
7368 (add_inf_child_target): Declare.
7369 (inf_child_open_target): Declare.
7370 * linux-thread-db.c (thread_db_target_info): New.
7371 (thread_db_target) <shortname, longname, doc>: Delete.
7373 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
7374 add_inf_child_target.
7375 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
7376 add_inf_child_target.
7377 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
7378 add_inf_child_target.
7379 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
7380 add_inf_child_target.
7381 * make-target-delegates (print_class): Adjust.
7382 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
7383 add_inf_child_target.
7384 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
7385 add_inf_child_target.
7386 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
7387 add_inf_child_target.
7388 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
7389 add_inf_child_target.
7390 * nto-procfs.c (nto_native_target_info): New.
7391 (nto_procfs_target_native) <shortname, longname, doc>:
7394 (nto_procfs_target_info): New.
7395 (nto_procfs_target_procfs) <shortname, longname, doc>:
7398 (init_procfs_targets): Adjust.
7399 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
7400 add_inf_child_target.
7401 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
7402 add_inf_child_target.
7403 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
7404 add_inf_child_target.
7405 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
7406 add_inf_child_target.
7407 * ravenscar-thread.c (ravenscar_target_info): New.
7408 (ravenscar_thread_target) <shortname, longname, doc>:
7411 * record-btrace.c (record_btrace_target_info):
7412 (record_btrace_target) <shortname, longname, doc>: Delete.
7414 (record_btrace_target::open): Rename to ...
7415 (record_btrace_target_open): ... this. Adjust.
7416 * record-full.c (record_longname, record_doc): New.
7417 (record_full_base_target) <shortname, longname, doc>: Delete.
7419 (record_full_target_info): New.
7420 (record_full_target): <shortname>: Delete.
7422 (record_full_core_open_1, record_full_open_1): Update comments.
7423 (record_full_base_target::open): Rename to ...
7424 (record_full_open): ... this.
7425 (cmd_record_full_restore): Update.
7426 (_initialize_record_full): Update.
7427 * remote-sim.c (remote_sim_target_info): New.
7428 (gdbsim_target) <shortname, longname, doc>: Delete.
7430 (gdbsim_target::open): Rename to ...
7431 (gdbsim_target_open): ... this.
7432 (_initialize_remote_sim): Adjust.
7433 * remote.c (remote_doc): New.
7434 (remote_target_info): New.
7435 (remote_target) <shortname, longname, doc>: Delete.
7437 (extended_remote_target_info): New.
7438 (extended_remote_target) <shortname, longname, doc>: Delete.
7440 (remote_target::open_1): Make static. Adjust.
7441 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
7442 * s390-linux-nat.c (_initialize_s390_nat): Use
7443 add_inf_child_target.
7444 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
7445 add_inf_child_target.
7446 * sol-thread.c (thread_db_target_info): New.
7447 (sol_thread_target) <shortname, longname, doc>: Delete.
7449 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
7450 add_inf_child_target.
7451 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
7452 add_inf_child_target.
7453 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
7454 add_inf_child_target.
7455 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
7456 add_inf_child_target.
7457 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
7458 add_inf_child_target.
7459 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
7460 add_inf_child_target.
7461 * spu-linux-nat.c (_initialize_spu_nat): Use
7462 add_inf_child_target.
7463 * spu-multiarch.c (spu_multiarch_target_info): New.
7464 (spu_multiarch_target) <shortname, longname, doc>: Delete.
7466 * target-delegates.c: Regenerate.
7467 * target.c: Include <unordered_map>.
7468 (target_ops_p): Delete.
7469 (DEF_VEC_P(target_ops_p)): Delete.
7470 (target_factories): New.
7471 (test_target_info): New.
7472 (test_target_ops::info): New.
7473 (open_target): Adjust to use target_factories.
7474 (add_target_with_completer): Rename to ...
7475 (add_target): ... this. Change prototype. Register target_info
7476 and open callback in target_factories. Register target_info in
7477 command context instead of target_ops.
7478 (add_target): Delete old implementation.
7479 (add_deprecated_target_alias): Change prototype. Adjust.
7480 (the_native_target): New.
7481 (set_native_target, get_native_target): New.
7482 (find_default_run_target): Use the_native_target.
7483 (find_attach_target, find_run_target): Simplify.
7484 (target_ops::open): Delete.
7485 (dummy_target_info): New.
7486 (dummy_target::shortname, dummy_target::longname)
7487 (dummy_target::doc): Delete.
7488 (dummy_target::info): New.
7489 (debug_target::shortname, debug_target::longname)
7490 (debug_target::doc): Delete.
7491 (debug_target::info): New.
7492 * target.h (struct target_info): New.
7493 (target_ops::~target_ops): Add comment.
7494 (target_ops::info): New.
7495 (target_ops::shortname, target_ops::longname, target_ops::doc): No
7496 longer virtual. Implement in terms of target_info.
7497 (set_native_target, get_native_target): Declare.
7498 (target_open_ftype): New.
7499 (add_target, add_target_with_completer)
7500 (add_deprecated_target_alias): Change prototype.
7501 (test_target) <shortname, longname, doc>: Delete.
7503 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
7504 add_inf_child_target.
7505 * tracefile-tfile.c (tfile_target_info): New.
7506 (tfile_target) <shortname, longname, doc>: Delete.
7508 (tfile_target::open): Rename to ...
7509 (tfile_target_open): ... this.
7510 (_initialize_tracefile_tfile): Adjust.
7511 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
7512 add_inf_child_target.
7513 * windows-nat.c (_initialize_windows_nat): Use
7514 add_inf_child_target.
7515 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
7516 add_inf_child_target.
7518 2018-05-02 Pedro Alves <palves@redhat.com>
7520 * linux-nat.h (linux_nat_target) <low_new_thread,
7521 low_delete_thread, low_new_fork, low_forget_process,
7522 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
7523 New virtual methods.
7524 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7525 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
7526 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
7527 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7528 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
7530 * linux-fork.c (delete_fork): Adjust to call low method.
7531 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
7532 (linux_nat_new_fork, linux_nat_forget_process_hook)
7533 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
7534 (linux_nat_status_is_event):
7535 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
7536 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
7538 (sigtrap_is_event): Rename to ...
7539 (linux_nat_target::low_status_is_event): ... this.
7540 (linux_nat_set_status_is_event): Delete.
7541 (save_stop_reason, linux_nat_wait_1)
7542 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
7544 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7545 (linux_nat_set_new_fork, linux_nat_set_forget_process)
7546 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7547 (linux_nat_set_prepare_to_resume): Delete.
7548 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
7549 low virtual methods.
7550 * amd64-linux-nat.c: Likewise.
7551 * arm-linux-nat.c: Likewise.
7552 * i386-linux-nat.c: Likewise.
7553 * ia64-linux-nat.c: Likewise.
7554 * mips-linux-nat.c: Likewise.
7555 * ppc-linux-nat.c: Likewise.
7556 * s390-linux-nat.c: Likewise.
7557 * sparc64-linux-nat.c: Likewise.
7558 * x86-linux-nat.c: Likewise.
7559 * x86-linux-nat.h: Include "nat/x86-linux.h".
7560 (x86_linux_nat_target) <low_new_fork, low_forget_process,
7561 low_prepare_to_resume, low_new_thread, low_delete_thread>:
7564 2018-05-02 Pedro Alves <palves@redhat.com>
7566 * target.h (target_ops)
7567 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
7568 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
7569 stopped_by_watchpoint, have_continuable_watchpoint,
7570 stopped_data_address, watchpoint_addr_within_range,
7571 can_accel_watchpoint_condition, can_run, thread_alive,
7572 has_all_memory, has_memory, has_stack, has_registers,
7573 has_execution, can_async_p, is_async_p, supports_non_stop,
7574 always_non_stop_p, can_execute_reverse, supports_multi_process,
7575 supports_enable_disable_tracepoint,
7576 supports_disable_randomization, supports_string_tracing,
7577 supports_evaluation_of_breakpoint_conditions,
7578 can_run_breakpoint_commands, filesystem_is_local,
7579 can_download_tracepoint, get_trace_state_variable_value,
7580 set_trace_notes, get_tib_address, use_agent, can_use_agent,
7581 record_is_replaying, record_will_replay,
7582 augmented_libraries_svr4_read>: Adjust to return bool.
7583 * aarch64-linux-nat.c: All implementations adjusted.
7584 * aix-thread.c: All implementations adjusted.
7585 * arm-linux-nat.c: All implementations adjusted.
7586 * breakpoint.c: All implementations adjusted.
7587 * bsd-kvm.c: All implementations adjusted.
7588 * bsd-uthread.c: All implementations adjusted.
7589 * corelow.c: All implementations adjusted.
7590 * ctf.c: All implementations adjusted.
7591 * darwin-nat.c: All implementations adjusted.
7592 * darwin-nat.h: All implementations adjusted.
7593 * exec.c: All implementations adjusted.
7594 * fbsd-nat.c: All implementations adjusted.
7595 * fbsd-nat.h: All implementations adjusted.
7596 * gnu-nat.c: All implementations adjusted.
7597 * gnu-nat.h: All implementations adjusted.
7598 * go32-nat.c: All implementations adjusted.
7599 * ia64-linux-nat.c: All implementations adjusted.
7600 * inf-child.c: All implementations adjusted.
7601 * inf-child.h: All implementations adjusted.
7602 * inf-ptrace.c: All implementations adjusted.
7603 * inf-ptrace.h: All implementations adjusted.
7604 * linux-nat.c: All implementations adjusted.
7605 * linux-nat.h: All implementations adjusted.
7606 * mips-linux-nat.c: All implementations adjusted.
7607 * nto-procfs.c: All implementations adjusted.
7608 * ppc-linux-nat.c: All implementations adjusted.
7609 * procfs.c: All implementations adjusted.
7610 * ravenscar-thread.c: All implementations adjusted.
7611 * record-btrace.c: All implementations adjusted.
7612 * record-full.c: All implementations adjusted.
7613 * remote-sim.c: All implementations adjusted.
7614 * remote.c: All implementations adjusted.
7615 * s390-linux-nat.c: All implementations adjusted.
7616 * sol-thread.c: All implementations adjusted.
7617 * spu-multiarch.c: All implementations adjusted.
7618 * target-delegates.c: All implementations adjusted.
7619 * target.c: All implementations adjusted.
7620 * target.h: All implementations adjusted.
7621 * tracefile-tfile.c: All implementations adjusted.
7622 * tracefile.c: All implementations adjusted.
7623 * tracefile.h: All implementations adjusted.
7624 * windows-nat.c: All implementations adjusted.
7625 * x86-linux-nat.h: All implementations adjusted.
7626 * x86-nat.h: All implementations adjusted.
7628 2018-05-02 Pedro Alves <palves@redhat.com>
7630 * make-target-delegates (scan_target_h): Don't trim lines here.
7631 Replace sequences of tabs and/or whitespace with a single
7633 (top level, parsing methods): Trim each line before processing it
7636 2018-05-02 Pedro Alves <palves@redhat.com>
7637 John Baldwin <jhb@freebsd.org>
7639 * target.h (enum strata) <debug_stratum>: New.
7640 (struct target_ops) <all delegation methods>: Replace by C++
7641 virtual methods, and drop "to_" prefix. All references updated
7643 <to_shortname, to_longname, to_doc, to_data,
7644 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
7645 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
7646 virtual methods. All references updated throughout.
7647 <can_attach, supports_terminal_ours, can_create_inferior,
7648 get_thread_control_capabilities, attach_no_wait>: New
7650 <insert_breakpoint, remove_breakpoint>: Now
7651 TARGET_DEFAULT_NORETURN methods.
7652 <info_proc>: Now returns bool.
7654 (OPS_MAGIC): Delete.
7655 (current_target): Delete. All references replaced by references
7657 (target_stack): ... this. New.
7658 (target_shortname, target_longname): Adjust.
7659 (target_can_run): Now a function declaration.
7660 (default_child_has_all_memory, default_child_has_memory)
7661 (default_child_has_stack, default_child_has_registers)
7662 (default_child_has_execution): Remove target_ops parameter.
7663 (complete_target_initialization): Delete.
7664 (memory_breakpoint_target): New template class.
7665 (test_target_ops): Refactor as a C++ class with virtual methods.
7666 * make-target-delegates (NAME_PART): Tighten.
7667 (POINTER_PART, CP_SYMBOL): New.
7668 (SIMPLE_RETURN_PART): Reimplement.
7669 (VEC_RETURN_PART): Expect less.
7670 (RETURN_PART, VIRTUAL_PART): New.
7671 (METHOD): Adjust to C++ virtual methods.
7672 (scan_target_h): Remove reference to C99.
7673 (dname): Output "target_ops::" prefix.
7674 (write_function_header): Adjust to output a C++ class method.
7675 (write_declaration): New.
7676 (write_delegator): Adjust to output a C++ class method.
7677 (tdname): Output "dummy_target::" prefix.
7678 (write_tdefault, write_debugmethod): Adjust to output a C++ class
7680 (tdefault_names, debug_names): Delete.
7681 (return_types, tdefaults, styles, argtypes_array): New.
7682 (top level): All methods are delegators.
7684 (top level): Print dummy_target and debug_target classes.
7685 * target-delegates.c: Regenerate.
7686 * target-debug.h (target_debug_print_enum_info_proc_what)
7687 (target_debug_print_thread_control_capabilities)
7688 (target_debug_print_thread_info_p): New.
7689 * target.c (dummy_target): Delete.
7690 (the_dummy_target, the_debug_target): New.
7691 (target_stack): Now extern.
7692 (set_targetdebug): Push/unpush debug target.
7693 (default_child_has_all_memory, default_child_has_memory)
7694 (default_child_has_stack, default_child_has_registers)
7695 (default_child_has_execution): Remove target_ops parameter.
7696 (complete_target_initialization): Delete.
7697 (add_target_with_completer): No longer call
7698 complete_target_initialization.
7699 (target_supports_terminal_ours): Use regular delegation.
7700 (update_current_target): Delete.
7701 (push_target): No longer check magic number. Don't call
7702 update_current_target.
7703 (unpush_target): Don't call update_current_target.
7704 (target_is_pushed): No longer check magic number.
7705 (target_require_runnable): Skip for all stratums over
7707 (target_ops::info_proc): New.
7708 (target_info_proc): Use find_target_at and
7709 find_default_run_target.
7710 (target_supports_disable_randomization): Use regular delegation.
7711 (target_get_osdata): Use find_target_at.
7712 (target_ops::open, target_ops::close, target_ops::can_attach)
7713 (target_ops::attach, target_ops::can_create_inferior)
7714 (target_ops::create_inferior, target_ops::can_run)
7715 (target_can_run): New.
7716 (default_fileio_target): Use regular delegation.
7717 (target_ops::fileio_open, target_ops::fileio_pwrite)
7718 (target_ops::fileio_pread, target_ops::fileio_fstat)
7719 (target_ops::fileio_close, target_ops::fileio_unlink)
7720 (target_ops::fileio_readlink): New.
7721 (target_fileio_open_1, target_fileio_unlink)
7722 (target_fileio_readlink): Always call the target method. Handle
7724 (return_zero, return_zero_has_execution): Delete.
7725 (init_dummy_target): Delete.
7726 (dummy_target::dummy_target, dummy_target::shortname)
7727 (dummy_target::longname, dummy_target::doc)
7728 (debug_target::debug_target, debug_target::shortname)
7729 (debug_target::longname, debug_target::doc): New.
7730 (target_supports_delete_record): Use regular delegation.
7731 (setup_target_debug): Delete.
7732 (maintenance_print_target_stack): Skip debug_stratum.
7733 (initialize_targets): Instantiate the_dummy_target and
7735 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
7737 (target_auxv_search, fprint_target_auxv): Adjust.
7738 (info_auxv_command): Adjust to use target_stack.
7739 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
7740 * exceptions.c (print_flush): Handle a NULL target_stack.
7741 * regcache.c (target_ops_no_register): Refactor as class with
7744 * exec.c (exec_target): New class.
7745 (exec_ops): Now an exec_target.
7746 (exec_open, exec_close_1, exec_get_section_table)
7747 (exec_xfer_partial, exec_files_info, exec_has_memory)
7748 (exec_make_note_section): Refactor as exec_target methods.
7749 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
7751 (exec_target::find_memory_regions): New.
7752 (_initialize_exec): Don't call init_exec_ops.
7753 * gdbcore.h (exec_file_clear): Delete.
7755 * corefile.c (core_target): Delete.
7756 (core_file_command): Adjust.
7757 * corelow.c (core_target): New class.
7758 (the_core_target): New.
7759 (core_close): Remove target_ops parameter.
7760 (core_close_cleanup): Adjust.
7761 (core_target::close): New.
7762 (core_open, core_detach, get_core_registers, core_files_info)
7763 (core_xfer_partial, core_thread_alive, core_read_description)
7764 (core_pid_to_str, core_thread_name, core_has_memory)
7765 (core_has_stack, core_has_registers, core_info_proc): Rework as
7766 core_target methods.
7767 (ignore, core_remove_breakpoint, init_core_ops): Delete.
7768 (_initialize_corelow): Initialize the_core_target.
7769 * gdbcore.h (core_target): Delete.
7770 (the_core_target): New.
7772 * ctf.c: (ctf_target): New class.
7773 (ctf_ops): Now a ctf_target.
7774 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
7775 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
7776 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
7778 (init_ctf_ops): Delete.
7779 (_initialize_ctf): Don't call it.
7780 * tracefile-tfile.c (tfile_target): New class.
7781 (tfile_ops): Now a tfile_target.
7782 (tfile_open, tfile_close, tfile_files_info)
7783 (tfile_get_tracepoint_status, tfile_trace_find)
7784 (tfile_fetch_registers, tfile_xfer_partial)
7785 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
7786 Refactor as tfile_target methods.
7787 (tfile_xfer_partial_features): Remove target_ops parameter.
7788 (init_tfile_ops): Delete.
7789 (_initialize_tracefile_tfile): Don't call it.
7790 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
7791 (tracefile_has_stack, tracefile_has_registers)
7792 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
7793 tracefile_target methods.
7794 (init_tracefile_ops): Delete.
7795 (tracefile_target::tracefile_target): New.
7796 * tracefile.h: Include "target.h".
7797 (tracefile_target): New class.
7798 (init_tracefile_ops): Delete.
7800 * spu-multiarch.c (spu_multiarch_target): New class.
7801 (spu_ops): Now a spu_multiarch_target.
7802 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
7803 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
7804 (spu_search_memory, spu_mourn_inferior): Refactor as
7805 spu_multiarch_target methods.
7806 (init_spu_ops): Delete.
7807 (_initialize_spu_multiarch): Remove references to init_spu_ops,
7808 complete_target_initialization.
7810 * ravenscar-thread.c (ravenscar_thread_target): New class.
7811 (ravenscar_ops): Now a ravenscar_thread_target.
7812 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
7813 (ravenscar_thread_alive, ravenscar_pid_to_str)
7814 (ravenscar_fetch_registers, ravenscar_store_registers)
7815 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
7816 (ravenscar_stopped_by_hw_breakpoint)
7817 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
7818 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
7819 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
7821 (init_ravenscar_thread_ops): Delete.
7822 (_initialize_ravenscar): Remove references to
7823 init_ravenscar_thread_ops and complete_target_initialization.
7825 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
7826 (bsd_uthread_target): New class.
7827 (bsd_uthread_ops): Now a bsd_uthread_target.
7828 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
7829 (bsd_uthread_close, bsd_uthread_mourn_inferior)
7830 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
7831 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
7832 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
7833 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
7834 (bsd_uthread_target): Delete function.
7835 (_initialize_bsd_uthread): Remove reference to
7836 complete_target_initialization.
7838 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
7839 (target_bfd): ... this new class.
7840 (target_bfd_xfer_partial, target_bfd_get_section_table)
7841 (target_bfd_close): Refactor as target_bfd methods.
7842 (target_bfd::~target_bfd): New.
7843 (target_bfd_reopen): Adjust.
7844 (target_bfd::close): New.
7846 * record-btrace.c (record_btrace_target): New class.
7847 (record_btrace_ops): Now a record_btrace_target.
7848 (record_btrace_open, record_btrace_stop_recording)
7849 (record_btrace_disconnect, record_btrace_close)
7850 (record_btrace_async, record_btrace_info)
7851 (record_btrace_insn_history, record_btrace_insn_history_range)
7852 (record_btrace_insn_history_from, record_btrace_call_history)
7853 (record_btrace_call_history_range)
7854 (record_btrace_call_history_from, record_btrace_record_method)
7855 (record_btrace_is_replaying, record_btrace_will_replay)
7856 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
7857 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
7858 (record_btrace_store_registers, record_btrace_prepare_to_store)
7859 (record_btrace_to_get_unwinder)
7860 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
7861 (record_btrace_commit_resume, record_btrace_wait)
7862 (record_btrace_stop, record_btrace_can_execute_reverse)
7863 (record_btrace_stopped_by_sw_breakpoint)
7864 (record_btrace_supports_stopped_by_sw_breakpoint)
7865 (record_btrace_stopped_by_hw_breakpoint)
7866 (record_btrace_supports_stopped_by_hw_breakpoint)
7867 (record_btrace_update_thread_list, record_btrace_thread_alive)
7868 (record_btrace_goto_begin, record_btrace_goto_end)
7869 (record_btrace_goto, record_btrace_stop_replaying_all)
7870 (record_btrace_execution_direction)
7871 (record_btrace_prepare_to_generate_core)
7872 (record_btrace_done_generating_core): Refactor as
7873 record_btrace_target methods.
7874 (init_record_btrace_ops): Delete.
7875 (_initialize_record_btrace): Remove reference to
7876 init_record_btrace_ops.
7877 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
7878 the execution_direction global.
7879 (record_full_base_target, record_full_target)
7880 (record_full_core_target): New classes.
7881 (record_full_ops): Now a record_full_target.
7882 (record_full_core_ops): Now a record_full_core_target.
7883 (record_full_target::detach, record_full_target::disconnect)
7884 (record_full_core_target::disconnect)
7885 (record_full_target::mourn_inferior, record_full_target::kill):
7887 (record_full_open, record_full_close, record_full_async): Refactor
7888 as methods of the record_full_base_target class.
7889 (record_full_resume, record_full_commit_resume): Refactor
7890 as methods of the record_full_target class.
7891 (record_full_wait, record_full_stopped_by_watchpoint)
7892 (record_full_stopped_data_address)
7893 (record_full_stopped_by_sw_breakpoint)
7894 (record_full_supports_stopped_by_sw_breakpoint)
7895 (record_full_stopped_by_hw_breakpoint)
7896 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
7897 methods of the record_full_base_target class.
7898 (record_full_store_registers, record_full_xfer_partial)
7899 (record_full_insert_breakpoint, record_full_remove_breakpoint):
7900 Refactor as methods of the record_full_target class.
7901 (record_full_can_execute_reverse, record_full_get_bookmark)
7902 (record_full_goto_bookmark, record_full_execution_direction)
7903 (record_full_record_method, record_full_info, record_full_delete)
7904 (record_full_is_replaying, record_full_will_replay)
7905 (record_full_goto_begin, record_full_goto_end, record_full_goto)
7906 (record_full_stop_replaying): Refactor as methods of the
7907 record_full_base_target class.
7908 (record_full_core_resume, record_full_core_kill)
7909 (record_full_core_fetch_registers)
7910 (record_full_core_prepare_to_store)
7911 (record_full_core_store_registers, record_full_core_xfer_partial)
7912 (record_full_core_insert_breakpoint)
7913 (record_full_core_remove_breakpoint)
7914 (record_full_core_has_execution): Refactor
7915 as methods of the record_full_core_target class.
7916 (record_full_base_target::supports_delete_record): New.
7917 (init_record_full_ops): Delete.
7918 (init_record_full_core_ops): Delete.
7919 (record_full_save): Refactor as method of the
7920 record_full_base_target class.
7921 (_initialize_record_full): Remove references to
7922 init_record_full_ops and init_record_full_core_ops.
7924 * remote.c (remote_target, extended_remote_target): New classes.
7925 (remote_ops): Now a remote_target.
7926 (extended_remote_ops): Now an extended_remote_target.
7927 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
7928 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
7929 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
7930 (remote_pass_signals, remote_set_syscall_catchpoint)
7931 (remote_program_signals, )
7932 (remote_thread_always_alive): Remove target_ops parameter.
7933 (remote_thread_alive, remote_thread_name)
7934 (remote_update_thread_list, remote_threads_extra_info)
7935 (remote_static_tracepoint_marker_at)
7936 (remote_static_tracepoint_markers_by_strid)
7937 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
7938 (remote_open): Refactor as methods of remote_target.
7939 (extended_remote_open, extended_remote_detach)
7940 (extended_remote_attach, extended_remote_post_attach):
7941 (extended_remote_supports_disable_randomization)
7942 (extended_remote_create_inferior): : Refactor as method of
7943 extended_remote_target.
7944 (remote_set_permissions, remote_open_1, remote_detach)
7945 (remote_follow_fork, remote_follow_exec, remote_disconnect)
7946 (remote_resume, remote_commit_resume, remote_stop)
7947 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
7948 (remote_terminal_ours, remote_wait, remote_fetch_registers)
7949 (remote_prepare_to_store, remote_store_registers)
7950 (remote_flash_erase, remote_flash_done, remote_files_info)
7951 (remote_kill, remote_mourn, remote_insert_breakpoint)
7952 (remote_remove_breakpoint, remote_insert_watchpoint)
7953 (remote_watchpoint_addr_within_range)
7954 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
7955 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
7956 (remote_supports_stopped_by_sw_breakpoint)
7957 (remote_stopped_by_hw_breakpoint)
7958 (remote_supports_stopped_by_hw_breakpoint)
7959 (remote_stopped_by_watchpoint, remote_stopped_data_address)
7960 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
7961 (remote_verify_memory): Refactor as methods of remote_target.
7962 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
7964 (remote_xfer_partial, remote_get_memory_xfer_limit)
7965 (remote_search_memory, remote_rcmd, remote_memory_map)
7966 (remote_pid_to_str, remote_get_thread_local_address)
7967 (remote_get_tib_address, remote_read_description): Refactor as
7968 methods of remote_target.
7969 (remote_target::fileio_open, remote_target::fileio_pwrite)
7970 (remote_target::fileio_pread, remote_target::fileio_close): New.
7971 (remote_hostio_readlink, remote_hostio_fstat)
7972 (remote_filesystem_is_local, remote_can_execute_reverse)
7973 (remote_supports_non_stop, remote_supports_disable_randomization)
7974 (remote_supports_multi_process, remote_supports_cond_breakpoints)
7975 (remote_supports_enable_disable_tracepoint)
7976 (remote_supports_string_tracing)
7977 (remote_can_run_breakpoint_commands, remote_trace_init)
7978 (remote_download_tracepoint, remote_can_download_tracepoint)
7979 (remote_download_trace_state_variable, remote_enable_tracepoint)
7980 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
7981 (remote_trace_start, remote_get_trace_status)
7982 (remote_get_tracepoint_status, remote_trace_stop)
7983 (remote_trace_find, remote_get_trace_state_variable_value)
7984 (remote_save_trace_data, remote_get_raw_trace_data)
7985 (remote_set_disconnected_tracing, remote_core_of_thread)
7986 (remote_set_circular_trace_buffer, remote_traceframe_info)
7987 (remote_get_min_fast_tracepoint_insn_len)
7988 (remote_set_trace_buffer_size, remote_set_trace_notes)
7989 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
7990 (remote_disable_btrace, remote_teardown_btrace)
7991 (remote_read_btrace, remote_btrace_conf)
7992 (remote_augmented_libraries_svr4_read, remote_load)
7993 (remote_pid_to_exec_file, remote_can_do_single_step)
7994 (remote_execution_direction, remote_thread_handle_to_thread_info):
7995 Refactor as methods of remote_target.
7996 (init_remote_ops, init_extended_remote_ops): Delete.
7997 (remote_can_async_p, remote_is_async_p, remote_async)
7998 (remote_thread_events, remote_upload_tracepoints)
7999 (remote_upload_trace_state_variables): Refactor as methods of
8001 (_initialize_remote): Remove references to init_remote_ops and
8002 init_extended_remote_ops.
8004 * remote-sim.c (gdbsim_target): New class.
8005 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
8006 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
8007 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
8008 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
8009 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
8010 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
8011 Refactor as methods of gdbsim_target.
8012 (gdbsim_ops): Now a gdbsim_target.
8013 (init_gdbsim_ops): Delete.
8014 (gdbsim_cntrl_c): Adjust.
8015 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
8017 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
8018 (the_amd64_linux_nat_target): New.
8019 (amd64_linux_fetch_inferior_registers)
8020 (amd64_linux_store_inferior_registers): Refactor as methods of
8021 amd64_linux_nat_target.
8022 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
8023 * i386-linux-nat.c: Don't include "linux-nat.h".
8024 (i386_linux_nat_target): New class.
8025 (the_i386_linux_nat_target): New.
8026 (i386_linux_fetch_inferior_registers)
8027 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
8028 as methods of i386_linux_nat_target.
8029 (_initialize_i386_linux_nat): Adjust. Set linux_target.
8030 * inf-child.c (inf_child_ops): Delete.
8031 (inf_child_fetch_inferior_registers)
8032 (inf_child_store_inferior_registers): Delete.
8033 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
8034 methods of inf_child_target.
8035 (inf_child_target::supports_terminal_ours)
8036 (inf_child_target::terminal_init)
8037 (inf_child_target::terminal_inferior)
8038 (inf_child_target::terminal_ours_for_output)
8039 (inf_child_target::terminal_ours, inf_child_target::interrupt)
8040 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
8042 (inf_child_open, inf_child_disconnect, inf_child_close)
8043 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
8044 (inf_child_post_startup_inferior, inf_child_can_run)
8045 (inf_child_pid_to_exec_file): Refactor as methods of
8047 (inf_child_follow_fork): Delete.
8048 (inf_child_target::can_create_inferior)
8049 (inf_child_target::can_attach): New.
8050 (inf_child_target::has_all_memory, inf_child_target::has_memory)
8051 (inf_child_target::has_stack, inf_child_target::has_registers)
8052 (inf_child_target::has_execution): New.
8053 (inf_child_fileio_open, inf_child_fileio_pwrite)
8054 (inf_child_fileio_pread, inf_child_fileio_fstat)
8055 (inf_child_fileio_close, inf_child_fileio_unlink)
8056 (inf_child_fileio_readlink, inf_child_use_agent)
8057 (inf_child_can_use_agent): Refactor as methods of
8059 (return_zero, inf_child_target): Delete.
8060 (inf_child_target::inf_child_target): New.
8061 * inf-child.h: Include "target.h".
8062 (inf_child_target): Delete function prototype.
8063 (inf_child_target): New class.
8064 (inf_child_open_target, inf_child_mourn_inferior)
8065 (inf_child_maybe_unpush_target): Delete.
8066 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
8067 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
8068 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
8069 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
8070 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
8071 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
8072 (inf_ptrace_wait, inf_ptrace_xfer_partial)
8073 (inf_ptrace_thread_alive, inf_ptrace_files_info)
8074 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
8075 methods of inf_ptrace_target.
8076 (inf_ptrace_target): Delete function.
8077 * inf-ptrace.h: Include "inf-child.h".
8078 (inf_ptrace_target): Delete function declaration.
8079 (inf_ptrace_target): New class.
8080 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
8081 * linux-nat.c (linux_target): New.
8082 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
8083 (linux_nat_target::~linux_nat_target): New.
8084 (linux_child_post_attach, linux_child_post_startup_inferior)
8085 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
8086 (linux_child_remove_fork_catchpoint)
8087 (linux_child_insert_vfork_catchpoint)
8088 (linux_child_remove_vfork_catchpoint)
8089 (linux_child_insert_exec_catchpoint)
8090 (linux_child_remove_exec_catchpoint)
8091 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
8092 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
8093 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
8094 (linux_nat_stopped_data_address)
8095 (linux_nat_stopped_by_sw_breakpoint)
8096 (linux_nat_supports_stopped_by_sw_breakpoint)
8097 (linux_nat_stopped_by_hw_breakpoint)
8098 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
8099 (linux_nat_kill, linux_nat_mourn_inferior)
8100 (linux_nat_xfer_partial, linux_nat_thread_alive)
8101 (linux_nat_update_thread_list, linux_nat_pid_to_str)
8102 (linux_nat_thread_name, linux_child_pid_to_exec_file)
8103 (linux_child_static_tracepoint_markers_by_strid)
8104 (linux_nat_is_async_p, linux_nat_can_async_p)
8105 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
8106 (linux_nat_supports_multi_process)
8107 (linux_nat_supports_disable_randomization, linux_nat_async)
8108 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
8109 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
8110 (linux_nat_fileio_open, linux_nat_fileio_readlink)
8111 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
8112 methods of linux_nat_target.
8113 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
8114 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
8116 (check_stopped_by_watchpoint): Adjust.
8117 (linux_xfer_partial): Delete.
8118 (linux_target_install_ops, linux_target, linux_nat_add_target):
8120 (linux_nat_target::linux_nat_target): New.
8121 * linux-nat.h: Include "inf-ptrace.h".
8122 (linux_nat_target): New.
8123 (linux_target, linux_target_install_ops, linux_nat_add_target):
8124 Delete function declarations.
8125 (linux_target): Declare global.
8126 * linux-thread-db.c (thread_db_target): New.
8127 (thread_db_target::thread_db_target): New.
8128 (thread_db_ops): Delete.
8129 (the_thread_db_target): New.
8130 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
8131 (thread_db_update_thread_list, thread_db_pid_to_str)
8132 (thread_db_extra_thread_info)
8133 (thread_db_thread_handle_to_thread_info)
8134 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
8135 (thread_db_resume): Refactor as methods of thread_db_target.
8136 (init_thread_db_ops): Delete.
8137 (_initialize_thread_db): Remove reference to init_thread_db_ops.
8138 * x86-linux-nat.c: Don't include "linux-nat.h".
8139 (super_post_startup_inferior): Delete.
8140 (x86_linux_nat_target::~x86_linux_nat_target): New.
8141 (x86_linux_child_post_startup_inferior)
8142 (x86_linux_read_description, x86_linux_enable_btrace)
8143 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
8144 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
8145 methods of x86_linux_nat_target.
8146 (x86_linux_create_target): Delete. Bits folded ...
8147 (x86_linux_add_target): ... here. Now takes a linux_nat_target
8149 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
8150 (x86_linux_nat_target): New class.
8151 (x86_linux_create_target): Delete.
8152 (x86_linux_add_target): Now takes a linux_nat_target pointer.
8153 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
8154 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
8155 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
8156 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
8157 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
8159 (x86_use_watchpoints): Delete.
8160 * x86-nat.h: Include "breakpoint.h" and "target.h".
8161 (x86_use_watchpoints): Delete.
8162 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
8163 (x86_stopped_by_watchpoint, x86_stopped_data_address)
8164 (x86_insert_watchpoint, x86_remove_watchpoint)
8165 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
8166 (x86_stopped_by_hw_breakpoint): New declarations.
8167 (x86_nat_target): New template class.
8169 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
8170 (the_ppc_linux_nat_target): New.
8171 (ppc_linux_fetch_inferior_registers)
8172 (ppc_linux_can_use_hw_breakpoint)
8173 (ppc_linux_region_ok_for_hw_watchpoint)
8174 (ppc_linux_ranged_break_num_registers)
8175 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
8176 (ppc_linux_insert_mask_watchpoint)
8177 (ppc_linux_remove_mask_watchpoint)
8178 (ppc_linux_can_accel_watchpoint_condition)
8179 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
8180 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
8181 (ppc_linux_watchpoint_addr_within_range)
8182 (ppc_linux_masked_watch_num_registers)
8183 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
8184 (ppc_linux_read_description): Refactor as methods of
8185 ppc_linux_nat_target.
8186 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
8188 * procfs.c (procfs_xfer_partial): Delete forward declaration.
8189 (procfs_target): New class.
8190 (the_procfs_target): New.
8191 (procfs_target): Delete function.
8192 (procfs_auxv_parse, procfs_attach, procfs_detach)
8193 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
8194 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
8195 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
8196 (procfs_create_inferior, procfs_update_thread_list)
8197 (procfs_thread_alive, procfs_pid_to_str)
8198 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
8199 (procfs_stopped_data_address, procfs_insert_watchpoint)
8200 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
8201 (proc_find_memory_regions, procfs_info_proc)
8202 (procfs_make_note_section): Refactor as methods of procfs_target.
8203 (_initialize_procfs): Adjust.
8204 * sol-thread.c (sol_thread_target): New class.
8205 (sol_thread_ops): Now a sol_thread_target.
8206 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
8207 (sol_thread_fetch_registers, sol_thread_store_registers)
8208 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
8209 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
8210 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
8211 (init_sol_thread_ops): Delete.
8212 (_initialize_sol_thread): Adjust. Remove references to
8213 init_sol_thread_ops and complete_target_initialization.
8215 * windows-nat.c (windows_nat_target): New class.
8216 (windows_fetch_inferior_registers)
8217 (windows_store_inferior_registers, windows_resume, windows_wait)
8218 (windows_attach, windows_detach, windows_pid_to_exec_file)
8219 (windows_files_info, windows_create_inferior)
8220 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
8221 (windows_close, windows_pid_to_str, windows_xfer_partial)
8222 (windows_get_tib_address, windows_get_ada_task_ptid)
8223 (windows_thread_name, windows_thread_alive): Refactor as
8224 windows_nat_target methods.
8225 (do_initial_windows_stuff): Adjust.
8226 (windows_target): Delete function.
8227 (_initialize_windows_nat): Adjust.
8229 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
8230 (darwin_mourn_inferior, darwin_kill_inferior)
8231 (darwin_create_inferior, darwin_attach, darwin_detach)
8232 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
8233 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
8234 (darwin_supports_multi_process): Refactor as darwin_nat_target
8236 (darwin_resume_to, darwin_files_info): Delete.
8237 (_initialize_darwin_inferior): Rename to ...
8238 (_initialize_darwin_nat): ... this. Adjust to C++ification.
8239 * darwin-nat.h: Include "inf-child.h".
8240 (darwin_nat_target): New class.
8241 (darwin_complete_target): Delete.
8242 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
8243 (darwin_target): New.
8244 (i386_darwin_fetch_inferior_registers)
8245 (i386_darwin_store_inferior_registers): Refactor as methods of
8247 (darwin_complete_target): Delete, with ...
8248 (_initialize_i386_darwin_nat): ... bits factored out here.
8250 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
8251 (the_alpha_linux_nat_target): New.
8252 (alpha_linux_register_u_offset): Refactor as
8253 alpha_linux_nat_target method.
8254 (_initialize_alpha_linux_nat): Adjust.
8255 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
8256 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8257 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
8258 methods of linux_nat_trad_target.
8259 (linux_trad_target): Delete.
8260 * linux-nat-trad.h (linux_trad_target): Delete function.
8261 (linux_nat_trad_target): New class.
8262 * mips-linux-nat.c (mips_linux_nat_target): New class.
8263 (super_fetch_registers, super_store_registers, super_close):
8265 (the_mips_linux_nat_target): New.
8266 (mips64_linux_regsets_fetch_registers)
8267 (mips64_linux_regsets_store_registers)
8268 (mips64_linux_fetch_registers, mips64_linux_store_registers)
8269 (mips_linux_register_u_offset, mips_linux_read_description)
8270 (mips_linux_can_use_hw_breakpoint)
8271 (mips_linux_stopped_by_watchpoint)
8272 (mips_linux_stopped_data_address)
8273 (mips_linux_region_ok_for_hw_watchpoint)
8274 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
8275 (mips_linux_close): Refactor as methods of mips_linux_nat.
8276 (_initialize_mips_linux_nat): Adjust to C++ification.
8278 * aix-thread.c (aix_thread_target): New class.
8279 (aix_thread_ops): Now an aix_thread_target.
8280 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
8281 (aix_thread_fetch_registers, aix_thread_store_registers)
8282 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
8283 (aix_thread_thread_alive, aix_thread_pid_to_str)
8284 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
8285 Refactor as methods of aix_thread_target.
8286 (init_aix_thread_ops): Delete.
8287 (_initialize_aix_thread): Remove references to init_aix_thread_ops
8288 and complete_target_initialization.
8289 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
8290 (rs6000_nat_target): New class.
8291 (the_rs6000_nat_target): New.
8292 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
8293 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
8294 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
8295 (super_create_inferior): Delete.
8296 (_initialize_rs6000_nat): Adjust to C++ification.
8298 * arm-linux-nat.c (arm_linux_nat_target): New class.
8299 (the_arm_linux_nat_target): New.
8300 (arm_linux_fetch_inferior_registers)
8301 (arm_linux_store_inferior_registers, arm_linux_read_description)
8302 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
8303 (arm_linux_remove_hw_breakpoint)
8304 (arm_linux_region_ok_for_hw_watchpoint)
8305 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
8306 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
8307 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
8308 arm_linux_nat_target.
8309 (_initialize_arm_linux_nat): Adjust to C++ification.
8311 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
8312 (the_aarch64_linux_nat_target): New.
8313 (aarch64_linux_fetch_inferior_registers)
8314 (aarch64_linux_store_inferior_registers)
8315 (aarch64_linux_child_post_startup_inferior)
8316 (aarch64_linux_read_description)
8317 (aarch64_linux_can_use_hw_breakpoint)
8318 (aarch64_linux_insert_hw_breakpoint)
8319 (aarch64_linux_remove_hw_breakpoint)
8320 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
8321 (aarch64_linux_region_ok_for_hw_watchpoint)
8322 (aarch64_linux_stopped_data_address)
8323 (aarch64_linux_stopped_by_watchpoint)
8324 (aarch64_linux_watchpoint_addr_within_range)
8325 (aarch64_linux_can_do_single_step): Refactor as methods of
8326 aarch64_linux_nat_target.
8327 (super_post_startup_inferior): Delete.
8328 (_initialize_aarch64_linux_nat): Adjust to C++ification.
8330 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
8331 (the_hppa_linux_nat_target): New.
8332 (hppa_linux_fetch_inferior_registers)
8333 (hppa_linux_store_inferior_registers): Refactor as methods of
8334 hppa_linux_nat_target.
8335 (_initialize_hppa_linux_nat): Adjust to C++ification.
8337 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
8338 (the_ia64_linux_nat_target): New.
8339 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
8340 (ia64_linux_stopped_data_address)
8341 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
8342 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
8343 ia64_linux_nat_target methods.
8344 (super_xfer_partial): Delete.
8345 (_initialize_ia64_linux_nat): Adjust to C++ification.
8347 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
8348 (the_m32r_linux_nat_target): New.
8349 (m32r_linux_fetch_inferior_registers)
8350 (m32r_linux_store_inferior_registers): Refactor as
8351 m32r_linux_nat_target methods.
8352 (_initialize_m32r_linux_nat): Adjust to C++ification.
8354 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
8355 (the_m68k_linux_nat_target): New.
8356 (m68k_linux_fetch_inferior_registers)
8357 (m68k_linux_store_inferior_registers): Refactor as
8358 m68k_linux_nat_target methods.
8359 (_initialize_m68k_linux_nat): Adjust to C++ification.
8361 * s390-linux-nat.c (s390_linux_nat_target): New class.
8362 (the_s390_linux_nat_target): New.
8363 (s390_linux_fetch_inferior_registers)
8364 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
8365 (s390_insert_watchpoint, s390_remove_watchpoint)
8366 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
8367 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
8368 (s390_auxv_parse, s390_read_description): Refactor as methods of
8369 s390_linux_nat_target.
8370 (_initialize_s390_nat): Adjust to C++ification.
8372 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
8373 (the_sparc_linux_nat_target): New.
8374 (_initialize_sparc_linux_nat): Adjust to C++ification.
8375 * sparc-nat.c (sparc_fetch_inferior_registers)
8376 (sparc_store_inferior_registers): Remove target_ops parameter.
8377 * sparc-nat.h (sparc_fetch_inferior_registers)
8378 (sparc_store_inferior_registers): Remove target_ops parameter.
8379 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
8380 (the_sparc64_linux_nat_target): New.
8381 (_initialize_sparc64_linux_nat): Adjust to C++ification.
8383 * spu-linux-nat.c (spu_linux_nat_target): New class.
8384 (the_spu_linux_nat_target): New.
8385 (spu_child_post_startup_inferior, spu_child_post_attach)
8386 (spu_child_wait, spu_fetch_inferior_registers)
8387 (spu_store_inferior_registers, spu_xfer_partial)
8388 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
8390 (_initialize_spu_nat): Adjust to C++ification.
8392 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
8393 (the_tilegx_linux_nat_target): New.
8394 (fetch_inferior_registers, store_inferior_registers):
8395 Refactor as methods.
8396 (_initialize_tile_linux_nat): Adjust to C++ification.
8398 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
8399 (the_xtensa_linux_nat_target): New.
8400 (xtensa_linux_fetch_inferior_registers)
8401 (xtensa_linux_store_inferior_registers): Refactor as
8402 xtensa_linux_nat_target methods.
8403 (_initialize_xtensa_linux_nat): Adjust to C++ification.
8405 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
8406 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
8407 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
8408 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
8409 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
8410 (fbsd_stopped_by_sw_breakpoint)
8411 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
8412 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
8413 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
8414 (fbsd_post_startup_inferior, fbsd_post_attach)
8415 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
8416 (fbsd_set_syscall_catchpoint)
8417 (super_xfer_partial, super_resume, super_wait)
8418 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
8419 (fbsd_handle_debug_trap): Remove target_ops parameter.
8420 (fbsd_nat_add_target): Delete.
8421 * fbsd-nat.h: Include "inf-ptrace.h".
8422 (fbsd_nat_add_target): Delete.
8423 (USE_SIGTRAP_SIGINFO): Define.
8424 (fbsd_nat_target): New class.
8426 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
8427 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
8428 (amd64bsd_target): Delete.
8429 * amd64-bsd-nat.h: New file.
8430 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
8432 (amd64_fbsd_nat_target): New class.
8433 (the_amd64_fbsd_nat_target): New.
8434 (amd64fbsd_read_description): Refactor as method of
8435 amd64_fbsd_nat_target.
8436 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8437 (_initialize_amd64fbsd_nat): Adjust to C++ification.
8438 * amd64-nat.h (amd64bsd_target): Delete function declaration.
8439 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
8440 (i386bsd_store_inferior_registers): Remove target_ops parameter.
8441 (i386bsd_target): Delete.
8442 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
8443 (i386bsd_fetch_inferior_registers)
8444 (i386bsd_store_inferior_registers): Declare.
8445 (i386_bsd_nat_target): New class.
8446 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
8447 (the_i386_fbsd_nat_target): New.
8448 (i386fbsd_resume, i386fbsd_read_description): Refactor as
8449 i386_fbsd_nat_target methods.
8450 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8451 (_initialize_i386fbsd_nat): Adjust to C++ification.
8452 * x86-bsd-nat.c (super_mourn_inferior): Delete.
8453 (x86bsd_mourn_inferior, x86bsd_target): Delete.
8454 (_initialize_x86_bsd_nat): Adjust to C++ification.
8455 * x86-bsd-nat.h: Include "x86-nat.h".
8456 (x86bsd_target): Delete declaration.
8457 (x86bsd_nat_target): New class.
8459 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
8460 (the_aarch64_fbsd_nat_target): New.
8461 (aarch64_fbsd_fetch_inferior_registers)
8462 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
8463 aarch64_fbsd_nat_target.
8464 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
8465 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
8466 (the_alpha_bsd_nat_target): New.
8467 (alphabsd_fetch_inferior_registers)
8468 (alphabsd_store_inferior_registers): Refactor as
8469 alpha_bsd_nat_target methods.
8470 (_initialize_alphabsd_nat): Refactor as methods of
8471 alpha_bsd_nat_target.
8472 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
8473 (the_amd64_nbsd_nat_target): New.
8474 (_initialize_amd64nbsd_nat): Adjust to C++ification.
8475 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
8476 (the_amd64_obsd_nat_target): New.
8477 (_initialize_amd64obsd_nat): Adjust to C++ification.
8478 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
8479 (the_arm_fbsd_nat_target): New.
8480 (arm_fbsd_fetch_inferior_registers)
8481 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
8482 (_initialize_arm_fbsd_nat): Refactor as methods of
8483 arm_fbsd_nat_target.
8484 (_initialize_arm_fbsd_nat): Adjust to C++ification.
8485 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
8486 (the_arm_netbsd_nat_target): New.
8487 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
8488 arm_netbsd_nat_target.
8489 (_initialize_arm_netbsd_nat): Adjust to C++ification.
8490 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
8491 (the_hppa_nbsd_nat_target): New.
8492 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
8493 hppa_nbsd_nat_target methods.
8494 (_initialize_hppanbsd_nat): Adjust to C++ification.
8495 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
8496 (the_hppa_obsd_nat_target): New.
8497 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
8498 methods of hppa_obsd_nat_target.
8499 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
8501 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
8502 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
8504 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
8505 (_initialize_i386obsd_nat): Use add_target.
8506 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
8507 (the_m68k_bsd_nat_target): New.
8508 (m68kbsd_fetch_inferior_registers)
8509 (m68kbsd_store_inferior_registers): Refactor as methods of
8510 m68k_bsd_nat_target.
8511 (_initialize_m68kbsd_nat): Adjust to C++ification.
8512 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
8513 (the_mips_fbsd_nat_target): New.
8514 (mips_fbsd_fetch_inferior_registers)
8515 (mips_fbsd_store_inferior_registers): Refactor as methods of
8516 mips_fbsd_nat_target.
8517 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
8519 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
8520 (the_mips_nbsd_nat_target): New.
8521 (mipsnbsd_fetch_inferior_registers)
8522 (mipsnbsd_store_inferior_registers): Refactor as methods of
8523 mips_nbsd_nat_target.
8524 (_initialize_mipsnbsd_nat): Adjust to C++ification.
8525 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
8526 (the_mips64_obsd_nat_target): New.
8527 (mips64obsd_fetch_inferior_registers)
8528 (mips64obsd_store_inferior_registers): Refactor as methods of
8529 mips64_obsd_nat_target.
8530 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
8532 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
8534 * nbsd-nat.h: Include "inf-ptrace.h".
8535 (nbsd_nat_target): New class.
8536 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
8537 (obsd_wait): Refactor as methods of obsd_nat_target.
8538 (obsd_add_target): Delete.
8539 * obsd-nat.h: Include "inf-ptrace.h".
8540 (obsd_nat_target): New class.
8541 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
8542 (the_ppc_fbsd_nat_target): New.
8543 (ppcfbsd_fetch_inferior_registers)
8544 (ppcfbsd_store_inferior_registers): Refactor as methods of
8545 ppc_fbsd_nat_target.
8546 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
8548 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
8549 (the_ppc_nbsd_nat_target): New.
8550 (ppcnbsd_fetch_inferior_registers)
8551 (ppcnbsd_store_inferior_registers): Refactor as methods of
8552 ppc_nbsd_nat_target.
8553 (_initialize_ppcnbsd_nat): Adjust to C++ification.
8554 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
8555 (the_ppc_obsd_nat_target): New.
8556 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
8557 methods of ppc_obsd_nat_target.
8558 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
8560 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
8561 (the_sh_nbsd_nat_target): New.
8562 (shnbsd_fetch_inferior_registers)
8563 (shnbsd_store_inferior_registers): Refactor as methods of
8565 (_initialize_shnbsd_nat): Adjust to C++ification.
8566 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
8567 (inf_ptrace_xfer_partial): Delete.
8568 (sparc_xfer_partial, sparc_target): Delete.
8569 * sparc-nat.h (sparc_fetch_inferior_registers)
8570 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
8571 (sparc_target): Delete function declaration.
8572 (sparc_target): New template class.
8573 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
8574 (_initialize_sparcnbsd_nat): Adjust to C++ification.
8575 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
8576 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
8578 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
8579 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
8580 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
8581 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
8583 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
8584 (the_vax_bsd_nat_target): New.
8585 (vaxbsd_fetch_inferior_registers)
8586 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
8588 (_initialize_vaxbsd_nat): Adjust to C++ification.
8590 * bsd-kvm.c (bsd_kvm_target): New class.
8591 (bsd_kvm_ops): Now a bsd_kvm_target.
8592 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
8593 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
8594 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
8596 (bsd_kvm_return_one): Delete.
8597 (bsd_kvm_add_target): Adjust to C++ification.
8599 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
8600 (nto_procfs_target_procfs): New classes.
8601 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
8602 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
8603 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
8604 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
8605 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
8606 (procfs_remove_hw_breakpoint, procfs_resume)
8607 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
8608 (procfs_kill_inferior, procfs_store_registers)
8609 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
8610 as methods of nto_procfs_target.
8611 (nto_procfs_ops): Now an nto_procfs_target_procfs.
8612 (nto_native_ops): Delete.
8613 (procfs_open, procfs_native_open): Delete.
8614 (nto_native_ops): Now an nto_procfs_target_native.
8615 (init_procfs_targets): Adjust to C++ification.
8616 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
8617 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
8618 Refactor as methods of nto_procfs_target.
8620 * go32-nat.c (go32_nat_target): New class.
8621 (the_go32_nat_target): New.
8622 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
8623 (go32_store_registers, go32_xfer_partial, go32_files_info)
8624 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
8625 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
8626 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
8627 (go32_pid_to_str): Refactor as methods of go32_nat_target.
8628 (go32_target): Delete.
8629 (_initialize_go32_nat): Adjust to C++ification.
8631 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
8632 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
8633 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
8634 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
8636 (gnu_target): Delete.
8637 * gnu-nat.h (gnu_target): Delete.
8638 (gnu_nat_target): New class.
8639 * i386-gnu-nat.c (gnu_base_target): New.
8640 (i386_gnu_nat_target): New class.
8641 (the_i386_gnu_nat_target): New.
8642 (_initialize_i386gnu_nat): Adjust to C++ification.
8644 2018-05-02 Pedro Alves <palves@redhat.com>
8646 * bfd-target.c (target_bfd_xclose): Rename to ...
8647 (target_bfd_close): ... this.
8648 (target_bfd_reopen): Adjust.
8649 * target.c (target_close): Remove references to to_xclose.
8650 * target.h (target_ops::to_xclose): Delete.
8651 (target_ops::to_close): Update comments.
8653 2018-05-02 Pedro Alves <palves@redhat.com>
8655 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
8657 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
8658 * inf-ptrace.c (inf_ptrace_register_u_offset)
8659 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8660 (inf_ptrace_store_register, inf_ptrace_store_registers)
8661 (inf_ptrace_trad_target): Move to ...
8662 * linux-nat-trad.c: ... this new file.
8663 * linux-nat-trad.h: New file.
8664 * linux-nat.c (linux_target_install_ops): Make extern.
8665 (linux_trad_target): Delete.
8666 * linux-nat.h (linux_trad_target): Delete declaration.
8667 (linux_target_install_ops): Declare.
8668 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
8671 2018-05-02 Pedro Alves <palves@redhat.com>
8673 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8674 procfs_target/add_target here.
8675 * procfs.c (procfs_target): Make static.
8676 (_initialize_procfs): Call add_target here.
8677 * procfs.h (struct target_ops): Remove forward declaration.
8678 (procfs_target): Remove declaration.
8679 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
8681 2018-05-02 Pedro Alves <palves@redhat.com>
8683 * procfs.c (procfs_stopped_by_watchpoint)
8684 (procfs_insert_watchpoint, procfs_remove_watchpoint)
8685 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
8687 (procfs_use_watchpoints): Delete, move contents...
8688 (procfs_target): ... here.
8689 * procfs.h (procfs_use_watchpoints): Delete declaration.
8690 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8691 procfs_use_watchpoints.
8692 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
8693 procfs_use_watchpoints.
8695 2018-05-02 Tom Tromey <tom@tromey.com>
8698 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
8699 and var_zuinteger_unlimited.
8700 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
8701 and PARAM_ZUINTEGER_UNLIMITED.
8702 (set_parameter_value): Handle var_zuinteger and
8703 var_zuinteger_unlimited.
8704 (add_setshow_generic): Likewise.
8705 (parmpy_init): Likewise.
8707 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
8710 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
8711 pointer is not null before dereferencing it.
8713 2018-04-30 Tom Tromey <tom@tromey.com>
8715 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
8718 2018-04-30 Tom Tromey <tom@tromey.com>
8720 * breakpoint.c (mention): Remove use of is_mi_like_p.
8721 (print_mention_ranged_breakpoint): Likewise.
8722 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
8725 2018-04-30 Tom Tromey <tom@tromey.com>
8727 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
8729 2018-04-30 Tom Tromey <tom@tromey.com>
8731 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
8732 (info_spu_event_command): Remove some uses of is_mi_like_p.
8734 2018-04-30 Tom Tromey <tom@tromey.com>
8736 * python/py-framefilter.c (py_print_single_arg)
8737 (enumerate_locals, py_print_args, py_print_frame): Remove some
8738 uses of is_mi_like_p.
8740 2018-04-30 Tom Tromey <tom@tromey.com>
8743 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
8744 * ui-out.h (ui_out::is_mi_like_p): Now const.
8745 (ui_out::do_is_mi_like_p): Now const.
8746 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
8748 2018-04-30 Tom Tromey <tom@tromey.com>
8750 * varobj.c (varobj_set_visualizer): Use new_reference.
8751 * python/python.c (gdbpy_decode_line): Use new_reference.
8752 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
8755 2018-04-30 Tom Tromey <tom@tromey.com>
8757 * varobj.c (install_new_value): Use new_reference.
8758 * value.h (value_incref): Return void. Swap intro comment with
8760 * value.c (set_value_parent): Use new_reference.
8761 (value_incref): Return void. Update intro comment.
8762 (release_value): Use new_reference.
8763 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
8765 2018-04-30 Tom Tromey <tom@tromey.com>
8767 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
8768 * gdb_bfd.h (new_bfd_ref): Remove.
8769 (gdb_bfd_open): Update comment.
8770 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
8771 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
8772 (gdb_bfd_fdopenr): Use new_reference.
8773 * exec.c (exec_file_attach): Use new_reference.
8775 2018-04-30 Tom Tromey <tom@tromey.com>
8777 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
8780 2018-04-30 Tom Tromey <tom@tromey.com>
8782 * jit.c (jit_read_code_entry): Use type_align.
8783 * i386-tdep.c (i386_gdbarch_init): Don't call
8784 set_gdbarch_long_long_align_bit.
8785 * gdbarch.sh: Remove long_long_align_bit.
8786 * gdbarch.c, gdbarch.h: Rebuild.
8787 * arc-tdep.c (arc_type_align): New function.
8788 (arc_gdbarch_init): Use arc_type_align. Don't call
8789 set_gdbarch_long_long_align_bit.
8791 2018-04-30 Tom Tromey <tom@tromey.com>
8793 * rust-lang.c (rust_type_alignment): Remove.
8794 (rust_composite_type): Use type_align.
8796 2018-04-30 Tom Tromey <tom@tromey.com>
8798 * NEWS: Mention Type.align.
8799 * python/py-type.c (typy_get_alignof): New function.
8800 (type_object_getset): Add "alignof".
8802 2018-04-30 Tom Tromey <tom@tromey.com>
8806 * std-operator.def (UNOP_ALIGNOF): New operator.
8807 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
8809 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
8810 * c-lang.c (c_op_print_tab): Add alignof.
8811 * c-exp.y (ALIGNOF): New token.
8812 (exp): Add "ALIGNOF" production.
8813 (ident_tokens): Add _Alignof and alignof.
8815 2018-04-30 Tom Tromey <tom@tromey.com>
8817 * i386-tdep.c (i386_type_align): New function.
8818 (i386_gdbarch_init): Update.
8819 * gdbarch.sh (type_align): New method.
8820 * gdbarch.c, gdbarch.h: Rebuild.
8821 * arch-utils.h (default_type_align): Declare.
8822 * arch-utils.c (default_type_align): New function.
8823 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
8824 (struct type) <align_log2>: New field.
8825 <instance_flags>: Now a bitfield.
8826 (TYPE_RAW_ALIGN): New macro.
8827 (type_align, type_raw_align, set_type_align): Declare.
8828 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
8830 * dwarf2read.c (quirk_rust_enum): Set type alignment.
8831 (get_alignment, maybe_set_alignment): New functions.
8832 (read_structure_type, read_enumeration_type, read_array_type)
8833 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
8834 (read_subrange_type, read_base_type): Set type alignment.
8836 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
8838 * dwarf2read.c (read_index_from_section): Use bool.
8840 2018-04-29 Fabian Groffen <grobian@gentoo.org>
8843 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
8846 2018-04-29 John Reiser <jreiser@BitWagon.com>
8849 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
8850 last step, and do it atomically.
8852 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
8854 * compile/compile-c-types.c (convert_int, convert_float):
8857 2018-04-27 Tom Tromey <tom@tromey.com>
8860 * rust-lang.c (rust_inclusive_range_type_p): New function.
8861 (rust_range): Handle inclusive ranges.
8862 (rust_compute_range): Likewise.
8863 * rust-exp.y (struct rust_op) <inclusive>: New field.
8864 (DOTDOTEQ): New constant.
8865 (range_expr): Add "..=" productions.
8866 (operator_tokens): Add "..=" token.
8867 (ast_range): Add "inclusive" parameter.
8868 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
8870 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
8872 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
8873 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
8875 * expprint.c (print_subexp_standard): Handle new bounds values.
8876 (dump_subexp_body_standard): Likewise.
8878 2018-04-27 Tom Tromey <tom@tromey.com>
8880 * configure: Rebuild.
8881 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
8882 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
8884 (class symbol_needs_eval_context): Likewise.
8885 * dwarf2read.c (mock_mapped_index::symbol_name_count)
8886 (mock_mapped_index::symbol_name_at): Use "override". Remove
8888 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
8890 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
8891 * aarch64-tdep.c (instruction_reader::read): Use "override".
8892 (instruction_reader_test::read): Likewise.
8893 * arm-tdep.c (instruction_reader::read): Use "override".
8894 (instruction_reader_thumb::read): Likewise.
8896 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
8899 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
8900 instead of remote_send.
8901 (remote_send): Remove.
8903 2018-04-26 Pedro Alves <palves@redhat.com>
8905 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
8906 find_function_start_sal instead of find_pc_line.
8908 2018-04-26 Pedro Alves <palves@redhat.com>
8910 * breakpoint.c (set_breakpoint_location_function): Handle
8912 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
8913 * elfread.c (elf_symtab_read): Give data symbols with
8914 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
8915 (elf_rel_plt_read): Update comment.
8916 * linespec.c (convert_linespec_to_sals): Handle
8918 (minsym_found): Handle mst_data_gnu_ifunc.
8919 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
8920 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
8921 * parse.c (find_minsym_type_and_address): Handle
8923 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
8924 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
8925 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
8927 <mst_data_gnu_ifunc>: New enumerator.
8929 2018-04-26 Pedro Alves <palves@redhat.com>
8931 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
8932 (lookup_minimal_symbol_by_pc_section): ... this. Replace
8933 'want_trampoline' parameter by a lookup_msym_prefer parameter.
8935 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
8936 (lookup_minimal_symbol_by_pc): Adjust.
8937 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
8938 (lookup_solib_trampoline_symbol_by_pc): Adjust.
8939 * minsyms.h (lookup_msym_prefer): New enum.
8940 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
8941 parameter by a lookup_msym_prefer parameter.
8943 2018-04-26 Pedro Alves <palves@redhat.com>
8945 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
8946 ends in "@plt" instead of looking at the symbol's section.
8948 2018-04-26 Pedro Alves <palves@redhat.com>
8950 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
8952 (find_pc_partial_function_gnu_ifunc): Rename to ...
8953 (find_pc_partial_function): ... this, and remove references to
8955 (find_pc_partial_function): Delete old implementation.
8956 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
8958 2018-04-26 Pedro Alves <palves@redhat.com>
8960 * linespec.c (struct bound_minimal_symbol_search_key): New.
8961 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
8962 skip first line if we found a GNU ifunc minimal symbol by name.
8963 (compare_msymbols): Change parameters to work with a destructured
8965 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
8968 2018-04-26 Pedro Alves <palves@redhat.com>
8970 * breakpoint.c (set_breakpoint_location_function): Don't resolve
8971 ifunc targets here. Instead, if we have an ifunc minsym, use its
8973 (add_location_to_breakpoint): Store the minsym and the objfile in
8974 the breakpoint location.
8975 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
8976 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
8977 Record the minsym in the sal.
8978 * symtab.h (symtab_and_line) <msymbol>: New field.
8980 2018-04-26 Pedro Alves <palves@redhat.com>
8982 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
8983 unless we actually resolved the ifunc.
8985 2018-04-26 Pedro Alves <palves@redhat.com>
8987 * c-exp.y (variable production): Prefer ifunc minsyms over
8988 regular function symbols.
8989 * symtab.c (find_gnu_ifunc): New function.
8990 * minsyms.h (lookup_msym_prefer): New enum.
8991 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
8992 parameter by a lookup_msym_prefer parameter.
8993 * symtab.h (find_gnu_ifunc): New declaration.
8995 2018-04-26 Pedro Alves <palves@redhat.com>
8997 * blockframe.c (find_gnu_ifunc_target_type): New function.
8998 (find_function_type): New.
8999 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
9000 return a value with a memory address.
9001 (eval_call): For calls to GNU ifunc functions, try to find the
9002 type of the target function from the type that the resolver
9004 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
9006 * infcall.c (find_function_return_type): Delete.
9007 (find_function_addr): Add 'function_type' parameter. For calls to
9008 GNU ifunc functions, try to find the type of the target function
9009 from the type that the resolver returns, and return it via
9011 (call_function_by_hand_dummy): Adjust to use the function type
9012 returned by find_function_addr.
9013 (find_function_addr): Add 'function_type' parameter and move
9015 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
9018 2018-04-26 Pedro Alves <palves@redhat.com>
9020 * c-exp.y (variable production): Skip finding an alias for ifunc
9023 2018-04-26 Pedro Alves <palves@redhat.com>
9025 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
9027 2018-04-25 Pedro Alves <palves@redhat.com>
9029 * infcmd.c (kill_command): Print the pid as string, not the whole
9030 thread's ptid. Add comment. s/has been killed/killed/ in output
9032 * remote.c (remote_detach_1): Print the pid as string, not the
9033 whole thread's ptid.
9035 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9036 Sergio Durigan Junior <sergiodj@redhat.com>
9037 Pedro Alves <palves@redhat.com>
9039 * infcmd.c (kill_command): Print message when inferior has
9041 * inferior.c (print_inferior_events): Remove 'static'. Set as
9043 (add_inferior): Improve message printed when
9044 'print_inferior_events' is on.
9045 (exit_inferior): Remove message printed when
9046 'print_inferior_events' is on.
9047 (detach_inferior): Improve message printed when
9048 'print_inferior_events' is on.
9049 (initialize_inferiors): Use 'add_inferior_silent' to set
9050 'current_inferior_'.
9051 * inferior.h (print_inferior_events): Declare here as
9053 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
9054 '[Detaching...]' messages when 'print_inferior_events' is on.
9055 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
9056 as prefix/suffix for messages. Remove periods. Fix erroneous
9057 'Detaching after fork from child...', replace it by '... from
9059 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
9060 prefix/suffix when printing 'Detaching...' messages. Print
9061 them when 'print_inferior_events' is on.
9062 * remote.c (remote_detach_1): Print message when detaching
9063 from inferior and '!is_fork_parent'.
9065 2018-04-24 Tom Tromey <tom@tromey.com>
9067 * cli-out.h: Reindent.
9069 2018-04-24 Tom Tromey <tom@tromey.com>
9071 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
9072 (cli_ui_out::do_field_string): Use fputs_filtered.
9073 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
9075 2018-04-23 Tom Tromey <tom@tromey.com>
9077 * guile/scm-frame.c (gdbscm_frame_read_var): Use
9078 gdb::unique_xmalloc_ptr.
9080 2018-04-23 Tom Tromey <tom@tromey.com>
9082 * configure: Rebuild.
9084 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
9087 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
9088 prepare_for_testing. Set normal_bp to r_debug_state if target
9091 2018-04-21 Pedro Alves <palves@redhat.com>
9092 Rajendra SY <rajendra.sy@gmail.com>
9094 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
9095 * remote.c (extended_remote_attach): In all-stop mode, mark the
9096 thread as executing.
9098 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9100 * thread.c (thread_apply_all_command): Fix comment.
9101 (thread_command): Fix comment.
9103 2018-04-10 Alan Hayward <alan.hayward@arm.com>
9105 * common/tdesc.h (tdesc_create_feature): Remove xml filename
9107 * features/aarch64-core.c (create_feature_aarch64_core):
9109 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
9111 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
9113 * features/i386/32bit-avx512.c
9114 (create_feature_i386_32bit_avx512): Likewise.
9115 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
9117 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
9119 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
9121 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
9123 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
9125 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
9127 * features/i386/64bit-avx512.c
9128 (create_feature_i386_64bit_avx512): Likewise.
9129 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
9131 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
9133 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
9135 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
9137 * features/i386/64bit-segments.c
9138 (create_feature_i386_64bit_segments): Likewise.
9139 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
9141 * features/i386/x32-core.c
9142 (create_feature_i386_x32_core): Likewise.
9143 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
9144 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
9145 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
9146 * target-descriptions.c: In generated code, don't pass xml
9149 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9151 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
9152 (print_xml_feature::visit_post): Likewise.
9153 (print_xml_feature::visit): Likewise.
9154 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
9155 (print_xml_feature): Add new class.
9156 * regformats/regdat.sh: Null xmltarget on feature targets.
9157 * target-descriptions.c (struct target_desc): Add xmltarget.
9158 (maintenance_check_tdesc_xml_convert): Add unittest function.
9159 (tdesc_get_features_xml): Add function to get xml.
9160 (maintenance_check_xml_descriptions): Test xml generation.
9161 * xml-tdesc.c (string_read_description_xml): Add function.
9162 * xml-tdesc.h (string_read_description_xml): Add declaration.
9164 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9166 * features/Makefile: Add feature marker to targets with new style
9167 target descriptions.
9168 * regformats/aarch64.dat: Regenerate.
9169 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
9170 * regformats/i386/amd64-avx-linux.dat: Likewise.
9171 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
9172 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
9173 * regformats/i386/amd64-linux.dat: Likewise.
9174 * regformats/i386/amd64-mpx-linux.dat: Likewise.
9175 * regformats/i386/amd64.dat: Likewise.
9176 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
9177 * regformats/i386/i386-avx-linux.dat: Likewise.
9178 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
9179 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
9180 * regformats/i386/i386-linux.dat: Likewise.
9181 * regformats/i386/i386-mmx-linux.dat: Likewise.
9182 * regformats/i386/i386-mpx-linux.dat: Likewise.
9183 * regformats/i386/i386.dat: Likewise.
9184 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
9185 * regformats/i386/x32-avx-linux.dat: Likewise.
9186 * regformats/i386/x32-linux.dat: Likewise.
9187 * regformats/tic6x-c62x-linux.dat: Likewise.
9188 * regformats/tic6x-c64x-linux.dat: Likewise.
9189 * regformats/tic6x-c64xp-linux.dat: Likewise.
9190 * regformats/regdat.sh: Parse feature marker.
9192 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9194 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
9195 (tdesc_osabi_name): Likewise.
9196 * target-descriptions.c (tdesc_architecture_name): Add new
9198 (tdesc_osabi_name): Likewise.
9200 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9202 * common/tdesc.c (tdesc_predefined_type): Move to here.
9203 (tdesc_named_type): Likewise.
9204 (tdesc_create_vector): Likewise.
9205 (tdesc_create_struct): Likewise.
9206 (tdesc_set_struct_size): Likewise.
9207 (tdesc_create_union): Likewise.
9208 (tdesc_create_flags): Likewise.
9209 (tdesc_create_enum): Likewise.
9210 (tdesc_add_field): Likewise.
9211 (tdesc_add_typed_bitfield): Likewise.
9212 (tdesc_add_bitfield): Likewise.
9213 (tdesc_add_flag): Likewise.
9214 (tdesc_add_enum_value): Likewise.
9215 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
9216 (struct tdesc_type_vector): Likewise.
9217 (struct tdesc_type_field): Likewise.
9218 (struct tdesc_type_with_fields): Likewise.
9219 (tdesc_create_enum): Add declaration.
9220 (tdesc_add_typed_bitfield): Likewise.
9221 (tdesc_add_enum_value): Likewise.
9222 * target-descriptions.c (tdesc_type_field): Move from here.
9223 (tdesc_type_builtin): Likewise.
9224 (tdesc_type_vector): Likewise.
9225 (tdesc_type_with_fields): Likewise.
9226 (tdesc_predefined_types): Likewise.
9227 (tdesc_named_type): Likewise.
9228 (tdesc_create_vector): Likewise.
9229 (tdesc_create_struct): Likewise.
9230 (tdesc_set_struct_size): Likewise.
9231 (tdesc_create_union): Likewise.
9232 (tdesc_create_flags): Likewise.
9233 (tdesc_create_enum): Likewise.
9234 (tdesc_add_field): Likewise.
9235 (tdesc_add_typed_bitfield): Likewise.
9236 (tdesc_add_bitfield): Likewise.
9237 (tdesc_add_flag): Likewise.
9238 (tdesc_add_enum_value): Likewise.
9239 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
9240 (tdesc_add_typed_bitfield): Likewise.
9241 (tdesc_add_enum_value): Likewise.
9243 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9245 * common/tdesc.c (tdesc_feature::accept): Move to here.
9246 (tdesc_feature::operator==): Likewise.
9247 (tdesc_create_reg): Likewise.
9248 * common/tdesc.h (tdesc_type_kind): Likewise.
9249 (struct tdesc_type): Likewise.
9250 (struct tdesc_feature): Likewise.
9251 * regformats/regdat.sh: Create a feature.
9252 * target-descriptions.c (tdesc_type_kind): Move from here.
9253 (tdesc_type): Likewise.
9254 (tdesc_type_up): Likewise.
9255 (tdesc_feature): Likewise.
9256 (tdesc_create_reg): Likewise.
9258 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9260 * Makefile.in: Add arch/tdesc.c
9261 * common/tdesc.c: New file.
9262 * common/tdesc.h (tdesc_element_visitor): Move to here.
9263 (tdesc_element): Likewise.
9264 (tdesc_reg): Likewise.
9265 (tdesc_reg_up): Likewise.
9266 * regformats/regdef.h (reg): Add offset to constructors.
9267 * target-descriptions.c (tdesc_element_visitor): Move from here.
9268 (tdesc_element): Likewise.
9269 (tdesc_reg): Likewise.
9270 (tdesc_reg_up): Likewise.
9272 2018-04-17 Tom Tromey <tom@tromey.com>
9274 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
9277 2018-04-17 Tom Tromey <tom@tromey.com>
9279 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
9281 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
9283 * symtab.c (print_symbol_info): Skip printing filename and line
9284 number when `last' is NULL.
9285 (symtab_symbol_info): Use empty string instead of NULL for first
9286 invocation of print_symbol_info.
9287 (rbreak_command): Pass NULL to `last' parameter of
9290 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
9292 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
9295 2018-04-16 Pedro Alves <palves@redhat.com>
9297 * MAINTAINERS (sh): Remove.
9298 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
9299 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
9300 (ALLDEPFILES): Remove sh64-tdep.c.
9301 * NEWS: Mentions that support for SH-5/SH64 is removed.
9302 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
9303 (sh*-*-openbsd*): Ditto.
9304 (sh64-*-elf*): Remove.
9306 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
9307 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
9308 * sh-tdep.c: No longer include "sh64-tdep.h".
9309 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
9310 * sh64-tdep.c, sh64-tdep.h: Remove files.
9312 2018-04-16 Pedro Alves <palves@redhat.com>
9314 * MAINTAINERS: Remove m88k.
9315 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
9316 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
9317 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
9318 * NEWS: Mention that support for m88k was removed.
9319 * configure.host (m88*-*-*): Remove support.
9320 * configure.nat (m88k-*-*): Remove support.
9321 * configure.tgt (m88*-*-openbsd*): Remove.
9322 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
9324 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
9326 * configure.tgt (x86_tobjs): New variable.
9327 (amd64_tobjs, i386_tobjs): Use it.
9329 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9331 * symtab.c (print_symbol_info): Precede the symbol definition by
9332 the line number when available.
9333 * NEWS: Advertise this enhancement.
9335 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9337 * NEWS (New options): announce set/show record btrace cpu.
9338 * btrace.c: Include record-btrace.h.
9339 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
9340 the vendor is unknown.
9341 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
9342 Maybe overwrite the btrace configuration's cpu.
9343 (btrace_compute_ftrace): Add cpu parameter. Update callers.
9344 (btrace_fetch): Add cpu parameter. Update callers.
9345 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
9346 Maybe overwrite the btrace configuration's cpu. Skip enabling
9347 errata workarounds if the vendor is unknown.
9348 * python/py-record-btrace.c: Include record-btrace.h.
9349 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
9350 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
9351 * record-btrace.c (record_btrace_cpu_state_kind): New.
9352 (record_btrace_cpu): New.
9353 (set_record_btrace_cpu_cmdlist): New.
9354 (record_btrace_get_cpu): New.
9355 (require_btrace_thread, record_btrace_info)
9356 (record_btrace_resume_thread): Call record_btrace_get_cpu.
9357 (cmd_set_record_btrace_cpu_none): New.
9358 (cmd_set_record_btrace_cpu_auto): New.
9359 (cmd_set_record_btrace_cpu): New.
9360 (cmd_show_record_btrace_cpu): New.
9361 (_initialize_record_btrace): Initialize set/show record btrace cpu
9363 * record-btrace.h (record_btrace_get_cpu): New.
9365 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9367 * record.c (set_record_command): Fix typo in message.
9369 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9371 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
9373 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9375 * infrun.c (process_event_stop_test): Call
9376 gdbarch_in_indirect_branch_thunk.
9377 * gdbarch.sh (in_indirect_branch_thunk): New.
9378 * gdbarch.c: Regenerated.
9379 * gdbarch.h: Regenerated.
9382 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
9383 (HFILES_NO_SRCDIR): Add x86-tdep.h.
9384 (ALLDEPFILES): Add x86-tdep.c.
9385 * arch-utils.h (default_in_indirect_branch_thunk): New.
9386 * arch-utils.c (default_in_indirect_branch_thunk): New.
9387 * i386-tdep: Include x86-tdep.h.
9388 (i386_in_indirect_branch_thunk): New.
9389 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
9391 * amd64-tdep: Include x86-tdep.h.
9392 (amd64_in_indirect_branch_thunk): New.
9393 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
9395 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
9398 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
9399 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
9400 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
9403 2018-04-12 Tom Tromey <tom@tromey.com>
9405 * rust-lang.c (rust_print_struct_def): Remove univariant code.
9406 (rust_evaluate_subexp): Likewise.
9408 2018-04-12 Pedro Alves <palves@redhat.com>
9410 * procfs.c (procfs_detach): Make forward declaration's prototype
9411 match definition's protototype.
9412 (proc_get_LDT_entry): Remove stale do_cleanups call.
9414 2018-04-12 Pedro Alves <palves@redhat.com>
9416 * target.h (target_ops::to_has_exited): Delete.
9417 (target_has_exited): Delete.
9418 * target-delegates.c: Regenerate.
9420 2018-04-11 Pedro Alves <palves@redhat.com>
9422 * target.c (fileio_fh_t::t): Add comment.
9423 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9424 (target_fileio_close): Handle a NULL target.
9425 (invalidate_fileio_fh): New.
9426 (target_close): Call it.
9427 * remote.c (remote_hostio_send_command): No longer check whether
9428 remote_desc is open.
9430 2018-04-11 Pedro Alves <palves@redhat.com>
9432 * target.c (fileio_fh_t): Make it a named struct instead of a
9434 (fileio_fh_t::is_closed): New method.
9435 (DEF_VEC_O (fileio_fh_t)): Remove.
9436 (fileio_fhandles): Now a std::vector.
9437 (is_closed_fileio_fh): Delete.
9438 (acquire_fileio_fd): Adjust. Rename parameters.
9439 (release_fileio_fd): Adjust.
9440 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
9441 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9442 (target_fileio_close): Adjust.
9444 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
9446 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
9449 2018-04-10 Pedro Alves <palves@redhat.com>
9451 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
9452 (scoped_finish_thread_state): New class.
9453 * infcmd.c (run_command_1): Use it instead of finish_thread_state
9455 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
9456 (fetch_inferior_event, normal_stop): Likewise.
9457 * thread.c (finish_thread_state_cleanup): Delete.
9459 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9460 Pedro Alves <palves@redhat.com>
9462 * value.c: Include "selftest.h" and "common/array-view.h".
9463 (struct range) <operator ==>: New.
9464 (test_ranges_contain): New.
9465 (check_ranges_vector): New.
9466 (test_insert_into_bit_range_vector): New.
9467 (_initialize_values): Register selftests.
9468 * common/array-view.h (operator==, operator!=): New.
9470 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9472 * common/gdb_vecs.h (unordered_remove): Add overload that takes
9474 * inline-frame.c: Include <algorithm>.
9475 (struct inline_state): Add constructor.
9476 (inline_state_s): Remove.
9477 (DEF_VEC_O(inline_state_s)): Remove.
9478 (inline_states): Change type to std::vector.
9479 (find_inline_frame_state): Adjust to std::vector.
9480 (allocate_inline_frame_state): Remove.
9481 (clear_inline_frame_state): Adjust to std::vector.
9482 (skip_inline_frames): Adjust to std::vector.
9484 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9486 * tracepoint.h (struct trace_state_variable): Add constructor.
9487 <name>: Change type to std::string.
9488 * tracepoint.c (tsv_s): Remove.
9489 (DEF_VEC_O(tsv_s)): Remove.
9490 (tvariables): Change to std::vector.
9491 (create_trace_state_variable): Adjust to std::vector.
9492 (find_trace_state_variable): Likewise.
9493 (find_trace_state_variable_by_number): Likewise.
9494 (delete_trace_state_variable): Likewise.
9495 (trace_variable_command): Adjust to std::string.
9496 (delete_trace_variable_command): Likewise.
9497 (tvariables_info_1): Adjust to std::vector.
9498 (save_trace_state_variables): Likewise.
9499 (start_tracing): Likewise.
9500 (merge_uploaded_trace_state_variables): Adjust to std::vector
9502 * target.h (struct target_ops)
9503 <to_download_trace_state_variable>: Pass reference to
9504 trace_state_variable.
9505 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
9506 * target-delegates.c: Re-generate.
9507 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
9508 (mi_tsv_deleted): Likewise.
9509 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
9510 * remote.c (remote_download_trace_state_variable): Change
9511 pointer to reference and adjust.
9512 * make-target-delegates (parse_argtypes): Handle references.
9513 (write_function_header): Likewise.
9514 (munge_type): Likewise.
9516 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9518 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9519 string_view-selftests.c.
9520 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
9522 * unittests/basic_string_view/cons/char/1.cc: Likewise.
9523 * unittests/basic_string_view/cons/char/2.cc: Likewise.
9524 * unittests/basic_string_view/cons/char/3.cc: Likewise.
9525 * unittests/basic_string_view/element_access/char/1.cc:
9527 * unittests/basic_string_view/element_access/char/empty.cc:
9529 * unittests/basic_string_view/element_access/char/front_back.cc:
9531 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
9532 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
9534 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
9536 * unittests/basic_string_view/modifiers/swap/char/1.cc:
9538 * unittests/basic_string_view/operations/compare/char/1.cc:
9540 * unittests/basic_string_view/operations/compare/char/13650.cc:
9542 * unittests/basic_string_view/operations/copy/char/1.cc:
9544 * unittests/basic_string_view/operations/data/char/1.cc:
9546 * unittests/basic_string_view/operations/find/char/1.cc:
9548 * unittests/basic_string_view/operations/find/char/2.cc:
9550 * unittests/basic_string_view/operations/find/char/3.cc:
9552 * unittests/basic_string_view/operations/find/char/4.cc:
9554 * unittests/basic_string_view/operations/rfind/char/1.cc:
9556 * unittests/basic_string_view/operations/rfind/char/2.cc:
9558 * unittests/basic_string_view/operations/rfind/char/3.cc:
9560 * unittests/basic_string_view/operations/substr/char/1.cc:
9562 * unittests/basic_string_view/operators/char/2.cc: Likewise.
9563 * unittests/string_view-selftests.c: New file.
9565 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9567 * unittests/basic_string_view/capacity/1.cc: New file.
9568 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
9569 * unittests/basic_string_view/cons/char/1.cc: New file.
9570 * unittests/basic_string_view/cons/char/2.cc: New file.
9571 * unittests/basic_string_view/cons/char/3.cc: New file.
9572 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
9573 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
9574 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
9575 * unittests/basic_string_view/element_access/char/1.cc: New file.
9576 * unittests/basic_string_view/element_access/char/2.cc: New file.
9577 * unittests/basic_string_view/element_access/char/empty.cc: New file.
9578 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
9579 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
9580 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
9581 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
9582 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
9583 * unittests/basic_string_view/include.cc: New file.
9584 * unittests/basic_string_view/inserters/char/1.cc: New file.
9585 * unittests/basic_string_view/inserters/char/2.cc: New file.
9586 * unittests/basic_string_view/inserters/char/3.cc: New file.
9587 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
9588 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
9589 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
9590 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
9591 * unittests/basic_string_view/literals/types.cc: New file.
9592 * unittests/basic_string_view/literals/values.cc: New file.
9593 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
9594 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
9595 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
9596 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
9597 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
9598 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
9599 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
9600 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
9601 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
9602 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
9603 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
9604 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
9605 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
9606 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
9607 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
9608 * unittests/basic_string_view/operations/data/char/1.cc: New file.
9609 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
9610 * unittests/basic_string_view/operations/find/char/1.cc: New file.
9611 * unittests/basic_string_view/operations/find/char/2.cc: New file.
9612 * unittests/basic_string_view/operations/find/char/3.cc: New file.
9613 * unittests/basic_string_view/operations/find/char/4.cc: New file.
9614 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
9615 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
9616 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
9617 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
9618 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
9619 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
9620 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
9621 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
9622 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
9623 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
9624 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
9625 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
9626 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
9627 * unittests/basic_string_view/operators/char/2.cc: New file.
9628 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
9629 * unittests/basic_string_view/range_access/char/1.cc: New file.
9630 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
9631 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
9632 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
9633 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
9634 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
9635 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
9636 * unittests/basic_string_view/requirements/typedefs.cc: New file.
9637 * unittests/basic_string_view/typedefs.cc: New file.
9638 * unittests/basic_string_view/types/1.cc: New file.
9640 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9642 * common/gdb_string_view.h: Remove libstdc++ implementation
9643 details, adjust to gdb reality.
9644 * common/gdb_string_view.tcc: Likewise.
9645 * cli/cli-script.c (struct string_view): Remove.
9646 (user_args) <m_args>: Change element type to gdb::string_view.
9647 (user_args::insert_args): Adjust.
9649 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9651 * common/gdb_string_view.h: New file.
9652 * common/gdb_string_view.tcc: New file.
9654 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9656 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
9657 * configure: Re-generate.
9659 2018-04-09 Pedro Alves <palves@redhat.com>
9661 * gdbarch.sh: Include "observable.h" instead of "observer.h".
9662 (set_target_gdbarch): Call
9663 gdb::observers::architecture_changed.notify instead of
9664 observer_notify_architecture_changed.
9666 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9668 * tracepoint.c (struct current_traceframe_cleanup): Remove.
9669 (do_restore_current_traceframe_cleanup): Remove.
9670 (restore_current_traceframe_cleanup_dtor): Remove.
9671 (make_cleanup_restore_current_traceframe): Remove.
9672 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
9674 * tracepoint.h (struct scoped_restore_current_traceframe): New.
9675 * infrun.c (fetch_inferior_event): Use
9676 scoped_restore_current_traceframe.
9678 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9680 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
9682 <n_allocated_type_units>: Remove.
9683 <all_type_units>: Change to std::vector.
9684 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9685 to std::vector change.
9686 (dwarf2_per_objfile::get_cutu): Likewise.
9687 (dwarf2_per_objfile::get_tu): Likewise.
9688 (create_signatured_type_table_from_index): Likewise.
9689 (create_signatured_type_table_from_debug_names): Likewise.
9690 (dw2_symtab_iter_next): Likewise.
9691 (dw2_print_stats): Likewise.
9692 (dw2_expand_all_symtabs): Likewise.
9693 (dw2_expand_marked_cus): Likewise.
9694 (dw2_debug_names_iterator::next): Likewise.
9695 (dwarf2_initialize_objfile): Likewise.
9696 (add_signatured_type_cu_to_table): Likewise.
9697 (create_all_type_units): Likewise.
9698 (add_type_unit): Likewise.
9699 (struct tu_abbrev_offset): Add constructor.
9700 (build_type_psymtabs_1): Adjust to std::vector change.
9701 (print_tu_stats): Likewise.
9702 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9703 (write_debug_names): Likewise.
9705 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9707 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
9708 Make an std::vector.
9709 <n_comp_units>: Remove.
9710 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9711 to std::vector change.
9712 (dwarf2_per_objfile::get_cutu): Likewise.
9713 (dwarf2_per_objfile::get_cu): Likewise.
9714 (create_cus_from_index): Likewise.
9715 (create_addrmap_from_index): Likewise.
9716 (create_addrmap_from_aranges): Likewise.
9717 (dwarf2_read_index): Likewise.
9718 (dw2_find_last_source_symtab): Likewise.
9719 (dw2_map_symtabs_matching_filename): Likewise.
9720 (dw2_symtab_iter_next): Likewise.
9721 (dw2_print_stats): Likewise.
9722 (dw2_expand_all_symtabs): Likewise.
9723 (dw2_expand_symtabs_with_fullname): Likewise.
9724 (dw2_expand_marked_cus): Likewise.
9725 (dw2_map_symbol_filenames): Likewise.
9726 (create_cus_from_debug_names): Likewise.
9727 (dwarf2_read_debug_names): Likewise.
9728 (dw2_debug_names_iterator::next): Likewise.
9729 (dwarf2_initialize_objfile): Likewise.
9730 (set_partial_user): Likewise.
9731 (dwarf2_build_psymtabs_hard): Likewise.
9732 (read_comp_units_from_section): Remove arguments, adjust to
9734 (create_all_comp_units): Adjust to std::vector and
9735 read_comp_units_from_section changes.
9736 (dwarf2_find_containing_comp_unit): Adjust to std::vector
9738 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9739 (psyms_seen_size): Likewise.
9740 (write_gdbindex): Likewise.
9741 (write_debug_names): Likewise.
9743 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9745 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
9746 with dwarf2_per_objfile.
9747 (create_cus_from_index): Likewise.
9748 (create_signatured_type_table_from_index): Likewise.
9749 (dwarf2_read_index): Likewise.
9750 (dwarf2_initialize_objfile): Likewise.
9751 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
9752 per_cu rather than get_dwarf2_per_objfile.
9754 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9756 * dwarf2read.h (struct signatured_type): Forward declare.
9757 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
9759 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
9760 (dw2_get_cutu): ...this.
9761 (dwarf2_per_objfile::get_cu): Rename from...
9762 (dw2_get_cu): ...this.
9763 (dwarf2_per_objfile::get_tu): New.
9764 (create_addrmap_from_index): Adjust.
9765 (create_addrmap_from_aranges): Adjust.
9766 (dw2_find_last_source_symtab): Adjust.
9767 (dw2_map_symtabs_matching_filename): Adjust.
9768 (dw2_symtab_iter_next): Adjust.
9769 (dw2_print_stats): Adjust.
9770 (dw2_expand_all_symtabs): Adjust.
9771 (dw2_expand_symtabs_with_fullname): Adjust.
9772 (dw2_expand_marked_cus): Adjust.
9773 (dw_expand_symtabs_matching_file_matcher): Adjust.
9774 (dw2_map_symbol_filenames): Adjust.
9775 (dw2_debug_names_iterator::next): Adjust.
9776 (dwarf2_initialize_objfile): Adjust.
9777 (set_partial_user): Adjust.
9778 (dwarf2_build_psymtabs_hard): Adjust.
9780 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9782 * dwarf2read.c (create_signatured_type_table_from_debug_names):
9783 Remove unused variables.
9784 (dw2_map_symtabs_matching_filename): Likewise.
9785 (dwarf2_record_block_ranges): Likewise.
9786 (dwarf2_read_addr_index): Likewise.
9787 (follow_die_offset): Likewise.
9789 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9791 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
9792 to symbol_file_add_main.
9794 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9797 * mi/mi-console.c (do_fputc_async_safe): New.
9798 (mi_console_file::write_async_safe): New.
9799 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
9800 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
9802 * ui-file.c (ui_file::putstrn): Adjust call to
9803 fputstrn_unfiltered.
9804 * utils.c (printchar): Replace do_fputs and do_fprintf
9805 parameters by do_fputc.
9806 (fputstr_filtered): Adjust call to printchar.
9807 (fputstr_unfiltered): Likewise.
9808 (fputstrn_filtered): Likewise.
9809 (fputstrn_unfiltered): Add do_fputc parameter, pass to
9811 * utils.h (do_fputc_ftype): New typedef.
9812 (fputstrn_unfiltered): Add do_fputc parameter.
9814 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9816 * regformats/i386/i386-avx.dat: Remove.
9818 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9821 * amd64-tdep.c (amd64_none_init_abi): New function.
9822 (amd64_x32_none_init_abi): New function.
9823 (_initialize_amd64_tdep): Register handlers for x86-64 and
9824 x64_32 with GDB_OSABI_NONE.
9825 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
9826 GDB_OSABI_NONE osabi.
9828 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9831 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
9833 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
9834 * osabi.c (gdb_osabi_names): Add "unknown" entry.
9836 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9838 * common/byte-vector.h (char_vector): New type.
9839 * target.h (target_read_alloc): Return
9840 gdb::optional<byte_vector>.
9841 (target_read_stralloc): Return gdb::optional<char_vector>.
9842 (target_get_osdata): Return gdb::optional<char_vector>.
9843 * target.c (target_read_alloc_1): Templatize. Replacement
9844 manual memory management with vector.
9845 (target_read_alloc): Change return type, adjust.
9846 (target_read_stralloc): Change return type, adjust.
9847 (target_get_osdata): Change return type, adjust.
9848 * auxv.c (struct auxv_info) <length>: Remove.
9849 <data>: Change type to gdb::optional<byte_vector>.
9850 (auxv_inferior_data_cleanup): Free auxv_info with delete.
9851 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
9852 (target_auxv_search): Adjust.
9853 (fprint_target_auxv): Adjust.
9854 * avr-tdep.c (avr_io_reg_read_command): Adjust.
9855 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
9856 (linux_make_corefile_notes): Adjust.
9857 * osdata.c (get_osdata): Adjust.
9858 * remote.c (remote_get_threads_with_qxfer): Adjust.
9859 (remote_memory_map): Adjust.
9860 (remote_traceframe_info): Adjust.
9861 (btrace_read_config): Adjust.
9862 (remote_read_btrace): Adjust.
9863 (remote_pid_to_exec_file): Adjust.
9864 * solib-aix.c (solib_aix_get_library_list): Adjust.
9865 * solib-dsbt.c (decode_loadmap): Don't free buf.
9866 (dsbt_get_initial_loadmaps): Adjust.
9867 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
9868 * solib-target.c (solib_target_current_sos): Adjust.
9869 * tracepoint.c (sdata_make_value): Adjust.
9870 * xml-support.c (xinclude_start_include): Adjust.
9871 (xml_fetch_content_from_file): Adjust.
9872 * xml-support.h (xml_fetch_another): Change return type.
9873 (xml_fetch_content_from_file): Change return type.
9874 * xml-syscall.c (xml_init_syscalls_info): Adjust.
9875 * xml-tdesc.c (file_read_description_xml): Adjust.
9876 (fetch_available_features_from_target): Change return type.
9877 (target_fetch_description_xml): Adjust.
9878 (target_read_description_xml): Adjust.
9880 2018-04-06 Tom Tromey <tom@tromey.com>
9882 * value.c (~value): Update.
9883 (struct value) <contents>: Now unique_xmalloc_ptr.
9884 (value_contents_bits_eq, allocate_value_contents)
9885 (value_contents_raw, value_contents_all_raw)
9886 (value_contents_for_printing, value_contents_for_printing_const)
9887 (set_value_enclosing_type): Update.
9889 2018-04-06 Tom Tromey <tom@tromey.com>
9891 * value.c (range_s): Remove typedef, VEC.
9892 (struct range): Add operator<.
9893 (range_lessthan): Remove.
9894 (ranges_contain): Change type.
9896 (struct value) <unavailable, optimized_out>: Now std::vector.
9897 (value_entirely_available)
9898 (value_entirely_covered_by_range_vector)
9899 (value_entirely_unavailable, value_entirely_optimized_out):
9901 (insert_into_bit_range_vector): Change argument type.
9902 (find_first_range_overlap): Likewise.
9903 (struct ranges_and_idx, value_contents_bits_eq)
9904 (require_not_optimized_out, require_available): Update.
9905 (ranges_copy_adjusted): Change argument types.
9906 (value_optimized_out, value_copy, value_fetch_lazy): Update.
9908 2018-04-06 Tom Tromey <tom@tromey.com>
9910 * value.c (~value): Update.
9911 (struct value) <parent>: Now a value_ref_ptr.
9912 (value_parent, set_value_parent, value_address, value_copy):
9915 2018-04-06 Tom Tromey <tom@tromey.com>
9917 * value.c (struct value): Add constructor, destructor, and member
9919 (allocate_value_lazy, value_decref): Update.
9921 2018-04-06 Tom Tromey <tom@tromey.com>
9923 * value.c (struct value) <released, next>: Remove.
9924 (all_values): Now a std::vector.
9925 (allocate_value_lazy): Update.
9926 (value_next): Remove.
9927 (value_mark, value_free_to_mark, release_value)
9928 (value_release_to_mark): Update.
9930 2018-04-06 Tom Tromey <tom@tromey.com>
9932 * value.h (fetch_subexp_value, value_release_to_mark): Update.
9933 (free_value_chain): Remove.
9934 * value.c (free_value_chain): Remove.
9935 (value_release_to_mark): Return a std::vector.
9936 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
9938 (check_condition): Update.
9939 * eval.c (fetch_subexp_value): Change "val_chain" to a
9941 * breakpoint.c (update_watchpoint): Update.
9942 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
9944 2018-04-06 Tom Tromey <tom@tromey.com>
9946 * value.h (free_all_values): Remove.
9947 * value.c (free_all_values): Remove.
9949 2018-04-06 Tom Tromey <tom@tromey.com>
9951 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
9952 (value_history_chain, value_history_count): Remove.
9953 (value_history): New global.
9954 (record_latest_value, access_value_history, show_values)
9955 (preserve_values): Update.
9957 2018-04-06 Tom Tromey <tom@tromey.com>
9959 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
9960 * varobj.c (varobj_set_display_format, varobj_set_value)
9961 (install_default_visualizer, construct_visualizer)
9962 (install_new_value, ~varobj, varobj_get_value_type)
9963 (my_value_of_variable, varobj_editable_p): Update.
9964 * c-varobj.c (c_describe_child, c_value_of_variable)
9965 (cplus_number_of_children, cplus_describe_child): Update.
9966 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
9967 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
9968 (ada_value_of_variable, ada_value_is_changeable_p): Update.
9970 2018-04-06 Tom Tromey <tom@tromey.com>
9972 * printcmd.c (last_examine_address): Change type to
9974 (do_examine, x_command): Update.
9976 2018-04-06 Tom Tromey <tom@tromey.com>
9978 * value.c (release_value): Update.
9979 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
9980 (struct bpstats) <val>: Now a value_ref_ptr.
9981 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
9982 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
9983 (~watchpoint, print_it_watchpoint, watch_command_1)
9984 (invalidate_bp_value_on_memory_change): Update.
9986 2018-04-06 Tom Tromey <tom@tromey.com>
9988 * varobj.c (varobj_clear_saved_item)
9989 (update_dynamic_varobj_children, install_new_value, ~varobj):
9991 * value.h (value_incref): Move declaration earlier.
9992 (value_decref): Rename from value_free.
9993 (struct value_ref_policy): New.
9994 (value_ref_ptr): New typedef.
9995 (struct value_deleter): Remove.
9996 (gdb_value_up): Remove typedef.
9997 (release_value): Change return type.
9998 (release_value_or_incref): Remove.
9999 * value.c (set_value_parent): Update.
10000 (value_incref): Change return type.
10001 (value_decref): Rename from value_free.
10002 (value_free_to_mark, free_all_values, free_value_chain): Update.
10003 (release_value): Return value_ref_ptr.
10004 (release_value_or_incref): Remove.
10005 (record_latest_value, set_internalvar, clear_internalvar):
10007 * stack.c (info_frame_command): Don't call value_free.
10008 * python/py-value.c (valpy_dealloc, valpy_new)
10009 (value_to_value_object): Update.
10010 * printcmd.c (do_examine): Update.
10011 * opencl-lang.c (lval_func_free_closure): Update.
10012 * mi/mi-main.c (register_changed_p): Don't call value_free.
10013 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
10014 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
10015 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
10017 * guile/scm-value.c (vlscm_free_value_smob)
10018 (vlscm_scm_from_value): Update.
10019 * frame.c (frame_register_unwind, frame_unwind_register_signed)
10020 (frame_unwind_register_unsigned, get_frame_register_bytes)
10021 (put_frame_register_bytes): Don't call value_free.
10022 * findvar.c (address_from_register): Don't call value_free.
10023 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
10024 * dwarf2loc.c (entry_data_value_free_closure)
10025 (value_of_dwarf_reg_entry, free_pieced_value_closure)
10026 (dwarf2_evaluate_loc_desc_full): Update.
10027 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
10028 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
10029 (~watchpoint, watch_command_1)
10030 (invalidate_bp_value_on_memory_change): Update.
10031 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
10033 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
10036 * warning.m4: Add -Wno-error=deprecated-register.
10037 * configure: Re-generate.
10039 2018-04-05 Tom Tromey <tom@tromey.com>
10041 * linespec.h: Remove include of "vec.h".
10043 2018-04-05 Tom Tromey <tom@tromey.com>
10045 * linespec.c (typep): Remove typedef.
10046 (find_methods, find_superclass_methods): Take a std::vector.
10047 (find_method): Use std::vector.
10049 2018-04-05 Tom Tromey <tom@tromey.com>
10051 * utils.c (compare_strings): Remove.
10052 * utils.h (compare_strings): Remove.
10053 * objc-lang.h (find_imps): Update.
10054 * objc-lang.c (find_methods): Take a std::vector.
10055 (uniquify_strings, find_imps): Likewise.
10056 * linespec.c (find_methods): Take a std::vector.
10057 (decode_objc): Use std::vector.
10058 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
10060 (find_method, find_function_symbols): Use std::vector.
10062 2018-04-05 Tom Tromey <tom@tromey.com>
10064 * completer.c (completion_tracker::completion_tracker): Remove
10066 (completion_tracker::discard_completions): Likewise.
10067 * breakpoint.c (ambiguous_names_p): Remove cast.
10068 * ada-lang.c (_initialize_ada_language): Remove cast.
10069 * utils.h (streq): Update.
10070 (streq_hash): Add new declaration.
10071 * utils.c (streq): Return bool.
10072 (streq_hash): New function.
10074 2018-04-05 Tom Tromey <tom@tromey.com>
10076 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
10077 Remove a string copy.
10079 2018-04-05 Tom Tromey <tom@tromey.com>
10081 * linespec.c (filter_results): Use std::vector.
10082 (decode_line_2, decode_line_full): Update.
10084 2018-04-05 Tom Tromey <tom@tromey.com>
10086 * linespec.c (canonical_to_fullform): Return std::string.
10087 (filter_results): Update.
10088 (struct decode_line_2_item): Add constructor.
10089 <fullform, displayform>: Now std::string.
10090 (decode_line_2_compare_items): Now a std::sort comparator.
10091 (decode_line_2): Update.
10093 2018-04-05 Tom Tromey <tom@tromey.com>
10095 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
10096 (unexpected_linespec_error): Update.
10097 (linespec_parse_basic, parse_linespec): Update.
10099 2018-04-05 Tom Tromey <tom@tromey.com>
10101 * linespec.c (linespec_parse_basic): Reindent.
10103 2018-04-05 Tom Tromey <tom@tromey.com>
10105 * minsyms.h (iterate_over_minimal_symbols): Update.
10106 * minsyms.c (iterate_over_minimal_symbols): Take a
10107 gdb::function_view.
10108 * linespec.c (struct collect_minsyms): Remove.
10109 (compare_msyms): Now a std::sort comparator.
10110 (add_minsym): Add parameters.
10111 (search_minsyms_for_name): Update. Use std::vector.
10113 2018-04-03 Tom Tromey <tom@tromey.com>
10115 * mipsread.c (read_alphacoff_dynamic_symtab): Use
10118 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10120 * MAINTAINERS (Write After Approval): Add Weimin Pan.
10122 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10125 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
10126 printing static type.
10128 2018-04-01 Tom Tromey <tom@tromey.com>
10130 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
10131 (rs6000_xfer_shared_libraries): Update.
10133 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
10135 * common/gdb_vecs.h (char_ptr): Remove.
10136 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
10138 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10140 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
10142 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
10144 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10146 * tracepoint.h (struct uploaded_tp): Initialize fields.
10147 <actions, step_actions, cmd_strings>: Change type to
10148 std::vector<char *>.
10149 * tracepoint.c (get_uploaded_tp): Allocate with new.
10150 (free_uploaded_tps): Free with delete.
10151 (parse_tracepoint_definition): Adjust to std::vector change.
10152 * breakpoint.c (read_uploaded_action): Likewise.
10153 (create_tracepoint_from_upload): Likewise.
10154 * ctf.c (ctf_write_uploaded_tp): Likewise.
10155 (SET_ARRAY_FIELD): Likewise.
10156 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
10158 2018-03-30 Tom Tromey <tom@tromey.com>
10160 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
10162 (svr4_keep_data_in_core): Update.
10163 (svr4_read_so_list): Update.
10165 2018-03-30 Tom Tromey <tom@tromey.com>
10167 * windows-nat.c (handle_output_debug_string, handle_exception):
10169 * target.h (target_read_string): Update.
10170 * target.c (target_read_string): Change "string" to
10171 unique_xmalloc_ptr.
10172 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
10174 * solib-frv.c (frv_current_sos): Update.
10175 * solib-dsbt.c (dsbt_current_sos): Update.
10176 * solib-darwin.c (darwin_current_sos): Update.
10177 * linux-thread-db.c (inferior_has_bug): Update.
10178 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
10179 Update. Remove alloca.
10180 * ada-lang.c (ada_main_name): Update.
10182 2018-03-30 Tom Tromey <tom@tromey.com>
10184 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
10185 (struct dwo_file_deleter): New.
10186 (dwo_file_up): New typedef.
10187 (open_and_init_dwo_file): Use dwo_file_up.
10188 (free_dwo_file_cleanup): Remove.
10190 2018-03-30 Tom Tromey <tom@tromey.com>
10192 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
10193 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
10195 2018-03-30 Tom Tromey <tom@tromey.com>
10197 * dwarf2read.c (class free_cached_comp_units): New class.
10198 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
10199 (free_cached_comp_units): Remove function.
10201 2018-03-30 Tom Tromey <tom@tromey.com>
10203 * utils.h (make_cleanup_unpush_target): Remove.
10204 * inf-ptrace.c (struct target_unpusher): New.
10205 (target_unpush_up) New typedef.
10206 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
10208 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
10210 2018-03-27 Tom Tromey <tom@tromey.com>
10212 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
10214 2018-03-27 Pedro Alves <palves@redhat.com>
10215 Tom Tromey <tom@tromey.com>
10217 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
10218 destructor. Now a class.
10219 (gdb_readline_wrapper_cleanup): Remove function.
10220 (gdb_readline_wrapper): Remove cleanups.
10222 2018-03-27 Tom Tromey <tom@tromey.com>
10224 * typeprint.h (struct type_print_options) <local_typedefs,
10225 global_typedefs>: Remove "struct" keyword.
10226 (class typedef_hash_table): New class.
10227 (recursively_update_typedef_hash, add_template_parameters)
10228 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
10229 (find_typedef_in_hash): Don't declare.
10230 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
10231 (typedef_hash_table::recursively_update): Rename from
10232 recursively_update_typedef_hash. Now a member.
10233 (typedef_hash_table::add_template_parameters): Rename from
10234 add_template_parameters. Now a member.
10235 (typedef_hash_table::typedef_hash_table): Now a constructor;
10236 rename from create_typedef_hash.
10237 (typedef_hash_table::~typedef_hash_table): Now a destructor;
10238 rename from free_typedef_hash.
10239 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
10240 (do_free_global_table): Remove.
10241 (typedef_hash_table::typedef_hash_table): New constructor; renamed
10242 from copy_type_recursive.
10243 (create_global_typedef_table): Remove.
10244 (typedef_hash_table::find_global_typedef): Now a member of
10245 typedef_hash_table.
10246 (typedef_hash_table::find_typedef): Rename from
10247 find_typedef_in_hash; now a member.
10248 (whatis_exp): Update.
10249 * extension.h (struct ext_lang_type_printers): Add constructor and
10251 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
10253 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
10254 Now a constructor; rename from start_ext_lang_type_printers.
10255 (ext_lang_type_printers): Now a destructor; rename from
10256 free_ext_lang_type_printers.
10257 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
10259 (c_type_print_base_struct_union): Update. Remove cleanups.
10261 2018-03-27 Tom Tromey <tom@tromey.com>
10263 * dwarf-index-write.c: Include <cmath>.
10265 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10267 * NEWS: Add entry describing new "set|show varsize-limit" command.
10268 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
10270 * printcmd.c (_initialize_printcmd): Add "set var" alias of
10273 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
10275 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
10276 dwarf-index-write.c
10277 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
10278 * dwarf-index-common.c: New file.
10279 * dwarf-index-common.h: New file.
10280 * dwarf-index-write.c: New file.
10281 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
10282 (struct dwarf2_section_info): Move from here.
10283 (dwarf2_section_info_def): Likewise.
10284 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
10285 (offset_type): Likewise.
10286 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
10287 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
10288 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
10289 (byte_swap): Likewise.
10290 (MAYBE_SWAP): Likewise.
10291 (dwarf2_per_cu_ptr): Likewise.
10292 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
10293 (struct tu_stats): Likewise.
10294 (struct dwarf2_per_objfile): Likewise.
10295 (struct dwarf2_per_cu_data): Likewise.
10296 (struct signatured_type): Likewise.
10297 (sig_type_ptr): Likewise.
10298 (DEF_VEC_P (sig_type_ptr)): Likewise.
10299 (INDEX4_SUFFIX): Likewise.
10300 (INDEX5_SUFFIX): Likewise.
10301 (DEBUG_STR_SUFFIX): Likewise.
10302 (dwarf2_read_section): Make non-static.
10303 (mapped_index_string_hash): Move from here.
10304 (dwarf5_djb_hash): Likewise.
10305 (file_write): Likewise.
10306 (class data_buf): Likewise.
10307 (struct symtab_index_entry): Likewise.
10308 (struct mapped_symtab): Likewise.
10309 (find_slot): Likewise.
10310 (hash_expand): Likewise.
10311 (add_index_entry): Likewise.
10312 (uniquify_cu_indices): Likewise.
10313 (class c_str_view): Likewise.
10314 (class c_str_view_hasher): Likewise.
10315 (class vector_hasher): Likewise.
10316 (write_hash_table): Likewise.
10317 (psym_index_map): Likewise.
10318 (struct addrmap_index_data): Likewise.
10319 (add_address_entry): Likewise.
10320 (add_address_entry_worker): Likewise.
10321 (write_address_map): Likewise.
10322 (symbol_kind): Likewise.
10323 (write_psymbols): Likewise.
10324 (struct signatured_type_index_data): Likewise.
10325 (write_one_signatured_type): Likewise.
10326 (recursively_count_psymbols): Likewise.
10327 (recursively_write_psymbols): Likewise.
10328 (class debug_names): Likewise.
10329 (check_dwarf64_offsets): Likewise.
10330 (psyms_seen_size): Likewise.
10331 (write_gdbindex): Likewise.
10332 (write_debug_names): Likewise.
10333 (assert_file_size): Likewise.
10334 (write_psymtabs_to_index): Likewise.
10335 (save_gdb_index_command): Likewise.
10336 (_initialize_dwarf2_read): Don't register the "save gdb-index"
10338 * dwarf2read.h: New file.
10340 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10343 * dwarf2read.c (dwarf2_physname): Do not return the demangled
10344 symbol name if the CU's language stores symbol names in linkage
10346 * language.h (struct language_defn)
10347 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
10348 all instances of this struct.
10350 2018-03-26 Tom Tromey <tom@tromey.com>
10352 * stack.c (backtrace_command_1): Remove verbose code.
10354 2018-03-26 Tom Tromey <tom@tromey.com>
10356 * python/py-framefilter.c (py_print_type): Don't catch
10357 exceptions. Return void.
10358 (py_print_value): Likewise.
10359 (py_print_single_arg): Likewise.
10360 (enumerate_args): Don't catch exceptions.
10361 (py_print_args): Likewise.
10362 (py_print_frame): Likewise.
10363 (gdbpy_apply_frame_filter): Catch exceptions here.
10365 2018-03-26 Tom Tromey <tom@tromey.com>
10367 * stack.c (_initialize_stack): Remove trailing newlines from help
10368 text. Add "Usage" line to "backtrace" help.
10370 2018-03-26 Tom Tromey <tom@tromey.com>
10373 * python/py-framefilter.c (py_print_args): Call wrap_hint.
10375 2018-03-26 Tom Tromey <tom@tromey.com>
10377 * python/py-framefilter.c (py_print_single_arg): Return
10378 EXT_LANG_BT_ERROR from catch.
10380 2018-03-26 Tom Tromey <tom@tromey.com>
10382 PR backtrace/15584:
10383 * stack.c (backtrace_command_1): Move some code into no-filters
10386 2018-03-26 Tom Tromey <tom@tromey.com>
10388 * python/py-framefilter.c (throw_quit_or_print_exception): New
10390 (gdbpy_apply_frame_filter): Use it.
10392 2018-03-26 Tom Tromey <tom@tromey.com>
10395 * python/py-framefilter.c (py_print_type, py_print_value)
10396 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
10399 2018-03-26 Tom Tromey <tom@tromey.com>
10401 * python/py-framefilter.c (enumerate_args): Use
10402 gdb::unique_xmalloc_ptr.
10404 2018-03-26 Tom Tromey <tom@tromey.com>
10406 * python/py-framefilter.c (py_print_frame): Return
10408 (gdbpy_apply_frame_filter): Update comment.
10409 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
10411 <EXT_LANG_BT_NO_FILTERS>: Change value.
10413 2018-03-26 Tom Tromey <tom@tromey.com>
10415 PR backtrace/15582:
10416 * stack.c (backtrace_command): Parse "hide" argument.
10417 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
10418 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
10421 2018-03-26 Tom Tromey <tom@tromey.com>
10423 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
10425 (backtrace_command): Remove "fulltrace", add "flags".
10427 2018-03-26 Tom Tromey <tom@tromey.com>
10429 * stack.c (backtrace_command): Rewrite command line parsing.
10431 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10433 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
10435 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10437 * filename-seen-cache.h: Add include guard.
10439 2018-03-26 Keith Seitz <keiths@redhat.com>
10441 * symfile.c (place_section): Remove "struct" from section_addr_info
10443 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
10444 "struct" keyword from section_addr_info.
10446 2018-03-26 Alan Hayward <alan.hayward@arm.com>
10448 * regformats/regdef.h (reg): Add constructors.
10450 2018-03-25 Pedro Alves <palves@redhat.com>
10452 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
10453 if then/else bodies in var_func_name extraction.
10455 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
10457 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
10458 lookup_minimal_symbol() to find symbol entry.
10459 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
10461 2018-03-23 Keith Seitz <keiths@redhat.com>
10464 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
10465 nested type definitions for C++, too.
10467 2018-03-23 Tom Tromey <tom@tromey.com>
10469 * machoread.c (struct oso_el): Add a constructor. Don't define as
10471 (macho_register_oso): Remove.
10472 (macho_symtab_read): Take a std::vector.
10473 (oso_el_compare_name): Now a std::sort comparator.
10474 (macho_symfile_read_all_oso): Take a std::vector.
10475 (macho_symfile_read): Use std::vector. Remove cleanups.
10477 2018-03-22 Tom Tromey <tom@tromey.com>
10479 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
10480 (record_full_goto_bookmark): Use std::string.
10482 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10485 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
10488 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10490 * rs6000-tdep.c (store_insn_p): New function.
10491 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
10492 and cr_reg to their unshifted values. Use store_insn_p to
10493 match LR saves using either R1 or fdata->alloca_reg. Use
10494 store_insn_p to match CR saves. Set alloca_reg_offset
10495 when alloca_reg and framep are set. Remove lr_reg shift
10496 when assigning to fdata->lr_register.
10498 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
10500 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
10501 command line args instead of emitting a warning.
10503 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10505 * tracepoint.h (struct static_tracepoint_marker): Initialize
10506 fields, define default constructor, move constructor and move
10507 assignment, disable the rest.
10508 <str_id, extra>: Make std::string.
10509 (release_static_tracepoint_marker): Remove.
10510 (free_current_marker): Remove.
10511 * tracepoint.c (free_current_marker): Remove.
10512 (parse_static_tracepoint_marker_definition): Adjust to
10513 std::string, use new hex2str overload.
10514 (release_static_tracepoint_marker): Remove.
10515 (print_one_static_tracepoint_marker): Get marker by reference
10516 and adjust to std::string.
10517 (info_static_tracepoint_markers_command): Adjust to std::vector
10519 * target.h (static_tracepoint_marker_p): Remove typedef.
10520 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
10521 (struct target_ops) <to_static_tracepoint_marker_at>: Return
10523 <to_static_tracepoint_markers_by_strid>: Return std::vector.
10525 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
10526 (target_debug_print_std_vector_static_tracepoint_marker): New.
10527 (target_debug_print_struct_static_tracepoint_marker_p): Rename
10529 (target_debug_print_static_tracepoint_marker_p): ... this.
10530 * target-delegates.c: Re-generate.
10531 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
10533 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
10534 (decode_static_tracepoint_spec): Adjust to std::vector.
10535 (tracepoint_print_one_detail): Adjust to std::string.
10536 (strace_marker_decode_location): Adjust to std::string.
10537 (update_static_tracepoint): Adjust to std::string, remove call
10538 to release_static_tracepoint_marker.
10539 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
10540 Adjust to std::vector.
10541 * remote.c (remote_static_tracepoint_marker_at): Return bool.
10542 (remote_static_tracepoint_markers_by_strid): Adjust to
10544 * common/rsp-low.h (hex2str): New overload with explicit count
10546 * common/rsp-low.c (hex2str): New overload with explicit count
10548 * unittests/rsp-low-selftests.c (test_hex2str): New function.
10549 (_initialize_rsp_low_selftests): Add test_hex2str test.
10550 * unittests/tracepoint-selftests.c
10551 (test_parse_static_tracepoint_marker_definition): Adjust to
10554 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10556 * tracepoint.c (parse_static_tracepoint_marker_definition):
10557 Consider case where the definition is followed by more
10559 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10560 tracepoint-selftests.c.
10561 * unittests/tracepoint-selftests.c: New.
10563 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10565 * MAINTAINERS (Write After Approval): Add Pedro Franco de
10568 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10570 * symtab.c (find_pc_sect_line): fixed indentation.
10572 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10574 * symtab.c (find_pc_sect_line): now uses binary search.
10576 2018-03-19 Tom Tromey <tom@tromey.com>
10578 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
10579 "IDENT" production.
10581 2018-03-19 Pedro Alves <palves@redhat.com>
10582 Tom Tromey <tom@tromey.com>
10584 * unittests/observable-selftests.c: New file.
10585 * common/observable.h: New file.
10586 * observable.h: New file.
10587 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
10588 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
10589 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
10590 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
10591 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
10592 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
10593 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
10594 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
10595 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
10596 python/py-breakpoint.c, python/py-finishbreakpoint.c,
10597 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
10598 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
10599 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
10600 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
10601 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
10602 tui/tui-interp.c, valops.c: Update all users.
10603 * tui/tui-hooks.c (tui_bp_created_observer)
10604 (tui_bp_deleted_observer, tui_bp_modified_observer)
10605 (tui_inferior_exit_observer, tui_before_prompt_observer)
10606 (tui_normal_stop_observer, tui_register_changed_observer):
10608 (tui_observers_token): New global.
10609 (attach_or_detach, tui_attach_detach_observers): New functions.
10610 (tui_install_hooks, tui_remove_hooks): Use
10611 tui_attach_detach_observers.
10612 * record-btrace.c (record_btrace_thread_observer): Remove.
10613 (record_btrace_thread_observer_token): New global.
10614 * observer.sh: Remove.
10615 * observer.c: Rename to observable.c.
10616 * observable.c (namespace gdb_observers): Define new objects.
10617 (observer_debug): Move into gdb_observers namespace.
10618 (struct observer, struct observer_list, xalloc_observer_list_node)
10619 (xfree_observer_list_node, generic_observer_attach)
10620 (generic_observer_detach, generic_observer_notify): Remove.
10621 (_initialize_observer): Update.
10622 Don't include observer.inc.
10623 * Makefile.in (generated_files): Remove observer.h, observer.inc.
10624 (clean mostlyclean): Likewise.
10625 (observer.h, observer.inc): Remove targets.
10626 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
10627 (COMMON_SFILES): Use observable.c, not observer.c.
10628 * .gitignore: Remove observer.h.
10630 2018-03-18 Tom Tromey <tom@tromey.com>
10632 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
10634 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
10636 2018-03-17 Tom Tromey <tom@tromey.com>
10638 * auto-load.c (auto_load_objfile_script_1): Use std::string.
10640 2018-03-17 Tom Tromey <tom@tromey.com>
10642 * target.c (class scoped_target_fd): New.
10643 (target_fileio_close_cleanup): Remove.
10644 (target_fileio_read_alloc_1): Use scoped_target_fd.
10646 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
10648 * silent-rules.mk: New.
10649 * Makefile.in: Include silent-rules.mk
10650 (srcdir, VPATH, top_srcdir): Move up.
10651 (COMPILE): Add ECHO_CXX.
10652 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
10653 (init.c): Add ECHO_INIT_C.
10654 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
10655 (version.c): Add ECHO_GEN.
10656 (printcmd.o): Add ECHO_CXX.
10657 (target-float.o): Add ECHO_CXX.
10658 (ada-exp.o): Add ECHO_CXX.
10659 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
10660 (insight$(EXEEXT)): Add ECHO_CXXLD.
10661 * gnulib/configure.ac: Add AM_SILENT_RULES.
10662 * gnulib/aclocal.m4: Re-generate.
10663 * gnulib/configure: Re-generate.
10664 * gnulib/import/Makefile.in: Re-generate.
10666 2018-03-16 Tom Tromey <tom@tromey.com>
10668 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
10669 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
10670 * utils.c (do_free_section_addr_info)
10671 (make_cleanup_free_section_addr_info): Remove.
10672 * symfile.h (struct other_sections): Add constructor.
10673 (struct section_addr_info): Remove.
10674 (section_addr_info): New typedef.
10675 (struct sym_fns) <sym_offsets>: Change type of parameter.
10676 (build_section_addr_info_from_objfile)
10677 (relative_addr_info_to_section_offsets, addr_info_make_relative)
10678 (default_symfile_offsets, symbol_file_add)
10679 (symbol_file_add_from_bfd)
10680 (build_section_addr_info_from_section_table): Update.
10681 (alloc_section_addr_info, free_section_addr_info): Don't declare.
10682 * symfile.c (alloc_section_addr_info): Remove.
10683 (build_section_addr_info_from_section_table): Change return type.
10685 (build_section_addr_info_from_bfd)
10686 (build_section_addr_info_from_objfile): Likewise.
10687 (free_section_addr_info): Remove.
10688 (relative_addr_info_to_section_offsets): Change type of "addrs".
10689 (addrs_section_compar): Now a std::sort comparator.
10690 (addrs_section_sort): Change return type.
10691 (addr_info_make_relative): Change type of "addrs". Update.
10692 (default_symfile_offsets, syms_from_objfile_1)
10693 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
10694 (symbol_file_add_separate): Update.
10695 (symbol_file_add): Change type of "addrs". Update.
10696 (add_symbol_file_command): Update. Remove cleanups.
10697 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
10699 * symfile-debug.c (debug_sym_offsets): Change type of "info".
10700 * solib.c (solib_read_symbols): Update.
10701 * objfiles.c (objfile_relocate): Update. Remove cleanups.
10702 * machoread.c (macho_symfile_offsets): Update.
10703 * jit.c (jit_bfd_try_read_symtab): Update.
10705 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
10707 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10708 unittests/utils-selftests.c.
10709 * unittests/utils-selftests.c: New file.
10711 2018-03-14 Tom Tromey <tom@tromey.com>
10714 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
10717 2018-03-14 Tom Tromey <tom@tromey.com>
10720 * printcmd.c (printf_pointer): Allow "-" in format.
10722 2018-03-14 Tom Tromey <tom@tromey.com>
10724 * printcmd.c (_initialize_printcmd): Add usage to printf.
10726 2018-03-14 Yao Qi <qiyao@sourceware.org>
10728 * MAINTAINERS: Update my email address.
10730 2018-03-13 Tom Tromey <tom@tromey.com>
10732 * machoread.c (macho_check_dsym): Change filenamep to a
10734 (macho_symfile_read): Update.
10735 * symfile.c (load_command): Use std::string.
10737 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
10739 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
10740 to error message string.
10741 (riscv_register_name): Use xsnprintf instead of sprintf.
10742 (riscv_insn::fetch_instruction): Use gdb_assert instead of
10744 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
10746 (riscv_push_dummy_call): Likewise.
10748 2018-03-12 Tom Tromey <tom@tromey.com>
10750 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
10751 Use gdb::byte_vector.
10752 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
10754 2018-03-12 Yao Qi <yao.qi@linaro.org>
10756 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
10757 parameter type to readable_regcache.
10758 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
10761 2018-03-11 Tom Tromey <tom@tromey.com>
10763 * dwarf2read.c (struct nextfield): Add initializers.
10764 (struct nextfnfield): Remove.
10765 (struct fnfieldlist): Add initializers. Remove "length" and
10766 "head", use std::vector.
10767 (struct decl_field_list): Remove.
10768 (struct field_info): Add initializers.
10769 <fields, baseclasses>: Now std::vector.
10770 <nbaseclasses, nfnfields, typedef_field_list_count,
10771 nested_types_list_count>: Remove.
10772 (dwarf2_add_field, dwarf2_add_type_defn)
10773 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
10774 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
10775 (process_structure_scope): Update.
10777 2018-03-11 Tom Tromey <tom@tromey.com>
10779 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
10780 for use by std::sort.
10781 (build_type_psymtabs_1): Use std::vector.
10783 2018-03-09 Eli Zaretskii <eliz@gnu.org>
10785 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
10786 and LIBMPFR in the printed configuration.
10788 2018-03-08 Tom Tromey <tom@tromey.com>
10790 * source.c (get_filename_and_charpos): Use scoped_fd.
10791 * nto-procfs.c (procfs_open_1): Use scoped_fd.
10792 (procfs_pidlist): Likewise.
10793 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
10794 (iterate_over_mappings): Likewise.
10796 2018-03-08 Tom Tromey <tom@tromey.com>
10798 * infcall.c (struct call_return_meta_info)
10799 <stack_temporaries_enabled>: Remove.
10800 (get_call_return_value, call_function_by_hand_dummy): Update.
10801 * thread.c (disable_thread_stack_temporaries): Remove.
10802 (enable_thread_stack_temporaries): Remove.
10803 (thread_stack_temporaries_enabled_p): Return bool.
10804 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
10805 (get_last_thread_stack_temporary): Update.
10806 * eval.c (evaluate_subexp): Update.
10807 * gdbthread.h (class enable_thread_stack_temporaries): Now a
10808 class, not a function.
10809 (value_ptr, value_vec): Remove typedefs.
10810 (class thread_info) <stack_temporaries_enabled>: Now bool.
10811 <stack_temporaries>: Now a std::vector.
10812 (thread_stack_temporaries_enabled_p)
10813 (value_in_thread_stack_temporaries): Return bool.
10815 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
10817 * remote.c (putpkt_binary): Fix omitted bytes reporting.
10818 (getpkt_or_notif_sane_1): Likewise.
10820 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10822 * build-id.c (build_id_to_debug_bfd): Use std::string.
10824 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10826 * build-id.c (find_separate_debug_file_by_buildid): Return
10828 * build-id.h (find_separate_debug_file_by_buildid): Return
10830 * coffread.c (coff_symfile_read): Adjust to std::string.
10831 * elfread.c (elf_symfile_read): Adjust to std::string.
10832 * symfile.c (separate_debug_file_exists): Change parameter to
10834 (find_separate_debug_file): Return std::string.
10835 (find_separate_debug_file_by_debuglink): Return std::string.
10836 * symfile.h (find_separate_debug_file_by_debuglink): Return
10839 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10841 * common/xml-utils.c (xml_escape_text): Move code to...
10842 (xml_escape_text_append): ... this new function.
10843 * common/xml-utils.h (xml_escape_text_append): New declaration.
10844 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
10846 (_initialize_xml_utils): register test_xml_escape_text_append as
10849 2018-03-07 Alan Hayward <alan.hayward@arm.com>
10851 * defs.h: Remove MAX_REGISTER_SIZE.
10852 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
10854 * python/py-unwind.c (pyuw_sniffer): Likewise.
10856 2018-03-07 Tom Tromey <tom@tromey.com>
10858 * linux-tdep.c (linux_info_proc): Update.
10859 * target.h (struct target_ops) <to_fileio_readlink>: Return
10861 (target_fileio_readlink): Return optional<string>.
10862 * remote.c (remote_hostio_readlink): Return optional<string>.
10863 * inf-child.c (inf_child_fileio_readlink): Return
10865 * target.c (target_fileio_readlink): Return optional<string>.
10867 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
10869 * regcache.c (cooked_read_test): Add riscv to the list of
10870 architectures that have a save_reggroup.
10872 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
10874 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
10875 value is not a dynamic class object.
10877 2018-03-06 Tom Tromey <tom@tromey.com>
10879 * rust-exp.y: Formatting fixes.
10881 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10883 * riscv-tdep.c (riscv_register_name): Remove target description
10885 (riscv_gdbarch_init): Remove target description check.
10887 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10889 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
10891 * riscv-tdep.h: Likewise.
10893 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10895 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
10896 (riscv_pseudo_register_write): Delete.
10897 (riscv_gdbarch_init): Remove all use of pseudo registers.
10899 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10901 * record-btrace.c (btrace_print_lines): Replace cleanup
10902 parameter with RAII equivalents.
10903 (btrace_insn_history): Replace cleanup with RAII equivalents.
10904 * ui-out.h (make_cleanup_ui_out_list_begin_end,
10905 make_cleanup_ui_out_tuple_begin_end): Remove.
10906 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
10907 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
10908 make_cleanup_ui_out_list_begin_end): Remove.
10910 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10912 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
10913 parameter types to std::vector. Use bool.
10914 (record_btrace_wait): Replace VEC(tp_t) with
10915 std::vector<thread_info *>.
10916 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
10918 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10920 * record-btrace.c (record_btrace_disable_callback): Remove.
10921 (struct scoped_btrace_disable): New.
10922 (record_btrace_open): Use scoped_btrace_disable.
10924 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10926 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
10927 reading values from registers.
10929 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10931 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
10934 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10936 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
10937 change parameter type. Use GDB's print functions, and use
10938 core_addr_to_string where appropriate.
10939 (riscv_push_dummy_call): Use core_addr_to_string where
10940 appropriate, update call to riscv_print_arg_location, and reindent
10942 (riscv_return_value): Update call to riscv_print_arg_location.
10944 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10945 Tim Newsome <tim@sifive.com>
10946 Albert Ou <a0u@eecs.berkeley.edu>
10947 Darius Rad <darius@bluespec.com>
10949 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
10950 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
10951 (ALLDEPFILES): Add riscv-tdep.c
10952 * configure.tgt: Add riscv support.
10953 * riscv-tdep.c: New file.
10954 * riscv-tdep.h: New file.
10955 * NEWS: Mention new target.
10956 * MAINTAINERS: Add entry for riscv.
10958 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10960 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
10961 fields within aggregates.
10963 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
10965 * record-btrace.c (btrace_print_lines): Change type of flags to
10966 gdb_disassembly_flags.
10968 2018-03-04 John Baldwin <jhb@FreeBSD.org>
10970 * fbsd-nat.c: Include "inf-ptrace.h".
10971 (USE_SIGTRAP_SIGINFO): Conditionally define.
10972 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
10973 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
10974 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
10976 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
10978 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
10980 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
10981 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
10982 "supports_stopped_by_hw_breakpoint" target methods.
10984 2018-03-04 John Baldwin <jhb@FreeBSD.org>
10986 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
10987 * fbsd-nat.c (debug_fbsd_nat): New variable.
10988 (show_fbsd_nat_debug): New function.
10989 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
10990 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
10992 2018-03-04 John Baldwin <jhb@FreeBSD.org>
10994 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
10995 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
10997 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
10998 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
11001 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11003 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
11004 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
11006 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11008 * charset.c (struct charset_vector): New.
11009 (charsets): Change type to charset_vector.
11010 (find_charset_names): Adjust.
11012 (_initialize_charset): Adjust.
11014 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11016 * progspace.h (struct program_space) <deleted_solibs>: Change
11017 type to std::vector<std::string>.
11018 * progspace.c (clear_program_space_solib_cache): Adjust.
11019 * breakpoint.c (print_solib_event): Adjust.
11020 (check_status_catch_solib): Adjust.
11021 * solib.c (update_solib_list): Adjust.
11022 * ui-out.h (class ui_out) <field_string>: New overload.
11023 * ui-out.c (ui_out::field_string): New overload.
11025 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11027 * progspace.h (struct program_space): Add constructor and
11028 destructor, initialize fields.
11029 (add_program_space): Remove.
11030 * progspace.c (add_program_space): Rename to...
11031 (program_space::program_space): ... this.
11032 (release_program_space): Rename to...
11033 (program_space::~program_space): ... this.
11034 (delete_program_space): Use delete to delete program_space.
11035 (initialize_progspace): Use new to allocate program_space.
11036 * inferior.c (add_inferior_with_spaces): Likewise.
11037 (clone_inferior_command): Likewise.
11038 * infrun.c (follow_fork_inferior): Likewise.
11039 (handle_vfork_child_exec_or_exit): Likewise.
11041 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11043 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
11044 (delim_string_to_char_ptr_vec): Return std::vector of
11045 gdb::unique_xmalloc_ptr.
11046 (dirnames_to_char_ptr_vec_append): Take std::vector of
11047 gdb::unique_xmalloc_ptr.
11048 (dirnames_to_char_ptr_vec): Return std::vector of
11049 gdb::unique_xmalloc_ptr.
11050 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
11051 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
11052 (delim_string_to_char_ptr_vec): Return an std::vector of
11053 gdb::unique_xmalloc_ptr, adjust the code.
11054 (dirnames_to_char_ptr_vec_append): Take an std::vector of
11055 gdb::unique_xmalloc_ptr, adjust the code.
11056 (dirnames_to_char_ptr_vec): Return an std::vector of
11057 gdb::unique_xmalloc_ptr, adjust the code.
11058 * auto-load.c (auto_load_safe_path_vec): Change type to
11059 std::vector of gdb::unique_xmalloc_ptr.
11060 (auto_load_expand_dir_vars): Return an std::vector of
11061 gdb::unique_xmalloc_ptr, adjust the code.
11062 (auto_load_safe_path_vec_update): Adjust.
11063 (filename_is_in_auto_load_safe_path_vec): Adjust.
11064 (auto_load_objfile_script_1): Adjust.
11065 * build-id.c (build_id_to_debug_bfd): Adjust.
11066 * linux-thread-db.c (thread_db_load_search): Adjust.
11067 * source.c (add_path): Adjust.
11069 * symfile.c (find_separate_debug_file): Adjust.
11070 * utils.c (do_free_char_ptr_vec): Remove.
11071 (make_cleanup_free_char_ptr_vec): Remove.
11073 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
11076 * common/pathstuff.c: Conditionally include "<windows.h>".
11078 2018-03-01 Georg Sauthoff <mail@georg.so>
11081 * gcore.in: Quote variables and switch interpreter to bash.
11083 2018-03-01 Tom Tromey <tom@tromey.com>
11085 * dwarf2read.c (alloc_discriminant_info): Fix default_index
11086 assertion. Add assertion for discriminant_index.
11087 (quirk_rust_enum): Use correct base type name in univariant case.
11089 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
11091 * record.c (get_call_history_modifiers): Return a
11092 record_print_flags.
11093 (cmd_record_call_history): Adjust.
11094 * record-btrace.c (record_btrace_call_history): Adjust.
11095 (record_btrace_call_history_range): Adjust.
11096 (record_btrace_call_history_from): Adjust.
11097 * target-debug.h (target_debug_print_record_print_flags): New.
11098 * target-delegates.c: Re-generate.
11099 * target.c (target_call_history): Change flags type.
11100 (target_call_history_from): Likewise.
11101 (target_call_history_range): Likewise.
11102 * target.h (struct target_ops) <target_call_history>: Likewise.
11103 (target_call_history_from): Likewise.
11104 (target_call_history_range): Likewise.
11106 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11107 Simon Marchi <simon.marchi@polymtl.ca>
11109 * common/common-utils.c: Include "sys/stat.h".
11110 (is_regular_file): Move here from "source.c"; change return
11112 * common/common-utils.h (is_regular_file): New prototype.
11113 * common/pathstuff.c (contains_dir_separator): New function.
11114 * common/pathstuff.h (contains_dir_separator): New prototype.
11115 * source.c: Don't include "sys/stat.h".
11116 (is_regular_file): Move to "common/common-utils.c".
11118 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11120 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
11121 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
11122 * auto-load.c: Include "common/pathstuff.h".
11123 * common/common-def.h (current_directory): Move here.
11124 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
11126 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
11128 * common/pathstuff.c: New file.
11129 * common/pathstuff.h: New file.
11130 * compile/compile.c: Include "common/pathstuff.h".
11131 * defs.h (current_directory): Move to "common/common-defs.h".
11132 * dwarf2read.c: Include "common/pathstuff.h".
11133 * exec.c: Likewise.
11134 * guile/scm-safe-call.c: Likewise.
11135 * linux-thread-db.c: Likewise.
11136 * main.c: Likewise.
11137 * nto-tdep.c: Likewise.
11138 * objfiles.c: Likewise.
11139 * source.c: Likewise.
11140 * symtab.c: Likewise.
11141 * utils.c: Include "common/pathstuff.h".
11142 (gdb_realpath): Move to "common/pathstuff.c".
11143 (gdb_realpath_keepfile): Likewise.
11144 (gdb_abspath): Likewise.
11145 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
11146 (gdb_realpath_keepfile): Likewise.
11147 (gdb_abspath): Likewise.
11149 2018-02-28 John Baldwin <jhb@FreeBSD.org>
11151 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
11152 wildcard process pid for super_resume for kernels with a
11155 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
11157 * compile/compile.c (get_args): Add additional comments
11158 explaining function.
11160 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
11161 Tom Tromey <tom@tromey.com>
11163 * target.h (memory_write_request_s): Remove typedef. Don't define
11165 (target_write_memory_blocks): Change argument to std::vector.
11166 (struct memory_write_request): Add constructor.
11167 * target-memory.c (compare_block_starting_address): Return bool.
11168 Change argument types.
11169 (claim_memory): Change arguments to use std::vector.
11170 (split_regular_and_flash_blocks, blocks_to_erase)
11171 (compute_garbled_blocks): Likewise.
11172 (cleanup_request_data, cleanup_write_requests_vector): Remove.
11173 (target_write_memory_blocks): Change argument to std::vector.
11174 * symfile.c (struct load_section_data): Add constructor and
11175 destructor. Use std::vector for "requests".
11176 (struct load_progress_data): Add initializers.
11177 (load_section_callback): Update. Use "new".
11178 (clear_memory_write_data): Remove.
11179 (generic_load): Update.
11181 2018-02-27 Alan Hayward <alan.hayward@arm.com>
11183 * arch/aarch64.h: Use common/tdesc.h.
11185 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11187 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
11188 architecture with a 64-bit ABI.
11190 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11192 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
11193 ahead of target description loading.
11195 2018-02-26 Tom Tromey <tom@tromey.com>
11197 * stack.c (backtrace_command_1): Update.
11198 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
11200 * python/py-framefilter.c (py_print_frame)
11201 (gdbpy_apply_frame_filter): Change type of "flags".
11202 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
11204 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
11205 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
11206 * extension.h (enum frame_filter_flag): Rename from
11207 frame_filter_flags.
11208 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
11209 (apply_ext_lang_frame_filter): Change type of "flags".
11210 * extension.c (apply_ext_lang_frame_filter): Change type of
11212 * extension-priv.h (struct extension_language_ops)
11213 <apply_frame_filter>: Change type of "flags".
11215 2018-02-26 Tom Tromey <tom@tromey.com>
11218 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
11219 off-by-one in py_end computation.
11220 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
11222 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
11225 2018-02-26 Tom Tromey <tom@tromey.com>
11227 * dwarf2read.c (struct variant_field): New.
11228 (struct nextfield) <variant>: New field.
11229 (dwarf2_add_field): Handle DW_TAG_variant_part.
11230 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
11231 discriminated union.
11232 (read_structure_type): Handle DW_TAG_variant_part.
11233 (handle_struct_member_die): New function, extracted from
11234 process_structure_scope. Handle DW_TAG_variant.
11235 (process_structure_scope): Handle discriminated unions. Call
11236 handle_struct_member_die.
11238 2018-02-26 Tom Tromey <tom@tromey.com>
11240 * rust-lang.h (rust_last_path_segment): Declare.
11241 * rust-lang.c (rust_last_path_segment): Now public. Change
11243 (struct disr_info): Remove.
11244 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
11245 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
11246 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
11247 (rust_enum_p, rust_enum_variant): New function.
11248 (rust_underscore_fields): Remove "offset" parameter.
11249 (rust_print_enum): New function.
11250 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
11251 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
11252 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
11254 (rust_internal_print_type): New function, from rust_print_type.
11256 (rust_print_type): Call rust_internal_print_type.
11257 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
11258 Update enum handling.
11259 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
11260 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
11261 (rust_union_quirks): New functions.
11262 (process_full_comp_unit, process_full_type_unit): Call
11264 (process_structure_scope): Update rust_unions if necessary.
11266 2018-02-26 Tom Tromey <tom@tromey.com>
11268 * value.h (value_union_variant): Declare.
11269 * valops.c (value_union_variant): New function.
11270 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
11271 (struct discriminant_info): New.
11272 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
11274 (struct main_type) <flag_discriminated_union>: New field.
11276 2018-02-26 Tom Tromey <tom@tromey.com>
11278 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11279 unittests/unpack-selftests.c.
11280 * unittests/unpack-selftests.c: New file.
11281 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
11283 2018-02-26 Yao Qi <yao.qi@linaro.org>
11285 * dwarf2read.c (struct partial_die_info) <read>: New method.
11286 (read_partial_die): Remove the declaration.
11287 (load_partial_dies): Update.
11288 (partial_die_info::partial_die_info):
11289 (read_partial_die): Change it to partial_die_info::read.
11291 2018-02-26 Yao Qi <yao.qi@linaro.org>
11293 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
11294 (fixup_partial_die): Remove declaration.
11295 (scan_partial_symbols): Update.
11296 (partial_die_parent_scope): Likewise.
11297 (partial_die_full_name): Likewise.
11298 (fixup_partial_die): Change it to partial_die_info::fixup.
11300 2018-02-26 Yao Qi <yao.qi@linaro.org>
11302 * dwarf2read.c (read_partial_die): Update the declaration.
11303 (load_partial_dies): Caller update.
11304 (read_partial_die): Remove one argument abbrev_len.
11306 2018-02-26 Yao Qi <yao.qi@linaro.org>
11308 * dwarf2read.c (struct partial_die_info): Add ctor, delete
11309 assignment operator.
11310 (load_partial_dies): Use ctor and copy ctor.
11311 (read_partial_die): Update.
11312 (dwarf2_cu::find_partial_die): Use ctor.
11314 2018-02-26 Yao Qi <yao.qi@linaro.org>
11316 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
11317 (find_partial_die_in_comp_unit): Change it to
11318 dwarf2_cu::find_partial_die.
11319 (find_partial_die): Update.
11321 2018-02-26 Yao Qi <yao.qi@linaro.org>
11323 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
11326 2018-02-26 Yao Qi <yao.qi@linaro.org>
11328 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
11330 2018-02-26 Alan Hayward <alan.hayward@arm.com>
11332 * arch/amd64.h: Use common/tdesc.h.
11333 * arch/i386.c: Likewise.
11334 * arch/i386.h: Likewise.
11335 * arch/tic6x.c: Likewise.
11336 * arch/tdesc.h: Move file from here...
11337 * common/tdesc.h: ...to here.
11338 * features/aarch64-core.c: Regenerate.
11339 * features/aarch64-fpu.c: Regenerate.
11340 * features/i386/32bit-avx.c: Regenerate.
11341 * features/i386/32bit-avx512.c: Regenerate.
11342 * features/i386/32bit-core.c: Regenerate.
11343 * features/i386/32bit-linux.c: Regenerate.
11344 * features/i386/32bit-mpx.c: Regenerate.
11345 * features/i386/32bit-pkeys.c: Regenerate.
11346 * features/i386/32bit-sse.c: Regenerate.
11347 * features/i386/64bit-avx.c: Regenerate.
11348 * features/i386/64bit-avx512.c: Regenerate.
11349 * features/i386/64bit-core.c: Regenerate.
11350 * features/i386/64bit-linux.c: Regenerate.
11351 * features/i386/64bit-mpx.c: Regenerate.
11352 * features/i386/64bit-pkeys.c: Regenerate.
11353 * features/i386/64bit-segments.c: Regenerate.
11354 * features/i386/64bit-sse.c: Regenerate.
11355 * features/i386/x32-core.c: Regenerate.
11356 * features/tic6x-c6xp.c: Regenerate.
11357 * features/tic6x-core.c: Regenerate.
11358 * features/tic6x-gp.c: Regenerate.
11359 * target-descriptions.c: Use common/tdesc.h.
11360 * target-descriptions.h: Likewise.
11362 2018-02-24 Tom Tromey <tom@tromey.com>
11364 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
11365 (try_thread_db_load_from_dir, thread_db_load_search): Use
11367 (info_auto_load_libthread_db_compare): Return bool. Change
11369 (info_auto_load_libthread_db): Use std::vector, std::string.
11372 2018-02-24 Tom Tromey <tom@tromey.com>
11374 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
11376 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
11378 * gdbarch.c: Rebuild.
11379 * gdbarch.h: Rebuild.
11380 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
11381 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
11382 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
11385 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
11387 * gdbtypes.h (sect_offset): Change type to uint64_t.
11388 (sect_offset_str): New function.
11389 * dwarf2read.c (create_addrmap_from_aranges): Use
11391 (error_check_comp_unit_head): Likewise.
11392 (create_debug_type_hash_table): Likewise.
11393 (read_cutu_die_from_dwo): Likewise.
11394 (init_cutu_and_read_dies): Likewise.
11395 (init_cutu_and_read_dies_no_follow): Likewise.
11396 (process_psymtab_comp_unit_reader): Likewise.
11397 (partial_die_parent_scope): Likewise.
11398 (peek_die_abbrev): Likewise.
11399 (process_queue): Likewise.
11400 (dwarf2_physname): Likewise.
11401 (read_namespace_alias): Likewise.
11402 (read_import_statement): Likewise.
11403 (create_dwo_cu_reader): Likewise.
11404 (create_cus_hash_table): Likewise.
11405 (lookup_dwo_cutu): Likewise.
11406 (inherit_abstract_dies): Likewise.
11407 (read_func_scope): Likewise.
11408 (read_call_site_scope): Likewise.
11409 (dwarf2_add_member_fn): Likewise.
11410 (read_common_block): Likewise.
11411 (read_module_type): Likewise.
11412 (read_typedef): Likewise.
11413 (read_subrange_type): Likewise.
11414 (load_partial_dies): Likewise.
11415 (read_partial_die): Likewise.
11416 (find_partial_die): Likewise.
11417 (read_str_index): Likewise.
11418 (dwarf2_string_attr): Likewise.
11419 (build_error_marker_type): Likewise.
11420 (lookup_die_type): Likewise.
11421 (dump_die_shallow): Likewise.
11422 (follow_die_ref): Likewise.
11423 (dwarf2_fetch_die_loc_sect_off): Likewise.
11424 (dwarf2_fetch_constant_bytes): Likewise.
11425 (follow_die_sig): Likewise.
11426 (get_signatured_type): Likewise.
11427 (get_DW_AT_signature_type): Likewise.
11428 (dwarf2_find_containing_comp_unit): Likewise.
11429 (set_die_type): Likewise.
11431 2018-02-21 John Baldwin <jhb@FreeBSD.org>
11433 * arch/aarch64.c: Include "common-defs.h".
11434 * arch/amd64.c: Likewise.
11435 * arch/i386.c: Likewise.
11437 2018-02-21 Tom Tromey <tom@tromey.com>
11439 * value.h: (extract_field_op): Update.
11440 * eval.c (extract_field_op): Return a const char *.
11441 * expression.h (parse_expression_for_completion): Update.
11442 * completer.c (complete_expression): Update.
11443 (add_struct_fields): Make fieldname const.
11444 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
11445 (mark_completion_tag, parse_exp_in_context_1): Update.
11446 (parse_expression_for_completion): Change "name" to
11447 unique_xmalloc_ptr*.
11449 2018-02-21 Tom Tromey <tom@tromey.com>
11451 * infcall.c (call_function_by_hand_dummy): Use std::vector.
11453 2018-02-21 Yao Qi <yao.qi@linaro.org>
11455 * avr-tdep.c (avr_read_pc): Change parameter type to
11457 * gdbarch.sh (read_pc): Likewise.
11458 * gdbarch.c: Re-generated.
11459 * gdbarch.h: Re-generated.
11460 * hppa-tdep.c (hppa_read_pc): Change parameter type to
11462 * ia64-tdep.c (ia64_read_pc): Likewise.
11463 * mips-tdep.c (mips_read_pc): Likewise.
11464 * spu-tdep.c (spu_read_pc): Likewise.
11466 2018-02-21 Yao Qi <yao.qi@linaro.org>
11468 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
11469 * regcache-dump.c: New file.
11470 * regcache.c: Move register_dump to regcache-dump.c.
11471 (maintenance_print_registers): Likewise.
11472 (maintenance_print_raw_registers): Likewise.
11473 (maintenance_print_cooked_registers): Likewise.
11474 (maintenance_print_register_groups): Likewise.
11475 (maintenance_print_remote_registers): Likewise.
11476 (_initialize_regcache): Likewise.
11477 * regcache.h (register_dump): Moved from regcache.c.
11479 2018-02-21 Yao Qi <yao.qi@linaro.org>
11481 * regcache.c (regcache::regcache): Update.
11482 (regcache::invalidate): Move it to detached_regcache::invalidate.
11483 (get_thread_arch_aspace_regcache): Update.
11484 (regcache::raw_update): Update.
11485 (regcache::cooked_read): Remove some code.
11486 (regcache::cooked_read_value): Likewise.
11487 (regcache::raw_write): Remove assert on m_readonly_p.
11488 (regcache::raw_supply_integer): Move it to
11489 detached_regcache::raw_supply_integer.
11490 (regcache::raw_supply_zeroed): Likewise.
11491 * regcache.h (detached_regcache) <raw_supply_integer>: New
11493 <raw_supply_zeroed, invalidate>: Likewise.
11494 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
11495 <invalidate>: Likewise.
11496 <m_readonly_p>: Removed.
11498 2018-02-21 Yao Qi <yao.qi@linaro.org>
11500 * infcmd.c (get_return_value): Let stop_regs point to
11501 get_current_regcache.
11502 * regcache.c (regcache::regcache): Remove.
11503 (register_dump_reg_buffer): New class.
11504 (regcache_print): Adjust.
11505 * regcache.h (regcache): Remove constructors.
11507 2018-02-21 Yao Qi <yao.qi@linaro.org>
11509 * regcache.c (class register_dump): New class.
11510 (register_dump_regcache, register_dump_none): New class.
11511 (register_dump_remote, register_dump_groups): New class.
11512 (regcache_print): Update.
11513 * regcache.h (regcache_dump_what): Move it to regcache.c.
11514 (regcache) <dump>: Remove.
11516 2018-02-21 Yao Qi <yao.qi@linaro.org>
11518 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
11520 (jit_unwind_reg_set_impl): Call raw_supply.
11521 (jit_frame_sniffer): Use reg_buffer_rw.
11522 * record-full.c (record_full_core_regbuf): Change its type.
11523 (record_full_core_open_1): Use reg_buffer_rw.
11524 (record_full_close): Likewise.
11525 (record_full_core_fetch_registers): Use regcache->raw_supply.
11526 (record_full_core_store_registers): Likewise.
11527 * regcache.c (regcache::get_register_status): Move it to
11529 (regcache_raw_set_cached_value): Remove.
11530 (regcache::raw_set_cached_value): Remove.
11531 (regcache::raw_write): Call raw_supply.
11532 (regcache::raw_supply): Move it to reg_buffer_rw.
11533 * regcache.h (regcache_raw_set_cached_value): Remove.
11534 (reg_buffer_rw): New class.
11536 2018-02-21 Yao Qi <yao.qi@linaro.org>
11538 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
11539 readonly_detached_regcache.
11540 (dummy_frame_prev_register): Use regcache->cooked_read.
11541 * frame.c (frame_save_as_regcache): Change return type.
11542 (frame_pop): Update.
11543 * frame.h (frame_save_as_regcache): Update declaration.
11544 * inferior.h (get_infcall_suspend_state_regcache): Update
11546 * infrun.c (infcall_suspend_state) <registers>: use
11547 readonly_detached_regcache.
11548 (save_infcall_suspend_state): Don't use regcache_dup.
11549 (get_infcall_suspend_state_regcache): Change return type.
11550 * linux-fork.c (struct fork_info) <savedregs>: Change to
11551 readonly_detached_regcache.
11553 (fork_save_infrun_state): Don't use regcache_dup.
11554 (info_checkpoints_command): Adjust.
11555 * mi/mi-main.c (register_changed_p): Update declaration.
11556 (mi_cmd_data_list_changed_registers): Use
11557 readonly_detached_regcache.
11558 (register_changed_p): Change parameter type to
11559 readonly_detached_regcache.
11560 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
11561 readonly_detached_regcache.
11562 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
11563 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
11565 (regcache::save): Move it to reg_buffer.
11566 (regcache::restore): Change parameter type.
11567 (regcache_dup): Remove.
11568 * regcache.h (reg_buffer) <save>: New method.
11569 (readonly_detached_regcache): New class.
11570 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
11571 readonly_detached_regcache.
11572 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
11574 2018-02-21 Yao Qi <yao.qi@linaro.org>
11576 * frame.c (frame_save_as_regcache): Use regcache method save.
11577 (frame_pop): Use regcache method restore.
11578 * infrun.c (restore_infcall_suspend_state): Likewise.
11579 * linux-fork.c (fork_load_infrun_state): Likewise.
11580 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
11582 * regcache.c (regcache_save): Remove.
11583 (regcache::restore): More asserts.
11584 (regcache_cpy): Remove.
11585 * regcache.h (regcache_save): Remove the declaration.
11586 (regcache::restore): Move from private to public.
11587 Remove the friend declaration of regcache_cpy.
11588 (regcache_cpy): Remove declaration.
11590 2018-02-21 Yao Qi <yao.qi@linaro.org>
11592 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
11593 parameter type to 'readable_regcache *'.
11594 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
11595 * arm-tdep.c (arm_neon_quad_read): Likewise.
11596 (arm_pseudo_read): Likewise.
11597 * avr-tdep.c (avr_pseudo_register_read): Likewise.
11598 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
11599 * frv-tdep.c (frv_pseudo_register_read): Likewise.
11600 * gdbarch.c: Re-generated.
11601 * gdbarch.h: Re-generated.
11602 * gdbarch.sh (pseudo_register_read): Change parameter type to
11603 'readable_regcache *'.
11604 (pseudo_register_read_value): Likewise.
11605 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
11606 (h8300_pseudo_register_read): Likewise.
11607 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
11608 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
11609 (i386_pseudo_register_read_into_value): Likewise.
11610 (i386_pseudo_register_read_value): Likewise.
11611 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
11613 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
11614 * m32c-tdep.c (m32c_raw_read): Likewise.
11615 (m32c_read_flg): Likewise.
11616 (m32c_banked_register): Likewise.
11617 (m32c_banked_read): Likewise.
11618 (m32c_sb_read): Likewise.
11619 (m32c_part_read): Likewise.
11620 (m32c_cat_read): Likewise.
11621 (m32c_r3r2r1r0_read): Likewise.
11622 (m32c_pseudo_register_read): Likewise.
11623 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
11624 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
11625 (mep_pseudo_cr64_read): Likewise.
11626 (mep_pseudo_register_read): Likewise.
11627 * mips-tdep.c (mips_pseudo_register_read): Likewise.
11628 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
11629 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
11630 * regcache.c (regcache::raw_read): Move it to readable_regcache.
11631 (regcache::cooked_read): Likewise.
11632 (regcache::cooked_read_value): Likewise.
11633 (regcache_cooked_read_signed):
11634 (regcache::cooked_read): Likewise.
11635 * regcache.h (readable_regcache): New class.
11636 (regcache): Inherit readable_regcache. Move some methods to
11638 * rl78-tdep.c (rl78_pseudo_register_read): Change
11639 parameter type to 'readable_regcache *'.
11640 * rs6000-tdep.c (do_regcache_raw_read): Remove.
11641 (e500_pseudo_register_read): Change parameter type to
11642 'readable_regcache *'.
11643 (dfp_pseudo_register_read): Likewise.
11644 (vsx_pseudo_register_read): Likewise.
11645 (efpr_pseudo_register_read): Likewise.
11646 * s390-tdep.c (s390_pseudo_register_read): Likewise.
11647 * sh-tdep.c (sh_pseudo_register_read): Likewise.
11648 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
11649 (sh64_pseudo_register_read): Likewise.
11650 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
11651 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
11652 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
11653 (spu_pseudo_register_read): Likewise.
11654 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
11655 (xtensa_pseudo_register_read): Likewise.
11657 2018-02-21 Yao Qi <yao.qi@linaro.org>
11659 * regcache.c (regcache::regcache): Call reg_buffer ctor.
11660 (regcache::arch): Move it to reg_buffer::arch.
11661 (regcache::register_buffer): Likewise.
11662 (regcache::assert_regnum): Likewise.
11663 (regcache::num_raw_registers): Likewise.
11664 * regcache.h (reg_buffer): New class.
11665 (regcache): Inherit reg_buffer.
11667 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
11669 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
11670 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
11672 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
11674 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
11676 2018-02-19 Alan Hayward <alan.hayward@arm.com>
11678 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
11679 (SFILES): Remove common/*.c files.
11680 (COMMON_OBS): Remove some *.o files built from common/*.c files.
11681 * common/common.host: Add common reference.
11682 * configure.ac: Likewise.
11683 * configure: Regenerate.
11685 2018-02-16 Yao Qi <yao.qi@linaro.org>
11687 * block.c (block_namespace_info): Inherit allocate_on_obstack.
11688 (block_initialize_namespace): Use new.
11689 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
11690 (dwarf2_free_objfile): Use delete.
11691 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
11692 (copy_type_recursive): Use new.
11693 * gdb_obstack.h (allocate_on_obstack): New.
11695 2018-02-15 Yao Qi <yao.qi@linaro.org>
11698 * inferior.c (exit_inferior_1): Reset inf->control.
11700 2018-02-15 Joel Brobecker <brobecker@adacore.com>
11702 * ada-lang.c (ada_to_fixed_value_create): Delete advance
11705 2018-02-14 Pedro Alves <palves@redhat.com>
11707 * frame-unwind.c (frame_unwind_try_unwinder): Always call
11708 frame_cleanup_after_sniffer on exception.
11710 2018-02-14 Tom Tromey <tom@tromey.com>
11712 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
11714 (solib_bfd_open): Make pathname const.
11715 * solib.c (solib_bfd_open): Make pathname const.
11716 * solib-spu.c (spu_bfd_fopen): Make name const.
11717 (spu_bfd_open): Make pathname const.
11718 * solib-darwin.c (darwin_bfd_open): Make pathname const.
11719 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
11721 2018-02-14 Tom Tromey <tom@tromey.com>
11723 * symfile.c (symfile_bfd_open): Update.
11724 * source.h (openp, source_full_path_of, find_and_open_source):
11725 Change argument type to unique_xmalloc_ptr.
11726 * source.c (openp): Take a unique_xmalloc_ptr.
11727 (source_full_path_of, find_and_open_source): Likewise.
11728 (open_source_file, symtab_to_fullname): Update.
11729 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
11730 unique_xmalloc_ptr.
11731 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
11732 (exec_file_find): Update.
11733 * psymtab.c (psymtab_to_fullname): Update.
11734 * nto-tdep.h (nto_find_and_open_solib): Update.
11735 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
11736 unique_xmalloc_ptr.
11737 * exec.c (exec_file_attach): Update.
11738 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
11739 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
11741 2018-02-14 Tom Tromey <tom@tromey.com>
11743 * solib.c: Include source.h.
11744 * nto-tdep.c: Include source.h.
11745 * mi/mi-cmd-env.c: Include source.h.
11746 * infcmd.c: Include source.h.
11747 * exec.c: Include source.h.
11748 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
11749 (add_path, directory_switch, source_path, init_source_path): Move
11751 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
11752 (add_path, directory_switch, source_path, init_source_path):
11755 2018-02-14 Tom Tromey <tom@tromey.com>
11757 * solist.h (exec_file_find, solib_find): Return
11758 unique_xmalloc_ptr.
11759 (solib_bfd_fopen): Take a const char *.
11760 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
11761 (exec_file_find, solib_find): Likewise.
11762 (solib_bfd_fopen): Do not take ownership of "pathname".
11763 (solib_bfd_open): Use unique_xmalloc_ptr.
11764 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
11765 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
11766 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
11767 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
11769 2018-02-14 Joel Brobecker <brobecker@adacore.com>
11771 * ada-lang.c (name_match_type_from_name): Remove reference to
11772 ada_name_for_lookup in function's documentation.
11773 * ada-lang.h (ada_name_for_lookup): Delete declaration.
11775 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
11777 * defs.h (enum openp_flags): New enum.
11778 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
11779 Move to enum openp_flags.
11780 (openp_flags): New enum flags.
11781 (openp): Change parameter type to openp_flags.
11782 * source.c (openp): Change parameter type to openp_flags.
11783 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
11784 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
11786 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
11788 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
11791 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
11793 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
11795 (class dwarf2_queue_guard): ...the destructor of this new class.
11796 (dw2_do_instantiate_symtab): Create instance of the new class
11797 dwarf2_queue_guard, remove cleanup.
11799 2018-02-09 Tom Tromey <tom@tromey.com>
11801 * source.c (find_source_lines): Don't reference past the end of
11804 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11806 * remote.c (remote_btrace_maybe_reopen): Change error message.
11807 * btrace.c (btrace_enable): Likewise.
11808 (parse_xml_btrace): Likewise.
11809 (parse_xml_btrace_conf): Likewise.
11811 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11813 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
11814 (linux_enable_pt, linux_enable_bts): Call
11815 diagnose_perf_event_open_fail.
11817 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11819 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
11820 Remove parameter and change return type. Update callers. Move it.
11821 (linux_enable_bts, linux_enable_pt): Improve error message.
11822 (linux_enable_pt): Remove zero buffer size check.
11823 (linux_enable_btrace): Improve error messages. Remove NULL return
11826 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11828 * btrace.c (btrace_enable): Remove target_supports_btrace call.
11829 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
11830 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
11831 (linux_supports_pt, linux_supports_btrace): Remove.
11832 (linux_enable_bts): Call cpu_supports_bts.
11833 * nat/linux-btrace.h (linux_supports_btrace): Remove.
11834 * remote.c (remote_supports_btrace): Remove.
11835 (init_remote_ops): Remove remote_supports_btrace.
11836 * target-delegates.c: Regenerated.
11837 * target.c (target_supports_btrace): Remove.
11838 * target.h (target_ops) <to_supports_btrace>: Remove
11839 (target_supports_btrace): Remove.
11840 * x86-linux-nat.c (x86_linux_create_target): Remove
11841 linux_supports_btrace.
11843 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11845 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
11847 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
11848 exception and use message in own exception.
11850 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11852 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
11853 (perf_event_pt_event_type): Use gdb_file_up.
11854 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
11855 scoped_fd, and scoped_mmap.
11857 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11859 * common/scoped_mmap.h: New.
11860 * unittests/scoped_mmap-selftest.c: New.
11861 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11862 unittests/scoped_mmap-selftest.c.
11864 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11866 * common/scoped_fd.h: New.
11867 * unittests/scoped_fd-selftest.c: New.
11868 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11869 unittests/scoped_fd-selftest.c.
11871 2018-02-09 Tom Tromey <tom@tromey.com>
11873 * auto-load.c (auto_load_section_scripts): Use
11874 gdb::unique_xmalloc_ptr.
11876 2018-02-09 Tom Tromey <tom@tromey.com>
11878 * auto-load.c (execute_script_contents): Use std::string.
11880 2018-02-09 Joel Brobecker <brobecker@adacore.com>
11882 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
11883 Python function, rather than a new command.
11885 2018-02-08 Tom Tromey <tom@tromey.com>
11887 * solib.c (solib_find_1): Use std::string.
11888 (solib_bfd_fopen): Use unique_xmalloc_ptr.
11890 2018-02-08 Tom Tromey <tom@tromey.com>
11892 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
11894 2018-02-08 Tom Tromey <tom@tromey.com>
11896 * source.c (find_source_lines): Use gdb::def_vector.
11898 2018-02-08 Tom Tromey <tom@tromey.com>
11900 * macrocmd.c (struct temporary_macro_definition): New.
11901 (macro_define_command): Use temporary_macro_definition. Remove
11903 (free_macro_definition_ptr): Remove.
11905 2018-02-08 Tom Tromey <tom@tromey.com>
11907 * macroexp.c (maybe_expand): Use std::string.
11909 2018-02-08 Tom Tromey <tom@tromey.com>
11911 * macroexp.c (struct macro_buffer): Add initializers for some
11913 (init_buffer, init_shared_buffer, free_buffer)
11914 (free_buffer_return_text): Remove.
11915 (macro_buffer): New constructors.
11916 (~macro_buffer): New destructor.
11917 (macro_buffer::set_shared): New method.
11918 (macro_buffer::resize_buffer, macro_buffer::appendc)
11919 (macro_buffer::appendmem): Now methods, not free functions.
11920 (set_token, append_tokens_without_splicing, stringify)
11921 (macro_stringify): Update.
11922 (gather_arguments): Change return type. Remove argc_p argument,
11923 add args_ptr argument. Use std::vector.
11924 (substitute_args): Remove argc argument. Accept std::vector.
11925 (expand): Update. Use std::vector.
11926 (scan, macro_expand, macro_expand_next): Update.
11928 2018-02-08 Tom Tromey <tom@tromey.com>
11930 * symtab.c (default_collect_symbol_completion_matches_break_on):
11931 Use unique_xmalloc_ptr.
11932 * macroscope.h: (sal_macro_scope, user_macro_scope)
11933 (default_macro_scope): Return unique_xmalloc_ptr.
11934 * macroscope.c (sal_macro_scope, user_macro_scope)
11935 (default_macro_scope): Return unique_xmalloc_ptr.
11936 * macroexp.h (macro_expand, macro_expand_once): Return
11937 unique_xmalloc_ptr.
11938 * macroexp.c (macro_expand, macro_expand_once): Return
11939 unique_xmalloc_ptr.
11940 * macrocmd.c (macro_expand_command, macro_expand_once_command)
11941 (info_macro_command, info_macros_command): Use
11942 unique_xmalloc_ptr.
11943 * compile/compile-c-support.c (write_macro_definitions): Use
11944 unique_xmalloc_ptr.
11945 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
11947 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
11949 * value.c (value_static_field): Assign field type instead of
11950 containing type when returning an optimized out value.
11952 2018-02-06 Yao Qi <yao.qi@linaro.org>
11954 * ft32-tdep.c (ft32_read_pc): Remove.
11955 (ft32_write_pc): Remove.
11956 (ft32_gdbarch_init): Update.
11957 * m32r-tdep.c (m32r_read_pc): Remove.
11958 (m32r_gdbarch_init): Update.
11959 * mep-tdep.c (mep_read_pc): Remove.
11960 (mep_gdbarch_init): Update.
11961 * microblaze-tdep.c (microblaze_write_pc): Remove.
11962 (microblaze_gdbarch_init): Update.
11963 * mn10300-tdep.c (mn10300_read_pc): Remove.
11964 (mn10300_write_pc): Remove.
11965 (mn10300_gdbarch_init): Update.
11966 * moxie-tdep.c (moxie_read_pc): Remove.
11967 (moxie_write_pc): Remove.
11968 (moxie_gdbarch_init): Update.
11970 2018-02-06 Yao Qi <yao.qi@linaro.org>
11972 * expprint.c (print_subexp_standard): Handle
11973 OP_F77_UNDETERMINED_ARGLIST.
11974 (dump_subexp_body_standard): Likewise.
11976 2018-02-05 Alan Hayward <alan.hayward@arm.com>
11978 * target-descriptions.c (tdesc_element_visitor) Add empty
11980 (tdesc_type): Move make_gdb_type from here.
11981 (tdesc_type_builtin): Likewise.
11982 (tdesc_type_vector): Likewise.
11983 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
11984 (make_gdb_type_struct): Move from tdesc_type_with_fields.
11985 (make_gdb_type_union): Likewise.
11986 (make_gdb_type_flags): Likewise.
11987 (make_gdb_type_enum): Likewise.
11988 (make_gdb_type): New function.
11989 (tdesc_register_type): Use static make_gdb_type.
11991 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
11993 * infcmd.c (default_print_one_register_info): Align natural-format
11994 column values consistently one under another.
11995 (pad_to_column): New function.
11997 2018-02-05 Joel Brobecker <brobecker@adacore.com>
11999 * dwarf2read.c (dwarf2_physname): Move commment.
12001 2018-02-01 Leszek Swirski <leszeks@google.com>
12003 * varobj.c (varobj_formatted_print_options): Allow recursive
12004 pretty printing if pretty printing is enabled.
12006 2018-02-01 Leszek Swirski <leszeks@google.com>
12008 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
12009 names after a structop as a filename.
12011 2018-02-01 Yao Qi <yao.qi@linaro.org>
12013 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
12014 (arm_record_coproc_data_proc): Likewise.
12016 2018-02-01 Yao Qi <yao.qi@linaro.org>
12018 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
12020 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
12022 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
12023 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
12025 2018-01-31 Pedro Alves <palves@redhat.com>
12027 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
12028 * inflow.c (child_terminal_save_inferior): Wrap reference to
12029 tcgetpgrp in HAVE_TERMIOS_H.
12030 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
12032 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
12033 always iterate over all inferiors.
12034 (gdbsim_cntrl_c): Adjust.
12035 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
12037 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12039 * gdbtypes.c (lookup_array_range_type): Make sure the array's
12040 index type is objfile-owned if the element type is as well.
12042 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12046 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
12048 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
12049 "features/s390x-linux64.c".
12050 (_initialize_s390_linux_tdep): Remove initialization of tdescs
12051 s390_linux32 and s390x_linux64.
12052 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
12054 * s390-tdep.c: Include "features/s390-linux32.c" and
12055 "features/s390x-linux64.c".
12056 (s390_tdesc_valid): Add check for tdesc_has_registers.
12057 (s390_gdbarch_init): Make sure there is always a valid tdesc.
12058 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
12059 tdesc_s390x_linux64.
12060 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
12061 tdesc_s390x_linux64 to...
12062 * s390-tdep.h: ...here.
12064 2018-01-30 Pedro Alves <palves@redhat.com>
12067 * config.in, configure: Regenerate.
12068 * configure.ac: Check for getpgid.
12069 * go32-nat.c (go32_pass_ctrlc): New.
12070 (go32_target): Install it.
12071 * inf-child.c (inf_child_target): Install
12072 child_terminal_save_inferior, child_pass_ctrlc and
12074 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
12075 (inf_ptrace_target): No longer install it.
12076 * infcmd.c (interrupt_target_1): Adjust.
12077 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
12078 (child_interrupt): Declare.
12079 (inferior::terminal_state): New.
12080 * inflow.c (struct terminal_info): Update comments.
12081 (inferior_process_group): Delete.
12082 (terminal_is_ours): Delete.
12083 (gdb_tty_state): New.
12084 (child_terminal_init): Adjust.
12085 (is_gdb_terminal, sharing_input_terminal_1)
12086 (sharing_input_terminal): New functions.
12087 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
12088 Set the process's actual process group in the foreground if
12089 possible. Handle is_ours_for_output/is_ours distinction. Don't
12090 mark terminal as the inferior's if not sharing GDB's terminal.
12091 Don't check attach_flag.
12092 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
12093 pass down a target_terminal_state.
12094 (child_terminal_save_inferior): New, factored out from ...
12095 (child_terminal_ours_1): ... this. Handle
12096 target_terminal_state::is_ours_for_output.
12097 (child_interrupt, child_pass_ctrlc): New.
12098 (inflow_inferior_exit): Clear the inferior's terminal_state.
12099 (copy_terminal_info): Copy the inferior's terminal state.
12100 (_initialize_inflow): Remove reference to terminal_is_ours.
12101 * inflow.h (inferior_process_group): Delete.
12102 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
12103 * procfs.c (procfs_target): Don't install procfs_interrupt.
12104 (procfs_interrupt): Delete.
12105 * remote.c (remote_serial_quit_handler): Adjust.
12106 (remote_interrupt): Remove ptid parameter. Adjust.
12107 * target-delegates.c: Regenerate.
12108 * target.c: Include "terminal.h".
12109 (target_terminal::terminal_state): Rename to ...
12110 (target_terminal::m_terminal_state): ... this.
12111 (target_terminal::init): Adjust.
12112 (target_terminal::inferior): Adjust to per-inferior
12114 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
12115 (target_terminal::ours, target_terminal::ours_for_output): Use
12116 target_terminal_is_ours_kind.
12117 (target_interrupt): Remove ptid parameter. Adjust.
12118 (default_target_pass_ctrlc): Adjust.
12119 * target.h (target_ops::to_terminal_save_inferior): New field.
12120 (target_ops::to_interrupt): Remove ptid_t parameter.
12121 (target_interrupt): Remove ptid_t parameter. Update comment.
12122 (target_pass_ctrlc): Update comment.
12123 * target/target.h (target_terminal_state): New scoped enum,
12124 factored out of ...
12125 (target_terminal::terminal_state): ... here.
12126 (target_terminal::inferior): Update comments.
12127 (target_terminal::restore_inferior): New.
12128 (target_terminal::is_inferior, target_terminal::is_ours)
12129 (target_terminal::is_ours_for_output): Adjust.
12130 (target_terminal::scoped_restore_terminal_state): Adjust to
12131 rename, and call restore_inferior() instead of inferior().
12132 (target_terminal::scoped_restore_terminal_state::m_state): Change
12134 (target_terminal::terminal_state): Rename to ...
12135 (target_terminal::m_terminal_state): ... this and change type.
12137 2018-01-30 Pedro Alves <palves@redhat.com>
12139 * linux-nat.c (wait_for_signal): New function.
12140 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
12142 (async_terminal_is_ours)
12143 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
12144 (linux_nat_add_target): Don't override
12145 to_terminal_inferior/to_terminal_ours.
12147 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
12149 * remote.c (remote_follow_fork): Don't call "detach_inferior".
12151 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
12153 * dwarf2read.c (free_dwo_files): Add forward-declaration.
12154 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
12155 dwarf2_per_objfile_free here.
12156 (dwarf2_per_objfile_free): Remove.
12157 (_initialize_dwarf2_read): Don't register
12158 dwarf2_per_objfile_free as a registry cleanup.
12160 2018-01-27 Eli Zaretskii <eliz@gnu.org>
12162 Avoid compilation errors in MinGW native builds
12164 The error is triggered by including python-internal.h, and the
12167 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
12168 from build-gnulib/import/math.h:27,
12169 from d:/usr/Python26/include/pyport.h:235,
12170 from d:/usr/Python26/include/Python.h:58,
12171 from python/python-internal.h:94,
12172 from python/py-arch.c:24:
12173 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
12177 This happens because Python headers define 'hypot' to expand t
12178 '_hypot' in the Windows builds.
12179 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
12180 'hypoth'. This avoids a compilation error.
12182 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12184 * MAINTAINERS (Write After Approval): Fix ordering.
12186 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12188 * MAINTAINERS (Write After Approval): Add Alan Hayward.
12190 2018-01-26 Alan Modra <amodra@gmail.com>
12192 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
12193 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
12194 Remove nop. Make const. Comment.
12195 (powerpc32_plt_stub_so_2): New.
12196 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
12197 Correct count. Update uses.
12198 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
12199 Move common code reading PLT entry word. Correct
12200 powerpc32_plt_stub PLT address calculation.
12201 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
12202 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
12203 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
12204 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
12205 (ppc64_standard_linkage8): Likewise.
12206 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
12207 Correct insns description.
12208 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
12210 2018-01-24 Pedro Alves <palves@redhat.com>
12212 GCC PR libstdc++/83906
12213 * gdbtypes.c (operator==(const dynamic_prop &,
12214 const dynamic_prop &)): New.
12215 (operator==(const range_bounds &, const range_bounds &)): New.
12216 (check_types_equal): Use them instead of memcmp.
12217 * gdbtypes.h (operator==(const dynamic_prop &,
12218 const dynamic_prop &)): Declare.
12219 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
12220 (operator==(const range_bounds &, const range_bounds &)): Declare.
12221 (operator!=(const range_bounds &, const range_bounds &)): Declare.
12223 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12225 * s390-linux-tdep.c (s390_record_address_mask)
12226 (s390_record_calc_disp_common, s390_record_calc_disp)
12227 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12228 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12229 (s390_process_record): Move to s390-tdep.c.
12230 (s390_linux_init_abi_any): Adjust.
12231 * s390-tdep.c (s390_record_address_mask)
12232 (s390_record_calc_disp_common, s390_record_calc_disp)
12233 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12234 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12235 (s390_process_record): Moved from s390-linux-tdep.c
12236 (s390_gdbarch_init): Adjust.
12238 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12240 * s390-linux-nat.c (s390-tdep.h): New include.
12241 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
12242 (HFILES_NO_SRCDIR): Add s390-tdep.h.
12243 (ALLDEPFILES): Add s390-tdep.c.
12244 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
12245 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
12246 * s390-tdep.h: ...this. New file.
12247 * s390-linux-tdep.c (s390-tdep.h): New include.
12248 (_initialize_s390_tdep): Rename to...
12249 (_initialize_s390_linux_tdep): ...this and adjust.
12250 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
12251 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
12253 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
12254 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
12255 (s390_is_partial_instruction, s390_software_single_step)
12256 (is_non_branch_ril, s390_displaced_step_copy_insn)
12257 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
12258 (s390_prologue_data, s390_addr, s390_store, s390_load)
12259 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
12260 (s390_register_call_saved, s390_guess_tracepoint_registers)
12261 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
12262 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
12263 (s390_pseudo_register_name, s390_pseudo_register_type)
12264 (s390_pseudo_register_read, s390_pseudo_register_write)
12265 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
12266 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
12267 (s390_addr_bits_remove, s390_address_class_type_flags)
12268 (s390_address_class_type_flags_to_name)
12269 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
12270 (s390_function_arg_float, s390_function_arg_vector)
12271 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
12272 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
12273 (s390_frame_align, s390_register_return_value, s390_return_value)
12274 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
12275 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
12276 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
12277 (s390_trad_frame_prev_register, s390_unwind_cache)
12278 (s390_prologue_frame_unwind_cache)
12279 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
12280 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
12281 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
12282 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
12283 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
12284 (s390_frame_base_address, s390_local_base_address)
12285 (s390_frame_base, s390_gcc_target_options)
12286 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
12287 (s390_validate_reg_range, s390_tdesc_valid)
12288 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
12289 * s390-tdep.c: ...this. New file.
12291 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12293 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
12294 (s390_process_record, s390_gdbarch_tdep_alloc)
12295 (s390_linux_init_abi_any): Use/set new hook.
12297 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12299 * s390-linux-tdep.c (osabi.h): New include.
12300 (s390_linux_init_abi_31, s390_linux_init_abi_64)
12301 (s390_linux_init_abi_any): New functions.
12302 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
12304 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12306 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
12307 tdesc_has_registers check
12309 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12311 * s390-linux-tdep.c (s390_tdesc_valid): New function.
12312 (s390_validate_reg_range): New macro.
12313 (s390_gdbarch_init): Adjust.
12315 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12317 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
12318 (s390_gdbarch_tdep_alloc): Adjust.
12319 (s390_gdbarch_init): Adjust.
12321 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12323 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
12324 <have_tdb>: Change type to bool.
12325 (s390_gdbarch_tdep_alloc): Adjust.
12326 (s390_gdbarch_init): Adjust.
12328 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12330 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
12331 (gdbarch_tdep) <have_upper, have_vx>: New fields.
12332 (s390_gdbarch_tdep_alloc): New function.
12333 (s390_gdbarch_init): Allocate tdep at start and use its fields
12334 instead of separate variables.
12336 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12338 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
12339 when looking for cached gdbarch and add comment for remaining.
12341 2018-01-22 Pedro Alves <palves@redhat.com>
12342 Sergio Durigan Junior <sergiodj@redhat.com>
12344 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
12347 2018-01-22 Maciej W. Rozycki <macro@mips.com>
12349 * MAINTAINERS: Update my company e-mail address.
12351 2018-01-22 Yao Qi <yao.qi@linaro.org>
12353 * regcache.c (cooked_write_test): New function.
12354 (_initialize_regcache): Register the test.
12356 2018-01-22 Yao Qi <yao.qi@linaro.org>
12358 * ia64-tdep.c (ia64_pseudo_register_read): Call
12359 regcache->cooked_read instead of regcache_cooked_read_unsigned.
12360 * m32c-tdep.c (m32c_cat_read): Likewise.
12361 (m32c_r3r2r1r0_read): Likewise.
12362 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
12363 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
12365 2018-01-22 Yao Qi <yao.qi@linaro.org>
12367 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
12368 method raw_read instead of regcache_raw_read.
12369 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
12370 * arm-tdep.c (arm_neon_quad_read): Likewise.
12371 * avr-tdep.c (avr_pseudo_register_read): Likewise.
12372 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
12373 * frv-tdep.c (frv_pseudo_register_read): Likewise.
12374 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
12375 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
12376 (i386_pseudo_register_read_into_value): Likewise.
12377 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
12378 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
12379 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
12380 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
12381 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
12382 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
12383 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
12384 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
12385 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
12387 2018-01-22 Yao Qi <yao.qi@linaro.org>
12389 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
12390 * configure.tgt: Remove target mt.
12391 * mt-tdep.c: Remove.
12392 * regcache.c (cooked_read_test): Remove the check for mt.
12394 2018-01-22 Yao Qi <yao.qi@linaro.org>
12396 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
12397 instead of gdbarch_pseudo_register_read_value.
12399 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12401 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
12404 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12406 * linespec.c (create_sals_line_offset): Remove code that preserved
12407 the symtab_and_line's line number.
12409 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12411 * varobj.c (varobj_create): Don't set valid_block when creating a
12414 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12416 * varobj.c (varobj_create): Remove out of date comment.
12418 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12421 * ada-exp.y (write_var_from_sym): Pass extra parameter when
12422 updating innermost block.
12423 * parse.c (innermost_block_tracker::update): Take extra type
12424 parameter, and check types match before updating innermost block.
12425 (write_dollar_variable): Update innermost block for registers.
12426 * parser-defs.h (enum innermost_block_tracker_type): New enum.
12427 (innermost_block_tracker::innermost_block_tracker): Initialise
12429 (innermost_block_tracker::reset): Take type parameter.
12430 (innermost_block_tracker::update): Take type parameter, and pass
12431 type through as needed.
12432 (innermost_block_tracker::m_types): New member.
12433 * varobj.c (varobj_create): Pass type when reseting innermost
12436 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12438 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
12439 * ada-lang.c (resolve_subexp): Likewise.
12440 * breakpoint.c (set_breakpoint_condition) Likewise.
12441 (watch_command_1) Likewise.
12442 * c-exp.y (variable): Likewise.
12443 * d-exp.y (PrimaryExpression): Likewise.
12444 * f-exp.y (variable): Likewise.
12445 * go-exp.y (variable): Likewise.
12446 * m2-exp.y (variable): Likewise.
12447 * objfiles.c (objfile::~objfile): Likewise.
12448 * p-exp.y (variable): Likewise.
12449 * parse.c (innermost_block): Change type.
12450 * parser-defs.h (class innermost_block_tracker): New.
12451 (innermost_block): Change to innermost_block_tracker.
12452 * printcmd.c (display_command): Switch to innermost_block API.
12453 (do_one_display): Likewise.
12454 * rust-exp.y (do_one_display): Likewise.
12455 * symfile.c (clear_symtab_users): Likewise.
12456 * varobj.c (varobj_create): Switch to innermost_block API, replace
12457 use of innermost_block with block stored on varobj object.
12459 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12461 * expression.h (innermost_block): Remove declaration.
12462 * varobj.c: Add 'parser-defs.h' include.
12464 2018-01-19 Tom Tromey <tom@tromey.com>
12466 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
12467 symbols in the static and global blocks.
12469 2018-01-19 James Clarke <jrtc27@jrtc27.com>
12471 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
12472 gdb_ptrace.h, and move including gdb_wait.h ...
12473 * nat/linux-ptrace.h: ... to here.
12475 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12477 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
12478 inf_ptrace_detach_success.
12479 (inf_ptrace_detach_success): Add inferior parameter, use it
12480 instead of inferior_ptid, pass it to detach_inferior.
12481 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
12483 * inferior.c (detach_inferior): Add overload that takes an
12485 * inferior.h (detach_inferior): Likewise.
12486 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
12487 use inferior_ptid, adjust call to inf_ptrace_detach_success.
12488 * linux-thread-db.c (thread_db_detach): Use inf parameter.
12490 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12492 * target.h (struct target_ops) <to_detach>: Add inferior
12494 (target_detach): Likewise.
12495 * target.c (dispose_inferior): Pass inferior down.
12496 (target_detach): Pass inferior down. Assert that it is equal to
12497 the current inferior.
12498 * aix-thread.c (aix_thread_detach): Pass inferior down.
12499 * corefile.c (core_file_command): Pass current_inferior() down.
12500 * corelow.c (core_detach): Add inferior parameter.
12501 * darwin-nat.c (darwin_detach): Likewise.
12502 * gnu-nat.c (gnu_detach): Likewise.
12503 * inf-ptrace.c (inf_ptrace_detach): Likewise.
12504 * infcmd.c (detach_command): Pass current_inferior() down to
12506 * infrun.c (follow_fork_inferior): Pass parent_inf to
12508 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
12510 * linux-nat.c (linux_nat_detach): Add inferior parameter.
12511 * linux-thread-db.c (thread_db_detach): Likewise.
12512 * nto-procfs.c (procfs_detach): Likewise.
12513 * procfs.c (procfs_detach): Likewise.
12514 * record.c (record_detach): Likewise.
12515 * record.h (struct inferior): Forward-declare.
12516 (record_detach): Add inferior parameter.
12517 * remote-sim.c (gdbsim_detach): Likewise.
12518 * remote.c (remote_detach_1): Likewise.
12519 (remote_detach): Likewise.
12520 (extended_remote_detach): Likewise.
12521 * sol-thread.c (sol_thread_detach): Likewise.
12522 * target-debug.h (target_debug_print_inferior_p): New macro.
12523 * target-delegates.c: Re-generate.
12524 * top.c (kill_or_detach): Pass inferior down to target_detach.
12525 * windows-nat.c (windows_detach): Add inferior parameter.
12527 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12529 * target.h (struct target_ops) <to_detach>: Remove args
12531 (target_detach): Likewise.
12532 * target.c (dispose_inferior): Adjust.
12533 (target_detach): Remove args parameter, adjust.
12534 * aix-thread.c (aix_thread_detach): Adjust.
12535 * corefile.c (core_file_command): Adjust.
12536 * corelow.c (core_detach): Adjust.
12537 * darwin-nat.c (darwin_detach): Adjust.
12538 * gnu-nat.c (gnu_detach): Adjust.
12539 * inf-ptrace.c (inf_ptrace_detach): Adjust.
12540 * infcmd.c (detach_command): Adjust
12541 * infrun.c (follow_fork_inferior): Adjust.
12542 (handle_vfork_child_exec_or_exit): Adjust.
12543 * linux-fork.c (linux_fork_detach): Remove args parameter.
12544 * linux-fork.h (linux_fork_detach): Likewise.
12545 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
12546 * linux-thread-db.c (thread_db_detach): Likewise.
12547 * nto-procfs.c (procfs_detach): Likewise.
12548 * procfs.c (procfs_detach): Likewise.
12549 (do_detach): Remove signo parameter.
12550 * record.c (record_detach): Remove args parameter.
12551 * record.h (record_detach): Likewise.
12552 * remote-sim.c (gdbsim_detach): Likewise.
12553 * remote.c (remote_detach_1): Likewise.
12554 (remote_detach): Likewise.
12555 (extended_remote_detach): Likewise.
12556 * sol-thread.c (sol_thread_detach): Likewise.
12557 * target-delegates.c: Re-generate.
12558 * top.c (struct qt_args) <args>: Remove field.
12559 (kill_or_detach): Don't pass args.
12560 (quit_force): Don't set args.
12561 * windows-nat.c (windows_detach): Remove args parameter.
12563 2018-01-19 Yao Qi <yao.qi@linaro.org>
12565 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
12566 (arm_linux_init_abi): Install it.
12568 2018-01-19 Yao Qi <yao.qi@linaro.org>
12570 * osabi.c (gdb_osabi_names): Extend the regexp for
12571 arm-linux-gnueabihf.
12573 2018-01-18 Yao Qi <yao.qi@linaro.org>
12575 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
12577 (abbrev_table::add_abbrev): Update.
12578 (abbrev_table::lookup_abbrev): Update.
12580 2018-01-18 Yao Qi <yao.qi@linaro.org>
12582 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
12584 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
12586 * compile/compile.c (compile_to_object): Convert "triplet_rx"
12589 2018-01-17 Tom Tromey <tom@tromey.com>
12591 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
12593 2018-01-17 Tom Tromey <tom@tromey.com>
12595 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
12596 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
12597 (create_array_type_with_stride): Update.
12598 * dwarf2read.c (set_die_type): Update.
12600 2018-01-17 Tom Tromey <tom@tromey.com>
12602 * dwarf2read.c (delayed_method_info): Remove typedef.
12603 (dwarf2_cu::method_info): Now a std::vector.
12604 (add_to_method_list): Update.
12605 (free_delayed_list): Remove.
12606 (compute_delayed_physnames): Update.
12607 (process_full_comp_unit, process_full_type_unit): Clear the method
12608 list. Remove cleanups.
12609 (psymtab_include_file_name): Add name_holder parameter. Use
12610 unique_xmalloc_ptr.
12611 (dwarf_decode_lines): Update.
12613 2018-01-17 Tom Tromey <tom@tromey.com>
12614 Simon Marchi <simon.marchi@ericsson.com>
12616 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
12617 (dwarf2_per_objfile::free_cached_comp_units)
12618 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12619 (init_cutu_and_read_dies_no_follow): Update.
12620 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
12621 (dwarf2_cu::~dwarf2_cu): New.
12622 (free_heap_comp_unit, free_stack_comp_unit): Remove.
12623 (age_cached_comp_units, free_one_cached_comp_unit): Update.
12625 2018-01-17 Tom Tromey <tom@tromey.com>
12626 Simon Marchi <simon.marchi@ericsson.com>
12628 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
12629 (struct die_reader_specs) <abbrev_table>: New member.
12630 (struct abbrev_table): Add constructor.
12631 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
12632 <abbrev_obstack>: Now an auto_obstack.
12633 (abbrev_table_up): New typedef.
12634 (init_cu_die_reader): Add abbrev_table parameter.
12635 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
12636 Add result_dwo_abbrev_table.
12637 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12638 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
12640 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
12642 (skip_children): Update.
12643 (abbrev_table::alloc_abbrev): Rename from
12644 abbrev_table_alloc_abbrev.
12645 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
12646 (abbrev_table::lookup_abbrev): Rename from
12647 abbrev_table_lookup_abbrev.
12648 (abbrev_table_read_table): Return abbrev_table_up.
12649 (abbrev_table_free, abbrev_table_free_cleanup)
12650 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
12651 (load_partial_dies): Update.
12653 2018-01-17 Tom Tromey <tom@tromey.com>
12655 * dwarf2read.c (dwarf2_compute_name): Update comment.
12656 (read_func_scope, read_variable): Update.
12657 (new_symbol): Remove.
12658 (new_symbol_full): Rename to new_symbol.
12660 2018-01-17 Mike Gulick <mgulick@mathworks.com>
12663 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
12664 a warning instead of throwing an error, set section size to 0 and return
12666 * gdb_bfd.h (gdb_bfd_map_section): Update description.
12668 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
12670 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
12672 (linux_ptrace_attach_fail_reason_string): Likewise.
12673 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
12675 (linux_ptrace_attach_fail_reason_string): Likewise.
12676 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
12678 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
12680 * linux-nat.c (linux_nat_attach): Remove xstrdup.
12682 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
12685 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
12686 checking for fs_base/gs_base fields in struct user_regs_struct.
12687 * configure: Regenerate.
12689 2018-01-17 Yao Qi <yao.qi@linaro.org>
12691 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
12693 (aarch64_linux_init_abi): Install it to gdbarch hook
12694 gcc_target_options.
12696 2018-01-15 Pedro Alves <palves@redhat.com>
12698 * common/signals-state-save-restore.c
12699 (save_original_signals_state): Fix typos.
12701 2017-01-12 Tom Tromey <tom@tromey.com>
12702 Sergio Durigan Junior <sergiodj@redhat.com>
12704 * Makefile.in (install-only): Install gdb-add-index.
12706 2018-01-12 John Baldwin <jhb@FreeBSD.org>
12708 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
12710 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
12712 * infrun.c (keep_going_pass_signal): Clear step-over info when
12713 insert_breakpoints fails.
12715 2018-01-11 Pedro Alves <palves@redhat.com>
12718 * infrun.c (resume): Rename to ...
12719 (resume_1): ... this.
12720 (resume): Reimplement as wrapper around resume_1.
12722 2018-01-11 Pedro Alves <palves@redhat.com>
12725 * remote.c (remote_parse_stop_reply): Default to the last-set
12726 general thread instead of to 'magic_null_ptid'.
12728 2018-01-10 Pedro Alves <palves@redhat.com>
12730 * language.h (language_get_symbol_name_matcher): Rename ...
12731 (get_symbol_name_matcher): ... this.
12732 * language.c (language_get_symbol_name_matcher): Ditto.
12733 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
12736 2018-01-10 Pedro Alves <palves@redhat.com>
12740 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
12741 Adjust to use language_get_symbol_name_matcher instead of
12742 language_defn::la_get_symbol_name_matcher.
12743 * language.c (language_get_symbol_name_matcher): If in Ada mode
12744 and the lookup name is a verbatim match, return Ada's matcher.
12745 * language.h (language_get_symbol_name_matcher): Adjust comment.
12746 (ada_lookup_name_info::verbatim_p):: New method.
12748 2018-01-10 Pedro Alves <palves@redhat.com>
12751 * ada-lang.c (ada_collect_symbol_completion_matches): If the
12752 minsym's language is language_auto or language_cplus, pass down
12753 language_ada instead.
12754 * symtab.c (compare_symbol_name): Don't frob symbol language here.
12756 2018-01-10 Pedro Alves <palves@redhat.com>
12759 * minsyms.c (linkage_name_str): New function.
12760 (iterate_over_minimal_symbols): Use it.
12762 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12764 * NEWS: Document that 'info proc' now works on FreeBSD.
12766 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12768 * configure.ac: Check for kinfo_getfile in libutil.
12769 * configure: Regenerate.
12770 * config.in: Regenerate.
12771 * fbsd-nat.c: Include "fbsd-tdep.h".
12772 (fbsd_fetch_cmdline): New.
12773 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
12774 rather than calling error.
12775 (fbsd_info_proc): New.
12776 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
12777 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
12778 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
12780 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12782 * fbsd-nat.c (struct free_deleter): Remove.
12783 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
12785 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12787 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
12788 NULL for an empty pathname.
12790 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12792 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
12793 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
12794 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
12795 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
12796 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
12797 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
12798 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
12799 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
12800 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
12801 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
12802 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
12803 (fbsd_core_fetch_timeval, fbsd_print_sigset)
12804 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
12805 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
12806 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
12808 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
12810 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
12811 (gnu_xfer_auxv): New function.
12812 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
12813 TARGET_OBJECT_AUXV.
12815 2018-01-08 Yao Qi <yao.qi@linaro.org>
12816 Simon Marchi <simon.marchi@ericsson.com>
12818 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
12820 (COMMON_OBS): Remove selftest.o.
12821 * configure.ac: Append selftest-arch.c and common/selftest.c to
12822 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
12823 * configure: Re-generated.
12824 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
12826 (maintenance_info_selftests): Likewise.
12828 2018-01-08 Xavier Roirand <roirand@adacore.com>
12830 * ada-valprint.c (val_print_packed_array_elements): Use
12831 proper number of elements when printing an array indexed
12832 by an enumeration type.
12834 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
12836 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
12837 (dw2_get_file_names_reader): Adjust.
12838 (lookup_dwo_signatured_type): Adjust.
12839 (lookup_dwp_signatured_type): Adjust.
12840 (lookup_signatured_type): Adjust.
12841 (create_type_unit_group): Adjust.
12842 (get_type_unit_group): Adjust.
12843 (process_psymtab_comp_unit_reader): Adjust.
12844 (build_type_psymtabs_reader): Adjust.
12845 (scan_partial_symbols): Adjust.
12846 (add_partial_symbol): Adjust.
12847 (add_partial_subprogram): Adjust.
12848 (peek_die_abbrev): Adjust.
12849 (fixup_go_packaging): Adjust.
12850 (process_imported_unit_die): Adjust.
12851 (dwarf2_compute_name): Adjust.
12852 (dwarf2_physname): Adjust.
12853 (read_import_statement): Adjust.
12854 (handle_DW_AT_stmt_list): Adjust.
12855 (read_file_scope): Adjust.
12856 (read_func_scope): Adjust.
12857 (read_lexical_block_scope): Adjust.
12858 (read_call_site_scope): Adjust.
12859 (read_variable): Adjust.
12860 (dwarf2_rnglists_process): Adjust.
12861 (dwarf2_ranges_process): Adjust.
12862 (dwarf2_ranges_read): Adjust.
12863 (dwarf2_get_pc_bounds): Adjust.
12864 (dwarf2_record_block_ranges): Adjust.
12865 (dwarf2_add_field): Adjust.
12866 (dwarf2_add_member_fn): Adjust.
12867 (read_structure_type): Adjust.
12868 (process_structure_scope): Adjust.
12869 (read_enumeration_type): Adjust.
12870 (read_array_type): Adjust.
12871 (mark_common_block_symbol_computed): Adjust.
12872 (read_common_block): Adjust.
12873 (read_namespace_type): Adjust.
12874 (read_namespace): Adjust.
12875 (read_module_type): Adjust.
12876 (read_tag_pointer_type): Adjust.
12877 (read_tag_ptr_to_member_type): Adjust.
12878 (read_tag_string_type): Adjust.
12879 (read_subroutine_type): Adjust.
12880 (read_typedef): Adjust.
12881 (read_base_type): Adjust.
12882 (attr_to_dynamic_prop): Adjust.
12883 (read_subrange_type): Adjust.
12884 (read_unspecified_type): Adjust.
12885 (dwarf2_read_abbrevs): Adjust.
12886 (load_partial_dies): Adjust.
12887 (read_partial_die): Adjust.
12888 (find_partial_die): Adjust.
12889 (guess_partial_die_structure_name): Adjust.
12890 (fixup_partial_die): Adjust.
12891 (read_attribute_value): Adjust.
12892 (read_addr_index): Adjust.
12893 (read_addr_index_from_leb128): Adjust.
12894 (read_str_index): Adjust.
12895 (dwarf2_string_attr): Adjust.
12896 (get_debug_line_section): Adjust.
12897 (dwarf_decode_line_header): Adjust.
12898 (lnp_state_machine::check_line_address): Adjust.
12899 (dwarf_decode_lines_1): Adjust.
12900 (dwarf_decode_lines): Adjust.
12901 (dwarf2_start_symtab): Adjust.
12902 (var_decode_location): Adjust.
12903 (new_symbol_full): Adjust.
12904 (dwarf2_const_value_data): Adjust.
12905 (dwarf2_const_value_attr): Adjust.
12906 (dwarf2_const_value): Adjust.
12907 (die_type): Adjust.
12908 (die_containing_type): Adjust.
12909 (build_error_marker_type): Adjust.
12910 (lookup_die_type): Adjust.
12911 (guess_full_die_structure_name): Adjust.
12912 (anonymous_struct_prefix): Adjust.
12913 (determine_prefix): Adjust.
12914 (dwarf2_name): Adjust.
12915 (follow_die_ref_or_sig): Adjust.
12916 (follow_die_offset): Adjust.
12917 (follow_die_ref): Adjust.
12918 (follow_die_sig_1): Adjust.
12919 (follow_die_sig): Adjust.
12920 (get_signatured_type): Adjust.
12921 (get_DW_AT_signature_type): Adjust.
12922 (decode_locdesc): Adjust.
12923 (dwarf_decode_macros): Adjust.
12924 (cu_debug_loc_section): Adjust.
12925 (fill_in_loclist_baton): Adjust.
12926 (dwarf2_symbol_mark_computed): Adjust.
12927 (init_one_comp_unit): Don't assign
12928 dwarf2_cu::dwarf2_per_objfile.
12929 (set_die_type): Adjust.
12931 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
12933 * dwarf2read.c (struct mapped_debug_names): Add constructor.
12934 <dwarf2_per_objfile>: New field.
12935 (dwarf2_per_objfile): Remove global.
12936 (get_dwarf2_per_objfile): New function.
12937 (set_dwarf2_per_objfile): New function.
12938 (dwarf2_build_psymtabs_hard): Change objfile parameter to
12939 dwarf2_per_objfile.
12940 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
12941 (read_abbrev_offset): Likewise.
12942 (read_indirect_string): Likewise.
12943 (read_indirect_line_string): Likewise.
12944 (read_indirect_string_at_offset): Likewise.
12945 (read_indirect_string_from_dwz): Likewise.
12946 (dwarf2_find_containing_comp_unit): Change objfile parameter to
12947 dwarf2_per_objfile.
12948 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
12949 (create_all_comp_units): Change objfile parameter to
12950 dwarf2_per_objfile.
12951 (create_all_type_units): Likewise.
12952 (process_queue): Add dwarf2_per_objfile parameter.
12953 (read_and_check_comp_unit_head): Likewise.
12954 (lookup_dwo_unit_in_dwp): Likewise.
12955 (get_dwp_file): Likewise.
12956 (process_cu_includes): Likewise.
12957 (struct free_dwo_file_cleanup_data): New struct.
12958 (dwarf2_has_info): Use get_dwarf2_per_objfile and
12959 set_dwarf2_per_objfile.
12960 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
12961 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
12962 context, adjust calls.
12963 (dw2_instantiate_symtab): Likewise.
12964 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
12965 (dw2_get_cu): Likewise.
12966 (create_cu_from_index_list): Change objfile parameter to
12967 dwarf2_per_objfile.
12968 (create_cus_from_index_list): Get dwarf2_per_objfile from
12969 context, adjust calls.
12970 (create_cus_from_index): Likewise.
12971 (create_signatured_type_table_from_index): Change objfile
12972 parameter to dwarf2_per_objfile.
12973 (create_signatured_type_table_from_debug_names): Change objfile
12974 parameter to dwarf2_per_objfile.
12975 (create_addrmap_from_index): Likewise.
12976 (create_addrmap_from_aranges): Likewise.
12977 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
12978 (dw2_setup): Remove.
12979 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
12981 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
12982 get_dwarf2_per_objfile.
12983 (dw2_forget_cached_source_info): Likewise.
12984 (dw2_map_symtabs_matching_filename): Likewise.
12985 (struct dw2_symtab_iterator) <index>: Remove.
12986 <dwarf2_per_objfile>: New field.
12987 (dw2_symtab_iter_init): Replace index parameter with
12988 dwarf2_per_objfile.
12989 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
12990 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
12991 (dw2_print_stats): Likewise.
12992 (dw2_dump): Likewise.
12993 (dw2_expand_symtabs_for_function): Likewise.
12994 (dw2_expand_all_symtabs): Likewise.
12995 (dw2_expand_symtabs_with_fullname): Likewise.
12996 (dw2_expand_marked_cus): Replace index and objfile parameters
12997 with dwarf2_per_objfile.
12998 (dw_expand_symtabs_matching_file_matcher): Add
12999 dwarf2_per_objfile parameter and adjust calls.
13000 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
13002 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
13003 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
13005 (create_cus_from_debug_names_list): Replace objfile parameter
13006 with dwarf2_per_objfile and adjust calls.
13007 (create_cus_from_debug_names): Likewise.
13008 (dwarf2_read_debug_names): Likewise.
13009 (mapped_debug_names::namei_to_name): Adjust call.
13010 (dw2_debug_names_iterator::next): Likewise.
13011 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
13012 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
13013 (dw2_debug_names_dump): Likewise.
13014 (dw2_debug_names_expand_symtabs_for_function): Likewise.
13015 (dw2_debug_names_expand_symtabs_matching): Likewise.
13016 (dwarf2_initialize_objfile): Likewise.
13017 (dwarf2_build_psymtabs): Likewise.
13018 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
13020 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
13021 (read_and_check_comp_unit_head): Likewise.
13022 (read_abbrev_offset): Likewise.
13023 (create_debug_type_hash_table): Likewise.
13024 (create_debug_types_hash_table): Likewise.
13025 (create_all_type_units): Replace objfile parameter with
13026 dwarf2_per_objfile.
13027 (add_type_unit): Add dwarf2_per_objfile parameter.
13028 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
13029 with dwarf2_per_objfile.
13030 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
13031 (lookup_dwp_signatured_type): Likewise.
13032 (lookup_signatured_type): Likewise.
13033 (read_cutu_die_from_dwo): Likewise.
13034 (init_tu_and_read_dwo_dies): Likewise.
13035 (init_cutu_and_read_dies): Likewise.
13036 (init_cutu_and_read_dies_no_follow): Likewise.
13037 (allocate_type_unit_groups_table): Add objfile parameter.
13038 (create_type_unit_group): Use dwarf2_per_objfile from cu.
13039 (get_type_unit_group): Likewise.
13040 (process_psymtab_comp_unit): Update call.
13041 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
13042 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
13043 (print_tu_stats): Likewise.
13044 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
13045 in void* parameter.
13046 (build_type_psymtabs): Change objfile parameter to
13047 dwarf2_per_objfile.
13048 (process_skeletonless_type_unit): Use dwarf2_per_objfile
13049 passed in void* parameter.
13050 (process_skeletonless_type_units): Change objfile parameter to
13051 dwarf2_per_objfile.
13052 (set_partial_user): Likewise.
13053 (dwarf2_build_psymtabs_hard): Likewise.
13054 (read_comp_units_from_section): Likewise.
13055 (create_all_comp_units): Likewise.
13056 (scan_partial_symbols): Update calls.
13057 (add_partial_symbol): Likewise.
13058 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
13059 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
13060 (process_queue): Add dwarf2_per_objfile parameter.
13061 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
13062 (compute_compunit_symtab_includes): Likewise.
13063 (process_cu_includes): Add dwarf2_per_objfile parameter.
13064 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
13065 (process_full_type_unit): Likewise.
13066 (process_imported_unit_die): Update call.
13067 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
13068 (read_file_scope): Likewise.
13069 (allocate_dwo_file_hash_table): Add objfile parameter.
13070 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
13071 (create_cus_hash_table): Likewise.
13072 (create_dwp_hash_table): Likewise.
13073 (create_dwo_unit_in_dwp_v1): Likewise.
13074 (create_dwp_v2_section): Likewise.
13075 (create_dwo_unit_in_dwp_v2): Likewise.
13076 (lookup_dwo_unit_in_dwp): Likewise.
13077 (try_open_dwop_file): Likewise.
13078 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
13079 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
13080 cleanup to include a reference to dwarf2_per_objfile.
13081 (open_dwp_file): Add dwarf2_per_objfile parameter.
13082 (open_and_init_dwp_file): Likewise.
13083 (get_dwp_file): Likewise.
13084 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
13085 (queue_and_load_all_dwo_tus): Update call.
13086 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
13088 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
13089 (dwarf2_ranges_process): Likewise.
13090 (dwarf2_get_pc_bounds): Likewise.
13091 (mark_common_block_symbol_computed): Likewise.
13092 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
13093 (dwarf2_read_abbrevs): Update call.
13094 (read_partial_die): Use dwarf2_per_objfile from cu.
13095 (find_partial_die): Likewise.
13096 (fixup_partial_die): Likewise.
13097 (read_attribute_value): Likewise.
13098 (read_indirect_string_at_offset_from): Add objfile parameter.
13099 (read_indirect_string_at_offset): Add dwarf2_per_objfile
13101 (read_indirect_string_from_dwz): Add objfile parameter.
13102 (read_indirect_string): Add objfile parameter.
13103 (read_addr_index_1): Add dwarf2_per_objfile parameter.
13104 (read_addr_index): Use dwarf2_per_objfile from cu.
13105 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
13107 (read_str_index): Use dwarf2_per_objfile from cu.
13108 (get_debug_line_section): Likewise.
13109 (read_formatted_entries): Add dwarf2_per_objfile parameter.
13110 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
13111 (new_symbol_full): Use dwarf2_per_objfile from cu.
13112 (build_error_marker_type): Likewise.
13113 (lookup_die_type): Likewise.
13114 (determine_prefix): Likewise.
13115 (follow_die_offset): Likewise.
13116 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
13117 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
13118 (dwarf2_fetch_die_type_sect_off): Likewise.
13119 (dwarf2_get_die_type): Likewise.
13120 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
13121 (get_signatured_type): Likewise.
13122 (get_DW_AT_signature_type): Likewise.
13123 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
13124 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
13125 (cu_debug_loc_section): Likewise.
13126 (fill_in_loclist_baton): Likewise.
13127 (dwarf2_symbol_mark_computed): Likewise.
13128 (dwarf2_find_containing_comp_unit): Change objfile parameter to
13129 dwarf2_per_objfile.
13130 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
13132 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
13133 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
13134 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
13135 (set_die_type): Use dwarf2_free_objfile from cu.
13136 (get_die_type_at_offset): Likewise.
13137 (dwarf2_per_objfile_free): Don't assign global variable.
13138 (debug_names) <constructor>: Add dwarf2_per_objfile
13139 parameter, update m_debugstrlookup construction.
13140 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
13142 <m_dwarf2_per_objfile>: New field.
13143 <lookup>: Use m_dwarf2_per_objfile.
13144 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
13145 (psyms_seen_size): Likewise.
13146 (write_gdbindex): Replace objfile parameter with
13147 dwarf2_per_objfile.
13148 (write_debug_names): Likewise.
13149 (write_psymtabs_to_index): Likewise.
13150 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
13153 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13155 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
13156 <dwarf2_per_objfile>: New field.
13157 (struct dwarf2_per_cu_data) <objfile>: Remove.
13158 <dwarf2_per_objfile>: New field.
13159 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
13161 (create_signatured_type_table_from_index): Likewise.
13162 (create_debug_type_hash_table): Likewise.
13163 (fill_in_sig_entry_from_dwo_entry): Likewise.
13164 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
13165 (create_type_unit_group): Assign dwarf2_per_objfile instead of
13167 (create_partial_symtab): Access objfile through
13168 dwarf2_per_objfile.
13169 (process_psymtab_comp_unit_reader): Likewise.
13170 (read_comp_units_from_section): Likewise.
13171 (scan_partial_symbols): Likewise.
13172 (add_partial_symbol): Likewise.
13173 (add_partial_subprogram): Likewise.
13174 (peek_die_abbrev): Likewise.
13175 (fixup_go_packaging): Likewise.
13176 (process_full_comp_unit): Likewise.
13177 (process_full_type_unit): Likewise.
13178 (process_imported_unit_die): Likewise.
13179 (dwarf2_compute_name): Likewise.
13180 (dwarf2_physname): Likewise.
13181 (read_import_statement): Likewise.
13182 (create_cus_hash_table): Assign dwarf2_physname instead of
13184 (read_func_scope): Access objfile through dwarf2_per_objfile.
13185 (read_lexical_block_scope): Likewise.
13186 (read_call_site_scope): Likewise.
13187 (read_variable): Likewise.
13188 (dwarf2_rnglists_process): Likewise.
13189 (dwarf2_ranges_process): Likewise.
13190 (dwarf2_ranges_read): Likewise.
13191 (dwarf2_record_block_ranges): Likewise.
13192 (dwarf2_add_field): Likewise.
13193 (dwarf2_add_member_fn): Likewise.
13194 (read_structure_type): Likewise.
13195 (process_structure_scope): Likewise.
13196 (read_enumeration_type): Likewise.
13197 (read_array_type): Likewise.
13198 (read_common_block): Likewise.
13199 (read_namespace_type): Likewise.
13200 (read_namespace): Likewise.
13201 (read_module_type): Likewise.
13202 (read_tag_pointer_type): Likewise.
13203 (read_tag_ptr_to_member_type): Likewise.
13204 (read_tag_string_type): Likewise.
13205 (read_subroutine_type): Likewise.
13206 (read_typedef): Likewise.
13207 (read_base_type): Likewise.
13208 (attr_to_dynamic_prop): Likewise.
13209 (read_subrange_type): Likewise.
13210 (read_unspecified_type): Likewise.
13211 (load_partial_dies): Likewise.
13212 (read_partial_die): Likewise.
13213 (find_partial_die): Likewise.
13214 (guess_partial_die_structure_name): Likewise.
13215 (fixup_partial_die): Likewise.
13216 (read_attribute_value): Likewise.
13217 (read_addr_index_from_leb128): Likewise.
13218 (dwarf2_read_addr_index): Likewise.
13219 (dwarf2_string_attr): Likewise.
13220 (lnp_state_machine::check_line_address): Likewise.
13221 (dwarf_decode_lines_1): Likewise.
13222 (dwarf_decode_lines): Likewise.
13223 (dwarf2_start_symtab): Likewise.
13224 (var_decode_location): Likewise.
13225 (new_symbol_full): Likewise.
13226 (dwarf2_const_value_data): Likewise.
13227 (dwarf2_const_value_attr): Likewise.
13228 (dwarf2_const_value): Likewise.
13229 (die_type): Likewise.
13230 (die_containing_type): Likewise.
13231 (lookup_die_type): Likewise.
13232 (guess_full_die_structure_name): Likewise.
13233 (anonymous_struct_prefix): Likewise.
13234 (dwarf2_name): Likewise.
13235 (follow_die_ref_or_sig): Likewise.
13236 (follow_die_offset): Likewise.
13237 (follow_die_ref): Likewise.
13238 (dwarf2_fetch_die_loc_sect_off): Likewise.
13239 (dwarf2_fetch_constant_bytes): Likewise.
13240 (dwarf2_fetch_die_type_sect_off): Likewise.
13241 (dwarf2_get_die_type): Likewise.
13242 (follow_die_sig): Likewise.
13243 (decode_locdesc): Likewise.
13244 (dwarf2_per_cu_objfile): Likewise.
13245 (dwarf2_per_cu_text_offset): Likewise.
13246 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
13248 (set_die_type): Access objfile through
13249 dwarf2_per_objfile.
13251 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13253 * valprint.c (converted_character_d): Remove typedef.
13254 (DEF_VEC_O (converted_character_d)): Remove.
13255 (count_next_character): Use std::vector.
13256 (print_converted_chars_to_obstack): Likewise.
13257 (generic_printstr): Likewise.
13259 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13261 * xml-support.h (struct gdb_xml_value): Add constructor.
13262 <value>: Change type to unique_xmalloc_ptr.
13263 (gdb_xml_value_s): Remove typedef.
13264 (DEF_VEC_O (gdb_xml_value_s)): Remove.
13265 (gdb_xml_element_start_handler): Change parameter type to
13267 (xml_find_attribute): Likewise.
13268 * xml-support.c (xml_find_attribute): Change parameter type to
13269 std::vector and adjust.
13270 (gdb_xml_values_cleanup): Remove.
13271 (gdb_xml_parser::start_element): Adjust to std::vector.
13272 (xinclude_start_include): Change paraeter type to std::vector
13274 * btrace.c (check_xml_btrace_version): Likewise.
13275 (parse_xml_btrace_block): Likewise.
13276 (parse_xml_btrace_pt_config_cpu): Likewise.
13277 (parse_xml_btrace_pt): Likewise.
13278 (parse_xml_btrace_conf_bts): Likewise.
13279 (parse_xml_btrace_conf_pt): Likewise.
13280 * memory-map.c (memory_map_start_memory): Likewise.
13281 (memory_map_start_property): Likewise.
13282 * osdata.c (osdata_start_osdata): Likewise.
13283 (osdata_start_item): Likewise.
13284 (osdata_start_column): Likewise.
13285 * remote.c (start_thread): Likewise.
13286 * solib-aix.c (library_list_start_library): Likewise.
13287 (library_list_start_list): Likewise.
13288 * solib-svr4.c (library_list_start_library): Likewise.
13289 (svr4_library_list_start_list): Likewise.
13290 * solib-target.c (library_list_start_segment): Likewise.
13291 (library_list_start_section): Likewise.
13292 (library_list_start_library): Likewise.
13293 (library_list_start_list): Likewise.
13294 * tracepoint.c (traceframe_info_start_memory): Likewise.
13295 (traceframe_info_start_tvar): Likewise.
13296 * xml-syscall.c (syscall_start_syscall): Likewise.
13297 * xml-tdesc.c (tdesc_start_target): Likewise.
13298 (tdesc_start_feature): Likewise.
13299 (tdesc_start_reg): Likewise.
13300 (tdesc_start_union): Likewise.
13301 (tdesc_start_struct): Likewise.
13302 (tdesc_start_flags): Likewise.
13303 (tdesc_start_enum): Likewise.
13304 (tdesc_start_field): Likewise.
13305 (tdesc_start_enum_value): Likewise.
13306 (tdesc_start_vector): Likewise.
13308 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13310 * extension.h (struct xmethod_worker) <clone>: Remove.
13311 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
13313 (python_xmethod_worker::clone): Remove.
13314 * valops.c (find_overload_match): Use std::move instead of
13317 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13319 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
13320 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
13321 <free_xmethod_worker_data>: Remove.
13322 <get_matching_xmethod_workers>: Chance VEC to std::vector.
13323 <get_xmethod_arg_types>: Remove.
13324 <get_xmethod_result_type>: Remove.
13325 <invoke_xmethod>: Remove.
13326 * extension.c (new_xmethod_worker): Remove.
13327 (clone_xmethod_worker): Remove.
13328 (get_matching_xmethod_workers): Return void, pass std::vector by
13330 (get_xmethod_arg_types): Rename to...
13331 (xmethod_worker::get_arg_types): ... this, and adjust.
13332 (get_xmethod_result_type): Rename to...
13333 (xmethod_worker::get_result_type): ... this, and adjust.
13334 (invoke_xmethod): Remove.
13335 (free_xmethod_worker): Remove.
13336 (free_xmethod_worker_vec): Remove.
13337 * extension.h (enum ext_lang_rc): Move here from
13339 (struct xmethod_worker): Add constructor and destructor.
13342 <invoke, clone, do_get_result_type, do_get_arg_types>: New
13343 virtual pure methods.
13344 <get_arg_types, get_result_type>: New methods.
13345 (xmethod_worker_ptr): Remove typedef.
13346 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
13347 (xmethod_worker_vec): Remove typedef.
13348 (xmethod_worker_up): New typedef.
13349 (invoke_xmethod): Remove.
13350 (clone_xmethod_worker): Remove.
13351 (free_xmethod_worker): Remove.
13352 (free_xmethod_worker_vec): Remove.
13353 (get_xmethod_arg_types): Remove.
13354 (get_xmethod_result_type): Remove.
13355 * valops.c (find_method_list): Use std::vector, don't use
13356 intermediate vector.
13357 (value_find_oload_method_list): Use std::vector.
13358 (find_overload_match): Use std::vector.
13359 (find_oload_champ): Use std::vector.
13360 * value.c (value_free): Use operator delete.
13361 (value_of_xmethod): Rename to...
13362 (value_from_xmethod): ... this. Don't assign
13363 xmethod_worker::value, take rvalue-reference.
13364 (result_type_of_xmethod): Adjust.
13365 (call_xmethod): Adjust.
13366 * value.h: Include extension.h.
13367 (struct xmethod_worker): Don't forward-declare.
13368 (value_of_xmethod): Rename to...
13369 (value_from_xmethod): ... this, take rvalue-reference.
13370 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
13371 (struct python_xmethod_worker): ... this, add constructor and
13373 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
13374 (gdbpy_free_xmethod_worker_data): Rename to...
13375 (python_xmethod_worker::~python_xmethod_worker): ... this and
13377 (gdbpy_clone_xmethod_worker_data): Rename to...
13378 (python_xmethod_worker::clone): ... this and adjust.
13379 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
13381 (gdbpy_get_xmethod_arg_types): Rename to...
13382 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
13383 (gdbpy_get_xmethod_result_type): Rename to...
13384 (python_xmethod_worker::do_get_result_type): ... this and
13386 (gdbpy_invoke_xmethod): Rename to...
13387 (python_xmethod_worker::invoke): ... this and adjust.
13388 (new_python_xmethod_worker): Rename to...
13389 (python_xmethod_worker::python_xmethod_worker): ... this and
13391 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
13393 (gdbpy_free_xmethod_worker_data): Remove.
13394 (gdbpy_get_matching_xmethod_workers): Use std::vector.
13395 (gdbpy_get_xmethod_arg_types): Remove.
13396 (gdbpy_get_xmethod_result_type): Remove.
13397 (gdbpy_invoke_xmethod): Remove.
13398 * python/python.c (python_extension_ops): Remove obsolete
13401 2018-01-05 Pedro Alves <palves@redhat.com>
13404 * common/signals-state-save-restore.c
13405 (save_original_signals_state): New parameter 'quiet'. Warn if we
13406 find a custom handler preinstalled, instead of internal erroring.
13407 But only warn if !quiet.
13408 * common/signals-state-save-restore.h
13409 (save_original_signals_state): New parameter 'quiet'.
13410 * main.c (captured_main_1): Move save_original_signals_state call
13411 after option handling, and pass QUIET.
13413 2018-01-05 Pedro Alves <palves@redhat.com>
13415 * spu-tdep.c (spu_catch_start): Pass
13416 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
13418 2018-01-05 Pedro Alves <palves@redhat.com>
13421 * ada-lang.c (literal_symbol_name_matcher): New function.
13422 (ada_get_symbol_name_matcher): Use it for
13423 symbol_name_match_type::SEARCH_NAME.
13424 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
13425 it down instead of assuming symbol_name_match_type::FULL.
13426 * block.h (block_lookup_symbol): New parameter 'match_type'.
13427 * c-valprint.c (print_unpacked_pointer): Use
13428 lookup_symbol_search_name instead of lookup_symbol.
13429 * compile/compile-object-load.c (get_out_value_type): Pass down
13430 symbol_name_match_type::SEARCH_NAME.
13431 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
13432 symbol_name_match_type::FULL.
13433 * cp-support.c (cp_get_symbol_name_matcher): Handle
13434 symbol_name_match_type::SEARCH_NAME.
13435 * infrun.c (insert_exception_resume_breakpoint): Use
13436 lookup_symbol_search_name.
13437 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
13438 * psymtab.c (maintenance_check_psymtabs): Use
13439 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
13440 * stack.c (print_frame_args): Use lookup_symbol_search_name and
13441 SYMBOL_SEARCH_NAME.
13442 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
13443 if symbol_name_match_type::SEARCH_NAME.
13444 (lookup_symbol_in_language): Pass down
13445 symbol_name_match_type::FULL.
13446 (lookup_symbol_search_name): New.
13447 (lookup_language_this): Pass down
13448 symbol_name_match_type::SEARCH_NAME.
13449 (lookup_symbol_aux, lookup_local_symbol): New parameter
13450 'match_type'. Pass it down.
13451 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
13452 (lookup_symbol_search_name): New declaration.
13453 (lookup_symbol_in_block): New 'match_type' parameter.
13455 2018-01-05 Pedro Alves <palves@redhat.com>
13458 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
13460 (ada_lookup_symbol): Reimplement in terms of
13461 ada_lookup_symbol_list, bits factored out from
13462 ada_lookup_encoded_symbol.
13464 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13466 * ada-exp.y (write_object_renaming): When subscripting an array
13467 using a symbol as the index, pass the block in call to
13468 ada_lookup_encoded_symbol when looking that symbol up.
13470 2018-01-05 Jerome Guitton <guitton@adacore.com>
13472 * ada-lang.c (ada_array_length): Use ada_index_type instead of
13475 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13477 * ada-lang.c (ada_to_fixed_value_create): Add handling of
13478 the case where VALUE_LVAL (val0) is not lval_memory.
13480 2018-01-05 Xavier Roirand <roirand@adacore.com>
13482 * ada-valprint.c (print_optional_low_bound): Handle
13483 character-indexed array printing like boolean-indexed array
13486 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13488 * NEWS: Create a new section for the next release branch.
13489 Rename the section of the current branch, now that it has
13492 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13494 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
13495 * version.in: Bump version to 8.1.50.DATE-git.
13497 2018-01-03 Xavier Roirand <roirand@adacore.com>
13499 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
13501 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
13503 (default_exception_support_info) <catch_handlers_sym>: Add field.
13504 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
13505 (ada_exception_name_addr_1): Add "catch handlers" handling.
13506 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
13507 Update all callers.
13508 (create_excep_cond_exprs) <ex>: Add parameter.
13509 (re_set_exception): Update create_excep_cond_exprs call.
13510 (print_it_exception, print_one_exception, print_mention_exception)
13511 (print_recreate_exception): Add "catch handler" handling.
13512 (allocate_location_catch_handlers, re_set_catch_handlers)
13513 (check_status_catch_handlers, print_it_catch_handlers)
13514 (print_one_catch_handlers, print_mention_catch_handlers)
13515 (print_recreate_catch_handlers): New function.
13516 (catch_handlers_breakpoint_ops): New variable.
13517 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
13518 Add parameter. Add "catch handler" handling.
13519 (ada_exception_sym_name, ada_exception_breakpoint_ops):
13520 Add "catch handler" handling.
13521 (ada_exception_catchpoint_cond_string): Add "catch handler"
13523 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
13525 (catch_ada_handlers_command): New function.
13526 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
13527 operations structure.
13528 (_initialize_ada_language): Add "catch handlers" command entry.
13529 * NEWS: Document "catch handlers" feature.
13531 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13533 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
13534 account when creating the array type of the slice.
13535 (ada_value_slice): Likewise.
13537 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13539 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
13541 (create_array_type_with_stride): Add byte_stride_prop parameter.
13542 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
13543 New parameter. Update all callers in this file.
13544 (array_type_has_dynamic_stride): New function.
13545 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
13546 of arrays with dynamic byte strides.
13547 * dwarf2read.c (read_array_type): Add support for dynamic
13548 DW_AT_byte_stride attributes.
13550 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13552 * dwarf2read.c (read_unspecified_type): Treat
13553 DW_TAG_enumeration_type DIEs from Ada units as stubs.
13555 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13557 Update copyright year range in all GDB files.
13559 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13561 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
13562 and gdb/testsuite/gdb.base/step-line.c.
13564 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13566 * copyright.py (main): Dump the contents of
13567 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
13568 even if BY_HAND is empty.
13570 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13572 * top.c (print_gdb_version): Update Copyright year in version
13575 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13577 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
13579 For older changes see ChangeLog-2017.
13585 version-control: never