]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - gdb/ChangeLog
Remove two infrun cleanups
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
1 2018-09-17 Tom Tromey <tom@tromey.com>
2
3 * inferior.h (struct infcall_suspend_state_deleter): New.
4 (infcall_suspend_state_up): New typedef.
5 (struct infcall_control_state_deleter): New.
6 (infcall_control_state_up): New typedef.
7 (make_cleanup_restore_infcall_suspend_state)
8 (make_cleanup_restore_infcall_control_state): Don't declare.
9 * infcall.c (call_function_by_hand_dummy): Update.
10 * infrun.c (do_restore_infcall_suspend_state_cleanup)
11 (make_cleanup_restore_infcall_suspend_state): Remove.
12 (do_restore_infcall_control_state_cleanup)
13 (make_cleanup_restore_infcall_control_state): Remove.
14
15 2018-09-17 Tom Tromey <tom@tromey.com>
16
17 * gdbthread.h (struct thread_control_state): Add initializer.
18 (class thread_info) <control>: Remove initializer.
19 * inferior.h (struct inferior_control_state): Add initializer.
20 (class inferior) <control>: Remove initializer.
21 (exit_inferior_1): Update.
22 * infrun.c (struct infcall_control_state): Add constructors.
23 (save_infcall_control_state): Use new.
24 (restore_infcall_control_state, discard_infcall_control_state):
25 Use delete.
26
27 2018-09-17 Tom Tromey <tom@tromey.com>
28
29 * infrun.c (struct infcall_suspend_state) <registers>: Now a
30 unique_ptr.
31 <siginfo_data>: Now a unique_xmalloc_ptr.
32 (save_infcall_suspend_state, restore_infcall_suspend_state)
33 (discard_infcall_suspend_state)
34 (get_infcall_suspend_state_regcache): Update.
35
36 2018-09-17 Tom Tromey <tom@tromey.com>
37
38 * gdbthread.h (struct thread_suspend_state): Add initializers.
39 (class thread_info) <suspend>: Remove initializer.
40 * infrun.c (struct infcall_suspend_state): Add initializers.
41 (save_infcall_suspend_state): Use new.
42 (discard_infcall_suspend_state): Use delete.
43
44 2018-09-16 Tom Tromey <tom@tromey.com>
45
46 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
47 Remove.
48 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
49 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
50 (py_varobj_iter_new): Likewise.
51 (py_varobj_get_iterator): Use gdbpy_ref.
52
53 2018-09-16 Tom Tromey <tom@tromey.com>
54
55 * python/py-threadevent.c (py_get_event_thread): Simplify.
56 * python/py-inferior.c (infpy_thread_from_thread_handle):
57 Return immediately after calling thread_to_thread_object. Use
58 Py_RETURN_NONE.
59 (thread_to_thread_object): Set the exception on a NULL return.
60
61 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
62
63 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
64
65 2018-09-16 Tom Tromey <tom@tromey.com>
66
67 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
68 Remove.
69
70 2018-09-16 Tom Tromey <tom@tromey.com>
71
72 * python/python-internal.h (thread_to_thread_object): Change
73 return type.
74 * python/py-inferior.c (thread_to_thread_object): Return a new
75 reference.
76 (infpy_thread_from_thread_handle): Update.
77 * python/py-infthread.c (gdbpy_selected_thread): Update.
78 * python/py-stopevent.c (create_stop_event_object): Update.
79 * python/py-threadevent.c (py_get_event_thread): Return a new
80 reference.
81 (py_get_event_thread): Update.
82 * python/py-event.h (py_get_event_thread): Change return type.
83 * python/py-continueevent.c (create_continue_event_object):
84 Update.
85
86 2018-09-16 Tom Tromey <tom@tromey.com>
87
88 * python/py-progspace.c (pspy_get_objfiles): Update.
89 * python/python-internal.h (objfile_to_objfile_object): Change
90 return type.
91 * python/py-newobjfileevent.c (create_new_objfile_event_object):
92 Update.
93 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
94 Update.
95 * python/python.c (gdbpy_get_current_objfile): Update.
96 (gdbpy_objfiles): Update.
97 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
98 Update.
99 (objfile_to_objfile_object): Return a new reference.
100 * python/py-symtab.c (stpy_get_objfile): Update.
101 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
102 Update.
103
104 2018-09-16 Tom Tromey <tom@tromey.com>
105
106 * python/py-inferior.c (infpy_get_progspace): Update.
107 * python/python-internal.h (pspace_to_pspace_object): Change
108 return type.
109 * python/py-newobjfileevent.c
110 (create_clear_objfiles_event_object): Update.
111 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
112 Update.
113 * python/python.c (gdbpy_get_current_progspace): Update.
114 (gdbpy_progspaces): Update.
115 * python/py-progspace.c (pspace_to_pspace_object): Return a new
116 reference.
117 * python/py-objfile.c (objfpy_get_progspace): Update.
118 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
119 Update.
120
121 2018-09-16 Tom Tromey <tom@tromey.com>
122
123 * python/lib/gdb/__init__.py (current_progspace, objfiles)
124 (solib_name, block_for_pc, find_pc_line): New functions.
125 (execute_unwinders): Update.
126 * python/py-block.c (gdbpy_block_for_pc): Remove.
127 * python/py-inferior.c (infpy_get_progspace): New function.
128 (inferior_object_getset) <progspace>: Add.
129 * python/py-progspace.c (pspy_objfiles): Rewrite.
130 (pspy_solib_name, pspy_block_for_pc)
131 (pspy_find_pc_line, pspy_is_valid): New functions.
132 (progspace_object_methods): Add entries for solib_name,
133 block_for_pc, find_pc_line, is_valid.
134 * python/python-internal.h (gdbpy_block_for_pc)
135 (build_objfiles_list): Don't declare.
136 * python/python.c: Don't include solib.h.
137 (gdbpy_solib_name, gdbpy_find_pc_line)
138 (gdbpy_get_current_progspace, build_objfiles_list)
139 (gdbpy_objfiles): Remove.
140 (GdbMethods) <current_progspace, objfiles, block_for_pc,
141 solib_name, find_pc_line>: Remove entries.
142
143 2018-09-16 Tom Tromey <tom@tromey.com>
144
145 * top.c (new_ui_command): Use GNU style for metasyntactic
146 variables.
147 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
148 variables.
149 * maint.c (maintenance_translate_address): Remove "<>" around
150 text.
151 * interps.c (interpreter_exec_cmd): Use GNU style for
152 metasyntactic variables.
153 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
154 metasyntactic variables.
155 * tracepoint.c (tfind_range_command): Use GNU style for
156 metasyntactic variables.
157 (tfind_outside_command): Likewise.
158 (_initialize_tracepoint): Likewise.
159 * remote.c (extended_remote_target::create_inferior): Use GNU
160 style for metasyntactic variables.
161 * sparc64-tdep.c (adi_examine_command): Use GNU style for
162 metasyntactic variables.
163 (adi_assign_command): Likewise.
164
165 2018-09-16 Tom Tromey <tom@tromey.com>
166
167 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
168 metasyntactic variables. Print message if no disassembler options
169 are available.
170
171 2018-09-15 Tom Tromey <tom@tromey.com>
172
173 * infcmd.c (get_inferior_args): Return const char *.
174 * inferior.h (get_inferior_args): Return type now const.
175 * linux-tdep.c (linux_fill_prpsinfo): Update.
176 * procfs.c (procfs_target::make_corefile_notes): Update.
177
178 2018-09-07 Tom Tromey <tom@tromey.com>
179
180 * python/python.c (execute_gdb_command): Call bpstat_do_actions
181 inside the TRY.
182
183 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
184
185 * nios2-tdep.c (nios2_type_align): New.
186 (nios2_gdb_arch_init): Install type_align hook.
187
188 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
189
190 * eval.c (fake_method::fake_method): Call xzalloc directly for a
191 type that is neither object file owned, nor gdbarch owned.
192 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
193 gdbarch is non-NULL.
194 (alloc_type_instance): Allocate non-objfile owned types on the
195 gdbarch obstack.
196 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
197 using TYPE_ALLOC to ensure memory is allocated on the correct
198 obstack.
199 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
200 obstack, or the gdbarch obstack.
201 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
202
203 2018-09-14 Tom Tromey <tom@tromey.com>
204
205 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
206 block.
207
208 2018-09-14 Tom Tromey <tom@tromey.com>
209
210 * nat/fork-inferior.c (get_startup_shell): Remove "static".
211
212 2018-09-13 Tom Tromey <tom@tromey.com>
213
214 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
215 static.
216
217 2018-09-13 Tom Tromey <tom@tromey.com>
218
219 * exec.c (try_open_exec_file): Use std::string.
220
221 2018-09-13 Tom Tromey <tom@tromey.com>
222
223 * utils.h (gdb_bfd_errmsg): Return std::string.
224 * exec.c (exec_file_attach): Update.
225 * compile/compile-object-load.c (compile_object_load): Update.
226 * utils.c (gdb_bfd_errmsg): Return std::string.
227
228 2018-09-13 Tom Tromey <tom@tromey.com>
229
230 * procfs.c (struct procinfo_deleter): New.
231 (procinfo_up): New typedef.
232 (do_destroy_procinfo_cleanup): Remove.
233 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
234
235 2018-09-13 Tom Tromey <tom@tromey.com>
236
237 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
238
239 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
240 2018-09-13 Tom Tromey <tom@tromey.com>
241
242 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
243 (pspy_get_objfiles): New function.
244 (progspace_object_methods): New.
245 (pspace_object_type): Add tp_methods callback.
246 * python/python-internal.h (build_objfiles_list): New
247 declaration.
248 * python/python.c (build_objfiles_list): New function.
249 (gdbpy_objfiles): Implement using build_objfiles_list.
250 * NEWS: Mention the Progspace.objfiles method.
251
252 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
253
254 * python/py-inferior.c (infpy_get_progspace): New function.
255 (inferior_object_getset): Add progspace property.
256 * NEWS: Mention the new property.
257
258 2018-09-13 Tom Tromey <tom@tromey.com>
259
260 PR rust/23650:
261 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
262
263 2018-09-13 Tom Tromey <tom@tromey.com>
264
265 PR rust/23626:
266 * rust-lang.c (rust_enum_variant): Now static.
267 (rust_empty_enum_p): New function.
268 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
269 Handle empty enum.
270
271 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
272
273 * python/py-inferior.c (infpy_repr): New.
274 (inferior_object_type): Register infpy_repr.
275 * python/py-objfile.c (objfpy_repr): New.
276 (objfile_object_type): Register objfpy_repr.
277
278 2018-09-12 John Baldwin <jhb@FreeBSD.org>
279
280 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
281
282 2018-09-12 John Baldwin <jhb@FreeBSD.org>
283
284 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
285 typo.
286
287 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
288
289 * common/common-utils.c: Don't include '<sys/stat.h>'.
290 (is_regular_file): Move to...
291 * common/filestuff.c (is_regular_file): ... here.
292 * common/common-utils.h (is_regular_file): Move to...
293 * common/filestuff.h (is_regular_file): ... here.
294
295 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
296
297 * skip.c (debug_skip): New variable.
298 (skiplist_entry::do_skip_file_p): Add debug output.
299 (skiplist_entry::do_skip_gfile_p): Likewise.
300 (skiplist_entry::skip_function_p): Likewise.
301 (_initialize_step_skip): Create debug command.
302 * NEWS: Mention set/show debug skip.
303
304 2018-09-11 Xavier Roirand <roirand@adacore.com>
305
306 * darwin-nat.c (should_disable_startup_with_shell):
307 New function.
308 (darwin_nat_target::create_inferior): Add call.
309
310 2018-09-11 Xavier Roirand <roirand@adacore.com>
311
312 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
313 inf_port, msg_state>: Initialize.
314 (struct darwin_thread_info) <signaled, single_step>: Change
315 type and initialize.
316 (struct darwin_thread_info) <event>: Initialize.
317
318 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
319
320 PR gdb/23555
321 PR gdb/23558
322 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
323 guesses.
324
325 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
326
327 Revert:
328 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
329
330 PR gdb/23555
331 PR gdb/23558
332 * gnulib/aclocal.m4: Regenerate.
333 * gnulib/config.in: Regenerate.
334 * gnulib/configure: Regenerate.
335 * gnulib/import/Makefile.am: Update.
336 * gnulib/import/Makefile.in: Update.
337 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
338 * gnulib/import/_Noreturn.h: ... this.
339 * gnulib/import/alloca.in.h: Update.
340 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
341 * gnulib/import/arg-nonnull.h: ... this.
342 * gnulib/import/assure.h: Update.
343 * gnulib/import/at-func.c: Update.
344 * gnulib/import/basename-lgpl.c: Update.
345 * gnulib/import/extra/snippet/c++defs.h: Rename to...
346 * gnulib/import/c++defs.h: ... this.
347 * gnulib/import/canonicalize-lgpl.c: Update.
348 * gnulib/import/cdefs.h: Update.
349 * gnulib/import/chdir-long.c: Update.
350 * gnulib/import/chdir-long.h: Update.
351 * gnulib/import/cloexec.c: Update.
352 * gnulib/import/cloexec.h: Update.
353 * gnulib/import/close.c: Update.
354 * gnulib/import/closedir.c: Update.
355 * gnulib/import/config.charset: Update.
356 * gnulib/import/dirent-private.h: Update.
357 * gnulib/import/dirent.in.h: Update.
358 * gnulib/import/dirfd.c: Update.
359 * gnulib/import/dirname-lgpl.c: Update.
360 * gnulib/import/dirname.h: Update.
361 * gnulib/import/dosname.h: Update.
362 * gnulib/import/dup-safer-flag.c: Update.
363 * gnulib/import/dup-safer.c: Update.
364 * gnulib/import/dup.c: Update.
365 * gnulib/import/dup2.c: Update.
366 * gnulib/import/errno.in.h: Update.
367 * gnulib/import/error.c: Update.
368 * gnulib/import/error.h: Update.
369 * gnulib/import/exitfail.c: Update.
370 * gnulib/import/exitfail.h: Update.
371 * gnulib/import/extra/update-copyright: Update.
372 * gnulib/import/fchdir.c: Update.
373 * gnulib/import/fcntl.c: Update.
374 * gnulib/import/fcntl.in.h: Update.
375 * gnulib/import/fd-hook.c: Update.
376 * gnulib/import/fd-hook.h: Update.
377 * gnulib/import/fd-safer-flag.c: Update.
378 * gnulib/import/fd-safer.c: Update.
379 * gnulib/import/fdopendir.c: Update.
380 * gnulib/import/filename.h: Update.
381 * gnulib/import/filenamecat-lgpl.c: Update.
382 * gnulib/import/filenamecat.h: Update.
383 * gnulib/import/flexmember.h: Update.
384 * gnulib/import/float+.h: Update.
385 * gnulib/import/float.c: Update.
386 * gnulib/import/float.in.h: Update.
387 * gnulib/import/fnmatch.c: Update.
388 * gnulib/import/fnmatch.in.h: Update.
389 * gnulib/import/fnmatch_loop.c: Update.
390 * gnulib/import/fpucw.h: Update.
391 * gnulib/import/frexp.c: Update.
392 * gnulib/import/frexpl.c: Update.
393 * gnulib/import/fstat.c: Update.
394 * gnulib/import/fstatat.c: Update.
395 * gnulib/import/getcwd-lgpl.c: Update.
396 * gnulib/import/getcwd.c: Update.
397 * gnulib/import/getdtablesize.c: Update.
398 * gnulib/import/getlogin_r.c: Update.
399 * gnulib/import/getprogname.c: Update.
400 * gnulib/import/getprogname.h: Update.
401 * gnulib/import/gettext.h: Update.
402 * gnulib/import/gettimeofday.c: Update.
403 * gnulib/import/glob-libc.h: Update.
404 * gnulib/import/glob.c: Update.
405 * gnulib/import/glob.in.h: Update.
406 * gnulib/import/glob_internal.h: Update.
407 * gnulib/import/glob_pattern_p.c: Update.
408 * gnulib/import/globfree.c: Update.
409 * gnulib/import/hard-locale.c: Update.
410 * gnulib/import/hard-locale.h: Update.
411 * gnulib/import/intprops.h: Update.
412 * gnulib/import/inttypes.in.h: Update.
413 * gnulib/import/isnan.c: Update.
414 * gnulib/import/isnand-nolibm.h: Update.
415 * gnulib/import/isnand.c: Update.
416 * gnulib/import/isnanl-nolibm.h: Update.
417 * gnulib/import/isnanl.c: Update.
418 * gnulib/import/itold.c: Update.
419 * gnulib/import/libc-config.h: Update.
420 * gnulib/import/limits.in.h: Update.
421 * gnulib/import/localcharset.c: Update.
422 * gnulib/import/localcharset.h: Update.
423 * gnulib/import/localtime-buffer.c: Update.
424 * gnulib/import/localtime-buffer.h: Update.
425 * gnulib/import/lstat.c: Update.
426 * gnulib/import/m4/00gnulib.m4: Update.
427 * gnulib/import/m4/__inline.m4: Update.
428 * gnulib/import/m4/absolute-header.m4: Update.
429 * gnulib/import/m4/alloca.m4: Update.
430 * gnulib/import/m4/builtin-expect.m4: Update.
431 * gnulib/import/m4/canonicalize.m4: Update.
432 * gnulib/import/m4/chdir-long.m4: Update.
433 * gnulib/import/m4/close.m4: Update.
434 * gnulib/import/m4/closedir.m4: Update.
435 * gnulib/import/m4/configmake.m4: Update.
436 * gnulib/import/m4/d-ino.m4: Update.
437 * gnulib/import/m4/d-type.m4: Update.
438 * gnulib/import/m4/dirent_h.m4: Update.
439 * gnulib/import/m4/dirfd.m4: Update.
440 * gnulib/import/m4/dirname.m4: Update.
441 * gnulib/import/m4/double-slash-root.m4: Update.
442 * gnulib/import/m4/dup.m4: Update.
443 * gnulib/import/m4/dup2.m4: Update.
444 * gnulib/import/m4/eealloc.m4: Update.
445 * gnulib/import/m4/environ.m4: Update.
446 * gnulib/import/m4/errno_h.m4: Update.
447 * gnulib/import/m4/error.m4: Update.
448 * gnulib/import/m4/exponentd.m4: Update.
449 * gnulib/import/m4/exponentl.m4: Update.
450 * gnulib/import/m4/extensions.m4: Update.
451 * gnulib/import/m4/extern-inline.m4: Update.
452 * gnulib/import/m4/fchdir.m4: Update.
453 * gnulib/import/m4/fcntl-o.m4: Update.
454 * gnulib/import/m4/fcntl.m4: Update.
455 * gnulib/import/m4/fcntl_h.m4: Update.
456 * gnulib/import/m4/fdopendir.m4: Update.
457 * gnulib/import/m4/filenamecat.m4: Update.
458 * gnulib/import/m4/flexmember.m4: Update.
459 * gnulib/import/m4/float_h.m4: Update.
460 * gnulib/import/m4/fnmatch.m4: Update.
461 * gnulib/import/m4/fnmatch_h.m4: Update.
462 * gnulib/import/m4/fpieee.m4: Update.
463 * gnulib/import/m4/frexp.m4: Update.
464 * gnulib/import/m4/frexpl.m4: Update.
465 * gnulib/import/m4/fstat.m4: Update.
466 * gnulib/import/m4/fstatat.m4: Update.
467 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
468 * gnulib/import/m4/getcwd-path-max.m4: Update.
469 * gnulib/import/m4/getcwd.m4: Update.
470 * gnulib/import/m4/getdtablesize.m4: Update.
471 * gnulib/import/m4/getlogin.m4: Update.
472 * gnulib/import/m4/getlogin_r.m4: Update.
473 * gnulib/import/m4/getpagesize.m4: Update.
474 * gnulib/import/m4/getprogname.m4: Update.
475 * gnulib/import/m4/gettimeofday.m4: Update.
476 * gnulib/import/m4/glibc21.m4: Update.
477 * gnulib/import/m4/glob.m4: Update.
478 * gnulib/import/m4/glob_h.m4: Update.
479 * gnulib/import/m4/gnulib-cache.m4: Update.
480 * gnulib/import/m4/gnulib-common.m4: Update.
481 * gnulib/import/m4/gnulib-comp.m4: Update.
482 * gnulib/import/m4/gnulib-tool.m4: Update.
483 * gnulib/import/m4/hard-locale.m4: Update.
484 * gnulib/import/m4/include_next.m4: Update.
485 * gnulib/import/m4/inttypes-pri.m4: Update.
486 * gnulib/import/m4/inttypes.m4: Update.
487 * gnulib/import/m4/isnand.m4: Update.
488 * gnulib/import/m4/isnanl.m4: Update.
489 * gnulib/import/m4/largefile.m4: Update.
490 * gnulib/import/m4/limits-h.m4: Update.
491 * gnulib/import/m4/localcharset.m4: Update.
492 * gnulib/import/m4/locale-fr.m4: Update.
493 * gnulib/import/m4/locale-ja.m4: Update.
494 * gnulib/import/m4/locale-zh.m4: Update.
495 * gnulib/import/m4/localtime-buffer.m4: Update.
496 * gnulib/import/m4/longlong.m4: Update.
497 * gnulib/import/m4/lstat.m4: Update.
498 * gnulib/import/m4/malloc.m4: Update.
499 * gnulib/import/m4/malloca.m4: Update.
500 * gnulib/import/m4/math_h.m4: Update.
501 * gnulib/import/m4/mbrtowc.m4: Update.
502 * gnulib/import/m4/mbsinit.m4: Update.
503 * gnulib/import/m4/mbsrtowcs.m4: Update.
504 * gnulib/import/m4/mbstate_t.m4: Update.
505 * gnulib/import/m4/memchr.m4: Update.
506 * gnulib/import/m4/memmem.m4: Update.
507 * gnulib/import/m4/mempcpy.m4: Update.
508 * gnulib/import/m4/memrchr.m4: Update.
509 * gnulib/import/m4/mkdir.m4: Update.
510 * gnulib/import/m4/mkstemp.m4: Update.
511 * gnulib/import/m4/mmap-anon.m4: Update.
512 * gnulib/import/m4/mode_t.m4: Update.
513 * gnulib/import/m4/msvc-inval.m4: Update.
514 * gnulib/import/m4/msvc-nothrow.m4: Update.
515 * gnulib/import/m4/multiarch.m4: Update.
516 * gnulib/import/m4/nocrash.m4: Update.
517 * gnulib/import/m4/off_t.m4: Update.
518 * gnulib/import/m4/onceonly.m4: Update.
519 * gnulib/import/m4/open-cloexec.m4: Update.
520 * gnulib/import/m4/open.m4: Update.
521 * gnulib/import/m4/openat.m4: Update.
522 * gnulib/import/m4/opendir.m4: Update.
523 * gnulib/import/m4/pathmax.m4: Update.
524 * gnulib/import/m4/rawmemchr.m4: Update.
525 * gnulib/import/m4/readdir.m4: Update.
526 * gnulib/import/m4/readlink.m4: Update.
527 * gnulib/import/m4/realloc.m4: Update.
528 * gnulib/import/m4/rename.m4: Update.
529 * gnulib/import/m4/rewinddir.m4: Update.
530 * gnulib/import/m4/rmdir.m4: Update.
531 * gnulib/import/m4/save-cwd.m4: Update.
532 * gnulib/import/m4/secure_getenv.m4: Update.
533 * gnulib/import/m4/setenv.m4: Update.
534 * gnulib/import/m4/signal_h.m4: Update.
535 * gnulib/import/m4/ssize_t.m4: Update.
536 * gnulib/import/m4/stat-time.m4: Update.
537 * gnulib/import/m4/stat.m4: Update.
538 * gnulib/import/m4/std-gnu11.m4: Update.
539 * gnulib/import/m4/stdbool.m4: Update.
540 * gnulib/import/m4/stddef_h.m4: Update.
541 * gnulib/import/m4/stdint.m4: Update.
542 * gnulib/import/m4/stdio_h.m4: Update.
543 * gnulib/import/m4/stdlib_h.m4: Update.
544 * gnulib/import/m4/strchrnul.m4: Update.
545 * gnulib/import/m4/strdup.m4: Update.
546 * gnulib/import/m4/strerror.m4: Update.
547 * gnulib/import/m4/string_h.m4: Update.
548 * gnulib/import/m4/strstr.m4: Update.
549 * gnulib/import/m4/strtok_r.m4: Update.
550 * gnulib/import/m4/sys_socket_h.m4: Update.
551 * gnulib/import/m4/sys_stat_h.m4: Update.
552 * gnulib/import/m4/sys_time_h.m4: Update.
553 * gnulib/import/m4/sys_types_h.m4: Update.
554 * gnulib/import/m4/tempname.m4: Update.
555 * gnulib/import/m4/time_h.m4: Update.
556 * gnulib/import/m4/unistd-safer.m4: Update.
557 * gnulib/import/m4/unistd_h.m4: Update.
558 * gnulib/import/m4/warn-on-use.m4: Update.
559 * gnulib/import/m4/wchar_h.m4: Update.
560 * gnulib/import/m4/wchar_t.m4: Update.
561 * gnulib/import/m4/wctype_h.m4: Update.
562 * gnulib/import/m4/wint_t.m4: Update.
563 * gnulib/import/malloc.c: Update.
564 * gnulib/import/malloc/scratch_buffer.h: Update.
565 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
566 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
567 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
568 * gnulib/import/malloca.c: Update.
569 * gnulib/import/malloca.h: Update.
570 * gnulib/import/malloca.valgrind: Update.
571 * gnulib/import/math.in.h: Update.
572 * gnulib/import/mbrtowc.c: Update.
573 * gnulib/import/mbsinit.c: Update.
574 * gnulib/import/mbsrtowcs-impl.h: Update.
575 * gnulib/import/mbsrtowcs-state.c: Update.
576 * gnulib/import/mbsrtowcs.c: Update.
577 * gnulib/import/memchr.c: Update.
578 * gnulib/import/memmem.c: Update.
579 * gnulib/import/mempcpy.c: Update.
580 * gnulib/import/memrchr.c: Update.
581 * gnulib/import/mkdir.c: Update.
582 * gnulib/import/mkstemp.c: Update.
583 * gnulib/import/msvc-inval.c: Update.
584 * gnulib/import/msvc-inval.h: Update.
585 * gnulib/import/msvc-nothrow.c: Update.
586 * gnulib/import/msvc-nothrow.h: Update.
587 * gnulib/import/open.c: Update.
588 * gnulib/import/openat-die.c: Update.
589 * gnulib/import/openat-priv.h: Update.
590 * gnulib/import/openat-proc.c: Update.
591 * gnulib/import/openat.c: Update.
592 * gnulib/import/openat.h: Update.
593 * gnulib/import/opendir.c: Update.
594 * gnulib/import/pathmax.h: Update.
595 * gnulib/import/pipe-safer.c: Update.
596 * gnulib/import/rawmemchr.c: Update.
597 * gnulib/import/readdir.c: Update.
598 * gnulib/import/readlink.c: Update.
599 * gnulib/import/realloc.c: Update.
600 * gnulib/import/ref-add.sin: Update.
601 * gnulib/import/ref-del.sin: Update.
602 * gnulib/import/rename.c: Update.
603 * gnulib/import/rewinddir.c: Update.
604 * gnulib/import/rmdir.c: Update.
605 * gnulib/import/same-inode.h: Update.
606 * gnulib/import/save-cwd.c: Update.
607 * gnulib/import/save-cwd.h: Update.
608 * gnulib/import/scratch_buffer.h: Update.
609 * gnulib/import/secure_getenv.c: Update.
610 * gnulib/import/setenv.c: Update.
611 * gnulib/import/signal.in.h: Update.
612 * gnulib/import/stat-time.c: Update.
613 * gnulib/import/stat-time.h: Update.
614 * gnulib/import/stat-w32.c: Update.
615 * gnulib/import/stat-w32.h: Update.
616 * gnulib/import/stat.c: Update.
617 * gnulib/import/stdbool.in.h: Update.
618 * gnulib/import/stddef.in.h: Update.
619 * gnulib/import/stdint.in.h: Update.
620 * gnulib/import/stdio.in.h: Update.
621 * gnulib/import/stdlib.in.h: Update.
622 * gnulib/import/str-two-way.h: Update.
623 * gnulib/import/strchrnul.c: Update.
624 * gnulib/import/strdup.c: Update.
625 * gnulib/import/streq.h: Update.
626 * gnulib/import/strerror-override.c: Update.
627 * gnulib/import/strerror-override.h: Update.
628 * gnulib/import/strerror.c: Update.
629 * gnulib/import/string.in.h: Update.
630 * gnulib/import/stripslash.c: Update.
631 * gnulib/import/strnlen1.c: Update.
632 * gnulib/import/strnlen1.h: Update.
633 * gnulib/import/strstr.c: Update.
634 * gnulib/import/strtok_r.c: Update.
635 * gnulib/import/sys_stat.in.h: Update.
636 * gnulib/import/sys_time.in.h: Update.
637 * gnulib/import/sys_types.in.h: Update.
638 * gnulib/import/tempname.c: Update.
639 * gnulib/import/tempname.h: Update.
640 * gnulib/import/time.in.h: Update.
641 * gnulib/import/unistd--.h: Update.
642 * gnulib/import/unistd-safer.h: Update.
643 * gnulib/import/unistd.in.h: Update.
644 * gnulib/import/unsetenv.c: Update.
645 * gnulib/import/verify.h: Update.
646 * gnulib/import/extra/snippet/warn-on-use.h: Update.
647 * gnulib/import/wchar.in.h: Update.
648 * gnulib/import/wctype.in.h: Update.
649 * gnulib/import/xalloc-oversized.h: Update.
650 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
651 "53e2c179f26a890fa6685af4b6c1397ee370433b".
652
653 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
654
655 * record-btrace.c (get_thread_current_frame): Remove
656 old_inferior_ptid.
657
658 2018-09-10 Jerome Guitton <guitton@adacore.com>
659
660 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
661 with check_tag to 1 if and only if the type is tagged and the
662 component being searched cannot been found in the current
663 view. Otherwise, always call ada_to_fixed_type with
664 check_tag to 0.
665
666 2018-09-10 Xavier Roirand <roirand@adacore.com>
667
668 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
669 declaration.
670 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
671 * ada-varobj.c (ada_varobj_get_number_of_children,
672 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
673
674 2018-09-10 Xavier Roirand <roirand@adacore.com>
675
676 * ada-valprint.c (ada_value_print): Use type instead of
677 enclosing type.
678
679 2018-09-10 Xavier Roirand <roirand@adacore.com>
680
681 * ada-lang.c (ada_value_subscript): Handle case when parameter is
682 an array of access to unconstrained array.
683
684 2018-09-10 Xavier Roirand <roirand@adacore.com>
685
686 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
687 (ada_check_typedef): Use it.
688
689 2018-09-10 Xavier Roirand <roirand@adacore.com>
690
691 * ada-varobj.c (ada_varobj_describe_struct_child)
692 (ada_varobj_describe_child): Handle union case like struct one.
693
694 2018-09-10 Tom Tromey <tom@tromey.com>
695
696 PR python/18380:
697 * python/python.c (_initialize_python): Make example in "python"
698 help work in Python 3.
699
700 2018-09-10 Eli Zaretskii <eliz@gnu.org>
701
702 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
703 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
704 $(EXEEXT) to the script, as it is not a program.
705
706 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
707
708 * python/py-prettyprint.c (pretty_print_one_value): Return
709 gdbpy_ref<>.
710 (print_string_repr): Adjust.
711 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
712 * python/python-internal.h (apply_varobj_pretty_printer): Return
713 gdbpy_ref<>.
714 * varobj.c (varobj_value_get_print_value): Adjust.
715
716 2018-09-08 Tom Tromey <tom@tromey.com>
717
718 PR python/16047:
719 * python/py-prettyprint.c (pretty_print_one_value): Check for
720 to_string method.
721
722 2018-09-08 Joel Brobecker <brobecker@adacore.com>
723
724 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
725 replace_operator_with_call.
726
727 2018-09-08 Joel Brobecker <brobecker@adacore.com>
728
729 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
730
731 2018-09-08 Joel Brobecker <brobecker@adacore.com>
732
733 * ada-typeprint.c (print_range): Print the bounds using TYPE
734 rather than its TYPE_TARGET_TYPE.
735
736 2018-09-08 Joel Brobecker <brobecker@adacore.com>
737
738 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
739 call to ada_to_fixed_value_create.
740
741 2018-09-08 Jerome Guitton <guitton@adacore.com>
742
743 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
744
745 2018-09-08 Joel Brobecker <brobecker@adacore.com>
746
747 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
748 by calls to error.
749
750 2018-09-08 Joel Brobecker <brobecker@adacore.com>
751
752 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
753 Move update of loop variable "fi".
754
755 2018-09-08 Joel Brobecker <brobecker@adacore.com>
756
757 * ada-lang.c (value_assign_to_component): In the case of
758 big-endian targets, extract the bits of the given VAL
759 using an src_offset of zero if container is not a scalar.
760
761 2018-09-06 Simon Ser <contact@emersion.fr>
762
763 PR gdb/23105
764 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
765 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
766 * fbsd-tdep.c (fbsd_make_note_desc): New.
767 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
768 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
769 * target.h (enum target_object) Add FreeBSD-specific
770 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
771
772 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
773
774 * compile/compile-c.h (generate_c_for_variable_locations):
775 Change reference to pointer.
776 * compile/compile-c-support.c (compile_program) <compute>:
777 Likewise.
778 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
779 (generate_c_for_for_one_variable): Likewise
780 (generate_c_for_variable_locations): Likewise
781 * compile/compile-c-types.c (compile_c_instance::convert_type):
782 Likewise
783 * compile/compile-cplus-symbols.c (convert_one_symbol):
784 std::move the scope passed to enter_scope.
785 * compile/compile-cplus-types.c
786 (compile_cplus_instance::enter_scope): Make parameter
787 rvalue-reference.
788 (compile_cplus_instance::new_scope): Change reference to
789 pointer.
790 (compile_cplus_instance::convert_type): Likewise
791 (compile_cplus_convert_typedef): std::move the scope passed to
792 enter_scope.
793 (compile_cplus_convert_struct_or_union): Likewise.
794 (compile_cplus_convert_enum): Likewise.
795 (compile_cplus_convert_namespace): Likewise.
796 * compile/compile-cplus.h (compile_cplus_instance)
797 <enter_scope>: Make parameter rvalue-reference.
798 * compile/compile-internal.h (compile_instance)
799 <get_cached_type>: Likewise
800 * compile/compile-loc2c.c (push): Likewise
801 (pushf): Likewise
802 (unary): Likewise
803 (binary): Likewise
804 (print_label): Likewise
805 (pushf_register_address): Likewise
806 (pushf_register): Likewise
807 (do_compile_dwarf_expr_to_c): Likewise
808 (compile_dwarf_expr_to_c): Likewise
809 (compile_dwarf_bounds_to_c): Likewise
810 * compile/compile.c (compile_instance::get_cached_type):
811 Likewise
812 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
813 (compile_dwarf_bounds_to_c): Likewise
814 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
815 (dwarf2_compile_property_to_c): Likewise
816 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
817 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
818 Likewise
819
820 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
821
822 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
823 * tui/tui-data.c (init_content_element): Don't initialize it.
824
825 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
826
827 * tui/tui-data.h (struct tui_win_info)
828 <detail::opaque>: Remove.
829 * tui/tui-data.c (init_win_info): Remove assignment.
830
831 2018-09-05 Tom Tromey <tom@tromey.com>
832
833 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
834 -Wformat-nonliteral.
835 * target-float.c (host_float_ops<T>::to_string)
836 (host_float_ops<T>::from_string): Use
837 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
838 * configure: Rebuild.
839
840 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
841
842 * printcmd.c (printf_c_string): Use
843 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
844 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
845
846 2018-09-05 Tom Tromey <tom@tromey.com>
847
848 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
849
850 2018-09-05 Tom de Vries <tdevries@suse.de>
851
852 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
853 with resolve_abstract_p == true.
854 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
855 defaulting to false. Propagate resolve_abstract_p to
856 dwarf2_fetch_die_loc_sect_off.
857 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
858 parameter, defaulting to false.
859 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
860 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
861 parameter.
862 * dwarf2read.h (struct die_info): Forward-declare.
863 (die_info_ptr): New typedef.
864 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
865
866 2018-09-05 Joel Brobecker <brobecker@adacore.com>
867
868 GDB 8.2 released.
869
870 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
871 Pedro Alves <palves@redhat.com>
872
873 * gnulib/Makefile.in (aclocal_m4_deps): Move to
874 "aclocal-m4-deps.mk". Include file here.
875 $(srcdir)/aclocal.m4: Add "configure.ac".
876 * gnulib/aclocal-m4-deps.mk: New file.
877 * gnulib/update-gnulib.sh: Automatically update
878 "aclocal-m4-deps.mk".
879
880 2018-09-04 Tom Tromey <tom@tromey.com>
881
882 * configure: Rebuild.
883 * configure.ac: Remove multi-ice code.
884
885 2018-09-04 Tom Tromey <tom@tromey.com>
886
887 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
888 (ada-exp.o): Update.
889
890 2018-09-04 Tom Tromey <tom@tromey.com>
891
892 * Makefile.in (printcmd.o, target-float.o): Remove.
893 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
894
895 2018-09-04 Tom Tromey <tom@tromey.com>
896
897 * gnulib/Makefile.in: Remove obsolete comment.
898 * Makefile.in: Remove obsolete comment.
899
900 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
901
902 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
903 line with '+'.
904
905 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
906
907 * riscv-tdep.c: Add 'prologue-value.h' include.
908 (struct riscv_unwind_cache): New struct.
909 (riscv_debug_unwinder): New global.
910 (riscv_scan_prologue): Update arguments, capture register details
911 from prologue scan.
912 (riscv_skip_prologue): Reformat arguments line, move end of
913 prologue calculation into riscv_scan_prologue.
914 (riscv_frame_cache): Update return type, create
915 riscv_unwind_cache, scan the prologue, and fill in remaining cache
916 details.
917 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
918 (riscv_frame_prev_register): Use the trad_frame within the
919 riscv_unwind_cache.
920 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
921 flag.
922
923 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
924
925 * trad-frame.h (trad_frame_set_realreg): Declare.
926 (trad_frame_set_addr): Declare.
927 * trad-frame.c (trad_frame_set_realreg): Define new function.
928 (trad_frame_set_addr): Define new function.
929 (trad_frame_set_reg_realreg): Use new function.
930 (trad_frame_set_reg_addr): Use new function.
931
932 2018-09-01 Keith Seitz <keiths@redhat.com>
933
934 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
935 pulongest instead of "%lld".
936 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
937 ATTRIBUTE_UNUSED.
938
939 2018-08-31 Tom Tromey <tom@tromey.com>
940
941 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
942 variant part type.
943
944 2018-08-31 Pedro Alves <palves@redhat.com>
945
946 * gdbarch.h: Regenerate.
947
948 2018-08-31 Pedro Alves <palves@redhat.com>
949
950 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
951 * target.h (Hardware watchpoint interfaces): Describe
952 continuable/steppable/non-steppable watchpoints.
953 * gdbarch.h, gdbarch.c: Regenerate.
954
955 2018-08-31 Pedro Alves <palves@redhat.com>
956
957 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
958 Delete.
959 * s390-linux-nat.c
960 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
961 * target.h (target_ops::have_continuable_watchpoint): Delete.
962 (target_have_continuable_watchpoint): Delete.
963 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
964 * target-delegates.c: Regenerate.
965
966 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
967
968 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
969 the files present in "gnulib/import/m4/".
970
971 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
972
973 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
974 c.sw, c.swsp, and c.sdsp.
975
976 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
977
978 * riscv-tdep.c (struct riscv_inferior_data): Delete.
979 (riscv_read_misa_reg): Don't cache value read into inferior data.
980 (riscv_new_inferior_data): Delete.
981 (riscv_inferior_data_cleanup): Delete.
982 (riscv_inferior_data): Delete.
983 (riscv_invalidate_inferior_data): Delete.
984 (_initialize_riscv_tdep): Remove initialisation of inferior data.
985
986 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
987
988 * compile/compile-cplus-types.c
989 (compile_cplus_instance::leave_scope): Take the address of scope
990 object.
991 (compile_cplus_instance::convert_qualified_base): Compare quals
992 to 0.
993
994 2018-08-30 Keith Seitz <keiths@redhat.com>
995
996 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
997 Use "%s" and host_address_to_string instead of "%p" in printf.
998
999 2018-08-29 Keith Seitz <keiths@redhat.com>
1000
1001 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
1002 and compile-cplus-types.c.
1003 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
1004 * c-lang.c (cplus_language_defn): Set C++ compile functions.
1005 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
1006 Declare.
1007 * compile/compile-c-support.c: Include compile-cplus.h.
1008 (load_libcompile): Templatize.
1009 (get_compile_context): "New" function.
1010 (c_get_compile_context): Use get_compile_context.
1011 (cplus_get_compile_context): New function.
1012 (cplus_push_user_expression, cplus_pop_user_expression)
1013 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
1014 (cplus_compute_program): Define new structs/functions.
1015 * compile/compile-cplus-symmbols.c: New file.
1016 * compile/compile-cplus-types.c: New file.
1017 * compile/compile-cplus.h: New file.
1018 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
1019 Declare.
1020 * compile/compile-object-load.c (get_out_value_type): Use
1021 strncmp_iw when comparing symbol names.
1022 (compile_object_load): Add mst_bss and mst_data.
1023 * compile/compile.c (_initialize_compile): Remove
1024 -Wno-implicit-function-declaration from `compile_args'.
1025 * compile/gcc-cp-plugin.h: New file.
1026 * NEWS: Mention C++ compile support and new debug options.
1027
1028 2018-08-29 Keith Seitz <keiths@redhat.com>
1029
1030 * linespec.c (collect_info::add_symbol): Make virtual.
1031 (struct symbol_searcher_collect_info): New struct.
1032 (symbol_searcher::find_all_symbols): New method.
1033 * symtab.h (class symbol_searcher): New class.
1034
1035 2018-08-29 Keith Seitz <keiths@redhat.com>
1036
1037 * linespec.c (struct linespec) <function_symbols, label_symbols>:
1038 Change to vector of block_symbol. Update all users.
1039 (struct collect_info) <symbols>: Likewise.
1040 (collect_info::add_symbol): Take block_symbol as argument.
1041 Update all callers.
1042 (decode_compound_collector) <m_symbols>: Change type to vector
1043 of block_symbol. Update all users.
1044 (decode_compound_collector::operator ()): Change parameter type
1045 to block_symbol.
1046 (find_method, find_function_symbols, find_linespec_symbols)
1047 (find_label_symbols_in_block, find_label_symbols): Change symbol
1048 vectors to block_symbol vectors.
1049 * symtab.h (symbol_found_callback_ftype): Change parameter type to
1050 block_symbol.
1051
1052 2018-08-29 Keith Seitz <keiths@redhat.com>
1053
1054 * linespec.c (symbolp): Remove typedef and VEC definitions.
1055 (bound_minimal_symbol_d): Likewise.
1056
1057 2018-08-29 Keith Seitz <keiths@redhat.com>
1058
1059 * linespec.c (decode_compound_collector::decode_compound_collector):
1060 Remove initialization for `m_symtabs'.
1061 (decode_compound_collector::release_symbols): Change return type
1062 to std::vector. Update all callers.
1063 (class decode_compound_collector) <m_symbols>: Change type to
1064 std::vector.
1065 (lookup_prefix_sym): Change return type to std::vector. Update all
1066 callers.
1067 (compare_symbols): Remove.
1068 (std_compare_symbols): Rename to `compare_symbols'.
1069 (find_method): Change `sym_classes' parameter to std::vector.
1070 Update all callers. Use std::sort to sort sym_classes.
1071 (find_linespec_symbols): Remove cleanup.
1072
1073 2018-08-29 Keith Seitz <keiths@redhat.com>
1074
1075 * linespec.c (struct linespec) <minimal_symbols>: Change type to
1076 std::vector. Update all users.
1077 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
1078 (struct collect_info) <minimal_symbols>: Likewise.
1079 (compare_msymbols): Return bool. Change parameters to const
1080 bound_minimal_symbol references.
1081 (find_method, find_function_symbols, find_linespec_symbols): Change
1082 `minsyms' parameter to std::vector. Update all callers.
1083
1084 2018-08-29 Keith Seitz <keiths@redhat.com>
1085
1086 * linespec.c (struct linespec) <label_symbols>: Change type to
1087 std::vector. Update all users.
1088 (find_label_symbols_in_block): Change `result' parameter to
1089 std::vector. Update all callers.
1090 (find_label_symbols): Return std::vector. Update all callers.
1091
1092 2018-08-29 Keith Seitz <keiths@redhat.com>
1093
1094 * linespec.c (struct linespec) <function_symbols>: Change type to
1095 std::vector. Update all users.
1096 (struct collect_info) <function_symbols>: Likewise.
1097 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
1098 (std_compare_symbols): New function.
1099 (find_method, find_function_symbols, find_linespec_symbols)
1100 (find_label_symbols_in_block): Change `symbols' parameter to
1101 std::vector. Update all callers.
1102 (find_label_symbols): Likewise for `function_symbols' and
1103 `label_funcs_ret'.
1104
1105 2018-08-29 Keith Seitz <keiths@redhat.com>
1106
1107 * linespec.c (symtab_vector_up): Define.
1108 (struct linespec) <file_symtabs>: Change type to std::vector *.
1109 Update all uses.
1110 (struct collect_info) <file_symtabs>: Likewise.
1111 (collect_symtabs_from_filename): Return symtab_vector_up.
1112 Update all callers.
1113 (decode_objc): Remove cleanup.
1114 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
1115 (symtab_collector::release_symtabs): Return symtab_vector_up.
1116 Update all callers.
1117 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
1118 Update all users.
1119 (collect_symtabs_from_filename, symtabs_from_filename): Return
1120 symtab_vector_up. Update all callers.
1121
1122 2018-08-29 Tom Tromey <tom@tromey.com>
1123
1124 * csky-tdep.c (csky_analyze_prologue): Use
1125 core_addr_to_string_nz.
1126
1127 2018-08-29 Tom Tromey <tom@tromey.com>
1128
1129 * windows-nat.c (struct xlate_exception) <them>: Change type to
1130 DWORD.
1131 (xlate): Fix formatting. Remove last entry.
1132 (struct xlate_exception, xlate): Comment out.
1133 (windows_nat_target::resume): Use ranged for.
1134
1135 2018-08-29 Jim Wilson <jimw@sifive.com>
1136
1137 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
1138 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
1139 of NT_PRFPREG.
1140 (riscv_linux_nat_target::store_registers): Likewise.
1141
1142 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
1143
1144 PR gdb/23555
1145 PR gdb/23558
1146 * gnulib/aclocal.m4: Regenerate.
1147 * gnulib/config.in: Regenerate.
1148 * gnulib/configure: Regenerate.
1149 * gnulib/import/Makefile.am: Update.
1150 * gnulib/import/Makefile.in: Update.
1151 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
1152 * gnulib/import/_Noreturn.h: ... this.
1153 * gnulib/import/alloca.in.h: Update.
1154 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
1155 * gnulib/import/arg-nonnull.h: ... this.
1156 * gnulib/import/assure.h: Update.
1157 * gnulib/import/at-func.c: Update.
1158 * gnulib/import/basename-lgpl.c: Update.
1159 * gnulib/import/extra/snippet/c++defs.h: Rename to...
1160 * gnulib/import/c++defs.h: ... this.
1161 * gnulib/import/canonicalize-lgpl.c: Update.
1162 * gnulib/import/cdefs.h: Update.
1163 * gnulib/import/chdir-long.c: Update.
1164 * gnulib/import/chdir-long.h: Update.
1165 * gnulib/import/cloexec.c: Update.
1166 * gnulib/import/cloexec.h: Update.
1167 * gnulib/import/close.c: Update.
1168 * gnulib/import/closedir.c: Update.
1169 * gnulib/import/config.charset: Update.
1170 * gnulib/import/dirent-private.h: Update.
1171 * gnulib/import/dirent.in.h: Update.
1172 * gnulib/import/dirfd.c: Update.
1173 * gnulib/import/dirname-lgpl.c: Update.
1174 * gnulib/import/dirname.h: Update.
1175 * gnulib/import/dosname.h: Update.
1176 * gnulib/import/dup-safer-flag.c: Update.
1177 * gnulib/import/dup-safer.c: Update.
1178 * gnulib/import/dup.c: Update.
1179 * gnulib/import/dup2.c: Update.
1180 * gnulib/import/errno.in.h: Update.
1181 * gnulib/import/error.c: Update.
1182 * gnulib/import/error.h: Update.
1183 * gnulib/import/exitfail.c: Update.
1184 * gnulib/import/exitfail.h: Update.
1185 * gnulib/import/extra/update-copyright: Update.
1186 * gnulib/import/fchdir.c: Update.
1187 * gnulib/import/fcntl.c: Update.
1188 * gnulib/import/fcntl.in.h: Update.
1189 * gnulib/import/fd-hook.c: Update.
1190 * gnulib/import/fd-hook.h: Update.
1191 * gnulib/import/fd-safer-flag.c: Update.
1192 * gnulib/import/fd-safer.c: Update.
1193 * gnulib/import/fdopendir.c: Update.
1194 * gnulib/import/filename.h: Update.
1195 * gnulib/import/filenamecat-lgpl.c: Update.
1196 * gnulib/import/filenamecat.h: Update.
1197 * gnulib/import/flexmember.h: Update.
1198 * gnulib/import/float+.h: Update.
1199 * gnulib/import/float.c: Update.
1200 * gnulib/import/float.in.h: Update.
1201 * gnulib/import/fnmatch.c: Update.
1202 * gnulib/import/fnmatch.in.h: Update.
1203 * gnulib/import/fnmatch_loop.c: Update.
1204 * gnulib/import/fpucw.h: Update.
1205 * gnulib/import/frexp.c: Update.
1206 * gnulib/import/frexpl.c: Update.
1207 * gnulib/import/fstat.c: Update.
1208 * gnulib/import/fstatat.c: Update.
1209 * gnulib/import/getcwd-lgpl.c: Update.
1210 * gnulib/import/getcwd.c: Update.
1211 * gnulib/import/getdtablesize.c: Update.
1212 * gnulib/import/getlogin_r.c: Update.
1213 * gnulib/import/getprogname.c: Update.
1214 * gnulib/import/getprogname.h: Update.
1215 * gnulib/import/gettext.h: Update.
1216 * gnulib/import/gettimeofday.c: Update.
1217 * gnulib/import/glob-libc.h: Update.
1218 * gnulib/import/glob.c: Update.
1219 * gnulib/import/glob.in.h: Update.
1220 * gnulib/import/glob_internal.h: Update.
1221 * gnulib/import/glob_pattern_p.c: Update.
1222 * gnulib/import/globfree.c: Update.
1223 * gnulib/import/hard-locale.c: Update.
1224 * gnulib/import/hard-locale.h: Update.
1225 * gnulib/import/intprops.h: Update.
1226 * gnulib/import/inttypes.in.h: Update.
1227 * gnulib/import/isnan.c: Update.
1228 * gnulib/import/isnand-nolibm.h: Update.
1229 * gnulib/import/isnand.c: Update.
1230 * gnulib/import/isnanl-nolibm.h: Update.
1231 * gnulib/import/isnanl.c: Update.
1232 * gnulib/import/itold.c: Update.
1233 * gnulib/import/libc-config.h: Update.
1234 * gnulib/import/limits.in.h: Update.
1235 * gnulib/import/localcharset.c: Update.
1236 * gnulib/import/localcharset.h: Update.
1237 * gnulib/import/localtime-buffer.c: Update.
1238 * gnulib/import/localtime-buffer.h: Update.
1239 * gnulib/import/lstat.c: Update.
1240 * gnulib/import/m4/00gnulib.m4: Update.
1241 * gnulib/import/m4/__inline.m4: Update.
1242 * gnulib/import/m4/absolute-header.m4: Update.
1243 * gnulib/import/m4/alloca.m4: Update.
1244 * gnulib/import/m4/builtin-expect.m4: Update.
1245 * gnulib/import/m4/canonicalize.m4: Update.
1246 * gnulib/import/m4/chdir-long.m4: Update.
1247 * gnulib/import/m4/close.m4: Update.
1248 * gnulib/import/m4/closedir.m4: Update.
1249 * gnulib/import/m4/configmake.m4: Update.
1250 * gnulib/import/m4/d-ino.m4: Update.
1251 * gnulib/import/m4/d-type.m4: Update.
1252 * gnulib/import/m4/dirent_h.m4: Update.
1253 * gnulib/import/m4/dirfd.m4: Update.
1254 * gnulib/import/m4/dirname.m4: Update.
1255 * gnulib/import/m4/double-slash-root.m4: Update.
1256 * gnulib/import/m4/dup.m4: Update.
1257 * gnulib/import/m4/dup2.m4: Update.
1258 * gnulib/import/m4/eealloc.m4: Update.
1259 * gnulib/import/m4/environ.m4: Update.
1260 * gnulib/import/m4/errno_h.m4: Update.
1261 * gnulib/import/m4/error.m4: Update.
1262 * gnulib/import/m4/exponentd.m4: Update.
1263 * gnulib/import/m4/exponentl.m4: Update.
1264 * gnulib/import/m4/extensions.m4: Update.
1265 * gnulib/import/m4/extern-inline.m4: Update.
1266 * gnulib/import/m4/fchdir.m4: Update.
1267 * gnulib/import/m4/fcntl-o.m4: Update.
1268 * gnulib/import/m4/fcntl.m4: Update.
1269 * gnulib/import/m4/fcntl_h.m4: Update.
1270 * gnulib/import/m4/fdopendir.m4: Update.
1271 * gnulib/import/m4/filenamecat.m4: Update.
1272 * gnulib/import/m4/flexmember.m4: Update.
1273 * gnulib/import/m4/float_h.m4: Update.
1274 * gnulib/import/m4/fnmatch.m4: Update.
1275 * gnulib/import/m4/fnmatch_h.m4: Update.
1276 * gnulib/import/m4/fpieee.m4: Update.
1277 * gnulib/import/m4/frexp.m4: Update.
1278 * gnulib/import/m4/frexpl.m4: Update.
1279 * gnulib/import/m4/fstat.m4: Update.
1280 * gnulib/import/m4/fstatat.m4: Update.
1281 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
1282 * gnulib/import/m4/getcwd-path-max.m4: Update.
1283 * gnulib/import/m4/getcwd.m4: Update.
1284 * gnulib/import/m4/getdtablesize.m4: Update.
1285 * gnulib/import/m4/getlogin.m4: Update.
1286 * gnulib/import/m4/getlogin_r.m4: Update.
1287 * gnulib/import/m4/getpagesize.m4: Update.
1288 * gnulib/import/m4/getprogname.m4: Update.
1289 * gnulib/import/m4/gettimeofday.m4: Update.
1290 * gnulib/import/m4/glibc21.m4: Update.
1291 * gnulib/import/m4/glob.m4: Update.
1292 * gnulib/import/m4/glob_h.m4: Update.
1293 * gnulib/import/m4/gnulib-cache.m4: Update.
1294 * gnulib/import/m4/gnulib-common.m4: Update.
1295 * gnulib/import/m4/gnulib-comp.m4: Update.
1296 * gnulib/import/m4/gnulib-tool.m4: Update.
1297 * gnulib/import/m4/hard-locale.m4: Update.
1298 * gnulib/import/m4/include_next.m4: Update.
1299 * gnulib/import/m4/inttypes-pri.m4: Update.
1300 * gnulib/import/m4/inttypes.m4: Update.
1301 * gnulib/import/m4/isnand.m4: Update.
1302 * gnulib/import/m4/isnanl.m4: Update.
1303 * gnulib/import/m4/largefile.m4: Update.
1304 * gnulib/import/m4/limits-h.m4: Update.
1305 * gnulib/import/m4/localcharset.m4: Update.
1306 * gnulib/import/m4/locale-fr.m4: Update.
1307 * gnulib/import/m4/locale-ja.m4: Update.
1308 * gnulib/import/m4/locale-zh.m4: Update.
1309 * gnulib/import/m4/localtime-buffer.m4: Update.
1310 * gnulib/import/m4/longlong.m4: Update.
1311 * gnulib/import/m4/lstat.m4: Update.
1312 * gnulib/import/m4/malloc.m4: Update.
1313 * gnulib/import/m4/malloca.m4: Update.
1314 * gnulib/import/m4/math_h.m4: Update.
1315 * gnulib/import/m4/mbrtowc.m4: Update.
1316 * gnulib/import/m4/mbsinit.m4: Update.
1317 * gnulib/import/m4/mbsrtowcs.m4: Update.
1318 * gnulib/import/m4/mbstate_t.m4: Update.
1319 * gnulib/import/m4/memchr.m4: Update.
1320 * gnulib/import/m4/memmem.m4: Update.
1321 * gnulib/import/m4/mempcpy.m4: Update.
1322 * gnulib/import/m4/memrchr.m4: Update.
1323 * gnulib/import/m4/mkdir.m4: Update.
1324 * gnulib/import/m4/mkstemp.m4: Update.
1325 * gnulib/import/m4/mmap-anon.m4: Update.
1326 * gnulib/import/m4/mode_t.m4: Update.
1327 * gnulib/import/m4/msvc-inval.m4: Update.
1328 * gnulib/import/m4/msvc-nothrow.m4: Update.
1329 * gnulib/import/m4/multiarch.m4: Update.
1330 * gnulib/import/m4/nocrash.m4: Update.
1331 * gnulib/import/m4/off_t.m4: Update.
1332 * gnulib/import/m4/onceonly.m4: Update.
1333 * gnulib/import/m4/open-cloexec.m4: Update.
1334 * gnulib/import/m4/open.m4: Update.
1335 * gnulib/import/m4/openat.m4: Update.
1336 * gnulib/import/m4/opendir.m4: Update.
1337 * gnulib/import/m4/pathmax.m4: Update.
1338 * gnulib/import/m4/rawmemchr.m4: Update.
1339 * gnulib/import/m4/readdir.m4: Update.
1340 * gnulib/import/m4/readlink.m4: Update.
1341 * gnulib/import/m4/realloc.m4: Update.
1342 * gnulib/import/m4/rename.m4: Update.
1343 * gnulib/import/m4/rewinddir.m4: Update.
1344 * gnulib/import/m4/rmdir.m4: Update.
1345 * gnulib/import/m4/save-cwd.m4: Update.
1346 * gnulib/import/m4/secure_getenv.m4: Update.
1347 * gnulib/import/m4/setenv.m4: Update.
1348 * gnulib/import/m4/signal_h.m4: Update.
1349 * gnulib/import/m4/ssize_t.m4: Update.
1350 * gnulib/import/m4/stat-time.m4: Update.
1351 * gnulib/import/m4/stat.m4: Update.
1352 * gnulib/import/m4/std-gnu11.m4: Update.
1353 * gnulib/import/m4/stdbool.m4: Update.
1354 * gnulib/import/m4/stddef_h.m4: Update.
1355 * gnulib/import/m4/stdint.m4: Update.
1356 * gnulib/import/m4/stdio_h.m4: Update.
1357 * gnulib/import/m4/stdlib_h.m4: Update.
1358 * gnulib/import/m4/strchrnul.m4: Update.
1359 * gnulib/import/m4/strdup.m4: Update.
1360 * gnulib/import/m4/strerror.m4: Update.
1361 * gnulib/import/m4/string_h.m4: Update.
1362 * gnulib/import/m4/strstr.m4: Update.
1363 * gnulib/import/m4/strtok_r.m4: Update.
1364 * gnulib/import/m4/sys_socket_h.m4: Update.
1365 * gnulib/import/m4/sys_stat_h.m4: Update.
1366 * gnulib/import/m4/sys_time_h.m4: Update.
1367 * gnulib/import/m4/sys_types_h.m4: Update.
1368 * gnulib/import/m4/tempname.m4: Update.
1369 * gnulib/import/m4/time_h.m4: Update.
1370 * gnulib/import/m4/unistd-safer.m4: Update.
1371 * gnulib/import/m4/unistd_h.m4: Update.
1372 * gnulib/import/m4/warn-on-use.m4: Update.
1373 * gnulib/import/m4/wchar_h.m4: Update.
1374 * gnulib/import/m4/wchar_t.m4: Update.
1375 * gnulib/import/m4/wctype_h.m4: Update.
1376 * gnulib/import/m4/wint_t.m4: Update.
1377 * gnulib/import/malloc.c: Update.
1378 * gnulib/import/malloc/scratch_buffer.h: Update.
1379 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
1380 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
1381 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
1382 * gnulib/import/malloca.c: Update.
1383 * gnulib/import/malloca.h: Update.
1384 * gnulib/import/malloca.valgrind: Update.
1385 * gnulib/import/math.in.h: Update.
1386 * gnulib/import/mbrtowc.c: Update.
1387 * gnulib/import/mbsinit.c: Update.
1388 * gnulib/import/mbsrtowcs-impl.h: Update.
1389 * gnulib/import/mbsrtowcs-state.c: Update.
1390 * gnulib/import/mbsrtowcs.c: Update.
1391 * gnulib/import/memchr.c: Update.
1392 * gnulib/import/memmem.c: Update.
1393 * gnulib/import/mempcpy.c: Update.
1394 * gnulib/import/memrchr.c: Update.
1395 * gnulib/import/mkdir.c: Update.
1396 * gnulib/import/mkstemp.c: Update.
1397 * gnulib/import/msvc-inval.c: Update.
1398 * gnulib/import/msvc-inval.h: Update.
1399 * gnulib/import/msvc-nothrow.c: Update.
1400 * gnulib/import/msvc-nothrow.h: Update.
1401 * gnulib/import/open.c: Update.
1402 * gnulib/import/openat-die.c: Update.
1403 * gnulib/import/openat-priv.h: Update.
1404 * gnulib/import/openat-proc.c: Update.
1405 * gnulib/import/openat.c: Update.
1406 * gnulib/import/openat.h: Update.
1407 * gnulib/import/opendir.c: Update.
1408 * gnulib/import/pathmax.h: Update.
1409 * gnulib/import/pipe-safer.c: Update.
1410 * gnulib/import/rawmemchr.c: Update.
1411 * gnulib/import/readdir.c: Update.
1412 * gnulib/import/readlink.c: Update.
1413 * gnulib/import/realloc.c: Update.
1414 * gnulib/import/ref-add.sin: Update.
1415 * gnulib/import/ref-del.sin: Update.
1416 * gnulib/import/rename.c: Update.
1417 * gnulib/import/rewinddir.c: Update.
1418 * gnulib/import/rmdir.c: Update.
1419 * gnulib/import/same-inode.h: Update.
1420 * gnulib/import/save-cwd.c: Update.
1421 * gnulib/import/save-cwd.h: Update.
1422 * gnulib/import/scratch_buffer.h: Update.
1423 * gnulib/import/secure_getenv.c: Update.
1424 * gnulib/import/setenv.c: Update.
1425 * gnulib/import/signal.in.h: Update.
1426 * gnulib/import/stat-time.c: Update.
1427 * gnulib/import/stat-time.h: Update.
1428 * gnulib/import/stat-w32.c: Update.
1429 * gnulib/import/stat-w32.h: Update.
1430 * gnulib/import/stat.c: Update.
1431 * gnulib/import/stdbool.in.h: Update.
1432 * gnulib/import/stddef.in.h: Update.
1433 * gnulib/import/stdint.in.h: Update.
1434 * gnulib/import/stdio.in.h: Update.
1435 * gnulib/import/stdlib.in.h: Update.
1436 * gnulib/import/str-two-way.h: Update.
1437 * gnulib/import/strchrnul.c: Update.
1438 * gnulib/import/strdup.c: Update.
1439 * gnulib/import/streq.h: Update.
1440 * gnulib/import/strerror-override.c: Update.
1441 * gnulib/import/strerror-override.h: Update.
1442 * gnulib/import/strerror.c: Update.
1443 * gnulib/import/string.in.h: Update.
1444 * gnulib/import/stripslash.c: Update.
1445 * gnulib/import/strnlen1.c: Update.
1446 * gnulib/import/strnlen1.h: Update.
1447 * gnulib/import/strstr.c: Update.
1448 * gnulib/import/strtok_r.c: Update.
1449 * gnulib/import/sys_stat.in.h: Update.
1450 * gnulib/import/sys_time.in.h: Update.
1451 * gnulib/import/sys_types.in.h: Update.
1452 * gnulib/import/tempname.c: Update.
1453 * gnulib/import/tempname.h: Update.
1454 * gnulib/import/time.in.h: Update.
1455 * gnulib/import/unistd--.h: Update.
1456 * gnulib/import/unistd-safer.h: Update.
1457 * gnulib/import/unistd.in.h: Update.
1458 * gnulib/import/unsetenv.c: Update.
1459 * gnulib/import/verify.h: Update.
1460 * gnulib/import/extra/snippet/warn-on-use.h: Update.
1461 * gnulib/import/wchar.in.h: Update.
1462 * gnulib/import/wctype.in.h: Update.
1463 * gnulib/import/xalloc-oversized.h: Update.
1464 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
1465 "53e2c179f26a890fa6685af4b6c1397ee370433b".
1466
1467 2018-08-16 Gary Benson <gbenson@redhat.com>
1468
1469 PR gdb/13000:
1470 * gdb/main.c (captured_main_1): Exit with nonzero status
1471 in batch mode if the last command to be executed failed.
1472 * NEWS: Mention the above.
1473
1474 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
1475
1476 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
1477 end of warning message.
1478
1479 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1480
1481 PR gdb/22943:
1482 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
1483 (aarch64_extract_return_value): Use
1484 aapcs_is_vfp_call_or_return_candidate.
1485 (aarch64_return_in_memory): Likewise.
1486 (aarch64_store_return_value): Likewise.
1487
1488 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1489
1490 * aarch64-tdep.c
1491 (aapcs_is_vfp_call_or_return_candidate): Make static
1492 (pass_in_v_or_stack): Remove function.
1493 (pass_in_v_vfp_candidate): New function.
1494 (aarch64_push_dummy_call): Check for float register candidates.
1495
1496 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1497
1498 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
1499 (aapcs_is_vfp_call_or_return_candidate_1): New function.
1500 (aapcs_is_vfp_call_or_return_candidate): Likewise.
1501
1502 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
1503
1504 PR build/23399
1505 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
1506 (struct ipa_sym_addresses): Rename to...
1507 (struct ipa_sym_addresses_common): ... this.
1508 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
1509
1510 2018-08-28 Tom Tromey <tom@tromey.com>
1511
1512 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1513 (token_fifo): Now a std::vector.
1514 (yylex, c_parse): Update.
1515 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1516 (token_fifo): Now a std::vector.
1517 (yylex, d_parse): Update.
1518 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1519 (token_fifo): Now a std::vector.
1520 (yylex, go_parse): Update.
1521
1522 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
1523
1524 * parser-defs.h (struct type_stack) <elements>: Change type to
1525 std::vector<union type_stack_elt>.
1526 <depth, size>: Remove.
1527 * parse.c (parse_exp_in_context_1): Adjust.
1528 (type_stack_reserve): Remove.
1529 (check_type_stack_depth): Remove.
1530 (insert_into_type_stack): Adjust to std::vector.
1531 (insert_type): Likewise.
1532 (push_type): Likewise.
1533 (push_type_int): Likewise.
1534 (insert_type_address_space): Likewise.
1535 (pop_type): Likewise.
1536 (pop_type_int): Likewise.
1537 (pop_typelist): Likewise.
1538 (pop_type_stack): Likewise.
1539 (append_type_stack): Likewise.
1540 (push_type_stack): Likewise.
1541 (get_type_stack): Likewise.
1542 (type_stack_cleanup): Likewise.
1543 (push_typelist): Likewise.
1544 (follow_types): Likewise.
1545 (_initialize_parse): Likewise.
1546
1547 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
1548
1549 * NEWS: Mention csky target.
1550
1551 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
1552 Hafiz Abid Qadeer <abidh@codesourcery.com>
1553 Don Breazeal <donb@codesourcery.com>
1554
1555 * csky-linux-tdep.c: New file.
1556 * csky-tdep.c: Likewise.
1557 * csky-tdep.h: Likewise.
1558 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
1559 csky-tdep.o.
1560 (HFILES_NO_SRCDIR): Add csky-tdep.h.
1561 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
1562 * configure.tgt: Add csky support.
1563
1564 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
1565
1566 * python/py-framefilter.c (py_print_frame): Print frame architecture
1567 when printing on an MI output.
1568
1569 2018-08-27 Tom Tromey <tom@tromey.com>
1570
1571 PR build/23087:
1572 * configure: Rebuild.
1573 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
1574
1575 2018-08-27 Tom Tromey <tom@tromey.com>
1576
1577 * aarch64-linux-tdep.c
1578 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
1579 casts to int.
1580
1581 2018-08-27 Tom Tromey <tom@tromey.com>
1582
1583 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
1584 unsigned.
1585 (ppc64_standard_linkage1, ppc64_standard_linkage2)
1586 (ppc64_standard_linkage3, ppc64_standard_linkage4)
1587 (ppc64_standard_linkage5, ppc64_standard_linkage6)
1588 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
1589 unsigned.
1590
1591 2018-08-27 Tom Tromey <tom@tromey.com>
1592
1593 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
1594 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
1595
1596 2018-08-27 Tom Tromey <tom@tromey.com>
1597
1598 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
1599 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
1600 ULONGEST_MAX.
1601 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
1602 ULONGEST_MAX.
1603 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
1604 ULONGEST_MAX.
1605 * sparc-linux-tdep.c (sparc32_linux_sigframe)
1606 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
1607 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
1608 ULONGEST_MAX.
1609 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
1610 (ppc64_linux_sigaction_tramp_frame)
1611 (ppc32_linux_sighandler_tramp_frame)
1612 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1613 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
1614 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
1615 * mn10300-linux-tdep.c (am33_linux_sigframe)
1616 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
1617 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
1618 * mips-linux-tdep.c (mips_linux_o32_sigframe)
1619 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
1620 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
1621 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
1622 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
1623 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
1624 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
1625 * microblaze-linux-tdep.c
1626 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1627 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
1628 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
1629 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
1630 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
1631 * common/common-types.h (ULONGEST_MAX): New define.
1632 (CORE_ADDR_MAX): Fix formatting.
1633 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
1634 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
1635 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
1636 (arm_linux_rt_sigreturn_tramp_frame)
1637 (arm_eabi_linux_sigreturn_tramp_frame)
1638 (arm_eabi_linux_rt_sigreturn_tramp_frame)
1639 (thumb2_eabi_linux_sigreturn_tramp_frame)
1640 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
1641 (arm_linux_restart_syscall_tramp_frame)
1642 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
1643 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
1644 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
1645 ULONGEST_MAX.
1646 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
1647
1648 2018-08-27 Tom Tromey <tom@tromey.com>
1649
1650 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
1651 CORE_ADDR_MAX.
1652 * mips-tdep.c (mips_deal_with_atomic_sequence)
1653 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
1654 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
1655 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
1656 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
1657 CORE_ADDR_MAX.
1658 * aarch64-tdep.c (aarch64_software_single_step): Use
1659 CORE_ADDR_MAX.
1660
1661 2018-08-27 Tom Tromey <tom@tromey.com>
1662
1663 * linespec.c (complete_linespec_component): Add cast to "char".
1664 * completer.c (completion_tracker::build_completion_result): Add
1665 cast to "char".
1666
1667 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1668
1669 * solist.h (struct solist, struct target_so_ops): Fix
1670 indentation.
1671
1672 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1673
1674 * ada-tasks.c (ada_task_info_s): Remove typedef.
1675 (DEF_VEC_O(ada_task_info_s)): Remove.
1676 (struct ada_tasks_inferior_data): Initialize fields.
1677 <task_list>: Make an std::vector.
1678 (get_ada_tasks_inferior_data): Allocate with new.
1679 (ada_get_task_number): Adjust.
1680 (get_task_number_from_id): Likewise.
1681 (valid_task_id): Likewise.
1682 (ada_get_task_info_from_ptid): Likewise.
1683 (iterate_over_live_ada_tasks): Likewise.
1684 (add_ada_task): Likewise.
1685 (read_known_tasks): Likewise.
1686 (ada_build_task_list): Likewise.
1687 (print_ada_task_info): Likewise.
1688 (info_task): Likewise.
1689 (task_command_1): Likewise.
1690
1691 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1692
1693 * ada-lang.c (add_angle_brackets): Return std::string.
1694
1695 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
1696
1697 * python/py-threadevent.c (py_get_event_thread): Initialize
1698 pythread.
1699
1700 2018-08-24 Pedro Alves <palves@redhat.com>
1701
1702 * python/py-bpevent.c (create_breakpoint_event_object): Use
1703 copy-initialization.
1704 * python/py-continueevent.c (emit_continue_event): Use
1705 copy-initialization.
1706 * python/py-exitedevent.c (create_exited_event_object): Return a
1707 gdbpy_ref<>.
1708 (emit_exited_event): Use copy-initialization.
1709 * python/py-inferior.c (python_new_inferior)
1710 (python_inferior_deleted, add_thread_object): Use
1711 copy-initialization.
1712 * python/py-infevents.c (create_inferior_call_event_object)
1713 (create_register_changed_event_object)
1714 (create_memory_changed_event_object): Return a gdbpy_ref<>.
1715 (emit_inferior_call_event, emit_memory_changed_event)
1716 (emit_register_changed_event): Use copy-initialization.
1717 * python/py-newobjfileevent.c (create_new_objfile_event_object):
1718 Return a gdbpy_ref<>.
1719 (emit_new_objfile_event): Use copy-initialization.
1720 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
1721 (emit_clear_objfiles_event): Use copy-initialization.
1722 * python/py-signalevent.c (create_signal_event_object): Use
1723 copy-initialization.
1724 * python/py-threadevent.c (create_thread_event_object): Use
1725 copy-initialization.
1726
1727 2018-08-24 Pedro Alves <palves@redhat.com>
1728 Simon Marchi <simon.marchi@ericsson.com>
1729
1730 PR gdb/23379
1731 * python/py-continueevent.c: Include "gdbthread.h".
1732 (create_continue_event_object): Add intro comment. Add 'ptid'
1733 parameter. Use it to find thread to pass to
1734 create_thread_event_object.
1735 (emit_continue_event): Pass PTID down to
1736 create_continue_event_object.
1737 * python/py-event.h (py_get_event_thread): Declare.
1738 (create_thread_event_object): Remove default from 'thread'
1739 parameter.
1740 * python/py-stopevent.c (create_stop_event_object): Use
1741 py_get_event_thread.
1742 * python/py-threadevent.c (get_event_thread): Rename to ...
1743 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
1744 and use it to find the thread.
1745 (create_thread_event_object): Assert that THREAD isn't null.
1746 Don't find the event thread here.
1747
1748 2018-08-23 Kevin Buettner <kevinb@redhat.com>
1749
1750 * block.h (blockrange, blockranges): New struct declarations.
1751 (struct block): Add new field named `ranges'.
1752 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
1753 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
1754 macros for accessing ranges in struct block.
1755 (make_blockranges): New declaration.
1756 block.c (make_blockranges): New function.
1757 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
1758 for block.
1759 * symtab.h (find_pc_partial_function): Add new parameter `block'.
1760 * blockframe.c (cache_pc_function_block): New static global.
1761 (clear_pc_function_cache): Clear cache_pc_function_block.
1762 (find_pc_partial_function): Move comment to symtab.h. Add
1763 support for non-contiguous blocks.
1764 * cli/cli-cmds.c (block.h): Include.
1765 (print_disassembly): Handle printing of non-contiguous blocks.
1766 (disassemble_current_function): Likewise.
1767 (disassemble_command): Likewise.
1768
1769 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
1770 BLOCK_START.
1771 * blockframe.c (get_pc_function_start): Likewise.
1772 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
1773 (gcc_symbol_address): Likewise.
1774 * compile/compile-object-run.c (compile_object_run): Likewise.
1775 * compile/compile.c (get_expr_block_and_pc): Likewise.
1776 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
1777 (func_addr_to_tail_call_list): Likewise.
1778 * findvar.c (default_read_var_value): Likewise.
1779 * inline-frame.c (inline_frame_this_id): Likewise.
1780 (skip-inline_frames): Likewise.
1781 * infcmd.c (until_next_command): Likewise.
1782 * linespec.c (convert_linespec_to_sals): Likewise.
1783 * parse.c (parse_exp_in_context_1): Likewise.
1784 * printcmd.c (build_address_symbolic): likewise.
1785 (info_address_command): Likewise.
1786 symtab.c (find_function_start_sal): Likewise.
1787 (skip_prologue_sal): Likewise.
1788 (find_function_alias_target): Likewise.
1789 (find_gnu_ifunc): Likewise.
1790 * stack.c (find_frame_funname): Likewise.
1791 * symtab.c (fixup_symbol_section): Likewise.
1792 (find_function_start_sal): Likewise.
1793 (skip_prologue_sal): Likewsie.
1794 (find_function_alias_target): Likewise.
1795 (find_gnu_ifunc): Likewise.
1796 * tracepoint.c (info_scope_command): Likewise.
1797 * value.c (value_fn_field): Likewise.
1798
1799 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
1800 in place of find_pc_partial_function.
1801 * blockframe.c (find_function_entry_range_from_pc): New function.
1802 * symtab.h (find_function_entry_range_from_pc): Declare and document.
1803 * objfiles.c (objfile_relocate1): Relocate start and end addresses
1804 for each range in a block.
1805
1806
1807 2018-08-23 Xavier Roirand <roirand@adacore.com>
1808
1809 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
1810 incrementation.
1811
1812 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1813
1814 * solib-svr4.c (read_program_headers_from_bfd): Return
1815 gdb::optional<gdb::byte_vector>.
1816 (svr4_exec_displacement): Adjust.
1817
1818 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1819
1820 * solib-svr4.c (read_program_header): Return
1821 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
1822 (find_program_interpreter): Return
1823 gdb::optional<gdb::byte_vector>.
1824 (scan_dyntag_auxv): Adjust.
1825 (enable_break): Adjust.
1826 (svr4_exec_displacement): Adjust.
1827
1828 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1829
1830 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
1831 * inf-child.c (inf_child_target::terminal_save_inferior): New.
1832
1833 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1834
1835 * guile/scm-string.c (gdbscm_scm_from_printf): Use
1836 string_vprintf.
1837 * guile/scm-utils.c (gdbscm_printf): Likewise.
1838 * serial.c (serial_printf): Likewise.
1839 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
1840
1841 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
1842
1843 * stack.c (print_frame): Print frame architecture when printing on
1844 an MI output.
1845 * NEWS: Mention new "arch" attribute in frame output.
1846
1847 2018-08-21 Alan Hayward <alan.hayward@arm.com>
1848
1849 * arch/aarch64.h (aarch64_regnum): Update comment.
1850
1851 2018-08-21 Alan Hayward <alan.hayward@arm.com>
1852
1853 * NEWS: Add SVE to 8.2 section.
1854
1855 2018-08-21 Pedro Alves <palves@redhat.com>
1856
1857 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
1858 out from gdbscm_parse_function_args.
1859 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
1860 gdbscm_parse_function_args_1.
1861
1862 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
1863
1864 PR gdb/17816
1865 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
1866 operator.
1867
1868 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
1869
1870 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
1871
1872 2018-08-19 Michael Spang <spang@google.com>
1873
1874 PR gdb/11786
1875 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
1876 for PT_TLS segments.
1877
1878 2018-08-18 Kevin Buettner <kevinb@redhat.com>
1879
1880 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
1881 dwarf_variable_value.
1882 * dwarf2-frame.c (class dwarf_expr_executor):
1883 Add override for dwarf_variable_value.
1884 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
1885 (class symbol_needs_eval_context): Likewise.
1886 (indirect_synthetic_pointer): Add forward declaration.
1887 (sect_variable_value): New function.
1888 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
1889 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
1890 for DW_OP_GNU_variable_value.
1891
1892 2018-08-16 Tom Tromey <tom@tromey.com>
1893
1894 * top.c (read_command_file): Update.
1895 (command_line_input): Remove "repeat" argument.
1896 * ada-lang.c (get_selections): Update.
1897 * linespec.c (decode_line_2): Update.
1898 * defs.h (command_line_input): Remove argument.
1899 * cli/cli-script.c (read_next_line): Update.
1900 * python/py-gdb-readline.c: Update.
1901
1902 2018-08-17 Tom Tromey <tom@tromey.com>
1903
1904 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
1905 command_line_input.
1906
1907 2018-08-15 Tom Tromey <tom@tromey.com>
1908
1909 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
1910
1911 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
1912
1913 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
1914 If used, use find_pc_partial_function to find address range
1915 to disassemble.
1916 * mi/mi-main.c (mi_cmd_list_features): Report
1917 "data-disassemble-a-option" feature.
1918 * NEWS: Mention new -data-disassemble option -a.
1919
1920 2018-08-13 Tom Tromey <tom@tromey.com>
1921
1922 * common/common-defs.h (_FORTIFY_SOURCE): Define.
1923
1924 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1925
1926 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
1927 (aarch64_linux_collect_sve_regset): Likewise.
1928 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
1929 * regcache.h (regcache_map_entry_size): New function.
1930
1931 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1932
1933 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
1934 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
1935 (SVE_HEADER_VL_LENGTH): Likewise.
1936 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
1937 (SVE_HEADER_FLAGS_LENGTH): Likewise.
1938 (SVE_HEADER_RESERVED_LENGTH): Likewise.
1939 (SVE_HEADER_SIZE_OFFSET): Likewise.
1940 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
1941 (SVE_HEADER_VL_OFFSET): Likewise.
1942 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
1943 (SVE_HEADER_FLAGS_OFFSET): Likewise.
1944 (SVE_HEADER_RESERVED_OFFSET): Likewise.
1945 (SVE_HEADER_SIZE): Likewise.
1946 (aarch64_linux_core_read_vq): Add function.
1947 (aarch64_linux_core_read_description): Check for SVE section.
1948
1949 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1950
1951 * aarch64-fbsd-tdep.c
1952 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
1953 collect_size.
1954 * aarch64-linux-tdep.c
1955 (aarch64_linux_iterate_over_regset_sections): Likewise.
1956 * alpha-linux-tdep.c
1957 (alpha_linux_iterate_over_regset_sections):
1958 * alpha-nbsd-tdep.c
1959 (alphanbsd_iterate_over_regset_sections): Likewise.
1960 * amd64-fbsd-tdep.c
1961 (amd64fbsd_iterate_over_regset_sections): Likewise.
1962 * amd64-linux-tdep.c
1963 (amd64_linux_iterate_over_regset_sections): Likewise.
1964 * arm-bsd-tdep.c
1965 (armbsd_iterate_over_regset_sections): Likewise.
1966 * arm-fbsd-tdep.c
1967 (arm_fbsd_iterate_over_regset_sections): Likewise.
1968 * arm-linux-tdep.c
1969 (arm_linux_iterate_over_regset_sections): Likewise.
1970 * corelow.c (get_core_registers_cb): Likewise.
1971 (core_target::fetch_registers): Likewise.
1972 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
1973 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
1974 * gdbarch.h (void): Regenerate.
1975 * gdbarch.sh: Add supply_size and collect_size.
1976 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
1977 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
1978 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
1979 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
1980 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
1981 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
1982 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
1983 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
1984 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
1985 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
1986 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
1987 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
1988 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
1989 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
1990 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
1991 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
1992 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
1993 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
1994 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
1995 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
1996 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
1997 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
1998 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
1999 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
2000 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
2001 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
2002 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
2003 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
2004 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
2005 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
2006
2007 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
2008
2009 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
2010 with string_printf.
2011
2012 2018-08-10 Keith Seitz <keiths@redhat.com>
2013
2014 * compile/compile-c-support.c (add_code_header, add_code_footer):
2015 Move into policy class.
2016 (c_push_user_expression, pop_user_expression_nop)
2017 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
2018 (compile_program): New host class.
2019 (c_compile_program): New typedef.
2020 (c_compute_porgram): Use c_compile_program.
2021
2022 2018-08-10 Keith Seitz <keiths@redhat.com>
2023
2024 * compile/compile-internal.h (compile_instance::~compile_instance):
2025 Remove calls to htab_delete.
2026 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
2027 * compile.c (compile_instance::compile_instance): Initialize
2028 htab unique pointers.
2029 (compile_instance::get_cached_type, compile_instance::insert_type)
2030 (compile_instance::error_symbol_once): Update for unique_ptr.
2031
2032 2018-08-10 Keith Seitz <keiths@redhat.com>
2033
2034 * compile/compile-c-symbols.c (struct symbol_error)
2035 (hash_symbol_error, eq_symbol_error, del_symbol_error)
2036 (compile_instance::insert_symbol_error)
2037 (compile_instance::error_symbol_once): Move to ...
2038 * compile/compile.c: ... here.
2039
2040 2018-08-10 Keith Seitz <keiths@redhat.com>
2041
2042 * compile/compile-c-support.c (c_get_compile_context): Use `new'
2043 instead of `new_compile_instance'.
2044 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
2045 Update description.
2046 If the symbol error map is not initialized, create it.
2047 (generate_c_for_for_one_symbol): Do not check/initialize
2048 the symbol error map.
2049 * compile/compile-c-types.c (compile_c_instance): Make a class.
2050 Update all callers.
2051 (compile_instance::compile_instance): Initialize the type cache.
2052 (get_cached_type): New function.
2053 (insert_type): Update description.
2054 (compile_c_instance::m_default_cflags): Define.
2055 (convert_type): Update description. Use get_cached_type.
2056 (delete_instance): Moved to destructor.
2057 (new_compile_instance): Moved to constructor.
2058 * compile/compile-c.h (compile_c_instance): Make class inheriting
2059 from compile_instance.
2060 <base>: Remove field.
2061 <type_map, symbol_err_map>: Move to base class.
2062 <c_plugin>: Rename to `m_plugin' and remove pointer type.
2063 * compile/compile-internal.h (compile_instance): Make class.
2064 <type_map_t, symbol_err_map_t>: Define.
2065 <fe>: Rename to `m_gcc_fe'.
2066 <scope, block, gcc_target_options>: Add `m_' prefix.
2067 <m_type_map, m_symbol_err_map>: New fields, moved from
2068 compile_c_instance.
2069 <destroy>: Remove.
2070 (convert_type, new_compile_instance): Remove.
2071 * compile/compile.c (cleanup_compile_instance): Remove.
2072 (compile_to_object): Use unique_ptr to eliminate cleanups.
2073 (compile_instance::set_print_callback, compile_instance::version)
2074 (compile_instance::set_verbose)
2075 (compile_instance::set_driver_filename)
2076 (compile_instance::set_triplet_regexp)
2077 (compile_instance::set_arguments)
2078 (compile_instance::set_source_file)
2079 (compile_instance::compile): Define.
2080
2081 2018-08-10 Keith Seitz <keiths@redhat.com>
2082
2083 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
2084 * compile/compile-c-types.c: Define GCC_METHODN macros and include
2085 gcc-c-fe.def to define C plugin.
2086 (delete_instance): Delete `c_plugin'.
2087 (new_compile_instance): Initialize `c_plugin'.
2088 * compile/compile-c.h: Include gcc_c_plugin.h.
2089 (struct compile_c_instance) <c_plugin>: New member.
2090 * gcc-c-plugin.h: New file.
2091 Update all callers with API change.
2092
2093 2018-08-10 Keith Seitz <keiths@redhat.com>
2094
2095 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
2096 (HFILES_NO_SRCDIR): ... to here.
2097 Add compile-internal.h and compile-c.h.
2098 * compile/compile-c-support.c: Include compile-c.h.
2099 * compile/compile-c-symbols.c: Include compile-c.h.
2100 (generate_c_for_variable_locations): Update comment.
2101 * compile/compile-c-types.c: Include compile-c.h.
2102 * compile/compile-c.h: New file -- moved C language declarations
2103 from other files here.
2104 * compile/compile-internal.h: Do not include hashtab.h or
2105 common/enum-flags.h.
2106 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
2107 (gcc_convert_symbol, gcc_symbol_address)
2108 (generate_c_for_variable_locations, c_get_mode_for_size)
2109 (c_get_range_decl_name): Definitions moved to compile-c.h.
2110 * compile/compile-loc2c.c: Include compile-c.h.
2111
2112 2018-08-10 Keith Seitz <keiths@redhat.com>
2113
2114 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
2115 (c_symbol_substitution_name): ... this.
2116 Update all callers.
2117
2118 2018-08-10 Keith Seitz <keiths@redhat.com>
2119
2120 * compile/compile-c-support.c (c_compute_program): Use
2121 unique_xmalloc_ptr to eliminate cleanup.
2122 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
2123 Return a unique_xmalloc_ptr and eliminate cleanup.
2124 * compile/compile-internal.h (generate_c_for_variable_locations):
2125 Return unique_xmalloc_ptr and update description.
2126
2127 2018-08-10 Alan Hayward <alan.hayward@arm.com>
2128
2129 * corelow.c (core_target::get_core_register_section): Rename
2130 min_size to section_min_size.
2131
2132 2018-08-09 Jim Wilson <jimw@sifive.com>
2133
2134 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
2135 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
2136 * NEWS: Mention new GNU/Linux RISC-V target.
2137 * configure.host: Add riscv*-*-linux*.
2138 * configure.nat: Add riscv*.
2139 * configure.tgt: Add riscv*-*-linux*.
2140 * riscv-linux-nat.c: New file.
2141 * riscv-linux-tdep.c: New file.
2142
2143 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2144
2145 * infrun.c (resume): Make static, add forward declaration.
2146 (proceed): Update header comment.
2147 * infrun.h (resume): Delete declaration.
2148
2149 2018-08-09 Tom Tromey <tom@tromey.com>
2150
2151 * riscv-tdep.h: Minor formatting fixes.
2152
2153 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
2154
2155 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
2156 * dwarf-index-cache.c (create_dir_and_check): Likewise.
2157 (test_mkdir_recursive): Likewise.
2158 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
2159
2160 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2161
2162 * valarith.c (value_subscripted_rvalue): If an array is not in
2163 memory, and we don't know the upper bound, then we can't know that
2164 the requested element exists or not.
2165
2166 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
2167
2168 * target.c (str_comma_list_concat_elem): Fix typo in comment.
2169 (target_options_to_string): Add comment.
2170
2171 2018-08-08 Tom Tromey <tom@tromey.com>
2172
2173 * unittests/scoped_mmap-selftests.c: Check result of "write".
2174
2175 2018-08-08 Jim Wilson <jimw@sifive.com>
2176
2177 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
2178 (decode_register_index_short): New.
2179 (decode_j_type_insn, decode_cj_type_insn): New.
2180 (decode_b_type_insn, decode_cb_type_insn): New.
2181 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
2182 local xlen. Check xlen when decoding ambiguous compressed insns. In
2183 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
2184 is_c_sw_insn instead of is_sw_insn.
2185 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
2186 (riscv_software_single_step): New.
2187 * riscv-tdep.h (riscv_software_single_step): Declare.
2188
2189 * riscv-tdep.c (riscv_isa_xlen): Drop static.
2190 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
2191
2192 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
2193
2194 PR gdb/18050:
2195 * target.c (dispose_inferior): Don't dispose of inferiors that are
2196 already killed.
2197
2198 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
2199
2200 * remote.c (remote_target::download_tracepoint): Change char* to
2201 const char*.
2202
2203 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
2204
2205 * target.h (target_options_to_string): Return an std::string.
2206 * target.c (str_comma_list_concat_elem): Return void, use
2207 std::string.
2208 (do_option): Likewise.
2209 (target_options_to_string): Return an std::string.
2210 * linux-nat.c (linux_nat_target::wait): Adjust.
2211 * target-debug.h (target_debug_print_options): Adjust.
2212
2213 2018-08-07 Tom Tromey <tom@tromey.com>
2214
2215 * Makefile.in (CPPFLAGS): New variable.
2216 (INTERNAL_CPPFLAGS): Use it.
2217
2218 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2219
2220 * NEWS: Mention the index cache.
2221
2222 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2223
2224 * common/pathstuff.h (get_standard_cache_dir): New.
2225 * common/pathstuff.c (get_standard_cache_dir): New.
2226 * build-id.h (build_id_to_string): New.
2227 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
2228 DEBUG_STR_SUFFIX): Move to here.
2229 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
2230 DEBUG_STR_SUFFIX): Move from there.
2231 (write_psymtabs_to_index): Make non-static, add basename
2232 parameter. Write to temporary files, rename when done.
2233 (save_gdb_index_command): Adjust call to
2234 write_psymtabs_to_index.
2235 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
2236 field.
2237 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
2238 (get_gdb_index_contents_from_cache): New.
2239 (get_gdb_index_contents_from_cache_dwz): New.
2240 (dwarf2_initialize_objfile): Read index from cache.
2241 (dwarf2_build_psymtabs): Save to index.
2242 * dwarf-index-cache.h: New file.
2243 * dwarf-index-cache.c: New file.
2244 * dwarf-index-write.h: New file.
2245
2246 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2247
2248 * gnulib/aclocal.m4: Re-generate.
2249 * gnulib/config.in: Re-generate.
2250 * gnulib/configure: Re-generate.
2251 * gnulib/import/Makefile.am: Re-generate.
2252 * gnulib/import/Makefile.in: Re-generate.
2253 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
2254 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2255 * gnulib/import/m4/mkdir.m4: New file.
2256 * gnulib/import/mkdir.c: New file.
2257 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
2258 module.
2259
2260 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2261
2262 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
2263 * common/scoped_mmap.c: New file.
2264 * common/scoped_mmap.h (destroy): New method.
2265 (~scoped_mmap, reset): Use destroy.
2266 (scoped_mmap): New move constructor.
2267 (mmap_file): New declaration.
2268 * unittests/scoped_mmap-selftests.c (test_normal,
2269 test_invalid_filename, run_tests): New functions.
2270 (_initialize_scoped_mmap_selftests): Register selftest.
2271
2272 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2273
2274 * dwarf2read.c (read_gdb_index_from_section): Rename to...
2275 (read_gdb_index_from_buffer): ... this. Remove section
2276 parameter, add buffer parameter.
2277 (get_gdb_index_contents_ftype,
2278 get_gdb_index_contents_dwz_ftype): New typedefs.
2279 (dwarf2_read_gdb_index): Add callback parameters to get the
2280 index contents.
2281 (get_gdb_index_contents_from_section): New.
2282 (dwarf2_initialize_objfile): Update call to
2283 dwarf2_read_gdb_index.
2284
2285 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2286
2287 * common/filestuff.h (gdb_fopen_cloexec): New overload.
2288 (gdb_open_cloexec): Likewise.
2289 * nat/linux-osdata.c (command_from_pid): Use string_printf.
2290 (commandline_from_pid): Likewise.
2291 (linux_xfer_osdata_threads): Likewise.
2292 (linux_xfer_osdata_fds): Likewise.
2293 * ada-lang.c (is_package_name): Likewise.
2294 * auxv.c (procfs_xfer_auxv): Likewise.
2295 * breakpoint.c (print_one_breakpoint_location): Use
2296 uiout::field_fmt.
2297 (print_one_catch_solib): Use string_printf.
2298 * coff-pe-read.c (add_pe_exported_sym): Likewise.
2299 (add_pe_forwarded_sym): Likewise.
2300 * dwarf2read.c (create_type_unit_group): Likewise.
2301 (build_error_marker_type): Likewise.
2302 * infcall.c (get_function_name): Likewise.
2303 * valprint.c (print_converted_chars_to_obstack): Likewise.
2304 * xtensa-tdep.c (xtensa_register_type): Likewise.
2305
2306 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
2307
2308 * remote.c (remote_target::download_tracepoint): Fix format
2309 string errors.
2310
2311 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2312
2313 * tracefile.c: Include common/byte-vector.h.
2314 (trace_save): Change type of buf to gdb::byte_vector. Initialize
2315 with trace_regblock_size if needed. Update uses of buf.
2316
2317 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2318
2319 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
2320 std::vector<unsigned char>.
2321 * tracepoint.c (collection_list::collection_list): Remove
2322 m_regs_mask initializer from initializer list. Resize
2323 m_regs_mask using the largest remote register number.
2324 (collection_list::add_remote_register): Remove size check on
2325 m_regs_mask. Use at to access element.
2326 (collection_list::stringify): Change type of temp_buf to
2327 gdb::char_vector. Update uses of temp_buf. Resize if needed to
2328 stringify the register mask. Use pack_hex_byte for the register
2329 mask.
2330
2331 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2332
2333 * tracepoint.h (class collection_list) <add_register>: Remove.
2334 <add_remote_register, add_ax_registers, add_local_register>:
2335 Declare.
2336 <add_memrange>: Add scope parameter.
2337 * tracepoint.c (encode_actions_1): Likewise.
2338 (collection_list::add_register): Rename to ...
2339 (collection_list::add_remote_register): ... this. Update
2340 comment.
2341 (collection_list::add_ax_registers, add_local_register): New
2342 methods.
2343 (collection_list::add_memrange): Add scope parameter. Call
2344 add_local_register instead of add_register.
2345 (finalize_tracepoint_aexpr): New function.
2346 (collection_list::collect_symbol): Update calls to add_memrange.
2347 Call add_local_register instead of add_register. Call
2348 add_ax_registers. Call finalize_tracepoint_aexpr.
2349 (encode_actions_1): Get remote regnos for $reg action. Call
2350 add_remote_register, add_ax_registers, and add_local_register.
2351 Update call to add_memrange. Call finalize_tracepoint_aexpr.
2352 (validate_actionline): Call finalize_tracepoint_aexpr.
2353
2354 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2355
2356 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
2357 Replace array buf with gdb::char_vector buf, of size
2358 get_remote_packet_size (). Replace references to buf and
2359 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
2360 and xsnprintf with snprintf. Raise errors if the buffer is too
2361 small.
2362
2363 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2364
2365 * remote.c (remote_target::download_tracepoint): Fix the has_more
2366 predicate in the QTDP action list iteration.
2367
2368 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2369
2370 * remote.c (remote_target::download_tracepoint): Fix indentation
2371 in for block.
2372
2373 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2374
2375 * proc-api.c (_initialize_proc_api): Remove c, unused.
2376 * procfs.c (procfs_init_inferior): Remove signals, unused.
2377 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
2378 unused.
2379
2380 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
2381 Andrew Burgess <andrew.burgess@embecosm.com>
2382
2383 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
2384 'W_STOPCODE (0)' as this could be ambiguous.
2385
2386 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
2387
2388 * ser-tcp.c (net_open): Fix thinko when deciding whether to
2389 disable TCP's Nagle algorithm (use "ai_protocol" instead of
2390 "ai_socktype").
2391
2392 2018-08-02 Tom Tromey <tom@tromey.com>
2393
2394 PR symtab/16842.
2395 * dwarf2read.c (read_func_scope): Set symtab on template parameter
2396 symbols.
2397 (process_structure_scope): Likewise.
2398
2399 2018-08-02 Xavier Roirand <roirand@adacore.com>
2400
2401 PR gdb/22629:
2402 * darwin-nat.c (darwin_kill_inferior): Fix handling of
2403 kill inferior.
2404
2405 2018-08-02 Tom Tromey <tom@tromey.com>
2406
2407 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
2408 (darwin_suspend_inferior, darwin_resume_inferior)
2409 (darwin_decode_notify_message, darwin_resume_inferior_threads)
2410 (darwin_check_new_threads): Check result of get_darwin_inferior.
2411
2412 2018-07-31 Joel Brobecker <brobecker@adacore.com>
2413
2414 GDB 8.1.1 released.
2415
2416 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
2417
2418 * varobj.c (varobj_get_path_expr_parent): Report an error if
2419 parent is a dynamic varobj.
2420
2421 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2422
2423 * gnulib/aclocal.m4: Re-generate.
2424 * gnulib/config.in: Re-generate.
2425 * gnulib/configure: Re-generate.
2426 * gnulib/import/Makefile.in: Re-generate.
2427 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2428 * gnulib/import/m4/onceonly.m4: Re-generate.
2429
2430 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2431
2432 * target-descriptions.c (struct xml_test_tdesc): New.
2433 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
2434 (record_xml_tdesc): Update.
2435 (maintenance_check_xml_descriptions): Update.
2436 * target-descriptions.h (record_xml_tdesc): Update comment.
2437
2438 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
2439
2440 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
2441 checking array bounds are defined.
2442
2443 2018-07-30 Tom Tromey <tom@tromey.com>
2444
2445 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
2446 irreflexivity violation.
2447
2448 2018-07-30 Tom Tromey <tom@tromey.com>
2449
2450 * cli/cli-decode.c (lookup_cmd): Remove lint code.
2451 * value.c (unpack_long): Remove lint code.
2452 * valops.c (value_ind): Remove lint code.
2453 * valarith.c (value_x_binop, value_x_unop, value_equal)
2454 (value_pos): Remove lint code.
2455
2456 2018-07-28 Tom de Vries <tdevries@suse.de>
2457
2458 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
2459 with undefined upper bound as <optimized out>.
2460
2461 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
2462
2463 * gcore.in: Rename variable "name" to "prefix". Expand
2464 "usage" text.
2465
2466 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
2467
2468 * windows-nat.c (windows_nat_target::create_inferior): Update to
2469 call close() in global namespace.
2470
2471 2018-07-26 Tom Tromey <tom@tromey.com>
2472
2473 * dwarf-index-write.c (add_address_entry): Don't add objfile
2474 offsets.
2475 * dbxread.c (find_stab_function): Rename from
2476 find_stab_function_addr. Return a bound_minimal_symbol.
2477 (read_dbx_symtab): Use raw_text_low, raw_text_high.
2478 Don't add objfile offsets.
2479 (end_psymtab): Use raw_text_low, raw_text_high,
2480 MSYMBOL_VALUE_RAW_ADDRESS.
2481 (read_ofile_symtab): Update.
2482 (process_one_symbol): Update.
2483 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
2484 offsets.
2485 (dw2_relocate): Remove.
2486 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
2487 searching addrmap.
2488 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
2489 Update.
2490 (process_psymtab_comp_unit_reader, add_partial_symbol)
2491 (add_partial_subprogram, dwarf2_ranges_read): Update.
2492 (load_partial_dies): Update.
2493 (add_address_entry): Don't add objfile offsets.
2494 (dwarf2_build_include_psymtabs): Update.
2495 (create_addrmap_from_aranges): Don't add objfile offsets.
2496 (dw2_find_pc_sect_compunit_symtab): Update.
2497 * mdebugread.c (parse_symbol): Don't add objfile offsets.
2498 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
2499 Update.
2500 (parse_partial_symbols): Don't add objfile offsets. Use
2501 raw_text_low, raw_text_high. Update.
2502 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
2503 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
2504 or call 'relocate' quick function. Clear psymbol_map.
2505 * psympriv.h (struct partial_symbol) <address>: Add section
2506 offset.
2507 <set_unrelocated_address>: Rename from set_address.
2508 <raw_text_low, raw_text_high>: New methods.
2509 <text_low, text_high>: Add objfile parameter.
2510 (add_psymbol_to_bcache): Add 'section' parameter. Call
2511 set_unrelocated_address.
2512 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2513 (find_pc_psymbol): Update.
2514 (fixup_psymbol_section, relocate_psymtabs): Remove.
2515 (dump_psymtab, psym_functions): Update.
2516 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
2517 parameter.
2518 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
2519 (start_psymtab_common): Update.
2520 * symfile-debug.c (debug_qf_relocate): Remove.
2521 (debug_sym_quick_functions): Update.
2522 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
2523 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
2524 Update.
2525
2526 2018-07-26 Tom Tromey <tromey@redhat.com>
2527
2528 * dbxread.c (end_psymtab): Use text_high_valid and
2529 text_low_valid.
2530 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
2531 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
2532 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2533 Update comment.
2534 <text_low_valid, text_high_valid>: New fields.
2535 <set_text_low, set_text_high>: Update.
2536 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
2537
2538 2018-07-26 Tom Tromey <tom@tromey.com>
2539
2540 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
2541 Update.
2542 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
2543 textlow and texthigh fields.
2544 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
2545 Update.
2546 * mdebugread.c (parse_lines, parse_partial_symbols)
2547 (psymtab_to_symtab_1): Update.
2548 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2549 Rename fields. Update comment. Now private.
2550 <text_low, text_high, set_text_low, set_text_high>: New methods.
2551 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2552 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
2553 (start_psymtab_common, maintenance_info_psymtabs)
2554 (maintenance_check_psymtabs): Update.
2555 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
2556 texthigh fields.
2557 (scan_xcoff_symtab): Update.
2558
2559 2018-07-26 Tom Tromey <tromey@redhat.com>
2560
2561 * psympriv.h (struct partial_symbol) <unrelocated_address,
2562 address, set_address>: New methods.
2563 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
2564 (fixup_psymbol_section, relocate_psymtabs): Update.
2565 (print_partial_symbols): Add 'objfile' parameter. Update.
2566 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
2567 Update.
2568
2569 2018-07-26 Tom Tromey <tom@tromey.com>
2570
2571 * dwarf-index-write.c (write_psymbols, debug_names::insert)
2572 (debug_names::write_psymbols): Update.
2573 * psympriv.h (struct partial_symbol): Derive from
2574 general_symbol_info.
2575 <obj_section>: New method.
2576 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
2577 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2578 (find_pc_sect_psymbol, fixup_psymbol_section)
2579 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
2580 (print_partial_symbols, recursively_search_psymtabs)
2581 (compare_psymbols, psymbol_hash, psymbol_compare)
2582 (add_psymbol_to_bcache, maintenance_check_psymtabs)
2583 (psymbol_name_matches, psym_fill_psymbol_map): Update.
2584
2585 2018-07-26 Tom Tromey <tromey@redhat.com>
2586
2587 * dbxread.c (end_psymtab): Remove dead code.
2588
2589 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
2590
2591 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
2592 DWARF unwinders are disabled.
2593 * dwarf2-frame.c: Add dwarf2read.h include.
2594 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
2595 disabled.
2596 (dwarf2_frame_unwinders_enabled_p): Define.
2597 (show_dwarf_unwinders_enabled_p): New function.
2598 (_initialize_dwarf2_frame): Register switch to control DWARF
2599 unwinder use.
2600 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
2601 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
2602 (show_dwarf_cmdlist): Remove static keyword.
2603 * dwarf2read.h (set_dwarf_cmdlist): Declare.
2604 (show_dwarf_cmdlist): Declare.
2605 * NEWS: Document new feature.
2606
2607 2018-07-26 Tom de Vries <tdevries@suse.de>
2608
2609 PR breakpoints/23366
2610 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
2611
2612 2018-07-26 Tom de Vries <tdevries@suse.de>
2613
2614 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
2615 DW_AT_count can't be translated to a dynamic prop.
2616
2617 2018-07-25 Tom de Vries <tdevries@suse.de>
2618
2619 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
2620 try/catch.
2621
2622 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
2623
2624 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
2625
2626 2018-07-25 Joel Brobecker <brobecker@adacore.com>
2627
2628 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
2629
2630 2018-07-24 Keith Seitz <keiths@redhat.comt
2631
2632 PR symtab/23010
2633 * dwarf2read.c (dw2_add_symbol_to_list): New function.
2634 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
2635 instead of add_symbol_to_list.
2636 (read_file_scope): Call prepare_one_comp_unit before reading
2637 any other DIEs.
2638
2639 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
2640
2641 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
2642
2643 2018-07-24 Tom Tromey <tom@tromey.com>
2644
2645 * utils.c (malloc, realloc, free): Don't declare.
2646 * configure, config.in: Rebuild.
2647 * configure.ac: Don't check for declarations of free, malloc, or
2648 realloc.
2649
2650 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2651
2652 * aarch64-linux-nat.c
2653 (aarch64_linux_nat_target::stopped_data_address): Remove unused
2654 variable.
2655 * arm-linux-nat.c (fetch_regs): Likewise.
2656 (store_regs): Likewise.
2657 (fetch_vfp_regs): Likewise.
2658 (store_vfp_regs): Likewise.
2659 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
2660 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
2661 (arm_linux_nat_target::insert_watchpoint): Likewise.
2662 (arm_linux_nat_target::remove_watchpoint): Likewise.
2663 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
2664 Likewise.
2665 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
2666 Likewise.
2667 * ppc-linux-nat.c (fetch_register): Likewise.
2668 (fetch_all_gp_regs): Likewise.
2669 (fetch_ppc_registers): Likewise.
2670 (store_all_gp_regs): Likewise.
2671 (store_ppc_registers): Likewise.
2672 (hwdebug_insert_point): Likewise.
2673 (can_use_watchpoint_cond_accel): Likewise.
2674 * remote-sim.c (gdb_os_write_stdout): Likewise.
2675
2676 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2677 Tom Tromey <tom@tromey.com>
2678
2679 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
2680 test for it.
2681 * configure: Rebuild.
2682
2683 2018-07-22 Tom Tromey <tom@tromey.com>
2684
2685 * regformats/regdat.sh: Define xmltarget_${name} inside
2686 #ifndef IN_PROCESS_AGENT.
2687
2688 2018-07-22 Tom Tromey <tom@tromey.com>
2689
2690 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
2691
2692 2018-07-22 Tom Tromey <tom@tromey.com>
2693
2694 * symfile.c (reread_symbols): Notify iter, not objfile.
2695
2696 2018-07-22 Tom Tromey <tom@tromey.com>
2697
2698 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
2699 Use arch_ops.
2700 (ravenscar_thread_target::prepare_to_store): Likewise.
2701
2702 2018-07-22 Tom Tromey <tom@tromey.com>
2703
2704 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
2705 unused variable. Call value_fetch_lazy when needed.
2706 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
2707 Remove unused variable. Call value_fetch_lazy when needed.
2708
2709 2018-07-22 Tom Tromey <tom@tromey.com>
2710
2711 * m32c-tdep.c (mark_dma): Return void.
2712 (make_regs): Remove unused declarations.
2713
2714 2018-07-22 Tom Tromey <tom@tromey.com>
2715
2716 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
2717 cmdscm_get_valid_command_smob_arg_unsafe for effect.
2718 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
2719 bkscm_get_valid_block_smob_arg_unsafe for effect.
2720
2721 2018-07-22 Tom Tromey <tom@tromey.com>
2722
2723 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
2724 value_type.
2725
2726 2018-07-22 Tom Tromey <tom@tromey.com>
2727
2728 * windows-nat.c (saved_context): Conditionally define.
2729 * remote.c (remote_target::remote_btrace_maybe_reopen):
2730 Conditionally declare "warned".
2731 * inflow.c (sigquit_ours): Conditionally define.
2732 (new_tty): Move "tty" declaration inside #if.
2733 * guile/guile.c (guile_datadir): Conditionally define.
2734 * charset.c (set_be_le_names): Move some declarations inside #if.
2735 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
2736 #if.
2737 (parse_xml_btrace_conf): Likewise.
2738
2739 2018-07-22 Tom Tromey <tom@tromey.com>
2740
2741 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
2742
2743 2018-07-22 Tom Tromey <tom@tromey.com>
2744
2745 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
2746 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
2747 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
2748 * buildsym-legacy.c (get_macro_table): Remove unused variable.
2749 * stack.c (frame_apply_level_command): Remove unused variable.
2750 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
2751 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
2752 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
2753 unused variable.
2754 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
2755 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
2756 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
2757 variable.
2758 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
2759 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
2760 variable.
2761 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
2762 Remove unused variable.
2763 * cli/cli-script.c (recurse_read_control_structure): Remove unused
2764 variable.
2765 * common/tdesc.c (print_xml_feature::visit): Remove unused
2766 variable.
2767 * compile/compile-object-load.c (store_regs): Remove unused
2768 variables.
2769 * complaints.c (clear_complaints): Remove unused variable.
2770 * corelow.c (core_target_open): Remove unused variable.
2771 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
2772 variable.
2773 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
2774 variable.
2775 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
2776 variable.
2777 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
2778 variable.
2779 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
2780 variable.
2781 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
2782 variable.
2783 * ia64-tdep.c (examine_prologue): Remove unused variable.
2784 * infcall.c (run_inferior_call): Remove unused variable.
2785 * inferior.c (exit_inferior): Remove unused variable.
2786 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
2787 * linespec.c (decode_line_2): Remove unused variable.
2788 * linux-nat.c (super_close): Remove.
2789 * linux-tdep.c (linux_info_proc): Remove unused variable.
2790 * mi/mi-main.c (mi_execute_command): Remove unused variable.
2791 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
2792 Remove unused variable.
2793 * parse.c (find_minsym_type_and_address): Remove unused variable.
2794 * printcmd.c (info_symbol_command, printf_floating): Remove unused
2795 variable.
2796 * python/py-breakpoint.c (bppy_set_commands): Remove unused
2797 variable.
2798 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
2799 variables.
2800 * record-btrace.c (record_btrace_target::store_registers): Remove
2801 unused variable.
2802 (cmd_show_record_btrace_cpu): Remove unused variable.
2803 * riscv-tdep.c (riscv_register_reggroup_p)
2804 (riscv_push_dummy_call, riscv_return_value): Remove unused
2805 variable.
2806 * rust-exp.y (literal): Remove unused variable.
2807 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
2808 unused variable.
2809 <STRUCTOP_ANONYMOUS>: Likewise.
2810 * s390-linux-tdep.c (s390_linux_init_abi_31)
2811 (s390_linux_init_abi_64): Remove unused variable.
2812 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
2813 (file_select_thread, net_windows_open, _initialize_ser_windows):
2814 Remove unused variables.
2815 * symtab.c (find_pc_sect_line): Remove unused variable.
2816 * target-memory.c (compute_garbled_blocks): Remove unused
2817 variable.
2818 (target_write_memory_blocks): Remove unused variable.
2819 * target.c (target_stack::unpush): Remove unused variables.
2820 * tracepoint.c (start_tracing, all_tracepoint_actions)
2821 (merge_uploaded_trace_state_variables)
2822 (print_one_static_tracepoint_marker): Remove unused variable.
2823 * unittests/basic_string_view/element_access/char/1.cc (test01):
2824 Remove unused variable.
2825 * windows-nat.c (windows_continue, windows_add_all_dlls)
2826 (do_initial_windows_stuff, windows_nat_target::create_inferior):
2827 Remove unused variables.
2828
2829 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
2830
2831 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
2832 attr_profile in HAVE_ELF.
2833 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
2834 HAVE_ELF.
2835
2836 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
2837
2838 * frame.c (frame_register_unwind): Change parameter name.
2839 (frame_unwind_register): Likewise.
2840 (frame_unwind_register_value): Likewise.
2841 (frame_unwind_register_signed): Likewise.
2842 (frame_unwind_register_unsigned): Likewise.
2843 * frame.h (frame_register_unwind): Likewise.
2844 (frame_unwind_register): Likewise.
2845 (frame_unwind_register_value): Likewise.
2846 (frame_unwind_register_signed): Likewise.
2847 (frame_unwind_register_unsigned): Likewise.
2848 (frame_unwind_arch): Likewise.
2849
2850 2018-07-20 Maciej W. Rozycki <macro@mips.com>
2851
2852 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
2853 ISA maintenance.
2854
2855 2018-07-20 Maciej W. Rozycki <macro@mips.com>
2856
2857 * mips-linux-nat.c (mips_linux_nat_target::read_description):
2858 Call `get_ptrace_pid' rather than extracting the ptrace PID by
2859 hand.
2860
2861 2018-07-20 Keith Seitz <keiths@redhat.com>
2862
2863 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
2864 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
2865 m_compunit_symtab, m_language>: Add "m_" prefix.
2866 Update all uses.
2867 * buildsym.c: Update all uses.
2868
2869 2018-07-20 Tom Tromey <tom@tromey.com>
2870
2871 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
2872 * buildsym.h (record_line_ftype): Remove typedef.
2873
2874 2018-07-20 Tom Tromey <tom@tromey.com>
2875
2876 * buildsym-legacy.h (augment_type_symtab): Don't declare.
2877 (end_expandable_symtab): Likewise.
2878 (end_symtab_get_static_block): Likewise.
2879 (end_symtab_from_static_block): Likewise.
2880 * buildsym-legacy.c (augment_type_symtab): Remove.
2881 (end_expandable_symtab): Remove.
2882 (end_symtab_get_static_block): Remove.
2883 (end_symtab_from_static_block): Remove.
2884
2885 2018-07-20 Tom Tromey <tom@tromey.com>
2886
2887 * dwarf2read.c: Include buildsym.h.
2888 (struct dwarf2_cu) <builder>: New method.
2889 (fixup_go_packaging): Update.
2890 (process_full_comp_unit, process_full_type_unit): Update. Don't
2891 use scoped_free_pendings.
2892 (using_directives): Add "cu" parameter, remove "language".
2893 (read_import_statement, setup_type_unit_groups, )
2894 (read_func_scope, read_lexical_block_scope)
2895 (dwarf2_record_block_ranges, read_namespace): Update.
2896 (lnp_state_machine::lnp_state_machine): Add cu parameter.
2897 (lnp_state_machine::handle_end_sequence): Update.
2898 (class lnp_state_machine) <m_cu>: New member.
2899 <m_record_line_callback>: Remove.
2900 <m_currently_recording_lines>: New member.
2901 (lnp_state_machine::handle_set_file): Update.
2902 (noop_record_line): Remove.
2903 (dwarf_record_line_p): Add cu parameter.
2904 (dwarf_record_line_1, dwarf_finish_line): Likewise.
2905 (lnp_state_machine::record_line)
2906 (lnp_state_machine::lnp_state_machine)
2907 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
2908 (dwarf_decode_lines): Update.
2909 (dwarf2_start_subfile): Add cu parameter.
2910 (dwarf2_start_symtab, new_symbol): Update.
2911 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
2912 Remove dwarf2_per_objfile parameter.
2913 (dwarf_decode_macros): Update.
2914
2915 2018-07-20 Tom Tromey <tom@tromey.com>
2916
2917 * stabsread.c (define_symbol): Update.
2918 * buildsym-legacy.h (get_buildsym_compunit): Declare.
2919 * dwarf2read.c (new_symbol): Update.
2920 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
2921 * cp-namespace.c: Include buildsym.h.
2922 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
2923 * buildsym-legacy.c (get_buildsym_compunit): New function.
2924
2925 2018-07-20 Tom Tromey <tom@tromey.com>
2926
2927 * xcoffread.c: Include buildsym-legacy.h.
2928 * windows-nat.c: Include buildsym-legacy.h.
2929 * stabsread.c: Include buildsym-legacy.h.
2930 * mdebugread.c: Include buildsym-legacy.h.
2931 * buildsym-legacy.h: New file.
2932 * buildsym-legacy.c: New file, from buildsym.c.
2933 * go32-nat.c: Include buildsym-legacy.h.
2934 * dwarf2read.c: Include buildsym-legacy.h.
2935 * dbxread.c: Include buildsym-legacy.h.
2936 * cp-namespace.c: Include buildsym-legacy.h.
2937 * coffread.c: Include buildsym-legacy.h.
2938 * buildsym.h: Move some contents to buildsym-legacy.h.
2939 * buildsym.c: Include buildsym-legacy.h. Move many functions to
2940 buildsym-legacy.c.
2941 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
2942
2943 2018-07-20 Tom Tromey <tom@tromey.com>
2944
2945 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
2946 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
2947 (buildsym_compunit::buildsym_compunit)
2948 (buildsym_compunit::~buildsym_compunit)
2949 (buildsym_compunit::get_macro_table): Define.
2950
2951 2018-07-20 Tom Tromey <tom@tromey.com>
2952
2953 * buildsym.c (reset_symtab_globals): Remove.
2954 (buildsym_compunit::end_symtab_from_static_block): Update.
2955 (buildsym_compunit::augment_type_symtab): Update.
2956 (end_symtab_from_static_block): Call free_buildsym_compunit.
2957 (augment_type_symtab, end_symtab, end_expandable_symtab):
2958 Likewise.
2959
2960 2018-07-20 Tom Tromey <tom@tromey.com>
2961
2962 * arch-utils.c: Do not include buildsym.h.
2963 * mipsread.c: Do not include buildsym.h.
2964 * machoread.c: Do not include buildsym.h.
2965 * elfread.c: Do not include buildsym.h.
2966
2967 2018-07-20 Tom Tromey <tom@tromey.com>
2968
2969 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
2970 initialization.
2971 (buildsym_compunit): Add new constructor.
2972 (struct buildsym_compunit) <get_last_source_file, finish_block,
2973 record_block_range, start_subfile, patch_subfile_names,
2974 push_subfile, pop_subfile, record_line, get_compunit_symtab,
2975 set_last_source_start_addr, get_last_source_start_addr,
2976 get_local_using_directives, set_local_using_directives,
2977 get_global_using_directives, outermost_context_p,
2978 get_current_context_stack, get_context_stack_depth,
2979 get_current_subfile, get_local_symbols, get_file_symbols,
2980 get_global_symbols, record_debugformat, record_producer,
2981 push_context, pop_context, end_symtab_get_static_block,
2982 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
2983 New public methods.
2984 <record_pending_block, finish_block_internal, make_blockvector,
2985 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
2986 private methods.
2987 Update all users.
2988
2989 2018-05-22 Tom Tromey <tom@tromey.com>
2990
2991 * buildsym.c (record_pending_block): Move earlier. Remove objfile
2992 parameter.
2993 (finish_block_internal): Update.
2994
2995 2018-07-20 Tom Tromey <tom@tromey.com>
2996
2997 * buildsym.c (record_pending_block): Move earlier. Remove objfile
2998 parameter.
2999 (finish_block_internal): Update.
3000
3001 2018-07-20 Tom Tromey <tom@tromey.com>
3002
3003 * buildsym.h (EXTERN): Don't define or undef.
3004 * buildsym.c (EXTERN): Don't define.
3005
3006 2018-07-20 Tom Tromey <tom@tromey.com>
3007
3008 * buildsym.c: Remove TODO comment.
3009
3010 2018-07-20 Tom Tromey <tom@tromey.com>
3011
3012 * coffread.c (coff_symtab_read): Update.
3013 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
3014 (xcoff_new_init): Update.
3015 * mipsread.c (mipscoff_new_init): Update.
3016 * mdebugread.c (mdebug_build_psymtabs): Update.
3017 * elfread.c (elf_new_init): Update.
3018 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
3019 Update.
3020 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
3021 (coffstab_build_psymtabs, elfstab_build_psymtabs)
3022 (stabsect_build_psymtabs): Update.
3023 * buildsym.h (buildsym_init): Don't declare.
3024 * buildsym.c: Update comment.
3025 (prepare_for_building): Remove.
3026 (start_symtab, restart_symtab): Update.
3027 (reset_symtab_globals): Update comment.
3028 (buildsym_init): Remove.
3029
3030 2018-07-20 Tom Tromey <tom@tromey.com>
3031
3032 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
3033 * stabsread.c (patch_block_stabs, define_symbol, read_type)
3034 (read_enum_type, common_block_start, common_block_end)
3035 (cleanup_undefined_types_1, finish_global_stabs): Update.
3036 * mdebugread.c (psymtab_to_symtab_1): Update.
3037 * dwarf2read.c (fixup_go_packaging, read_func_scope)
3038 (read_lexical_block_scope, new_symbol): Update.
3039 * dbxread.c (process_one_symbol): Update.
3040 * coffread.c (coff_symtab_read, process_coff_symbol)
3041 (coff_read_enum_type): Update.
3042 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
3043 declare.
3044 (get_local_symbols, get_file_symbols, get_global_symbols): New
3045 functions.
3046 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
3047 m_global_symbols.
3048 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
3049 (~scoped_free_pendings): Update.
3050 (finish_block, prepare_for_building, reset_symtab_globals)
3051 (end_symtab_get_static_block, end_symtab_with_blockvector)
3052 (augment_type_symtab, push_context): Update.
3053 (get_local_symbols, get_file_symbols, get_global_symbols): New
3054 functions.
3055 (buildsym_init): Update.
3056
3057 2018-07-20 Tom Tromey <tom@tromey.com>
3058
3059 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
3060 (process_full_type_unit): Likewise.
3061 (dwarf2_start_symtab): Set list_in_scope.
3062
3063 2018-07-20 Tom Tromey <tom@tromey.com>
3064
3065 * dwarf2read.c (process_psymtab_comp_unit_reader)
3066 (build_type_psymtabs_reader): Do not set list_in_scope.
3067
3068 2018-07-20 Tom Tromey <tom@tromey.com>
3069
3070 * buildsym.c (free_pendings): Remove.
3071 (add_symbol_to_list, scoped_free_pendings)
3072 (finish_block_internal, buildsym_init): Update.
3073
3074 2018-07-20 Tom Tromey <tom@tromey.com>
3075
3076 * xcoffread.c (read_xcoff_symtab): Update.
3077 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
3078 Update.
3079 * dbxread.c (process_one_symbol): Update.
3080 * coffread.c (coff_symtab_read): Update.
3081 * buildsym.h (finish_block): Update.
3082 * buildsym.c (finish_block): Remove "listhead" argument.
3083 (end_symtab_get_static_block): Update.
3084
3085 2018-07-20 Tom Tromey <tom@tromey.com>
3086
3087 * buildsym.h (class scoped_free_pendings): Remove constructor.
3088 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
3089 method.
3090 <m_pending_block_obstack, m_pending_blocks>: New members.
3091 (pending_block_obstack, pending_blocks): Remove.
3092 (scoped_free_pendings::scoped_free_pendings): Default.
3093 (~scoped_free_pendings): Update.
3094 (free_pending_blocks): Remove.
3095 (finish_block_internal, record_pending_block, make_blockvector)
3096 (end_symtab_get_static_block, augment_type_symtab, push_context)
3097 (buildsym_init): Update.
3098
3099 2018-07-20 Tom Tromey <tom@tromey.com>
3100
3101 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
3102 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
3103 members.
3104 (pending_addrmap, pending_addrmap_obstack)
3105 (pending_addrmap_interesting): Remove.
3106 (scoped_free_pendings, record_block_range, make_blockvector)
3107 (prepare_for_building, reset_symtab_globals, buildsym_init):
3108 Update.
3109
3110 2018-07-20 Tom Tromey <tom@tromey.com>
3111
3112 * xcoffread.c (process_linenos): Update.
3113 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
3114 * mdebugread.c (psymtab_to_symtab_1): Update.
3115 * dwarf2read.c (setup_type_unit_groups)
3116 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
3117 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
3118 * dbxread.c (process_one_symbol): Update.
3119 * coffread.c (coff_symtab_read, enter_linenos)
3120 (process_coff_symbol): Update.
3121 * buildsym.h (current_subfile): Don't declare.
3122 (get_current_subfile): Declare.
3123 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
3124 member.
3125 (start_subfile, free_buildsym_compunit, push_subfile)
3126 (prepare_for_building, start_symtab): Update.
3127 (get_current_subfile): New function.
3128
3129 2018-07-20 Tom Tromey <tom@tromey.com>
3130
3131 * coffread.c (coff_symtab_read): Update.
3132 * xcoffread.c (read_xcoff_symtab): Update.
3133 * dwarf2read.c (new_symbol): Update.
3134 (read_func_scope, read_lexical_block_scope): Update.
3135 * dbxread.c (process_one_symbol): Update.
3136 * buildsym.h (context_stack, context_stack_depth): Don't declare.
3137 (outermost_context_p): Remove macro.
3138 (outermost_context_p, get_current_context_stack)
3139 (get_context_stack_depth): Declare.
3140 (pop_context): Return struct context_stack.
3141 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
3142 member.
3143 (context_stack_size): Remove.
3144 (INITIAL_CONTEXT_STACK_SIZE): Remove.
3145 (prepare_for_building, end_symtab_get_static_block)
3146 (augment_type_symtab, push_context): Update.
3147 (pop_context): Return struct context_stack.
3148 (outermost_context_p, get_current_context_stack)
3149 (get_context_stack_depth): New functions.
3150 (buildsym_init): Update.
3151
3152 2018-07-20 Tom Tromey <tom@tromey.com>
3153
3154 * rust-exp.y: Now a pure parser. Update all rules.
3155 (%union): Move earlier.
3156 (current_parser, work_obstack): Remove globals.
3157 (rust_parser, ~rust_parser): Update.
3158 (class rust_parser) <copy_name, concat3, crate_name, super_name,
3159 lex_character, lex_number, lex_string, lex_identifier,
3160 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
3161 convert_name, convert_params_to_expression,
3162 convert_ast_to_expression, ast_basic_type, ast_operation,
3163 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
3164 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
3165 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
3166 ast_array_type, ast_slice_type, ast_reference_type,
3167 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
3168 (rust_parse): Update.
3169 (rustyyerror, rustyylex): Add parser parameter.
3170 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
3171 (rust_lex_stringish_test, rust_lex_test_sequence)
3172 (rust_lex_test_trailing_dot, rust_lex_test_completion)
3173 (rust_lex_test_push_back, rust_lex_tests): Update.
3174
3175 2018-07-19 Pedro Alves <palves@redhat.com>
3176
3177 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
3178 gdb::unique_xmalloc_ptr.
3179 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
3180 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
3181 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
3182 copy-initialization.
3183 * guile/scm-pretty-print.c (ppscm_print_children): Use
3184 gdb::unique_xmalloc_ptr instead of cleanups.
3185 (gdbscm_apply_val_pretty_printer): Remove cleanups.
3186 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
3187 gdb::unique_xmalloc_ptr.
3188 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3189 Adjust to use gdb::unique_xmalloc_ptr.
3190 * guile/scm-utils.c (extract_arg): Adjust.
3191 * guile/scm-value.c (gdbscm_value_field): Adjust to use
3192 gdb::unique_xmalloc_ptr instead of a cleanup.
3193
3194 2018-07-19 Tom Tromey <tom@tromey.com>
3195
3196 * utils.c (do_value_free_to_mark)
3197 (make_cleanup_value_free_to_mark): Remove.
3198 * utils.h (make_cleanup_value_free_to_mark): Remove.
3199
3200 2018-07-19 Pedro Alves <palves@redhat.com>
3201
3202 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
3203 forwarding reference.
3204
3205 2018-07-18 Pedro Alves <palves@redhat.com>
3206
3207 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
3208 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
3209 cleanup.
3210
3211 2018-07-18 Pedro Alves <palves@redhat.com>
3212
3213 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
3214 exceptions.
3215 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
3216 (gdbscm_wrap): New.
3217 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
3218 directly instead of a cleanup.
3219 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
3220 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
3221 (vlscm_binop_gdbthrow): New, factored out from ...
3222 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
3223 (vlscm_rich_compare): Use gdbscm_wrap.
3224 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
3225 instead of a cleanup.
3226 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
3227 cleanup.
3228 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3229 Use xfree directly instead of a cleanup.
3230 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
3231 Adjust to use gdbscm_wrap and scoped_value_mark.
3232 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
3233 (gdbscm_value_address, gdbscm_value_dereference)
3234 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
3235 scoped_value_mark.
3236 (gdbscm_value_dynamic_type): Use scoped_value_mark.
3237 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
3238 scoped_value_mark.
3239 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
3240 gdbscm_wrap and scoped_value_mark.
3241 (gdbscm_value_to_string): Use xfree directly instead of a
3242 cleanup. Move 'buffer' unique_ptr to TRY scope.
3243 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
3244 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
3245 scoped_value_mark.
3246 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
3247 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
3248 scoped_value_mark.
3249 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
3250 gdbscm_wrap.
3251
3252 2018-07-18 Tom de Vries <tdevries@suse.de>
3253
3254 * findvar.c (default_read_var_value): Also resolve dynamic type for
3255 LOC_OPTIMIZED_OUT vars.
3256
3257 2018-07-18 Maciej W. Rozycki <macro@mips.com>
3258
3259 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
3260 decoding.
3261
3262 2018-07-17 Tom Tromey <tom@tromey.com>
3263
3264 * guile/scm-param.c (pascm_set_func, pascm_show_func)
3265 (compute_enum_list, pascm_set_param_value_x)
3266 (gdbscm_parameter_value): Update.
3267 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
3268 (gdbscm_scm_to_host_string): Update.
3269 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
3270 Update.
3271 * guile/scm-cmd.c (cmdscm_add_completion): Update.
3272 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
3273 * guile/scm-string.c (gdbscm_scm_to_string): Return
3274 unique_xmalloc_ptr.
3275 (gdbscm_scm_to_host_string): Likewise.
3276
3277 2018-07-17 Tom Tromey <tom@tromey.com>
3278
3279 * guile/guile.c (gdbscm_eval_from_control_command): Update.
3280 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
3281 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
3282 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
3283 unique_xmalloc_ptr.
3284
3285 2018-07-17 Tom Tromey <tom@tromey.com>
3286
3287 * guile/scm-param.c (pascm_signal_setshow_error): Update.
3288 * guile/guile-internal.h (gdbscm_exception_message_to_string):
3289 Update.
3290 * guile/scm-cmd.c (cmdscm_function): Update.
3291 * guile/scm-pretty-print.c
3292 (ppscm_print_exception_unless_memory_error): Update.
3293 * guile/scm-exception.c (gdbscm_exception_message_to_string):
3294 Return unique_xmalloc_ptr.
3295
3296 2018-07-17 Tom Tromey <tom@tromey.com>
3297
3298 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
3299 Use string_printf.
3300
3301 2018-07-17 Jim Wilson <jimw@sifive.com>
3302
3303 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
3304 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
3305 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
3306 unecessary braces after EF_RISCV_RVC test. Delete call to
3307 set_gdbarch_decr_pc_after_break.
3308
3309 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
3310 RISCV_LAST_FP_REGNUM + 1.
3311 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
3312
3313 2018-07-17 Tom Tromey <tom@tromey.com>
3314
3315 * configure.ac: Remove --disable-gdbcli.
3316 * configure: Rebuild.
3317 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
3318 (SUBDIR_CLI_CFLAGS): Remove.
3319 (SFILES): Use SUBDIR_CLI_SRCS.
3320 (COMMON_OBS): Use SUBDIR_CLI_OBS.
3321
3322 2018-07-17 Tom Tromey <tom@tromey.com>
3323
3324 PR gdb/18624:
3325 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
3326
3327 2018-07-16 Jim Wilson <jimw@sifive.com>
3328
3329 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
3330
3331 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3332
3333 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
3334 variable.
3335 (libunwind_frame_sniffer): Likewise.
3336 (libunwind_frame_prev_register): Likewise.
3337 (libunwind_sigtramp_frame_sniffer): Likewise.
3338 * ia64-tdep.c (ia64_access_reg): Likewise.
3339 (ia64_access_rse_reg): Likewise.
3340 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
3341 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
3342
3343 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3344
3345 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
3346
3347 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3348
3349 * remote-sim.c (gdbsim_target::close,
3350 gdbsim_target::mourn_inferior): Remove unused variables.
3351
3352 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
3353
3354 * ia64-tdep.c (ktab_buf): New global.
3355 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
3356 (get_kernel_table): Adjust.
3357
3358 2018-07-16 Tom Tromey <tom@tromey.com>
3359
3360 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
3361 * dwarf2read.c (using_directives, new_symbol): Use
3362 outermost_context_p.
3363 * dbxread.c (process_one_symbol): Use outermost_context_p.
3364 * coffread.c (coff_symtab_read): Use outermost_context_p.
3365
3366 2018-07-16 Tom Tromey <tom@tromey.com>
3367
3368 * dwarf2read.c (using_directives, read_func_scope)
3369 (read_lexical_block_scope): Update.
3370 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
3371 * buildsym.h (local_using_directives, global_using_directives):
3372 Don't declare.
3373 (get_local_using_directives, set_local_using_directives)
3374 (get_global_using_directives): Declare.
3375 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
3376 m_global_using_directives>: New members.
3377 (finish_block_internal, prepare_for_building)
3378 (reset_symtab_globals, end_symtab_get_static_block)
3379 (push_context): Update.
3380 (get_local_using_directives, set_local_using_directives)
3381 (get_global_using_directives): New functions.
3382 (buildsym_init): Update.
3383
3384 2018-07-16 Tom Tromey <tom@tromey.com>
3385
3386 * xcoffread.c (xcoff_initial_scan): Don't call
3387 free_pending_blocks.
3388 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
3389 * buildsym.h (class scoped_free_pendings): Add constructor.
3390 (free_pending_blocks): Don't declare.
3391 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
3392 (free_pending_blocks): Now static.
3393
3394 2018-07-16 Tom Tromey <tom@tromey.com>
3395
3396 * buildsym.h (push_subfile, pop_subfile): Update declarations.
3397 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
3398 member.
3399 (struct subfile_stack): Remove.
3400 (subfile_stack): Remove.
3401 (push_subfile, pop_subfile, buildsym_init): Update.
3402
3403 2018-07-16 Tom Tromey <tom@tromey.com>
3404
3405 * buildsym.c (push_subfile): Use gdb_assert.
3406 (pop_subfile): Use gdb_assert.
3407
3408 2018-07-16 Tom Tromey <tom@tromey.com>
3409
3410 * buildsym.h (merge_symbol_lists): Remove.
3411 * buildsym.c (merge_symbol_lists): Remove.
3412
3413 2018-07-16 Tom Tromey <tom@tromey.com>
3414
3415 * stabsread.c (scan_file_globals): Update comment.
3416 * stabsread.h (scan_file_globals): Move from buildsym.h.
3417 * buildsym.h (scan_file_globals): Move to stabsread.h.
3418
3419 2018-07-16 Tom Tromey <tom@tromey.com>
3420
3421 * xcoffread.c (xcoff_new_init): Update.
3422 * mipsread.c (mipscoff_new_init): Update.
3423 * mdebugread.c (mdebug_build_psymtabs): Update.
3424 * elfread.c (elf_new_init): Update.
3425 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
3426 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
3427 * buildsym.h (buildsym_new_init): Don't declare.
3428 * buildsym.c (buildsym_new_init): Remove.
3429
3430 2018-07-16 Tom Tromey <tom@tromey.com>
3431
3432 * stabsread.h (within_function): Move from buildsym.h.
3433 * stabsread.c (start_stabs): Clear within_function.
3434 * coffread.c (coff_start_symtab): Clear within_function.
3435 * buildsym.h (within_function): Move to stabsread.h.
3436 * buildsym.c (prepare_for_building): Update.
3437
3438 2018-07-16 Tom Tromey <tom@tromey.com>
3439
3440 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
3441 * dwarf2read.c (dwarf2_start_symtab): Don't set
3442 processing_gcc_compilation.
3443 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
3444
3445 2018-07-16 Tom Tromey <tom@tromey.com>
3446
3447 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
3448 (next_symbol_text_func): Move from buildsym.h.
3449 * stabsread.c (hashname): Move from buildsym.c.
3450 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
3451 (next_symbol_text_func, hashname): Move to stabsread.h.
3452 * buildsym.c: Don't include bcache.h
3453 (hashname): Move to stasbread.c.
3454
3455 2018-07-16 Tom Tromey <tom@tromey.com>
3456
3457 * buildsym.h (context_stack_size): Don't declare.
3458 * buildsym.c (context_stack_size): New global.
3459
3460 2018-07-16 Tom Tromey <tom@tromey.com>
3461
3462 * dbxread.c (processing_acc_compilation): New global.
3463 * buildsym.h (processing_acc_compilation): Don't declare.
3464
3465 2018-07-16 Tom Tromey <tom@tromey.com>
3466
3467 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
3468 * dbxread.c (read_ofile_symtab): Update.
3469 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
3470 * buildsym.h (last_source_start_addr): Remove.
3471 (set_last_source_start_addr, get_last_source_start_addr):
3472 Declare.
3473 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
3474 parameter.
3475 (struct buildsym_compunit) <m_last_source_start_addr>: New
3476 member.
3477 (prepare_for_building): Remove start_addr parameter.
3478 (start_symtab, restart_symtab, end_symtab_get_static_block)
3479 (end_symtab_with_blockvector): Update.
3480 (set_last_source_start_addr, get_last_source_start_addr): New
3481 functions.
3482
3483 2018-07-16 Tom Tromey <tom@tromey.com>
3484
3485 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
3486 member.
3487 (have_line_numbers): Remove.
3488 (record_line, prepare_for_building, end_symtab_get_static_block)
3489 (augment_type_symtab): Update.
3490
3491 2018-07-16 Tom Tromey <tom@tromey.com>
3492
3493 * buildsym.c (~buildsym_compunit): Free the macro table.
3494 (struct buildsym_compunit) <get_macro_table, release_macros>: New
3495 methods.
3496 <m_pending_macros>: New member.
3497 (pending_macros): Remove.
3498 (~scoped_free_pendings, get_macro_table, prepare_for_building)
3499 (reset_symtab_globals, end_symtab_get_static_block)
3500 (end_symtab_with_blockvector, augment_type_symtab)
3501 (buildsym_init): Update.
3502
3503 2018-07-16 Tom Tromey <tom@tromey.com>
3504
3505 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
3506 parameter.
3507 (buildsym_compunit::set_last_source_file): New method.
3508 <m_last_source_file>: New member.
3509 (prepare_for_building): Remove "name" parameter.
3510 (start_symtab, restart_symtab, reset_symtab_globals): Update.
3511 (last_source_file): Remove.
3512 (set_last_source_file, get_last_source_file): Update.
3513
3514 2018-07-16 Tom Tromey <tom@tromey.com>
3515
3516 * buildsym.c (prepare_for_building): Add assert.
3517
3518 2018-07-16 Tom Tromey <tom@tromey.com>
3519
3520 * buildsym.c (~buildsym_compunit): Update.
3521 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
3522 (start_subfile, patch_subfile_names)
3523 (end_symtab_with_blockvector): Update.
3524
3525 2018-07-16 Tom Tromey <tom@tromey.com>
3526
3527 * buildsym.c (struct buildsym_compunit): Add constructor,
3528 destructor, initializers.
3529 (start_buildsym_compunit): Remove.
3530 (free_buildsym_compunit): Use "delete".
3531 (start_symtab, restart_symtab): Use "new".
3532
3533 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
3534
3535 * symfile.c (set_objfile_default_section_offset): Remove struct
3536 keyword.
3537
3538 2018-07-14 Stafford Horne <shorne@gmail.com>
3539
3540 * (Responsible Maintainers): Add myself as or1k maintainer.
3541
3542 2018-07-13 Tom Tromey <tom@tromey.com>
3543
3544 * symfile.c (set_objfile_default_section_offset): Use extra braces
3545 around initializer.
3546
3547 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
3548
3549 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
3550 non-branching basr.
3551
3552 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3553
3554 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3555 unittests/cli-utils-selftests.c
3556 * unittests/cli-utils-selftests.c: New file.
3557
3558 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3559
3560 * NEWS: Mention new commands. Mention change to 'thread apply'.
3561
3562 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3563
3564 * thread.c (thr_try_catch_cmd): New function.
3565 (thread_apply_all_command): Handle qcs flags.
3566 (thread_apply_command): Handle qcs flags.
3567 (taas_command): New function.
3568 (tfaas_command): New function.
3569 (_initialize_thread): Update to setup the new commands 'taas
3570 and 'tfaas'. Change doc string for 'thread apply'.
3571
3572 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3573
3574 * stack.c: (trailing_outermost_frame): New function, mostly
3575 extracted from backtrace_command_1.
3576 (leading_innermost_frame): New function.
3577 (backtrace_command_1): Update to call trailing_outermost_frame.
3578 (frame_apply_command_count): New function.
3579 (frame_apply_level_command): New function.
3580 (frame_apply_all_command): New function.
3581 (frame_apply_command): New function.
3582 (faas_command): New function.
3583 (frame_cmd_list): New variable.
3584 (_initialize_stack): Update to setup the new commands 'frame apply'
3585 and 'faas'.
3586
3587 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3588
3589 * cli-utils.c (number_or_range_parser::get_number): Only handle
3590 numbers or convenience var as numbers.
3591 (parse_flags): New function.
3592 (parse_flags_qcs): New function.
3593 (number_or_range_parser::finished): Ensure parsing end is detected
3594 before end of string.
3595 * cli-utils.h (parse_flags): New function.
3596 (parse_flags_qcs): New function.
3597 (number_or_range_parser): Remove m_finished bool.
3598 (number_or_range_parser::skip_range): Set m_in_range to false.
3599
3600 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
3601
3602 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
3603 on Windows.
3604
3605 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3606 Jan Kratochvil <jan.kratochvil@redhat.com>
3607 Paul Fertser <fercerpav@gmail.com>
3608 Tsutomu Seki <sekiriki@gmail.com>
3609 Pedro Alves <palves@redhat.com>
3610
3611 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3612 'unittests/parse-connection-spec-selftests.c'.
3613 (COMMON_SFILES): Add 'common/netstuff.c'.
3614 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
3615 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
3616 * common/netstuff.c: New file.
3617 * common/netstuff.h: New file.
3618 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
3619 (wait_for_connect): Update comment. New parameter
3620 'gdb::optional<int> sock' instead of 'struct serial *scb'.
3621 Use 'sock' directly instead of 'scb->fd'.
3622 (try_connect): New function, with code from 'net_open'.
3623 (net_open): Rewrite main loop to deal with multiple
3624 sockets/addresses. Handle IPv6-style hostnames; implement
3625 support for IPv6 connections.
3626 * unittests/parse-connection-spec-selftests.c: New file.
3627
3628 2018-07-11 Pedro Alves <palves@redhat.com>
3629
3630 PR gdb/23377
3631 * remote.c (remote_target::remote_detach_pid): Call
3632 set_current_process.
3633
3634 2018-07-11 Pedro Alves <palves@redhat.com>
3635
3636 * h8300-tdep.c (h8300_gdbarch_init): Remove
3637 set_gdbarch_ecoff_reg_to_regnum calls.
3638
3639 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3640
3641 PR c++/23373
3642 * c-typeprint.c (c_type_print_base_struct_union): Don't print
3643 offsets/sizes for static members of a class/struct.
3644
3645 2018-07-11 Alan Hayward <alan.hayward@arm.com>
3646
3647 * target-descriptions.c (tdesc_register_bitsize): Rename.
3648 * target-descriptions.h (tdesc_register_bitsize): Likewise.
3649 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
3650 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
3651
3652 2018-07-10 Tom Tromey <tom@tromey.com>
3653
3654 * breakpoint.c (moribund_locations): Now static and a
3655 std::vector.
3656 (breakpoint_init_inferior, moribund_breakpoint_here_p)
3657 (build_bpstat_chain, update_global_location_list)
3658 (breakpoint_retire_moribund): Update.
3659 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
3660 VEC.
3661
3662 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
3663
3664 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
3665 (riscv_register_reggroup_p): Use new function, remove unneeded
3666 parenthesis.
3667 (riscv_push_dummy_call): Extend assert to compare against xlen or
3668 flen based on register type.
3669
3670 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
3671
3672 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
3673
3674 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
3675
3676 * remote.c (show_hardware_watchpoint_limit): New function.
3677 (show_hardware_watchpoint_length_limit): New function.
3678 (show_hardware_breakpoint_limit): New function.
3679 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
3680 where appropriate, update help text.
3681
3682 2018-07-09 Tom Tromey <tom@tromey.com>
3683
3684 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
3685 (CLIBS): Don't mention NAT_CLIBS.
3686
3687 2018-07-09 Tom Tromey <tom@tromey.com>
3688
3689 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
3690 (LIBGDB_OBS, clean mostlyclean): Update.
3691 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
3692
3693 2018-07-09 Tom Tromey <tom@tromey.com>
3694
3695 * Makefile.in (%.c: %.y): Use ECHO_YACC.
3696 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
3697 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
3698
3699 2018-07-09 Tom Tromey <tom@tromey.com>
3700
3701 * Makefile.in (ALLDEPFILES): Remove exec.c.
3702 (COMMON_OBS): Remove exec.o.
3703 (COMMON_SFILES): Add exec.c.
3704
3705 2018-07-09 Tom Tromey <tom@tromey.com>
3706
3707 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
3708
3709 2018-07-09 Tom Tromey <tom@tromey.com>
3710
3711 * Makefile.in (clean mostlyclean): Remove stamp-version.
3712 (version.c): Depend on stamp-version.
3713 (stamp-version): New rule, from version.c rule.
3714
3715 2018-07-09 Tom Tromey <tom@tromey.com>
3716
3717 * Makefile.in (init.c): Depend on stamp-init.
3718 (stamp-init): New rule, from init.c rule.
3719 (clean mostlyclean): Remove stamp-init.
3720
3721 2018-07-09 Tom Tromey <tom@tromey.com>
3722
3723 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
3724 SUBDIR_GCC_COMPILE_SRCS.
3725
3726 2018-07-09 Tom Tromey <tom@tromey.com>
3727
3728 * Makefile.in (init.c): Remove some unused sed rules.
3729
3730 2018-07-09 Tom Tromey <tom@tromey.com>
3731
3732 * Makefile.in (TSOBS): Remove.
3733 (INIT_FILES): Update.
3734 (LIBGDB_OBS): Update.
3735 (COMMON_SFILES): Add inflow.c.
3736 (SFILES): Remove inflow.c.
3737
3738 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
3739
3740 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
3741
3742 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
3743
3744 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
3745 get_saveloc_name, is_signal_frame_name, step_name,
3746 init_remote_name, create_addr_space_name,
3747 destroy_addr_space_name, search_unwind_table_name,
3748 find_dyn_list_name): Constify.
3749
3750 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
3751
3752 * darwin-nat.c (darwin_pthread_kill): New function.
3753 (darwin_resume_thread): Use darwin_pthread_kill.
3754
3755 2018-07-05 Tom de Vries <tdevries@suse.de>
3756
3757 * macroexp.c (macro_buffer) <operator=>: New member function.
3758
3759 2018-07-04 Tom Tromey <tom@tromey.com>
3760
3761 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
3762
3763 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
3764
3765 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
3766 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
3767 * maint.c: Likewise.
3768 * top.c: Likewise.
3769
3770 2018-07-04 Joel Brobecker <brobecker@adacore.com>
3771
3772 * NEWS: Create a new section for the next release branch.
3773 Rename the section of the current branch, now that it has
3774 been cut.
3775
3776 2018-07-04 Joel Brobecker <brobecker@adacore.com>
3777
3778 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
3779 * version.in: Bump version to 8.2.50.DATE-git.
3780
3781 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
3782 Pedro Alves <palves@redhat.com>
3783
3784 * linux-nat.c (linux_init_ptrace): Rename to ...
3785 (linux_init_ptrace_procfs): ... this. Call
3786 linux_proc_init_warnings.
3787 (linux_nat_target::post_attach)
3788 (linux_nat_target::post_startup_inferior): Adjust.
3789 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
3790 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
3791
3792 2018-07-04 Tom de Vries <tdevries@suse.de>
3793
3794 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
3795 check ...
3796 (read_comp_unit_head): ... here.
3797
3798 2018-07-03 Tom Tromey <tom@tromey.com>
3799
3800 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
3801 (stop_tracing, tstatus_command)
3802 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
3803 (print_one_static_tracepoint_marker): Update.
3804 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
3805 std::vector.
3806 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
3807 VEC.
3808 (all_tracepoints, static_tracepoints_here): Return std::vector.
3809
3810 2018-07-03 Tom Tromey <tom@tromey.com>
3811
3812 * common/ptid.c (ptid_equal): Remove.
3813 * common/ptid.h (ptid_equal): Don't declare.
3814 * ada-tasks.c: Update.
3815 * breakpoint.c: Update.
3816 * common/agent.c: Update.
3817 * corelow.c: Update.
3818 * darwin-nat-info.c: Update.
3819 * darwin-nat.c: Update.
3820 * dcache.c: Update.
3821 * dtrace-probe.c: Update.
3822 * dummy-frame.c: Update.
3823 * fbsd-nat.c: Update.
3824 * frame.c: Update.
3825 * gdbthread.h: Update.
3826 * gnu-nat.c: Update.
3827 * go32-nat.c: Update.
3828 * inf-loop.c: Update.
3829 * inf-ptrace.c: Update.
3830 * infcall.c: Update.
3831 * infcmd.c: Update.
3832 * inflow.c: Update.
3833 * infrun.c: Update.
3834 * linux-fork.c: Update.
3835 * linux-nat.c: Update.
3836 * linux-thread-db.c: Update.
3837 * mi/mi-cmd-var.c: Update.
3838 * mi/mi-interp.c: Update.
3839 * mi/mi-main.c: Update.
3840 * nto-procfs.c: Update.
3841 * ppc-linux-tdep.c: Update.
3842 * procfs.c: Update.
3843 * python/py-inferior.c: Update.
3844 * python/py-record-btrace.c: Update.
3845 * python/py-record.c: Update.
3846 * ravenscar-thread.c: Update.
3847 * regcache.c: Update.
3848 * remote-sim.c: Update.
3849 * remote.c: Update.
3850 * sol-thread.c: Update.
3851 * solib.c: Update.
3852 * target.c: Update.
3853 * tui/tui-stack.c: Update.
3854 * varobj.c: Update.
3855 * windows-nat.c: Update.
3856 * windows-tdep.c: Update.
3857
3858 2018-07-03 Tom Tromey <tom@tromey.com>
3859
3860 * common/ptid.c (ptid_match): Remove.
3861 * common/ptid.h (ptid_match): Don't declare.
3862 * fbsd-nat.c: Update.
3863 * infcmd.c: Update.
3864 * infrun.c: Update.
3865 * linux-nat.c: Update.
3866 * record-btrace.c: Update.
3867 * regcache.c: Update.
3868 * remote.c: Update.
3869
3870 2018-07-03 Tom Tromey <tom@tromey.com>
3871
3872 * common/ptid.c (ptid_tid_p): Remove.
3873 * common/ptid.h (ptid_tid_p): Don't declare.
3874 * sol-thread.c: Update.
3875
3876 2018-07-03 Tom Tromey <tom@tromey.com>
3877
3878 * common/ptid.c (ptid_lwp_p): Remove.
3879 * common/ptid.h (ptid_lwp_p): Don't declare.
3880 * fbsd-nat.c: Update.
3881 * linux-nat.c: Update.
3882 * nat/linux-procfs.c: Update.
3883 * nat/x86-linux-dregs.c: Update.
3884 * sol-thread.c: Update.
3885
3886 2018-07-03 Tom Tromey <tom@tromey.com>
3887
3888 * common/ptid.c (ptid_is_pid): Remove.
3889 * common/ptid.h (ptid_is_pid): Don't declare.
3890 * infrun.c: Update.
3891 * linux-nat.c: Update.
3892 * mi/mi-interp.c: Update.
3893 * remote.c: Update.
3894 * thread.c: Update.
3895
3896 2018-07-03 Tom Tromey <tom@tromey.com>
3897
3898 * common/ptid.c (ptid_get_tid): Remove.
3899 * common/ptid.h (ptid_get_tid): Don't declare.
3900 * ada-tasks.c: Update.
3901 * aix-thread.c: Update.
3902 * bsd-uthread.c: Update.
3903 * darwin-nat.c: Update.
3904 * fbsd-nat.c: Update.
3905 * i386-darwin-nat.c: Update.
3906 * infrun.c: Update.
3907 * linux-tdep.c: Update.
3908 * nto-procfs.c: Update.
3909 * ppc-ravenscar-thread.c: Update.
3910 * python/py-infthread.c: Update.
3911 * ravenscar-thread.c: Update.
3912 * sol-thread.c: Update.
3913 * sparc-ravenscar-thread.c: Update.
3914 * windows-nat.c: Update.
3915
3916 2018-07-03 Tom Tromey <tom@tromey.com>
3917
3918 * common/ptid.c (ptid_get_lwp): Remove.
3919 * common/ptid.h (ptid_get_lwp): Don't declare.
3920 * aarch64-linux-nat.c: Update.
3921 * ada-tasks.c: Update.
3922 * aix-thread.c: Update.
3923 * amd64-linux-nat.c: Update.
3924 * arm-linux-nat.c: Update.
3925 * corelow.c: Update.
3926 * fbsd-nat.c: Update.
3927 * fbsd-tdep.c: Update.
3928 * gnu-nat.c: Update.
3929 * i386-cygwin-tdep.c: Update.
3930 * i386-gnu-nat.c: Update.
3931 * i386-linux-nat.c: Update.
3932 * ia64-linux-nat.c: Update.
3933 * inf-ptrace.c: Update.
3934 * infrun.c: Update.
3935 * linux-fork.c: Update.
3936 * linux-nat.c: Update.
3937 * linux-tdep.c: Update.
3938 * linux-thread-db.c: Update.
3939 * mips-linux-nat.c: Update.
3940 * nat/aarch64-linux-hw-point.c: Update.
3941 * nat/aarch64-linux.c: Update.
3942 * nat/linux-btrace.c: Update.
3943 * nat/linux-osdata.c: Update.
3944 * nat/linux-procfs.c: Update.
3945 * nat/x86-linux-dregs.c: Update.
3946 * obsd-nat.c: Update.
3947 * ppc-fbsd-nat.c: Update.
3948 * ppc-linux-nat.c: Update.
3949 * procfs.c: Update.
3950 * python/py-infthread.c: Update.
3951 * ravenscar-thread.c: Update.
3952 * remote.c: Update.
3953 * s390-linux-nat.c: Update.
3954 * sol-thread.c: Update.
3955 * sol2-tdep.c: Update.
3956 * spu-linux-nat.c: Update.
3957 * x86-linux-nat.c: Update.
3958 * xtensa-linux-nat.c: Update.
3959
3960 2018-07-03 Tom Tromey <tom@tromey.com>
3961
3962 * common/ptid.c (ptid_get_pid): Remove.
3963 * common/ptid.h (ptid_get_pid): Don't declare.
3964 * aarch64-linux-nat.c: Update.
3965 * ada-lang.c: Update.
3966 * aix-thread.c: Update.
3967 * alpha-bsd-nat.c: Update.
3968 * amd64-fbsd-nat.c: Update.
3969 * amd64-linux-nat.c: Update.
3970 * arm-linux-nat.c: Update.
3971 * arm-nbsd-nat.c: Update.
3972 * auxv.c: Update.
3973 * break-catch-syscall.c: Update.
3974 * breakpoint.c: Update.
3975 * bsd-uthread.c: Update.
3976 * corelow.c: Update.
3977 * ctf.c: Update.
3978 * darwin-nat.c: Update.
3979 * fbsd-nat.c: Update.
3980 * fbsd-tdep.c: Update.
3981 * gcore.c: Update.
3982 * gnu-nat.c: Update.
3983 * hppa-nbsd-nat.c: Update.
3984 * hppa-obsd-nat.c: Update.
3985 * i386-fbsd-nat.c: Update.
3986 * ia64-linux-nat.c: Update.
3987 * inf-ptrace.c: Update.
3988 * infcmd.c: Update.
3989 * inferior.c: Update.
3990 * inferior.h: Update.
3991 * inflow.c: Update.
3992 * infrun.c: Update.
3993 * linux-fork.c: Update.
3994 * linux-nat.c: Update.
3995 * linux-tdep.c: Update.
3996 * linux-thread-db.c: Update.
3997 * m68k-bsd-nat.c: Update.
3998 * mi/mi-interp.c: Update.
3999 * mi/mi-main.c: Update.
4000 * mips-linux-nat.c: Update.
4001 * mips-nbsd-nat.c: Update.
4002 * mips64-obsd-nat.c: Update.
4003 * nat/aarch64-linux-hw-point.c: Update.
4004 * nat/aarch64-linux.c: Update.
4005 * nat/linux-btrace.c: Update.
4006 * nat/linux-osdata.c: Update.
4007 * nat/linux-procfs.c: Update.
4008 * nat/x86-linux-dregs.c: Update.
4009 * nto-procfs.c: Update.
4010 * obsd-nat.c: Update.
4011 * ppc-linux-nat.c: Update.
4012 * ppc-nbsd-nat.c: Update.
4013 * ppc-obsd-nat.c: Update.
4014 * proc-service.c: Update.
4015 * procfs.c: Update.
4016 * python/py-inferior.c: Update.
4017 * python/py-infthread.c: Update.
4018 * ravenscar-thread.c: Update.
4019 * record.c: Update.
4020 * remote-sim.c: Update.
4021 * remote.c: Update.
4022 * rs6000-nat.c: Update.
4023 * s390-linux-nat.c: Update.
4024 * sh-nbsd-nat.c: Update.
4025 * sol-thread.c: Update.
4026 * sparc-nat.c: Update.
4027 * sparc64-tdep.c: Update.
4028 * spu-linux-nat.c: Update.
4029 * spu-tdep.c: Update.
4030 * target-debug.h: Update.
4031 * target.c: Update.
4032 * thread.c: Update.
4033 * tid-parse.c: Update.
4034 * tracefile-tfile.c: Update.
4035 * vax-bsd-nat.c: Update.
4036 * windows-nat.c: Update.
4037 * x86-linux-nat.c: Update.
4038 * x86-nat.c: Update.
4039
4040 2018-07-03 Tom Tromey <tom@tromey.com>
4041
4042 * common/ptid.c (pid_to_ptid): Remove.
4043 * common/ptid.h (pid_to_ptid): Don't declare.
4044 * aix-thread.c: Update.
4045 * arm-linux-nat.c: Update.
4046 * common/ptid.c: Update.
4047 * common/ptid.h: Update.
4048 * corelow.c: Update.
4049 * ctf.c: Update.
4050 * darwin-nat.c: Update.
4051 * fbsd-nat.c: Update.
4052 * fork-child.c: Update.
4053 * gnu-nat.c: Update.
4054 * go32-nat.c: Update.
4055 * inf-ptrace.c: Update.
4056 * infcmd.c: Update.
4057 * inferior.c: Update.
4058 * infrun.c: Update.
4059 * linux-fork.c: Update.
4060 * linux-nat.c: Update.
4061 * nat/aarch64-linux-hw-point.c: Update.
4062 * nat/fork-inferior.c: Update.
4063 * nat/x86-linux-dregs.c: Update.
4064 * nto-procfs.c: Update.
4065 * obsd-nat.c: Update.
4066 * procfs.c: Update.
4067 * progspace.c: Update.
4068 * remote.c: Update.
4069 * rs6000-nat.c: Update.
4070 * s390-linux-nat.c: Update.
4071 * sol-thread.c: Update.
4072 * spu-linux-nat.c: Update.
4073 * target.c: Update.
4074 * top.c: Update.
4075 * tracefile-tfile.c: Update.
4076 * windows-nat.c: Update.
4077
4078 2018-07-03 Tom Tromey <tom@tromey.com>
4079
4080 * common/ptid.h (ptid_build): Don't declare.
4081 * common/ptid.c (ptid_build): Remove.
4082 * aix-thread.c: Update.
4083 * bsd-kvm.c: Update.
4084 * bsd-uthread.c: Update.
4085 * common/agent.c: Update.
4086 * common/ptid.c: Update.
4087 * common/ptid.h: Update.
4088 * corelow.c: Update.
4089 * darwin-nat.c: Update.
4090 * fbsd-nat.c: Update.
4091 * gnu-nat.c: Update.
4092 * linux-fork.c: Update.
4093 * linux-nat.c: Update.
4094 * linux-thread-db.c: Update.
4095 * nat/linux-osdata.c: Update.
4096 * nat/linux-procfs.c: Update.
4097 * nto-procfs.c: Update.
4098 * obsd-nat.c: Update.
4099 * proc-service.c: Update.
4100 * procfs.c: Update.
4101 * ravenscar-thread.c: Update.
4102 * remote-sim.c: Update.
4103 * remote.c: Update.
4104 * sol-thread.c: Update.
4105 * target.c: Update.
4106 * windows-nat.c: Update.
4107
4108 2018-07-03 Tom Tromey <tom@tromey.com>
4109
4110 * infrun.c (follow_exec): Use exit_inferior_silent.
4111 * inferior.c (exit_inferior_num_silent): Remove.
4112 * inferior.h (exit_inferior_num_silent): Don't declare.
4113
4114 2018-07-03 Tom Tromey <tom@tromey.com>
4115
4116 PR cli/23340:
4117 * darwin-nat.c (darwin_attach_pid): Reset inferior and
4118 inferior_ptid on error.
4119
4120 2018-07-02 Maciej W. Rozycki <macro@mips.com>
4121 Simon Marchi <simon.marchi@polymtl.ca>
4122
4123 PR tdep/8282
4124 * disasm.h (gdb_disassembler): Add
4125 `m_disassembler_options_holder'. member
4126 * disasm.c (get_all_disassembler_options): New function.
4127 (gdb_disassembler::gdb_disassembler): Use it.
4128 (gdb_buffered_insn_length_init_dis): Likewise.
4129 (gdb_buffered_insn_length): Adjust accordingly.
4130 (set_disassembler_options): Handle options with arguments.
4131 (show_disassembler_options_sfunc): Likewise. Add a leading new
4132 line if showing options with descriptions.
4133 (disassembler_options_completer): Adapt to using the
4134 `disasm_options_and_args_t' structure.
4135 * mips-tdep.c (mips_disassembler_options): New variable.
4136 (mips_disassembler_options_o32): Likewise.
4137 (mips_disassembler_options_n32): Likewise.
4138 (mips_disassembler_options_n64): Likewise.
4139 (gdb_print_insn_mips): Don't set `disassembler_options'.
4140 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
4141 functions.
4142 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
4143 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
4144 `gdbarch_disassembler_options_implicit' and
4145 `gdbarch_valid_disassembler_options'.
4146 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
4147 `disasm_options_and_args_t' structure.
4148 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
4149 method.
4150 (valid_disassembler_options): Switch from `disasm_options_t' to
4151 the `disasm_options_and_args_t' structure.
4152 * NEWS: Document `set disassembler-options' support for the MIPS
4153 target.
4154 * gdbarch.h: Regenerate.
4155 * gdbarch.c: Regenerate.
4156
4157 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
4158
4159 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
4160
4161 2018-06-29 Joel Brobecker <brobecker@adacore.com>
4162
4163 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
4164 parameter in call to amd64_target_description.
4165 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
4166 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
4167 (amd64fbsd_init_abi): Likewise.
4168 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
4169 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
4170 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
4171 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
4172
4173 2018-06-29 Pedro Alves <palves@redhat.com>
4174
4175 * gdb/amd64-tdep.h (amd64_create_target_description): Add
4176 "segments" parameter.
4177 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
4178 (_initialize_amd64_tdep): Update call to
4179 amd64_create_target_description.
4180 (amd64_target_description): Add "segments" parameter. Adjust
4181 the implementation to use it.
4182 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
4183 call to amd64_create_target_description.
4184 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
4185 * gdb/arch/amd64.h (amd64_create_target_description): Add
4186 "segments" register.
4187 * gdb/arch/amd64.c (amd64_create_target_description): Add
4188 "segments" parameter. Call create_feature_i386_64bit_segments
4189 only if SEGMENTS is true.
4190 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
4191 call to amd64_create_target_description.
4192
4193 2018-06-29 Pedro Alves <palves@redhat.com>
4194
4195 * thread.c (thread_target_id_str): New, factored out from ...
4196 (print_thread_info_1): ... here. Use it to compute the max
4197 "Target Id" column width.
4198
4199 2018-06-29 Pedro Alves <palves@redhat.com>
4200
4201 * remote.c (remote_target::extra_thread_info): Delete
4202 'display_buf' and 'n' locals. from the cache, regardless of
4203 packet mechanims is in use. Use cache for qThreadExtra and qP
4204 methods too.
4205
4206 2018-06-29 Pedro Alves <palves@redhat.com>
4207
4208 * blockframe.c (find_pc_sect_containing_function): New function.
4209 * breakpoint.c (print_breakpoint_location): Don't call
4210 find_pc_sect_function.
4211 * linespec.c (create_sals_line_offset): Record the location's
4212 symbol in the sal.
4213 * linespec.c (convert_address_location_to_sals): Fill in sal's
4214 symbol with find_pc_sect_containing_function.
4215 * symtab.c (find_function_start_sal): Rename to ...
4216 (find_function_start_sal_1): ... this.
4217 (find_function_start_sal): Reimplement as wrapper around
4218 find_function_start_sal_1, and use
4219 find_pc_sect_containing_function to fill in the sal's symbol.
4220 (find_function_start_sal(symbol*, bool)): Adjust.
4221 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
4222 comments.
4223 (find_pc_sect_containing_function): Declare.
4224
4225 2018-06-29 Pedro Alves <palves@redhat.com>
4226
4227 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
4228 true if the the location has no symbol.
4229
4230 2018-06-28 Tom Tromey <tom@tromey.com>
4231
4232 * NEWS: Mention --enable-codesign.
4233 * silent-rules.mk (ECHO_SIGN): New variable.
4234 * configure.ac: Add --enable-codesign.
4235 * configure: Rebuild.
4236 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
4237 (gdb$(EXEEXT)): Optionally invoke codesign.
4238
4239 2018-06-28 Pedro Alves <palves@redhat.com>
4240
4241 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
4242 comments.
4243 (switch_to_thread_no_regs): Adjust comment.
4244 * infcmd.c (stop_pc): Delete.
4245 (post_create_inferior, info_program_command): Replace references
4246 to stop_pc with references to thread_info->suspend.stop_pc.
4247 * inferior.h (stop_pc): Delete declaration.
4248 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
4249 (handle_inferior_event_1, handle_signal_stop)
4250 (process_event_stop_test, keep_going_stepped_thread)
4251 (handle_step_into_function, handle_step_into_function_backward)
4252 (print_stop_location): Replace references to stop_pc with
4253 references to thread_info->suspend.stop_pc.
4254 (struct infcall_suspend_state) <stop_pc>: Delete field.
4255 (save_infcall_suspend_state, restore_infcall_suspend_state):
4256 Remove references to inf_stat->stop_pc.
4257 * linux-fork.c (fork_load_infrun_state): Likewise.
4258 * record-btrace.c (record_btrace_set_replay): Likewise.
4259 * record-full.c (record_full_goto_entry): Likewise.
4260 * remote.c (print_one_stopped_thread): Likewise.
4261 * target.c (target_resume): Extend comment.
4262 * thread.c (set_executing_thread): New.
4263 (set_executing): Use it.
4264 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
4265 Remove references to stop_pc.
4266
4267 2018-06-28 Pedro Alves <palves@redhat.com>
4268
4269 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
4270 Moving fetching stop_pc until after ecs->event_thread is refreshed.
4271
4272 2018-06-28 Tom Tromey <tom@tromey.com>
4273
4274 * coffread.c (coff_symfile_finish): Update.
4275 * xcoffread.c (xcoff_symfile_finish): Update.
4276 * elfread.c (elf_symfile_finish): Update.
4277 * symfile.h (dwarf2_free_objfile): Don't declare.
4278 * dwarf2read.c (_initialize_dwarf2_read): Use
4279 register_objfile_data_with_cleanup.
4280 (dwarf2_free_objfile): Now static. Change signature.
4281
4282 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4283
4284 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
4285 option "-o" to add-symbol-file-load to add an offset to each
4286 section's load address.
4287 * symfile.c (set_objfile_default_section_offset): New function.
4288
4289 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4290
4291 * symfile.c (add_symbol_file_command): Make sure that sections
4292 with the same name are sorted in the same order.
4293
4294 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4295
4296 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
4297 require the second argument. If omitted, load sections at the
4298 addresses specified in the file.
4299
4300 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4301
4302 * symfile.c (symbol_file_command, symbol_file_add_main_1)
4303 (_initialize_symfile): Add option "-o" to symbol-file to add an
4304 offset to each section of the symbol file.
4305
4306 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4307
4308 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
4309
4310 2018-06-27 Tom Tromey <tom@tromey.com>
4311
4312 * stack.c (_initialize_stack): Update "func" help text.
4313
4314 2018-06-27 Tom Tromey <tom@tromey.com>
4315
4316 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
4317 std::vector.
4318 (unwind_infopy_str, pyuw_create_unwind_info)
4319 (unwind_infopy_add_saved_register, pyuw_sniffer)
4320 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
4321 Update.
4322 (struct saved_reg): Add constructor.
4323 <value>: Now a gdbpy_ref<>.
4324
4325 2018-06-27 Tom Tromey <tom@tromey.com>
4326
4327 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
4328
4329 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4330
4331 * gdb-gdb.py.in: Format using autopep8.
4332
4333 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4334
4335 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
4336 (type_lookup_function): Recognize CORE_ADDR values.
4337
4338 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4339
4340 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
4341 print tag_name.
4342
4343 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4344
4345 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
4346 <__lt__>: Add.
4347
4348 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4349
4350 * gdb-gdb.py: Move to...
4351 * gdb-gdb.py.in: ... here.
4352 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
4353 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
4354 dependencies.
4355 (distclean): Remove gdb-gdb.py when cleaning.
4356 (gdb-gdb.py, gdb-gdb.gdb): New rules.
4357 * configure: Re-generate.
4358
4359 2018-06-27 Pedro Alves <palves@redhat.com>
4360
4361 * proc-service.c (get_ps_regcache): New.
4362 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
4363 (ps_lsetfpregs): Use it.
4364
4365 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
4366
4367 PR gdb/21695
4368 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
4369 (dwarf_decode_lines_1): Adjust.
4370
4371 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4372
4373 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
4374 override.
4375 <info_proc>: Likewise.
4376
4377 2018-06-26 Joel Brobecker <brobecker@adacore.com>
4378
4379 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
4380 to windows_fetch_one_register, and only handle the case of
4381 fetching one register. Move the code that reloads the context
4382 and iterates over all registers if R is negative to...
4383 (windows_nat_target::fetch_registers): ... here.
4384 (do_windows_store_inferior_registers): Rename to
4385 windows_store_one_register, and only handle the case of storing
4386 one register. Move the code that handles the case where r is
4387 negative to...
4388 (windows_nat_target::store_registers) ... here.
4389
4390 2018-06-26 Tom Tromey <tom@tromey.com>
4391
4392 PR rust/22574:
4393 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
4394 * rust-lang.c (rust_print_struct_def): Add podata parameter.
4395 Update.
4396 (rust_internal_print_type): Add podata parameter.
4397 (rust_print_type): Update.
4398
4399 2018-06-26 Tom Tromey <tom@tromey.com>
4400
4401 * typeprint.h (struct print_offset_data) <update, finish,
4402 maybe_print_hole>: New methods.
4403 <indentation>: New constant.
4404 * typeprint.c (print_offset_data::indentation): Define.
4405 (print_offset_data::maybe_print_hole, print_offset_data::update)
4406 (print_offset_data::finish): Move from c-typeprint.c and rename.
4407 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
4408 (print_spaces_filtered_with_print_options): Update.
4409 (c_print_type_union_field_offset, maybe_print_hole)
4410 (c_print_type_struct_field_offset): Move to typeprint.c and
4411 rename.
4412 (c_type_print_base_struct_union): Update.
4413
4414 2018-06-25 Pedro Alves <palves@redhat.com>
4415
4416 * gdbthread.h (thread_info_ref, delete_thread)
4417 (delete_thread_silent, first_thread_of_inferior)
4418 (any_thread_of_inferior, switch_to_thread)
4419 (enable_thread_stack_temporaries)
4420 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4421 (get_last_thread_stack_temporary)
4422 (value_in_thread_stack_temporaries, can_access_registers_thread):
4423 Spell out "struct thread_info" instead of just "thread_info".
4424 * inferior.h (notice_new_inferior): Likewise.
4425
4426 2018-06-25 Pedro Alves <palves@redhat.com>
4427
4428 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4429 pass thread_info pointer to delete_thread.
4430 (windows_nat_target::detach): Pass inferior pointer to
4431 detach_inferior.
4432 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
4433 delete_thread.
4434 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
4435 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
4436 and pass a thread_info pointer to delete_thread.
4437 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
4438 pass thread_info pointer to delete_thread.
4439 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
4440 delete_thread_silent call.
4441 * procfs.c (procfs_target::detach): Pass inferior pointer to
4442 detach_inferior.
4443 (procfs_target::wait): Pass thread_info pointer to delete_thread.
4444 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
4445 delete_thread_silent call.
4446 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4447 pass thread_info pointer to delete_thread.
4448 (windows_nat_target::detach): Pass inferior pointer to
4449 delete_inferior.
4450
4451 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4452
4453 * regcache.c (readable_regcache::read_part): Fix asserts.
4454 (reg_buffer::raw_collect_part): New function.
4455 (regcache::write_part): Fix asserts.
4456 (reg_buffer::raw_supply_part): New function.
4457 (regcache::transfer_regset_register): New helper function.
4458 (regcache::transfer_regset): Call new functions.
4459 (regcache_supply_regset): Use gdb_byte*.
4460 (regcache::supply_regset): Likewise.
4461 (regcache_collect_regset): Likewise.
4462 (regcache::collect_regset): Likewise.
4463 * regcache.h (reg_buffer::raw_collect_part): New declaration.
4464 (reg_buffer::raw_supply_part): Likewise.
4465 (regcache::transfer_regset_register): Likewise.
4466 (regcache::transfer_regset): Use gdb_byte*.
4467
4468 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4469
4470 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
4471
4472 2018-06-21 Pedro Alves <palves@redhat.com>
4473
4474 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
4475 instead of a ptid_t. All callers adjusted.
4476 * ada-tasks.c (ada_get_task_number): Likewise. All callers
4477 adjusted.
4478 (print_ada_task_info, display_current_task_id, task_command_1):
4479 Adjust.
4480 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
4481 inferior_thread.
4482 (breakpoint_kind): Adjust.
4483 (remove_breakpoints_pid): Rename to ...
4484 (remove_breakpoints_inf): ... this. Adjust to take an inferior
4485 pointer. All callers adjusted.
4486 (bpstat_clear_actions): Use inferior_thread.
4487 (get_bpstat_thread): New.
4488 (bpstat_do_actions): Use it.
4489 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
4490 to take a thread_info pointer. All callers adjusted.
4491 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
4492 (breakpoint_re_set_thread): Use inferior_thread.
4493 * breakpoint.h (struct inferior): Forward declare.
4494 (bpstat_stop_status): Update.
4495 (remove_breakpoints_pid): Delete.
4496 (remove_breakpoints_inf): New.
4497 * bsd-uthread.c (bsd_uthread_target::wait)
4498 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
4499 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
4500 (maint_btrace_packet_history_cmd)
4501 (maint_btrace_clear_packet_history_cmd): Adjust.
4502 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
4503 inferior_thread.
4504 * cli/cli-interp.c: Include "inferior.h".
4505 * common/refcounted-object.h (struct
4506 refcounted_object_ref_policy): New.
4507 * compile/compile-object-load.c: Include gdbthread.h.
4508 (store_regs): Use inferior_thread.
4509 * corelow.c (core_target::close): Use current_inferior.
4510 (core_target_open): Adjust to use first_thread_of_inferior and use
4511 the current inferior.
4512 * ctf.c (ctf_target::close): Adjust to use current_inferior.
4513 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
4514 <thread>: ... this new field. All references adjusted.
4515 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
4516 Take a thread_info pointer instead of a ptid_t.
4517 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
4518 (dummy_frame_discard, register_dummy_frame_dtor): Take a
4519 thread_info pointer instead of a ptid_t.
4520 * elfread.c: Include "inferior.h".
4521 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
4522 Use inferior_thread.
4523 * eval.c (evaluate_subexp): Likewise.
4524 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
4525 inferior_thread.
4526 * gdb_proc_service.h (struct thread_info): Forward declare.
4527 (struct ps_prochandle) <ptid>: Delete, replaced by ...
4528 <thread>: ... this new field. All references adjusted.
4529 * gdbarch.h, gdbarch.c: Regenerate.
4530 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
4531 'thread' parameter. All implementations and callers adjusted.
4532 * gdbthread.h (thread_info) <set_running>: New method.
4533 (delete_thread, delete_thread_silent): Take a thread_info pointer
4534 instead of a ptid.
4535 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
4536 (first_thread_of_process): Delete, replaced by ...
4537 (first_thread_of_inferior): ... this new function. All callers
4538 adjusted.
4539 (any_live_thread_of_process): Delete, replaced by ...
4540 (any_live_thread_of_inferior): ... this new function. All callers
4541 adjusted.
4542 (switch_to_thread, switch_to_no_thread): Declare.
4543 (is_executing): Delete.
4544 (enable_thread_stack_temporaries): Update comment.
4545 <enable_thread_stack_temporaries>: Take a thread_info pointer
4546 instead of a ptid_t. Incref the thread.
4547 <~enable_thread_stack_temporaries>: Decref the thread.
4548 <m_ptid>: Delete
4549 <m_thr>: New.
4550 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4551 (get_last_thread_stack_temporary)
4552 (value_in_thread_stack_temporaries, can_access_registers_thread):
4553 Take a thread_info pointer instead of a ptid_t. All callers
4554 adjusted.
4555 * infcall.c (get_call_return_value): Use inferior_thread.
4556 (run_inferior_call): Work with thread pointers instead of ptid_t.
4557 (call_function_by_hand_dummy): Work with thread pointers instead
4558 of ptid_t. Use thread_info_ref.
4559 * infcmd.c (proceed_thread_callback): Access thread's state
4560 directly.
4561 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
4562 access thread's state directly.
4563 (continue_command): Use inferior_thread.
4564 (info_program_command): Use find_thread_ptid and access thread
4565 state directly.
4566 (proceed_after_attach_callback): Use thread state directly.
4567 (notice_new_inferior): Take a thread_info pointer instead of a
4568 ptid_t. All callers adjusted.
4569 (exit_inferior): Take an inferior pointer instead of a pid. All
4570 callers adjusted.
4571 (exit_inferior_silent): New.
4572 (detach_inferior): Delete.
4573 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
4574 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
4575 (detach_inferior_command, kill_inferior_command): Use
4576 find_inferior_id instead of valid_gdb_inferior_id and
4577 gdb_inferior_id_to_pid.
4578 (inferior_command): Use inferior and thread pointers.
4579 * inferior.h (struct thread_info): Forward declare.
4580 (notice_new_inferior): Take a thread_info pointer instead of a
4581 ptid_t. All callers adjusted.
4582 (detach_inferior): Delete declaration.
4583 (exit_inferior, exit_inferior_silent): Take an inferior pointer
4584 instead of a pid. All callers adjusted.
4585 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
4586 (valid_gdb_inferior_id): Delete.
4587 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
4588 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
4589 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
4590 ...
4591 <inf>: ... this new field.
4592 <step_ptid>: Delete, replaced by ...
4593 <step_thread>: ... this new field.
4594 (get_displaced_stepping_state): Take an inferior pointer instead
4595 of a pid. All callers adjusted.
4596 (displaced_step_in_progress_any_inferior): Adjust.
4597 (displaced_step_in_progress_thread): Take a thread pointer instead
4598 of a ptid_t. All callers adjusted.
4599 (displaced_step_in_progress, add_displaced_stepping_state): Take
4600 an inferior pointer instead of a pid. All callers adjusted.
4601 (get_displaced_step_closure_by_addr): Adjust.
4602 (remove_displaced_stepping_state): Take an inferior pointer
4603 instead of a pid. All callers adjusted.
4604 (displaced_step_prepare_throw, displaced_step_prepare)
4605 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
4606 All callers adjusted.
4607 (start_step_over): Adjust.
4608 (infrun_thread_ptid_changed): Remove bit updating ptids in the
4609 displaced step queue.
4610 (do_target_resume): Adjust.
4611 (fetch_inferior_event): Use inferior_thread.
4612 (context_switch, get_inferior_stop_soon): Take an
4613 execution_control_state pointer instead of a ptid_t. All callers
4614 adjusted.
4615 (switch_to_thread_cleanup): Delete.
4616 (stop_all_threads): Use scoped_restore_current_thread.
4617 * inline-frame.c: Include "gdbthread.h".
4618 (inline_state) <inline_state>: Take a thread pointer instead of a
4619 ptid_t. All callers adjusted.
4620 <ptid>: Delete, replaced by ...
4621 <thread>: ... this new field.
4622 (find_inline_frame_state): Take a thread pointer instead of a
4623 ptid_t. All callers adjusted.
4624 (skip_inline_frames, step_into_inline_frame)
4625 (inline_skipped_frames, inline_skipped_symbol): Take a thread
4626 pointer instead of a ptid_t. All callers adjusted.
4627 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
4628 (inline_skipped_frames, inline_skipped_symbol): Likewise.
4629 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
4630 pointers directly.
4631 * linux-nat.c (get_detach_signal): Likewise.
4632 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
4633 (thread_db_notice_clone): Adjust.
4634 (thread_db_find_new_threads_silently)
4635 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
4636 a thread pointer instead of a ptid_t. All callers adjusted.
4637 * mi/mi-cmd-var.c: Include "inferior.h".
4638 (mi_cmd_var_update_iter): Update to use thread pointers.
4639 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
4640 inferior directly.
4641 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
4642 out to ...
4643 (mi_output_running): ... this new function.
4644 (mi_on_resume_1): Adjust to use it.
4645 (mi_user_selected_context_changed): Adjust to use inferior_thread.
4646 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
4647 directly.
4648 (interrupt_thread_callback): : Adjust to use thread and inferior
4649 pointers.
4650 * proc-service.c: Include "gdbthread.h".
4651 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
4652 * progspace-and-thread.c: Include "inferior.h".
4653 * progspace.c: Include "inferior.h".
4654 * python/py-exitedevent.c (create_exited_event_object): Adjust to
4655 hold a reference to an inferior_object.
4656 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
4657 inferior_thread.
4658 * python/py-inferior.c (struct inferior_object): Give the type a
4659 tag name instead of a typedef.
4660 (python_on_normal_stop): No need to check if the current thread is
4661 listed.
4662 (inferior_to_inferior_object): Change return type to
4663 inferior_object. All callers adjusted.
4664 (find_thread_object): Delete, bits factored out to ...
4665 (thread_to_thread_object): ... this new function.
4666 * python/py-infthread.c (create_thread_object): Use
4667 inferior_to_inferior_object.
4668 (thpy_is_stopped): Use thread pointer directly.
4669 (gdbpy_selected_thread): Use inferior_thread.
4670 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
4671 field, replaced with ...
4672 <thread>: ... this new field. All users adjusted.
4673 (btpy_insn_or_gap_new): Drop const.
4674 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
4675 callers adjusted.
4676 * python/py-record.c: Include "gdbthread.h".
4677 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4678 a ptid_t. All callers adjusted.
4679 (gdbpy_current_recording): Use inferior_thread.
4680 * python/py-record.h (recpy_record_object) <ptid>: Delete
4681 field, replaced with ...
4682 <thread>: ... this new field. All users adjusted.
4683 (recpy_element_object) <ptid>: Delete
4684 field, replaced with ...
4685 <thread>: ... this new field. All users adjusted.
4686 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4687 a ptid_t. All callers adjusted.
4688 * python/py-threadevent.c: Include "gdbthread.h".
4689 (get_event_thread): Use thread_to_thread_object.
4690 * python/python-internal.h (struct inferior_object): Forward
4691 declare.
4692 (find_thread_object, find_inferior_object): Delete declarations.
4693 (thread_to_thread_object, inferior_to_inferior_object): New
4694 declarations.
4695 * record-btrace.c: Include "inferior.h".
4696 (require_btrace_thread): Use inferior_thread.
4697 (record_btrace_frame_sniffer)
4698 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
4699 (get_thread_current_frame): Use scoped_restore_current_thread and
4700 switch_to_thread.
4701 (get_thread_current_frame): Use thread pointer directly.
4702 (record_btrace_replay_at_breakpoint): Use thread's inferior
4703 pointer directly.
4704 * record-full.c: Include "inferior.h".
4705 * regcache.c: Include "gdbthread.h".
4706 (get_thread_arch_regcache): Use the inferior's address space
4707 directly.
4708 (get_thread_regcache, registers_changed_thread): New.
4709 * regcache.h (get_thread_regcache(thread_info *thread)): New
4710 overload.
4711 (registers_changed_thread): New.
4712 (remote_target) <remote_detach_1>: Swap order of parameters.
4713 (remote_add_thread): <remote_add_thread>: Return the new thread.
4714 (get_remote_thread_info(ptid_t)): New overload.
4715 (remote_target::remote_notice_new_inferior): Use thread pointers
4716 directly.
4717 (remote_target::process_initial_stop_replies): Use
4718 thread_info::set_running.
4719 (remote_target::remote_detach_1, remote_target::detach)
4720 (extended_remote_target::detach): Adjust.
4721 * stack.c (frame_show_address): Use inferior_thread.
4722 * target-debug.h (target_debug_print_thread_info_pp): New.
4723 * target-delegates.c: Regenerate.
4724 * target.c (default_thread_address_space): Delete.
4725 (memory_xfer_partial_1): Use current_inferior.
4726 (target_detach): Use current_inferior.
4727 (target_thread_address_space): Delete.
4728 (generic_mourn_inferior): Use current_inferior.
4729 * target.h (struct target_ops) <thread_address_space>: Delete.
4730 (target_thread_address_space): Delete.
4731 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
4732 pointers directly.
4733 (delete_thread_1, delete_thread, delete_thread_silent): Take a
4734 thread pointer instead of a ptid_t. Adjust all callers.
4735 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
4736 (first_thread_of_process): Delete, replaced by ...
4737 (first_thread_of_inferior): ... this new function. All callers
4738 adjusted.
4739 (any_thread_of_process): Rename to ...
4740 (any_thread_of_inferior): ... this, and take an inferior pointer.
4741 (any_live_thread_of_process): Rename to ...
4742 (any_live_thread_of_inferior): ... this, and take an inferior
4743 pointer.
4744 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4745 (value_in_thread_stack_temporaries)
4746 (get_last_thread_stack_temporary): Take a thread pointer instead
4747 of a ptid_t. Adjust all callers.
4748 (thread_info::set_running): New.
4749 (validate_registers_access): Use inferior_thread.
4750 (can_access_registers_ptid): Rename to ...
4751 (can_access_registers_thread): ... this, and take a thread
4752 pointer.
4753 (print_thread_info_1): Adjust to compare thread pointers instead
4754 of ptids.
4755 (switch_to_no_thread, switch_to_thread): Make extern.
4756 (scoped_restore_current_thread::~scoped_restore_current_thread):
4757 Use m_thread pointer directly.
4758 (scoped_restore_current_thread::scoped_restore_current_thread):
4759 Use inferior_thread.
4760 (thread_command): Use thread pointer directly.
4761 (thread_num_make_value_helper): Use inferior_thread.
4762 * top.c (execute_command): Use inferior_thread.
4763 * tui/tui-interp.c: Include "inferior.h".
4764 * varobj.c (varobj_create): Use inferior_thread.
4765 (value_of_root_1): Use find_thread_global_id instead of
4766 global_thread_id_to_ptid.
4767
4768 2018-06-21 Alan Hayward <alan.hayward@arm.com>
4769
4770 * regcache.c (readable_regcache::read_part): Avoid memcpy when
4771 possible.
4772 (regcache::write_part): Likewise.
4773 (readable_regcache::cooked_read_part): Update comment.
4774 (readable_regcache::cooked_write_part): Likewise.
4775 * regcache.h: (readable_regcache::read_part): Likewise.
4776 (regcache::write_part): Likewise.
4777
4778 2018-06-21 Richard Bunt <richard.bunt@arm.com>
4779 Dirk Schubert <dirk.schubert@arm.com>
4780
4781 * aarch64-linux-nat.c (post_attach): New.
4782 (aarch64_linux_nat_target::post_attach): Override post_attach to
4783 record the number of hardware debug registers.
4784
4785 2018-06-20 Tom Tromey <tom@tromey.com>
4786
4787 * python/py-param.c (add_setshow_generic): Make parameters const.
4788 (parmpy_init): Update.
4789
4790 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
4791
4792 * regcache.h (regcache_cooked_read_ftype): Rename to...
4793 (register_read_ftype): ...this, change type to function_view.
4794 (class reg_buffer) <save>: Remove src parameter.
4795 (readonly_detached_regcache) <readonly_detached_regcache>: Make
4796 parameter non-const in first overload. Remove src parameter in
4797 second overload.
4798 * regcache.c (do_cooked_read): Remove.
4799 (readonly_detached_regcache::readonly_detached_regcache): Make
4800 parameter non-const, adjust call to other constructor.
4801 (reg_buffer::save): Remove src parameter.
4802 * frame.c (do_frame_register_read): Remove.
4803 (frame_save_as_regcache): Use lambda function.
4804 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
4805 parameter to ppu2spu_data *.
4806 (ppu2spu_sniffer): Use lambda function.
4807
4808 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
4809
4810 * record-full.c (record_full_target::insert_breakpoint): Remove
4811 "struct" keyword, add const.
4812
4813 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
4814
4815 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
4816 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
4817 * configure.ac: Remove AC_PREREQ, add missing quoting.
4818 * gnulib/configure.ac: Modernize usage of
4819 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
4820 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
4821 (AUTOMAKE_VERSION): Bump to 1.15.1.
4822 * configure: Re-generate.
4823 * config.in: Re-generate.
4824 * aclocal.m4: Re-generate.
4825 * gnulib/aclocal.m4: Re-generate.
4826 * gnulib/config.in: Re-generate.
4827 * gnulib/configure: Re-generate.
4828 * gnulib/import/Makefile.in: Re-generate.
4829
4830 2018-06-19 Pedro Alves <palves@redhat.com>
4831
4832 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
4833 (lookup_minimal_symbol_by_pc_section): ... here with
4834 gdb_assert_not_reached added.
4835
4836 2018-06-19 Pedro Alves <palves@redhat.com>
4837
4838 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
4839 parameter with a block parameter. Compare location's block symbol
4840 with the frame's block instead of addresses.
4841 (skip_inline_frames): Pass the current block instead of the
4842 frame's address. Break out as soon as we determine the frame
4843 should not be skipped.
4844
4845 2018-06-18 Tom Tromey <tom@tromey.com>
4846
4847 * solib-aix.c (solib_aix_get_section_offsets): Return
4848 unique_xmalloc_ptr.
4849 (solib_aix_solib_create_inferior_hook): Update.
4850
4851 2018-06-18 Tom Tromey <tom@tromey.com>
4852
4853 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
4854
4855 2018-06-18 Tom Tromey <tom@tromey.com>
4856
4857 * solib-frv.c (frv_relocate_main_executable): Use
4858 unique_xmalloc_ptr.
4859 * solib-dsbt.c (dsbt_relocate_main_executable): Use
4860 unique_xmalloc_ptr.
4861
4862 2018-06-18 Tom Tromey <tom@tromey.com>
4863
4864 * objfiles.h (inhibit_section_map_updates): Update.
4865 (resume_section_map_updates, resume_section_map_updates_cleanup):
4866 Remove.
4867 * solib-svr4.c (svr4_handle_solib_event): Update.
4868 * objfiles.c (inhibit_section_map_updates): Return
4869 scoped_restore_tmpl<int>.
4870 (resume_section_map_updates, resume_section_map_updates_cleanup):
4871 Remove.
4872
4873 2018-06-18 Tom Tromey <tom@tromey.com>
4874
4875 * valprint.h (read_string): Update.
4876 * valprint.c (read_string): Change type of "buffer".
4877 (val_print_string): Update.
4878 * python/py-value.c (valpy_string): Update.
4879 * language.h (struct language_defn) <la_get_string>: Change
4880 type of "buffer".
4881 (default_get_string, c_get_string): Update.
4882 * language.c (default_get_string): Change type of "buffer".
4883 * guile/scm-value.c (gdbscm_value_to_string): Update.
4884 * c-lang.c (c_get_string): Change type of "buffer".
4885
4886 2018-06-18 Tom Tromey <tom@tromey.com>
4887
4888 * ser-mingw.c (struct pipe_state_destroyer): New.
4889 (pipe_state_up): New typedef.
4890 (cleanup_pipe_state): Remove.
4891 (pipe_windows_open): Use pipe_state_up. Don't release argv.
4892
4893 2018-06-18 Tom Tromey <tom@tromey.com>
4894
4895 * rust-lang.h (rust_yyerror): Don't declare.
4896 * rust-lang.c (rust_language_defn): Update.
4897 * rust-exp.y (yyerror): Now static.
4898 * parse.c (parse_exp_in_context_1): Update.
4899 * p-lang.h (p_yyerror): Don't declare.
4900 * p-lang.c (p_language_defn): Update.
4901 * p-exp.y (yyerror): Now static.
4902 * opencl-lang.c (opencl_language_defn): Update.
4903 * objc-lang.c (objc_language_defn): Update.
4904 * m2-lang.h (m2_yyerror): Don't declare.
4905 * m2-lang.c (m2_language_defn): Update.
4906 * m2-exp.y (yyerror): Now static.
4907 * language.h (struct language_defn) <la_error>: Remove.
4908 * language.c (unk_lang_error): Remove.
4909 (unknown_language_defn, auto_language_defn): Remove.
4910 * go-lang.h (go_yyerror): Don't declare.
4911 * go-lang.c (go_language_defn): Update.
4912 * go-exp.y (yyerror): Now static.
4913 * f-lang.h (f_yyerror): Don't declare.
4914 * f-lang.c (f_language_defn): Update.
4915 * f-exp.y (yyerror): Now static.
4916 * d-lang.h (d_yyerror): Don't declare.
4917 * d-lang.c (d_language_defn): Update.
4918 * d-exp.y (yyerror): Now static.
4919 * c-lang.h (c_yyerror): Don't declare.
4920 * c-lang.c (c_language_defn, cplus_language_defn)
4921 (asm_language_defn, minimal_language_defn): Update.
4922 * c-exp.y (yyerror): Now static.
4923 * ada-lang.h (ada_yyerror): Don't declare.
4924 * ada-lang.c (ada_language_defn): Update.
4925 * ada-exp.y (yyerror): Now static.
4926
4927 2018-06-18 Alan Hayward <alan.hayward@arm.com>
4928
4929 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
4930 (store_sveregs_to_thread): Likewise.
4931 (aarch64_linux_fetch_inferior_registers): Check for SVE.
4932 (aarch64_linux_store_inferior_registers): Likewise.
4933 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
4934 function.
4935 (aarch64_sve_regs_copy_to_regcache): Likewise.
4936 (aarch64_sve_regs_copy_from_regcache): Likewise.
4937 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
4938 declaration.
4939 (aarch64_sve_regs_copy_to_regcache): Likewise.
4940 (aarch64_sve_regs_copy_from_regcache): Likewise.
4941 (sve_context): Structure from Linux headers.
4942 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
4943 (SVE_SIG_ZREG_SIZE): Likewise.
4944 (SVE_SIG_PREG_SIZE): Likewise.
4945 (SVE_SIG_FFR_SIZE): Likewise.
4946 (SVE_SIG_REGS_OFFSET): Likewise.
4947 (SVE_SIG_ZREGS_OFFSET): Likewise.
4948 (SVE_SIG_ZREG_OFFSET): Likewise.
4949 (SVE_SIG_ZREGS_SIZE): Likewise.
4950 (SVE_SIG_PREGS_OFFSET): Likewise.
4951 (SVE_SIG_PREG_OFFSET): Likewise.
4952 (SVE_SIG_PREGS_SIZE): Likewise.
4953 (SVE_SIG_FFR_OFFSET): Likewise.
4954 (SVE_SIG_REGS_SIZE): Likewise.
4955 (SVE_SIG_CONTEXT_SIZE): Likewise.
4956 (SVE_PT_REGS_MASK): Likewise.
4957 (SVE_PT_REGS_FPSIMD): Likewise.
4958 (SVE_PT_REGS_SVE): Likewise.
4959 (SVE_PT_VL_INHERIT): Likewise.
4960 (SVE_PT_VL_ONEXEC): Likewise.
4961 (SVE_PT_REGS_OFFSET): Likewise.
4962 (SVE_PT_FPSIMD_OFFSET): Likewise.
4963 (SVE_PT_FPSIMD_SIZE): Likewise.
4964 (SVE_PT_SVE_ZREG_SIZE): Likewise.
4965 (SVE_PT_SVE_PREG_SIZE): Likewise.
4966 (SVE_PT_SVE_FFR_SIZE): Likewise.
4967 (SVE_PT_SVE_FPSR_SIZE): Likewise.
4968 (SVE_PT_SVE_FPCR_SIZE): Likewise.
4969 (__SVE_SIG_TO_PT): Likewise.
4970 (SVE_PT_SVE_OFFSET): Likewise.
4971 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
4972 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
4973 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
4974 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
4975 (SVE_PT_SVE_PREG_OFFSET): Likewise.
4976 (SVE_PT_SVE_PREGS_SIZE): Likewise.
4977 (SVE_PT_SVE_FFR_OFFSET): Likewise.
4978 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
4979 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
4980 (SVE_PT_SVE_SIZE): Likewise.
4981 (SVE_PT_SIZE): Likewise.
4982 (HAS_SVE_STATE): New define.
4983
4984 2018-06-18 Alan Hayward <alan.hayward@arm.com>
4985
4986 * nat/aarch64-sve-linux-sigcontext.h: New file.
4987 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
4988 new files.
4989 (SVE_VQ_MIN): Likewise.
4990 (SVE_VQ_MAX): Likewise.
4991 (SVE_VL_MIN): Likewise.
4992 (SVE_VL_MAX): Likewise.
4993 (SVE_NUM_ZREGS): Likewise.
4994 (SVE_NUM_PREGS): Likewise.
4995 (sve_vl_valid): Likewise.
4996 (struct user_sve_header): Likewise.
4997
4998 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
4999 Richard Bunt <Richard.Bunt@arm.com>
5000
5001 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
5002 was requested by GDB.
5003
5004 2018-06-15 Tom de Vries <tdevries@suse.de>
5005
5006 * MAINTAINERS (Write After Approval): Add Tom de Vries.
5007
5008 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
5009
5010 * gnulib/update-gnulib.sh: Print expected versions of
5011 autoconf/aclocal.
5012
5013 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
5014
5015 * arch-utils.c (default_type_align): Use type_length_units.
5016 * gdbtypes.c (type_align): Use type_length_units.
5017
5018 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5019
5020 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
5021 of 'define' command.
5022
5023 2018-06-14 Tom de Vries <tdevries@suse.de>
5024
5025 PR cli/22573
5026 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
5027 get_no_prettyformat_print_options.
5028
5029 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
5030
5031 * sparc-nat.h: Include target.h.
5032 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
5033 <fetch_registers>: Remove this argument in function call.
5034 <store_registers>: Remove this argument in function call, remove
5035 extra semicolon.
5036 <low_forget_process>: Call sparc64_forget_process instead of
5037 sparc_forget_process.
5038
5039 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5040
5041 * procfs.c (_initialize_procfs): Use add_inf_child_target.
5042 (procfs_target::make_corefile_notes): Adjust to new
5043 target_read_alloc return type.
5044
5045 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5046 Stephen Roberts <stephen.roberts@arm.com>
5047
5048 PR gdb/22882
5049 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
5050 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
5051 Move should_notify_stop local into more inner scope.
5052
5053 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5054 Stephen Roberts <stephen.roberts@arm.com>
5055
5056 PR gdb/22882
5057 * infrun.c (resume_1): Add call to mark_async_event_handler.
5058
5059 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5060
5061 * infrun.c (do_target_wait): Change old version of $pc printed.
5062
5063 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
5064
5065 * dwarf2read.c (read_index_from_section): Rename to...
5066 (read_gdb_index_from_section): ... this, update all callers.
5067 (dwarf2_read_index): Rename to...
5068 (dwarf2_read_gdb_index): ... this, update all callers.
5069
5070 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
5071
5072 * gdb/hppa-linux-nat.c
5073 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
5074 hppa_linux_nat_target::fetch_registers.
5075
5076 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5077
5078 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
5079 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
5080 (AARCH64_DWARF_SVE_FFR): Likewise.
5081 (AARCH64_DWARF_SVE_P0): Likewise.
5082 (AARCH64_DWARF_SVE_Z0): Likewise.
5083
5084 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5085
5086 * common/common-regcache.h (raw_compare): New function.
5087 * regcache.c (regcache::raw_compare): Likewise.
5088 * regcache.h (regcache::raw_compare): New declaration.
5089
5090 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5091
5092 * common/common-regcache.h (reg_buffer_common): New structure.
5093 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
5094 (reg_buffer::raw_supply): Likewise.
5095 (reg_buffer::raw_supply_integer): Likewise.
5096 (reg_buffer::raw_supply_zeroed): Likewise.
5097 (reg_buffer::raw_collect): Likewise.
5098 (reg_buffer::raw_collect_integer): Likewise.
5099 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
5100 (reg_buffer::raw_supply): Likewise.
5101 (reg_buffer::raw_supply_integer): Likewise.
5102 (reg_buffer::raw_supply_zeroed): Likewise.
5103 (reg_buffer::raw_collect): Likewise.
5104 (reg_buffer::raw_collect_integer): Likewise.
5105
5106 2018-06-10 Tom Tromey <tom@tromey.com>
5107
5108 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
5109 (class remote_state) <stop_reply_queue>: Now std::vector.
5110 (remote_state::~remote_state)
5111 (remote_target::stop_reply_queue_length): Update.
5112 (struct queue_iter_param, remove_child_of_pending_fork)
5113 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
5114 (check_pending_event_prevents_wildcard_vcont_callback)
5115 (remove_stop_reply_for_inferior)
5116 (remove_stop_reply_of_remote_state)
5117 (remote_notif_remove_once_on_match)
5118 (stop_reply_match_ptid_and_ws)
5119 (remote_kill_child_of_pending_fork): Remove.
5120 (remote_target::remove_new_fork_children)
5121 (remote_target::check_pending_events_prevent_wildcard_vcont)
5122 (remote_target::discard_pending_stop_replies)
5123 (remote_target::discard_pending_stop_replies_in_queue)
5124 (remote_target::remote_notif_remove_queued_reply)
5125 (remote_target::queued_stop_reply)
5126 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
5127 (remote_target::wait, remote_target::kill_new_fork_children)
5128 (remote_target::async): Update.
5129
5130 2018-06-10 Tom Tromey <tom@tromey.com>
5131
5132 * record-full.c (record_full_arch_list_cleanups): Remove.
5133 (record_full_message): Use try/catch.
5134 (record_full_wait_cleanups): Remove.
5135 (record_full_wait_1): Use try/catch.
5136 (record_full_restore): Likewise.
5137
5138 2018-06-10 Tom Tromey <tom@tromey.com>
5139
5140 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
5141 declare VEC. Add constructor.
5142 <in_target_beneath>: Now bool.
5143 (record_full_breakpoints): Now a std::vector, static.
5144 (record_full_sync_record_breakpoints)
5145 (record_full_init_record_breakpoints)
5146 (record_full_target::insert_breakpoint)
5147 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
5148
5149 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
5150
5151 * dwarf2read.c (process_cu_includes): Remove struct keyword.
5152 * serial.c (serial_interface_lookup): Remove struct keyword.
5153
5154 2018-06-10 Tom Tromey <tom@tromey.com>
5155
5156 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
5157 method.
5158 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
5159 a method.
5160 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
5161 method.
5162 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
5163 "beneath" as a method.
5164 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
5165 Use "beneath" as a method.
5166
5167 2018-06-10 Tom Tromey <tom@tromey.com>
5168
5169 * tracefile.c (struct trace_file_writer_deleter): New.
5170 <operator()>: Rename from trace_file_writer_xfree.
5171 (trace_file_writer_up): New typedef.
5172 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
5173
5174 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5175
5176 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
5177 <m_registers, m_register_status>: Change type to
5178 std::unique_ptr.
5179 * regcache.c (reg_buffer::reg_buffer): Use new instead of
5180 XCNEWVEC.
5181
5182 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5183
5184 * common/common-regcache.h (enum register_status): Add
5185 underlying type "signed char".
5186 * regcache.h (reg_buffer) <m_register_status>: Change type to
5187 register_status *.
5188 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
5189 register_status instead of signed char.
5190 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
5191 (reg_buffer::get_register_status): Remove cast.
5192 (readable_regcache::raw_read): Remove cast.
5193 (readable_regcache::cooked_read): Remove cast.
5194
5195 2018-06-09 Tom Tromey <tom@tromey.com>
5196
5197 * source.c (reverse_search_command, forward_search_command): Use
5198 scoped_fd.
5199
5200 2018-06-09 Tom Tromey <tom@tromey.com>
5201
5202 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
5203 (serial_ops_list): Now static, std::vector.
5204 (serial_interface_lookup, serial_add_interface): Update.
5205
5206 2018-06-09 Tom Tromey <tom@tromey.com>
5207
5208 * dwarf2read.c (process_cu_includes): Update.
5209 (process_full_comp_unit): Update.
5210 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
5211 std::vector.
5212
5213 2018-06-08 Paul Koning <paul_koning@dell.com>
5214
5215 PR gdb/23252
5216
5217 * python/python.c (do_start_initialization):
5218 Avoid call to internal Python API.
5219 (init__gdb_module): New function.
5220
5221 2018-06-08 Gary Benson <gbenson@redhat.com>
5222
5223 * linux-thread-db.c (valprint.h): New include.
5224 (struct check_thread_db_info): New structure.
5225 (check_thread_db_on_load, tdb_testinfo): New static globals.
5226 (check_thread_db, check_thread_db_callback): New functions.
5227 (try_thread_db_load_1): Run integrity checks if requested.
5228 (maintenance_check_libthread_db): New function.
5229 (_initialize_thread_db): Register "maint check libthread-db"
5230 and "maint set/show check-libthread-db".
5231 * NEWS: Mention the above new commands.
5232
5233 2018-06-08 Tom Tromey <tom@tromey.com>
5234
5235 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
5236 now a method.
5237
5238 2018-06-08 Tom Tromey <tom@tromey.com>
5239
5240 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
5241
5242 2018-06-08 Tom Tromey <tom@tromey.com>
5243
5244 * common/btrace-common.h (struct btrace_data): Add constructor,
5245 destructor, move assignment operator.
5246 <empty, clear, fini>: New methods.
5247 <format>: Initialize.
5248 (btrace_data_init, btrace_data_fini, btrace_data_clear)
5249 (btrace_data_empty): Don't declare.
5250 * common/btrace-common.c (btrace_data_init): Remove.
5251 (btrace_data::fini): Rename from btrace_data_fini.
5252 (btrace_data::empty): Rename from btrace_data_empty.
5253 (btrace_data::clear): Rename from btrace_data_clear. Return
5254 bool.
5255 * btrace.h (make_cleanup_btrace_data): Don't declare.
5256 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
5257 (parse_xml_btrace): Update.
5258 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
5259 (maint_btrace_clear_packet_history_cmd): Update.
5260
5261 2018-06-07 Pedro Alves <palves@redhat.com>
5262
5263 * target.h (target_ops) <beneath>: Now a method. All references
5264 updated.
5265 (class target_stack): New.
5266 * target.c (g_target_stack): New.
5267 (g_current_top_target): Delete.
5268 (current_top_target): Get the top target out of g_target_stack.
5269 (target_stack::push, target_stack::unpush): New.
5270 (push_target, unpush_target): Reimplement.
5271 (target_is_pushed): Reimplement in terms of g_target_stack.
5272 (target_ops::beneath, target_stack::find_beneath): New.
5273
5274 2018-06-07 Pedro Alves <palves@redhat.com>
5275
5276 * target.h (find_target_beneath): Delete declaration.
5277 * target.c (find_target_beneath): Delete definition.
5278 * aix-thread.c: All callers of find_target_beneath adjusted to
5279 call target_ops::beneath instead.
5280 * bsd-uthread.c: Likewise.
5281 * linux-thread-db.c: Likewise.
5282 * ravenscar-thread.c: Likewise.
5283 * sol-thread.c: Likewise.
5284 * spu-multiarch.c: Likewise.
5285
5286 2018-06-07 Pedro Alves <palves@redhat.com>
5287
5288 * target.h (target_ops) <beneath>: Now a method. All references
5289 updated.
5290 (target_ops) <m_beneath>: New.
5291 * target.c (target_ops::beneath): New.
5292 * corelow.c: Adjust all references to target_ops::beneath.
5293 * linux-thread-db.c: Likewise.
5294 * make-target-delegates: Likewise.
5295 * record-btrace.c: Likewise.
5296 * record-full.c: Likewise.
5297 * remote.c: Likewise.
5298 * target.c: Likewise.
5299 * target-delegates.c: Regenerate.
5300
5301 2018-06-07 Pedro Alves <palves@redhat.com>
5302
5303 * target.h (target_stack): Delete.
5304 (current_top_target): Declare function.
5305 * target.c (target_stack): Delete.
5306 (g_current_top_target): New.
5307 (current_top_target): New function.
5308 * auxv.c: Use current_top_target instead of target_stack
5309 throughout.
5310 * avr-tdep.c: Likewise.
5311 * breakpoint.c: Likewise.
5312 * corefile.c: Likewise.
5313 * elfread.c: Likewise.
5314 * eval.c: Likewise.
5315 * exceptions.c: Likewise.
5316 * frame.c: Likewise.
5317 * gdbarch-selftests.c: Likewise.
5318 * gnu-v3-abi.c: Likewise.
5319 * ia64-tdep.c: Likewise.
5320 * ia64-vms-tdep.c: Likewise.
5321 * infcall.c: Likewise.
5322 * infcmd.c: Likewise.
5323 * infrun.c: Likewise.
5324 * linespec.c: Likewise.
5325 * linux-tdep.c: Likewise.
5326 * minsyms.c: Likewise.
5327 * ppc-linux-nat.c: Likewise.
5328 * ppc-linux-tdep.c: Likewise.
5329 * procfs.c: Likewise.
5330 * regcache.c: Likewise.
5331 * remote.c: Likewise.
5332 * rs6000-tdep.c: Likewise.
5333 * s390-linux-nat.c: Likewise.
5334 * s390-tdep.c: Likewise.
5335 * solib-aix.c: Likewise.
5336 * solib-darwin.c: Likewise.
5337 * solib-dsbt.c: Likewise.
5338 * solib-spu.c: Likewise.
5339 * solib-svr4.c: Likewise.
5340 * solib-target.c: Likewise.
5341 * sparc-tdep.c: Likewise.
5342 * sparc64-tdep.c: Likewise.
5343 * spu-tdep.c: Likewise.
5344 * symfile.c: Likewise.
5345 * symtab.c: Likewise.
5346 * target-descriptions.c: Likewise.
5347 * target-memory.c: Likewise.
5348 * target.c: Likewise.
5349 * target.h: Likewise.
5350 * tracefile-tfile.c: Likewise.
5351 * tracepoint.c: Likewise.
5352 * valops.c: Likewise.
5353 * valprint.c: Likewise.
5354 * value.c: Likewise.
5355 * windows-tdep.c: Likewise.
5356 * mi/mi-main.c: Likewise.
5357
5358 2018-06-07 Tom Tromey <tom@tromey.com>
5359
5360 * valprint.h (build_address_symbolic): Declare.
5361 * printcmd.c (print_address_symbolic): Update.
5362 (build_address_symbolic): Change "name" and "filename" to
5363 std::string.
5364 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
5365 Update.
5366 * defs.h (build_address_symbolic): Remove declaration.
5367
5368 2018-06-07 Alan Hayward <alan.hayward@arm.com>
5369
5370 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
5371 (aarch64_vnv_type): Add function.
5372 (aarch64_pseudo_register_name): Add V regs for SVE.
5373 (aarch64_pseudo_register_type): Likewise.
5374 (aarch64_pseudo_register_reggroup_p): Likewise.
5375 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
5376 (aarch64_pseudo_read_value): Add V regs for SVE.
5377 (aarch64_pseudo_write_2): Use V0 offset for SVE
5378 (aarch64_pseudo_write): Add V regs for SVE.
5379 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
5380
5381 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
5382
5383 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
5384 (sve_vl_from_vq): Likewise.
5385
5386 2018-06-05 Tom Tromey <tom@tromey.com>
5387
5388 * cli/cli-cmds.c (show_version): Update.
5389 * top.c (print_gdb_version): Add "interactive" parameter.
5390 Update.
5391 * main.c (captured_main_1): Update.
5392 * top.h (print_gdb_version): Add "interactive" parameter and a
5393 comment.
5394
5395 2018-06-05 David Malcolm <dmalcolm@redhat.com>
5396
5397 * common/enum-flags.h: Add trailing semicolon to example in
5398 comment.
5399
5400 2018-06-05 Tom Tromey <tom@tromey.com>
5401
5402 PR cli/12326:
5403 * NEWS: Add entry about pager.
5404 * utils.c (pagination_disabled_for_command): New global.
5405 (prompt_for_continue): Allow "c" response to prompt.
5406 (reinitialize_more_filter): Clear
5407 pagination_disabled_for_command.
5408 (fputs_maybe_filtered): Check pagination_disabled_for_command.
5409
5410 2018-06-04 Tom Tromey <tom@tromey.com>
5411
5412 * ada-lang.h (ada_lookup_symbol_list): Update.
5413 * ada-lang.c (resolve_subexp): Update.
5414 (symbols_are_identical_enums): Change type of syms. Remove nsyms
5415 parameter.
5416 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
5417 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
5418 results parameter to std::vector.
5419 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
5420 Update.
5421 * ada-exp.y (block_lookup): Update.
5422 (select_possible_type_sym): Change type of syms. Remove nsyms
5423 parameter.
5424 (write_var_or_type, write_name_assoc): Update.
5425
5426 2018-06-04 Joel Brobecker <brobecker@adacore.com>
5427
5428 * windows-nat.c (windows_nat_target::xfer_partial): Return
5429 TARGET_XFER_E_IO if we need to delegate to the target beneath
5430 but BENEATH is NULL.
5431
5432 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
5433
5434 * Makefile.in (config.status): Add configure.nat as a
5435 dependency.
5436
5437 2018-06-04 Tom Tromey <tom@tromey.com>
5438
5439 * cp-name-parser.y (cpname_state): Add method declarations.
5440 (HANDLE_QUAL): Update.
5441 (cpname_state::d_grab, cpname_state::fill_comp)
5442 (cpname_state::make_operator, cpname_state::make_dtor)
5443 (cpname_state::make_builtin_type, cpname_state::make_name)
5444 (cpname_state::d_qualify, cpname_state::d_int_type)
5445 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
5446 (%union): Move earlier.
5447
5448 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5449
5450 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
5451
5452 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5453
5454 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
5455 (aarch64_pseudo_write_1): Likewise.
5456 (aarch64_pseudo_read_value): Use helper.
5457 (aarch64_pseudo_write): Likewise.
5458
5459 2018-06-04 Pedro Alves <palves@redhat.com>
5460
5461 * darwin-nat.c (darwin_ops): Delete.
5462 (darwin_attach_pid): Use get_native_target.
5463
5464 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5465
5466 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
5467 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
5468
5469 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5470
5471 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
5472 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
5473 (aarch64_gdbarch_init): Check for SVE.
5474 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
5475
5476 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5477
5478 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
5479 * aarch64-tdep.h (aarch64_read_description): Likewise.
5480 * arch/aarch64.c (aarch64_create_target_description): Likewise.
5481 * arch/aarch64.h (aarch64_create_target_description): Likewise.
5482 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
5483 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
5484 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
5485
5486 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
5487
5488 * value.c (value_fetch_lazy_bitfield): New.
5489 (value_fetch_lazy_memory): New.
5490 (value_fetch_lazy_register): New.
5491 (value_fetch_lazy): Factor out to smaller functions.
5492
5493 2018-06-01 Tom Tromey <tom@tromey.com>
5494
5495 * cp-name-parser.y (backslashable, represented): Now const.
5496
5497 2018-06-01 Tom Tromey <tom@tromey.com>
5498
5499 * cp-name-parser.y: Include parser-defs.h.
5500 (parser_fprintf): Remove declaration.
5501
5502 2018-06-01 Tom Tromey <tom@tromey.com>
5503
5504 * cp-name-parser.y: Use %pure-parser, %lex-param, and
5505 %parse-param.
5506 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
5507 (global_result): Remove globals.
5508 (struct cpname_state): New.
5509 (yyparse): Don't declare.
5510 (yylex, yyerror): Move declarations after %union.
5511 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
5512 (make_name): Add state parameter.
5513 Update all callers.
5514 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
5515 parameter.
5516 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
5517 Update.
5518 (yylex): Add lvalp, state parameters.
5519 (yyerror): Add state parameter.
5520 (cp_demangled_name_to_comp): Update.
5521
5522 2018-06-01 Tom Tromey <tom@tromey.com>
5523
5524 * cp-name-parser.y (parser_fprintf): Declare.
5525 (GDB_YY_REMAP_PREFIX): Define.
5526 Include yy-remap.h. Don't redefine yy* identifiers.
5527
5528 2018-06-01 Tom Tromey <tom@tromey.com>
5529
5530 * python/py-type.c (typy_legacy_template_argument): Update.
5531 * cp-support.h (cp_demangled_name_to_comp): Update.
5532 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
5533 parameter to be a "std::string *".
5534 (main): Update.
5535
5536 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
5537
5538 * ada-lex.l: Include "diagnostics.h" instead of
5539 "common/diagnostics.h".
5540 * unittests/environ-selftests.c: Likewise.
5541 * common/diagnostics.h: Moved to ../include.
5542
5543 2018-06-01 Joel Brobecker <brobecker@adacore.com>
5544
5545 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
5546 to language_mode_manual while calling breakpoint_re_set_one.
5547
5548 2018-06-01 Tom Tromey <tom@tromey.com>
5549
5550 * valops.c (value_cast_structs, destructor_name_p): Update.
5551 * symtab.c (gdb_mangle_name): Update.
5552 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
5553 Update.
5554 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
5555 (pascal_object_print_value_fields, pascal_object_print_value):
5556 Update.
5557 * p-typeprint.c (pascal_type_print_derivation_info): Update.
5558 * linespec.c (find_methods): Update.
5559 * gdbtypes.h (type_name_no_tag): Remove.
5560 (type_name_or_error): Rename from type_name_no_tag_or_error.
5561 * gdbtypes.c (type_name_no_tag): Remove.
5562 (type_name_or_error): Rename from type_name_no_tag_or_error.
5563 (lookup_struct_elt_type, check_typedef): Update.
5564 * expprint.c (print_subexp_standard): Update.
5565 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
5566 * d-namespace.c (d_lookup_nested_symbol): Update.
5567 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
5568 (cp_print_class_member): Update.
5569 * cp-namespace.c (cp_lookup_nested_symbol): Update.
5570 * completer.c (add_struct_fields): Update.
5571 * c-typeprint.c (cp_type_print_derivation_info)
5572 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
5573 Update.
5574 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
5575 (ada_prefer_type, ada_is_exception_sym): Update.
5576
5577 2018-06-01 Tom Tromey <tom@tromey.com>
5578
5579 * valops.c (enum_constant_from_type, value_namespace_elt)
5580 (value_maybe_namespace_elt): Update.
5581 * valarith.c (find_size_for_pointer_math): Update.
5582 * target-descriptions.c (make_gdb_type): Update.
5583 * symmisc.c (print_symbol): Update.
5584 * stabsread.c (define_symbol, read_type)
5585 (complain_about_struct_wipeout, add_undefined_type)
5586 (cleanup_undefined_types_1): Update.
5587 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
5588 (rust_range_type_p, val_print_struct, rust_print_struct_def)
5589 (rust_internal_print_type, rust_composite_type)
5590 (rust_evaluate_funcall, rust_evaluate_subexp)
5591 (rust_inclusive_range_type_p): Update.
5592 * python/py-type.c (typy_get_tag): Update.
5593 * p-typeprint.c (pascal_type_print_base): Update.
5594 * mdebugread.c (parse_symbol, parse_type): Update.
5595 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
5596 Update.
5597 * guile/scm-type.c (gdbscm_type_tag): Update.
5598 * go-lang.c (sixg_string_p): Update.
5599 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
5600 Update.
5601 * gdbtypes.h (struct main_type) <tag_name>: Remove.
5602 (TYPE_TAG_NAME): Remove.
5603 * gdbtypes.c (type_name_no_tag): Simplify.
5604 (check_typedef, check_types_equal, recursive_dump_type)
5605 (copy_type_recursive, arch_composite_type): Update.
5606 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
5607 in summary mode when needed.
5608 * eval.c (evaluate_funcall): Update.
5609 * dwarf2read.c (fixup_go_packaging, read_structure_type)
5610 (process_structure_scope, read_enumeration_type)
5611 (read_namespace_type, read_module_type, determine_prefix): Update.
5612 * cp-support.c (inspect_type): Update.
5613 * coffread.c (process_coff_symbol, decode_base_type): Update.
5614 * c-varobj.c (c_is_path_expr_parent): Update.
5615 * c-typeprint.c (c_type_print_base_struct_union): Update.
5616 (c_type_print_base_1): Update. Print struct/class/union/enum in
5617 summary when using C language.
5618 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
5619 (gen_maybe_namespace_elt): Update.
5620 * ada-lang.c (ada_type_name): Simplify.
5621 (empty_record, ada_template_to_fixed_record_type_1)
5622 (template_to_static_fixed_type)
5623 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
5624
5625 2018-06-01 Tom Tromey <tom@tromey.com>
5626
5627 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
5628 c_print_type.
5629 * c-typeprint.c (c_print_type_1): Add "language" parameter.
5630 (c_print_type): Update.
5631 (c_print_type): New overload.
5632 (c_type_print_varspec_prefix, c_type_print_args)
5633 (c_type_print_varspec_suffix, c_print_type_no_offsets)
5634 (c_type_print_base_struct_union, c_type_print_base_1)
5635 (cp_type_print_method_args): Add "language" parameter.
5636 (c_type_print_base): Update.
5637 * c-lang.h (c_print_type): Add new overload.
5638
5639 2018-06-01 Tom Tromey <tom@tromey.com>
5640
5641 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
5642 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
5643
5644 2018-06-01 Alan Hayward <alan.hayward@arm.com>
5645
5646 * aarch64-tdep.c (aarch64_sve_register_names): New const
5647 var.
5648 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
5649 (AARCH64_SVE_Z_REGS_NUM): New define.
5650 (AARCH64_SVE_P_REGS_NUM): Likewise.
5651 (AARCH64_SVE_NUM_REGS): Likewise.
5652
5653 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
5654
5655 * nat/linux-ptrace.h [__alpha__]
5656 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
5657 definitions.
5658
5659 2018-05-31 Maciej W. Rozycki <macro@mips.com>
5660
5661 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
5662 the endianness selected.
5663 * NEWS: Document `set endian auto' mode operation update.
5664
5665 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5666
5667 * Makefile.in: Add new header.
5668 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
5669 (sve_vl_from_vg): Likewise.
5670 (sve_vq_from_vl): Likewise.
5671 (sve_vl_from_vq): Likewise.
5672 (sve_vq_from_vg): Likewise.
5673 (sve_vg_from_vq): Likewise.
5674 * configure.nat: Add new c file.
5675 * nat/aarch64-sve-linux-ptrace.c: New file.
5676 * nat/aarch64-sve-linux-ptrace.h: New file.
5677
5678 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5679
5680 * aarch64-linux-nat.c (aarch64_linux_read_description):
5681 Add parmeter zero.
5682 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
5683 Likewise.
5684 * aarch64-tdep.c (tdesc_aarch64_list): Add.
5685 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
5686 (aarch64_gdbarch_init): Add parmeter zero.
5687 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
5688 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
5689 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
5690 parmeter.
5691 * doc/gdb.texinfo: Describe SVE feature
5692 * features/aarch64-sve.c: New file.
5693
5694 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
5695
5696 PR gdb/23210
5697 * gdbarch.sh (significant_addr_bit): Default to zero when
5698 not set by target architecture.
5699 * gdbarch.c: Re-generated.
5700 * utils.c (address_significant): Update.
5701
5702 2018-05-30 Joel Brobecker <brobecker@adacore.com>
5703
5704 * stack.c (func_command): Remove trailing newline in call to error.
5705
5706 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5707
5708 * regcache.h (regcache_raw_collect): Remove, update callers to
5709 use regcache::raw_collect.
5710 * regcache.c (regcache_raw_collect): Remove.
5711
5712 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5713
5714 * regcache.h (regcache_raw_supply): Remove, update callers to
5715 use detached_regcache::raw_supply.
5716 * regcache.c (regcache_raw_supply): Remove.
5717
5718 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5719
5720 * regcache.h (regcache_cooked_write_part): Remove, update
5721 callers to use regcache::cooked_write_part.
5722 * regcache.c (regcache_cooked_write_part): Remove.
5723
5724 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5725
5726 * regcache.h (regcache_cooked_read_part): Remove, update callers
5727 to use readable_regcache::cooked_read_part.
5728 * regcache.c (regcache_cooked_read_part): Remove.
5729
5730 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5731
5732 * regcache.h (regcache_cooked_read_value): Remove, update
5733 callers to use readable_regcache::cooked_read_value.
5734 * regcache.c (regcache_cooked_read_value): Remove.
5735
5736 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5737
5738 * regcache.h (regcache_cooked_write): Remove, update callers to
5739 use regcache::cooked_write.
5740 * regcache.c (regcache_cooked_write): Remove.
5741
5742 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5743
5744 * regcache.h (regcache_invalidate): Remove, update callers to
5745 use detached_regcache::invalidate instead.
5746 * regcache.c (regcache_invalidate): Remove.
5747
5748 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5749
5750 * regcache.h (regcache_raw_write_part): Remove, update callers
5751 to use regcache::raw_write_part instead.
5752 * regcache.c (regcache_raw_write_part): Remove.
5753
5754 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5755
5756 * regcache.h (regcache_raw_read_part): Remove, update callers to
5757 use readable_regcache::raw_read_part instead.
5758 * regcache.c (regcache_raw_read_part): Remove.
5759
5760 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5761
5762 * regcache.h (regcache_cooked_read): Remove, update callers to
5763 use readable_regcache::cooked_read instead.
5764 * regcache.c (regcache_cooked_read): Remove.
5765
5766 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5767
5768 * regcache.h (regcache_raw_write): Remove, update callers to use
5769 regcache::raw_write instead.
5770 * regcache.c (regcache_raw_write): Remove.
5771
5772 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5773
5774 * regcache.h (regcache_raw_read): Remove, update callers to use
5775 readable_regcache::raw_read instead.
5776 * regcache.c (regcache_raw_read): Remove.
5777
5778 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5779
5780 * regcache.h (regcache_raw_update): Remove, update callers to
5781 use readable_regcache::raw_update instead.
5782 * regcache.c (regcache_raw_update): Remove.
5783
5784 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5785
5786 * regcache.h (regcache_register_status): Remove, update callers
5787 to use reg_buffer::get_register_status directly instead.
5788 * regcache.c (regcache_register_status): Remove.
5789
5790 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5791
5792 * regcache.h (regcache_get_ptid): Remove, update all callers to
5793 call regcache::ptid instead.
5794 * regcache.c (regcache_get_ptid): Remove.
5795
5796 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5797
5798 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
5799
5800 2018-05-30 Pedro Alves <palves@redhat.com>
5801
5802 * common/common-exceptions.h (exception_rethrow): Use
5803 ATTRIBUTE_NORETURN.
5804
5805 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
5806
5807 * breakpoint.c (print_solib_event, check_status_catch_solib):
5808 Remove struct keyword in range-based for loops.
5809 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
5810 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
5811 Likewise.
5812 * linespec.c (find_superclass_methods, search_minsyms_for_name):
5813 Likewise.
5814 * symfile.c (addr_info_make_relative): Likewise.
5815 * thread.c (value_in_thread_stack_temporaries): Likewise.
5816
5817 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
5818
5819 PR gdb/16841
5820 * valops.c (value_struct_elt_for_reference): Call check_typedef on
5821 aggregate type to get its real type before accessing it.
5822
5823 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
5824
5825 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
5826 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
5827 * coff-pe-read.c (add_pe_forwarded_sym): Replace
5828 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
5829 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
5830 * jit.c (jit_breakpoint_re_set_internal): Likewise.
5831 * printcmd.c (info_address_command): Likewise.
5832
5833 2018-05-29 Tom Tromey <tom@tromey.com>
5834
5835 * windows-nat.c (handle_exception): Update fall-through comment.
5836
5837 2018-05-29 Tom Tromey <tom@tromey.com>
5838
5839 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
5840 (struct program_space) <added_solibs>: Now a std::vector.
5841 * breakpoint.c (print_solib_event): Update.
5842 (check_status_catch_solib): Update.
5843 * progspace.c (clear_program_space_solib_cache): Update.
5844 * solib.c (update_solib_list): Update.
5845
5846 2018-05-29 Tom Tromey <tom@tromey.com>
5847
5848 * python/py-type.c (typy_richcompare): Update.
5849 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
5850 * gdbtypes.h (types_deeply_equal): Return bool.
5851 (types_equal): Likewise.
5852 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
5853 declare VEC.
5854 (check_types_equal): Change worklist to std::vector. Return
5855 bool.
5856 (struct type_equality_entry): Add constructor.
5857 (compare_maybe_null_strings): Return bool.
5858 (check_types_worklist): Return bool. Change worklist to
5859 std::vector.
5860 (types_deeply_equal): Use std::vector.
5861 (types_equal): Return bool.
5862 (compare_maybe_null_strings): Simplify.
5863
5864 2018-05-29 Tom Tromey <tom@tromey.com>
5865
5866 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
5867
5868 2018-05-29 Tom Tromey <tom@tromey.com>
5869
5870 * objc-lang.h: Don't include cp-support.h.
5871 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
5872 declare VEC.
5873
5874 2018-05-27 Tom Tromey <tom@tromey.com>
5875
5876 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
5877
5878 2018-05-25 Tom Tromey <tom@tromey.com>
5879
5880 * value.c (value::location): Initialize.
5881
5882 2018-05-25 Tom Tromey <tom@tromey.com>
5883
5884 * dbxread.c (init_bincl_list): Remove.
5885 (bincl_list): Now a std::vector.
5886 (bincls_allocated, next_bincl): Remove.
5887 (free_bincl_list, do_free_bincl_list_cleanup)
5888 (make_cleanup_free_bincl_list): Remove.
5889 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
5890 unique_xmalloc_ptr.
5891 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
5892 (struct header_file_location): Add constructor.
5893 (add_bincl_to_list): Remove.
5894
5895 2018-05-25 Tom Tromey <tom@tromey.com>
5896
5897 * tui/tui.c (tui_enable): Update.
5898 * mi/mi-interp.c (mi_interp::init): Update.
5899 * interps.h (class interp) <name>: New method.
5900 <m_name>: Rename from name.
5901 (~scoped_restore_interp): Update.
5902 * interps.c (interp::interp): Update.
5903 (interp_add, interp_set, interp_lookup_existing)
5904 (current_interp_named_p): Update.
5905
5906 2018-05-25 Tom Tromey <tom@tromey.com>
5907
5908 * interps.c (interp_name): Remove.
5909 * mi/mi-interp.c (mi_interp::init): Update.
5910 * interps.h (interp_name): Remove.
5911 (~scoped_restore_interp): Update.
5912 * tui/tui.c (tui_enable): Update.
5913
5914 2018-05-25 Tom Tromey <tom@tromey.com>
5915
5916 * utils.c (fputs_maybe_filtered): Update.
5917 * linespec.c (decode_line_full): Update.
5918 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
5919 (mi_print_breakpoint_for_event, mi_solib_loaded)
5920 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
5921 (mi_user_selected_context_changed): Update.
5922 * mi/mi-main.c (mi_execute_command): Update.
5923 * cli/cli-script.c (execute_control_command): Update.
5924 * python/python.c (execute_gdb_command): Update.
5925 * solib.c (info_sharedlibrary_command): Update.
5926 * interps.c (interp_ui_out): Remove.
5927 * interps.h (interp_ui_out): Remove.
5928
5929 2018-05-25 Tom Tromey <tom@tromey.com>
5930
5931 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
5932 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
5933 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
5934
5935 2018-05-25 Tom Tromey <tom@tromey.com>
5936
5937 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
5938 * interps.c (interp_exec): Use scoped_restore.
5939
5940 2018-05-25 Tom Tromey <tom@tromey.com>
5941
5942 * remote.c (remote_target::remote_file_get): Use
5943 gdb::byte_vector.
5944 (remote_target::remote_file_put): Likewise.
5945
5946 2018-05-25 Tom Tromey <tom@tromey.com>
5947
5948 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
5949 a std::string.
5950 (get_pe_section_index, add_pe_exported_sym): Update.
5951 (read_pe_exported_syms): Use gdb::def_vector.
5952
5953 2018-05-25 Tom Tromey <tom@tromey.com>
5954
5955 * frame.c (remove_prev_frame): Remove.
5956 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
5957
5958 2018-05-25 Maciej W. Rozycki <macro@mips.com>
5959
5960 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
5961 Remove prototypes.
5962 * mips-linux-nat.c (supply_fpregset): Always call
5963 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
5964 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
5965 `mips_fill_fpregset'.
5966 * mips-linux-tdep.c (mips_supply_fpregset)
5967 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
5968 (mips_fill_fpregset_wrapper): Remove functions.
5969 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
5970 (mips_linux_fpregset): Remove variable.
5971 (mips_linux_iterate_over_regset_sections): Use
5972 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
5973 (mips_linux_o32_sigframe_init): Remove comment.
5974
5975 2018-05-25 Pedro Alves <palves@redhat.com>
5976
5977 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
5978 (struct readahead_cache, struct packet_reg, struct
5979 remote_arch_state, class remote_state): Move higher up in the
5980 file.
5981 (remote_target::m_remote_state): Now an object instead of a pointer.
5982 (remote_target::get_remote_state): Adjust.
5983
5984 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
5985
5986 * stack.c (select_and_print_frame): Delete.
5987 (struct function_bounds): Move struct within function.
5988 (func_command): Most content moved into new function
5989 find_frame_for_function, use new function, print result, add
5990 function comment.
5991 (find_frame_for_function): New function, now returns a result.
5992
5993 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5994
5995 * stack.c (iterate_over_block_arg_vars): Fix comment.
5996 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
5997
5998 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
5999
6000 PR gdb/23203
6001 * frame.c
6002 (scoped_restore_selected_frame::scoped_restore_selected_frame):
6003 Define.
6004 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
6005 Define.
6006 * frame.h (class scoped_restore_selected_frame): New class.
6007 * stack.c (print_frame_local_vars): Remove catching and rethrowing
6008 of any exception, use scoped_restore_selected_frame to restore the
6009 frame instead.
6010
6011 2018-05-24 Pedro Alves <palves@redhat.com>
6012
6013 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
6014 override.
6015
6016 2018-05-23 Tom Tromey <tom@tromey.com>
6017
6018 * complaints.c (struct complaints): Remove.
6019 (symfile_complaint_book): Remove.
6020 (series): New global.
6021 (complaint_internal): Update.
6022 (clear_complaints): Update.
6023
6024 2018-05-23 Tom Tromey <tom@tromey.com>
6025
6026 * complaints.c (counters): New global.
6027 (struct complain): Remove.
6028 (struct complaints) <root>: Remove.
6029 (complaint_sentinel): Remove.
6030 (symfile_complaint_book): Update.
6031 (find_complaint) Remove.
6032 (complaint_internal, clear_complaints): Update.
6033
6034 2018-05-23 Tom Tromey <tom@tromey.com>
6035
6036 * complaints.c (struct complain) <file, line>: Remove.
6037 (find_complaint): Remove file, line parameters.
6038 (complaint_internal): Update.
6039
6040 2018-05-23 Tom Tromey <tom@tromey.com>
6041
6042 * complaints.c (vcomplaint): Remove.
6043 (complaint_internal) Merge in contents of vcomplaint.
6044
6045 2018-05-23 Tom Tromey <tom@tromey.com>
6046
6047 * complaints.c (struct complaints) <explanation>: Remove.
6048 (symfile_explanations): Remove.
6049 (symfile_complaint_book): Update.
6050 (vcomplaint): Update.
6051 (struct explanation): Remove.
6052
6053 2018-05-23 Tom Tromey <tom@tromey.com>
6054
6055 * complaints.c (symfile_complaints): Remove.
6056 (complaint_internal): Remove "complaints" parameter.
6057 (clear_complaints, vcomplaint): Remove "c" parameter.
6058 (get_complaints): Remove.
6059 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
6060 (dwarf2_debug_line_missing_file_complaint)
6061 (dwarf2_debug_line_missing_end_sequence_complaint)
6062 (dwarf2_complex_location_expr_complaint)
6063 (dwarf2_const_value_length_mismatch_complaint)
6064 (dwarf2_section_buffer_overflow_complaint)
6065 (dwarf2_macro_malformed_definition_complaint)
6066 (dwarf2_invalid_attrib_class_complaint)
6067 (create_addrmap_from_index, dw2_symtab_iter_next)
6068 (dw2_expand_marked_cus)
6069 (dw2_debug_names_iterator::find_vec_in_debug_names)
6070 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
6071 (create_debug_type_hash_table, init_cutu_and_read_dies)
6072 (partial_die_parent_scope, add_partial_enumeration)
6073 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
6074 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
6075 (read_import_statement, read_file_scope, create_dwo_cu_reader)
6076 (create_cus_hash_table, create_dwp_hash_table)
6077 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
6078 (dwarf2_rnglists_process, dwarf2_ranges_process)
6079 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
6080 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
6081 (handle_struct_member_die, process_structure_scope)
6082 (read_array_type, read_common_block, read_module_type)
6083 (read_tag_pointer_type, read_typedef, read_base_type)
6084 (read_subrange_type, load_partial_dies, partial_die_info::read)
6085 (partial_die_info::read, partial_die_info::read)
6086 (partial_die_info::read, read_checked_initial_length_and_offset)
6087 (dwarf2_string_attr, read_formatted_entries)
6088 (dwarf_decode_line_header)
6089 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
6090 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
6091 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
6092 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
6093 (get_signatured_type, get_DW_AT_signature_type)
6094 (decode_locdesc, file_file_name, consume_improper_spaces)
6095 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
6096 (dwarf_decode_macro_bytes, dwarf_decode_macros)
6097 (dwarf2_symbol_mark_computed, set_die_type)
6098 (read_attribute_value): Update.
6099 * stap-probe.c (handle_stap_probe, get_stap_base_address):
6100 Update.
6101 * dbxread.c (unknown_symtype_complaint)
6102 (lbrac_mismatch_complaint, repeated_header_complaint)
6103 (set_namestring, function_outside_compilation_unit_complaint)
6104 (read_dbx_symtab, process_one_symbol): Update.
6105 * gdbtypes.c (stub_noname_complaint): Update.
6106 * windows-nat.c (handle_unload_dll): Update.
6107 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
6108 (decode_base_type): Update.
6109 * xcoffread.c (bf_notfound_complaint, ef_complaint)
6110 (eb_complaint, record_include_begin, record_include_end)
6111 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
6112 (process_xcoff_symbol, read_symbol)
6113 (function_outside_compilation_unit_complaint)
6114 (scan_xcoff_symtab): Update.
6115 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
6116 * buildsym.c (finish_block_internal, make_blockvector)
6117 (end_symtab_get_static_block, augment_type_symtab): Update.
6118 * dtrace-probe.c (dtrace_process_dof)
6119 (dtrace_static_probe_ops::get_probes): Update.
6120 * complaints.h (struct complaint): Don't declare.
6121 (symfile_complaints): Remove.
6122 (complaint_internal): Remove "complaints" parameter.
6123 (complaint): Likewise.
6124 (clear_complaints): Likewise.
6125 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6126 (reread_symbols): Update.
6127 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
6128 (dwarf2_frame_cache, decode_frame_entry): Update.
6129 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
6130 * objc-lang.c (lookup_objc_class, lookup_child_selector)
6131 (info_selectors_command): Update.
6132 * macrotab.c (macro_include, check_for_redefinition)
6133 (macro_undef): Update.
6134 * objfiles.c (filter_overlapping_sections): Update.
6135 * stabsread.c (invalid_cpp_abbrev_complaint)
6136 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
6137 (define_symbol, error_type, read_type, rs6000_builtin_type)
6138 (stabs_method_name_from_physname, read_member_functions)
6139 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
6140 (attach_fields_to_type, complain_about_struct_wipeout)
6141 (read_range_type, read_args, common_block_start)
6142 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
6143 Update.
6144 * mdebugread.c (index_complaint, unknown_ext_complaint)
6145 (basic_type_complaint, bad_tag_guess_complaint)
6146 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
6147 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
6148 (parse_procedure, parse_lines)
6149 (function_outside_compilation_unit_complaint)
6150 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
6151 (bad_tag_guess_complaint, reg_value_complaint): Update.
6152 * cp-support.c (demangled_name_complaint): Update.
6153 * macroscope.c (sal_macro_scope): Update.
6154 * dwarf-index-write.c (class debug_names): Update.
6155
6156 2018-05-23 Tom Tromey <tom@tromey.com>
6157
6158 * complaints.c (clear_complaints): Remove "noisy" parameter.
6159 * complaints.h (clear_complaints): Update.
6160 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6161 (reread_symbols): Update.
6162
6163 2018-05-23 Tom Tromey <tom@tromey.com>
6164
6165 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
6166 SUBSEQUENT_MESSAGE.
6167 (vcomplaint, clear_complaints): Update.
6168 (symfile_explanations): Remove some messages.
6169
6170 2018-05-23 Tom Tromey <tom@tromey.com>
6171
6172 * complaints.c (internal_complaint): Remove.
6173 * complaints.h (internal_complaint): Remove.
6174
6175 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6176
6177 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
6178
6179 2018-05-22 Pedro Alves <palves@redhat.com>
6180
6181 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
6182 (remote_fileio_badfd, remote_fileio_return_errno)
6183 (remote_fileio_return_success, remote_fileio_func_open)
6184 (remote_fileio_func_open, remote_fileio_func_close)
6185 (remote_fileio_func_read, remote_fileio_func_write)
6186 (remote_fileio_func_lseek, remote_fileio_func_rename)
6187 (remote_fileio_func_unlink, remote_fileio_func_stat)
6188 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
6189 (remote_fileio_func_isatty, remote_fileio_func_system): Add
6190 remote_target parameter.
6191 (remote_fio_func_map) <func>: Add remote_target parameter.
6192 (do_remote_fileio_request, remote_fileio_request):
6193 * remote-fileio.h (remote_fileio_request):
6194 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
6195 remote_target parameter.
6196 (remote_notif_process, handle_notification): Adjust to pass down
6197 the remote.
6198 (remote_notif_state_allocate): Add remote_target parameter. Save
6199 it.
6200 * remote-notif.h (struct remote_target): Forward declare.
6201 (struct notif_client) <parse, ack, can_get_pending_events>: Add
6202 remote_target parameter.
6203 (struct remote_notif_state) <remote>: New field.
6204 (remote_notif_ack, remote_notif_parse): Add remote_target
6205 parameter.
6206 (remote_notif_state_allocate, remote_notif_state_allocate): Add
6207 remote_target parameter.
6208 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
6209 (threads_listing_context, rmt_thread_action, protocol_feature)
6210 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
6211 (packet_result, struct threads_listing_context, remote_state):
6212 Move definitions and declarations higher up.
6213 (remote_target) <~remote_target>: Declare.
6214 (remote_download_command_source, remote_file_put, remote_file_get)
6215 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
6216 (remote_hostio_pread_vFile, remote_hostio_send_command)
6217 (remote_hostio_set_filesystem, remote_hostio_open)
6218 (remote_hostio_close, remote_hostio_unlink, remote_state)
6219 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
6220 (get_memory_write_packet_size, get_memory_read_packet_size)
6221 (append_pending_thread_resumptions, remote_detach_1)
6222 (append_resumption, remote_resume_with_vcont)
6223 (add_current_inferior_and_thread, wait_ns, wait_as)
6224 (process_stop_reply, remote_notice_new_inferior)
6225 (process_initial_stop_replies, remote_add_thread)
6226 (btrace_sync_conf, remote_btrace_maybe_reopen)
6227 (remove_new_fork_children, kill_new_fork_children)
6228 (discard_pending_stop_replies, stop_reply_queue_length)
6229 (check_pending_events_prevent_wildcard_vcont)
6230 (discard_pending_stop_replies_in_queue, stop_reply)
6231 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
6232 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
6233 (remote_interrupt_as, remote_interrupt_ns)
6234 (remote_get_noisy_reply, remote_query_attached)
6235 (remote_add_inferior, remote_current_thread, get_current_thread)
6236 (set_thread, set_general_thread, set_continue_thread)
6237 (set_general_process, write_ptid)
6238 (remote_unpack_thread_info_response, remote_get_threadinfo)
6239 (parse_threadlist_response, remote_get_threadlist)
6240 (remote_threadlist_iterator, remote_get_threads_with_ql)
6241 (remote_get_threads_with_qxfer)
6242 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
6243 (get_offsets, remote_check_symbols, remote_supported_packet)
6244 (remote_query_supported, remote_packet_size)
6245 (remote_serial_quit_handler, remote_detach_pid)
6246 (remote_vcont_probe, remote_resume_with_hc)
6247 (send_interrupt_sequence, interrupt_query)
6248 (remote_notif_get_pending_events, fetch_register_using_p)
6249 (send_g_packet, process_g_packet, fetch_registers_using_g)
6250 (store_register_using_P, store_registers_using_G)
6251 (set_remote_traceframe, check_binary_download)
6252 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
6253 (remote_xfer_live_readonly_partial, remote_read_bytes)
6254 (remote_send_printf, remote_flash_write, readchar)
6255 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
6256 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
6257 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
6258 (extended_remote_disable_randomization, extended_remote_run)
6259 (send_environment_packet, extended_remote_environment_support)
6260 (extended_remote_set_inferior_cwd, remote_write_qxfer)
6261 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
6262 (packet_command): Now methods of ...
6263 (remote_target): ... this class.
6264 (m_remote_state) <remote_target>: New field.
6265 (struct remote_state) <stop_reply_queue,
6266 remote_async_inferior_event_token, wait_forever_enabled_p>: New
6267 fields.
6268 (remote_state::remote_state): Allocate stop_reply_queue.
6269 (remote_state): Delete global.
6270 (get_remote_state_raw): Delete.
6271 (remote_target::get_remote_state): Allocate m_remote_state on
6272 demand.
6273 (get_current_remote_target): New.
6274 (remote_ops, extended_remote_ops): Delete.
6275 (wait_forever_enabled_p, remote_async_inferior_event_token):
6276 Delete, moved to struct remote_state.
6277 (remote_target::close): Delete self. Destruction bits split to
6278 ...
6279 (remote_target::~remote_target): ... this.
6280 (show_memory_packet_size): Adjust to use
6281 get_current_remote_target.
6282 (struct protocol_feature) <func>: Add remote_target parameter.
6283 All callers adjusted.
6284 (curr_quit_handler_target): New.
6285 (remote_serial_quit_handler): Reimplement.
6286 (remote_target::open_1): Adjust to use get_current_remote_target.
6287 Heap-allocate remote_target/extended_remote_target instances.
6288 (vcont_builder::vcont_builder): Add remote_target parameter, and
6289 save it in m_remote. All callers adjusted.
6290 (vcont_builder::m_remote): New field.
6291 (vcont_builder::restart, vcont_builder::flush)
6292 (vcont_builder::push_action): Use it.
6293 (remote_target::commit_resume): Use it.
6294 (struct queue_iter_param) <remote>: New field.
6295 (remote_target::remove_new_fork_children): Fill in 'remote' field.
6296 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
6297 (check_pending_event_prevents_wildcard_vcont_callback)
6298 (remote_target::check_pending_events_prevent_wildcard_vcont)
6299 (remote_target::discard_pending_stop_replies)
6300 (remote_target::discard_pending_stop_replies_in_queue)
6301 (remote_target::remote_notif_remove_queued_reply): Fill in
6302 'remote' field.
6303 (remote_notif_get_pending_events): New.
6304 (remote_target::readchar, remote_target::remote_serial_write):
6305 Save/restore curr_quit_handler_target.
6306 (putpkt): New.
6307 (kill_new_fork_children): Fill in 'remote' field.
6308 (packet_command): Use get_current_remote_target, defer to
6309 remote_target method of same name.
6310 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
6311 parameter, and save it in m_remote. All callers adjusted.
6312 (scoped_remote_fd::release): Use m_remote.
6313 (scoped_remote_fd::m_remote): New field.
6314 (remote_file_put, remote_file_get, remote_file_delete): Use
6315 get_current_remote_target, defer to remote_target method of same
6316 name.
6317 (remote_btrace_reset): Add remote_state paremeter. Update all
6318 callers.
6319 (remote_async_inferior_event_handler). Pass down 'data'.
6320 (remote_new_objfile): Use get_current_remote_target.
6321 (remote_target::vcont_r_supported): New.
6322 (set_range_stepping): Use get_current_remote_target and
6323 remote_target::vcont_r_supported.
6324 (_initialize_remote): Don't allocate 'remote_state' and
6325 'stop_reply_queue' globals.
6326 * remote.h (struct remote_target): Forward declare.
6327 (getpkt, putpkt, remote_notif_get_pending_events): Add
6328 'remote_target' parameter.
6329
6330 2018-05-22 Pedro Alves <palves@redhat.com>
6331
6332 * remote.c (vcont_builder): Now a class. Make all data members
6333 private.
6334 (vcont_builder) <vcont_builder, restart, flush, push_action>:
6335 Declare methods.
6336 (vcont_builder_restart): Rename to ...
6337 (vcont_builder::restart): ... this.
6338 (vcont_builder_flush): Rename to ...
6339 (vcont_builder::flush): ... this.
6340 (vcont_builder_push_action): Rename to ...
6341 (vcont_builder::push_action): ... this.
6342 (remote_target::commit_resume): Adjust.
6343
6344 2018-05-22 Pedro Alves <palves@redhat.com>
6345
6346 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
6347 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
6348 (get_fixed_memory_packet_size): New.
6349 (get_memory_packet_size): Use it.
6350 (set_memory_packet_size): Don't override the config size with
6351 DEFAULT_MAX_MEMORY_PACKET_SIZE.
6352 (show_memory_packet_size): Use get_fixed_memory_packet_size.
6353 Don't refer to get_memory_packet_size if not connected to a remote
6354 target. Show "(default)" if configured size is 0.
6355
6356 2018-05-22 Pedro Alves <palves@redhat.com>
6357
6358 * remote.c (remote_target::mourn_inferior): Move
6359 discard_pending_stop_replies call here from ...
6360 (_initialize_remote): ... here.
6361
6362 2018-05-22 Pedro Alves <palves@redhat.com>
6363
6364 * remote.c (compare_section_command): Remove set_general_process
6365 call.
6366
6367 2018-05-22 Pedro Alves <palves@redhat.com>
6368
6369 * remote.c (struct packet_reg, struct remote_arch_state):
6370 Move higher up in the file.
6371 (remote_state) <m_arch_states>: Store remote_arch_state values
6372 instead of remote_arch_state pointers.
6373 (remote_state::get_remote_arch_state): Adjust.
6374
6375 2018-05-22 Pedro Alves <palves@redhat.com>
6376
6377 * remote.c: Include <unordered_map>.
6378 (remote_state): Now a class.
6379 (remote_state) <get_remote_arch_state>: Declare method.
6380 <get_remote_arch_state>: New field.
6381 (remote_arch_state) <remote_arch_state>: Declare ctor.
6382 <regs>: Now a unique_ptr.
6383 (remote_gdbarch_data_handle): Delete.
6384 (get_remote_arch_state): Delete.
6385 (remote_state::get_remote_arch_state): New.
6386 (get_remote_state): Adjust to call remote_state's
6387 get_remote_arch_state method.
6388 (init_remote_state): Delete, bits factored out to ...
6389 (remote_arch_state::remote_arch_state): ... this new method.
6390 (get_remote_packet_size, get_memory_packet_size)
6391 (process_g_packet, remote_target::fetch_registers)
6392 (remote_target::prepare_to_store, store_registers_using_G)
6393 (remote_target::store_registers, remote_target::get_trace_status):
6394 Adjust to call remote_state's method.
6395 (_initialize_remote): Remove reference to
6396 remote_gdbarch_data_handle.
6397
6398 2018-05-22 Pedro Alves <palves@redhat.com>
6399
6400 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
6401 pread>: New method declarations.
6402 (remote_target::open_1): Adjust.
6403 (readahead_cache_invalidate): Rename to ...
6404 (readahead_cache::invalidate): ... this, and adjust to be a class
6405 method.
6406 (readahead_cache_invalidate_fd): Rename to ...
6407 (readahead_cache::invalidate_fd): ... this, and adjust to be a
6408 class method.
6409 (remote_hostio_pwrite): Adjust.
6410 (remote_hostio_pread_from_cache): Rename to ...
6411 (readahead_cache::pread): ... this, and adjust to be a class
6412 method.
6413 (remote_hostio_close): Adjust.
6414
6415 2018-05-22 Pedro Alves <palves@redhat.com>
6416
6417 * remote.c (remote_hostio_close_cleanup): Delete.
6418 (class scoped_remote_fd): New.
6419 (remote_file_put, remote_file_get): Use it.
6420
6421 2018-05-22 Pedro Alves <palves@redhat.com>
6422
6423 (struct vCont_action_support): Use bool and initialize all fields.
6424 (struct readahead_cache): Initialize all fields.
6425 (remote_state): Use bool and initialize all fields.
6426 (remote_state::remote_state, remote_state::~remote_state): New.
6427 (new_remote_state): Delete.
6428 (_initialize_remote): Use new to allocate remote_state.
6429
6430 2018-05-22 Pedro Alves <palves@redhat.com>
6431 張俊芝 <zjz@zjz.name>
6432
6433 PR gdb/22973
6434 * c-exp.y: Include "c-support.h".
6435 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
6436 of tolower. Use c_ident_is_alpha to scan names.
6437 * c-lang.c: Include "c-support.h".
6438 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
6439 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
6440 * c-support.h: New file, with bits factored out from ...
6441 * cp-name-parser.y: ... this file.
6442 Include "c-support.h".
6443 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
6444 c-support.h and renamed.
6445 (symbol_end, yylex): Adjust.
6446
6447 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6448
6449 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
6450 parameter type to CORE_ADDR.
6451 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
6452 parameter type in declaration to CORE_ADDR.
6453 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
6454 target_auxv_search to get AT_HWCAP and use the result to get the
6455 target description.
6456 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
6457 to CORE_ADDR. Remove the cast of the return value to unsigned
6458 long. Fix error predicate of target_auxv_search.
6459 (ppc_linux_nat_target::read_description): Change the type of the
6460 hwcap variable to CORE_ADDR.
6461
6462 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6463
6464 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
6465 if the size of fpscr is larger than 32 bits.
6466
6467 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6468
6469 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
6470 (ppc32_linux_vsxregmap): New global.
6471 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
6472 regcache_supply_regset, and regcache_collect_regset.
6473 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
6474 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
6475 (fetch_vsx_register, store_vsx_register): Remove.
6476 (fetch_vsx_registers): Add regno parameter. Get regset using
6477 ppc_linux_vsxregset. Use regset to supply registers.
6478 (store_vsx_registers): Add regno parameter. Get regset using
6479 ppc_linux_vsxregset. Use regset to collect registers.
6480 (fetch_register): Call fetch_vsx_registers instead of
6481 fetch_vsx_register.
6482 (store_register): Call store_vsx_registers instead of
6483 store_vsx_register.
6484 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
6485 new regno parameter.
6486 (store_ppc_registers): Call store_vsx_registers with -1 for the
6487 new regno parameter.
6488 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
6489 (ppc_collect_vsxregset): Remove.
6490
6491 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6492
6493 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
6494 offset fields.
6495 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
6496 for vector register offset fields.
6497 (ppc64_fbsd_reg_offsets): Likewise.
6498 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6499 to vector register offset fields.
6500 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6501 to vector register offset fields.
6502 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
6503 vector register offset fields.
6504 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
6505 initializers for vector register offset fields.
6506 (rs6000_aix64_reg_offsets): Likewise.
6507 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
6508 (ppc_supply_vrregset): Remove.
6509 (ppc_collect_vrregset): Remove.
6510 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
6511 (ppc_linux_vrregset) : New function.
6512 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
6513 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
6514 (ppc32_linux_vrregset): Remove.
6515 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
6516 and use result instead of ppc32_linux_vrregset.
6517 (ppc32_linux_reg_offsets): Remove initializers for vector register
6518 offset fields.
6519 (ppc64_linux_reg_offsets): Likewise.
6520 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
6521 * ppc-linux-nat.c: Include regset.h.
6522 (gdb_vrregset_t): Adjust comment to account for little-endian
6523 mode.
6524 (supply_vrregset, fill_vrregset): Remove.
6525 (fetch_altivec_register, store_altivec_register): Remove.
6526 (fetch_altivec_registers): Add regno parameter. Get regset using
6527 ppc_linux_vrregset. Use regset to supply registers.
6528 (store_altivec_registers): Add regno parameter. Get regset using
6529 ppc_linux_vrregset. Use regset to collect registers.
6530 (fetch_register): Call fetch_altivec_registers instead of
6531 fetch_altivec_register.
6532 (store_register): Call store_altivec_registers instead of
6533 store_altivec_register.
6534 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
6535 the new regno parameter.
6536 (store_ppc_registers): Call store_altivec_registers with -1 for
6537 the new regno parameter.
6538
6539 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6540
6541 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
6542 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
6543 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
6544 (gdb_vrregset_t): Change array type size to
6545 PPC_LINUX_SIZEOF_VRREGSET.
6546 (gdb_vsxregset_t): Change array type size to
6547 PPC_LINUX_SIZEOF_VSXREGSET.
6548 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
6549 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
6550 PPC_LINUX_SIZEOF_VSXREGSET.
6551
6552 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6553
6554 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
6555 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
6556 nat/ppc-linux.c.
6557 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
6558 ppc_linux_target_wordsize with tid.
6559 (ppc_linux_nat_target::read_description): Call ppc_linux_target
6560 wordsize with tid.
6561 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
6562 (ppc64_64bit_inferior_p): Add static and inline specifiers.
6563 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
6564 tid parameter. Remove static specifier.
6565 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
6566 (ppc_linux_target_wordsize): New declaration.
6567
6568 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6569
6570 * arch/ppc-linux-common.c: New file.
6571 * arch/ppc-linux-common.h: New file.
6572 * arch/ppc-linux-tdesc.h: New file.
6573 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
6574 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
6575 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
6576 arch/ppc-linux-tdesc.h.
6577 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
6578 arch/ppc-linux-tdesc.h.
6579 (ppc_linux_nat_target::read_description): Remove target
6580 description matching code. Fill a ppc_linux_features struct and
6581 call ppc_linux_match_description with it. Move comment about ISA
6582 2.05 to ppc-linux-common.c.
6583 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
6584 arch/ppc-linux-tdesc.h.
6585 (ppc_linux_core_read_description): Remove target description
6586 matching code. Fill a ppc_linux_features struct and call
6587 ppc_linux_match_description with it.
6588 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
6589 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
6590 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
6591 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
6592 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
6593 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
6594 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
6595 (tdesc_powerpc_e500l): Remove.
6596
6597 2018-05-22 Joel Brobecker <brobecker@adacore.com>
6598
6599 * ada-lang.c (catch_assert_command): Pass empty string instead
6600 of NULL for excep_string argument.
6601
6602 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6603
6604 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
6605 the width of the requested register exceeds the width of the
6606 `ptrace' data type.
6607
6608 2018-05-21 Tom Tromey <tom@tromey.com>
6609
6610 * printcmd.c (output_command): Remove.
6611 (output_command_const): Rename to output_command.
6612 * valprint.h (output_command): Rename from output_command_const.
6613 * tracepoint.c (trace_dump_actions): Call output_command.
6614
6615 2018-05-21 Tom Tromey <tom@tromey.com>
6616
6617 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
6618 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
6619 * ada-lang.h (create_ada_exception_catchpoint): Update.
6620 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
6621 std::string.
6622 (create_excep_cond_exprs, ~ada_catchpoint)
6623 (should_stop_exception, print_one_exception)
6624 (print_mention_exception, print_recreate_exception): Update.
6625 (ada_get_next_arg): Remove.
6626 (catch_ada_exception_command_split): Use std::string. Change type
6627 of "excep_string", "cond_string".
6628 (catch_ada_exception_command): Update.
6629 (create_ada_exception_catchpoint): Change type of excep_string.
6630 (ada_exception_sal): Remove excep_string parameter.
6631 (~ada_catchpoint): Remove.
6632
6633 2018-05-21 Tom Tromey <tom@tromey.com>
6634
6635 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
6636 cleanup.
6637
6638 2018-05-21 Tom Tromey <tom@tromey.com>
6639
6640 * ada-lang.c (ada_exception_message_1, ada_exception_message):
6641 Return unique_xmalloc_ptr.
6642 (print_it_exception): Update.
6643
6644 2018-05-21 Tom Tromey <tom@tromey.com>
6645
6646 * tracepoint.c (trace_dump_actions): Use std::string.
6647
6648 2018-05-21 Tom Tromey <tom@tromey.com>
6649
6650 * symfile.c (reread_symbols): Use std::string for original_name.
6651
6652 2018-05-21 Tom Tromey <tom@tromey.com>
6653
6654 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
6655 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
6656 constructor.
6657
6658 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
6659
6660 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
6661 instance to...
6662 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
6663 * objfiles.c (get_objfile_bfd_data): Allocate
6664 objfile_per_bfd_storage with obstack_new when allocating on
6665 obstack.
6666
6667 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
6668
6669 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
6670 OBSTACK_ZALLOC.
6671 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
6672 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
6673 * mdebugread.c (mdebug_build_psymtabs): Likewise.
6674 (add_pending): Likewise.
6675 (parse_symbol): Likewise.
6676 (parse_partial_symbols): Likewise.
6677 (psymtab_to_symtab_1): Likewise.
6678 (new_psymtab): Likewise.
6679 (elfmdebug_build_psymtabs): Likewise.
6680 * minsyms.c (terminate_minimal_symbol_table): Likewise.
6681 * objfiles.c (get_objfile_bfd_data): Likewise.
6682 (objfile_register_static_link): Likewise.
6683 * psymtab.c (allocate_psymtab): Likewise.
6684 * stabsread.c (read_member_functions): Likewise.
6685 * xcoffread.c (xcoff_end_psymtab): Likewise.
6686
6687 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
6688
6689 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
6690 compiler supports std::is_trivially_constructible.
6691 * common/poison.h: Include obstack.h.
6692 (IsMallocable): Define to is_trivially_constructible if the
6693 compiler supports it, define to true_type otherwise.
6694 (xobnew): New.
6695 (XOBNEW): Redefine.
6696 (xobnewvec): New.
6697 (XOBNEWVEC): Redefine.
6698 * gdb_obstack.h (obstack_zalloc): New.
6699 (OBSTACK_ZALLOC): Redefine.
6700 (obstack_calloc): New.
6701 (OBSTACK_CALLOC): Redefine.
6702 (obstack_new): New.
6703 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
6704 (gdbarch_obstack): New declaration in gdbarch.h, definition in
6705 gdbarch.c.
6706 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
6707 obstack_calloc/obstack_zalloc.
6708 (gdbarch_obstack_zalloc): Remove.
6709 * target-descriptions.c (tdesc_data_init): Use obstack_new.
6710
6711 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6712
6713 * stack.c (backtrace_command_1): Remove useless variable int i.
6714
6715 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6716
6717 * stack.c (print_frame_info): Fix comment.
6718
6719 2018-05-18 Tom Tromey <tom@tromey.com>
6720
6721 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
6722 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
6723 (~dwarf2_per_objfile): Update
6724 (dwarf2_get_dwz_file): Use new.
6725 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
6726 unique_ptr.
6727
6728 2018-05-18 Tom Tromey <tom@tromey.com>
6729
6730 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
6731 unique_ptr.
6732 * dwarf2read.c (struct dwp_file): Add constructor and
6733 initializers.
6734 (open_and_init_dwp_file): Return a unique_ptr.
6735 (dwarf2_per_objfile, create_dwp_hash_table)
6736 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
6737 (lookup_dwo_unit_in_dwp): Update.
6738 (open_and_init_dwp_file, get_dwp_file): Update.
6739
6740 2018-05-18 Tom Tromey <tom@tromey.com>
6741
6742 * dwarf2read.c (dwarf2_per_objfile): Update.
6743 (struct mapped_index): Add initializers.
6744 (dwarf2_read_index): Use new.
6745 (dw2_symtab_iter_init): Update.
6746 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
6747 unique_ptr.
6748
6749 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6750
6751 * dwarf2read.c (mapped_index) <total_size>: Remove.
6752
6753 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6754
6755 * unittests/format_pieces-selftests.c (test_format_specifier):
6756 Add ARI comments.
6757
6758 2018-05-18 Tom Tromey <tom@tromey.com>
6759
6760 * c-typeprint.c (maybe_print_hole): New function.
6761 (c_print_type_struct_field_offset): Update.
6762 (c_type_print_base_struct_union): Call maybe_print_hole.
6763
6764 2018-05-17 Keith Seitz <keiths@redhat.com>
6765
6766 * breakpoint.c (build_bpstat_chain): New function, moved from
6767 bpstat_stop_status.
6768 (bpstat_stop_status): Add optional parameter, `stop_chain'.
6769 If no stop chain is passed, call build_bpstat_chain to build it.
6770 * breakpoint.h (build_bpstat_chain): Declare.
6771 (bpstat_stop_status): Move documentation here from breakpoint.c.
6772 * infrun.c (handle_signal_stop): Before eliding inlined frames,
6773 build the stop chain and pass it to skip_inline_frames.
6774 Pass this stop chain to bpstat_stop_status.
6775 * inline-frame.c: Include breakpoint.h.
6776 (stopped_by_user_bp_inline_frame): New function.
6777 (skip_inline_frames): Add parameter `stop_chain'.
6778 Move documention to inline-frame.h.
6779 If non-NULL, use stopped_by_user_bp_inline_frame to determine
6780 whether the frame should be elided.
6781 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
6782 Add moved documentation and update for new parameter.
6783
6784 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
6785
6786 PR cli/14975
6787 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6788 unittests/format_pieces-selftests.c.
6789 * common/format.h (format_piece) <operator==>: New.
6790 (format_pieces) <operator[]>: Remove.
6791 * common/format.c (format_pieces::format_pieces): Handle \e.
6792 * unittests/format_pieces-selftests.c: New.
6793
6794 2018-05-17 Tom Tromey <tom@tromey.com>
6795
6796 PR symtab/23010:
6797 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
6798 (dw2_instantiate_symtab): Add skip_partial parameter.
6799 (dw2_find_last_source_symtab, dw2_map_expand_apply)
6800 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
6801 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
6802 (dw2_expand_symtabs_matching_one)
6803 (dw2_find_pc_sect_compunit_symtab)
6804 (dw2_debug_names_lookup_symbol)
6805 (dw2_debug_names_expand_symtabs_for_function): Update.
6806 (init_cutu_and_read_dies): Add skip_partial parameter.
6807 (process_psymtab_comp_unit, build_type_psymtabs_1)
6808 (process_skeletonless_type_unit, load_partial_comp_unit)
6809 (psymtab_to_symtab_1): Update.
6810 (load_full_comp_unit): Add skip_partial parameter.
6811 (process_imported_unit_die, dwarf2_read_addr_index)
6812 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
6813 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
6814 (read_signatured_type): Update.
6815
6816 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
6817
6818 * value.c (release_value): Remove unused variable.
6819 (record_latest_value): Likewise.
6820 (access_value_history): Likewise.
6821 (preserve_values): Likewise.
6822
6823 2018-05-17 Tom Tromey <tom@tromey.com>
6824
6825 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
6826 Initialize.
6827
6828 2018-05-16 Maciej W. Rozycki <macro@mips.com>
6829
6830 PR gdb/22286
6831 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
6832 Also handle registers whose width is not a multiple of
6833 PTRACE_TYPE_RET.
6834 (linux_nat_trad_target::store_register): Likewise.
6835
6836 2018-05-16 Tom Tromey <tom@tromey.com>
6837
6838 * gdbcore.h (core_bfd): Redefine.
6839 * corelow.c (core_target::close): Update.
6840 (core_target_open): Update.
6841 * progspace.h (struct program_space) <cbfd>: Now a
6842 gdb_bfd_ref_ptr.
6843
6844 2018-05-16 Tom Tromey <tom@tromey.com>
6845
6846 PR cli/19551:
6847 * symfile-add-flags.h (enum symfile_add_flags)
6848 <SYMFILE_NOT_FILENAME>: New constant.
6849 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
6850 objfile name from BFD.
6851 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
6852 * minidebug.c (find_separate_debug_file_in_section): Put
6853 ".gnu_debugdata" into BFD's file name.
6854
6855 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
6856
6857 * regcache.c (regcache_read_ftype, regcache_write_ftype):
6858 Remove.
6859
6860 2018-05-15 Tamar Christina <tamar.christina@arm.com>
6861
6862 PR binutils/21446
6863 * aarch64-tdep.c (aarch64_analyze_prologue,
6864 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
6865 Indicate not interested in errors.
6866
6867 2018-05-15 Maciej W. Rozycki <macro@mips.com>
6868
6869 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
6870 Supply the MIPS_ZERO_REGNUM register.
6871
6872 2018-05-15 Maciej W. Rozycki <macro@mips.com>
6873
6874 * mips-tdep.c (mask_address_var): Make variable static.
6875
6876 2018-05-14 Tom Tromey <tom@tromey.com>
6877
6878 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
6879
6880 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
6881
6882 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
6883 FXSAVE_ADDR for the mxcsr register.
6884
6885 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
6886
6887 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
6888
6889 2018-05-11 Pedro Alves <palves@redhat.com>
6890
6891 * corelow.c (core_target) <core_target>: No longer inline.
6892 Initialize m_core_gdbarch, m_core_vec and build the section table
6893 here.
6894 <~core_target>: New.
6895 <core_gdbarch, get_core_register_section>: New methods.
6896 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
6897 factored out from ...
6898 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
6899 (core_ops): Delete.
6900 (sniff_core_bfd): Add gdbarch parameter.
6901 (core_close): Delete, merged into ...
6902 (core_target::close): ... here. Delete self.
6903 (core_close_cleanup): Delete.
6904 (core_target_open): Allocate a core_target on the heap. Use a
6905 unique_ptr instead of a cleanup. Bits moved into the core_target
6906 ctor. Adjust to use core_target methods instead of globals.
6907 (get_core_register_section): Rename to ...
6908 (core_target::get_core_register_section): ... this and adjust.
6909 (struct get_core_registers_cb_data): New.
6910 (get_core_registers_cb): Use it. Use bool.
6911 (core_target::fetch_registers, core_target::files_info)
6912 (core_target::xfer_partial, core_target::read_description)
6913 (core_target::pid_to, core_target::thread_name): Adjust to
6914 reference class fields instead of globals.
6915 * target.h (struct target_ops_deleter, target_ops_up): New.
6916
6917 2018-05-11 Pedro Alves <palves@redhat.com>
6918
6919 * corefile.c (core_file_command): Move to corelow.c.
6920 * corelow.c (the_core_target): Delete.
6921 (core_file_command): Moved from corefile.c. Check exec_bfd
6922 instead of the_core_target. Use target_detach instead of calling
6923 into the_core_target directly.
6924 (maybe_say_no_core_file_now): New.
6925 (core_target::detach): Use it.
6926 (_initialize_corelow): Remove references to the_core_target.
6927 * gdbcore.h (the_core_target): Delete.
6928
6929 2018-05-11 Tom Tromey <tromey@redhat.com>
6930 Pedro Alves <palves@redhat.com>
6931
6932 * corefile.c (core_bfd): Remove.
6933 * gdbcore.h (core_bfd): Now a macro.
6934 * progspace.h (struct program_space) <cbfd>: New field.
6935
6936 2018-05-11 Tom Tromey <tom@tromey.com>
6937
6938 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
6939 gdb::def_vector.
6940
6941 2018-05-10 Tom Tromey <tom@tromey.com>
6942
6943 * configure: Rebuild.
6944 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
6945
6946 2018-05-10 Joel Brobecker <brobecker@adacore.com>
6947
6948 PR server/23158:
6949 * regformats/regdat.sh: Adjust script, following the addition
6950 of the new expedite_regs parameter to init_target_desc.
6951
6952 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
6953
6954 PR gdb/23127
6955 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
6956 set_gdbarch_significant_addr_bit.
6957 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
6958 set_gdbarch_significant_addr_bit.
6959 * utils.c (address_significant): Update to sign extend addr.
6960
6961 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
6962
6963 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
6964 (xtensa_linux_init_abi): Limit tdep->num_regs by
6965 tdep->num_nopriv_regs.
6966 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
6967 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
6968 not initialized.
6969
6970 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
6971
6972 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
6973
6974 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
6975
6976 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
6977 (I387_MXCSR_INIT_VAL): New constant.
6978 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
6979 buffer if it was supplied by the inferior.
6980 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
6981 (i387_xsave_get_clear_bv): New function.
6982 (i387_supply_xsave): Only read x87 control registers from the
6983 xsave buffer if the feature is enabled, and the state will have
6984 been written, otherwise, provide a suitable default.
6985 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
6986 including x87 control registers. Update control registers if they
6987 have changed from the default value, and mark features as enabled
6988 as required.
6989 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
6990
6991 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
6992
6993 * spu-tdep.c (info_spu_event_command): Fix output formatting.
6994
6995 2018-05-07 Tom Tromey <tom@tromey.com>
6996
6997 * configure: Rebuild.
6998 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
6999
7000 2018-05-07 Tom Tromey <tom@tromey.com>
7001
7002 PR tdep/20362:
7003 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
7004 bit. Use correct value for VDIV.
7005
7006 2018-05-04 Tom Tromey <tom@tromey.com>
7007
7008 * configure: Rebuild.
7009 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
7010
7011 2018-05-04 Tom Tromey <tom@tromey.com>
7012
7013 * linux-record.c (record_linux_system_call) <case
7014 RECORD_SYS_RECVFROM>: Add "break".
7015
7016 2018-05-04 Tom Tromey <tom@tromey.com>
7017
7018 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
7019 Add missing "break".
7020 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
7021 Add missing "break".
7022
7023 2018-05-04 Tom Tromey <tom@tromey.com>
7024
7025 * rs6000-tdep.c (ppc_process_record_op4)
7026 (ppc_process_record_op63): Add fall-through comment.
7027
7028 2018-05-04 Tom Tromey <tom@tromey.com>
7029
7030 * i386-tdep.c (i386_process_record): Add fall-through comment.
7031
7032 2018-05-04 Tom Tromey <tom@tromey.com>
7033
7034 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
7035 comment.
7036
7037 2018-05-04 Tom Tromey <tom@tromey.com>
7038
7039 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
7040 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
7041 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
7042 comment.
7043 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
7044 comment.
7045 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
7046 comment.
7047
7048 2018-05-04 Tom Tromey <tom@tromey.com>
7049
7050 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
7051
7052 2018-05-04 Tom Tromey <tom@tromey.com>
7053
7054 * s390-tdep.c (s390_process_record): Fix fall-through comments.
7055 * xcoffread.c (scan_xcoff_symtab): Move comment later.
7056 * symfile.c (section_is_mapped): Fix fall-through comment.
7057 * stabsread.c (define_symbol, read_member_functions): Fix
7058 fall-through comment.
7059 * s390-linux-tdep.c (s390_process_record): Fix fall-through
7060 comment.
7061 * remote.c (remote_wait_as): Fix fall-through comment.
7062 * p-exp.y (yylex): Fix fall-through comment.
7063 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
7064 comment.
7065 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
7066 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
7067 * jv-exp.y (yylex): Fix fall-through comment.
7068 * go-exp.y (lex_one_token): Fix fall-through comment.
7069 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
7070 fall-through comment.
7071 * f-exp.y (yylex): Fix fall-through comment.
7072 * dwarf2read.c (process_die): Fix fall-through comments.
7073 * dbxread.c (process_one_symbol): Fix fall-through comment.
7074 * d-exp.y (lex_one_token): Fix fall-through comment.
7075 * cp-name-parser.y (yylex): Fix fall-through comment.
7076 * coffread.c (coff_symtab_read): Fix fall-through comment.
7077 * c-exp.y (lex_one_token): Fix fall-through comment.
7078 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
7079 comment.
7080 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
7081 comment.
7082
7083 2018-05-04 Tom Tromey <tom@tromey.com>
7084
7085 PR python/22730:
7086 * NEWS: Mention gdb.execute change.
7087 * gdbcmd.h (execute_control_command): Don't declare.
7088 * python/python.c (execute_gdb_command): Use read_command_lines_1,
7089 execute_control_commands, execute_control_commands_to_string.
7090 * cli/cli-script.h (execute_control_commands)
7091 (execute_control_commands_to_string): Declare.
7092 (execute_control_command): Add from_tty parameter.
7093 * cli/cli-script.c (execute_control_commands)
7094 (execute_control_commands_to_string): New functions.
7095 (execute_user_command): Use execute_control_commands.
7096 (execute_control_command_1): Add "from_tty" parameter. Update.
7097 (execute_control_command): Likewise.
7098
7099 2018-05-04 Tom Tromey <tom@tromey.com>
7100
7101 PR python/22731:
7102 * NEWS: Mention that breakpoint commands are writable.
7103 * python/py-breakpoint.c (bppy_set_commands): New function.
7104 (breakpoint_object_getset) <"commands">: Use it.
7105
7106 2018-05-04 Tom Tromey <tom@tromey.com>
7107
7108 * tracepoint.c (actions_command): Update.
7109 * mi/mi-cmd-break.c (mi_command_line_array)
7110 (mi_command_line_array_cnt, mi_command_line_array_ptr)
7111 (mi_read_next_line): Remove.
7112 (mi_cmd_break_commands): Update.
7113 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
7114 function_view.
7115 * cli/cli-script.c (get_command_line): Update.
7116 (process_next_line): Use function_view. Constify.
7117 (recurse_read_control_structure, read_command_lines)
7118 (read_command_lines_1): Change argument types to function_view.
7119 (do_define_command, document_command): Update.
7120 * breakpoint.h (check_tracepoint_command): Don't declare.
7121 * breakpoint.c (check_tracepoint_command): Remove.
7122 (commands_command_1, create_tracepoint_from_upload): Update.
7123
7124 2018-05-04 Tom Tromey <tom@tromey.com>
7125
7126 PR gdb/11750:
7127 * cli/cli-script.h (enum command_control_type) <define_control>:
7128 New constant.
7129 * cli/cli-script.c (multi_line_command_p): Handle define_control.
7130 (build_command_line, execute_control_command_1)
7131 (process_next_line): Likewise.
7132 (do_define_command): New function, extracted from define_command.
7133 (define_command): Use it.
7134
7135 2018-05-04 Tom Tromey <tom@tromey.com>
7136
7137 * tracepoint.c (actions_command): Update.
7138 * cli/cli-script.h (read_command_lines): Update.
7139 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
7140 (MAX_TMPBUF): Remove define.
7141 (define_command): Use string_printf.
7142 (document_command): Likewise.
7143 * breakpoint.c (commands_command_1): Update.
7144
7145 2018-05-04 Tom Tromey <tom@tromey.com>
7146
7147 * top.c (execute_command): Update.
7148 * cli/cli-script.h (print_command_lines): Now varargs.
7149 * cli/cli-script.c (print_command_lines): Now varargs.
7150 (execute_control_command_1) <case while_control, case if_control>:
7151 Update.
7152
7153 2018-05-04 Tom Tromey <tom@tromey.com>
7154
7155 * tracepoint.c (all_tracepoint_actions): Rename from
7156 all_tracepoint_actions_and_cleanup. Change return type.
7157 (actions_command, encode_actions_1, encode_actions)
7158 (trace_dump_actions, tdump_command): Update.
7159 * remote.c (remote_download_command_source): Update.
7160 * python/python.c (gdbpy_eval_from_control_command)
7161 (python_command, python_interactive_command): Update.
7162 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
7163 * guile/guile.c (guile_command)
7164 (gdbscm_eval_from_control_command, guile_command): Update.
7165 * compile/compile.c (compile_code_command)
7166 (compile_print_command, compile_to_object): Update.
7167 * cli/cli-script.h (struct command_lines_deleter): New.
7168 (counted_command_line): New typedef.
7169 (struct command_line): Add constructor, destructor.
7170 <body_list>: Remove.
7171 <body_list_0, body_list_1>: New members.
7172 (command_line_up): Remove typedef.
7173 (read_command_lines, read_command_lines_1, get_command_line):
7174 Update.
7175 (copy_command_lines): Don't declare.
7176 * cli/cli-script.c (build_command_line): Use "new".
7177 (get_command_line): Return counted_command_line.
7178 (print_command_lines, execute_user_command)
7179 (execute_control_command_1, while_command, if_command): Update.
7180 (realloc_body_list): Remove.
7181 (process_next_line, recurse_read_control_structure): Update.
7182 (read_command_lines, read_command_lines_1): Return counted_command_line.
7183 (free_command_lines): Use "delete".
7184 (copy_command_lines): Remove.
7185 (define_command, document_command, show_user_1): Update.
7186 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
7187 a counted_command_line.
7188 * breakpoint.h (counted_command_line): Remove typedef.
7189 (breakpoint_set_commands): Update.
7190 * breakpoint.c (check_no_tracepoint_commands)
7191 (validate_commands_for_breakpoint): Update.
7192 (breakpoint_set_commands): Change commands to be a
7193 counted_command_line.
7194 (commands_command_1, update_dprintf_command_list)
7195 (create_tracepoint_from_upload): Update.
7196
7197 2018-05-04 Tom Tromey <tom@tromey.com>
7198
7199 * cli/cli-decode.h (cmd_list_element): New constructor.
7200 (~cmd_list_element): New destructor.
7201 (struct cmd_list_element): Add initializers.
7202 * cli/cli-decode.c (do_add_cmd): Use "new".
7203 (delete_cmd): Use "delete".
7204
7205 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
7206 Pedro Alves <palves@redhat.com>
7207
7208 PR breakpoints/19806 and support for PR external/20207.
7209 * NEWS: Mention Aarch64 watchpoint improvements.
7210 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
7211 watchpoints and PR external/20207 watchpoints.
7212 * nat/aarch64-linux-hw-point.c
7213 (kernel_supports_any_contiguous_range): New.
7214 (aarch64_watchpoint_offset): New.
7215 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
7216 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
7217 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
7218 (aarch64_align_watchpoint): New parameters aligned_offset_p and
7219 next_addr_orig_p. Support PR external/20207 watchpoints.
7220 (aarch64_downgrade_regs): New.
7221 (aarch64_dr_state_insert_one_point): New parameters offset and
7222 addr_orig.
7223 (aarch64_dr_state_remove_one_point): Likewise.
7224 (aarch64_handle_breakpoint): Update caller.
7225 (aarch64_handle_aligned_watchpoint): Likewise.
7226 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
7227 aligned_offset.
7228 (aarch64_linux_set_debug_regs): Remove const from state. Call
7229 aarch64_downgrade_regs.
7230 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
7231 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
7232 (DR_CONTROL_MASK): ... this.
7233 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
7234 (unsigned int aarch64_watchpoint_offset): New prototype.
7235 (aarch64_linux_set_debug_regs): Remove const from state.
7236 * utils.c (align_up, align_down): Move to ...
7237 * common/common-utils.c (align_up, align_down): ... here.
7238 * utils.h (align_up, align_down): Move to ...
7239 * common/common-utils.h (align_up, align_down): ... here.
7240
7241 2018-05-04 Joel Brobecker <brobecker@adacore.com>
7242
7243 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
7244 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
7245 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
7246 Re-implement to match the ABI as summarized in GCC's
7247 gcc/config/sparc/sparc.c. All callers updated.
7248 (sparc32_store_arguments): Remove assertion.
7249
7250 2018-05-04 Tom Tromey <tom@tromey.com>
7251
7252 * printcmd.c: Don't include tui.h.
7253 (decode_format): Use skip_spaces.
7254
7255 2018-05-04 Tom Tromey <tom@tromey.com>
7256
7257 PR gdb/22619:
7258 * printcmd.c (last_count): New global.
7259 (x_command): Use saved count when repeating.
7260
7261 2018-05-04 Tom Tromey <tom@tromey.com>
7262
7263 * nto-procfs.c (do_closedir_cleanup): Remove.
7264 (procfs_pidlist): Use gdb_dir_up.
7265 * procfs.c (do_closedir_cleanup): Remove.
7266 (proc_update_threads): Use gdb_dir_up.
7267 * common/filestuff.h (struct gdb_dir_deleter): New.
7268 (gdb_dir_up): New typedef.
7269
7270 2018-05-04 Tom Tromey <tom@tromey.com>
7271
7272 * ada-lang.c (print_mention_exception): Use std::string.
7273
7274 2018-05-04 Tom Tromey <tom@tromey.com>
7275
7276 * ada-lang.c (create_excep_cond_exprs): Update.
7277 (ada_exception_catchpoint_cond_string): Use std::string.
7278
7279 2018-05-04 Tom Tromey <tom@tromey.com>
7280
7281 * ada-lang.c (xget_renaming_scope): Return std::string.
7282 (old_renaming_is_invisible): Update.
7283
7284 2018-05-04 Tom Tromey <tom@tromey.com>
7285
7286 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
7287 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
7288
7289 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
7290
7291 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
7292
7293 2018-05-04 Tom Tromey <tom@tromey.com>
7294
7295 * remote.c (remote_query_supported_append): Change type.
7296 (remote_check_symbols): Update.
7297
7298 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
7299
7300 PR gdb/11420
7301 * configure.ac: Prepend libpython.
7302 * python/python-config.py: Likewise.
7303 * configure: Regenerate.
7304
7305 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
7306
7307 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
7308
7309 2018-05-03 Pedro Alves <palves@redhat.com>
7310
7311 * s390-linux-nat.c
7312 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
7313 override. Write 'true' instead of '1'.
7314 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
7315 declaration.
7316
7317 2018-05-02 Pedro Alves <palves@redhat.com>
7318
7319 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
7320 add_inf_child_target.
7321 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
7322 add_inf_child_target.
7323 * aix-thread.c (aix_thread_target_info): New.
7324 (aix_thread_target) <shortname, longname, doc>: Delete.
7325 <info>: New.
7326 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
7327 add_inf_child_target.
7328 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
7329 add_inf_child_target.
7330 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
7331 add_inf_child_target.
7332 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
7333 add_inf_child_target.
7334 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
7335 add_inf_child_target.
7336 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
7337 add_inf_child_target.
7338 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
7339 add_inf_child_target.
7340 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
7341 add_inf_child_target.
7342 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
7343 add_inf_child_target.
7344 * bfd-target.c (target_bfd_target_info): New.
7345 (target_bfd) <shortname, longname, doc>: Delete.
7346 <info>: New.
7347 * bsd-kvm.c (bsd_kvm_target_info): New.
7348 (bsd_kvm_target) <shortname, longname, doc>: Delete.
7349 <info>: New.
7350 (bsd_kvm_target::open): Rename to ...
7351 (bsd_kvm_target_open): ... this. Adjust.
7352 * bsd-uthread.c (bsd_uthread_target_info): New.
7353 (bsd_uthread_target) <shortname, longname, doc>: Delete.
7354 <info>: New.
7355 * corefile.c (core_file_command): Adjust.
7356 * corelow.c (core_target_info): New.
7357 (core_target) <shortname, longname, doc>: Delete.
7358 <info>: New.
7359 (core_target::open): Rename to ...
7360 (core_target_open): ... this. Adjust.
7361 * ctf.c (ctf_target_info): New.
7362 (ctf_target) <shortname, longname, doc>: Delete.
7363 <info>: New.
7364 (ctf_target::open): Rename to ...
7365 (ctf_target_open): ... this.
7366 (_initialize_ctf): Adjust.
7367 * exec.c (exec_target_info): New.
7368 (exec_target) <shortname, longname, doc>: Delete.
7369 <info>: New.
7370 (exec_target::open): Rename to ...
7371 (exec_target_open): ... this.
7372 * gdbcore.h (core_target_open): Declare.
7373 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
7374 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
7375 add_inf_child_target.
7376 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
7377 add_inf_child_target.
7378 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
7379 add_inf_child_target.
7380 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
7381 add_inf_child_target.
7382 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
7383 add_inf_child_target.
7384 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
7385 add_inf_child_target.
7386 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
7387 add_inf_child_target.
7388 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
7389 add_inf_child_target.
7390 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
7391 add_inf_child_target.
7392 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
7393 add_inf_child_target.
7394 * inf-child.c (inf_child_target_info): New.
7395 (inf_child_target::info): New.
7396 (inf_child_open_target): Remove 'target' parameter. Use
7397 get_native_target instead.
7398 (inf_child_target::open): Delete.
7399 (add_inf_child_target): New.
7400 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
7401 Delete.
7402 <info>: New.
7403 (add_inf_child_target): Declare.
7404 (inf_child_open_target): Declare.
7405 * linux-thread-db.c (thread_db_target_info): New.
7406 (thread_db_target) <shortname, longname, doc>: Delete.
7407 <info>: New.
7408 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
7409 add_inf_child_target.
7410 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
7411 add_inf_child_target.
7412 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
7413 add_inf_child_target.
7414 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
7415 add_inf_child_target.
7416 * make-target-delegates (print_class): Adjust.
7417 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
7418 add_inf_child_target.
7419 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
7420 add_inf_child_target.
7421 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
7422 add_inf_child_target.
7423 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
7424 add_inf_child_target.
7425 * nto-procfs.c (nto_native_target_info): New.
7426 (nto_procfs_target_native) <shortname, longname, doc>:
7427 Delete.
7428 <info>: New.
7429 (nto_procfs_target_info): New.
7430 (nto_procfs_target_procfs) <shortname, longname, doc>:
7431 Delete.
7432 <info>: New.
7433 (init_procfs_targets): Adjust.
7434 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
7435 add_inf_child_target.
7436 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
7437 add_inf_child_target.
7438 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
7439 add_inf_child_target.
7440 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
7441 add_inf_child_target.
7442 * ravenscar-thread.c (ravenscar_target_info): New.
7443 (ravenscar_thread_target) <shortname, longname, doc>:
7444 Delete.
7445 <info>: New.
7446 * record-btrace.c (record_btrace_target_info):
7447 (record_btrace_target) <shortname, longname, doc>: Delete.
7448 <info>: New.
7449 (record_btrace_target::open): Rename to ...
7450 (record_btrace_target_open): ... this. Adjust.
7451 * record-full.c (record_longname, record_doc): New.
7452 (record_full_base_target) <shortname, longname, doc>: Delete.
7453 <info>: New.
7454 (record_full_target_info): New.
7455 (record_full_target): <shortname>: Delete.
7456 <info>: New.
7457 (record_full_core_open_1, record_full_open_1): Update comments.
7458 (record_full_base_target::open): Rename to ...
7459 (record_full_open): ... this.
7460 (cmd_record_full_restore): Update.
7461 (_initialize_record_full): Update.
7462 * remote-sim.c (remote_sim_target_info): New.
7463 (gdbsim_target) <shortname, longname, doc>: Delete.
7464 <info>: New.
7465 (gdbsim_target::open): Rename to ...
7466 (gdbsim_target_open): ... this.
7467 (_initialize_remote_sim): Adjust.
7468 * remote.c (remote_doc): New.
7469 (remote_target_info): New.
7470 (remote_target) <shortname, longname, doc>: Delete.
7471 <info>: New.
7472 (extended_remote_target_info): New.
7473 (extended_remote_target) <shortname, longname, doc>: Delete.
7474 <info>: New.
7475 (remote_target::open_1): Make static. Adjust.
7476 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
7477 * s390-linux-nat.c (_initialize_s390_nat): Use
7478 add_inf_child_target.
7479 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
7480 add_inf_child_target.
7481 * sol-thread.c (thread_db_target_info): New.
7482 (sol_thread_target) <shortname, longname, doc>: Delete.
7483 <info>: New.
7484 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
7485 add_inf_child_target.
7486 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
7487 add_inf_child_target.
7488 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
7489 add_inf_child_target.
7490 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
7491 add_inf_child_target.
7492 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
7493 add_inf_child_target.
7494 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
7495 add_inf_child_target.
7496 * spu-linux-nat.c (_initialize_spu_nat): Use
7497 add_inf_child_target.
7498 * spu-multiarch.c (spu_multiarch_target_info): New.
7499 (spu_multiarch_target) <shortname, longname, doc>: Delete.
7500 <info>: New.
7501 * target-delegates.c: Regenerate.
7502 * target.c: Include <unordered_map>.
7503 (target_ops_p): Delete.
7504 (DEF_VEC_P(target_ops_p)): Delete.
7505 (target_factories): New.
7506 (test_target_info): New.
7507 (test_target_ops::info): New.
7508 (open_target): Adjust to use target_factories.
7509 (add_target_with_completer): Rename to ...
7510 (add_target): ... this. Change prototype. Register target_info
7511 and open callback in target_factories. Register target_info in
7512 command context instead of target_ops.
7513 (add_target): Delete old implementation.
7514 (add_deprecated_target_alias): Change prototype. Adjust.
7515 (the_native_target): New.
7516 (set_native_target, get_native_target): New.
7517 (find_default_run_target): Use the_native_target.
7518 (find_attach_target, find_run_target): Simplify.
7519 (target_ops::open): Delete.
7520 (dummy_target_info): New.
7521 (dummy_target::shortname, dummy_target::longname)
7522 (dummy_target::doc): Delete.
7523 (dummy_target::info): New.
7524 (debug_target::shortname, debug_target::longname)
7525 (debug_target::doc): Delete.
7526 (debug_target::info): New.
7527 * target.h (struct target_info): New.
7528 (target_ops::~target_ops): Add comment.
7529 (target_ops::info): New.
7530 (target_ops::shortname, target_ops::longname, target_ops::doc): No
7531 longer virtual. Implement in terms of target_info.
7532 (set_native_target, get_native_target): Declare.
7533 (target_open_ftype): New.
7534 (add_target, add_target_with_completer)
7535 (add_deprecated_target_alias): Change prototype.
7536 (test_target) <shortname, longname, doc>: Delete.
7537 <info>: New.
7538 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
7539 add_inf_child_target.
7540 * tracefile-tfile.c (tfile_target_info): New.
7541 (tfile_target) <shortname, longname, doc>: Delete.
7542 <info>: New.
7543 (tfile_target::open): Rename to ...
7544 (tfile_target_open): ... this.
7545 (_initialize_tracefile_tfile): Adjust.
7546 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
7547 add_inf_child_target.
7548 * windows-nat.c (_initialize_windows_nat): Use
7549 add_inf_child_target.
7550 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
7551 add_inf_child_target.
7552
7553 2018-05-02 Pedro Alves <palves@redhat.com>
7554
7555 * linux-nat.h (linux_nat_target) <low_new_thread,
7556 low_delete_thread, low_new_fork, low_forget_process,
7557 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
7558 New virtual methods.
7559 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7560 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
7561 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
7562 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7563 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
7564 Delete.
7565 * linux-fork.c (delete_fork): Adjust to call low method.
7566 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
7567 (linux_nat_new_fork, linux_nat_forget_process_hook)
7568 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
7569 (linux_nat_status_is_event):
7570 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
7571 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
7572 to call low method.
7573 (sigtrap_is_event): Rename to ...
7574 (linux_nat_target::low_status_is_event): ... this.
7575 (linux_nat_set_status_is_event): Delete.
7576 (save_stop_reason, linux_nat_wait_1)
7577 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
7578 low methods.
7579 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7580 (linux_nat_set_new_fork, linux_nat_set_forget_process)
7581 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7582 (linux_nat_set_prepare_to_resume): Delete.
7583 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
7584 low virtual methods.
7585 * amd64-linux-nat.c: Likewise.
7586 * arm-linux-nat.c: Likewise.
7587 * i386-linux-nat.c: Likewise.
7588 * ia64-linux-nat.c: Likewise.
7589 * mips-linux-nat.c: Likewise.
7590 * ppc-linux-nat.c: Likewise.
7591 * s390-linux-nat.c: Likewise.
7592 * sparc64-linux-nat.c: Likewise.
7593 * x86-linux-nat.c: Likewise.
7594 * x86-linux-nat.h: Include "nat/x86-linux.h".
7595 (x86_linux_nat_target) <low_new_fork, low_forget_process,
7596 low_prepare_to_resume, low_new_thread, low_delete_thread>:
7597 Override methods.
7598
7599 2018-05-02 Pedro Alves <palves@redhat.com>
7600
7601 * target.h (target_ops)
7602 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
7603 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
7604 stopped_by_watchpoint, have_continuable_watchpoint,
7605 stopped_data_address, watchpoint_addr_within_range,
7606 can_accel_watchpoint_condition, can_run, thread_alive,
7607 has_all_memory, has_memory, has_stack, has_registers,
7608 has_execution, can_async_p, is_async_p, supports_non_stop,
7609 always_non_stop_p, can_execute_reverse, supports_multi_process,
7610 supports_enable_disable_tracepoint,
7611 supports_disable_randomization, supports_string_tracing,
7612 supports_evaluation_of_breakpoint_conditions,
7613 can_run_breakpoint_commands, filesystem_is_local,
7614 can_download_tracepoint, get_trace_state_variable_value,
7615 set_trace_notes, get_tib_address, use_agent, can_use_agent,
7616 record_is_replaying, record_will_replay,
7617 augmented_libraries_svr4_read>: Adjust to return bool.
7618 * aarch64-linux-nat.c: All implementations adjusted.
7619 * aix-thread.c: All implementations adjusted.
7620 * arm-linux-nat.c: All implementations adjusted.
7621 * breakpoint.c: All implementations adjusted.
7622 * bsd-kvm.c: All implementations adjusted.
7623 * bsd-uthread.c: All implementations adjusted.
7624 * corelow.c: All implementations adjusted.
7625 * ctf.c: All implementations adjusted.
7626 * darwin-nat.c: All implementations adjusted.
7627 * darwin-nat.h: All implementations adjusted.
7628 * exec.c: All implementations adjusted.
7629 * fbsd-nat.c: All implementations adjusted.
7630 * fbsd-nat.h: All implementations adjusted.
7631 * gnu-nat.c: All implementations adjusted.
7632 * gnu-nat.h: All implementations adjusted.
7633 * go32-nat.c: All implementations adjusted.
7634 * ia64-linux-nat.c: All implementations adjusted.
7635 * inf-child.c: All implementations adjusted.
7636 * inf-child.h: All implementations adjusted.
7637 * inf-ptrace.c: All implementations adjusted.
7638 * inf-ptrace.h: All implementations adjusted.
7639 * linux-nat.c: All implementations adjusted.
7640 * linux-nat.h: All implementations adjusted.
7641 * mips-linux-nat.c: All implementations adjusted.
7642 * nto-procfs.c: All implementations adjusted.
7643 * ppc-linux-nat.c: All implementations adjusted.
7644 * procfs.c: All implementations adjusted.
7645 * ravenscar-thread.c: All implementations adjusted.
7646 * record-btrace.c: All implementations adjusted.
7647 * record-full.c: All implementations adjusted.
7648 * remote-sim.c: All implementations adjusted.
7649 * remote.c: All implementations adjusted.
7650 * s390-linux-nat.c: All implementations adjusted.
7651 * sol-thread.c: All implementations adjusted.
7652 * spu-multiarch.c: All implementations adjusted.
7653 * target-delegates.c: All implementations adjusted.
7654 * target.c: All implementations adjusted.
7655 * target.h: All implementations adjusted.
7656 * tracefile-tfile.c: All implementations adjusted.
7657 * tracefile.c: All implementations adjusted.
7658 * tracefile.h: All implementations adjusted.
7659 * windows-nat.c: All implementations adjusted.
7660 * x86-linux-nat.h: All implementations adjusted.
7661 * x86-nat.h: All implementations adjusted.
7662
7663 2018-05-02 Pedro Alves <palves@redhat.com>
7664
7665 * make-target-delegates (scan_target_h): Don't trim lines here.
7666 Replace sequences of tabs and/or whitespace with a single
7667 whitespace.
7668 (top level, parsing methods): Trim each line before processing it
7669 here.
7670
7671 2018-05-02 Pedro Alves <palves@redhat.com>
7672 John Baldwin <jhb@freebsd.org>
7673
7674 * target.h (enum strata) <debug_stratum>: New.
7675 (struct target_ops) <all delegation methods>: Replace by C++
7676 virtual methods, and drop "to_" prefix. All references updated
7677 throughout.
7678 <to_shortname, to_longname, to_doc, to_data,
7679 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
7680 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
7681 virtual methods. All references updated throughout.
7682 <can_attach, supports_terminal_ours, can_create_inferior,
7683 get_thread_control_capabilities, attach_no_wait>: New
7684 virtual methods.
7685 <insert_breakpoint, remove_breakpoint>: Now
7686 TARGET_DEFAULT_NORETURN methods.
7687 <info_proc>: Now returns bool.
7688 <to_magic>: Delete.
7689 (OPS_MAGIC): Delete.
7690 (current_target): Delete. All references replaced by references
7691 to ...
7692 (target_stack): ... this. New.
7693 (target_shortname, target_longname): Adjust.
7694 (target_can_run): Now a function declaration.
7695 (default_child_has_all_memory, default_child_has_memory)
7696 (default_child_has_stack, default_child_has_registers)
7697 (default_child_has_execution): Remove target_ops parameter.
7698 (complete_target_initialization): Delete.
7699 (memory_breakpoint_target): New template class.
7700 (test_target_ops): Refactor as a C++ class with virtual methods.
7701 * make-target-delegates (NAME_PART): Tighten.
7702 (POINTER_PART, CP_SYMBOL): New.
7703 (SIMPLE_RETURN_PART): Reimplement.
7704 (VEC_RETURN_PART): Expect less.
7705 (RETURN_PART, VIRTUAL_PART): New.
7706 (METHOD): Adjust to C++ virtual methods.
7707 (scan_target_h): Remove reference to C99.
7708 (dname): Output "target_ops::" prefix.
7709 (write_function_header): Adjust to output a C++ class method.
7710 (write_declaration): New.
7711 (write_delegator): Adjust to output a C++ class method.
7712 (tdname): Output "dummy_target::" prefix.
7713 (write_tdefault, write_debugmethod): Adjust to output a C++ class
7714 method.
7715 (tdefault_names, debug_names): Delete.
7716 (return_types, tdefaults, styles, argtypes_array): New.
7717 (top level): All methods are delegators.
7718 (print_class): New.
7719 (top level): Print dummy_target and debug_target classes.
7720 * target-delegates.c: Regenerate.
7721 * target-debug.h (target_debug_print_enum_info_proc_what)
7722 (target_debug_print_thread_control_capabilities)
7723 (target_debug_print_thread_info_p): New.
7724 * target.c (dummy_target): Delete.
7725 (the_dummy_target, the_debug_target): New.
7726 (target_stack): Now extern.
7727 (set_targetdebug): Push/unpush debug target.
7728 (default_child_has_all_memory, default_child_has_memory)
7729 (default_child_has_stack, default_child_has_registers)
7730 (default_child_has_execution): Remove target_ops parameter.
7731 (complete_target_initialization): Delete.
7732 (add_target_with_completer): No longer call
7733 complete_target_initialization.
7734 (target_supports_terminal_ours): Use regular delegation.
7735 (update_current_target): Delete.
7736 (push_target): No longer check magic number. Don't call
7737 update_current_target.
7738 (unpush_target): Don't call update_current_target.
7739 (target_is_pushed): No longer check magic number.
7740 (target_require_runnable): Skip for all stratums over
7741 process_stratum.
7742 (target_ops::info_proc): New.
7743 (target_info_proc): Use find_target_at and
7744 find_default_run_target.
7745 (target_supports_disable_randomization): Use regular delegation.
7746 (target_get_osdata): Use find_target_at.
7747 (target_ops::open, target_ops::close, target_ops::can_attach)
7748 (target_ops::attach, target_ops::can_create_inferior)
7749 (target_ops::create_inferior, target_ops::can_run)
7750 (target_can_run): New.
7751 (default_fileio_target): Use regular delegation.
7752 (target_ops::fileio_open, target_ops::fileio_pwrite)
7753 (target_ops::fileio_pread, target_ops::fileio_fstat)
7754 (target_ops::fileio_close, target_ops::fileio_unlink)
7755 (target_ops::fileio_readlink): New.
7756 (target_fileio_open_1, target_fileio_unlink)
7757 (target_fileio_readlink): Always call the target method. Handle
7758 FILEIO_ENOSYS.
7759 (return_zero, return_zero_has_execution): Delete.
7760 (init_dummy_target): Delete.
7761 (dummy_target::dummy_target, dummy_target::shortname)
7762 (dummy_target::longname, dummy_target::doc)
7763 (debug_target::debug_target, debug_target::shortname)
7764 (debug_target::longname, debug_target::doc): New.
7765 (target_supports_delete_record): Use regular delegation.
7766 (setup_target_debug): Delete.
7767 (maintenance_print_target_stack): Skip debug_stratum.
7768 (initialize_targets): Instantiate the_dummy_target and
7769 the_debug_target.
7770 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
7771 use target_stack.
7772 (target_auxv_search, fprint_target_auxv): Adjust.
7773 (info_auxv_command): Adjust to use target_stack.
7774 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
7775 * exceptions.c (print_flush): Handle a NULL target_stack.
7776 * regcache.c (target_ops_no_register): Refactor as class with
7777 virtual methods.
7778
7779 * exec.c (exec_target): New class.
7780 (exec_ops): Now an exec_target.
7781 (exec_open, exec_close_1, exec_get_section_table)
7782 (exec_xfer_partial, exec_files_info, exec_has_memory)
7783 (exec_make_note_section): Refactor as exec_target methods.
7784 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
7785 Delete.
7786 (exec_target::find_memory_regions): New.
7787 (_initialize_exec): Don't call init_exec_ops.
7788 * gdbcore.h (exec_file_clear): Delete.
7789
7790 * corefile.c (core_target): Delete.
7791 (core_file_command): Adjust.
7792 * corelow.c (core_target): New class.
7793 (the_core_target): New.
7794 (core_close): Remove target_ops parameter.
7795 (core_close_cleanup): Adjust.
7796 (core_target::close): New.
7797 (core_open, core_detach, get_core_registers, core_files_info)
7798 (core_xfer_partial, core_thread_alive, core_read_description)
7799 (core_pid_to_str, core_thread_name, core_has_memory)
7800 (core_has_stack, core_has_registers, core_info_proc): Rework as
7801 core_target methods.
7802 (ignore, core_remove_breakpoint, init_core_ops): Delete.
7803 (_initialize_corelow): Initialize the_core_target.
7804 * gdbcore.h (core_target): Delete.
7805 (the_core_target): New.
7806
7807 * ctf.c: (ctf_target): New class.
7808 (ctf_ops): Now a ctf_target.
7809 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
7810 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
7811 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
7812 methods.
7813 (init_ctf_ops): Delete.
7814 (_initialize_ctf): Don't call it.
7815 * tracefile-tfile.c (tfile_target): New class.
7816 (tfile_ops): Now a tfile_target.
7817 (tfile_open, tfile_close, tfile_files_info)
7818 (tfile_get_tracepoint_status, tfile_trace_find)
7819 (tfile_fetch_registers, tfile_xfer_partial)
7820 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
7821 Refactor as tfile_target methods.
7822 (tfile_xfer_partial_features): Remove target_ops parameter.
7823 (init_tfile_ops): Delete.
7824 (_initialize_tracefile_tfile): Don't call it.
7825 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
7826 (tracefile_has_stack, tracefile_has_registers)
7827 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
7828 tracefile_target methods.
7829 (init_tracefile_ops): Delete.
7830 (tracefile_target::tracefile_target): New.
7831 * tracefile.h: Include "target.h".
7832 (tracefile_target): New class.
7833 (init_tracefile_ops): Delete.
7834
7835 * spu-multiarch.c (spu_multiarch_target): New class.
7836 (spu_ops): Now a spu_multiarch_target.
7837 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
7838 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
7839 (spu_search_memory, spu_mourn_inferior): Refactor as
7840 spu_multiarch_target methods.
7841 (init_spu_ops): Delete.
7842 (_initialize_spu_multiarch): Remove references to init_spu_ops,
7843 complete_target_initialization.
7844
7845 * ravenscar-thread.c (ravenscar_thread_target): New class.
7846 (ravenscar_ops): Now a ravenscar_thread_target.
7847 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
7848 (ravenscar_thread_alive, ravenscar_pid_to_str)
7849 (ravenscar_fetch_registers, ravenscar_store_registers)
7850 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
7851 (ravenscar_stopped_by_hw_breakpoint)
7852 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
7853 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
7854 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
7855 methods.
7856 (init_ravenscar_thread_ops): Delete.
7857 (_initialize_ravenscar): Remove references to
7858 init_ravenscar_thread_ops and complete_target_initialization.
7859
7860 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
7861 (bsd_uthread_target): New class.
7862 (bsd_uthread_ops): Now a bsd_uthread_target.
7863 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
7864 (bsd_uthread_close, bsd_uthread_mourn_inferior)
7865 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
7866 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
7867 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
7868 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
7869 (bsd_uthread_target): Delete function.
7870 (_initialize_bsd_uthread): Remove reference to
7871 complete_target_initialization.
7872
7873 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
7874 (target_bfd): ... this new class.
7875 (target_bfd_xfer_partial, target_bfd_get_section_table)
7876 (target_bfd_close): Refactor as target_bfd methods.
7877 (target_bfd::~target_bfd): New.
7878 (target_bfd_reopen): Adjust.
7879 (target_bfd::close): New.
7880
7881 * record-btrace.c (record_btrace_target): New class.
7882 (record_btrace_ops): Now a record_btrace_target.
7883 (record_btrace_open, record_btrace_stop_recording)
7884 (record_btrace_disconnect, record_btrace_close)
7885 (record_btrace_async, record_btrace_info)
7886 (record_btrace_insn_history, record_btrace_insn_history_range)
7887 (record_btrace_insn_history_from, record_btrace_call_history)
7888 (record_btrace_call_history_range)
7889 (record_btrace_call_history_from, record_btrace_record_method)
7890 (record_btrace_is_replaying, record_btrace_will_replay)
7891 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
7892 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
7893 (record_btrace_store_registers, record_btrace_prepare_to_store)
7894 (record_btrace_to_get_unwinder)
7895 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
7896 (record_btrace_commit_resume, record_btrace_wait)
7897 (record_btrace_stop, record_btrace_can_execute_reverse)
7898 (record_btrace_stopped_by_sw_breakpoint)
7899 (record_btrace_supports_stopped_by_sw_breakpoint)
7900 (record_btrace_stopped_by_hw_breakpoint)
7901 (record_btrace_supports_stopped_by_hw_breakpoint)
7902 (record_btrace_update_thread_list, record_btrace_thread_alive)
7903 (record_btrace_goto_begin, record_btrace_goto_end)
7904 (record_btrace_goto, record_btrace_stop_replaying_all)
7905 (record_btrace_execution_direction)
7906 (record_btrace_prepare_to_generate_core)
7907 (record_btrace_done_generating_core): Refactor as
7908 record_btrace_target methods.
7909 (init_record_btrace_ops): Delete.
7910 (_initialize_record_btrace): Remove reference to
7911 init_record_btrace_ops.
7912 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
7913 the execution_direction global.
7914 (record_full_base_target, record_full_target)
7915 (record_full_core_target): New classes.
7916 (record_full_ops): Now a record_full_target.
7917 (record_full_core_ops): Now a record_full_core_target.
7918 (record_full_target::detach, record_full_target::disconnect)
7919 (record_full_core_target::disconnect)
7920 (record_full_target::mourn_inferior, record_full_target::kill):
7921 New.
7922 (record_full_open, record_full_close, record_full_async): Refactor
7923 as methods of the record_full_base_target class.
7924 (record_full_resume, record_full_commit_resume): Refactor
7925 as methods of the record_full_target class.
7926 (record_full_wait, record_full_stopped_by_watchpoint)
7927 (record_full_stopped_data_address)
7928 (record_full_stopped_by_sw_breakpoint)
7929 (record_full_supports_stopped_by_sw_breakpoint)
7930 (record_full_stopped_by_hw_breakpoint)
7931 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
7932 methods of the record_full_base_target class.
7933 (record_full_store_registers, record_full_xfer_partial)
7934 (record_full_insert_breakpoint, record_full_remove_breakpoint):
7935 Refactor as methods of the record_full_target class.
7936 (record_full_can_execute_reverse, record_full_get_bookmark)
7937 (record_full_goto_bookmark, record_full_execution_direction)
7938 (record_full_record_method, record_full_info, record_full_delete)
7939 (record_full_is_replaying, record_full_will_replay)
7940 (record_full_goto_begin, record_full_goto_end, record_full_goto)
7941 (record_full_stop_replaying): Refactor as methods of the
7942 record_full_base_target class.
7943 (record_full_core_resume, record_full_core_kill)
7944 (record_full_core_fetch_registers)
7945 (record_full_core_prepare_to_store)
7946 (record_full_core_store_registers, record_full_core_xfer_partial)
7947 (record_full_core_insert_breakpoint)
7948 (record_full_core_remove_breakpoint)
7949 (record_full_core_has_execution): Refactor
7950 as methods of the record_full_core_target class.
7951 (record_full_base_target::supports_delete_record): New.
7952 (init_record_full_ops): Delete.
7953 (init_record_full_core_ops): Delete.
7954 (record_full_save): Refactor as method of the
7955 record_full_base_target class.
7956 (_initialize_record_full): Remove references to
7957 init_record_full_ops and init_record_full_core_ops.
7958
7959 * remote.c (remote_target, extended_remote_target): New classes.
7960 (remote_ops): Now a remote_target.
7961 (extended_remote_ops): Now an extended_remote_target.
7962 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
7963 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
7964 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
7965 (remote_pass_signals, remote_set_syscall_catchpoint)
7966 (remote_program_signals, )
7967 (remote_thread_always_alive): Remove target_ops parameter.
7968 (remote_thread_alive, remote_thread_name)
7969 (remote_update_thread_list, remote_threads_extra_info)
7970 (remote_static_tracepoint_marker_at)
7971 (remote_static_tracepoint_markers_by_strid)
7972 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
7973 (remote_open): Refactor as methods of remote_target.
7974 (extended_remote_open, extended_remote_detach)
7975 (extended_remote_attach, extended_remote_post_attach):
7976 (extended_remote_supports_disable_randomization)
7977 (extended_remote_create_inferior): : Refactor as method of
7978 extended_remote_target.
7979 (remote_set_permissions, remote_open_1, remote_detach)
7980 (remote_follow_fork, remote_follow_exec, remote_disconnect)
7981 (remote_resume, remote_commit_resume, remote_stop)
7982 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
7983 (remote_terminal_ours, remote_wait, remote_fetch_registers)
7984 (remote_prepare_to_store, remote_store_registers)
7985 (remote_flash_erase, remote_flash_done, remote_files_info)
7986 (remote_kill, remote_mourn, remote_insert_breakpoint)
7987 (remote_remove_breakpoint, remote_insert_watchpoint)
7988 (remote_watchpoint_addr_within_range)
7989 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
7990 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
7991 (remote_supports_stopped_by_sw_breakpoint)
7992 (remote_stopped_by_hw_breakpoint)
7993 (remote_supports_stopped_by_hw_breakpoint)
7994 (remote_stopped_by_watchpoint, remote_stopped_data_address)
7995 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
7996 (remote_verify_memory): Refactor as methods of remote_target.
7997 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
7998 parameter.
7999 (remote_xfer_partial, remote_get_memory_xfer_limit)
8000 (remote_search_memory, remote_rcmd, remote_memory_map)
8001 (remote_pid_to_str, remote_get_thread_local_address)
8002 (remote_get_tib_address, remote_read_description): Refactor as
8003 methods of remote_target.
8004 (remote_target::fileio_open, remote_target::fileio_pwrite)
8005 (remote_target::fileio_pread, remote_target::fileio_close): New.
8006 (remote_hostio_readlink, remote_hostio_fstat)
8007 (remote_filesystem_is_local, remote_can_execute_reverse)
8008 (remote_supports_non_stop, remote_supports_disable_randomization)
8009 (remote_supports_multi_process, remote_supports_cond_breakpoints)
8010 (remote_supports_enable_disable_tracepoint)
8011 (remote_supports_string_tracing)
8012 (remote_can_run_breakpoint_commands, remote_trace_init)
8013 (remote_download_tracepoint, remote_can_download_tracepoint)
8014 (remote_download_trace_state_variable, remote_enable_tracepoint)
8015 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
8016 (remote_trace_start, remote_get_trace_status)
8017 (remote_get_tracepoint_status, remote_trace_stop)
8018 (remote_trace_find, remote_get_trace_state_variable_value)
8019 (remote_save_trace_data, remote_get_raw_trace_data)
8020 (remote_set_disconnected_tracing, remote_core_of_thread)
8021 (remote_set_circular_trace_buffer, remote_traceframe_info)
8022 (remote_get_min_fast_tracepoint_insn_len)
8023 (remote_set_trace_buffer_size, remote_set_trace_notes)
8024 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
8025 (remote_disable_btrace, remote_teardown_btrace)
8026 (remote_read_btrace, remote_btrace_conf)
8027 (remote_augmented_libraries_svr4_read, remote_load)
8028 (remote_pid_to_exec_file, remote_can_do_single_step)
8029 (remote_execution_direction, remote_thread_handle_to_thread_info):
8030 Refactor as methods of remote_target.
8031 (init_remote_ops, init_extended_remote_ops): Delete.
8032 (remote_can_async_p, remote_is_async_p, remote_async)
8033 (remote_thread_events, remote_upload_tracepoints)
8034 (remote_upload_trace_state_variables): Refactor as methods of
8035 remote_target.
8036 (_initialize_remote): Remove references to init_remote_ops and
8037 init_extended_remote_ops.
8038
8039 * remote-sim.c (gdbsim_target): New class.
8040 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
8041 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
8042 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
8043 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
8044 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
8045 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
8046 Refactor as methods of gdbsim_target.
8047 (gdbsim_ops): Now a gdbsim_target.
8048 (init_gdbsim_ops): Delete.
8049 (gdbsim_cntrl_c): Adjust.
8050 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
8051
8052 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
8053 (the_amd64_linux_nat_target): New.
8054 (amd64_linux_fetch_inferior_registers)
8055 (amd64_linux_store_inferior_registers): Refactor as methods of
8056 amd64_linux_nat_target.
8057 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
8058 * i386-linux-nat.c: Don't include "linux-nat.h".
8059 (i386_linux_nat_target): New class.
8060 (the_i386_linux_nat_target): New.
8061 (i386_linux_fetch_inferior_registers)
8062 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
8063 as methods of i386_linux_nat_target.
8064 (_initialize_i386_linux_nat): Adjust. Set linux_target.
8065 * inf-child.c (inf_child_ops): Delete.
8066 (inf_child_fetch_inferior_registers)
8067 (inf_child_store_inferior_registers): Delete.
8068 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
8069 methods of inf_child_target.
8070 (inf_child_target::supports_terminal_ours)
8071 (inf_child_target::terminal_init)
8072 (inf_child_target::terminal_inferior)
8073 (inf_child_target::terminal_ours_for_output)
8074 (inf_child_target::terminal_ours, inf_child_target::interrupt)
8075 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
8076 New.
8077 (inf_child_open, inf_child_disconnect, inf_child_close)
8078 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
8079 (inf_child_post_startup_inferior, inf_child_can_run)
8080 (inf_child_pid_to_exec_file): Refactor as methods of
8081 inf_child_target.
8082 (inf_child_follow_fork): Delete.
8083 (inf_child_target::can_create_inferior)
8084 (inf_child_target::can_attach): New.
8085 (inf_child_target::has_all_memory, inf_child_target::has_memory)
8086 (inf_child_target::has_stack, inf_child_target::has_registers)
8087 (inf_child_target::has_execution): New.
8088 (inf_child_fileio_open, inf_child_fileio_pwrite)
8089 (inf_child_fileio_pread, inf_child_fileio_fstat)
8090 (inf_child_fileio_close, inf_child_fileio_unlink)
8091 (inf_child_fileio_readlink, inf_child_use_agent)
8092 (inf_child_can_use_agent): Refactor as methods of
8093 inf_child_target.
8094 (return_zero, inf_child_target): Delete.
8095 (inf_child_target::inf_child_target): New.
8096 * inf-child.h: Include "target.h".
8097 (inf_child_target): Delete function prototype.
8098 (inf_child_target): New class.
8099 (inf_child_open_target, inf_child_mourn_inferior)
8100 (inf_child_maybe_unpush_target): Delete.
8101 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
8102 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
8103 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
8104 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
8105 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
8106 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
8107 (inf_ptrace_wait, inf_ptrace_xfer_partial)
8108 (inf_ptrace_thread_alive, inf_ptrace_files_info)
8109 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
8110 methods of inf_ptrace_target.
8111 (inf_ptrace_target): Delete function.
8112 * inf-ptrace.h: Include "inf-child.h".
8113 (inf_ptrace_target): Delete function declaration.
8114 (inf_ptrace_target): New class.
8115 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
8116 * linux-nat.c (linux_target): New.
8117 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
8118 (linux_nat_target::~linux_nat_target): New.
8119 (linux_child_post_attach, linux_child_post_startup_inferior)
8120 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
8121 (linux_child_remove_fork_catchpoint)
8122 (linux_child_insert_vfork_catchpoint)
8123 (linux_child_remove_vfork_catchpoint)
8124 (linux_child_insert_exec_catchpoint)
8125 (linux_child_remove_exec_catchpoint)
8126 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
8127 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
8128 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
8129 (linux_nat_stopped_data_address)
8130 (linux_nat_stopped_by_sw_breakpoint)
8131 (linux_nat_supports_stopped_by_sw_breakpoint)
8132 (linux_nat_stopped_by_hw_breakpoint)
8133 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
8134 (linux_nat_kill, linux_nat_mourn_inferior)
8135 (linux_nat_xfer_partial, linux_nat_thread_alive)
8136 (linux_nat_update_thread_list, linux_nat_pid_to_str)
8137 (linux_nat_thread_name, linux_child_pid_to_exec_file)
8138 (linux_child_static_tracepoint_markers_by_strid)
8139 (linux_nat_is_async_p, linux_nat_can_async_p)
8140 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
8141 (linux_nat_supports_multi_process)
8142 (linux_nat_supports_disable_randomization, linux_nat_async)
8143 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
8144 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
8145 (linux_nat_fileio_open, linux_nat_fileio_readlink)
8146 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
8147 methods of linux_nat_target.
8148 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
8149 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
8150 parameter.
8151 (check_stopped_by_watchpoint): Adjust.
8152 (linux_xfer_partial): Delete.
8153 (linux_target_install_ops, linux_target, linux_nat_add_target):
8154 Delete.
8155 (linux_nat_target::linux_nat_target): New.
8156 * linux-nat.h: Include "inf-ptrace.h".
8157 (linux_nat_target): New.
8158 (linux_target, linux_target_install_ops, linux_nat_add_target):
8159 Delete function declarations.
8160 (linux_target): Declare global.
8161 * linux-thread-db.c (thread_db_target): New.
8162 (thread_db_target::thread_db_target): New.
8163 (thread_db_ops): Delete.
8164 (the_thread_db_target): New.
8165 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
8166 (thread_db_update_thread_list, thread_db_pid_to_str)
8167 (thread_db_extra_thread_info)
8168 (thread_db_thread_handle_to_thread_info)
8169 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
8170 (thread_db_resume): Refactor as methods of thread_db_target.
8171 (init_thread_db_ops): Delete.
8172 (_initialize_thread_db): Remove reference to init_thread_db_ops.
8173 * x86-linux-nat.c: Don't include "linux-nat.h".
8174 (super_post_startup_inferior): Delete.
8175 (x86_linux_nat_target::~x86_linux_nat_target): New.
8176 (x86_linux_child_post_startup_inferior)
8177 (x86_linux_read_description, x86_linux_enable_btrace)
8178 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
8179 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
8180 methods of x86_linux_nat_target.
8181 (x86_linux_create_target): Delete. Bits folded ...
8182 (x86_linux_add_target): ... here. Now takes a linux_nat_target
8183 pointer.
8184 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
8185 (x86_linux_nat_target): New class.
8186 (x86_linux_create_target): Delete.
8187 (x86_linux_add_target): Now takes a linux_nat_target pointer.
8188 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
8189 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
8190 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
8191 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
8192 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
8193 make extern.
8194 (x86_use_watchpoints): Delete.
8195 * x86-nat.h: Include "breakpoint.h" and "target.h".
8196 (x86_use_watchpoints): Delete.
8197 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
8198 (x86_stopped_by_watchpoint, x86_stopped_data_address)
8199 (x86_insert_watchpoint, x86_remove_watchpoint)
8200 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
8201 (x86_stopped_by_hw_breakpoint): New declarations.
8202 (x86_nat_target): New template class.
8203
8204 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
8205 (the_ppc_linux_nat_target): New.
8206 (ppc_linux_fetch_inferior_registers)
8207 (ppc_linux_can_use_hw_breakpoint)
8208 (ppc_linux_region_ok_for_hw_watchpoint)
8209 (ppc_linux_ranged_break_num_registers)
8210 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
8211 (ppc_linux_insert_mask_watchpoint)
8212 (ppc_linux_remove_mask_watchpoint)
8213 (ppc_linux_can_accel_watchpoint_condition)
8214 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
8215 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
8216 (ppc_linux_watchpoint_addr_within_range)
8217 (ppc_linux_masked_watch_num_registers)
8218 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
8219 (ppc_linux_read_description): Refactor as methods of
8220 ppc_linux_nat_target.
8221 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
8222
8223 * procfs.c (procfs_xfer_partial): Delete forward declaration.
8224 (procfs_target): New class.
8225 (the_procfs_target): New.
8226 (procfs_target): Delete function.
8227 (procfs_auxv_parse, procfs_attach, procfs_detach)
8228 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
8229 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
8230 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
8231 (procfs_create_inferior, procfs_update_thread_list)
8232 (procfs_thread_alive, procfs_pid_to_str)
8233 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
8234 (procfs_stopped_data_address, procfs_insert_watchpoint)
8235 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
8236 (proc_find_memory_regions, procfs_info_proc)
8237 (procfs_make_note_section): Refactor as methods of procfs_target.
8238 (_initialize_procfs): Adjust.
8239 * sol-thread.c (sol_thread_target): New class.
8240 (sol_thread_ops): Now a sol_thread_target.
8241 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
8242 (sol_thread_fetch_registers, sol_thread_store_registers)
8243 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
8244 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
8245 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
8246 (init_sol_thread_ops): Delete.
8247 (_initialize_sol_thread): Adjust. Remove references to
8248 init_sol_thread_ops and complete_target_initialization.
8249
8250 * windows-nat.c (windows_nat_target): New class.
8251 (windows_fetch_inferior_registers)
8252 (windows_store_inferior_registers, windows_resume, windows_wait)
8253 (windows_attach, windows_detach, windows_pid_to_exec_file)
8254 (windows_files_info, windows_create_inferior)
8255 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
8256 (windows_close, windows_pid_to_str, windows_xfer_partial)
8257 (windows_get_tib_address, windows_get_ada_task_ptid)
8258 (windows_thread_name, windows_thread_alive): Refactor as
8259 windows_nat_target methods.
8260 (do_initial_windows_stuff): Adjust.
8261 (windows_target): Delete function.
8262 (_initialize_windows_nat): Adjust.
8263
8264 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
8265 (darwin_mourn_inferior, darwin_kill_inferior)
8266 (darwin_create_inferior, darwin_attach, darwin_detach)
8267 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
8268 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
8269 (darwin_supports_multi_process): Refactor as darwin_nat_target
8270 methods.
8271 (darwin_resume_to, darwin_files_info): Delete.
8272 (_initialize_darwin_inferior): Rename to ...
8273 (_initialize_darwin_nat): ... this. Adjust to C++ification.
8274 * darwin-nat.h: Include "inf-child.h".
8275 (darwin_nat_target): New class.
8276 (darwin_complete_target): Delete.
8277 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
8278 (darwin_target): New.
8279 (i386_darwin_fetch_inferior_registers)
8280 (i386_darwin_store_inferior_registers): Refactor as methods of
8281 darwin_nat_target.
8282 (darwin_complete_target): Delete, with ...
8283 (_initialize_i386_darwin_nat): ... bits factored out here.
8284
8285 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
8286 (the_alpha_linux_nat_target): New.
8287 (alpha_linux_register_u_offset): Refactor as
8288 alpha_linux_nat_target method.
8289 (_initialize_alpha_linux_nat): Adjust.
8290 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
8291 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8292 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
8293 methods of linux_nat_trad_target.
8294 (linux_trad_target): Delete.
8295 * linux-nat-trad.h (linux_trad_target): Delete function.
8296 (linux_nat_trad_target): New class.
8297 * mips-linux-nat.c (mips_linux_nat_target): New class.
8298 (super_fetch_registers, super_store_registers, super_close):
8299 Delete.
8300 (the_mips_linux_nat_target): New.
8301 (mips64_linux_regsets_fetch_registers)
8302 (mips64_linux_regsets_store_registers)
8303 (mips64_linux_fetch_registers, mips64_linux_store_registers)
8304 (mips_linux_register_u_offset, mips_linux_read_description)
8305 (mips_linux_can_use_hw_breakpoint)
8306 (mips_linux_stopped_by_watchpoint)
8307 (mips_linux_stopped_data_address)
8308 (mips_linux_region_ok_for_hw_watchpoint)
8309 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
8310 (mips_linux_close): Refactor as methods of mips_linux_nat.
8311 (_initialize_mips_linux_nat): Adjust to C++ification.
8312
8313 * aix-thread.c (aix_thread_target): New class.
8314 (aix_thread_ops): Now an aix_thread_target.
8315 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
8316 (aix_thread_fetch_registers, aix_thread_store_registers)
8317 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
8318 (aix_thread_thread_alive, aix_thread_pid_to_str)
8319 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
8320 Refactor as methods of aix_thread_target.
8321 (init_aix_thread_ops): Delete.
8322 (_initialize_aix_thread): Remove references to init_aix_thread_ops
8323 and complete_target_initialization.
8324 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
8325 (rs6000_nat_target): New class.
8326 (the_rs6000_nat_target): New.
8327 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
8328 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
8329 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
8330 (super_create_inferior): Delete.
8331 (_initialize_rs6000_nat): Adjust to C++ification.
8332
8333 * arm-linux-nat.c (arm_linux_nat_target): New class.
8334 (the_arm_linux_nat_target): New.
8335 (arm_linux_fetch_inferior_registers)
8336 (arm_linux_store_inferior_registers, arm_linux_read_description)
8337 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
8338 (arm_linux_remove_hw_breakpoint)
8339 (arm_linux_region_ok_for_hw_watchpoint)
8340 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
8341 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
8342 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
8343 arm_linux_nat_target.
8344 (_initialize_arm_linux_nat): Adjust to C++ification.
8345
8346 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
8347 (the_aarch64_linux_nat_target): New.
8348 (aarch64_linux_fetch_inferior_registers)
8349 (aarch64_linux_store_inferior_registers)
8350 (aarch64_linux_child_post_startup_inferior)
8351 (aarch64_linux_read_description)
8352 (aarch64_linux_can_use_hw_breakpoint)
8353 (aarch64_linux_insert_hw_breakpoint)
8354 (aarch64_linux_remove_hw_breakpoint)
8355 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
8356 (aarch64_linux_region_ok_for_hw_watchpoint)
8357 (aarch64_linux_stopped_data_address)
8358 (aarch64_linux_stopped_by_watchpoint)
8359 (aarch64_linux_watchpoint_addr_within_range)
8360 (aarch64_linux_can_do_single_step): Refactor as methods of
8361 aarch64_linux_nat_target.
8362 (super_post_startup_inferior): Delete.
8363 (_initialize_aarch64_linux_nat): Adjust to C++ification.
8364
8365 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
8366 (the_hppa_linux_nat_target): New.
8367 (hppa_linux_fetch_inferior_registers)
8368 (hppa_linux_store_inferior_registers): Refactor as methods of
8369 hppa_linux_nat_target.
8370 (_initialize_hppa_linux_nat): Adjust to C++ification.
8371
8372 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
8373 (the_ia64_linux_nat_target): New.
8374 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
8375 (ia64_linux_stopped_data_address)
8376 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
8377 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
8378 ia64_linux_nat_target methods.
8379 (super_xfer_partial): Delete.
8380 (_initialize_ia64_linux_nat): Adjust to C++ification.
8381
8382 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
8383 (the_m32r_linux_nat_target): New.
8384 (m32r_linux_fetch_inferior_registers)
8385 (m32r_linux_store_inferior_registers): Refactor as
8386 m32r_linux_nat_target methods.
8387 (_initialize_m32r_linux_nat): Adjust to C++ification.
8388
8389 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
8390 (the_m68k_linux_nat_target): New.
8391 (m68k_linux_fetch_inferior_registers)
8392 (m68k_linux_store_inferior_registers): Refactor as
8393 m68k_linux_nat_target methods.
8394 (_initialize_m68k_linux_nat): Adjust to C++ification.
8395
8396 * s390-linux-nat.c (s390_linux_nat_target): New class.
8397 (the_s390_linux_nat_target): New.
8398 (s390_linux_fetch_inferior_registers)
8399 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
8400 (s390_insert_watchpoint, s390_remove_watchpoint)
8401 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
8402 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
8403 (s390_auxv_parse, s390_read_description): Refactor as methods of
8404 s390_linux_nat_target.
8405 (_initialize_s390_nat): Adjust to C++ification.
8406
8407 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
8408 (the_sparc_linux_nat_target): New.
8409 (_initialize_sparc_linux_nat): Adjust to C++ification.
8410 * sparc-nat.c (sparc_fetch_inferior_registers)
8411 (sparc_store_inferior_registers): Remove target_ops parameter.
8412 * sparc-nat.h (sparc_fetch_inferior_registers)
8413 (sparc_store_inferior_registers): Remove target_ops parameter.
8414 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
8415 (the_sparc64_linux_nat_target): New.
8416 (_initialize_sparc64_linux_nat): Adjust to C++ification.
8417
8418 * spu-linux-nat.c (spu_linux_nat_target): New class.
8419 (the_spu_linux_nat_target): New.
8420 (spu_child_post_startup_inferior, spu_child_post_attach)
8421 (spu_child_wait, spu_fetch_inferior_registers)
8422 (spu_store_inferior_registers, spu_xfer_partial)
8423 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
8424 methods.
8425 (_initialize_spu_nat): Adjust to C++ification.
8426
8427 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
8428 (the_tilegx_linux_nat_target): New.
8429 (fetch_inferior_registers, store_inferior_registers):
8430 Refactor as methods.
8431 (_initialize_tile_linux_nat): Adjust to C++ification.
8432
8433 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
8434 (the_xtensa_linux_nat_target): New.
8435 (xtensa_linux_fetch_inferior_registers)
8436 (xtensa_linux_store_inferior_registers): Refactor as
8437 xtensa_linux_nat_target methods.
8438 (_initialize_xtensa_linux_nat): Adjust to C++ification.
8439
8440 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
8441 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
8442 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
8443 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
8444 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
8445 (fbsd_stopped_by_sw_breakpoint)
8446 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
8447 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
8448 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
8449 (fbsd_post_startup_inferior, fbsd_post_attach)
8450 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
8451 (fbsd_set_syscall_catchpoint)
8452 (super_xfer_partial, super_resume, super_wait)
8453 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
8454 (fbsd_handle_debug_trap): Remove target_ops parameter.
8455 (fbsd_nat_add_target): Delete.
8456 * fbsd-nat.h: Include "inf-ptrace.h".
8457 (fbsd_nat_add_target): Delete.
8458 (USE_SIGTRAP_SIGINFO): Define.
8459 (fbsd_nat_target): New class.
8460
8461 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
8462 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
8463 (amd64bsd_target): Delete.
8464 * amd64-bsd-nat.h: New file.
8465 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
8466 "x86-bsd-nat.h".
8467 (amd64_fbsd_nat_target): New class.
8468 (the_amd64_fbsd_nat_target): New.
8469 (amd64fbsd_read_description): Refactor as method of
8470 amd64_fbsd_nat_target.
8471 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8472 (_initialize_amd64fbsd_nat): Adjust to C++ification.
8473 * amd64-nat.h (amd64bsd_target): Delete function declaration.
8474 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
8475 (i386bsd_store_inferior_registers): Remove target_ops parameter.
8476 (i386bsd_target): Delete.
8477 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
8478 (i386bsd_fetch_inferior_registers)
8479 (i386bsd_store_inferior_registers): Declare.
8480 (i386_bsd_nat_target): New class.
8481 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
8482 (the_i386_fbsd_nat_target): New.
8483 (i386fbsd_resume, i386fbsd_read_description): Refactor as
8484 i386_fbsd_nat_target methods.
8485 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8486 (_initialize_i386fbsd_nat): Adjust to C++ification.
8487 * x86-bsd-nat.c (super_mourn_inferior): Delete.
8488 (x86bsd_mourn_inferior, x86bsd_target): Delete.
8489 (_initialize_x86_bsd_nat): Adjust to C++ification.
8490 * x86-bsd-nat.h: Include "x86-nat.h".
8491 (x86bsd_target): Delete declaration.
8492 (x86bsd_nat_target): New class.
8493
8494 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
8495 (the_aarch64_fbsd_nat_target): New.
8496 (aarch64_fbsd_fetch_inferior_registers)
8497 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
8498 aarch64_fbsd_nat_target.
8499 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
8500 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
8501 (the_alpha_bsd_nat_target): New.
8502 (alphabsd_fetch_inferior_registers)
8503 (alphabsd_store_inferior_registers): Refactor as
8504 alpha_bsd_nat_target methods.
8505 (_initialize_alphabsd_nat): Refactor as methods of
8506 alpha_bsd_nat_target.
8507 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
8508 (the_amd64_nbsd_nat_target): New.
8509 (_initialize_amd64nbsd_nat): Adjust to C++ification.
8510 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
8511 (the_amd64_obsd_nat_target): New.
8512 (_initialize_amd64obsd_nat): Adjust to C++ification.
8513 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
8514 (the_arm_fbsd_nat_target): New.
8515 (arm_fbsd_fetch_inferior_registers)
8516 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
8517 (_initialize_arm_fbsd_nat): Refactor as methods of
8518 arm_fbsd_nat_target.
8519 (_initialize_arm_fbsd_nat): Adjust to C++ification.
8520 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
8521 (the_arm_netbsd_nat_target): New.
8522 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
8523 arm_netbsd_nat_target.
8524 (_initialize_arm_netbsd_nat): Adjust to C++ification.
8525 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
8526 (the_hppa_nbsd_nat_target): New.
8527 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
8528 hppa_nbsd_nat_target methods.
8529 (_initialize_hppanbsd_nat): Adjust to C++ification.
8530 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
8531 (the_hppa_obsd_nat_target): New.
8532 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
8533 methods of hppa_obsd_nat_target.
8534 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
8535 add_target.
8536 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
8537 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
8538 add_target.
8539 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
8540 (_initialize_i386obsd_nat): Use add_target.
8541 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
8542 (the_m68k_bsd_nat_target): New.
8543 (m68kbsd_fetch_inferior_registers)
8544 (m68kbsd_store_inferior_registers): Refactor as methods of
8545 m68k_bsd_nat_target.
8546 (_initialize_m68kbsd_nat): Adjust to C++ification.
8547 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
8548 (the_mips_fbsd_nat_target): New.
8549 (mips_fbsd_fetch_inferior_registers)
8550 (mips_fbsd_store_inferior_registers): Refactor as methods of
8551 mips_fbsd_nat_target.
8552 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
8553 add_target.
8554 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
8555 (the_mips_nbsd_nat_target): New.
8556 (mipsnbsd_fetch_inferior_registers)
8557 (mipsnbsd_store_inferior_registers): Refactor as methods of
8558 mips_nbsd_nat_target.
8559 (_initialize_mipsnbsd_nat): Adjust to C++ification.
8560 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
8561 (the_mips64_obsd_nat_target): New.
8562 (mips64obsd_fetch_inferior_registers)
8563 (mips64obsd_store_inferior_registers): Refactor as methods of
8564 mips64_obsd_nat_target.
8565 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
8566 add_target.
8567 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
8568 nbsd_nat_target.
8569 * nbsd-nat.h: Include "inf-ptrace.h".
8570 (nbsd_nat_target): New class.
8571 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
8572 (obsd_wait): Refactor as methods of obsd_nat_target.
8573 (obsd_add_target): Delete.
8574 * obsd-nat.h: Include "inf-ptrace.h".
8575 (obsd_nat_target): New class.
8576 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
8577 (the_ppc_fbsd_nat_target): New.
8578 (ppcfbsd_fetch_inferior_registers)
8579 (ppcfbsd_store_inferior_registers): Refactor as methods of
8580 ppc_fbsd_nat_target.
8581 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
8582 add_target.
8583 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
8584 (the_ppc_nbsd_nat_target): New.
8585 (ppcnbsd_fetch_inferior_registers)
8586 (ppcnbsd_store_inferior_registers): Refactor as methods of
8587 ppc_nbsd_nat_target.
8588 (_initialize_ppcnbsd_nat): Adjust to C++ification.
8589 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
8590 (the_ppc_obsd_nat_target): New.
8591 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
8592 methods of ppc_obsd_nat_target.
8593 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
8594 add_target.
8595 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
8596 (the_sh_nbsd_nat_target): New.
8597 (shnbsd_fetch_inferior_registers)
8598 (shnbsd_store_inferior_registers): Refactor as methods of
8599 sh_nbsd_nat_target.
8600 (_initialize_shnbsd_nat): Adjust to C++ification.
8601 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
8602 (inf_ptrace_xfer_partial): Delete.
8603 (sparc_xfer_partial, sparc_target): Delete.
8604 * sparc-nat.h (sparc_fetch_inferior_registers)
8605 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
8606 (sparc_target): Delete function declaration.
8607 (sparc_target): New template class.
8608 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
8609 (_initialize_sparcnbsd_nat): Adjust to C++ification.
8610 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
8611 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
8612 add_target.
8613 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
8614 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
8615 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
8616 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
8617 add_target.
8618 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
8619 (the_vax_bsd_nat_target): New.
8620 (vaxbsd_fetch_inferior_registers)
8621 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
8622 methods.
8623 (_initialize_vaxbsd_nat): Adjust to C++ification.
8624
8625 * bsd-kvm.c (bsd_kvm_target): New class.
8626 (bsd_kvm_ops): Now a bsd_kvm_target.
8627 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
8628 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
8629 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
8630 bsd_kvm_target.
8631 (bsd_kvm_return_one): Delete.
8632 (bsd_kvm_add_target): Adjust to C++ification.
8633
8634 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
8635 (nto_procfs_target_procfs): New classes.
8636 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
8637 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
8638 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
8639 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
8640 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
8641 (procfs_remove_hw_breakpoint, procfs_resume)
8642 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
8643 (procfs_kill_inferior, procfs_store_registers)
8644 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
8645 as methods of nto_procfs_target.
8646 (nto_procfs_ops): Now an nto_procfs_target_procfs.
8647 (nto_native_ops): Delete.
8648 (procfs_open, procfs_native_open): Delete.
8649 (nto_native_ops): Now an nto_procfs_target_native.
8650 (init_procfs_targets): Adjust to C++ification.
8651 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
8652 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
8653 Refactor as methods of nto_procfs_target.
8654
8655 * go32-nat.c (go32_nat_target): New class.
8656 (the_go32_nat_target): New.
8657 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
8658 (go32_store_registers, go32_xfer_partial, go32_files_info)
8659 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
8660 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
8661 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
8662 (go32_pid_to_str): Refactor as methods of go32_nat_target.
8663 (go32_target): Delete.
8664 (_initialize_go32_nat): Adjust to C++ification.
8665
8666 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
8667 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
8668 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
8669 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
8670 gnu_nat_target.
8671 (gnu_target): Delete.
8672 * gnu-nat.h (gnu_target): Delete.
8673 (gnu_nat_target): New class.
8674 * i386-gnu-nat.c (gnu_base_target): New.
8675 (i386_gnu_nat_target): New class.
8676 (the_i386_gnu_nat_target): New.
8677 (_initialize_i386gnu_nat): Adjust to C++ification.
8678
8679 2018-05-02 Pedro Alves <palves@redhat.com>
8680
8681 * bfd-target.c (target_bfd_xclose): Rename to ...
8682 (target_bfd_close): ... this.
8683 (target_bfd_reopen): Adjust.
8684 * target.c (target_close): Remove references to to_xclose.
8685 * target.h (target_ops::to_xclose): Delete.
8686 (target_ops::to_close): Update comments.
8687
8688 2018-05-02 Pedro Alves <palves@redhat.com>
8689
8690 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
8691 "linux-nat.h".
8692 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
8693 * inf-ptrace.c (inf_ptrace_register_u_offset)
8694 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8695 (inf_ptrace_store_register, inf_ptrace_store_registers)
8696 (inf_ptrace_trad_target): Move to ...
8697 * linux-nat-trad.c: ... this new file.
8698 * linux-nat-trad.h: New file.
8699 * linux-nat.c (linux_target_install_ops): Make extern.
8700 (linux_trad_target): Delete.
8701 * linux-nat.h (linux_trad_target): Delete declaration.
8702 (linux_target_install_ops): Declare.
8703 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
8704 "linux-nat.h".
8705
8706 2018-05-02 Pedro Alves <palves@redhat.com>
8707
8708 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8709 procfs_target/add_target here.
8710 * procfs.c (procfs_target): Make static.
8711 (_initialize_procfs): Call add_target here.
8712 * procfs.h (struct target_ops): Remove forward declaration.
8713 (procfs_target): Remove declaration.
8714 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
8715
8716 2018-05-02 Pedro Alves <palves@redhat.com>
8717
8718 * procfs.c (procfs_stopped_by_watchpoint)
8719 (procfs_insert_watchpoint, procfs_remove_watchpoint)
8720 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
8721 Forward declare.
8722 (procfs_use_watchpoints): Delete, move contents...
8723 (procfs_target): ... here.
8724 * procfs.h (procfs_use_watchpoints): Delete declaration.
8725 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8726 procfs_use_watchpoints.
8727 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
8728 procfs_use_watchpoints.
8729
8730 2018-05-02 Tom Tromey <tom@tromey.com>
8731
8732 PR python/20084:
8733 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
8734 and var_zuinteger_unlimited.
8735 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
8736 and PARAM_ZUINTEGER_UNLIMITED.
8737 (set_parameter_value): Handle var_zuinteger and
8738 var_zuinteger_unlimited.
8739 (add_setshow_generic): Likewise.
8740 (parmpy_init): Likewise.
8741
8742 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
8743
8744 PR rust/23124
8745 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
8746 pointer is not null before dereferencing it.
8747
8748 2018-04-30 Tom Tromey <tom@tromey.com>
8749
8750 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
8751 is_mi_like_p.
8752
8753 2018-04-30 Tom Tromey <tom@tromey.com>
8754
8755 * breakpoint.c (mention): Remove use of is_mi_like_p.
8756 (print_mention_ranged_breakpoint): Likewise.
8757 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
8758 of is_mi_like_p.
8759
8760 2018-04-30 Tom Tromey <tom@tromey.com>
8761
8762 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
8763
8764 2018-04-30 Tom Tromey <tom@tromey.com>
8765
8766 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
8767 (info_spu_event_command): Remove some uses of is_mi_like_p.
8768
8769 2018-04-30 Tom Tromey <tom@tromey.com>
8770
8771 * python/py-framefilter.c (py_print_single_arg)
8772 (enumerate_locals, py_print_args, py_print_frame): Remove some
8773 uses of is_mi_like_p.
8774
8775 2018-04-30 Tom Tromey <tom@tromey.com>
8776
8777 * ui-out.c: Update.
8778 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
8779 * ui-out.h (ui_out::is_mi_like_p): Now const.
8780 (ui_out::do_is_mi_like_p): Now const.
8781 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
8782
8783 2018-04-30 Tom Tromey <tom@tromey.com>
8784
8785 * varobj.c (varobj_set_visualizer): Use new_reference.
8786 * python/python.c (gdbpy_decode_line): Use new_reference.
8787 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
8788 new_reference.
8789
8790 2018-04-30 Tom Tromey <tom@tromey.com>
8791
8792 * varobj.c (install_new_value): Use new_reference.
8793 * value.h (value_incref): Return void. Swap intro comment with
8794 value_decref.
8795 * value.c (set_value_parent): Use new_reference.
8796 (value_incref): Return void. Update intro comment.
8797 (release_value): Use new_reference.
8798 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
8799
8800 2018-04-30 Tom Tromey <tom@tromey.com>
8801
8802 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
8803 * gdb_bfd.h (new_bfd_ref): Remove.
8804 (gdb_bfd_open): Update comment.
8805 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
8806 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
8807 (gdb_bfd_fdopenr): Use new_reference.
8808 * exec.c (exec_file_attach): Use new_reference.
8809
8810 2018-04-30 Tom Tromey <tom@tromey.com>
8811
8812 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
8813 method.
8814
8815 2018-04-30 Tom Tromey <tom@tromey.com>
8816
8817 * jit.c (jit_read_code_entry): Use type_align.
8818 * i386-tdep.c (i386_gdbarch_init): Don't call
8819 set_gdbarch_long_long_align_bit.
8820 * gdbarch.sh: Remove long_long_align_bit.
8821 * gdbarch.c, gdbarch.h: Rebuild.
8822 * arc-tdep.c (arc_type_align): New function.
8823 (arc_gdbarch_init): Use arc_type_align. Don't call
8824 set_gdbarch_long_long_align_bit.
8825
8826 2018-04-30 Tom Tromey <tom@tromey.com>
8827
8828 * rust-lang.c (rust_type_alignment): Remove.
8829 (rust_composite_type): Use type_align.
8830
8831 2018-04-30 Tom Tromey <tom@tromey.com>
8832
8833 * NEWS: Mention Type.align.
8834 * python/py-type.c (typy_get_alignof): New function.
8835 (type_object_getset): Add "alignof".
8836
8837 2018-04-30 Tom Tromey <tom@tromey.com>
8838
8839 PR exp/17095:
8840 * NEWS: Update.
8841 * std-operator.def (UNOP_ALIGNOF): New operator.
8842 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
8843 New.
8844 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
8845 * c-lang.c (c_op_print_tab): Add alignof.
8846 * c-exp.y (ALIGNOF): New token.
8847 (exp): Add "ALIGNOF" production.
8848 (ident_tokens): Add _Alignof and alignof.
8849
8850 2018-04-30 Tom Tromey <tom@tromey.com>
8851
8852 * i386-tdep.c (i386_type_align): New function.
8853 (i386_gdbarch_init): Update.
8854 * gdbarch.sh (type_align): New method.
8855 * gdbarch.c, gdbarch.h: Rebuild.
8856 * arch-utils.h (default_type_align): Declare.
8857 * arch-utils.c (default_type_align): New function.
8858 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
8859 (struct type) <align_log2>: New field.
8860 <instance_flags>: Now a bitfield.
8861 (TYPE_RAW_ALIGN): New macro.
8862 (type_align, type_raw_align, set_type_align): Declare.
8863 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
8864 functions.
8865 * dwarf2read.c (quirk_rust_enum): Set type alignment.
8866 (get_alignment, maybe_set_alignment): New functions.
8867 (read_structure_type, read_enumeration_type, read_array_type)
8868 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
8869 (read_subrange_type, read_base_type): Set type alignment.
8870
8871 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
8872
8873 * dwarf2read.c (read_index_from_section): Use bool.
8874
8875 2018-04-29 Fabian Groffen <grobian@gentoo.org>
8876
8877 PR gdb/22950
8878 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
8879 with #ifdef.
8880
8881 2018-04-29 John Reiser <jreiser@BitWagon.com>
8882
8883 PR build/22873
8884 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
8885 last step, and do it atomically.
8886
8887 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
8888
8889 * compile/compile-c-types.c (convert_int, convert_float):
8890 Update for C FE v1.
8891
8892 2018-04-27 Tom Tromey <tom@tromey.com>
8893
8894 PR rust/22545:
8895 * rust-lang.c (rust_inclusive_range_type_p): New function.
8896 (rust_range): Handle inclusive ranges.
8897 (rust_compute_range): Likewise.
8898 * rust-exp.y (struct rust_op) <inclusive>: New field.
8899 (DOTDOTEQ): New constant.
8900 (range_expr): Add "..=" productions.
8901 (operator_tokens): Add "..=" token.
8902 (ast_range): Add "inclusive" parameter.
8903 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
8904 ranges.
8905 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
8906 bounds values.
8907 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
8908 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
8909 Update comments.
8910 * expprint.c (print_subexp_standard): Handle new bounds values.
8911 (dump_subexp_body_standard): Likewise.
8912
8913 2018-04-27 Tom Tromey <tom@tromey.com>
8914
8915 * configure: Rebuild.
8916 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
8917 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
8918 "OVERRIDE".
8919 (class symbol_needs_eval_context): Likewise.
8920 * dwarf2read.c (mock_mapped_index::symbol_name_count)
8921 (mock_mapped_index::symbol_name_at): Use "override". Remove
8922 "virtual".
8923 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
8924 "override".
8925 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
8926 * aarch64-tdep.c (instruction_reader::read): Use "override".
8927 (instruction_reader_test::read): Likewise.
8928 * arm-tdep.c (instruction_reader::read): Use "override".
8929 (instruction_reader_thumb::read): Likewise.
8930
8931 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
8932
8933 PR remote/9665
8934 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
8935 instead of remote_send.
8936 (remote_send): Remove.
8937
8938 2018-04-26 Pedro Alves <palves@redhat.com>
8939
8940 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
8941 find_function_start_sal instead of find_pc_line.
8942
8943 2018-04-26 Pedro Alves <palves@redhat.com>
8944
8945 * breakpoint.c (set_breakpoint_location_function): Handle
8946 mst_data_gnu_ifunc.
8947 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
8948 * elfread.c (elf_symtab_read): Give data symbols with
8949 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
8950 (elf_rel_plt_read): Update comment.
8951 * linespec.c (convert_linespec_to_sals): Handle
8952 mst_data_gnu_ifunc.
8953 (minsym_found): Handle mst_data_gnu_ifunc.
8954 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
8955 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
8956 * parse.c (find_minsym_type_and_address): Handle
8957 mst_data_gnu_ifunc.
8958 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
8959 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
8960 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
8961 comment.
8962 <mst_data_gnu_ifunc>: New enumerator.
8963
8964 2018-04-26 Pedro Alves <palves@redhat.com>
8965
8966 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
8967 (lookup_minimal_symbol_by_pc_section): ... this. Replace
8968 'want_trampoline' parameter by a lookup_msym_prefer parameter.
8969 Handle it.
8970 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
8971 (lookup_minimal_symbol_by_pc): Adjust.
8972 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
8973 (lookup_solib_trampoline_symbol_by_pc): Adjust.
8974 * minsyms.h (lookup_msym_prefer): New enum.
8975 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
8976 parameter by a lookup_msym_prefer parameter.
8977
8978 2018-04-26 Pedro Alves <palves@redhat.com>
8979
8980 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
8981 ends in "@plt" instead of looking at the symbol's section.
8982
8983 2018-04-26 Pedro Alves <palves@redhat.com>
8984
8985 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
8986 all references.
8987 (find_pc_partial_function_gnu_ifunc): Rename to ...
8988 (find_pc_partial_function): ... this, and remove references to
8989 'is_gnu_ifunc_p'.
8990 (find_pc_partial_function): Delete old implementation.
8991 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
8992
8993 2018-04-26 Pedro Alves <palves@redhat.com>
8994
8995 * linespec.c (struct bound_minimal_symbol_search_key): New.
8996 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
8997 skip first line if we found a GNU ifunc minimal symbol by name.
8998 (compare_msymbols): Change parameters to work with a destructured
8999 lhs minsym.
9000 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
9001 functions.
9002
9003 2018-04-26 Pedro Alves <palves@redhat.com>
9004
9005 * breakpoint.c (set_breakpoint_location_function): Don't resolve
9006 ifunc targets here. Instead, if we have an ifunc minsym, use its
9007 address/name.
9008 (add_location_to_breakpoint): Store the minsym and the objfile in
9009 the breakpoint location.
9010 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
9011 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
9012 Record the minsym in the sal.
9013 * symtab.h (symtab_and_line) <msymbol>: New field.
9014
9015 2018-04-26 Pedro Alves <palves@redhat.com>
9016
9017 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
9018 unless we actually resolved the ifunc.
9019
9020 2018-04-26 Pedro Alves <palves@redhat.com>
9021
9022 * c-exp.y (variable production): Prefer ifunc minsyms over
9023 regular function symbols.
9024 * symtab.c (find_gnu_ifunc): New function.
9025 * minsyms.h (lookup_msym_prefer): New enum.
9026 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
9027 parameter by a lookup_msym_prefer parameter.
9028 * symtab.h (find_gnu_ifunc): New declaration.
9029
9030 2018-04-26 Pedro Alves <palves@redhat.com>
9031
9032 * blockframe.c (find_gnu_ifunc_target_type): New function.
9033 (find_function_type): New.
9034 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
9035 return a value with a memory address.
9036 (eval_call): For calls to GNU ifunc functions, try to find the
9037 type of the target function from the type that the resolver
9038 returns.
9039 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
9040 symbols.
9041 * infcall.c (find_function_return_type): Delete.
9042 (find_function_addr): Add 'function_type' parameter. For calls to
9043 GNU ifunc functions, try to find the type of the target function
9044 from the type that the resolver returns, and return it via
9045 FUNCTION_TYPE.
9046 (call_function_by_hand_dummy): Adjust to use the function type
9047 returned by find_function_addr.
9048 (find_function_addr): Add 'function_type' parameter and move
9049 description here.
9050 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
9051 declarations.
9052
9053 2018-04-26 Pedro Alves <palves@redhat.com>
9054
9055 * c-exp.y (variable production): Skip finding an alias for ifunc
9056 symbols.
9057
9058 2018-04-26 Pedro Alves <palves@redhat.com>
9059
9060 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
9061
9062 2018-04-25 Pedro Alves <palves@redhat.com>
9063
9064 * infcmd.c (kill_command): Print the pid as string, not the whole
9065 thread's ptid. Add comment. s/has been killed/killed/ in output
9066 message.
9067 * remote.c (remote_detach_1): Print the pid as string, not the
9068 whole thread's ptid.
9069
9070 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9071 Sergio Durigan Junior <sergiodj@redhat.com>
9072 Pedro Alves <palves@redhat.com>
9073
9074 * infcmd.c (kill_command): Print message when inferior has
9075 been killed.
9076 * inferior.c (print_inferior_events): Remove 'static'. Set as
9077 '1'.
9078 (add_inferior): Improve message printed when
9079 'print_inferior_events' is on.
9080 (exit_inferior): Remove message printed when
9081 'print_inferior_events' is on.
9082 (detach_inferior): Improve message printed when
9083 'print_inferior_events' is on.
9084 (initialize_inferiors): Use 'add_inferior_silent' to set
9085 'current_inferior_'.
9086 * inferior.h (print_inferior_events): Declare here as
9087 'extern'.
9088 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
9089 '[Detaching...]' messages when 'print_inferior_events' is on.
9090 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
9091 as prefix/suffix for messages. Remove periods. Fix erroneous
9092 'Detaching after fork from child...', replace it by '... from
9093 parent...'.
9094 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
9095 prefix/suffix when printing 'Detaching...' messages. Print
9096 them when 'print_inferior_events' is on.
9097 * remote.c (remote_detach_1): Print message when detaching
9098 from inferior and '!is_fork_parent'.
9099
9100 2018-04-24 Tom Tromey <tom@tromey.com>
9101
9102 * cli-out.h: Reindent.
9103
9104 2018-04-24 Tom Tromey <tom@tromey.com>
9105
9106 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
9107 (cli_ui_out::do_field_string): Use fputs_filtered.
9108 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
9109
9110 2018-04-23 Tom Tromey <tom@tromey.com>
9111
9112 * guile/scm-frame.c (gdbscm_frame_read_var): Use
9113 gdb::unique_xmalloc_ptr.
9114
9115 2018-04-23 Tom Tromey <tom@tromey.com>
9116
9117 * configure: Rebuild.
9118
9119 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
9120
9121 PR gdb/23095
9122 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
9123 prepare_for_testing. Set normal_bp to r_debug_state if target
9124 is bsd.
9125
9126 2018-04-21 Pedro Alves <palves@redhat.com>
9127 Rajendra SY <rajendra.sy@gmail.com>
9128
9129 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
9130 * remote.c (extended_remote_attach): In all-stop mode, mark the
9131 thread as executing.
9132
9133 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9134
9135 * thread.c (thread_apply_all_command): Fix comment.
9136 (thread_command): Fix comment.
9137
9138 2018-04-10 Alan Hayward <alan.hayward@arm.com>
9139
9140 * common/tdesc.h (tdesc_create_feature): Remove xml filename
9141 parameter.
9142 * features/aarch64-core.c (create_feature_aarch64_core):
9143 Regenerate.
9144 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
9145 Likewise.
9146 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
9147 Likewise.
9148 * features/i386/32bit-avx512.c
9149 (create_feature_i386_32bit_avx512): Likewise.
9150 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
9151 Likewise.
9152 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
9153 Likewise.
9154 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
9155 Likewise.
9156 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
9157 Likewise.
9158 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
9159 Likewise.
9160 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
9161 Likewise.
9162 * features/i386/64bit-avx512.c
9163 (create_feature_i386_64bit_avx512): Likewise.
9164 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
9165 Likewise.
9166 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
9167 Likewise.
9168 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
9169 Likewise.
9170 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
9171 Likewise.
9172 * features/i386/64bit-segments.c
9173 (create_feature_i386_64bit_segments): Likewise.
9174 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
9175 Likewise.
9176 * features/i386/x32-core.c
9177 (create_feature_i386_x32_core): Likewise.
9178 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
9179 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
9180 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
9181 * target-descriptions.c: In generated code, don't pass xml
9182 filename.
9183
9184 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9185
9186 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
9187 (print_xml_feature::visit_post): Likewise.
9188 (print_xml_feature::visit): Likewise.
9189 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
9190 (print_xml_feature): Add new class.
9191 * regformats/regdat.sh: Null xmltarget on feature targets.
9192 * target-descriptions.c (struct target_desc): Add xmltarget.
9193 (maintenance_check_tdesc_xml_convert): Add unittest function.
9194 (tdesc_get_features_xml): Add function to get xml.
9195 (maintenance_check_xml_descriptions): Test xml generation.
9196 * xml-tdesc.c (string_read_description_xml): Add function.
9197 * xml-tdesc.h (string_read_description_xml): Add declaration.
9198
9199 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9200
9201 * features/Makefile: Add feature marker to targets with new style
9202 target descriptions.
9203 * regformats/aarch64.dat: Regenerate.
9204 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
9205 * regformats/i386/amd64-avx-linux.dat: Likewise.
9206 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
9207 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
9208 * regformats/i386/amd64-linux.dat: Likewise.
9209 * regformats/i386/amd64-mpx-linux.dat: Likewise.
9210 * regformats/i386/amd64.dat: Likewise.
9211 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
9212 * regformats/i386/i386-avx-linux.dat: Likewise.
9213 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
9214 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
9215 * regformats/i386/i386-linux.dat: Likewise.
9216 * regformats/i386/i386-mmx-linux.dat: Likewise.
9217 * regformats/i386/i386-mpx-linux.dat: Likewise.
9218 * regformats/i386/i386.dat: Likewise.
9219 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
9220 * regformats/i386/x32-avx-linux.dat: Likewise.
9221 * regformats/i386/x32-linux.dat: Likewise.
9222 * regformats/tic6x-c62x-linux.dat: Likewise.
9223 * regformats/tic6x-c64x-linux.dat: Likewise.
9224 * regformats/tic6x-c64xp-linux.dat: Likewise.
9225 * regformats/regdat.sh: Parse feature marker.
9226
9227 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9228
9229 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
9230 (tdesc_osabi_name): Likewise.
9231 * target-descriptions.c (tdesc_architecture_name): Add new
9232 function.
9233 (tdesc_osabi_name): Likewise.
9234
9235 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9236
9237 * common/tdesc.c (tdesc_predefined_type): Move to here.
9238 (tdesc_named_type): Likewise.
9239 (tdesc_create_vector): Likewise.
9240 (tdesc_create_struct): Likewise.
9241 (tdesc_set_struct_size): Likewise.
9242 (tdesc_create_union): Likewise.
9243 (tdesc_create_flags): Likewise.
9244 (tdesc_create_enum): Likewise.
9245 (tdesc_add_field): Likewise.
9246 (tdesc_add_typed_bitfield): Likewise.
9247 (tdesc_add_bitfield): Likewise.
9248 (tdesc_add_flag): Likewise.
9249 (tdesc_add_enum_value): Likewise.
9250 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
9251 (struct tdesc_type_vector): Likewise.
9252 (struct tdesc_type_field): Likewise.
9253 (struct tdesc_type_with_fields): Likewise.
9254 (tdesc_create_enum): Add declaration.
9255 (tdesc_add_typed_bitfield): Likewise.
9256 (tdesc_add_enum_value): Likewise.
9257 * target-descriptions.c (tdesc_type_field): Move from here.
9258 (tdesc_type_builtin): Likewise.
9259 (tdesc_type_vector): Likewise.
9260 (tdesc_type_with_fields): Likewise.
9261 (tdesc_predefined_types): Likewise.
9262 (tdesc_named_type): Likewise.
9263 (tdesc_create_vector): Likewise.
9264 (tdesc_create_struct): Likewise.
9265 (tdesc_set_struct_size): Likewise.
9266 (tdesc_create_union): Likewise.
9267 (tdesc_create_flags): Likewise.
9268 (tdesc_create_enum): Likewise.
9269 (tdesc_add_field): Likewise.
9270 (tdesc_add_typed_bitfield): Likewise.
9271 (tdesc_add_bitfield): Likewise.
9272 (tdesc_add_flag): Likewise.
9273 (tdesc_add_enum_value): Likewise.
9274 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
9275 (tdesc_add_typed_bitfield): Likewise.
9276 (tdesc_add_enum_value): Likewise.
9277
9278 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9279
9280 * common/tdesc.c (tdesc_feature::accept): Move to here.
9281 (tdesc_feature::operator==): Likewise.
9282 (tdesc_create_reg): Likewise.
9283 * common/tdesc.h (tdesc_type_kind): Likewise.
9284 (struct tdesc_type): Likewise.
9285 (struct tdesc_feature): Likewise.
9286 * regformats/regdat.sh: Create a feature.
9287 * target-descriptions.c (tdesc_type_kind): Move from here.
9288 (tdesc_type): Likewise.
9289 (tdesc_type_up): Likewise.
9290 (tdesc_feature): Likewise.
9291 (tdesc_create_reg): Likewise.
9292
9293 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9294
9295 * Makefile.in: Add arch/tdesc.c
9296 * common/tdesc.c: New file.
9297 * common/tdesc.h (tdesc_element_visitor): Move to here.
9298 (tdesc_element): Likewise.
9299 (tdesc_reg): Likewise.
9300 (tdesc_reg_up): Likewise.
9301 * regformats/regdef.h (reg): Add offset to constructors.
9302 * target-descriptions.c (tdesc_element_visitor): Move from here.
9303 (tdesc_element): Likewise.
9304 (tdesc_reg): Likewise.
9305 (tdesc_reg_up): Likewise.
9306
9307 2018-04-17 Tom Tromey <tom@tromey.com>
9308
9309 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
9310 discriminant field.
9311
9312 2018-04-17 Tom Tromey <tom@tromey.com>
9313
9314 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
9315
9316 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
9317
9318 * symtab.c (print_symbol_info): Skip printing filename and line
9319 number when `last' is NULL.
9320 (symtab_symbol_info): Use empty string instead of NULL for first
9321 invocation of print_symbol_info.
9322 (rbreak_command): Pass NULL to `last' parameter of
9323 print_symbol_info.
9324
9325 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
9326
9327 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
9328 instead of nullptr.
9329
9330 2018-04-16 Pedro Alves <palves@redhat.com>
9331
9332 * MAINTAINERS (sh): Remove.
9333 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
9334 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
9335 (ALLDEPFILES): Remove sh64-tdep.c.
9336 * NEWS: Mentions that support for SH-5/SH64 is removed.
9337 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
9338 (sh*-*-openbsd*): Ditto.
9339 (sh64-*-elf*): Remove.
9340 (sh*): Remove.
9341 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
9342 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
9343 * sh-tdep.c: No longer include "sh64-tdep.h".
9344 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
9345 * sh64-tdep.c, sh64-tdep.h: Remove files.
9346
9347 2018-04-16 Pedro Alves <palves@redhat.com>
9348
9349 * MAINTAINERS: Remove m88k.
9350 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
9351 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
9352 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
9353 * NEWS: Mention that support for m88k was removed.
9354 * configure.host (m88*-*-*): Remove support.
9355 * configure.nat (m88k-*-*): Remove support.
9356 * configure.tgt (m88*-*-openbsd*): Remove.
9357 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
9358
9359 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
9360
9361 * configure.tgt (x86_tobjs): New variable.
9362 (amd64_tobjs, i386_tobjs): Use it.
9363
9364 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9365
9366 * symtab.c (print_symbol_info): Precede the symbol definition by
9367 the line number when available.
9368 * NEWS: Advertise this enhancement.
9369
9370 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9371
9372 * NEWS (New options): announce set/show record btrace cpu.
9373 * btrace.c: Include record-btrace.h.
9374 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
9375 the vendor is unknown.
9376 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
9377 Maybe overwrite the btrace configuration's cpu.
9378 (btrace_compute_ftrace): Add cpu parameter. Update callers.
9379 (btrace_fetch): Add cpu parameter. Update callers.
9380 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
9381 Maybe overwrite the btrace configuration's cpu. Skip enabling
9382 errata workarounds if the vendor is unknown.
9383 * python/py-record-btrace.c: Include record-btrace.h.
9384 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
9385 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
9386 * record-btrace.c (record_btrace_cpu_state_kind): New.
9387 (record_btrace_cpu): New.
9388 (set_record_btrace_cpu_cmdlist): New.
9389 (record_btrace_get_cpu): New.
9390 (require_btrace_thread, record_btrace_info)
9391 (record_btrace_resume_thread): Call record_btrace_get_cpu.
9392 (cmd_set_record_btrace_cpu_none): New.
9393 (cmd_set_record_btrace_cpu_auto): New.
9394 (cmd_set_record_btrace_cpu): New.
9395 (cmd_show_record_btrace_cpu): New.
9396 (_initialize_record_btrace): Initialize set/show record btrace cpu
9397 commands.
9398 * record-btrace.h (record_btrace_get_cpu): New.
9399
9400 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9401
9402 * record.c (set_record_command): Fix typo in message.
9403
9404 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9405
9406 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
9407
9408 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9409
9410 * infrun.c (process_event_stop_test): Call
9411 gdbarch_in_indirect_branch_thunk.
9412 * gdbarch.sh (in_indirect_branch_thunk): New.
9413 * gdbarch.c: Regenerated.
9414 * gdbarch.h: Regenerated.
9415 * x86-tdep.h: New.
9416 * x86-tdep.c: New.
9417 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
9418 (HFILES_NO_SRCDIR): Add x86-tdep.h.
9419 (ALLDEPFILES): Add x86-tdep.c.
9420 * arch-utils.h (default_in_indirect_branch_thunk): New.
9421 * arch-utils.c (default_in_indirect_branch_thunk): New.
9422 * i386-tdep: Include x86-tdep.h.
9423 (i386_in_indirect_branch_thunk): New.
9424 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
9425 function.
9426 * amd64-tdep: Include x86-tdep.h.
9427 (amd64_in_indirect_branch_thunk): New.
9428 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
9429
9430 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
9431
9432 PR gdb/23053
9433 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
9434 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
9435 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
9436 regression.
9437
9438 2018-04-12 Tom Tromey <tom@tromey.com>
9439
9440 * rust-lang.c (rust_print_struct_def): Remove univariant code.
9441 (rust_evaluate_subexp): Likewise.
9442
9443 2018-04-12 Pedro Alves <palves@redhat.com>
9444
9445 * procfs.c (procfs_detach): Make forward declaration's prototype
9446 match definition's protototype.
9447 (proc_get_LDT_entry): Remove stale do_cleanups call.
9448
9449 2018-04-12 Pedro Alves <palves@redhat.com>
9450
9451 * target.h (target_ops::to_has_exited): Delete.
9452 (target_has_exited): Delete.
9453 * target-delegates.c: Regenerate.
9454
9455 2018-04-11 Pedro Alves <palves@redhat.com>
9456
9457 * target.c (fileio_fh_t::t): Add comment.
9458 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9459 (target_fileio_close): Handle a NULL target.
9460 (invalidate_fileio_fh): New.
9461 (target_close): Call it.
9462 * remote.c (remote_hostio_send_command): No longer check whether
9463 remote_desc is open.
9464
9465 2018-04-11 Pedro Alves <palves@redhat.com>
9466
9467 * target.c (fileio_fh_t): Make it a named struct instead of a
9468 typedef.
9469 (fileio_fh_t::is_closed): New method.
9470 (DEF_VEC_O (fileio_fh_t)): Remove.
9471 (fileio_fhandles): Now a std::vector.
9472 (is_closed_fileio_fh): Delete.
9473 (acquire_fileio_fd): Adjust. Rename parameters.
9474 (release_fileio_fd): Adjust.
9475 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
9476 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9477 (target_fileio_close): Adjust.
9478
9479 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
9480
9481 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
9482 index.
9483
9484 2018-04-10 Pedro Alves <palves@redhat.com>
9485
9486 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
9487 (scoped_finish_thread_state): New class.
9488 * infcmd.c (run_command_1): Use it instead of finish_thread_state
9489 cleanup.
9490 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
9491 (fetch_inferior_event, normal_stop): Likewise.
9492 * thread.c (finish_thread_state_cleanup): Delete.
9493
9494 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9495 Pedro Alves <palves@redhat.com>
9496
9497 * value.c: Include "selftest.h" and "common/array-view.h".
9498 (struct range) <operator ==>: New.
9499 (test_ranges_contain): New.
9500 (check_ranges_vector): New.
9501 (test_insert_into_bit_range_vector): New.
9502 (_initialize_values): Register selftests.
9503 * common/array-view.h (operator==, operator!=): New.
9504
9505 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9506
9507 * common/gdb_vecs.h (unordered_remove): Add overload that takes
9508 an iterator.
9509 * inline-frame.c: Include <algorithm>.
9510 (struct inline_state): Add constructor.
9511 (inline_state_s): Remove.
9512 (DEF_VEC_O(inline_state_s)): Remove.
9513 (inline_states): Change type to std::vector.
9514 (find_inline_frame_state): Adjust to std::vector.
9515 (allocate_inline_frame_state): Remove.
9516 (clear_inline_frame_state): Adjust to std::vector.
9517 (skip_inline_frames): Adjust to std::vector.
9518
9519 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9520
9521 * tracepoint.h (struct trace_state_variable): Add constructor.
9522 <name>: Change type to std::string.
9523 * tracepoint.c (tsv_s): Remove.
9524 (DEF_VEC_O(tsv_s)): Remove.
9525 (tvariables): Change to std::vector.
9526 (create_trace_state_variable): Adjust to std::vector.
9527 (find_trace_state_variable): Likewise.
9528 (find_trace_state_variable_by_number): Likewise.
9529 (delete_trace_state_variable): Likewise.
9530 (trace_variable_command): Adjust to std::string.
9531 (delete_trace_variable_command): Likewise.
9532 (tvariables_info_1): Adjust to std::vector.
9533 (save_trace_state_variables): Likewise.
9534 (start_tracing): Likewise.
9535 (merge_uploaded_trace_state_variables): Adjust to std::vector
9536 and std::string.
9537 * target.h (struct target_ops)
9538 <to_download_trace_state_variable>: Pass reference to
9539 trace_state_variable.
9540 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
9541 * target-delegates.c: Re-generate.
9542 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
9543 (mi_tsv_deleted): Likewise.
9544 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
9545 * remote.c (remote_download_trace_state_variable): Change
9546 pointer to reference and adjust.
9547 * make-target-delegates (parse_argtypes): Handle references.
9548 (write_function_header): Likewise.
9549 (munge_type): Likewise.
9550
9551 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9552
9553 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9554 string_view-selftests.c.
9555 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
9556 testsuite.
9557 * unittests/basic_string_view/cons/char/1.cc: Likewise.
9558 * unittests/basic_string_view/cons/char/2.cc: Likewise.
9559 * unittests/basic_string_view/cons/char/3.cc: Likewise.
9560 * unittests/basic_string_view/element_access/char/1.cc:
9561 Likewise.
9562 * unittests/basic_string_view/element_access/char/empty.cc:
9563 Likewise.
9564 * unittests/basic_string_view/element_access/char/front_back.cc:
9565 Likewise.
9566 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
9567 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
9568 Likewise.
9569 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
9570 Likewise.
9571 * unittests/basic_string_view/modifiers/swap/char/1.cc:
9572 Likewise.
9573 * unittests/basic_string_view/operations/compare/char/1.cc:
9574 Likewise.
9575 * unittests/basic_string_view/operations/compare/char/13650.cc:
9576 Likewise.
9577 * unittests/basic_string_view/operations/copy/char/1.cc:
9578 Likewise.
9579 * unittests/basic_string_view/operations/data/char/1.cc:
9580 Likewise.
9581 * unittests/basic_string_view/operations/find/char/1.cc:
9582 Likewise.
9583 * unittests/basic_string_view/operations/find/char/2.cc:
9584 Likewise.
9585 * unittests/basic_string_view/operations/find/char/3.cc:
9586 Likewise.
9587 * unittests/basic_string_view/operations/find/char/4.cc:
9588 Likewise.
9589 * unittests/basic_string_view/operations/rfind/char/1.cc:
9590 Likewise.
9591 * unittests/basic_string_view/operations/rfind/char/2.cc:
9592 Likewise.
9593 * unittests/basic_string_view/operations/rfind/char/3.cc:
9594 Likewise.
9595 * unittests/basic_string_view/operations/substr/char/1.cc:
9596 Likewise.
9597 * unittests/basic_string_view/operators/char/2.cc: Likewise.
9598 * unittests/string_view-selftests.c: New file.
9599
9600 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9601
9602 * unittests/basic_string_view/capacity/1.cc: New file.
9603 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
9604 * unittests/basic_string_view/cons/char/1.cc: New file.
9605 * unittests/basic_string_view/cons/char/2.cc: New file.
9606 * unittests/basic_string_view/cons/char/3.cc: New file.
9607 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
9608 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
9609 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
9610 * unittests/basic_string_view/element_access/char/1.cc: New file.
9611 * unittests/basic_string_view/element_access/char/2.cc: New file.
9612 * unittests/basic_string_view/element_access/char/empty.cc: New file.
9613 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
9614 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
9615 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
9616 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
9617 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
9618 * unittests/basic_string_view/include.cc: New file.
9619 * unittests/basic_string_view/inserters/char/1.cc: New file.
9620 * unittests/basic_string_view/inserters/char/2.cc: New file.
9621 * unittests/basic_string_view/inserters/char/3.cc: New file.
9622 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
9623 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
9624 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
9625 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
9626 * unittests/basic_string_view/literals/types.cc: New file.
9627 * unittests/basic_string_view/literals/values.cc: New file.
9628 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
9629 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
9630 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
9631 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
9632 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
9633 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
9634 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
9635 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
9636 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
9637 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
9638 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
9639 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
9640 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
9641 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
9642 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
9643 * unittests/basic_string_view/operations/data/char/1.cc: New file.
9644 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
9645 * unittests/basic_string_view/operations/find/char/1.cc: New file.
9646 * unittests/basic_string_view/operations/find/char/2.cc: New file.
9647 * unittests/basic_string_view/operations/find/char/3.cc: New file.
9648 * unittests/basic_string_view/operations/find/char/4.cc: New file.
9649 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
9650 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
9651 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
9652 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
9653 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
9654 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
9655 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
9656 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
9657 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
9658 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
9659 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
9660 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
9661 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
9662 * unittests/basic_string_view/operators/char/2.cc: New file.
9663 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
9664 * unittests/basic_string_view/range_access/char/1.cc: New file.
9665 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
9666 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
9667 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
9668 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
9669 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
9670 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
9671 * unittests/basic_string_view/requirements/typedefs.cc: New file.
9672 * unittests/basic_string_view/typedefs.cc: New file.
9673 * unittests/basic_string_view/types/1.cc: New file.
9674
9675 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9676
9677 * common/gdb_string_view.h: Remove libstdc++ implementation
9678 details, adjust to gdb reality.
9679 * common/gdb_string_view.tcc: Likewise.
9680 * cli/cli-script.c (struct string_view): Remove.
9681 (user_args) <m_args>: Change element type to gdb::string_view.
9682 (user_args::insert_args): Adjust.
9683
9684 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9685
9686 * common/gdb_string_view.h: New file.
9687 * common/gdb_string_view.tcc: New file.
9688
9689 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9690
9691 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
9692 * configure: Re-generate.
9693
9694 2018-04-09 Pedro Alves <palves@redhat.com>
9695
9696 * gdbarch.sh: Include "observable.h" instead of "observer.h".
9697 (set_target_gdbarch): Call
9698 gdb::observers::architecture_changed.notify instead of
9699 observer_notify_architecture_changed.
9700
9701 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9702
9703 * tracepoint.c (struct current_traceframe_cleanup): Remove.
9704 (do_restore_current_traceframe_cleanup): Remove.
9705 (restore_current_traceframe_cleanup_dtor): Remove.
9706 (make_cleanup_restore_current_traceframe): Remove.
9707 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
9708 New.
9709 * tracepoint.h (struct scoped_restore_current_traceframe): New.
9710 * infrun.c (fetch_inferior_event): Use
9711 scoped_restore_current_traceframe.
9712
9713 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9714
9715 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
9716 Remove.
9717 <n_allocated_type_units>: Remove.
9718 <all_type_units>: Change to std::vector.
9719 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9720 to std::vector change.
9721 (dwarf2_per_objfile::get_cutu): Likewise.
9722 (dwarf2_per_objfile::get_tu): Likewise.
9723 (create_signatured_type_table_from_index): Likewise.
9724 (create_signatured_type_table_from_debug_names): Likewise.
9725 (dw2_symtab_iter_next): Likewise.
9726 (dw2_print_stats): Likewise.
9727 (dw2_expand_all_symtabs): Likewise.
9728 (dw2_expand_marked_cus): Likewise.
9729 (dw2_debug_names_iterator::next): Likewise.
9730 (dwarf2_initialize_objfile): Likewise.
9731 (add_signatured_type_cu_to_table): Likewise.
9732 (create_all_type_units): Likewise.
9733 (add_type_unit): Likewise.
9734 (struct tu_abbrev_offset): Add constructor.
9735 (build_type_psymtabs_1): Adjust to std::vector change.
9736 (print_tu_stats): Likewise.
9737 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9738 (write_debug_names): Likewise.
9739
9740 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9741
9742 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
9743 Make an std::vector.
9744 <n_comp_units>: Remove.
9745 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9746 to std::vector change.
9747 (dwarf2_per_objfile::get_cutu): Likewise.
9748 (dwarf2_per_objfile::get_cu): Likewise.
9749 (create_cus_from_index): Likewise.
9750 (create_addrmap_from_index): Likewise.
9751 (create_addrmap_from_aranges): Likewise.
9752 (dwarf2_read_index): Likewise.
9753 (dw2_find_last_source_symtab): Likewise.
9754 (dw2_map_symtabs_matching_filename): Likewise.
9755 (dw2_symtab_iter_next): Likewise.
9756 (dw2_print_stats): Likewise.
9757 (dw2_expand_all_symtabs): Likewise.
9758 (dw2_expand_symtabs_with_fullname): Likewise.
9759 (dw2_expand_marked_cus): Likewise.
9760 (dw2_map_symbol_filenames): Likewise.
9761 (create_cus_from_debug_names): Likewise.
9762 (dwarf2_read_debug_names): Likewise.
9763 (dw2_debug_names_iterator::next): Likewise.
9764 (dwarf2_initialize_objfile): Likewise.
9765 (set_partial_user): Likewise.
9766 (dwarf2_build_psymtabs_hard): Likewise.
9767 (read_comp_units_from_section): Remove arguments, adjust to
9768 std::vector change.
9769 (create_all_comp_units): Adjust to std::vector and
9770 read_comp_units_from_section changes.
9771 (dwarf2_find_containing_comp_unit): Adjust to std::vector
9772 change.
9773 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9774 (psyms_seen_size): Likewise.
9775 (write_gdbindex): Likewise.
9776 (write_debug_names): Likewise.
9777
9778 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9779
9780 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
9781 with dwarf2_per_objfile.
9782 (create_cus_from_index): Likewise.
9783 (create_signatured_type_table_from_index): Likewise.
9784 (dwarf2_read_index): Likewise.
9785 (dwarf2_initialize_objfile): Likewise.
9786 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
9787 per_cu rather than get_dwarf2_per_objfile.
9788
9789 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9790
9791 * dwarf2read.h (struct signatured_type): Forward declare.
9792 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
9793 New methods.
9794 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
9795 (dw2_get_cutu): ...this.
9796 (dwarf2_per_objfile::get_cu): Rename from...
9797 (dw2_get_cu): ...this.
9798 (dwarf2_per_objfile::get_tu): New.
9799 (create_addrmap_from_index): Adjust.
9800 (create_addrmap_from_aranges): Adjust.
9801 (dw2_find_last_source_symtab): Adjust.
9802 (dw2_map_symtabs_matching_filename): Adjust.
9803 (dw2_symtab_iter_next): Adjust.
9804 (dw2_print_stats): Adjust.
9805 (dw2_expand_all_symtabs): Adjust.
9806 (dw2_expand_symtabs_with_fullname): Adjust.
9807 (dw2_expand_marked_cus): Adjust.
9808 (dw_expand_symtabs_matching_file_matcher): Adjust.
9809 (dw2_map_symbol_filenames): Adjust.
9810 (dw2_debug_names_iterator::next): Adjust.
9811 (dwarf2_initialize_objfile): Adjust.
9812 (set_partial_user): Adjust.
9813 (dwarf2_build_psymtabs_hard): Adjust.
9814
9815 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9816
9817 * dwarf2read.c (create_signatured_type_table_from_debug_names):
9818 Remove unused variables.
9819 (dw2_map_symtabs_matching_filename): Likewise.
9820 (dwarf2_record_block_ranges): Likewise.
9821 (dwarf2_read_addr_index): Likewise.
9822 (follow_die_offset): Likewise.
9823
9824 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9825
9826 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
9827 to symbol_file_add_main.
9828
9829 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9830
9831 PR mi/22299
9832 * mi/mi-console.c (do_fputc_async_safe): New.
9833 (mi_console_file::write_async_safe): New.
9834 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
9835 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
9836 New.
9837 * ui-file.c (ui_file::putstrn): Adjust call to
9838 fputstrn_unfiltered.
9839 * utils.c (printchar): Replace do_fputs and do_fprintf
9840 parameters by do_fputc.
9841 (fputstr_filtered): Adjust call to printchar.
9842 (fputstr_unfiltered): Likewise.
9843 (fputstrn_filtered): Likewise.
9844 (fputstrn_unfiltered): Add do_fputc parameter, pass to
9845 printchar.
9846 * utils.h (do_fputc_ftype): New typedef.
9847 (fputstrn_unfiltered): Add do_fputc parameter.
9848
9849 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9850
9851 * regformats/i386/i386-avx.dat: Remove.
9852
9853 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9854
9855 PR gdb/22979
9856 * amd64-tdep.c (amd64_none_init_abi): New function.
9857 (amd64_x32_none_init_abi): New function.
9858 (_initialize_amd64_tdep): Register handlers for x86-64 and
9859 x64_32 with GDB_OSABI_NONE.
9860 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
9861 GDB_OSABI_NONE osabi.
9862
9863 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9864
9865 PR gdb/22980
9866 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
9867 GDB_OSABI_NONE.
9868 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
9869 * osabi.c (gdb_osabi_names): Add "unknown" entry.
9870
9871 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9872
9873 * common/byte-vector.h (char_vector): New type.
9874 * target.h (target_read_alloc): Return
9875 gdb::optional<byte_vector>.
9876 (target_read_stralloc): Return gdb::optional<char_vector>.
9877 (target_get_osdata): Return gdb::optional<char_vector>.
9878 * target.c (target_read_alloc_1): Templatize. Replacement
9879 manual memory management with vector.
9880 (target_read_alloc): Change return type, adjust.
9881 (target_read_stralloc): Change return type, adjust.
9882 (target_get_osdata): Change return type, adjust.
9883 * auxv.c (struct auxv_info) <length>: Remove.
9884 <data>: Change type to gdb::optional<byte_vector>.
9885 (auxv_inferior_data_cleanup): Free auxv_info with delete.
9886 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
9887 (target_auxv_search): Adjust.
9888 (fprint_target_auxv): Adjust.
9889 * avr-tdep.c (avr_io_reg_read_command): Adjust.
9890 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
9891 (linux_make_corefile_notes): Adjust.
9892 * osdata.c (get_osdata): Adjust.
9893 * remote.c (remote_get_threads_with_qxfer): Adjust.
9894 (remote_memory_map): Adjust.
9895 (remote_traceframe_info): Adjust.
9896 (btrace_read_config): Adjust.
9897 (remote_read_btrace): Adjust.
9898 (remote_pid_to_exec_file): Adjust.
9899 * solib-aix.c (solib_aix_get_library_list): Adjust.
9900 * solib-dsbt.c (decode_loadmap): Don't free buf.
9901 (dsbt_get_initial_loadmaps): Adjust.
9902 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
9903 * solib-target.c (solib_target_current_sos): Adjust.
9904 * tracepoint.c (sdata_make_value): Adjust.
9905 * xml-support.c (xinclude_start_include): Adjust.
9906 (xml_fetch_content_from_file): Adjust.
9907 * xml-support.h (xml_fetch_another): Change return type.
9908 (xml_fetch_content_from_file): Change return type.
9909 * xml-syscall.c (xml_init_syscalls_info): Adjust.
9910 * xml-tdesc.c (file_read_description_xml): Adjust.
9911 (fetch_available_features_from_target): Change return type.
9912 (target_fetch_description_xml): Adjust.
9913 (target_read_description_xml): Adjust.
9914
9915 2018-04-06 Tom Tromey <tom@tromey.com>
9916
9917 * value.c (~value): Update.
9918 (struct value) <contents>: Now unique_xmalloc_ptr.
9919 (value_contents_bits_eq, allocate_value_contents)
9920 (value_contents_raw, value_contents_all_raw)
9921 (value_contents_for_printing, value_contents_for_printing_const)
9922 (set_value_enclosing_type): Update.
9923
9924 2018-04-06 Tom Tromey <tom@tromey.com>
9925
9926 * value.c (range_s): Remove typedef, VEC.
9927 (struct range): Add operator<.
9928 (range_lessthan): Remove.
9929 (ranges_contain): Change type.
9930 (~value): Update.
9931 (struct value) <unavailable, optimized_out>: Now std::vector.
9932 (value_entirely_available)
9933 (value_entirely_covered_by_range_vector)
9934 (value_entirely_unavailable, value_entirely_optimized_out):
9935 Update.
9936 (insert_into_bit_range_vector): Change argument type.
9937 (find_first_range_overlap): Likewise.
9938 (struct ranges_and_idx, value_contents_bits_eq)
9939 (require_not_optimized_out, require_available): Update.
9940 (ranges_copy_adjusted): Change argument types.
9941 (value_optimized_out, value_copy, value_fetch_lazy): Update.
9942
9943 2018-04-06 Tom Tromey <tom@tromey.com>
9944
9945 * value.c (~value): Update.
9946 (struct value) <parent>: Now a value_ref_ptr.
9947 (value_parent, set_value_parent, value_address, value_copy):
9948 Update.
9949
9950 2018-04-06 Tom Tromey <tom@tromey.com>
9951
9952 * value.c (struct value): Add constructor, destructor, and member
9953 initializers.
9954 (allocate_value_lazy, value_decref): Update.
9955
9956 2018-04-06 Tom Tromey <tom@tromey.com>
9957
9958 * value.c (struct value) <released, next>: Remove.
9959 (all_values): Now a std::vector.
9960 (allocate_value_lazy): Update.
9961 (value_next): Remove.
9962 (value_mark, value_free_to_mark, release_value)
9963 (value_release_to_mark): Update.
9964
9965 2018-04-06 Tom Tromey <tom@tromey.com>
9966
9967 * value.h (fetch_subexp_value, value_release_to_mark): Update.
9968 (free_value_chain): Remove.
9969 * value.c (free_value_chain): Remove.
9970 (value_release_to_mark): Return a std::vector.
9971 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
9972 std::vector.
9973 (check_condition): Update.
9974 * eval.c (fetch_subexp_value): Change "val_chain" to a
9975 std::vector.
9976 * breakpoint.c (update_watchpoint): Update.
9977 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
9978
9979 2018-04-06 Tom Tromey <tom@tromey.com>
9980
9981 * value.h (free_all_values): Remove.
9982 * value.c (free_all_values): Remove.
9983
9984 2018-04-06 Tom Tromey <tom@tromey.com>
9985
9986 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
9987 (value_history_chain, value_history_count): Remove.
9988 (value_history): New global.
9989 (record_latest_value, access_value_history, show_values)
9990 (preserve_values): Update.
9991
9992 2018-04-06 Tom Tromey <tom@tromey.com>
9993
9994 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
9995 * varobj.c (varobj_set_display_format, varobj_set_value)
9996 (install_default_visualizer, construct_visualizer)
9997 (install_new_value, ~varobj, varobj_get_value_type)
9998 (my_value_of_variable, varobj_editable_p): Update.
9999 * c-varobj.c (c_describe_child, c_value_of_variable)
10000 (cplus_number_of_children, cplus_describe_child): Update.
10001 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
10002 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
10003 (ada_value_of_variable, ada_value_is_changeable_p): Update.
10004
10005 2018-04-06 Tom Tromey <tom@tromey.com>
10006
10007 * printcmd.c (last_examine_address): Change type to
10008 value_ref_ptr.
10009 (do_examine, x_command): Update.
10010
10011 2018-04-06 Tom Tromey <tom@tromey.com>
10012
10013 * value.c (release_value): Update.
10014 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
10015 (struct bpstats) <val>: Now a value_ref_ptr.
10016 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
10017 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
10018 (~watchpoint, print_it_watchpoint, watch_command_1)
10019 (invalidate_bp_value_on_memory_change): Update.
10020
10021 2018-04-06 Tom Tromey <tom@tromey.com>
10022
10023 * varobj.c (varobj_clear_saved_item)
10024 (update_dynamic_varobj_children, install_new_value, ~varobj):
10025 Update.
10026 * value.h (value_incref): Move declaration earlier.
10027 (value_decref): Rename from value_free.
10028 (struct value_ref_policy): New.
10029 (value_ref_ptr): New typedef.
10030 (struct value_deleter): Remove.
10031 (gdb_value_up): Remove typedef.
10032 (release_value): Change return type.
10033 (release_value_or_incref): Remove.
10034 * value.c (set_value_parent): Update.
10035 (value_incref): Change return type.
10036 (value_decref): Rename from value_free.
10037 (value_free_to_mark, free_all_values, free_value_chain): Update.
10038 (release_value): Return value_ref_ptr.
10039 (release_value_or_incref): Remove.
10040 (record_latest_value, set_internalvar, clear_internalvar):
10041 Update.
10042 * stack.c (info_frame_command): Don't call value_free.
10043 * python/py-value.c (valpy_dealloc, valpy_new)
10044 (value_to_value_object): Update.
10045 * printcmd.c (do_examine): Update.
10046 * opencl-lang.c (lval_func_free_closure): Update.
10047 * mi/mi-main.c (register_changed_p): Don't call value_free.
10048 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
10049 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
10050 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
10051 value_free.
10052 * guile/scm-value.c (vlscm_free_value_smob)
10053 (vlscm_scm_from_value): Update.
10054 * frame.c (frame_register_unwind, frame_unwind_register_signed)
10055 (frame_unwind_register_unsigned, get_frame_register_bytes)
10056 (put_frame_register_bytes): Don't call value_free.
10057 * findvar.c (address_from_register): Don't call value_free.
10058 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
10059 * dwarf2loc.c (entry_data_value_free_closure)
10060 (value_of_dwarf_reg_entry, free_pieced_value_closure)
10061 (dwarf2_evaluate_loc_desc_full): Update.
10062 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
10063 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
10064 (~watchpoint, watch_command_1)
10065 (invalidate_bp_value_on_memory_change): Update.
10066 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
10067
10068 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
10069
10070 PR gdb/23022
10071 * warning.m4: Add -Wno-error=deprecated-register.
10072 * configure: Re-generate.
10073
10074 2018-04-05 Tom Tromey <tom@tromey.com>
10075
10076 * linespec.h: Remove include of "vec.h".
10077
10078 2018-04-05 Tom Tromey <tom@tromey.com>
10079
10080 * linespec.c (typep): Remove typedef.
10081 (find_methods, find_superclass_methods): Take a std::vector.
10082 (find_method): Use std::vector.
10083
10084 2018-04-05 Tom Tromey <tom@tromey.com>
10085
10086 * utils.c (compare_strings): Remove.
10087 * utils.h (compare_strings): Remove.
10088 * objc-lang.h (find_imps): Update.
10089 * objc-lang.c (find_methods): Take a std::vector.
10090 (uniquify_strings, find_imps): Likewise.
10091 * linespec.c (find_methods): Take a std::vector.
10092 (decode_objc): Use std::vector.
10093 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
10094 a std::vector.
10095 (find_method, find_function_symbols): Use std::vector.
10096
10097 2018-04-05 Tom Tromey <tom@tromey.com>
10098
10099 * completer.c (completion_tracker::completion_tracker): Remove
10100 cast.
10101 (completion_tracker::discard_completions): Likewise.
10102 * breakpoint.c (ambiguous_names_p): Remove cast.
10103 * ada-lang.c (_initialize_ada_language): Remove cast.
10104 * utils.h (streq): Update.
10105 (streq_hash): Add new declaration.
10106 * utils.c (streq): Return bool.
10107 (streq_hash): New function.
10108
10109 2018-04-05 Tom Tromey <tom@tromey.com>
10110
10111 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
10112 Remove a string copy.
10113
10114 2018-04-05 Tom Tromey <tom@tromey.com>
10115
10116 * linespec.c (filter_results): Use std::vector.
10117 (decode_line_2, decode_line_full): Update.
10118
10119 2018-04-05 Tom Tromey <tom@tromey.com>
10120
10121 * linespec.c (canonical_to_fullform): Return std::string.
10122 (filter_results): Update.
10123 (struct decode_line_2_item): Add constructor.
10124 <fullform, displayform>: Now std::string.
10125 (decode_line_2_compare_items): Now a std::sort comparator.
10126 (decode_line_2): Update.
10127
10128 2018-04-05 Tom Tromey <tom@tromey.com>
10129
10130 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
10131 (unexpected_linespec_error): Update.
10132 (linespec_parse_basic, parse_linespec): Update.
10133
10134 2018-04-05 Tom Tromey <tom@tromey.com>
10135
10136 * linespec.c (linespec_parse_basic): Reindent.
10137
10138 2018-04-05 Tom Tromey <tom@tromey.com>
10139
10140 * minsyms.h (iterate_over_minimal_symbols): Update.
10141 * minsyms.c (iterate_over_minimal_symbols): Take a
10142 gdb::function_view.
10143 * linespec.c (struct collect_minsyms): Remove.
10144 (compare_msyms): Now a std::sort comparator.
10145 (add_minsym): Add parameters.
10146 (search_minsyms_for_name): Update. Use std::vector.
10147
10148 2018-04-03 Tom Tromey <tom@tromey.com>
10149
10150 * mipsread.c (read_alphacoff_dynamic_symtab): Use
10151 gdb::byte_vector.
10152
10153 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10154
10155 * MAINTAINERS (Write After Approval): Add Weimin Pan.
10156
10157 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10158
10159 PR gdb/16959
10160 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
10161 printing static type.
10162
10163 2018-04-01 Tom Tromey <tom@tromey.com>
10164
10165 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
10166 (rs6000_xfer_shared_libraries): Update.
10167
10168 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
10169
10170 * common/gdb_vecs.h (char_ptr): Remove.
10171 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
10172
10173 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10174
10175 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
10176 with std::vector.
10177 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
10178
10179 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10180
10181 * tracepoint.h (struct uploaded_tp): Initialize fields.
10182 <actions, step_actions, cmd_strings>: Change type to
10183 std::vector<char *>.
10184 * tracepoint.c (get_uploaded_tp): Allocate with new.
10185 (free_uploaded_tps): Free with delete.
10186 (parse_tracepoint_definition): Adjust to std::vector change.
10187 * breakpoint.c (read_uploaded_action): Likewise.
10188 (create_tracepoint_from_upload): Likewise.
10189 * ctf.c (ctf_write_uploaded_tp): Likewise.
10190 (SET_ARRAY_FIELD): Likewise.
10191 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
10192
10193 2018-03-30 Tom Tromey <tom@tromey.com>
10194
10195 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
10196 std::unique_ptr.
10197 (svr4_keep_data_in_core): Update.
10198 (svr4_read_so_list): Update.
10199
10200 2018-03-30 Tom Tromey <tom@tromey.com>
10201
10202 * windows-nat.c (handle_output_debug_string, handle_exception):
10203 Update.
10204 * target.h (target_read_string): Update.
10205 * target.c (target_read_string): Change "string" to
10206 unique_xmalloc_ptr.
10207 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
10208 Update.
10209 * solib-frv.c (frv_current_sos): Update.
10210 * solib-dsbt.c (dsbt_current_sos): Update.
10211 * solib-darwin.c (darwin_current_sos): Update.
10212 * linux-thread-db.c (inferior_has_bug): Update.
10213 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
10214 Update. Remove alloca.
10215 * ada-lang.c (ada_main_name): Update.
10216
10217 2018-03-30 Tom Tromey <tom@tromey.com>
10218
10219 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
10220 (struct dwo_file_deleter): New.
10221 (dwo_file_up): New typedef.
10222 (open_and_init_dwo_file): Use dwo_file_up.
10223 (free_dwo_file_cleanup): Remove.
10224
10225 2018-03-30 Tom Tromey <tom@tromey.com>
10226
10227 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
10228 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
10229
10230 2018-03-30 Tom Tromey <tom@tromey.com>
10231
10232 * dwarf2read.c (class free_cached_comp_units): New class.
10233 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
10234 (free_cached_comp_units): Remove function.
10235
10236 2018-03-30 Tom Tromey <tom@tromey.com>
10237
10238 * utils.h (make_cleanup_unpush_target): Remove.
10239 * inf-ptrace.c (struct target_unpusher): New.
10240 (target_unpush_up) New typedef.
10241 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
10242 target_unpush_up.
10243 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
10244
10245 2018-03-27 Tom Tromey <tom@tromey.com>
10246
10247 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
10248
10249 2018-03-27 Pedro Alves <palves@redhat.com>
10250 Tom Tromey <tom@tromey.com>
10251
10252 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
10253 destructor. Now a class.
10254 (gdb_readline_wrapper_cleanup): Remove function.
10255 (gdb_readline_wrapper): Remove cleanups.
10256
10257 2018-03-27 Tom Tromey <tom@tromey.com>
10258
10259 * typeprint.h (struct type_print_options) <local_typedefs,
10260 global_typedefs>: Remove "struct" keyword.
10261 (class typedef_hash_table): New class.
10262 (recursively_update_typedef_hash, add_template_parameters)
10263 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
10264 (find_typedef_in_hash): Don't declare.
10265 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
10266 (typedef_hash_table::recursively_update): Rename from
10267 recursively_update_typedef_hash. Now a member.
10268 (typedef_hash_table::add_template_parameters): Rename from
10269 add_template_parameters. Now a member.
10270 (typedef_hash_table::typedef_hash_table): Now a constructor;
10271 rename from create_typedef_hash.
10272 (typedef_hash_table::~typedef_hash_table): Now a destructor;
10273 rename from free_typedef_hash.
10274 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
10275 (do_free_global_table): Remove.
10276 (typedef_hash_table::typedef_hash_table): New constructor; renamed
10277 from copy_type_recursive.
10278 (create_global_typedef_table): Remove.
10279 (typedef_hash_table::find_global_typedef): Now a member of
10280 typedef_hash_table.
10281 (typedef_hash_table::find_typedef): Rename from
10282 find_typedef_in_hash; now a member.
10283 (whatis_exp): Update.
10284 * extension.h (struct ext_lang_type_printers): Add constructor and
10285 destructor.
10286 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
10287 declare.
10288 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
10289 Now a constructor; rename from start_ext_lang_type_printers.
10290 (ext_lang_type_printers): Now a destructor; rename from
10291 free_ext_lang_type_printers.
10292 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
10293 Update.
10294 (c_type_print_base_struct_union): Update. Remove cleanups.
10295
10296 2018-03-27 Tom Tromey <tom@tromey.com>
10297
10298 * dwarf-index-write.c: Include <cmath>.
10299
10300 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10301
10302 * NEWS: Add entry describing new "set|show varsize-limit" command.
10303 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
10304 command.
10305 * printcmd.c (_initialize_printcmd): Add "set var" alias of
10306 "set variable".
10307
10308 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
10309
10310 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
10311 dwarf-index-write.c
10312 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
10313 * dwarf-index-common.c: New file.
10314 * dwarf-index-common.h: New file.
10315 * dwarf-index-write.c: New file.
10316 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
10317 (struct dwarf2_section_info): Move from here.
10318 (dwarf2_section_info_def): Likewise.
10319 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
10320 (offset_type): Likewise.
10321 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
10322 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
10323 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
10324 (byte_swap): Likewise.
10325 (MAYBE_SWAP): Likewise.
10326 (dwarf2_per_cu_ptr): Likewise.
10327 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
10328 (struct tu_stats): Likewise.
10329 (struct dwarf2_per_objfile): Likewise.
10330 (struct dwarf2_per_cu_data): Likewise.
10331 (struct signatured_type): Likewise.
10332 (sig_type_ptr): Likewise.
10333 (DEF_VEC_P (sig_type_ptr)): Likewise.
10334 (INDEX4_SUFFIX): Likewise.
10335 (INDEX5_SUFFIX): Likewise.
10336 (DEBUG_STR_SUFFIX): Likewise.
10337 (dwarf2_read_section): Make non-static.
10338 (mapped_index_string_hash): Move from here.
10339 (dwarf5_djb_hash): Likewise.
10340 (file_write): Likewise.
10341 (class data_buf): Likewise.
10342 (struct symtab_index_entry): Likewise.
10343 (struct mapped_symtab): Likewise.
10344 (find_slot): Likewise.
10345 (hash_expand): Likewise.
10346 (add_index_entry): Likewise.
10347 (uniquify_cu_indices): Likewise.
10348 (class c_str_view): Likewise.
10349 (class c_str_view_hasher): Likewise.
10350 (class vector_hasher): Likewise.
10351 (write_hash_table): Likewise.
10352 (psym_index_map): Likewise.
10353 (struct addrmap_index_data): Likewise.
10354 (add_address_entry): Likewise.
10355 (add_address_entry_worker): Likewise.
10356 (write_address_map): Likewise.
10357 (symbol_kind): Likewise.
10358 (write_psymbols): Likewise.
10359 (struct signatured_type_index_data): Likewise.
10360 (write_one_signatured_type): Likewise.
10361 (recursively_count_psymbols): Likewise.
10362 (recursively_write_psymbols): Likewise.
10363 (class debug_names): Likewise.
10364 (check_dwarf64_offsets): Likewise.
10365 (psyms_seen_size): Likewise.
10366 (write_gdbindex): Likewise.
10367 (write_debug_names): Likewise.
10368 (assert_file_size): Likewise.
10369 (write_psymtabs_to_index): Likewise.
10370 (save_gdb_index_command): Likewise.
10371 (_initialize_dwarf2_read): Don't register the "save gdb-index"
10372 command.
10373 * dwarf2read.h: New file.
10374
10375 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10376
10377 PR gdb/22670
10378 * dwarf2read.c (dwarf2_physname): Do not return the demangled
10379 symbol name if the CU's language stores symbol names in linkage
10380 format.
10381 * language.h (struct language_defn)
10382 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
10383 all instances of this struct.
10384
10385 2018-03-26 Tom Tromey <tom@tromey.com>
10386
10387 * stack.c (backtrace_command_1): Remove verbose code.
10388
10389 2018-03-26 Tom Tromey <tom@tromey.com>
10390
10391 * python/py-framefilter.c (py_print_type): Don't catch
10392 exceptions. Return void.
10393 (py_print_value): Likewise.
10394 (py_print_single_arg): Likewise.
10395 (enumerate_args): Don't catch exceptions.
10396 (py_print_args): Likewise.
10397 (py_print_frame): Likewise.
10398 (gdbpy_apply_frame_filter): Catch exceptions here.
10399
10400 2018-03-26 Tom Tromey <tom@tromey.com>
10401
10402 * stack.c (_initialize_stack): Remove trailing newlines from help
10403 text. Add "Usage" line to "backtrace" help.
10404
10405 2018-03-26 Tom Tromey <tom@tromey.com>
10406
10407 PR python/16486:
10408 * python/py-framefilter.c (py_print_args): Call wrap_hint.
10409
10410 2018-03-26 Tom Tromey <tom@tromey.com>
10411
10412 * python/py-framefilter.c (py_print_single_arg): Return
10413 EXT_LANG_BT_ERROR from catch.
10414
10415 2018-03-26 Tom Tromey <tom@tromey.com>
10416
10417 PR backtrace/15584:
10418 * stack.c (backtrace_command_1): Move some code into no-filters
10419 "if".
10420
10421 2018-03-26 Tom Tromey <tom@tromey.com>
10422
10423 * python/py-framefilter.c (throw_quit_or_print_exception): New
10424 function.
10425 (gdbpy_apply_frame_filter): Use it.
10426
10427 2018-03-26 Tom Tromey <tom@tromey.com>
10428
10429 PR cli/17716:
10430 * python/py-framefilter.c (py_print_type, py_print_value)
10431 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
10432 RETURN_MASK_ERROR.
10433
10434 2018-03-26 Tom Tromey <tom@tromey.com>
10435
10436 * python/py-framefilter.c (enumerate_args): Use
10437 gdb::unique_xmalloc_ptr.
10438
10439 2018-03-26 Tom Tromey <tom@tromey.com>
10440
10441 * python/py-framefilter.c (py_print_frame): Return
10442 EXT_LANG_BT_OK.
10443 (gdbpy_apply_frame_filter): Update comment.
10444 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
10445 Remove.
10446 <EXT_LANG_BT_NO_FILTERS>: Change value.
10447
10448 2018-03-26 Tom Tromey <tom@tromey.com>
10449
10450 PR backtrace/15582:
10451 * stack.c (backtrace_command): Parse "hide" argument.
10452 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
10453 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
10454 constant.
10455
10456 2018-03-26 Tom Tromey <tom@tromey.com>
10457
10458 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
10459 add "flags".
10460 (backtrace_command): Remove "fulltrace", add "flags".
10461
10462 2018-03-26 Tom Tromey <tom@tromey.com>
10463
10464 * stack.c (backtrace_command): Rewrite command line parsing.
10465
10466 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10467
10468 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
10469
10470 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10471
10472 * filename-seen-cache.h: Add include guard.
10473
10474 2018-03-26 Keith Seitz <keiths@redhat.com>
10475
10476 * symfile.c (place_section): Remove "struct" from section_addr_info
10477 in comment.
10478 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
10479 "struct" keyword from section_addr_info.
10480
10481 2018-03-26 Alan Hayward <alan.hayward@arm.com>
10482
10483 * regformats/regdef.h (reg): Add constructors.
10484
10485 2018-03-25 Pedro Alves <palves@redhat.com>
10486
10487 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
10488 if then/else bodies in var_func_name extraction.
10489
10490 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
10491
10492 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
10493 lookup_minimal_symbol() to find symbol entry.
10494 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
10495
10496 2018-03-23 Keith Seitz <keiths@redhat.com>
10497
10498 PR c++/22968
10499 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
10500 nested type definitions for C++, too.
10501
10502 2018-03-23 Tom Tromey <tom@tromey.com>
10503
10504 * machoread.c (struct oso_el): Add a constructor. Don't define as
10505 a typedef.
10506 (macho_register_oso): Remove.
10507 (macho_symtab_read): Take a std::vector.
10508 (oso_el_compare_name): Now a std::sort comparator.
10509 (macho_symfile_read_all_oso): Take a std::vector.
10510 (macho_symfile_read): Use std::vector. Remove cleanups.
10511
10512 2018-03-22 Tom Tromey <tom@tromey.com>
10513
10514 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
10515 (record_full_goto_bookmark): Use std::string.
10516
10517 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10518
10519 PR tdep/18295
10520 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
10521 a single mask.
10522
10523 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10524
10525 * rs6000-tdep.c (store_insn_p): New function.
10526 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
10527 and cr_reg to their unshifted values. Use store_insn_p to
10528 match LR saves using either R1 or fdata->alloca_reg. Use
10529 store_insn_p to match CR saves. Set alloca_reg_offset
10530 when alloca_reg and framep are set. Remove lr_reg shift
10531 when assigning to fdata->lr_register.
10532
10533 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
10534
10535 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
10536 command line args instead of emitting a warning.
10537
10538 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10539
10540 * tracepoint.h (struct static_tracepoint_marker): Initialize
10541 fields, define default constructor, move constructor and move
10542 assignment, disable the rest.
10543 <str_id, extra>: Make std::string.
10544 (release_static_tracepoint_marker): Remove.
10545 (free_current_marker): Remove.
10546 * tracepoint.c (free_current_marker): Remove.
10547 (parse_static_tracepoint_marker_definition): Adjust to
10548 std::string, use new hex2str overload.
10549 (release_static_tracepoint_marker): Remove.
10550 (print_one_static_tracepoint_marker): Get marker by reference
10551 and adjust to std::string.
10552 (info_static_tracepoint_markers_command): Adjust to std::vector
10553 changes
10554 * target.h (static_tracepoint_marker_p): Remove typedef.
10555 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
10556 (struct target_ops) <to_static_tracepoint_marker_at>: Return
10557 bool.
10558 <to_static_tracepoint_markers_by_strid>: Return std::vector.
10559 * target-debug.h
10560 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
10561 (target_debug_print_std_vector_static_tracepoint_marker): New.
10562 (target_debug_print_struct_static_tracepoint_marker_p): Rename
10563 to...
10564 (target_debug_print_static_tracepoint_marker_p): ... this.
10565 * target-delegates.c: Re-generate.
10566 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
10567 Make std::string.
10568 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
10569 (decode_static_tracepoint_spec): Adjust to std::vector.
10570 (tracepoint_print_one_detail): Adjust to std::string.
10571 (strace_marker_decode_location): Adjust to std::string.
10572 (update_static_tracepoint): Adjust to std::string, remove call
10573 to release_static_tracepoint_marker.
10574 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
10575 Adjust to std::vector.
10576 * remote.c (remote_static_tracepoint_marker_at): Return bool.
10577 (remote_static_tracepoint_markers_by_strid): Adjust to
10578 std::vector.
10579 * common/rsp-low.h (hex2str): New overload with explicit count
10580 of bytes.
10581 * common/rsp-low.c (hex2str): New overload with explicit count
10582 of bytes.
10583 * unittests/rsp-low-selftests.c (test_hex2str): New function.
10584 (_initialize_rsp_low_selftests): Add test_hex2str test.
10585 * unittests/tracepoint-selftests.c
10586 (test_parse_static_tracepoint_marker_definition): Adjust to
10587 std::string.
10588
10589 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10590
10591 * tracepoint.c (parse_static_tracepoint_marker_definition):
10592 Consider case where the definition is followed by more
10593 definitions.
10594 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10595 tracepoint-selftests.c.
10596 * unittests/tracepoint-selftests.c: New.
10597
10598 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10599
10600 * MAINTAINERS (Write After Approval): Add Pedro Franco de
10601 Carvalho.
10602
10603 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10604
10605 * symtab.c (find_pc_sect_line): fixed indentation.
10606
10607 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10608
10609 * symtab.c (find_pc_sect_line): now uses binary search.
10610
10611 2018-03-19 Tom Tromey <tom@tromey.com>
10612
10613 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
10614 "IDENT" production.
10615
10616 2018-03-19 Pedro Alves <palves@redhat.com>
10617 Tom Tromey <tom@tromey.com>
10618
10619 * unittests/observable-selftests.c: New file.
10620 * common/observable.h: New file.
10621 * observable.h: New file.
10622 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
10623 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
10624 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
10625 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
10626 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
10627 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
10628 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
10629 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
10630 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
10631 python/py-breakpoint.c, python/py-finishbreakpoint.c,
10632 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
10633 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
10634 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
10635 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
10636 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
10637 tui/tui-interp.c, valops.c: Update all users.
10638 * tui/tui-hooks.c (tui_bp_created_observer)
10639 (tui_bp_deleted_observer, tui_bp_modified_observer)
10640 (tui_inferior_exit_observer, tui_before_prompt_observer)
10641 (tui_normal_stop_observer, tui_register_changed_observer):
10642 Remove.
10643 (tui_observers_token): New global.
10644 (attach_or_detach, tui_attach_detach_observers): New functions.
10645 (tui_install_hooks, tui_remove_hooks): Use
10646 tui_attach_detach_observers.
10647 * record-btrace.c (record_btrace_thread_observer): Remove.
10648 (record_btrace_thread_observer_token): New global.
10649 * observer.sh: Remove.
10650 * observer.c: Rename to observable.c.
10651 * observable.c (namespace gdb_observers): Define new objects.
10652 (observer_debug): Move into gdb_observers namespace.
10653 (struct observer, struct observer_list, xalloc_observer_list_node)
10654 (xfree_observer_list_node, generic_observer_attach)
10655 (generic_observer_detach, generic_observer_notify): Remove.
10656 (_initialize_observer): Update.
10657 Don't include observer.inc.
10658 * Makefile.in (generated_files): Remove observer.h, observer.inc.
10659 (clean mostlyclean): Likewise.
10660 (observer.h, observer.inc): Remove targets.
10661 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
10662 (COMMON_SFILES): Use observable.c, not observer.c.
10663 * .gitignore: Remove observer.h.
10664
10665 2018-03-18 Tom Tromey <tom@tromey.com>
10666
10667 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
10668 gdb::def_vector.
10669 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
10670
10671 2018-03-17 Tom Tromey <tom@tromey.com>
10672
10673 * auto-load.c (auto_load_objfile_script_1): Use std::string.
10674
10675 2018-03-17 Tom Tromey <tom@tromey.com>
10676
10677 * target.c (class scoped_target_fd): New.
10678 (target_fileio_close_cleanup): Remove.
10679 (target_fileio_read_alloc_1): Use scoped_target_fd.
10680
10681 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
10682
10683 * silent-rules.mk: New.
10684 * Makefile.in: Include silent-rules.mk
10685 (srcdir, VPATH, top_srcdir): Move up.
10686 (COMPILE): Add ECHO_CXX.
10687 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
10688 (init.c): Add ECHO_INIT_C.
10689 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
10690 (version.c): Add ECHO_GEN.
10691 (printcmd.o): Add ECHO_CXX.
10692 (target-float.o): Add ECHO_CXX.
10693 (ada-exp.o): Add ECHO_CXX.
10694 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
10695 (insight$(EXEEXT)): Add ECHO_CXXLD.
10696 * gnulib/configure.ac: Add AM_SILENT_RULES.
10697 * gnulib/aclocal.m4: Re-generate.
10698 * gnulib/configure: Re-generate.
10699 * gnulib/import/Makefile.in: Re-generate.
10700
10701 2018-03-16 Tom Tromey <tom@tromey.com>
10702
10703 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
10704 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
10705 * utils.c (do_free_section_addr_info)
10706 (make_cleanup_free_section_addr_info): Remove.
10707 * symfile.h (struct other_sections): Add constructor.
10708 (struct section_addr_info): Remove.
10709 (section_addr_info): New typedef.
10710 (struct sym_fns) <sym_offsets>: Change type of parameter.
10711 (build_section_addr_info_from_objfile)
10712 (relative_addr_info_to_section_offsets, addr_info_make_relative)
10713 (default_symfile_offsets, symbol_file_add)
10714 (symbol_file_add_from_bfd)
10715 (build_section_addr_info_from_section_table): Update.
10716 (alloc_section_addr_info, free_section_addr_info): Don't declare.
10717 * symfile.c (alloc_section_addr_info): Remove.
10718 (build_section_addr_info_from_section_table): Change return type.
10719 Update.
10720 (build_section_addr_info_from_bfd)
10721 (build_section_addr_info_from_objfile): Likewise.
10722 (free_section_addr_info): Remove.
10723 (relative_addr_info_to_section_offsets): Change type of "addrs".
10724 (addrs_section_compar): Now a std::sort comparator.
10725 (addrs_section_sort): Change return type.
10726 (addr_info_make_relative): Change type of "addrs". Update.
10727 (default_symfile_offsets, syms_from_objfile_1)
10728 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
10729 (symbol_file_add_separate): Update.
10730 (symbol_file_add): Change type of "addrs". Update.
10731 (add_symbol_file_command): Update. Remove cleanups.
10732 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
10733 cleanups.
10734 * symfile-debug.c (debug_sym_offsets): Change type of "info".
10735 * solib.c (solib_read_symbols): Update.
10736 * objfiles.c (objfile_relocate): Update. Remove cleanups.
10737 * machoread.c (macho_symfile_offsets): Update.
10738 * jit.c (jit_bfd_try_read_symtab): Update.
10739
10740 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
10741
10742 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10743 unittests/utils-selftests.c.
10744 * unittests/utils-selftests.c: New file.
10745
10746 2018-03-14 Tom Tromey <tom@tromey.com>
10747
10748 PR cli/14977:
10749 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
10750 for NULL.
10751
10752 2018-03-14 Tom Tromey <tom@tromey.com>
10753
10754 PR cli/19918:
10755 * printcmd.c (printf_pointer): Allow "-" in format.
10756
10757 2018-03-14 Tom Tromey <tom@tromey.com>
10758
10759 * printcmd.c (_initialize_printcmd): Add usage to printf.
10760
10761 2018-03-14 Yao Qi <qiyao@sourceware.org>
10762
10763 * MAINTAINERS: Update my email address.
10764
10765 2018-03-13 Tom Tromey <tom@tromey.com>
10766
10767 * machoread.c (macho_check_dsym): Change filenamep to a
10768 std::string*.
10769 (macho_symfile_read): Update.
10770 * symfile.c (load_command): Use std::string.
10771
10772 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
10773
10774 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
10775 to error message string.
10776 (riscv_register_name): Use xsnprintf instead of sprintf.
10777 (riscv_insn::fetch_instruction): Use gdb_assert instead of
10778 internal_error.
10779 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
10780 error.
10781 (riscv_push_dummy_call): Likewise.
10782
10783 2018-03-12 Tom Tromey <tom@tromey.com>
10784
10785 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
10786 Use gdb::byte_vector.
10787 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
10788
10789 2018-03-12 Yao Qi <yao.qi@linaro.org>
10790
10791 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
10792 parameter type to readable_regcache.
10793 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
10794 the declaration.
10795
10796 2018-03-11 Tom Tromey <tom@tromey.com>
10797
10798 * dwarf2read.c (struct nextfield): Add initializers.
10799 (struct nextfnfield): Remove.
10800 (struct fnfieldlist): Add initializers. Remove "length" and
10801 "head", use std::vector.
10802 (struct decl_field_list): Remove.
10803 (struct field_info): Add initializers.
10804 <fields, baseclasses>: Now std::vector.
10805 <nbaseclasses, nfnfields, typedef_field_list_count,
10806 nested_types_list_count>: Remove.
10807 (dwarf2_add_field, dwarf2_add_type_defn)
10808 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
10809 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
10810 (process_structure_scope): Update.
10811
10812 2018-03-11 Tom Tromey <tom@tromey.com>
10813
10814 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
10815 for use by std::sort.
10816 (build_type_psymtabs_1): Use std::vector.
10817
10818 2018-03-09 Eli Zaretskii <eliz@gnu.org>
10819
10820 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
10821 and LIBMPFR in the printed configuration.
10822
10823 2018-03-08 Tom Tromey <tom@tromey.com>
10824
10825 * source.c (get_filename_and_charpos): Use scoped_fd.
10826 * nto-procfs.c (procfs_open_1): Use scoped_fd.
10827 (procfs_pidlist): Likewise.
10828 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
10829 (iterate_over_mappings): Likewise.
10830
10831 2018-03-08 Tom Tromey <tom@tromey.com>
10832
10833 * infcall.c (struct call_return_meta_info)
10834 <stack_temporaries_enabled>: Remove.
10835 (get_call_return_value, call_function_by_hand_dummy): Update.
10836 * thread.c (disable_thread_stack_temporaries): Remove.
10837 (enable_thread_stack_temporaries): Remove.
10838 (thread_stack_temporaries_enabled_p): Return bool.
10839 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
10840 (get_last_thread_stack_temporary): Update.
10841 * eval.c (evaluate_subexp): Update.
10842 * gdbthread.h (class enable_thread_stack_temporaries): Now a
10843 class, not a function.
10844 (value_ptr, value_vec): Remove typedefs.
10845 (class thread_info) <stack_temporaries_enabled>: Now bool.
10846 <stack_temporaries>: Now a std::vector.
10847 (thread_stack_temporaries_enabled_p)
10848 (value_in_thread_stack_temporaries): Return bool.
10849
10850 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
10851
10852 * remote.c (putpkt_binary): Fix omitted bytes reporting.
10853 (getpkt_or_notif_sane_1): Likewise.
10854
10855 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10856
10857 * build-id.c (build_id_to_debug_bfd): Use std::string.
10858
10859 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10860
10861 * build-id.c (find_separate_debug_file_by_buildid): Return
10862 std::string.
10863 * build-id.h (find_separate_debug_file_by_buildid): Return
10864 std::string.
10865 * coffread.c (coff_symfile_read): Adjust to std::string.
10866 * elfread.c (elf_symfile_read): Adjust to std::string.
10867 * symfile.c (separate_debug_file_exists): Change parameter to
10868 std::string.
10869 (find_separate_debug_file): Return std::string.
10870 (find_separate_debug_file_by_debuglink): Return std::string.
10871 * symfile.h (find_separate_debug_file_by_debuglink): Return
10872 std::string.
10873
10874 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10875
10876 * common/xml-utils.c (xml_escape_text): Move code to...
10877 (xml_escape_text_append): ... this new function.
10878 * common/xml-utils.h (xml_escape_text_append): New declaration.
10879 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
10880 New function.
10881 (_initialize_xml_utils): register test_xml_escape_text_append as
10882 a selftest.
10883
10884 2018-03-07 Alan Hayward <alan.hayward@arm.com>
10885
10886 * defs.h: Remove MAX_REGISTER_SIZE.
10887 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
10888 asserts.
10889 * python/py-unwind.c (pyuw_sniffer): Likewise.
10890
10891 2018-03-07 Tom Tromey <tom@tromey.com>
10892
10893 * linux-tdep.c (linux_info_proc): Update.
10894 * target.h (struct target_ops) <to_fileio_readlink>: Return
10895 optional<string>.
10896 (target_fileio_readlink): Return optional<string>.
10897 * remote.c (remote_hostio_readlink): Return optional<string>.
10898 * inf-child.c (inf_child_fileio_readlink): Return
10899 optional<string>.
10900 * target.c (target_fileio_readlink): Return optional<string>.
10901
10902 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
10903
10904 * regcache.c (cooked_read_test): Add riscv to the list of
10905 architectures that have a save_reggroup.
10906
10907 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
10908
10909 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
10910 value is not a dynamic class object.
10911
10912 2018-03-06 Tom Tromey <tom@tromey.com>
10913
10914 * rust-exp.y: Formatting fixes.
10915
10916 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10917
10918 * riscv-tdep.c (riscv_register_name): Remove target description
10919 support.
10920 (riscv_gdbarch_init): Remove target description check.
10921
10922 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10923
10924 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
10925 comment.
10926 * riscv-tdep.h: Likewise.
10927
10928 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10929
10930 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
10931 (riscv_pseudo_register_write): Delete.
10932 (riscv_gdbarch_init): Remove all use of pseudo registers.
10933
10934 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10935
10936 * record-btrace.c (btrace_print_lines): Replace cleanup
10937 parameter with RAII equivalents.
10938 (btrace_insn_history): Replace cleanup with RAII equivalents.
10939 * ui-out.h (make_cleanup_ui_out_list_begin_end,
10940 make_cleanup_ui_out_tuple_begin_end): Remove.
10941 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
10942 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
10943 make_cleanup_ui_out_list_begin_end): Remove.
10944
10945 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10946
10947 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
10948 parameter types to std::vector. Use bool.
10949 (record_btrace_wait): Replace VEC(tp_t) with
10950 std::vector<thread_info *>.
10951 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
10952
10953 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10954
10955 * record-btrace.c (record_btrace_disable_callback): Remove.
10956 (struct scoped_btrace_disable): New.
10957 (record_btrace_open): Use scoped_btrace_disable.
10958
10959 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10960
10961 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
10962 reading values from registers.
10963
10964 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10965
10966 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
10967 where appropriate.
10968
10969 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10970
10971 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
10972 change parameter type. Use GDB's print functions, and use
10973 core_addr_to_string where appropriate.
10974 (riscv_push_dummy_call): Use core_addr_to_string where
10975 appropriate, update call to riscv_print_arg_location, and reindent
10976 a few lines.
10977 (riscv_return_value): Update call to riscv_print_arg_location.
10978
10979 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10980 Tim Newsome <tim@sifive.com>
10981 Albert Ou <a0u@eecs.berkeley.edu>
10982 Darius Rad <darius@bluespec.com>
10983
10984 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
10985 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
10986 (ALLDEPFILES): Add riscv-tdep.c
10987 * configure.tgt: Add riscv support.
10988 * riscv-tdep.c: New file.
10989 * riscv-tdep.h: New file.
10990 * NEWS: Mention new target.
10991 * MAINTAINERS: Add entry for riscv.
10992
10993 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10994
10995 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
10996 fields within aggregates.
10997
10998 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
10999
11000 * record-btrace.c (btrace_print_lines): Change type of flags to
11001 gdb_disassembly_flags.
11002
11003 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11004
11005 * fbsd-nat.c: Include "inf-ptrace.h".
11006 (USE_SIGTRAP_SIGINFO): Conditionally define.
11007 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
11008 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
11009 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
11010 function.
11011 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
11012 Likewise.
11013 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
11014 Likewise.
11015 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
11016 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
11017 "supports_stopped_by_hw_breakpoint" target methods.
11018
11019 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11020
11021 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
11022 * fbsd-nat.c (debug_fbsd_nat): New variable.
11023 (show_fbsd_nat_debug): New function.
11024 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
11025 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
11026
11027 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11028
11029 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
11030 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
11031 prototype.
11032 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
11033 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
11034 method.
11035
11036 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11037
11038 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
11039 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
11040
11041 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11042
11043 * charset.c (struct charset_vector): New.
11044 (charsets): Change type to charset_vector.
11045 (find_charset_names): Adjust.
11046 (add_one): Adjust.
11047 (_initialize_charset): Adjust.
11048
11049 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11050
11051 * progspace.h (struct program_space) <deleted_solibs>: Change
11052 type to std::vector<std::string>.
11053 * progspace.c (clear_program_space_solib_cache): Adjust.
11054 * breakpoint.c (print_solib_event): Adjust.
11055 (check_status_catch_solib): Adjust.
11056 * solib.c (update_solib_list): Adjust.
11057 * ui-out.h (class ui_out) <field_string>: New overload.
11058 * ui-out.c (ui_out::field_string): New overload.
11059
11060 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11061
11062 * progspace.h (struct program_space): Add constructor and
11063 destructor, initialize fields.
11064 (add_program_space): Remove.
11065 * progspace.c (add_program_space): Rename to...
11066 (program_space::program_space): ... this.
11067 (release_program_space): Rename to...
11068 (program_space::~program_space): ... this.
11069 (delete_program_space): Use delete to delete program_space.
11070 (initialize_progspace): Use new to allocate program_space.
11071 * inferior.c (add_inferior_with_spaces): Likewise.
11072 (clone_inferior_command): Likewise.
11073 * infrun.c (follow_fork_inferior): Likewise.
11074 (handle_vfork_child_exec_or_exit): Likewise.
11075
11076 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11077
11078 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
11079 (delim_string_to_char_ptr_vec): Return std::vector of
11080 gdb::unique_xmalloc_ptr.
11081 (dirnames_to_char_ptr_vec_append): Take std::vector of
11082 gdb::unique_xmalloc_ptr.
11083 (dirnames_to_char_ptr_vec): Return std::vector of
11084 gdb::unique_xmalloc_ptr.
11085 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
11086 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
11087 (delim_string_to_char_ptr_vec): Return an std::vector of
11088 gdb::unique_xmalloc_ptr, adjust the code.
11089 (dirnames_to_char_ptr_vec_append): Take an std::vector of
11090 gdb::unique_xmalloc_ptr, adjust the code.
11091 (dirnames_to_char_ptr_vec): Return an std::vector of
11092 gdb::unique_xmalloc_ptr, adjust the code.
11093 * auto-load.c (auto_load_safe_path_vec): Change type to
11094 std::vector of gdb::unique_xmalloc_ptr.
11095 (auto_load_expand_dir_vars): Return an std::vector of
11096 gdb::unique_xmalloc_ptr, adjust the code.
11097 (auto_load_safe_path_vec_update): Adjust.
11098 (filename_is_in_auto_load_safe_path_vec): Adjust.
11099 (auto_load_objfile_script_1): Adjust.
11100 * build-id.c (build_id_to_debug_bfd): Adjust.
11101 * linux-thread-db.c (thread_db_load_search): Adjust.
11102 * source.c (add_path): Adjust.
11103 (openp): Adjust.
11104 * symfile.c (find_separate_debug_file): Adjust.
11105 * utils.c (do_free_char_ptr_vec): Remove.
11106 (make_cleanup_free_char_ptr_vec): Remove.
11107
11108 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
11109
11110 PR gdb/22907
11111 * common/pathstuff.c: Conditionally include "<windows.h>".
11112
11113 2018-03-01 Georg Sauthoff <mail@georg.so>
11114
11115 PR gdb/22888
11116 * gcore.in: Quote variables and switch interpreter to bash.
11117
11118 2018-03-01 Tom Tromey <tom@tromey.com>
11119
11120 * dwarf2read.c (alloc_discriminant_info): Fix default_index
11121 assertion. Add assertion for discriminant_index.
11122 (quirk_rust_enum): Use correct base type name in univariant case.
11123
11124 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
11125
11126 * record.c (get_call_history_modifiers): Return a
11127 record_print_flags.
11128 (cmd_record_call_history): Adjust.
11129 * record-btrace.c (record_btrace_call_history): Adjust.
11130 (record_btrace_call_history_range): Adjust.
11131 (record_btrace_call_history_from): Adjust.
11132 * target-debug.h (target_debug_print_record_print_flags): New.
11133 * target-delegates.c: Re-generate.
11134 * target.c (target_call_history): Change flags type.
11135 (target_call_history_from): Likewise.
11136 (target_call_history_range): Likewise.
11137 * target.h (struct target_ops) <target_call_history>: Likewise.
11138 (target_call_history_from): Likewise.
11139 (target_call_history_range): Likewise.
11140
11141 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11142 Simon Marchi <simon.marchi@polymtl.ca>
11143
11144 * common/common-utils.c: Include "sys/stat.h".
11145 (is_regular_file): Move here from "source.c"; change return
11146 type to "bool".
11147 * common/common-utils.h (is_regular_file): New prototype.
11148 * common/pathstuff.c (contains_dir_separator): New function.
11149 * common/pathstuff.h (contains_dir_separator): New prototype.
11150 * source.c: Don't include "sys/stat.h".
11151 (is_regular_file): Move to "common/common-utils.c".
11152
11153 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11154
11155 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
11156 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
11157 * auto-load.c: Include "common/pathstuff.h".
11158 * common/common-def.h (current_directory): Move here.
11159 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
11160 function.
11161 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
11162 prototype.
11163 * common/pathstuff.c: New file.
11164 * common/pathstuff.h: New file.
11165 * compile/compile.c: Include "common/pathstuff.h".
11166 * defs.h (current_directory): Move to "common/common-defs.h".
11167 * dwarf2read.c: Include "common/pathstuff.h".
11168 * exec.c: Likewise.
11169 * guile/scm-safe-call.c: Likewise.
11170 * linux-thread-db.c: Likewise.
11171 * main.c: Likewise.
11172 * nto-tdep.c: Likewise.
11173 * objfiles.c: Likewise.
11174 * source.c: Likewise.
11175 * symtab.c: Likewise.
11176 * utils.c: Include "common/pathstuff.h".
11177 (gdb_realpath): Move to "common/pathstuff.c".
11178 (gdb_realpath_keepfile): Likewise.
11179 (gdb_abspath): Likewise.
11180 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
11181 (gdb_realpath_keepfile): Likewise.
11182 (gdb_abspath): Likewise.
11183
11184 2018-02-28 John Baldwin <jhb@FreeBSD.org>
11185
11186 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
11187 wildcard process pid for super_resume for kernels with a
11188 specific bug.
11189
11190 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
11191
11192 * compile/compile.c (get_args): Add additional comments
11193 explaining function.
11194
11195 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
11196 Tom Tromey <tom@tromey.com>
11197
11198 * target.h (memory_write_request_s): Remove typedef. Don't define
11199 VEC.
11200 (target_write_memory_blocks): Change argument to std::vector.
11201 (struct memory_write_request): Add constructor.
11202 * target-memory.c (compare_block_starting_address): Return bool.
11203 Change argument types.
11204 (claim_memory): Change arguments to use std::vector.
11205 (split_regular_and_flash_blocks, blocks_to_erase)
11206 (compute_garbled_blocks): Likewise.
11207 (cleanup_request_data, cleanup_write_requests_vector): Remove.
11208 (target_write_memory_blocks): Change argument to std::vector.
11209 * symfile.c (struct load_section_data): Add constructor and
11210 destructor. Use std::vector for "requests".
11211 (struct load_progress_data): Add initializers.
11212 (load_section_callback): Update. Use "new".
11213 (clear_memory_write_data): Remove.
11214 (generic_load): Update.
11215
11216 2018-02-27 Alan Hayward <alan.hayward@arm.com>
11217
11218 * arch/aarch64.h: Use common/tdesc.h.
11219
11220 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11221
11222 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
11223 architecture with a 64-bit ABI.
11224
11225 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11226
11227 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
11228 ahead of target description loading.
11229
11230 2018-02-26 Tom Tromey <tom@tromey.com>
11231
11232 * stack.c (backtrace_command_1): Update.
11233 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
11234 of "flags".
11235 * python/py-framefilter.c (py_print_frame)
11236 (gdbpy_apply_frame_filter): Change type of "flags".
11237 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
11238 of "flags".
11239 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
11240 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
11241 * extension.h (enum frame_filter_flag): Rename from
11242 frame_filter_flags.
11243 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
11244 (apply_ext_lang_frame_filter): Change type of "flags".
11245 * extension.c (apply_ext_lang_frame_filter): Change type of
11246 "flags".
11247 * extension-priv.h (struct extension_language_ops)
11248 <apply_frame_filter>: Change type of "flags".
11249
11250 2018-02-26 Tom Tromey <tom@tromey.com>
11251
11252 PR python/16497:
11253 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
11254 off-by-one in py_end computation.
11255 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
11256 PRINT_MORE_FRAMES.
11257 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
11258 constant.
11259
11260 2018-02-26 Tom Tromey <tom@tromey.com>
11261
11262 * dwarf2read.c (struct variant_field): New.
11263 (struct nextfield) <variant>: New field.
11264 (dwarf2_add_field): Handle DW_TAG_variant_part.
11265 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
11266 discriminated union.
11267 (read_structure_type): Handle DW_TAG_variant_part.
11268 (handle_struct_member_die): New function, extracted from
11269 process_structure_scope. Handle DW_TAG_variant.
11270 (process_structure_scope): Handle discriminated unions. Call
11271 handle_struct_member_die.
11272
11273 2018-02-26 Tom Tromey <tom@tromey.com>
11274
11275 * rust-lang.h (rust_last_path_segment): Declare.
11276 * rust-lang.c (rust_last_path_segment): Now public. Change
11277 contract.
11278 (struct disr_info): Remove.
11279 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
11280 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
11281 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
11282 (rust_enum_p, rust_enum_variant): New function.
11283 (rust_underscore_fields): Remove "offset" parameter.
11284 (rust_print_enum): New function.
11285 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
11286 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
11287 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
11288 enums.
11289 (rust_internal_print_type): New function, from rust_print_type.
11290 Remove enum code.
11291 (rust_print_type): Call rust_internal_print_type.
11292 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
11293 Update enum handling.
11294 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
11295 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
11296 (rust_union_quirks): New functions.
11297 (process_full_comp_unit, process_full_type_unit): Call
11298 rust_union_quirks.
11299 (process_structure_scope): Update rust_unions if necessary.
11300
11301 2018-02-26 Tom Tromey <tom@tromey.com>
11302
11303 * value.h (value_union_variant): Declare.
11304 * valops.c (value_union_variant): New function.
11305 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
11306 (struct discriminant_info): New.
11307 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
11308 enumerator.
11309 (struct main_type) <flag_discriminated_union>: New field.
11310
11311 2018-02-26 Tom Tromey <tom@tromey.com>
11312
11313 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11314 unittests/unpack-selftests.c.
11315 * unittests/unpack-selftests.c: New file.
11316 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
11317
11318 2018-02-26 Yao Qi <yao.qi@linaro.org>
11319
11320 * dwarf2read.c (struct partial_die_info) <read>: New method.
11321 (read_partial_die): Remove the declaration.
11322 (load_partial_dies): Update.
11323 (partial_die_info::partial_die_info):
11324 (read_partial_die): Change it to partial_die_info::read.
11325
11326 2018-02-26 Yao Qi <yao.qi@linaro.org>
11327
11328 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
11329 (fixup_partial_die): Remove declaration.
11330 (scan_partial_symbols): Update.
11331 (partial_die_parent_scope): Likewise.
11332 (partial_die_full_name): Likewise.
11333 (fixup_partial_die): Change it to partial_die_info::fixup.
11334
11335 2018-02-26 Yao Qi <yao.qi@linaro.org>
11336
11337 * dwarf2read.c (read_partial_die): Update the declaration.
11338 (load_partial_dies): Caller update.
11339 (read_partial_die): Remove one argument abbrev_len.
11340
11341 2018-02-26 Yao Qi <yao.qi@linaro.org>
11342
11343 * dwarf2read.c (struct partial_die_info): Add ctor, delete
11344 assignment operator.
11345 (load_partial_dies): Use ctor and copy ctor.
11346 (read_partial_die): Update.
11347 (dwarf2_cu::find_partial_die): Use ctor.
11348
11349 2018-02-26 Yao Qi <yao.qi@linaro.org>
11350
11351 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
11352 (find_partial_die_in_comp_unit): Change it to
11353 dwarf2_cu::find_partial_die.
11354 (find_partial_die): Update.
11355
11356 2018-02-26 Yao Qi <yao.qi@linaro.org>
11357
11358 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
11359 is NULL.
11360
11361 2018-02-26 Yao Qi <yao.qi@linaro.org>
11362
11363 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
11364
11365 2018-02-26 Alan Hayward <alan.hayward@arm.com>
11366
11367 * arch/amd64.h: Use common/tdesc.h.
11368 * arch/i386.c: Likewise.
11369 * arch/i386.h: Likewise.
11370 * arch/tic6x.c: Likewise.
11371 * arch/tdesc.h: Move file from here...
11372 * common/tdesc.h: ...to here.
11373 * features/aarch64-core.c: Regenerate.
11374 * features/aarch64-fpu.c: Regenerate.
11375 * features/i386/32bit-avx.c: Regenerate.
11376 * features/i386/32bit-avx512.c: Regenerate.
11377 * features/i386/32bit-core.c: Regenerate.
11378 * features/i386/32bit-linux.c: Regenerate.
11379 * features/i386/32bit-mpx.c: Regenerate.
11380 * features/i386/32bit-pkeys.c: Regenerate.
11381 * features/i386/32bit-sse.c: Regenerate.
11382 * features/i386/64bit-avx.c: Regenerate.
11383 * features/i386/64bit-avx512.c: Regenerate.
11384 * features/i386/64bit-core.c: Regenerate.
11385 * features/i386/64bit-linux.c: Regenerate.
11386 * features/i386/64bit-mpx.c: Regenerate.
11387 * features/i386/64bit-pkeys.c: Regenerate.
11388 * features/i386/64bit-segments.c: Regenerate.
11389 * features/i386/64bit-sse.c: Regenerate.
11390 * features/i386/x32-core.c: Regenerate.
11391 * features/tic6x-c6xp.c: Regenerate.
11392 * features/tic6x-core.c: Regenerate.
11393 * features/tic6x-gp.c: Regenerate.
11394 * target-descriptions.c: Use common/tdesc.h.
11395 * target-descriptions.h: Likewise.
11396
11397 2018-02-24 Tom Tromey <tom@tromey.com>
11398
11399 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
11400 (try_thread_db_load_from_dir, thread_db_load_search): Use
11401 std::string.
11402 (info_auto_load_libthread_db_compare): Return bool. Change
11403 argument types.
11404 (info_auto_load_libthread_db): Use std::vector, std::string.
11405 Remove cleanups.
11406
11407 2018-02-24 Tom Tromey <tom@tromey.com>
11408
11409 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
11410 std::string.
11411 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
11412 std::string*.
11413 * gdbarch.c: Rebuild.
11414 * gdbarch.h: Rebuild.
11415 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
11416 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
11417 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
11418 std::string*.
11419
11420 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
11421
11422 * gdbtypes.h (sect_offset): Change type to uint64_t.
11423 (sect_offset_str): New function.
11424 * dwarf2read.c (create_addrmap_from_aranges): Use
11425 sect_offset_str.
11426 (error_check_comp_unit_head): Likewise.
11427 (create_debug_type_hash_table): Likewise.
11428 (read_cutu_die_from_dwo): Likewise.
11429 (init_cutu_and_read_dies): Likewise.
11430 (init_cutu_and_read_dies_no_follow): Likewise.
11431 (process_psymtab_comp_unit_reader): Likewise.
11432 (partial_die_parent_scope): Likewise.
11433 (peek_die_abbrev): Likewise.
11434 (process_queue): Likewise.
11435 (dwarf2_physname): Likewise.
11436 (read_namespace_alias): Likewise.
11437 (read_import_statement): Likewise.
11438 (create_dwo_cu_reader): Likewise.
11439 (create_cus_hash_table): Likewise.
11440 (lookup_dwo_cutu): Likewise.
11441 (inherit_abstract_dies): Likewise.
11442 (read_func_scope): Likewise.
11443 (read_call_site_scope): Likewise.
11444 (dwarf2_add_member_fn): Likewise.
11445 (read_common_block): Likewise.
11446 (read_module_type): Likewise.
11447 (read_typedef): Likewise.
11448 (read_subrange_type): Likewise.
11449 (load_partial_dies): Likewise.
11450 (read_partial_die): Likewise.
11451 (find_partial_die): Likewise.
11452 (read_str_index): Likewise.
11453 (dwarf2_string_attr): Likewise.
11454 (build_error_marker_type): Likewise.
11455 (lookup_die_type): Likewise.
11456 (dump_die_shallow): Likewise.
11457 (follow_die_ref): Likewise.
11458 (dwarf2_fetch_die_loc_sect_off): Likewise.
11459 (dwarf2_fetch_constant_bytes): Likewise.
11460 (follow_die_sig): Likewise.
11461 (get_signatured_type): Likewise.
11462 (get_DW_AT_signature_type): Likewise.
11463 (dwarf2_find_containing_comp_unit): Likewise.
11464 (set_die_type): Likewise.
11465
11466 2018-02-21 John Baldwin <jhb@FreeBSD.org>
11467
11468 * arch/aarch64.c: Include "common-defs.h".
11469 * arch/amd64.c: Likewise.
11470 * arch/i386.c: Likewise.
11471
11472 2018-02-21 Tom Tromey <tom@tromey.com>
11473
11474 * value.h: (extract_field_op): Update.
11475 * eval.c (extract_field_op): Return a const char *.
11476 * expression.h (parse_expression_for_completion): Update.
11477 * completer.c (complete_expression): Update.
11478 (add_struct_fields): Make fieldname const.
11479 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
11480 (mark_completion_tag, parse_exp_in_context_1): Update.
11481 (parse_expression_for_completion): Change "name" to
11482 unique_xmalloc_ptr*.
11483
11484 2018-02-21 Tom Tromey <tom@tromey.com>
11485
11486 * infcall.c (call_function_by_hand_dummy): Use std::vector.
11487
11488 2018-02-21 Yao Qi <yao.qi@linaro.org>
11489
11490 * avr-tdep.c (avr_read_pc): Change parameter type to
11491 readable_regcache.
11492 * gdbarch.sh (read_pc): Likewise.
11493 * gdbarch.c: Re-generated.
11494 * gdbarch.h: Re-generated.
11495 * hppa-tdep.c (hppa_read_pc): Change parameter type to
11496 readable_regcache.
11497 * ia64-tdep.c (ia64_read_pc): Likewise.
11498 * mips-tdep.c (mips_read_pc): Likewise.
11499 * spu-tdep.c (spu_read_pc): Likewise.
11500
11501 2018-02-21 Yao Qi <yao.qi@linaro.org>
11502
11503 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
11504 * regcache-dump.c: New file.
11505 * regcache.c: Move register_dump to regcache-dump.c.
11506 (maintenance_print_registers): Likewise.
11507 (maintenance_print_raw_registers): Likewise.
11508 (maintenance_print_cooked_registers): Likewise.
11509 (maintenance_print_register_groups): Likewise.
11510 (maintenance_print_remote_registers): Likewise.
11511 (_initialize_regcache): Likewise.
11512 * regcache.h (register_dump): Moved from regcache.c.
11513
11514 2018-02-21 Yao Qi <yao.qi@linaro.org>
11515
11516 * regcache.c (regcache::regcache): Update.
11517 (regcache::invalidate): Move it to detached_regcache::invalidate.
11518 (get_thread_arch_aspace_regcache): Update.
11519 (regcache::raw_update): Update.
11520 (regcache::cooked_read): Remove some code.
11521 (regcache::cooked_read_value): Likewise.
11522 (regcache::raw_write): Remove assert on m_readonly_p.
11523 (regcache::raw_supply_integer): Move it to
11524 detached_regcache::raw_supply_integer.
11525 (regcache::raw_supply_zeroed): Likewise.
11526 * regcache.h (detached_regcache) <raw_supply_integer>: New
11527 declaration.
11528 <raw_supply_zeroed, invalidate>: Likewise.
11529 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
11530 <invalidate>: Likewise.
11531 <m_readonly_p>: Removed.
11532
11533 2018-02-21 Yao Qi <yao.qi@linaro.org>
11534
11535 * infcmd.c (get_return_value): Let stop_regs point to
11536 get_current_regcache.
11537 * regcache.c (regcache::regcache): Remove.
11538 (register_dump_reg_buffer): New class.
11539 (regcache_print): Adjust.
11540 * regcache.h (regcache): Remove constructors.
11541
11542 2018-02-21 Yao Qi <yao.qi@linaro.org>
11543
11544 * regcache.c (class register_dump): New class.
11545 (register_dump_regcache, register_dump_none): New class.
11546 (register_dump_remote, register_dump_groups): New class.
11547 (regcache_print): Update.
11548 * regcache.h (regcache_dump_what): Move it to regcache.c.
11549 (regcache) <dump>: Remove.
11550
11551 2018-02-21 Yao Qi <yao.qi@linaro.org>
11552
11553 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
11554 reg_buffer_rw *.
11555 (jit_unwind_reg_set_impl): Call raw_supply.
11556 (jit_frame_sniffer): Use reg_buffer_rw.
11557 * record-full.c (record_full_core_regbuf): Change its type.
11558 (record_full_core_open_1): Use reg_buffer_rw.
11559 (record_full_close): Likewise.
11560 (record_full_core_fetch_registers): Use regcache->raw_supply.
11561 (record_full_core_store_registers): Likewise.
11562 * regcache.c (regcache::get_register_status): Move it to
11563 reg_buffer.
11564 (regcache_raw_set_cached_value): Remove.
11565 (regcache::raw_set_cached_value): Remove.
11566 (regcache::raw_write): Call raw_supply.
11567 (regcache::raw_supply): Move it to reg_buffer_rw.
11568 * regcache.h (regcache_raw_set_cached_value): Remove.
11569 (reg_buffer_rw): New class.
11570
11571 2018-02-21 Yao Qi <yao.qi@linaro.org>
11572
11573 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
11574 readonly_detached_regcache.
11575 (dummy_frame_prev_register): Use regcache->cooked_read.
11576 * frame.c (frame_save_as_regcache): Change return type.
11577 (frame_pop): Update.
11578 * frame.h (frame_save_as_regcache): Update declaration.
11579 * inferior.h (get_infcall_suspend_state_regcache): Update
11580 declaration.
11581 * infrun.c (infcall_suspend_state) <registers>: use
11582 readonly_detached_regcache.
11583 (save_infcall_suspend_state): Don't use regcache_dup.
11584 (get_infcall_suspend_state_regcache): Change return type.
11585 * linux-fork.c (struct fork_info) <savedregs>: Change to
11586 readonly_detached_regcache.
11587 <pc>: New field.
11588 (fork_save_infrun_state): Don't use regcache_dup.
11589 (info_checkpoints_command): Adjust.
11590 * mi/mi-main.c (register_changed_p): Update declaration.
11591 (mi_cmd_data_list_changed_registers): Use
11592 readonly_detached_regcache.
11593 (register_changed_p): Change parameter type to
11594 readonly_detached_regcache.
11595 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
11596 readonly_detached_regcache.
11597 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
11598 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
11599 New.
11600 (regcache::save): Move it to reg_buffer.
11601 (regcache::restore): Change parameter type.
11602 (regcache_dup): Remove.
11603 * regcache.h (reg_buffer) <save>: New method.
11604 (readonly_detached_regcache): New class.
11605 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
11606 readonly_detached_regcache.
11607 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
11608
11609 2018-02-21 Yao Qi <yao.qi@linaro.org>
11610
11611 * frame.c (frame_save_as_regcache): Use regcache method save.
11612 (frame_pop): Use regcache method restore.
11613 * infrun.c (restore_infcall_suspend_state): Likewise.
11614 * linux-fork.c (fork_load_infrun_state): Likewise.
11615 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
11616 save.
11617 * regcache.c (regcache_save): Remove.
11618 (regcache::restore): More asserts.
11619 (regcache_cpy): Remove.
11620 * regcache.h (regcache_save): Remove the declaration.
11621 (regcache::restore): Move from private to public.
11622 Remove the friend declaration of regcache_cpy.
11623 (regcache_cpy): Remove declaration.
11624
11625 2018-02-21 Yao Qi <yao.qi@linaro.org>
11626
11627 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
11628 parameter type to 'readable_regcache *'.
11629 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
11630 * arm-tdep.c (arm_neon_quad_read): Likewise.
11631 (arm_pseudo_read): Likewise.
11632 * avr-tdep.c (avr_pseudo_register_read): Likewise.
11633 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
11634 * frv-tdep.c (frv_pseudo_register_read): Likewise.
11635 * gdbarch.c: Re-generated.
11636 * gdbarch.h: Re-generated.
11637 * gdbarch.sh (pseudo_register_read): Change parameter type to
11638 'readable_regcache *'.
11639 (pseudo_register_read_value): Likewise.
11640 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
11641 (h8300_pseudo_register_read): Likewise.
11642 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
11643 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
11644 (i386_pseudo_register_read_into_value): Likewise.
11645 (i386_pseudo_register_read_value): Likewise.
11646 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
11647 declaration.
11648 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
11649 * m32c-tdep.c (m32c_raw_read): Likewise.
11650 (m32c_read_flg): Likewise.
11651 (m32c_banked_register): Likewise.
11652 (m32c_banked_read): Likewise.
11653 (m32c_sb_read): Likewise.
11654 (m32c_part_read): Likewise.
11655 (m32c_cat_read): Likewise.
11656 (m32c_r3r2r1r0_read): Likewise.
11657 (m32c_pseudo_register_read): Likewise.
11658 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
11659 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
11660 (mep_pseudo_cr64_read): Likewise.
11661 (mep_pseudo_register_read): Likewise.
11662 * mips-tdep.c (mips_pseudo_register_read): Likewise.
11663 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
11664 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
11665 * regcache.c (regcache::raw_read): Move it to readable_regcache.
11666 (regcache::cooked_read): Likewise.
11667 (regcache::cooked_read_value): Likewise.
11668 (regcache_cooked_read_signed):
11669 (regcache::cooked_read): Likewise.
11670 * regcache.h (readable_regcache): New class.
11671 (regcache): Inherit readable_regcache. Move some methods to
11672 readable_regcache.
11673 * rl78-tdep.c (rl78_pseudo_register_read): Change
11674 parameter type to 'readable_regcache *'.
11675 * rs6000-tdep.c (do_regcache_raw_read): Remove.
11676 (e500_pseudo_register_read): Change parameter type to
11677 'readable_regcache *'.
11678 (dfp_pseudo_register_read): Likewise.
11679 (vsx_pseudo_register_read): Likewise.
11680 (efpr_pseudo_register_read): Likewise.
11681 * s390-tdep.c (s390_pseudo_register_read): Likewise.
11682 * sh-tdep.c (sh_pseudo_register_read): Likewise.
11683 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
11684 (sh64_pseudo_register_read): Likewise.
11685 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
11686 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
11687 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
11688 (spu_pseudo_register_read): Likewise.
11689 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
11690 (xtensa_pseudo_register_read): Likewise.
11691
11692 2018-02-21 Yao Qi <yao.qi@linaro.org>
11693
11694 * regcache.c (regcache::regcache): Call reg_buffer ctor.
11695 (regcache::arch): Move it to reg_buffer::arch.
11696 (regcache::register_buffer): Likewise.
11697 (regcache::assert_regnum): Likewise.
11698 (regcache::num_raw_registers): Likewise.
11699 * regcache.h (reg_buffer): New class.
11700 (regcache): Inherit reg_buffer.
11701
11702 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
11703
11704 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
11705 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
11706
11707 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
11708
11709 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
11710
11711 2018-02-19 Alan Hayward <alan.hayward@arm.com>
11712
11713 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
11714 (SFILES): Remove common/*.c files.
11715 (COMMON_OBS): Remove some *.o files built from common/*.c files.
11716 * common/common.host: Add common reference.
11717 * configure.ac: Likewise.
11718 * configure: Regenerate.
11719
11720 2018-02-16 Yao Qi <yao.qi@linaro.org>
11721
11722 * block.c (block_namespace_info): Inherit allocate_on_obstack.
11723 (block_initialize_namespace): Use new.
11724 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
11725 (dwarf2_free_objfile): Use delete.
11726 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
11727 (copy_type_recursive): Use new.
11728 * gdb_obstack.h (allocate_on_obstack): New.
11729
11730 2018-02-15 Yao Qi <yao.qi@linaro.org>
11731
11732 PR gdb/22849
11733 * inferior.c (exit_inferior_1): Reset inf->control.
11734
11735 2018-02-15 Joel Brobecker <brobecker@adacore.com>
11736
11737 * ada-lang.c (ada_to_fixed_value_create): Delete advance
11738 declaration.
11739
11740 2018-02-14 Pedro Alves <palves@redhat.com>
11741
11742 * frame-unwind.c (frame_unwind_try_unwinder): Always call
11743 frame_cleanup_after_sniffer on exception.
11744
11745 2018-02-14 Tom Tromey <tom@tromey.com>
11746
11747 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
11748 const.
11749 (solib_bfd_open): Make pathname const.
11750 * solib.c (solib_bfd_open): Make pathname const.
11751 * solib-spu.c (spu_bfd_fopen): Make name const.
11752 (spu_bfd_open): Make pathname const.
11753 * solib-darwin.c (darwin_bfd_open): Make pathname const.
11754 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
11755
11756 2018-02-14 Tom Tromey <tom@tromey.com>
11757
11758 * symfile.c (symfile_bfd_open): Update.
11759 * source.h (openp, source_full_path_of, find_and_open_source):
11760 Change argument type to unique_xmalloc_ptr.
11761 * source.c (openp): Take a unique_xmalloc_ptr.
11762 (source_full_path_of, find_and_open_source): Likewise.
11763 (open_source_file, symtab_to_fullname): Update.
11764 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
11765 unique_xmalloc_ptr.
11766 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
11767 (exec_file_find): Update.
11768 * psymtab.c (psymtab_to_fullname): Update.
11769 * nto-tdep.h (nto_find_and_open_solib): Update.
11770 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
11771 unique_xmalloc_ptr.
11772 * exec.c (exec_file_attach): Update.
11773 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
11774 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
11775
11776 2018-02-14 Tom Tromey <tom@tromey.com>
11777
11778 * solib.c: Include source.h.
11779 * nto-tdep.c: Include source.h.
11780 * mi/mi-cmd-env.c: Include source.h.
11781 * infcmd.c: Include source.h.
11782 * exec.c: Include source.h.
11783 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
11784 (add_path, directory_switch, source_path, init_source_path): Move
11785 declarations...
11786 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
11787 (add_path, directory_switch, source_path, init_source_path):
11788 ...here.
11789
11790 2018-02-14 Tom Tromey <tom@tromey.com>
11791
11792 * solist.h (exec_file_find, solib_find): Return
11793 unique_xmalloc_ptr.
11794 (solib_bfd_fopen): Take a const char *.
11795 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
11796 (exec_file_find, solib_find): Likewise.
11797 (solib_bfd_fopen): Do not take ownership of "pathname".
11798 (solib_bfd_open): Use unique_xmalloc_ptr.
11799 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
11800 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
11801 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
11802 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
11803
11804 2018-02-14 Joel Brobecker <brobecker@adacore.com>
11805
11806 * ada-lang.c (name_match_type_from_name): Remove reference to
11807 ada_name_for_lookup in function's documentation.
11808 * ada-lang.h (ada_name_for_lookup): Delete declaration.
11809
11810 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
11811
11812 * defs.h (enum openp_flags): New enum.
11813 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
11814 Move to enum openp_flags.
11815 (openp_flags): New enum flags.
11816 (openp): Change parameter type to openp_flags.
11817 * source.c (openp): Change parameter type to openp_flags.
11818 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
11819 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
11820
11821 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
11822
11823 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
11824 per-command.
11825
11826 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
11827
11828 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
11829 into...
11830 (class dwarf2_queue_guard): ...the destructor of this new class.
11831 (dw2_do_instantiate_symtab): Create instance of the new class
11832 dwarf2_queue_guard, remove cleanup.
11833
11834 2018-02-09 Tom Tromey <tom@tromey.com>
11835
11836 * source.c (find_source_lines): Don't reference past the end of
11837 the vector.
11838
11839 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11840
11841 * remote.c (remote_btrace_maybe_reopen): Change error message.
11842 * btrace.c (btrace_enable): Likewise.
11843 (parse_xml_btrace): Likewise.
11844 (parse_xml_btrace_conf): Likewise.
11845
11846 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11847
11848 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
11849 (linux_enable_pt, linux_enable_bts): Call
11850 diagnose_perf_event_open_fail.
11851
11852 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11853
11854 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
11855 Remove parameter and change return type. Update callers. Move it.
11856 (linux_enable_bts, linux_enable_pt): Improve error message.
11857 (linux_enable_pt): Remove zero buffer size check.
11858 (linux_enable_btrace): Improve error messages. Remove NULL return
11859 check.
11860
11861 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11862
11863 * btrace.c (btrace_enable): Remove target_supports_btrace call.
11864 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
11865 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
11866 (linux_supports_pt, linux_supports_btrace): Remove.
11867 (linux_enable_bts): Call cpu_supports_bts.
11868 * nat/linux-btrace.h (linux_supports_btrace): Remove.
11869 * remote.c (remote_supports_btrace): Remove.
11870 (init_remote_ops): Remove remote_supports_btrace.
11871 * target-delegates.c: Regenerated.
11872 * target.c (target_supports_btrace): Remove.
11873 * target.h (target_ops) <to_supports_btrace>: Remove
11874 (target_supports_btrace): Remove.
11875 * x86-linux-nat.c (x86_linux_create_target): Remove
11876 linux_supports_btrace.
11877
11878 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11879
11880 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
11881 btrace failed.
11882 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
11883 exception and use message in own exception.
11884
11885 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11886
11887 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
11888 (perf_event_pt_event_type): Use gdb_file_up.
11889 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
11890 scoped_fd, and scoped_mmap.
11891
11892 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11893
11894 * common/scoped_mmap.h: New.
11895 * unittests/scoped_mmap-selftest.c: New.
11896 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11897 unittests/scoped_mmap-selftest.c.
11898
11899 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11900
11901 * common/scoped_fd.h: New.
11902 * unittests/scoped_fd-selftest.c: New.
11903 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11904 unittests/scoped_fd-selftest.c.
11905
11906 2018-02-09 Tom Tromey <tom@tromey.com>
11907
11908 * auto-load.c (auto_load_section_scripts): Use
11909 gdb::unique_xmalloc_ptr.
11910
11911 2018-02-09 Tom Tromey <tom@tromey.com>
11912
11913 * auto-load.c (execute_script_contents): Use std::string.
11914
11915 2018-02-09 Joel Brobecker <brobecker@adacore.com>
11916
11917 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
11918 Python function, rather than a new command.
11919
11920 2018-02-08 Tom Tromey <tom@tromey.com>
11921
11922 * solib.c (solib_find_1): Use std::string.
11923 (solib_bfd_fopen): Use unique_xmalloc_ptr.
11924
11925 2018-02-08 Tom Tromey <tom@tromey.com>
11926
11927 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
11928
11929 2018-02-08 Tom Tromey <tom@tromey.com>
11930
11931 * source.c (find_source_lines): Use gdb::def_vector.
11932
11933 2018-02-08 Tom Tromey <tom@tromey.com>
11934
11935 * macrocmd.c (struct temporary_macro_definition): New.
11936 (macro_define_command): Use temporary_macro_definition. Remove
11937 cleanups.
11938 (free_macro_definition_ptr): Remove.
11939
11940 2018-02-08 Tom Tromey <tom@tromey.com>
11941
11942 * macroexp.c (maybe_expand): Use std::string.
11943
11944 2018-02-08 Tom Tromey <tom@tromey.com>
11945
11946 * macroexp.c (struct macro_buffer): Add initializers for some
11947 members.
11948 (init_buffer, init_shared_buffer, free_buffer)
11949 (free_buffer_return_text): Remove.
11950 (macro_buffer): New constructors.
11951 (~macro_buffer): New destructor.
11952 (macro_buffer::set_shared): New method.
11953 (macro_buffer::resize_buffer, macro_buffer::appendc)
11954 (macro_buffer::appendmem): Now methods, not free functions.
11955 (set_token, append_tokens_without_splicing, stringify)
11956 (macro_stringify): Update.
11957 (gather_arguments): Change return type. Remove argc_p argument,
11958 add args_ptr argument. Use std::vector.
11959 (substitute_args): Remove argc argument. Accept std::vector.
11960 (expand): Update. Use std::vector.
11961 (scan, macro_expand, macro_expand_next): Update.
11962
11963 2018-02-08 Tom Tromey <tom@tromey.com>
11964
11965 * symtab.c (default_collect_symbol_completion_matches_break_on):
11966 Use unique_xmalloc_ptr.
11967 * macroscope.h: (sal_macro_scope, user_macro_scope)
11968 (default_macro_scope): Return unique_xmalloc_ptr.
11969 * macroscope.c (sal_macro_scope, user_macro_scope)
11970 (default_macro_scope): Return unique_xmalloc_ptr.
11971 * macroexp.h (macro_expand, macro_expand_once): Return
11972 unique_xmalloc_ptr.
11973 * macroexp.c (macro_expand, macro_expand_once): Return
11974 unique_xmalloc_ptr.
11975 * macrocmd.c (macro_expand_command, macro_expand_once_command)
11976 (info_macro_command, info_macros_command): Use
11977 unique_xmalloc_ptr.
11978 * compile/compile-c-support.c (write_macro_definitions): Use
11979 unique_xmalloc_ptr.
11980 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
11981
11982 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
11983
11984 * value.c (value_static_field): Assign field type instead of
11985 containing type when returning an optimized out value.
11986
11987 2018-02-06 Yao Qi <yao.qi@linaro.org>
11988
11989 * ft32-tdep.c (ft32_read_pc): Remove.
11990 (ft32_write_pc): Remove.
11991 (ft32_gdbarch_init): Update.
11992 * m32r-tdep.c (m32r_read_pc): Remove.
11993 (m32r_gdbarch_init): Update.
11994 * mep-tdep.c (mep_read_pc): Remove.
11995 (mep_gdbarch_init): Update.
11996 * microblaze-tdep.c (microblaze_write_pc): Remove.
11997 (microblaze_gdbarch_init): Update.
11998 * mn10300-tdep.c (mn10300_read_pc): Remove.
11999 (mn10300_write_pc): Remove.
12000 (mn10300_gdbarch_init): Update.
12001 * moxie-tdep.c (moxie_read_pc): Remove.
12002 (moxie_write_pc): Remove.
12003 (moxie_gdbarch_init): Update.
12004
12005 2018-02-06 Yao Qi <yao.qi@linaro.org>
12006
12007 * expprint.c (print_subexp_standard): Handle
12008 OP_F77_UNDETERMINED_ARGLIST.
12009 (dump_subexp_body_standard): Likewise.
12010
12011 2018-02-05 Alan Hayward <alan.hayward@arm.com>
12012
12013 * target-descriptions.c (tdesc_element_visitor) Add empty
12014 implementations.
12015 (tdesc_type): Move make_gdb_type from here.
12016 (tdesc_type_builtin): Likewise.
12017 (tdesc_type_vector): Likewise.
12018 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
12019 (make_gdb_type_struct): Move from tdesc_type_with_fields.
12020 (make_gdb_type_union): Likewise.
12021 (make_gdb_type_flags): Likewise.
12022 (make_gdb_type_enum): Likewise.
12023 (make_gdb_type): New function.
12024 (tdesc_register_type): Use static make_gdb_type.
12025
12026 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
12027
12028 * infcmd.c (default_print_one_register_info): Align natural-format
12029 column values consistently one under another.
12030 (pad_to_column): New function.
12031
12032 2018-02-05 Joel Brobecker <brobecker@adacore.com>
12033
12034 * dwarf2read.c (dwarf2_physname): Move commment.
12035
12036 2018-02-01 Leszek Swirski <leszeks@google.com>
12037
12038 * varobj.c (varobj_formatted_print_options): Allow recursive
12039 pretty printing if pretty printing is enabled.
12040
12041 2018-02-01 Leszek Swirski <leszeks@google.com>
12042
12043 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
12044 names after a structop as a filename.
12045
12046 2018-02-01 Yao Qi <yao.qi@linaro.org>
12047
12048 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
12049 (arm_record_coproc_data_proc): Likewise.
12050
12051 2018-02-01 Yao Qi <yao.qi@linaro.org>
12052
12053 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
12054
12055 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
12056
12057 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
12058 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
12059
12060 2018-01-31 Pedro Alves <palves@redhat.com>
12061
12062 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
12063 * inflow.c (child_terminal_save_inferior): Wrap reference to
12064 tcgetpgrp in HAVE_TERMIOS_H.
12065 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
12066 _WIN32.
12067 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
12068 always iterate over all inferiors.
12069 (gdbsim_cntrl_c): Adjust.
12070 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
12071
12072 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12073
12074 * gdbtypes.c (lookup_array_range_type): Make sure the array's
12075 index type is objfile-owned if the element type is as well.
12076
12077 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12078
12079 GDB 8.1 released.
12080
12081 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
12082
12083 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
12084 "features/s390x-linux64.c".
12085 (_initialize_s390_linux_tdep): Remove initialization of tdescs
12086 s390_linux32 and s390x_linux64.
12087 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
12088 default tdesc.
12089 * s390-tdep.c: Include "features/s390-linux32.c" and
12090 "features/s390x-linux64.c".
12091 (s390_tdesc_valid): Add check for tdesc_has_registers.
12092 (s390_gdbarch_init): Make sure there is always a valid tdesc.
12093 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
12094 tdesc_s390x_linux64.
12095 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
12096 tdesc_s390x_linux64 to...
12097 * s390-tdep.h: ...here.
12098
12099 2018-01-30 Pedro Alves <palves@redhat.com>
12100
12101 PR gdb/13211
12102 * config.in, configure: Regenerate.
12103 * configure.ac: Check for getpgid.
12104 * go32-nat.c (go32_pass_ctrlc): New.
12105 (go32_target): Install it.
12106 * inf-child.c (inf_child_target): Install
12107 child_terminal_save_inferior, child_pass_ctrlc and
12108 child_interrupt.
12109 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
12110 (inf_ptrace_target): No longer install it.
12111 * infcmd.c (interrupt_target_1): Adjust.
12112 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
12113 (child_interrupt): Declare.
12114 (inferior::terminal_state): New.
12115 * inflow.c (struct terminal_info): Update comments.
12116 (inferior_process_group): Delete.
12117 (terminal_is_ours): Delete.
12118 (gdb_tty_state): New.
12119 (child_terminal_init): Adjust.
12120 (is_gdb_terminal, sharing_input_terminal_1)
12121 (sharing_input_terminal): New functions.
12122 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
12123 Set the process's actual process group in the foreground if
12124 possible. Handle is_ours_for_output/is_ours distinction. Don't
12125 mark terminal as the inferior's if not sharing GDB's terminal.
12126 Don't check attach_flag.
12127 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
12128 pass down a target_terminal_state.
12129 (child_terminal_save_inferior): New, factored out from ...
12130 (child_terminal_ours_1): ... this. Handle
12131 target_terminal_state::is_ours_for_output.
12132 (child_interrupt, child_pass_ctrlc): New.
12133 (inflow_inferior_exit): Clear the inferior's terminal_state.
12134 (copy_terminal_info): Copy the inferior's terminal state.
12135 (_initialize_inflow): Remove reference to terminal_is_ours.
12136 * inflow.h (inferior_process_group): Delete.
12137 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
12138 * procfs.c (procfs_target): Don't install procfs_interrupt.
12139 (procfs_interrupt): Delete.
12140 * remote.c (remote_serial_quit_handler): Adjust.
12141 (remote_interrupt): Remove ptid parameter. Adjust.
12142 * target-delegates.c: Regenerate.
12143 * target.c: Include "terminal.h".
12144 (target_terminal::terminal_state): Rename to ...
12145 (target_terminal::m_terminal_state): ... this.
12146 (target_terminal::init): Adjust.
12147 (target_terminal::inferior): Adjust to per-inferior
12148 terminal_state.
12149 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
12150 (target_terminal::ours, target_terminal::ours_for_output): Use
12151 target_terminal_is_ours_kind.
12152 (target_interrupt): Remove ptid parameter. Adjust.
12153 (default_target_pass_ctrlc): Adjust.
12154 * target.h (target_ops::to_terminal_save_inferior): New field.
12155 (target_ops::to_interrupt): Remove ptid_t parameter.
12156 (target_interrupt): Remove ptid_t parameter. Update comment.
12157 (target_pass_ctrlc): Update comment.
12158 * target/target.h (target_terminal_state): New scoped enum,
12159 factored out of ...
12160 (target_terminal::terminal_state): ... here.
12161 (target_terminal::inferior): Update comments.
12162 (target_terminal::restore_inferior): New.
12163 (target_terminal::is_inferior, target_terminal::is_ours)
12164 (target_terminal::is_ours_for_output): Adjust.
12165 (target_terminal::scoped_restore_terminal_state): Adjust to
12166 rename, and call restore_inferior() instead of inferior().
12167 (target_terminal::scoped_restore_terminal_state::m_state): Change
12168 type.
12169 (target_terminal::terminal_state): Rename to ...
12170 (target_terminal::m_terminal_state): ... this and change type.
12171
12172 2018-01-30 Pedro Alves <palves@redhat.com>
12173
12174 * linux-nat.c (wait_for_signal): New function.
12175 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
12176 directly.
12177 (async_terminal_is_ours)
12178 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
12179 (linux_nat_add_target): Don't override
12180 to_terminal_inferior/to_terminal_ours.
12181
12182 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
12183
12184 * remote.c (remote_follow_fork): Don't call "detach_inferior".
12185
12186 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
12187
12188 * dwarf2read.c (free_dwo_files): Add forward-declaration.
12189 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
12190 dwarf2_per_objfile_free here.
12191 (dwarf2_per_objfile_free): Remove.
12192 (_initialize_dwarf2_read): Don't register
12193 dwarf2_per_objfile_free as a registry cleanup.
12194
12195 2018-01-27 Eli Zaretskii <eliz@gnu.org>
12196
12197 Avoid compilation errors in MinGW native builds
12198
12199 The error is triggered by including python-internal.h, and the
12200 error message is:
12201
12202 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
12203 from build-gnulib/import/math.h:27,
12204 from d:/usr/Python26/include/pyport.h:235,
12205 from d:/usr/Python26/include/Python.h:58,
12206 from python/python-internal.h:94,
12207 from python/py-arch.c:24:
12208 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
12209 using ::hypot;
12210 ^~~~~
12211
12212 This happens because Python headers define 'hypot' to expand t
12213 '_hypot' in the Windows builds.
12214 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
12215 'hypoth'. This avoids a compilation error.
12216
12217 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12218
12219 * MAINTAINERS (Write After Approval): Fix ordering.
12220
12221 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12222
12223 * MAINTAINERS (Write After Approval): Add Alan Hayward.
12224
12225 2018-01-26 Alan Modra <amodra@gmail.com>
12226
12227 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
12228 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
12229 Remove nop. Make const. Comment.
12230 (powerpc32_plt_stub_so_2): New.
12231 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
12232 Correct count. Update uses.
12233 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
12234 Move common code reading PLT entry word. Correct
12235 powerpc32_plt_stub PLT address calculation.
12236 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
12237 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
12238 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
12239 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
12240 (ppc64_standard_linkage8): Likewise.
12241 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
12242 Correct insns description.
12243 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
12244
12245 2018-01-24 Pedro Alves <palves@redhat.com>
12246
12247 GCC PR libstdc++/83906
12248 * gdbtypes.c (operator==(const dynamic_prop &,
12249 const dynamic_prop &)): New.
12250 (operator==(const range_bounds &, const range_bounds &)): New.
12251 (check_types_equal): Use them instead of memcmp.
12252 * gdbtypes.h (operator==(const dynamic_prop &,
12253 const dynamic_prop &)): Declare.
12254 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
12255 (operator==(const range_bounds &, const range_bounds &)): Declare.
12256 (operator!=(const range_bounds &, const range_bounds &)): Declare.
12257
12258 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12259
12260 * s390-linux-tdep.c (s390_record_address_mask)
12261 (s390_record_calc_disp_common, s390_record_calc_disp)
12262 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12263 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12264 (s390_process_record): Move to s390-tdep.c.
12265 (s390_linux_init_abi_any): Adjust.
12266 * s390-tdep.c (s390_record_address_mask)
12267 (s390_record_calc_disp_common, s390_record_calc_disp)
12268 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12269 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12270 (s390_process_record): Moved from s390-linux-tdep.c
12271 (s390_gdbarch_init): Adjust.
12272
12273 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12274
12275 * s390-linux-nat.c (s390-tdep.h): New include.
12276 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
12277 (HFILES_NO_SRCDIR): Add s390-tdep.h.
12278 (ALLDEPFILES): Add s390-tdep.c.
12279 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
12280 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
12281 * s390-tdep.h: ...this. New file.
12282 * s390-linux-tdep.c (s390-tdep.h): New include.
12283 (_initialize_s390_tdep): Rename to...
12284 (_initialize_s390_linux_tdep): ...this and adjust.
12285 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
12286 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
12287 s390-tdep.h.
12288 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
12289 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
12290 (s390_is_partial_instruction, s390_software_single_step)
12291 (is_non_branch_ril, s390_displaced_step_copy_insn)
12292 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
12293 (s390_prologue_data, s390_addr, s390_store, s390_load)
12294 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
12295 (s390_register_call_saved, s390_guess_tracepoint_registers)
12296 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
12297 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
12298 (s390_pseudo_register_name, s390_pseudo_register_type)
12299 (s390_pseudo_register_read, s390_pseudo_register_write)
12300 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
12301 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
12302 (s390_addr_bits_remove, s390_address_class_type_flags)
12303 (s390_address_class_type_flags_to_name)
12304 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
12305 (s390_function_arg_float, s390_function_arg_vector)
12306 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
12307 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
12308 (s390_frame_align, s390_register_return_value, s390_return_value)
12309 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
12310 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
12311 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
12312 (s390_trad_frame_prev_register, s390_unwind_cache)
12313 (s390_prologue_frame_unwind_cache)
12314 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
12315 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
12316 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
12317 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
12318 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
12319 (s390_frame_base_address, s390_local_base_address)
12320 (s390_frame_base, s390_gcc_target_options)
12321 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
12322 (s390_validate_reg_range, s390_tdesc_valid)
12323 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
12324 * s390-tdep.c: ...this. New file.
12325
12326 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12327
12328 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
12329 (s390_process_record, s390_gdbarch_tdep_alloc)
12330 (s390_linux_init_abi_any): Use/set new hook.
12331
12332 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12333
12334 * s390-linux-tdep.c (osabi.h): New include.
12335 (s390_linux_init_abi_31, s390_linux_init_abi_64)
12336 (s390_linux_init_abi_any): New functions.
12337 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
12338
12339 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12340
12341 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
12342 tdesc_has_registers check
12343
12344 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12345
12346 * s390-linux-tdep.c (s390_tdesc_valid): New function.
12347 (s390_validate_reg_range): New macro.
12348 (s390_gdbarch_init): Adjust.
12349
12350 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12351
12352 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
12353 (s390_gdbarch_tdep_alloc): Adjust.
12354 (s390_gdbarch_init): Adjust.
12355
12356 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12357
12358 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
12359 <have_tdb>: Change type to bool.
12360 (s390_gdbarch_tdep_alloc): Adjust.
12361 (s390_gdbarch_init): Adjust.
12362
12363 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12364
12365 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
12366 (gdbarch_tdep) <have_upper, have_vx>: New fields.
12367 (s390_gdbarch_tdep_alloc): New function.
12368 (s390_gdbarch_init): Allocate tdep at start and use its fields
12369 instead of separate variables.
12370
12371 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12372
12373 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
12374 when looking for cached gdbarch and add comment for remaining.
12375
12376 2018-01-22 Pedro Alves <palves@redhat.com>
12377 Sergio Durigan Junior <sergiodj@redhat.com>
12378
12379 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
12380 case.
12381
12382 2018-01-22 Maciej W. Rozycki <macro@mips.com>
12383
12384 * MAINTAINERS: Update my company e-mail address.
12385
12386 2018-01-22 Yao Qi <yao.qi@linaro.org>
12387
12388 * regcache.c (cooked_write_test): New function.
12389 (_initialize_regcache): Register the test.
12390
12391 2018-01-22 Yao Qi <yao.qi@linaro.org>
12392
12393 * ia64-tdep.c (ia64_pseudo_register_read): Call
12394 regcache->cooked_read instead of regcache_cooked_read_unsigned.
12395 * m32c-tdep.c (m32c_cat_read): Likewise.
12396 (m32c_r3r2r1r0_read): Likewise.
12397 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
12398 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
12399
12400 2018-01-22 Yao Qi <yao.qi@linaro.org>
12401
12402 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
12403 method raw_read instead of regcache_raw_read.
12404 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
12405 * arm-tdep.c (arm_neon_quad_read): Likewise.
12406 * avr-tdep.c (avr_pseudo_register_read): Likewise.
12407 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
12408 * frv-tdep.c (frv_pseudo_register_read): Likewise.
12409 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
12410 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
12411 (i386_pseudo_register_read_into_value): Likewise.
12412 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
12413 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
12414 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
12415 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
12416 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
12417 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
12418 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
12419 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
12420 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
12421
12422 2018-01-22 Yao Qi <yao.qi@linaro.org>
12423
12424 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
12425 * configure.tgt: Remove target mt.
12426 * mt-tdep.c: Remove.
12427 * regcache.c (cooked_read_test): Remove the check for mt.
12428
12429 2018-01-22 Yao Qi <yao.qi@linaro.org>
12430
12431 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
12432 instead of gdbarch_pseudo_register_read_value.
12433
12434 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12435
12436 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
12437 language is Ada.
12438
12439 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12440
12441 * linespec.c (create_sals_line_offset): Remove code that preserved
12442 the symtab_and_line's line number.
12443
12444 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12445
12446 * varobj.c (varobj_create): Don't set valid_block when creating a
12447 floating varobj.
12448
12449 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12450
12451 * varobj.c (varobj_create): Remove out of date comment.
12452
12453 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12454
12455 PR mi/20395
12456 * ada-exp.y (write_var_from_sym): Pass extra parameter when
12457 updating innermost block.
12458 * parse.c (innermost_block_tracker::update): Take extra type
12459 parameter, and check types match before updating innermost block.
12460 (write_dollar_variable): Update innermost block for registers.
12461 * parser-defs.h (enum innermost_block_tracker_type): New enum.
12462 (innermost_block_tracker::innermost_block_tracker): Initialise
12463 m_types member.
12464 (innermost_block_tracker::reset): Take type parameter.
12465 (innermost_block_tracker::update): Take type parameter, and pass
12466 type through as needed.
12467 (innermost_block_tracker::m_types): New member.
12468 * varobj.c (varobj_create): Pass type when reseting innermost
12469 block.
12470
12471 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12472
12473 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
12474 * ada-lang.c (resolve_subexp): Likewise.
12475 * breakpoint.c (set_breakpoint_condition) Likewise.
12476 (watch_command_1) Likewise.
12477 * c-exp.y (variable): Likewise.
12478 * d-exp.y (PrimaryExpression): Likewise.
12479 * f-exp.y (variable): Likewise.
12480 * go-exp.y (variable): Likewise.
12481 * m2-exp.y (variable): Likewise.
12482 * objfiles.c (objfile::~objfile): Likewise.
12483 * p-exp.y (variable): Likewise.
12484 * parse.c (innermost_block): Change type.
12485 * parser-defs.h (class innermost_block_tracker): New.
12486 (innermost_block): Change to innermost_block_tracker.
12487 * printcmd.c (display_command): Switch to innermost_block API.
12488 (do_one_display): Likewise.
12489 * rust-exp.y (do_one_display): Likewise.
12490 * symfile.c (clear_symtab_users): Likewise.
12491 * varobj.c (varobj_create): Switch to innermost_block API, replace
12492 use of innermost_block with block stored on varobj object.
12493
12494 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12495
12496 * expression.h (innermost_block): Remove declaration.
12497 * varobj.c: Add 'parser-defs.h' include.
12498
12499 2018-01-19 Tom Tromey <tom@tromey.com>
12500
12501 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
12502 symbols in the static and global blocks.
12503
12504 2018-01-19 James Clarke <jrtc27@jrtc27.com>
12505
12506 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
12507 gdb_ptrace.h, and move including gdb_wait.h ...
12508 * nat/linux-ptrace.h: ... to here.
12509
12510 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12511
12512 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
12513 inf_ptrace_detach_success.
12514 (inf_ptrace_detach_success): Add inferior parameter, use it
12515 instead of inferior_ptid, pass it to detach_inferior.
12516 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
12517 parameter.
12518 * inferior.c (detach_inferior): Add overload that takes an
12519 inferior object.
12520 * inferior.h (detach_inferior): Likewise.
12521 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
12522 use inferior_ptid, adjust call to inf_ptrace_detach_success.
12523 * linux-thread-db.c (thread_db_detach): Use inf parameter.
12524
12525 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12526
12527 * target.h (struct target_ops) <to_detach>: Add inferior
12528 parameter.
12529 (target_detach): Likewise.
12530 * target.c (dispose_inferior): Pass inferior down.
12531 (target_detach): Pass inferior down. Assert that it is equal to
12532 the current inferior.
12533 * aix-thread.c (aix_thread_detach): Pass inferior down.
12534 * corefile.c (core_file_command): Pass current_inferior() down.
12535 * corelow.c (core_detach): Add inferior parameter.
12536 * darwin-nat.c (darwin_detach): Likewise.
12537 * gnu-nat.c (gnu_detach): Likewise.
12538 * inf-ptrace.c (inf_ptrace_detach): Likewise.
12539 * infcmd.c (detach_command): Pass current_inferior() down to
12540 target_detach.
12541 * infrun.c (follow_fork_inferior): Pass parent_inf to
12542 target_detach.
12543 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
12544 target_detach.
12545 * linux-nat.c (linux_nat_detach): Add inferior parameter.
12546 * linux-thread-db.c (thread_db_detach): Likewise.
12547 * nto-procfs.c (procfs_detach): Likewise.
12548 * procfs.c (procfs_detach): Likewise.
12549 * record.c (record_detach): Likewise.
12550 * record.h (struct inferior): Forward-declare.
12551 (record_detach): Add inferior parameter.
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-debug.h (target_debug_print_inferior_p): New macro.
12558 * target-delegates.c: Re-generate.
12559 * top.c (kill_or_detach): Pass inferior down to target_detach.
12560 * windows-nat.c (windows_detach): Add inferior parameter.
12561
12562 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12563
12564 * target.h (struct target_ops) <to_detach>: Remove args
12565 parameter.
12566 (target_detach): Likewise.
12567 * target.c (dispose_inferior): Adjust.
12568 (target_detach): Remove args parameter, adjust.
12569 * aix-thread.c (aix_thread_detach): Adjust.
12570 * corefile.c (core_file_command): Adjust.
12571 * corelow.c (core_detach): Adjust.
12572 * darwin-nat.c (darwin_detach): Adjust.
12573 * gnu-nat.c (gnu_detach): Adjust.
12574 * inf-ptrace.c (inf_ptrace_detach): Adjust.
12575 * infcmd.c (detach_command): Adjust
12576 * infrun.c (follow_fork_inferior): Adjust.
12577 (handle_vfork_child_exec_or_exit): Adjust.
12578 * linux-fork.c (linux_fork_detach): Remove args parameter.
12579 * linux-fork.h (linux_fork_detach): Likewise.
12580 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
12581 * linux-thread-db.c (thread_db_detach): Likewise.
12582 * nto-procfs.c (procfs_detach): Likewise.
12583 * procfs.c (procfs_detach): Likewise.
12584 (do_detach): Remove signo parameter.
12585 * record.c (record_detach): Remove args parameter.
12586 * record.h (record_detach): Likewise.
12587 * remote-sim.c (gdbsim_detach): Likewise.
12588 * remote.c (remote_detach_1): Likewise.
12589 (remote_detach): Likewise.
12590 (extended_remote_detach): Likewise.
12591 * sol-thread.c (sol_thread_detach): Likewise.
12592 * target-delegates.c: Re-generate.
12593 * top.c (struct qt_args) <args>: Remove field.
12594 (kill_or_detach): Don't pass args.
12595 (quit_force): Don't set args.
12596 * windows-nat.c (windows_detach): Remove args parameter.
12597
12598 2018-01-19 Yao Qi <yao.qi@linaro.org>
12599
12600 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
12601 (arm_linux_init_abi): Install it.
12602
12603 2018-01-19 Yao Qi <yao.qi@linaro.org>
12604
12605 * osabi.c (gdb_osabi_names): Extend the regexp for
12606 arm-linux-gnueabihf.
12607
12608 2018-01-18 Yao Qi <yao.qi@linaro.org>
12609
12610 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
12611 m_abbrevs.
12612 (abbrev_table::add_abbrev): Update.
12613 (abbrev_table::lookup_abbrev): Update.
12614
12615 2018-01-18 Yao Qi <yao.qi@linaro.org>
12616
12617 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
12618
12619 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
12620
12621 * compile/compile.c (compile_to_object): Convert "triplet_rx"
12622 to "std::string".
12623
12624 2018-01-17 Tom Tromey <tom@tromey.com>
12625
12626 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
12627
12628 2018-01-17 Tom Tromey <tom@tromey.com>
12629
12630 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
12631 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
12632 (create_array_type_with_stride): Update.
12633 * dwarf2read.c (set_die_type): Update.
12634
12635 2018-01-17 Tom Tromey <tom@tromey.com>
12636
12637 * dwarf2read.c (delayed_method_info): Remove typedef.
12638 (dwarf2_cu::method_info): Now a std::vector.
12639 (add_to_method_list): Update.
12640 (free_delayed_list): Remove.
12641 (compute_delayed_physnames): Update.
12642 (process_full_comp_unit, process_full_type_unit): Clear the method
12643 list. Remove cleanups.
12644 (psymtab_include_file_name): Add name_holder parameter. Use
12645 unique_xmalloc_ptr.
12646 (dwarf_decode_lines): Update.
12647
12648 2018-01-17 Tom Tromey <tom@tromey.com>
12649 Simon Marchi <simon.marchi@ericsson.com>
12650
12651 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
12652 (dwarf2_per_objfile::free_cached_comp_units)
12653 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12654 (init_cutu_and_read_dies_no_follow): Update.
12655 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
12656 (dwarf2_cu::~dwarf2_cu): New.
12657 (free_heap_comp_unit, free_stack_comp_unit): Remove.
12658 (age_cached_comp_units, free_one_cached_comp_unit): Update.
12659
12660 2018-01-17 Tom Tromey <tom@tromey.com>
12661 Simon Marchi <simon.marchi@ericsson.com>
12662
12663 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
12664 (struct die_reader_specs) <abbrev_table>: New member.
12665 (struct abbrev_table): Add constructor.
12666 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
12667 <abbrev_obstack>: Now an auto_obstack.
12668 (abbrev_table_up): New typedef.
12669 (init_cu_die_reader): Add abbrev_table parameter.
12670 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
12671 Add result_dwo_abbrev_table.
12672 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12673 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
12674 Update.
12675 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
12676 parameter.
12677 (skip_children): Update.
12678 (abbrev_table::alloc_abbrev): Rename from
12679 abbrev_table_alloc_abbrev.
12680 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
12681 (abbrev_table::lookup_abbrev): Rename from
12682 abbrev_table_lookup_abbrev.
12683 (abbrev_table_read_table): Return abbrev_table_up.
12684 (abbrev_table_free, abbrev_table_free_cleanup)
12685 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
12686 (load_partial_dies): Update.
12687
12688 2018-01-17 Tom Tromey <tom@tromey.com>
12689
12690 * dwarf2read.c (dwarf2_compute_name): Update comment.
12691 (read_func_scope, read_variable): Update.
12692 (new_symbol): Remove.
12693 (new_symbol_full): Rename to new_symbol.
12694
12695 2018-01-17 Mike Gulick <mgulick@mathworks.com>
12696
12697 PR gdb/16577
12698 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
12699 a warning instead of throwing an error, set section size to 0 and return
12700 NULL.
12701 * gdb_bfd.h (gdb_bfd_map_section): Update description.
12702
12703 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
12704
12705 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
12706 std::string.
12707 (linux_ptrace_attach_fail_reason_string): Likewise.
12708 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
12709 Likewise.
12710 (linux_ptrace_attach_fail_reason_string): Likewise.
12711 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
12712
12713 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
12714
12715 * linux-nat.c (linux_nat_attach): Remove xstrdup.
12716
12717 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
12718
12719 PR gdb/21559
12720 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
12721 checking for fs_base/gs_base fields in struct user_regs_struct.
12722 * configure: Regenerate.
12723
12724 2018-01-17 Yao Qi <yao.qi@linaro.org>
12725
12726 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
12727 function.
12728 (aarch64_linux_init_abi): Install it to gdbarch hook
12729 gcc_target_options.
12730
12731 2018-01-15 Pedro Alves <palves@redhat.com>
12732
12733 * common/signals-state-save-restore.c
12734 (save_original_signals_state): Fix typos.
12735
12736 2017-01-12 Tom Tromey <tom@tromey.com>
12737 Sergio Durigan Junior <sergiodj@redhat.com>
12738
12739 * Makefile.in (install-only): Install gdb-add-index.
12740
12741 2018-01-12 John Baldwin <jhb@FreeBSD.org>
12742
12743 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
12744
12745 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
12746
12747 * infrun.c (keep_going_pass_signal): Clear step-over info when
12748 insert_breakpoints fails.
12749
12750 2018-01-11 Pedro Alves <palves@redhat.com>
12751
12752 PR gdb/22583
12753 * infrun.c (resume): Rename to ...
12754 (resume_1): ... this.
12755 (resume): Reimplement as wrapper around resume_1.
12756
12757 2018-01-11 Pedro Alves <palves@redhat.com>
12758
12759 PR remote/22597
12760 * remote.c (remote_parse_stop_reply): Default to the last-set
12761 general thread instead of to 'magic_null_ptid'.
12762
12763 2018-01-10 Pedro Alves <palves@redhat.com>
12764
12765 * language.h (language_get_symbol_name_matcher): Rename ...
12766 (get_symbol_name_matcher): ... this.
12767 * language.c (language_get_symbol_name_matcher): Ditto.
12768 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
12769 callers adjusted.
12770
12771 2018-01-10 Pedro Alves <palves@redhat.com>
12772
12773 PR gdb/22670
12774 * dwarf2read.c
12775 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
12776 Adjust to use language_get_symbol_name_matcher instead of
12777 language_defn::la_get_symbol_name_matcher.
12778 * language.c (language_get_symbol_name_matcher): If in Ada mode
12779 and the lookup name is a verbatim match, return Ada's matcher.
12780 * language.h (language_get_symbol_name_matcher): Adjust comment.
12781 (ada_lookup_name_info::verbatim_p):: New method.
12782
12783 2018-01-10 Pedro Alves <palves@redhat.com>
12784
12785 PR gdb/22670
12786 * ada-lang.c (ada_collect_symbol_completion_matches): If the
12787 minsym's language is language_auto or language_cplus, pass down
12788 language_ada instead.
12789 * symtab.c (compare_symbol_name): Don't frob symbol language here.
12790
12791 2018-01-10 Pedro Alves <palves@redhat.com>
12792
12793 PR gdb/22670
12794 * minsyms.c (linkage_name_str): New function.
12795 (iterate_over_minimal_symbols): Use it.
12796
12797 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12798
12799 * NEWS: Document that 'info proc' now works on FreeBSD.
12800
12801 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12802
12803 * configure.ac: Check for kinfo_getfile in libutil.
12804 * configure: Regenerate.
12805 * config.in: Regenerate.
12806 * fbsd-nat.c: Include "fbsd-tdep.h".
12807 (fbsd_fetch_cmdline): New.
12808 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
12809 rather than calling error.
12810 (fbsd_info_proc): New.
12811 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
12812 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
12813 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
12814
12815 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12816
12817 * fbsd-nat.c (struct free_deleter): Remove.
12818 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
12819
12820 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12821
12822 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
12823 NULL for an empty pathname.
12824
12825 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12826
12827 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
12828 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
12829 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
12830 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
12831 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
12832 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
12833 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
12834 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
12835 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
12836 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
12837 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
12838 (fbsd_core_fetch_timeval, fbsd_print_sigset)
12839 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
12840 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
12841 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
12842
12843 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
12844
12845 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
12846 (gnu_xfer_auxv): New function.
12847 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
12848 TARGET_OBJECT_AUXV.
12849
12850 2018-01-08 Yao Qi <yao.qi@linaro.org>
12851 Simon Marchi <simon.marchi@ericsson.com>
12852
12853 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
12854 common/selftest.c.
12855 (COMMON_OBS): Remove selftest.o.
12856 * configure.ac: Append selftest-arch.c and common/selftest.c to
12857 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
12858 * configure: Re-generated.
12859 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
12860 GDB_SELF_TEST.
12861 (maintenance_info_selftests): Likewise.
12862
12863 2018-01-08 Xavier Roirand <roirand@adacore.com>
12864
12865 * ada-valprint.c (val_print_packed_array_elements): Use
12866 proper number of elements when printing an array indexed
12867 by an enumeration type.
12868
12869 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
12870
12871 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
12872 (dw2_get_file_names_reader): Adjust.
12873 (lookup_dwo_signatured_type): Adjust.
12874 (lookup_dwp_signatured_type): Adjust.
12875 (lookup_signatured_type): Adjust.
12876 (create_type_unit_group): Adjust.
12877 (get_type_unit_group): Adjust.
12878 (process_psymtab_comp_unit_reader): Adjust.
12879 (build_type_psymtabs_reader): Adjust.
12880 (scan_partial_symbols): Adjust.
12881 (add_partial_symbol): Adjust.
12882 (add_partial_subprogram): Adjust.
12883 (peek_die_abbrev): Adjust.
12884 (fixup_go_packaging): Adjust.
12885 (process_imported_unit_die): Adjust.
12886 (dwarf2_compute_name): Adjust.
12887 (dwarf2_physname): Adjust.
12888 (read_import_statement): Adjust.
12889 (handle_DW_AT_stmt_list): Adjust.
12890 (read_file_scope): Adjust.
12891 (read_func_scope): Adjust.
12892 (read_lexical_block_scope): Adjust.
12893 (read_call_site_scope): Adjust.
12894 (read_variable): Adjust.
12895 (dwarf2_rnglists_process): Adjust.
12896 (dwarf2_ranges_process): Adjust.
12897 (dwarf2_ranges_read): Adjust.
12898 (dwarf2_get_pc_bounds): Adjust.
12899 (dwarf2_record_block_ranges): Adjust.
12900 (dwarf2_add_field): Adjust.
12901 (dwarf2_add_member_fn): Adjust.
12902 (read_structure_type): Adjust.
12903 (process_structure_scope): Adjust.
12904 (read_enumeration_type): Adjust.
12905 (read_array_type): Adjust.
12906 (mark_common_block_symbol_computed): Adjust.
12907 (read_common_block): Adjust.
12908 (read_namespace_type): Adjust.
12909 (read_namespace): Adjust.
12910 (read_module_type): Adjust.
12911 (read_tag_pointer_type): Adjust.
12912 (read_tag_ptr_to_member_type): Adjust.
12913 (read_tag_string_type): Adjust.
12914 (read_subroutine_type): Adjust.
12915 (read_typedef): Adjust.
12916 (read_base_type): Adjust.
12917 (attr_to_dynamic_prop): Adjust.
12918 (read_subrange_type): Adjust.
12919 (read_unspecified_type): Adjust.
12920 (dwarf2_read_abbrevs): Adjust.
12921 (load_partial_dies): Adjust.
12922 (read_partial_die): Adjust.
12923 (find_partial_die): Adjust.
12924 (guess_partial_die_structure_name): Adjust.
12925 (fixup_partial_die): Adjust.
12926 (read_attribute_value): Adjust.
12927 (read_addr_index): Adjust.
12928 (read_addr_index_from_leb128): Adjust.
12929 (read_str_index): Adjust.
12930 (dwarf2_string_attr): Adjust.
12931 (get_debug_line_section): Adjust.
12932 (dwarf_decode_line_header): Adjust.
12933 (lnp_state_machine::check_line_address): Adjust.
12934 (dwarf_decode_lines_1): Adjust.
12935 (dwarf_decode_lines): Adjust.
12936 (dwarf2_start_symtab): Adjust.
12937 (var_decode_location): Adjust.
12938 (new_symbol_full): Adjust.
12939 (dwarf2_const_value_data): Adjust.
12940 (dwarf2_const_value_attr): Adjust.
12941 (dwarf2_const_value): Adjust.
12942 (die_type): Adjust.
12943 (die_containing_type): Adjust.
12944 (build_error_marker_type): Adjust.
12945 (lookup_die_type): Adjust.
12946 (guess_full_die_structure_name): Adjust.
12947 (anonymous_struct_prefix): Adjust.
12948 (determine_prefix): Adjust.
12949 (dwarf2_name): Adjust.
12950 (follow_die_ref_or_sig): Adjust.
12951 (follow_die_offset): Adjust.
12952 (follow_die_ref): Adjust.
12953 (follow_die_sig_1): Adjust.
12954 (follow_die_sig): Adjust.
12955 (get_signatured_type): Adjust.
12956 (get_DW_AT_signature_type): Adjust.
12957 (decode_locdesc): Adjust.
12958 (dwarf_decode_macros): Adjust.
12959 (cu_debug_loc_section): Adjust.
12960 (fill_in_loclist_baton): Adjust.
12961 (dwarf2_symbol_mark_computed): Adjust.
12962 (init_one_comp_unit): Don't assign
12963 dwarf2_cu::dwarf2_per_objfile.
12964 (set_die_type): Adjust.
12965
12966 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
12967
12968 * dwarf2read.c (struct mapped_debug_names): Add constructor.
12969 <dwarf2_per_objfile>: New field.
12970 (dwarf2_per_objfile): Remove global.
12971 (get_dwarf2_per_objfile): New function.
12972 (set_dwarf2_per_objfile): New function.
12973 (dwarf2_build_psymtabs_hard): Change objfile parameter to
12974 dwarf2_per_objfile.
12975 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
12976 (read_abbrev_offset): Likewise.
12977 (read_indirect_string): Likewise.
12978 (read_indirect_line_string): Likewise.
12979 (read_indirect_string_at_offset): Likewise.
12980 (read_indirect_string_from_dwz): Likewise.
12981 (dwarf2_find_containing_comp_unit): Change objfile parameter to
12982 dwarf2_per_objfile.
12983 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
12984 (create_all_comp_units): Change objfile parameter to
12985 dwarf2_per_objfile.
12986 (create_all_type_units): Likewise.
12987 (process_queue): Add dwarf2_per_objfile parameter.
12988 (read_and_check_comp_unit_head): Likewise.
12989 (lookup_dwo_unit_in_dwp): Likewise.
12990 (get_dwp_file): Likewise.
12991 (process_cu_includes): Likewise.
12992 (struct free_dwo_file_cleanup_data): New struct.
12993 (dwarf2_has_info): Use get_dwarf2_per_objfile and
12994 set_dwarf2_per_objfile.
12995 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
12996 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
12997 context, adjust calls.
12998 (dw2_instantiate_symtab): Likewise.
12999 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
13000 (dw2_get_cu): Likewise.
13001 (create_cu_from_index_list): Change objfile parameter to
13002 dwarf2_per_objfile.
13003 (create_cus_from_index_list): Get dwarf2_per_objfile from
13004 context, adjust calls.
13005 (create_cus_from_index): Likewise.
13006 (create_signatured_type_table_from_index): Change objfile
13007 parameter to dwarf2_per_objfile.
13008 (create_signatured_type_table_from_debug_names): Change objfile
13009 parameter to dwarf2_per_objfile.
13010 (create_addrmap_from_index): Likewise.
13011 (create_addrmap_from_aranges): Likewise.
13012 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
13013 (dw2_setup): Remove.
13014 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
13015 context.
13016 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
13017 get_dwarf2_per_objfile.
13018 (dw2_forget_cached_source_info): Likewise.
13019 (dw2_map_symtabs_matching_filename): Likewise.
13020 (struct dw2_symtab_iterator) <index>: Remove.
13021 <dwarf2_per_objfile>: New field.
13022 (dw2_symtab_iter_init): Replace index parameter with
13023 dwarf2_per_objfile.
13024 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
13025 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
13026 (dw2_print_stats): Likewise.
13027 (dw2_dump): Likewise.
13028 (dw2_expand_symtabs_for_function): Likewise.
13029 (dw2_expand_all_symtabs): Likewise.
13030 (dw2_expand_symtabs_with_fullname): Likewise.
13031 (dw2_expand_marked_cus): Replace index and objfile parameters
13032 with dwarf2_per_objfile.
13033 (dw_expand_symtabs_matching_file_matcher): Add
13034 dwarf2_per_objfile parameter and adjust calls.
13035 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
13036 adjust calls.
13037 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
13038 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
13039 adjust calls.
13040 (create_cus_from_debug_names_list): Replace objfile parameter
13041 with dwarf2_per_objfile and adjust calls.
13042 (create_cus_from_debug_names): Likewise.
13043 (dwarf2_read_debug_names): Likewise.
13044 (mapped_debug_names::namei_to_name): Adjust call.
13045 (dw2_debug_names_iterator::next): Likewise.
13046 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
13047 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
13048 (dw2_debug_names_dump): Likewise.
13049 (dw2_debug_names_expand_symtabs_for_function): Likewise.
13050 (dw2_debug_names_expand_symtabs_matching): Likewise.
13051 (dwarf2_initialize_objfile): Likewise.
13052 (dwarf2_build_psymtabs): Likewise.
13053 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
13054 this_cu.
13055 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
13056 (read_and_check_comp_unit_head): Likewise.
13057 (read_abbrev_offset): Likewise.
13058 (create_debug_type_hash_table): Likewise.
13059 (create_debug_types_hash_table): Likewise.
13060 (create_all_type_units): Replace objfile parameter with
13061 dwarf2_per_objfile.
13062 (add_type_unit): Add dwarf2_per_objfile parameter.
13063 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
13064 with dwarf2_per_objfile.
13065 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
13066 (lookup_dwp_signatured_type): Likewise.
13067 (lookup_signatured_type): Likewise.
13068 (read_cutu_die_from_dwo): Likewise.
13069 (init_tu_and_read_dwo_dies): Likewise.
13070 (init_cutu_and_read_dies): Likewise.
13071 (init_cutu_and_read_dies_no_follow): Likewise.
13072 (allocate_type_unit_groups_table): Add objfile parameter.
13073 (create_type_unit_group): Use dwarf2_per_objfile from cu.
13074 (get_type_unit_group): Likewise.
13075 (process_psymtab_comp_unit): Update call.
13076 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
13077 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
13078 (print_tu_stats): Likewise.
13079 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
13080 in void* parameter.
13081 (build_type_psymtabs): Change objfile parameter to
13082 dwarf2_per_objfile.
13083 (process_skeletonless_type_unit): Use dwarf2_per_objfile
13084 passed in void* parameter.
13085 (process_skeletonless_type_units): Change objfile parameter to
13086 dwarf2_per_objfile.
13087 (set_partial_user): Likewise.
13088 (dwarf2_build_psymtabs_hard): Likewise.
13089 (read_comp_units_from_section): Likewise.
13090 (create_all_comp_units): Likewise.
13091 (scan_partial_symbols): Update calls.
13092 (add_partial_symbol): Likewise.
13093 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
13094 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
13095 (process_queue): Add dwarf2_per_objfile parameter.
13096 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
13097 (compute_compunit_symtab_includes): Likewise.
13098 (process_cu_includes): Add dwarf2_per_objfile parameter.
13099 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
13100 (process_full_type_unit): Likewise.
13101 (process_imported_unit_die): Update call.
13102 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
13103 (read_file_scope): Likewise.
13104 (allocate_dwo_file_hash_table): Add objfile parameter.
13105 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
13106 (create_cus_hash_table): Likewise.
13107 (create_dwp_hash_table): Likewise.
13108 (create_dwo_unit_in_dwp_v1): Likewise.
13109 (create_dwp_v2_section): Likewise.
13110 (create_dwo_unit_in_dwp_v2): Likewise.
13111 (lookup_dwo_unit_in_dwp): Likewise.
13112 (try_open_dwop_file): Likewise.
13113 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
13114 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
13115 cleanup to include a reference to dwarf2_per_objfile.
13116 (open_dwp_file): Add dwarf2_per_objfile parameter.
13117 (open_and_init_dwp_file): Likewise.
13118 (get_dwp_file): Likewise.
13119 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
13120 (queue_and_load_all_dwo_tus): Update call.
13121 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
13122 data.
13123 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
13124 (dwarf2_ranges_process): Likewise.
13125 (dwarf2_get_pc_bounds): Likewise.
13126 (mark_common_block_symbol_computed): Likewise.
13127 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
13128 (dwarf2_read_abbrevs): Update call.
13129 (read_partial_die): Use dwarf2_per_objfile from cu.
13130 (find_partial_die): Likewise.
13131 (fixup_partial_die): Likewise.
13132 (read_attribute_value): Likewise.
13133 (read_indirect_string_at_offset_from): Add objfile parameter.
13134 (read_indirect_string_at_offset): Add dwarf2_per_objfile
13135 parameter.
13136 (read_indirect_string_from_dwz): Add objfile parameter.
13137 (read_indirect_string): Add objfile parameter.
13138 (read_addr_index_1): Add dwarf2_per_objfile parameter.
13139 (read_addr_index): Use dwarf2_per_objfile from cu.
13140 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
13141 call dw2_setup.
13142 (read_str_index): Use dwarf2_per_objfile from cu.
13143 (get_debug_line_section): Likewise.
13144 (read_formatted_entries): Add dwarf2_per_objfile parameter.
13145 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
13146 (new_symbol_full): Use dwarf2_per_objfile from cu.
13147 (build_error_marker_type): Likewise.
13148 (lookup_die_type): Likewise.
13149 (determine_prefix): Likewise.
13150 (follow_die_offset): Likewise.
13151 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
13152 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
13153 (dwarf2_fetch_die_type_sect_off): Likewise.
13154 (dwarf2_get_die_type): Likewise.
13155 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
13156 (get_signatured_type): Likewise.
13157 (get_DW_AT_signature_type): Likewise.
13158 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
13159 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
13160 (cu_debug_loc_section): Likewise.
13161 (fill_in_loclist_baton): Likewise.
13162 (dwarf2_symbol_mark_computed): Likewise.
13163 (dwarf2_find_containing_comp_unit): Change objfile parameter to
13164 dwarf2_per_objfile.
13165 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
13166 parameter.
13167 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
13168 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
13169 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
13170 (set_die_type): Use dwarf2_free_objfile from cu.
13171 (get_die_type_at_offset): Likewise.
13172 (dwarf2_per_objfile_free): Don't assign global variable.
13173 (debug_names) <constructor>: Add dwarf2_per_objfile
13174 parameter, update m_debugstrlookup construction.
13175 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
13176 parameter.
13177 <m_dwarf2_per_objfile>: New field.
13178 <lookup>: Use m_dwarf2_per_objfile.
13179 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
13180 (psyms_seen_size): Likewise.
13181 (write_gdbindex): Replace objfile parameter with
13182 dwarf2_per_objfile.
13183 (write_debug_names): Likewise.
13184 (write_psymtabs_to_index): Likewise.
13185 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
13186 calls.
13187
13188 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13189
13190 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
13191 <dwarf2_per_objfile>: New field.
13192 (struct dwarf2_per_cu_data) <objfile>: Remove.
13193 <dwarf2_per_objfile>: New field.
13194 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
13195 of objfile.
13196 (create_signatured_type_table_from_index): Likewise.
13197 (create_debug_type_hash_table): Likewise.
13198 (fill_in_sig_entry_from_dwo_entry): Likewise.
13199 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
13200 (create_type_unit_group): Assign dwarf2_per_objfile instead of
13201 objfile.
13202 (create_partial_symtab): Access objfile through
13203 dwarf2_per_objfile.
13204 (process_psymtab_comp_unit_reader): Likewise.
13205 (read_comp_units_from_section): Likewise.
13206 (scan_partial_symbols): Likewise.
13207 (add_partial_symbol): Likewise.
13208 (add_partial_subprogram): Likewise.
13209 (peek_die_abbrev): Likewise.
13210 (fixup_go_packaging): Likewise.
13211 (process_full_comp_unit): Likewise.
13212 (process_full_type_unit): Likewise.
13213 (process_imported_unit_die): Likewise.
13214 (dwarf2_compute_name): Likewise.
13215 (dwarf2_physname): Likewise.
13216 (read_import_statement): Likewise.
13217 (create_cus_hash_table): Assign dwarf2_physname instead of
13218 objfile.
13219 (read_func_scope): Access objfile through dwarf2_per_objfile.
13220 (read_lexical_block_scope): Likewise.
13221 (read_call_site_scope): Likewise.
13222 (read_variable): Likewise.
13223 (dwarf2_rnglists_process): Likewise.
13224 (dwarf2_ranges_process): Likewise.
13225 (dwarf2_ranges_read): Likewise.
13226 (dwarf2_record_block_ranges): Likewise.
13227 (dwarf2_add_field): Likewise.
13228 (dwarf2_add_member_fn): Likewise.
13229 (read_structure_type): Likewise.
13230 (process_structure_scope): Likewise.
13231 (read_enumeration_type): Likewise.
13232 (read_array_type): Likewise.
13233 (read_common_block): Likewise.
13234 (read_namespace_type): Likewise.
13235 (read_namespace): Likewise.
13236 (read_module_type): Likewise.
13237 (read_tag_pointer_type): Likewise.
13238 (read_tag_ptr_to_member_type): Likewise.
13239 (read_tag_string_type): Likewise.
13240 (read_subroutine_type): Likewise.
13241 (read_typedef): Likewise.
13242 (read_base_type): Likewise.
13243 (attr_to_dynamic_prop): Likewise.
13244 (read_subrange_type): Likewise.
13245 (read_unspecified_type): Likewise.
13246 (load_partial_dies): Likewise.
13247 (read_partial_die): Likewise.
13248 (find_partial_die): Likewise.
13249 (guess_partial_die_structure_name): Likewise.
13250 (fixup_partial_die): Likewise.
13251 (read_attribute_value): Likewise.
13252 (read_addr_index_from_leb128): Likewise.
13253 (dwarf2_read_addr_index): Likewise.
13254 (dwarf2_string_attr): Likewise.
13255 (lnp_state_machine::check_line_address): Likewise.
13256 (dwarf_decode_lines_1): Likewise.
13257 (dwarf_decode_lines): Likewise.
13258 (dwarf2_start_symtab): Likewise.
13259 (var_decode_location): Likewise.
13260 (new_symbol_full): Likewise.
13261 (dwarf2_const_value_data): Likewise.
13262 (dwarf2_const_value_attr): Likewise.
13263 (dwarf2_const_value): Likewise.
13264 (die_type): Likewise.
13265 (die_containing_type): Likewise.
13266 (lookup_die_type): Likewise.
13267 (guess_full_die_structure_name): Likewise.
13268 (anonymous_struct_prefix): Likewise.
13269 (dwarf2_name): Likewise.
13270 (follow_die_ref_or_sig): Likewise.
13271 (follow_die_offset): Likewise.
13272 (follow_die_ref): Likewise.
13273 (dwarf2_fetch_die_loc_sect_off): Likewise.
13274 (dwarf2_fetch_constant_bytes): Likewise.
13275 (dwarf2_fetch_die_type_sect_off): Likewise.
13276 (dwarf2_get_die_type): Likewise.
13277 (follow_die_sig): Likewise.
13278 (decode_locdesc): Likewise.
13279 (dwarf2_per_cu_objfile): Likewise.
13280 (dwarf2_per_cu_text_offset): Likewise.
13281 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
13282 objfile.
13283 (set_die_type): Access objfile through
13284 dwarf2_per_objfile.
13285
13286 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13287
13288 * valprint.c (converted_character_d): Remove typedef.
13289 (DEF_VEC_O (converted_character_d)): Remove.
13290 (count_next_character): Use std::vector.
13291 (print_converted_chars_to_obstack): Likewise.
13292 (generic_printstr): Likewise.
13293
13294 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13295
13296 * xml-support.h (struct gdb_xml_value): Add constructor.
13297 <value>: Change type to unique_xmalloc_ptr.
13298 (gdb_xml_value_s): Remove typedef.
13299 (DEF_VEC_O (gdb_xml_value_s)): Remove.
13300 (gdb_xml_element_start_handler): Change parameter type to
13301 std::vector.
13302 (xml_find_attribute): Likewise.
13303 * xml-support.c (xml_find_attribute): Change parameter type to
13304 std::vector and adjust.
13305 (gdb_xml_values_cleanup): Remove.
13306 (gdb_xml_parser::start_element): Adjust to std::vector.
13307 (xinclude_start_include): Change paraeter type to std::vector
13308 and adjust.
13309 * btrace.c (check_xml_btrace_version): Likewise.
13310 (parse_xml_btrace_block): Likewise.
13311 (parse_xml_btrace_pt_config_cpu): Likewise.
13312 (parse_xml_btrace_pt): Likewise.
13313 (parse_xml_btrace_conf_bts): Likewise.
13314 (parse_xml_btrace_conf_pt): Likewise.
13315 * memory-map.c (memory_map_start_memory): Likewise.
13316 (memory_map_start_property): Likewise.
13317 * osdata.c (osdata_start_osdata): Likewise.
13318 (osdata_start_item): Likewise.
13319 (osdata_start_column): Likewise.
13320 * remote.c (start_thread): Likewise.
13321 * solib-aix.c (library_list_start_library): Likewise.
13322 (library_list_start_list): Likewise.
13323 * solib-svr4.c (library_list_start_library): Likewise.
13324 (svr4_library_list_start_list): Likewise.
13325 * solib-target.c (library_list_start_segment): Likewise.
13326 (library_list_start_section): Likewise.
13327 (library_list_start_library): Likewise.
13328 (library_list_start_list): Likewise.
13329 * tracepoint.c (traceframe_info_start_memory): Likewise.
13330 (traceframe_info_start_tvar): Likewise.
13331 * xml-syscall.c (syscall_start_syscall): Likewise.
13332 * xml-tdesc.c (tdesc_start_target): Likewise.
13333 (tdesc_start_feature): Likewise.
13334 (tdesc_start_reg): Likewise.
13335 (tdesc_start_union): Likewise.
13336 (tdesc_start_struct): Likewise.
13337 (tdesc_start_flags): Likewise.
13338 (tdesc_start_enum): Likewise.
13339 (tdesc_start_field): Likewise.
13340 (tdesc_start_enum_value): Likewise.
13341 (tdesc_start_vector): Likewise.
13342
13343 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13344
13345 * extension.h (struct xmethod_worker) <clone>: Remove.
13346 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
13347 Remove.
13348 (python_xmethod_worker::clone): Remove.
13349 * valops.c (find_overload_match): Use std::move instead of
13350 clone.
13351
13352 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13353
13354 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
13355 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
13356 <free_xmethod_worker_data>: Remove.
13357 <get_matching_xmethod_workers>: Chance VEC to std::vector.
13358 <get_xmethod_arg_types>: Remove.
13359 <get_xmethod_result_type>: Remove.
13360 <invoke_xmethod>: Remove.
13361 * extension.c (new_xmethod_worker): Remove.
13362 (clone_xmethod_worker): Remove.
13363 (get_matching_xmethod_workers): Return void, pass std::vector by
13364 pointer.
13365 (get_xmethod_arg_types): Rename to...
13366 (xmethod_worker::get_arg_types): ... this, and adjust.
13367 (get_xmethod_result_type): Rename to...
13368 (xmethod_worker::get_result_type): ... this, and adjust.
13369 (invoke_xmethod): Remove.
13370 (free_xmethod_worker): Remove.
13371 (free_xmethod_worker_vec): Remove.
13372 * extension.h (enum ext_lang_rc): Move here from
13373 extension-priv.h.
13374 (struct xmethod_worker): Add constructor and destructor.
13375 <data>: Remove.
13376 <value>: Remove.
13377 <invoke, clone, do_get_result_type, do_get_arg_types>: New
13378 virtual pure methods.
13379 <get_arg_types, get_result_type>: New methods.
13380 (xmethod_worker_ptr): Remove typedef.
13381 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
13382 (xmethod_worker_vec): Remove typedef.
13383 (xmethod_worker_up): New typedef.
13384 (invoke_xmethod): Remove.
13385 (clone_xmethod_worker): Remove.
13386 (free_xmethod_worker): Remove.
13387 (free_xmethod_worker_vec): Remove.
13388 (get_xmethod_arg_types): Remove.
13389 (get_xmethod_result_type): Remove.
13390 * valops.c (find_method_list): Use std::vector, don't use
13391 intermediate vector.
13392 (value_find_oload_method_list): Use std::vector.
13393 (find_overload_match): Use std::vector.
13394 (find_oload_champ): Use std::vector.
13395 * value.c (value_free): Use operator delete.
13396 (value_of_xmethod): Rename to...
13397 (value_from_xmethod): ... this. Don't assign
13398 xmethod_worker::value, take rvalue-reference.
13399 (result_type_of_xmethod): Adjust.
13400 (call_xmethod): Adjust.
13401 * value.h: Include extension.h.
13402 (struct xmethod_worker): Don't forward-declare.
13403 (value_of_xmethod): Rename to...
13404 (value_from_xmethod): ... this, take rvalue-reference.
13405 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
13406 (struct python_xmethod_worker): ... this, add constructor and
13407 destructor.
13408 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
13409 (gdbpy_free_xmethod_worker_data): Rename to...
13410 (python_xmethod_worker::~python_xmethod_worker): ... this and
13411 adjust.
13412 (gdbpy_clone_xmethod_worker_data): Rename to...
13413 (python_xmethod_worker::clone): ... this and adjust.
13414 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
13415 temporary vector.
13416 (gdbpy_get_xmethod_arg_types): Rename to...
13417 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
13418 (gdbpy_get_xmethod_result_type): Rename to...
13419 (python_xmethod_worker::do_get_result_type): ... this and
13420 adjust.
13421 (gdbpy_invoke_xmethod): Rename to...
13422 (python_xmethod_worker::invoke): ... this and adjust.
13423 (new_python_xmethod_worker): Rename to...
13424 (python_xmethod_worker::python_xmethod_worker): ... this and
13425 adjust.
13426 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
13427 Remove.
13428 (gdbpy_free_xmethod_worker_data): Remove.
13429 (gdbpy_get_matching_xmethod_workers): Use std::vector.
13430 (gdbpy_get_xmethod_arg_types): Remove.
13431 (gdbpy_get_xmethod_result_type): Remove.
13432 (gdbpy_invoke_xmethod): Remove.
13433 * python/python.c (python_extension_ops): Remove obsolete
13434 callbacks.
13435
13436 2018-01-05 Pedro Alves <palves@redhat.com>
13437
13438 PR gdb/18653
13439 * common/signals-state-save-restore.c
13440 (save_original_signals_state): New parameter 'quiet'. Warn if we
13441 find a custom handler preinstalled, instead of internal erroring.
13442 But only warn if !quiet.
13443 * common/signals-state-save-restore.h
13444 (save_original_signals_state): New parameter 'quiet'.
13445 * main.c (captured_main_1): Move save_original_signals_state call
13446 after option handling, and pass QUIET.
13447
13448 2018-01-05 Pedro Alves <palves@redhat.com>
13449
13450 * spu-tdep.c (spu_catch_start): Pass
13451 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
13452
13453 2018-01-05 Pedro Alves <palves@redhat.com>
13454
13455 PR gdb/22670
13456 * ada-lang.c (literal_symbol_name_matcher): New function.
13457 (ada_get_symbol_name_matcher): Use it for
13458 symbol_name_match_type::SEARCH_NAME.
13459 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
13460 it down instead of assuming symbol_name_match_type::FULL.
13461 * block.h (block_lookup_symbol): New parameter 'match_type'.
13462 * c-valprint.c (print_unpacked_pointer): Use
13463 lookup_symbol_search_name instead of lookup_symbol.
13464 * compile/compile-object-load.c (get_out_value_type): Pass down
13465 symbol_name_match_type::SEARCH_NAME.
13466 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
13467 symbol_name_match_type::FULL.
13468 * cp-support.c (cp_get_symbol_name_matcher): Handle
13469 symbol_name_match_type::SEARCH_NAME.
13470 * infrun.c (insert_exception_resume_breakpoint): Use
13471 lookup_symbol_search_name.
13472 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
13473 * psymtab.c (maintenance_check_psymtabs): Use
13474 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
13475 * stack.c (print_frame_args): Use lookup_symbol_search_name and
13476 SYMBOL_SEARCH_NAME.
13477 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
13478 if symbol_name_match_type::SEARCH_NAME.
13479 (lookup_symbol_in_language): Pass down
13480 symbol_name_match_type::FULL.
13481 (lookup_symbol_search_name): New.
13482 (lookup_language_this): Pass down
13483 symbol_name_match_type::SEARCH_NAME.
13484 (lookup_symbol_aux, lookup_local_symbol): New parameter
13485 'match_type'. Pass it down.
13486 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
13487 (lookup_symbol_search_name): New declaration.
13488 (lookup_symbol_in_block): New 'match_type' parameter.
13489
13490 2018-01-05 Pedro Alves <palves@redhat.com>
13491
13492 PR gdb/22670
13493 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
13494 ada_lookup_symbol.
13495 (ada_lookup_symbol): Reimplement in terms of
13496 ada_lookup_symbol_list, bits factored out from
13497 ada_lookup_encoded_symbol.
13498
13499 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13500
13501 * ada-exp.y (write_object_renaming): When subscripting an array
13502 using a symbol as the index, pass the block in call to
13503 ada_lookup_encoded_symbol when looking that symbol up.
13504
13505 2018-01-05 Jerome Guitton <guitton@adacore.com>
13506
13507 * ada-lang.c (ada_array_length): Use ada_index_type instead of
13508 TYPE_INDEX_TYPE.
13509
13510 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13511
13512 * ada-lang.c (ada_to_fixed_value_create): Add handling of
13513 the case where VALUE_LVAL (val0) is not lval_memory.
13514
13515 2018-01-05 Xavier Roirand <roirand@adacore.com>
13516
13517 * ada-valprint.c (print_optional_low_bound): Handle
13518 character-indexed array printing like boolean-indexed array
13519 printing.
13520
13521 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13522
13523 * NEWS: Create a new section for the next release branch.
13524 Rename the section of the current branch, now that it has
13525 been cut.
13526
13527 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13528
13529 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
13530 * version.in: Bump version to 8.1.50.DATE-git.
13531
13532 2018-01-03 Xavier Roirand <roirand@adacore.com>
13533
13534 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
13535 Add field.
13536 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
13537 Add field.
13538 (default_exception_support_info) <catch_handlers_sym>: Add field.
13539 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
13540 (ada_exception_name_addr_1): Add "catch handlers" handling.
13541 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
13542 Update all callers.
13543 (create_excep_cond_exprs) <ex>: Add parameter.
13544 (re_set_exception): Update create_excep_cond_exprs call.
13545 (print_it_exception, print_one_exception, print_mention_exception)
13546 (print_recreate_exception): Add "catch handler" handling.
13547 (allocate_location_catch_handlers, re_set_catch_handlers)
13548 (check_status_catch_handlers, print_it_catch_handlers)
13549 (print_one_catch_handlers, print_mention_catch_handlers)
13550 (print_recreate_catch_handlers): New function.
13551 (catch_handlers_breakpoint_ops): New variable.
13552 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
13553 Add parameter. Add "catch handler" handling.
13554 (ada_exception_sym_name, ada_exception_breakpoint_ops):
13555 Add "catch handler" handling.
13556 (ada_exception_catchpoint_cond_string): Add "catch handler"
13557 handling.
13558 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
13559 call.
13560 (catch_ada_handlers_command): New function.
13561 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
13562 operations structure.
13563 (_initialize_ada_language): Add "catch handlers" command entry.
13564 * NEWS: Document "catch handlers" feature.
13565
13566 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13567
13568 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
13569 account when creating the array type of the slice.
13570 (ada_value_slice): Likewise.
13571
13572 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13573
13574 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
13575 New enum value.
13576 (create_array_type_with_stride): Add byte_stride_prop parameter.
13577 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
13578 New parameter. Update all callers in this file.
13579 (array_type_has_dynamic_stride): New function.
13580 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
13581 of arrays with dynamic byte strides.
13582 * dwarf2read.c (read_array_type): Add support for dynamic
13583 DW_AT_byte_stride attributes.
13584
13585 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13586
13587 * dwarf2read.c (read_unspecified_type): Treat
13588 DW_TAG_enumeration_type DIEs from Ada units as stubs.
13589
13590 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13591
13592 Update copyright year range in all GDB files.
13593
13594 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13595
13596 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
13597 and gdb/testsuite/gdb.base/step-line.c.
13598
13599 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13600
13601 * copyright.py (main): Dump the contents of
13602 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
13603 even if BY_HAND is empty.
13604
13605 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13606
13607 * top.c (print_gdb_version): Update Copyright year in version
13608 message.
13609
13610 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13611
13612 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
13613
13614 For older changes see ChangeLog-2017.
13615 \f
13616 Local Variables:
13617 mode: change-log
13618 left-margin: 8
13619 fill-column: 74
13620 version-control: never
13621 coding: utf-8
13622 End: