Import gnulib's inet_ntop module.
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2018-09-18 John Baldwin <jhb@FreeBSD.org>
2
3 * gnulib/aclocal-m4-deps.mk: Re-generate.
4 * gnulib/aclocal.m4: Re-generate.
5 * gnulib/config.in: Re-generate.
6 * gnulib/configure: Re-generate.
7 * gnulib/import/Makefile.am: Re-generate.
8 * gnulib/import/Makefile.in: Re-generate.
9 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
10 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
11 * gnulib/import/arpa_inet.in.h: New file.
12 * gnulib/import/inet_ntop.c: New file.
13 * gnulib/import/m4/arpa_inet_h.m4: New file.
14 * gnulib/import/m4/inet_ntop.m4: New file.
15 * gnulib/import/m4/netinet_in_h.m4: New file.
16 * gnulib/import/m4/socklen.m4: New file.
17 * gnulib/import/m4/sockpfaf.m4: New file.
18 * gnulib/import/m4/stdalign.m4: New file.
19 * gnulib/import/m4/sys_uio_h.m4: New file.
20 * gnulib/import/netinet_in.in.h: New file.
21 * gnulib/import/stdalign.in.h: New file.
22 * gnulib/import/sys_socket.c: New file.
23 * gnulib/import/sys_socket.in.h: New file.
24 * gnulib/import/sys_uio.in.h: New file.
25 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add inet_ntop
26 module.
27
28 2018-09-18 John Baldwin <jhb@FreeBSD.org>
29
30 * gnulib/aclocal-m4-deps.mk: New file.
31 * gnulib/update-gnulib.sh: Generate "aclocal-m4-deps.mk"
32 deterministically.
33
34 2018-09-18 John Baldwin <jhb@FreeBSD.org>
35
36 * fbsd-tdep.c (fbsd_core_vnode_path): Use KF_PATH instead of
37 KVE_PATH.
38
39 2018-09-18 Tom Tromey <tom@tromey.com>
40
41 * compile/compile-object-load.c (struct
42 link_hash_table_cleanup_data): Add constructor and destructor.
43 Use DISABLE_COPY_AND_ASSIGN.
44 (~link_hash_table_cleanup_data): Rename from
45 link_hash_table_free. Now a destructor.
46 (copy_sections): Use gdb::unique_xmalloc_ptr. Remove cleanups.
47
48 2018-09-18 Tom Tromey <tom@tromey.com>
49
50 * compile/compile-object-run.c (do_module_cleanup): Use delete.
51 * compile/compile-object-load.c (struct munmap_list): Move to
52 header file.
53 (munmap_list::add): Rename from munmap_list_add; rewrite.
54 (munmap_list::~munmap_list): Rename from munmap_list_free.
55 (munmap_listp_free_cleanup): Remove.
56 (compile_object_load): Update.
57 * compile/compile-object-load.h (struct munmap_list): Move from
58 compile-object-load.c. Rewrite.
59
60 2018-09-18 Alan Hayward <alan.hayward@arm.com>
61
62 * aarch64-tdep.c (pass_in_v): Use register size.
63 (aarch64_extract_return_value): Likewise.
64 (aarch64_store_return_value): Likewise.
65
66 2018-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
67
68 * utils.c (dump_core) [HAVE_SETRLIMIT]: Cast RLIM_INFINITY to
69 rlim_t.
70
71 2018-09-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
72
73 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter):
74 Fix short help line.
75
76 2018-09-17 Tom Tromey <tom@tromey.com>
77
78 PR python/20445:
79 * configure: Rebuild.
80 * configure.ac: Conditionally use -DNDEBUG for Python.
81
82 2018-09-17 Tom Tromey <tom@tromey.com>
83
84 * configure: Rebuild.
85 * configure.ac: Use gmp as a library dependency when checking for
86 mpfr.
87
88 2018-09-17 Pedro Alves <palves@redhat.com>
89
90 * python/py-inferior.c (find_inferior_object): Delete.
91
92 2018-09-17 Simon Marchi <simon.marchi@ericsson.com>
93
94 * compile/compile-cplus-types.c
95 (compile_cplus_instance::enter_scope): Don't use new_scope after
96 std::move.
97
98 2018-09-17 Tom Tromey <tom@tromey.com>
99
100 * common/pathstuff.c (get_standard_cache_dir): Use
101 ~/Library/Caches on macOS.
102 * common/pathstuff.h (get_standard_cache_dir): Update comment.
103
104 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
105
106 PR python/23669
107 * breakpoint.c (commands_cmd_element): New.
108 (_initialize_breakpoint): Assign commands_cmd_element.
109 * breakpoint.h (commands_cmd_element): New.
110 * cli/cli-script.c (while_cmd_element, if_command,
111 define_cmd_element): New.
112 (command_name_equals): Remove.
113 (process_next_line): Compare commands by pointer, not by name.
114 (_initialize_cli_script): Assign the various cmd_list_element
115 variables.
116 * compile/compile.c (compile_cmd_element): New.
117 (_initialize_compile): Assign compile_cmd_element.
118 * compile/compile.h (compile_cmd_element): New.
119 * guile/guile.c (guile_cmd_element): New.
120 (install_gdb_commands): Assign guile_cmd_element.
121 * guile/guile.h (guile_cmd_element): New.
122 * python/python.c (python_cmd_element): New.
123 (_initialize_python): Assign python_cmd_element.
124 * python/python.h (python_cmd_element): New.
125 * tracepoint.c (while_stepping_cmd_element): New.
126 (_initialize_tracepoint): Assign while_stepping_cmd_element.
127 * tracepoint.h (while_stepping_cmd_element): New.
128
129 2018-09-17 Tom Tromey <tom@tromey.com>
130
131 * infrun.c (save_infcall_suspend_state): Return
132 infcall_suspend_state_up.
133 (save_infcall_control_state): Return infcall_control_state_up.
134 * inferior.h (save_infcall_suspend_state)
135 (save_infcall_control_state): Declare later. Return unique
136 pointers.
137
138 2018-09-17 Tom Tromey <tom@tromey.com>
139
140 * infrun.c (struct stop_context): Declare constructor,
141 destructor, "changed" method.
142 (stop_context::stop_context): Rename from save_stop_context.
143 (stop_context::~stop_context): Rename from
144 release_stop_context_cleanup.
145 (normal_stop): Update.
146 (stop_context::changed): Rename from stop_context_changed. Return
147 bool.
148
149 2018-09-17 Tom Tromey <tom@tromey.com>
150
151 * inferior.h (struct infcall_suspend_state_deleter): New.
152 (infcall_suspend_state_up): New typedef.
153 (struct infcall_control_state_deleter): New.
154 (infcall_control_state_up): New typedef.
155 (make_cleanup_restore_infcall_suspend_state)
156 (make_cleanup_restore_infcall_control_state): Don't declare.
157 * infcall.c (call_function_by_hand_dummy): Update.
158 * infrun.c (do_restore_infcall_suspend_state_cleanup)
159 (make_cleanup_restore_infcall_suspend_state): Remove.
160 (do_restore_infcall_control_state_cleanup)
161 (make_cleanup_restore_infcall_control_state): Remove.
162
163 2018-09-17 Tom Tromey <tom@tromey.com>
164
165 * gdbthread.h (struct thread_control_state): Add initializer.
166 (class thread_info) <control>: Remove initializer.
167 * inferior.h (struct inferior_control_state): Add initializer.
168 (class inferior) <control>: Remove initializer.
169 (exit_inferior_1): Update.
170 * infrun.c (struct infcall_control_state): Add constructors.
171 (save_infcall_control_state): Use new.
172 (restore_infcall_control_state, discard_infcall_control_state):
173 Use delete.
174
175 2018-09-17 Tom Tromey <tom@tromey.com>
176
177 * infrun.c (struct infcall_suspend_state) <registers>: Now a
178 unique_ptr.
179 <siginfo_data>: Now a unique_xmalloc_ptr.
180 (save_infcall_suspend_state, restore_infcall_suspend_state)
181 (discard_infcall_suspend_state)
182 (get_infcall_suspend_state_regcache): Update.
183
184 2018-09-17 Tom Tromey <tom@tromey.com>
185
186 * gdbthread.h (struct thread_suspend_state): Add initializers.
187 (class thread_info) <suspend>: Remove initializer.
188 * infrun.c (struct infcall_suspend_state): Add initializers.
189 (save_infcall_suspend_state): Use new.
190 (discard_infcall_suspend_state): Use delete.
191
192 2018-09-16 Tom Tromey <tom@tromey.com>
193
194 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
195 Remove.
196 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
197 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
198 (py_varobj_iter_new): Likewise.
199 (py_varobj_get_iterator): Use gdbpy_ref.
200
201 2018-09-16 Tom Tromey <tom@tromey.com>
202
203 * python/py-threadevent.c (py_get_event_thread): Simplify.
204 * python/py-inferior.c (infpy_thread_from_thread_handle):
205 Return immediately after calling thread_to_thread_object. Use
206 Py_RETURN_NONE.
207 (thread_to_thread_object): Set the exception on a NULL return.
208
209 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
210
211 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
212
213 2018-09-16 Tom Tromey <tom@tromey.com>
214
215 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
216 Remove.
217
218 2018-09-16 Tom Tromey <tom@tromey.com>
219
220 * python/python-internal.h (thread_to_thread_object): Change
221 return type.
222 * python/py-inferior.c (thread_to_thread_object): Return a new
223 reference.
224 (infpy_thread_from_thread_handle): Update.
225 * python/py-infthread.c (gdbpy_selected_thread): Update.
226 * python/py-stopevent.c (create_stop_event_object): Update.
227 * python/py-threadevent.c (py_get_event_thread): Return a new
228 reference.
229 (py_get_event_thread): Update.
230 * python/py-event.h (py_get_event_thread): Change return type.
231 * python/py-continueevent.c (create_continue_event_object):
232 Update.
233
234 2018-09-16 Tom Tromey <tom@tromey.com>
235
236 * python/py-progspace.c (pspy_get_objfiles): Update.
237 * python/python-internal.h (objfile_to_objfile_object): Change
238 return type.
239 * python/py-newobjfileevent.c (create_new_objfile_event_object):
240 Update.
241 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
242 Update.
243 * python/python.c (gdbpy_get_current_objfile): Update.
244 (gdbpy_objfiles): Update.
245 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
246 Update.
247 (objfile_to_objfile_object): Return a new reference.
248 * python/py-symtab.c (stpy_get_objfile): Update.
249 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
250 Update.
251
252 2018-09-16 Tom Tromey <tom@tromey.com>
253
254 * python/py-inferior.c (infpy_get_progspace): Update.
255 * python/python-internal.h (pspace_to_pspace_object): Change
256 return type.
257 * python/py-newobjfileevent.c
258 (create_clear_objfiles_event_object): Update.
259 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
260 Update.
261 * python/python.c (gdbpy_get_current_progspace): Update.
262 (gdbpy_progspaces): Update.
263 * python/py-progspace.c (pspace_to_pspace_object): Return a new
264 reference.
265 * python/py-objfile.c (objfpy_get_progspace): Update.
266 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
267 Update.
268
269 2018-09-16 Tom Tromey <tom@tromey.com>
270
271 * python/lib/gdb/__init__.py (current_progspace, objfiles)
272 (solib_name, block_for_pc, find_pc_line): New functions.
273 (execute_unwinders): Update.
274 * python/py-block.c (gdbpy_block_for_pc): Remove.
275 * python/py-inferior.c (infpy_get_progspace): New function.
276 (inferior_object_getset) <progspace>: Add.
277 * python/py-progspace.c (pspy_objfiles): Rewrite.
278 (pspy_solib_name, pspy_block_for_pc)
279 (pspy_find_pc_line, pspy_is_valid): New functions.
280 (progspace_object_methods): Add entries for solib_name,
281 block_for_pc, find_pc_line, is_valid.
282 * python/python-internal.h (gdbpy_block_for_pc)
283 (build_objfiles_list): Don't declare.
284 * python/python.c: Don't include solib.h.
285 (gdbpy_solib_name, gdbpy_find_pc_line)
286 (gdbpy_get_current_progspace, build_objfiles_list)
287 (gdbpy_objfiles): Remove.
288 (GdbMethods) <current_progspace, objfiles, block_for_pc,
289 solib_name, find_pc_line>: Remove entries.
290
291 2018-09-16 Tom Tromey <tom@tromey.com>
292
293 * top.c (new_ui_command): Use GNU style for metasyntactic
294 variables.
295 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
296 variables.
297 * maint.c (maintenance_translate_address): Remove "<>" around
298 text.
299 * interps.c (interpreter_exec_cmd): Use GNU style for
300 metasyntactic variables.
301 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
302 metasyntactic variables.
303 * tracepoint.c (tfind_range_command): Use GNU style for
304 metasyntactic variables.
305 (tfind_outside_command): Likewise.
306 (_initialize_tracepoint): Likewise.
307 * remote.c (extended_remote_target::create_inferior): Use GNU
308 style for metasyntactic variables.
309 * sparc64-tdep.c (adi_examine_command): Use GNU style for
310 metasyntactic variables.
311 (adi_assign_command): Likewise.
312
313 2018-09-16 Tom Tromey <tom@tromey.com>
314
315 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
316 metasyntactic variables. Print message if no disassembler options
317 are available.
318
319 2018-09-15 Tom Tromey <tom@tromey.com>
320
321 * infcmd.c (get_inferior_args): Return const char *.
322 * inferior.h (get_inferior_args): Return type now const.
323 * linux-tdep.c (linux_fill_prpsinfo): Update.
324 * procfs.c (procfs_target::make_corefile_notes): Update.
325
326 2018-09-07 Tom Tromey <tom@tromey.com>
327
328 * python/python.c (execute_gdb_command): Call bpstat_do_actions
329 inside the TRY.
330
331 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
332
333 * nios2-tdep.c (nios2_type_align): New.
334 (nios2_gdb_arch_init): Install type_align hook.
335
336 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
337
338 * eval.c (fake_method::fake_method): Call xzalloc directly for a
339 type that is neither object file owned, nor gdbarch owned.
340 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
341 gdbarch is non-NULL.
342 (alloc_type_instance): Allocate non-objfile owned types on the
343 gdbarch obstack.
344 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
345 using TYPE_ALLOC to ensure memory is allocated on the correct
346 obstack.
347 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
348 obstack, or the gdbarch obstack.
349 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
350
351 2018-09-14 Tom Tromey <tom@tromey.com>
352
353 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
354 block.
355
356 2018-09-14 Tom Tromey <tom@tromey.com>
357
358 * nat/fork-inferior.c (get_startup_shell): Remove "static".
359
360 2018-09-13 Tom Tromey <tom@tromey.com>
361
362 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
363 static.
364
365 2018-09-13 Tom Tromey <tom@tromey.com>
366
367 * exec.c (try_open_exec_file): Use std::string.
368
369 2018-09-13 Tom Tromey <tom@tromey.com>
370
371 * utils.h (gdb_bfd_errmsg): Return std::string.
372 * exec.c (exec_file_attach): Update.
373 * compile/compile-object-load.c (compile_object_load): Update.
374 * utils.c (gdb_bfd_errmsg): Return std::string.
375
376 2018-09-13 Tom Tromey <tom@tromey.com>
377
378 * procfs.c (struct procinfo_deleter): New.
379 (procinfo_up): New typedef.
380 (do_destroy_procinfo_cleanup): Remove.
381 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
382
383 2018-09-13 Tom Tromey <tom@tromey.com>
384
385 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
386
387 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
388 2018-09-13 Tom Tromey <tom@tromey.com>
389
390 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
391 (pspy_get_objfiles): New function.
392 (progspace_object_methods): New.
393 (pspace_object_type): Add tp_methods callback.
394 * python/python-internal.h (build_objfiles_list): New
395 declaration.
396 * python/python.c (build_objfiles_list): New function.
397 (gdbpy_objfiles): Implement using build_objfiles_list.
398 * NEWS: Mention the Progspace.objfiles method.
399
400 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
401
402 * python/py-inferior.c (infpy_get_progspace): New function.
403 (inferior_object_getset): Add progspace property.
404 * NEWS: Mention the new property.
405
406 2018-09-13 Tom Tromey <tom@tromey.com>
407
408 PR rust/23650:
409 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
410
411 2018-09-13 Tom Tromey <tom@tromey.com>
412
413 PR rust/23626:
414 * rust-lang.c (rust_enum_variant): Now static.
415 (rust_empty_enum_p): New function.
416 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
417 Handle empty enum.
418
419 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
420
421 * python/py-inferior.c (infpy_repr): New.
422 (inferior_object_type): Register infpy_repr.
423 * python/py-objfile.c (objfpy_repr): New.
424 (objfile_object_type): Register objfpy_repr.
425
426 2018-09-12 John Baldwin <jhb@FreeBSD.org>
427
428 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
429
430 2018-09-12 John Baldwin <jhb@FreeBSD.org>
431
432 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
433 typo.
434
435 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
436
437 * common/common-utils.c: Don't include '<sys/stat.h>'.
438 (is_regular_file): Move to...
439 * common/filestuff.c (is_regular_file): ... here.
440 * common/common-utils.h (is_regular_file): Move to...
441 * common/filestuff.h (is_regular_file): ... here.
442
443 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
444
445 * skip.c (debug_skip): New variable.
446 (skiplist_entry::do_skip_file_p): Add debug output.
447 (skiplist_entry::do_skip_gfile_p): Likewise.
448 (skiplist_entry::skip_function_p): Likewise.
449 (_initialize_step_skip): Create debug command.
450 * NEWS: Mention set/show debug skip.
451
452 2018-09-11 Xavier Roirand <roirand@adacore.com>
453
454 * darwin-nat.c (should_disable_startup_with_shell):
455 New function.
456 (darwin_nat_target::create_inferior): Add call.
457
458 2018-09-11 Xavier Roirand <roirand@adacore.com>
459
460 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
461 inf_port, msg_state>: Initialize.
462 (struct darwin_thread_info) <signaled, single_step>: Change
463 type and initialize.
464 (struct darwin_thread_info) <event>: Initialize.
465
466 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
467
468 PR gdb/23555
469 PR gdb/23558
470 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
471 guesses.
472
473 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
474
475 Revert:
476 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
477
478 PR gdb/23555
479 PR gdb/23558
480 * gnulib/aclocal.m4: Regenerate.
481 * gnulib/config.in: Regenerate.
482 * gnulib/configure: Regenerate.
483 * gnulib/import/Makefile.am: Update.
484 * gnulib/import/Makefile.in: Update.
485 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
486 * gnulib/import/_Noreturn.h: ... this.
487 * gnulib/import/alloca.in.h: Update.
488 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
489 * gnulib/import/arg-nonnull.h: ... this.
490 * gnulib/import/assure.h: Update.
491 * gnulib/import/at-func.c: Update.
492 * gnulib/import/basename-lgpl.c: Update.
493 * gnulib/import/extra/snippet/c++defs.h: Rename to...
494 * gnulib/import/c++defs.h: ... this.
495 * gnulib/import/canonicalize-lgpl.c: Update.
496 * gnulib/import/cdefs.h: Update.
497 * gnulib/import/chdir-long.c: Update.
498 * gnulib/import/chdir-long.h: Update.
499 * gnulib/import/cloexec.c: Update.
500 * gnulib/import/cloexec.h: Update.
501 * gnulib/import/close.c: Update.
502 * gnulib/import/closedir.c: Update.
503 * gnulib/import/config.charset: Update.
504 * gnulib/import/dirent-private.h: Update.
505 * gnulib/import/dirent.in.h: Update.
506 * gnulib/import/dirfd.c: Update.
507 * gnulib/import/dirname-lgpl.c: Update.
508 * gnulib/import/dirname.h: Update.
509 * gnulib/import/dosname.h: Update.
510 * gnulib/import/dup-safer-flag.c: Update.
511 * gnulib/import/dup-safer.c: Update.
512 * gnulib/import/dup.c: Update.
513 * gnulib/import/dup2.c: Update.
514 * gnulib/import/errno.in.h: Update.
515 * gnulib/import/error.c: Update.
516 * gnulib/import/error.h: Update.
517 * gnulib/import/exitfail.c: Update.
518 * gnulib/import/exitfail.h: Update.
519 * gnulib/import/extra/update-copyright: Update.
520 * gnulib/import/fchdir.c: Update.
521 * gnulib/import/fcntl.c: Update.
522 * gnulib/import/fcntl.in.h: Update.
523 * gnulib/import/fd-hook.c: Update.
524 * gnulib/import/fd-hook.h: Update.
525 * gnulib/import/fd-safer-flag.c: Update.
526 * gnulib/import/fd-safer.c: Update.
527 * gnulib/import/fdopendir.c: Update.
528 * gnulib/import/filename.h: Update.
529 * gnulib/import/filenamecat-lgpl.c: Update.
530 * gnulib/import/filenamecat.h: Update.
531 * gnulib/import/flexmember.h: Update.
532 * gnulib/import/float+.h: Update.
533 * gnulib/import/float.c: Update.
534 * gnulib/import/float.in.h: Update.
535 * gnulib/import/fnmatch.c: Update.
536 * gnulib/import/fnmatch.in.h: Update.
537 * gnulib/import/fnmatch_loop.c: Update.
538 * gnulib/import/fpucw.h: Update.
539 * gnulib/import/frexp.c: Update.
540 * gnulib/import/frexpl.c: Update.
541 * gnulib/import/fstat.c: Update.
542 * gnulib/import/fstatat.c: Update.
543 * gnulib/import/getcwd-lgpl.c: Update.
544 * gnulib/import/getcwd.c: Update.
545 * gnulib/import/getdtablesize.c: Update.
546 * gnulib/import/getlogin_r.c: Update.
547 * gnulib/import/getprogname.c: Update.
548 * gnulib/import/getprogname.h: Update.
549 * gnulib/import/gettext.h: Update.
550 * gnulib/import/gettimeofday.c: Update.
551 * gnulib/import/glob-libc.h: Update.
552 * gnulib/import/glob.c: Update.
553 * gnulib/import/glob.in.h: Update.
554 * gnulib/import/glob_internal.h: Update.
555 * gnulib/import/glob_pattern_p.c: Update.
556 * gnulib/import/globfree.c: Update.
557 * gnulib/import/hard-locale.c: Update.
558 * gnulib/import/hard-locale.h: Update.
559 * gnulib/import/intprops.h: Update.
560 * gnulib/import/inttypes.in.h: Update.
561 * gnulib/import/isnan.c: Update.
562 * gnulib/import/isnand-nolibm.h: Update.
563 * gnulib/import/isnand.c: Update.
564 * gnulib/import/isnanl-nolibm.h: Update.
565 * gnulib/import/isnanl.c: Update.
566 * gnulib/import/itold.c: Update.
567 * gnulib/import/libc-config.h: Update.
568 * gnulib/import/limits.in.h: Update.
569 * gnulib/import/localcharset.c: Update.
570 * gnulib/import/localcharset.h: Update.
571 * gnulib/import/localtime-buffer.c: Update.
572 * gnulib/import/localtime-buffer.h: Update.
573 * gnulib/import/lstat.c: Update.
574 * gnulib/import/m4/00gnulib.m4: Update.
575 * gnulib/import/m4/__inline.m4: Update.
576 * gnulib/import/m4/absolute-header.m4: Update.
577 * gnulib/import/m4/alloca.m4: Update.
578 * gnulib/import/m4/builtin-expect.m4: Update.
579 * gnulib/import/m4/canonicalize.m4: Update.
580 * gnulib/import/m4/chdir-long.m4: Update.
581 * gnulib/import/m4/close.m4: Update.
582 * gnulib/import/m4/closedir.m4: Update.
583 * gnulib/import/m4/configmake.m4: Update.
584 * gnulib/import/m4/d-ino.m4: Update.
585 * gnulib/import/m4/d-type.m4: Update.
586 * gnulib/import/m4/dirent_h.m4: Update.
587 * gnulib/import/m4/dirfd.m4: Update.
588 * gnulib/import/m4/dirname.m4: Update.
589 * gnulib/import/m4/double-slash-root.m4: Update.
590 * gnulib/import/m4/dup.m4: Update.
591 * gnulib/import/m4/dup2.m4: Update.
592 * gnulib/import/m4/eealloc.m4: Update.
593 * gnulib/import/m4/environ.m4: Update.
594 * gnulib/import/m4/errno_h.m4: Update.
595 * gnulib/import/m4/error.m4: Update.
596 * gnulib/import/m4/exponentd.m4: Update.
597 * gnulib/import/m4/exponentl.m4: Update.
598 * gnulib/import/m4/extensions.m4: Update.
599 * gnulib/import/m4/extern-inline.m4: Update.
600 * gnulib/import/m4/fchdir.m4: Update.
601 * gnulib/import/m4/fcntl-o.m4: Update.
602 * gnulib/import/m4/fcntl.m4: Update.
603 * gnulib/import/m4/fcntl_h.m4: Update.
604 * gnulib/import/m4/fdopendir.m4: Update.
605 * gnulib/import/m4/filenamecat.m4: Update.
606 * gnulib/import/m4/flexmember.m4: Update.
607 * gnulib/import/m4/float_h.m4: Update.
608 * gnulib/import/m4/fnmatch.m4: Update.
609 * gnulib/import/m4/fnmatch_h.m4: Update.
610 * gnulib/import/m4/fpieee.m4: Update.
611 * gnulib/import/m4/frexp.m4: Update.
612 * gnulib/import/m4/frexpl.m4: Update.
613 * gnulib/import/m4/fstat.m4: Update.
614 * gnulib/import/m4/fstatat.m4: Update.
615 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
616 * gnulib/import/m4/getcwd-path-max.m4: Update.
617 * gnulib/import/m4/getcwd.m4: Update.
618 * gnulib/import/m4/getdtablesize.m4: Update.
619 * gnulib/import/m4/getlogin.m4: Update.
620 * gnulib/import/m4/getlogin_r.m4: Update.
621 * gnulib/import/m4/getpagesize.m4: Update.
622 * gnulib/import/m4/getprogname.m4: Update.
623 * gnulib/import/m4/gettimeofday.m4: Update.
624 * gnulib/import/m4/glibc21.m4: Update.
625 * gnulib/import/m4/glob.m4: Update.
626 * gnulib/import/m4/glob_h.m4: Update.
627 * gnulib/import/m4/gnulib-cache.m4: Update.
628 * gnulib/import/m4/gnulib-common.m4: Update.
629 * gnulib/import/m4/gnulib-comp.m4: Update.
630 * gnulib/import/m4/gnulib-tool.m4: Update.
631 * gnulib/import/m4/hard-locale.m4: Update.
632 * gnulib/import/m4/include_next.m4: Update.
633 * gnulib/import/m4/inttypes-pri.m4: Update.
634 * gnulib/import/m4/inttypes.m4: Update.
635 * gnulib/import/m4/isnand.m4: Update.
636 * gnulib/import/m4/isnanl.m4: Update.
637 * gnulib/import/m4/largefile.m4: Update.
638 * gnulib/import/m4/limits-h.m4: Update.
639 * gnulib/import/m4/localcharset.m4: Update.
640 * gnulib/import/m4/locale-fr.m4: Update.
641 * gnulib/import/m4/locale-ja.m4: Update.
642 * gnulib/import/m4/locale-zh.m4: Update.
643 * gnulib/import/m4/localtime-buffer.m4: Update.
644 * gnulib/import/m4/longlong.m4: Update.
645 * gnulib/import/m4/lstat.m4: Update.
646 * gnulib/import/m4/malloc.m4: Update.
647 * gnulib/import/m4/malloca.m4: Update.
648 * gnulib/import/m4/math_h.m4: Update.
649 * gnulib/import/m4/mbrtowc.m4: Update.
650 * gnulib/import/m4/mbsinit.m4: Update.
651 * gnulib/import/m4/mbsrtowcs.m4: Update.
652 * gnulib/import/m4/mbstate_t.m4: Update.
653 * gnulib/import/m4/memchr.m4: Update.
654 * gnulib/import/m4/memmem.m4: Update.
655 * gnulib/import/m4/mempcpy.m4: Update.
656 * gnulib/import/m4/memrchr.m4: Update.
657 * gnulib/import/m4/mkdir.m4: Update.
658 * gnulib/import/m4/mkstemp.m4: Update.
659 * gnulib/import/m4/mmap-anon.m4: Update.
660 * gnulib/import/m4/mode_t.m4: Update.
661 * gnulib/import/m4/msvc-inval.m4: Update.
662 * gnulib/import/m4/msvc-nothrow.m4: Update.
663 * gnulib/import/m4/multiarch.m4: Update.
664 * gnulib/import/m4/nocrash.m4: Update.
665 * gnulib/import/m4/off_t.m4: Update.
666 * gnulib/import/m4/onceonly.m4: Update.
667 * gnulib/import/m4/open-cloexec.m4: Update.
668 * gnulib/import/m4/open.m4: Update.
669 * gnulib/import/m4/openat.m4: Update.
670 * gnulib/import/m4/opendir.m4: Update.
671 * gnulib/import/m4/pathmax.m4: Update.
672 * gnulib/import/m4/rawmemchr.m4: Update.
673 * gnulib/import/m4/readdir.m4: Update.
674 * gnulib/import/m4/readlink.m4: Update.
675 * gnulib/import/m4/realloc.m4: Update.
676 * gnulib/import/m4/rename.m4: Update.
677 * gnulib/import/m4/rewinddir.m4: Update.
678 * gnulib/import/m4/rmdir.m4: Update.
679 * gnulib/import/m4/save-cwd.m4: Update.
680 * gnulib/import/m4/secure_getenv.m4: Update.
681 * gnulib/import/m4/setenv.m4: Update.
682 * gnulib/import/m4/signal_h.m4: Update.
683 * gnulib/import/m4/ssize_t.m4: Update.
684 * gnulib/import/m4/stat-time.m4: Update.
685 * gnulib/import/m4/stat.m4: Update.
686 * gnulib/import/m4/std-gnu11.m4: Update.
687 * gnulib/import/m4/stdbool.m4: Update.
688 * gnulib/import/m4/stddef_h.m4: Update.
689 * gnulib/import/m4/stdint.m4: Update.
690 * gnulib/import/m4/stdio_h.m4: Update.
691 * gnulib/import/m4/stdlib_h.m4: Update.
692 * gnulib/import/m4/strchrnul.m4: Update.
693 * gnulib/import/m4/strdup.m4: Update.
694 * gnulib/import/m4/strerror.m4: Update.
695 * gnulib/import/m4/string_h.m4: Update.
696 * gnulib/import/m4/strstr.m4: Update.
697 * gnulib/import/m4/strtok_r.m4: Update.
698 * gnulib/import/m4/sys_socket_h.m4: Update.
699 * gnulib/import/m4/sys_stat_h.m4: Update.
700 * gnulib/import/m4/sys_time_h.m4: Update.
701 * gnulib/import/m4/sys_types_h.m4: Update.
702 * gnulib/import/m4/tempname.m4: Update.
703 * gnulib/import/m4/time_h.m4: Update.
704 * gnulib/import/m4/unistd-safer.m4: Update.
705 * gnulib/import/m4/unistd_h.m4: Update.
706 * gnulib/import/m4/warn-on-use.m4: Update.
707 * gnulib/import/m4/wchar_h.m4: Update.
708 * gnulib/import/m4/wchar_t.m4: Update.
709 * gnulib/import/m4/wctype_h.m4: Update.
710 * gnulib/import/m4/wint_t.m4: Update.
711 * gnulib/import/malloc.c: Update.
712 * gnulib/import/malloc/scratch_buffer.h: Update.
713 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
714 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
715 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
716 * gnulib/import/malloca.c: Update.
717 * gnulib/import/malloca.h: Update.
718 * gnulib/import/malloca.valgrind: Update.
719 * gnulib/import/math.in.h: Update.
720 * gnulib/import/mbrtowc.c: Update.
721 * gnulib/import/mbsinit.c: Update.
722 * gnulib/import/mbsrtowcs-impl.h: Update.
723 * gnulib/import/mbsrtowcs-state.c: Update.
724 * gnulib/import/mbsrtowcs.c: Update.
725 * gnulib/import/memchr.c: Update.
726 * gnulib/import/memmem.c: Update.
727 * gnulib/import/mempcpy.c: Update.
728 * gnulib/import/memrchr.c: Update.
729 * gnulib/import/mkdir.c: Update.
730 * gnulib/import/mkstemp.c: Update.
731 * gnulib/import/msvc-inval.c: Update.
732 * gnulib/import/msvc-inval.h: Update.
733 * gnulib/import/msvc-nothrow.c: Update.
734 * gnulib/import/msvc-nothrow.h: Update.
735 * gnulib/import/open.c: Update.
736 * gnulib/import/openat-die.c: Update.
737 * gnulib/import/openat-priv.h: Update.
738 * gnulib/import/openat-proc.c: Update.
739 * gnulib/import/openat.c: Update.
740 * gnulib/import/openat.h: Update.
741 * gnulib/import/opendir.c: Update.
742 * gnulib/import/pathmax.h: Update.
743 * gnulib/import/pipe-safer.c: Update.
744 * gnulib/import/rawmemchr.c: Update.
745 * gnulib/import/readdir.c: Update.
746 * gnulib/import/readlink.c: Update.
747 * gnulib/import/realloc.c: Update.
748 * gnulib/import/ref-add.sin: Update.
749 * gnulib/import/ref-del.sin: Update.
750 * gnulib/import/rename.c: Update.
751 * gnulib/import/rewinddir.c: Update.
752 * gnulib/import/rmdir.c: Update.
753 * gnulib/import/same-inode.h: Update.
754 * gnulib/import/save-cwd.c: Update.
755 * gnulib/import/save-cwd.h: Update.
756 * gnulib/import/scratch_buffer.h: Update.
757 * gnulib/import/secure_getenv.c: Update.
758 * gnulib/import/setenv.c: Update.
759 * gnulib/import/signal.in.h: Update.
760 * gnulib/import/stat-time.c: Update.
761 * gnulib/import/stat-time.h: Update.
762 * gnulib/import/stat-w32.c: Update.
763 * gnulib/import/stat-w32.h: Update.
764 * gnulib/import/stat.c: Update.
765 * gnulib/import/stdbool.in.h: Update.
766 * gnulib/import/stddef.in.h: Update.
767 * gnulib/import/stdint.in.h: Update.
768 * gnulib/import/stdio.in.h: Update.
769 * gnulib/import/stdlib.in.h: Update.
770 * gnulib/import/str-two-way.h: Update.
771 * gnulib/import/strchrnul.c: Update.
772 * gnulib/import/strdup.c: Update.
773 * gnulib/import/streq.h: Update.
774 * gnulib/import/strerror-override.c: Update.
775 * gnulib/import/strerror-override.h: Update.
776 * gnulib/import/strerror.c: Update.
777 * gnulib/import/string.in.h: Update.
778 * gnulib/import/stripslash.c: Update.
779 * gnulib/import/strnlen1.c: Update.
780 * gnulib/import/strnlen1.h: Update.
781 * gnulib/import/strstr.c: Update.
782 * gnulib/import/strtok_r.c: Update.
783 * gnulib/import/sys_stat.in.h: Update.
784 * gnulib/import/sys_time.in.h: Update.
785 * gnulib/import/sys_types.in.h: Update.
786 * gnulib/import/tempname.c: Update.
787 * gnulib/import/tempname.h: Update.
788 * gnulib/import/time.in.h: Update.
789 * gnulib/import/unistd--.h: Update.
790 * gnulib/import/unistd-safer.h: Update.
791 * gnulib/import/unistd.in.h: Update.
792 * gnulib/import/unsetenv.c: Update.
793 * gnulib/import/verify.h: Update.
794 * gnulib/import/extra/snippet/warn-on-use.h: Update.
795 * gnulib/import/wchar.in.h: Update.
796 * gnulib/import/wctype.in.h: Update.
797 * gnulib/import/xalloc-oversized.h: Update.
798 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
799 "53e2c179f26a890fa6685af4b6c1397ee370433b".
800
801 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
802
803 * record-btrace.c (get_thread_current_frame): Remove
804 old_inferior_ptid.
805
806 2018-09-10 Jerome Guitton <guitton@adacore.com>
807
808 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
809 with check_tag to 1 if and only if the type is tagged and the
810 component being searched cannot been found in the current
811 view. Otherwise, always call ada_to_fixed_type with
812 check_tag to 0.
813
814 2018-09-10 Xavier Roirand <roirand@adacore.com>
815
816 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
817 declaration.
818 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
819 * ada-varobj.c (ada_varobj_get_number_of_children,
820 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
821
822 2018-09-10 Xavier Roirand <roirand@adacore.com>
823
824 * ada-valprint.c (ada_value_print): Use type instead of
825 enclosing type.
826
827 2018-09-10 Xavier Roirand <roirand@adacore.com>
828
829 * ada-lang.c (ada_value_subscript): Handle case when parameter is
830 an array of access to unconstrained array.
831
832 2018-09-10 Xavier Roirand <roirand@adacore.com>
833
834 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
835 (ada_check_typedef): Use it.
836
837 2018-09-10 Xavier Roirand <roirand@adacore.com>
838
839 * ada-varobj.c (ada_varobj_describe_struct_child)
840 (ada_varobj_describe_child): Handle union case like struct one.
841
842 2018-09-10 Tom Tromey <tom@tromey.com>
843
844 PR python/18380:
845 * python/python.c (_initialize_python): Make example in "python"
846 help work in Python 3.
847
848 2018-09-10 Eli Zaretskii <eliz@gnu.org>
849
850 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
851 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
852 $(EXEEXT) to the script, as it is not a program.
853
854 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
855
856 * python/py-prettyprint.c (pretty_print_one_value): Return
857 gdbpy_ref<>.
858 (print_string_repr): Adjust.
859 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
860 * python/python-internal.h (apply_varobj_pretty_printer): Return
861 gdbpy_ref<>.
862 * varobj.c (varobj_value_get_print_value): Adjust.
863
864 2018-09-08 Tom Tromey <tom@tromey.com>
865
866 PR python/16047:
867 * python/py-prettyprint.c (pretty_print_one_value): Check for
868 to_string method.
869
870 2018-09-08 Joel Brobecker <brobecker@adacore.com>
871
872 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
873 replace_operator_with_call.
874
875 2018-09-08 Joel Brobecker <brobecker@adacore.com>
876
877 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
878
879 2018-09-08 Joel Brobecker <brobecker@adacore.com>
880
881 * ada-typeprint.c (print_range): Print the bounds using TYPE
882 rather than its TYPE_TARGET_TYPE.
883
884 2018-09-08 Joel Brobecker <brobecker@adacore.com>
885
886 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
887 call to ada_to_fixed_value_create.
888
889 2018-09-08 Jerome Guitton <guitton@adacore.com>
890
891 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
892
893 2018-09-08 Joel Brobecker <brobecker@adacore.com>
894
895 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
896 by calls to error.
897
898 2018-09-08 Joel Brobecker <brobecker@adacore.com>
899
900 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
901 Move update of loop variable "fi".
902
903 2018-09-08 Joel Brobecker <brobecker@adacore.com>
904
905 * ada-lang.c (value_assign_to_component): In the case of
906 big-endian targets, extract the bits of the given VAL
907 using an src_offset of zero if container is not a scalar.
908
909 2018-09-06 Simon Ser <contact@emersion.fr>
910
911 PR gdb/23105
912 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
913 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
914 * fbsd-tdep.c (fbsd_make_note_desc): New.
915 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
916 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
917 * target.h (enum target_object) Add FreeBSD-specific
918 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
919
920 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
921
922 * compile/compile-c.h (generate_c_for_variable_locations):
923 Change reference to pointer.
924 * compile/compile-c-support.c (compile_program) <compute>:
925 Likewise.
926 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
927 (generate_c_for_for_one_variable): Likewise
928 (generate_c_for_variable_locations): Likewise
929 * compile/compile-c-types.c (compile_c_instance::convert_type):
930 Likewise
931 * compile/compile-cplus-symbols.c (convert_one_symbol):
932 std::move the scope passed to enter_scope.
933 * compile/compile-cplus-types.c
934 (compile_cplus_instance::enter_scope): Make parameter
935 rvalue-reference.
936 (compile_cplus_instance::new_scope): Change reference to
937 pointer.
938 (compile_cplus_instance::convert_type): Likewise
939 (compile_cplus_convert_typedef): std::move the scope passed to
940 enter_scope.
941 (compile_cplus_convert_struct_or_union): Likewise.
942 (compile_cplus_convert_enum): Likewise.
943 (compile_cplus_convert_namespace): Likewise.
944 * compile/compile-cplus.h (compile_cplus_instance)
945 <enter_scope>: Make parameter rvalue-reference.
946 * compile/compile-internal.h (compile_instance)
947 <get_cached_type>: Likewise
948 * compile/compile-loc2c.c (push): Likewise
949 (pushf): Likewise
950 (unary): Likewise
951 (binary): Likewise
952 (print_label): Likewise
953 (pushf_register_address): Likewise
954 (pushf_register): Likewise
955 (do_compile_dwarf_expr_to_c): Likewise
956 (compile_dwarf_expr_to_c): Likewise
957 (compile_dwarf_bounds_to_c): Likewise
958 * compile/compile.c (compile_instance::get_cached_type):
959 Likewise
960 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
961 (compile_dwarf_bounds_to_c): Likewise
962 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
963 (dwarf2_compile_property_to_c): Likewise
964 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
965 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
966 Likewise
967
968 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
969
970 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
971 * tui/tui-data.c (init_content_element): Don't initialize it.
972
973 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
974
975 * tui/tui-data.h (struct tui_win_info)
976 <detail::opaque>: Remove.
977 * tui/tui-data.c (init_win_info): Remove assignment.
978
979 2018-09-05 Tom Tromey <tom@tromey.com>
980
981 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
982 -Wformat-nonliteral.
983 * target-float.c (host_float_ops<T>::to_string)
984 (host_float_ops<T>::from_string): Use
985 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
986 * configure: Rebuild.
987
988 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
989
990 * printcmd.c (printf_c_string): Use
991 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
992 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
993
994 2018-09-05 Tom Tromey <tom@tromey.com>
995
996 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
997
998 2018-09-05 Tom de Vries <tdevries@suse.de>
999
1000 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
1001 with resolve_abstract_p == true.
1002 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
1003 defaulting to false. Propagate resolve_abstract_p to
1004 dwarf2_fetch_die_loc_sect_off.
1005 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
1006 parameter, defaulting to false.
1007 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
1008 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
1009 parameter.
1010 * dwarf2read.h (struct die_info): Forward-declare.
1011 (die_info_ptr): New typedef.
1012 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
1013
1014 2018-09-05 Joel Brobecker <brobecker@adacore.com>
1015
1016 GDB 8.2 released.
1017
1018 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
1019 Pedro Alves <palves@redhat.com>
1020
1021 * gnulib/Makefile.in (aclocal_m4_deps): Move to
1022 "aclocal-m4-deps.mk". Include file here.
1023 $(srcdir)/aclocal.m4: Add "configure.ac".
1024 * gnulib/aclocal-m4-deps.mk: New file.
1025 * gnulib/update-gnulib.sh: Automatically update
1026 "aclocal-m4-deps.mk".
1027
1028 2018-09-04 Tom Tromey <tom@tromey.com>
1029
1030 * configure: Rebuild.
1031 * configure.ac: Remove multi-ice code.
1032
1033 2018-09-04 Tom Tromey <tom@tromey.com>
1034
1035 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
1036 (ada-exp.o): Update.
1037
1038 2018-09-04 Tom Tromey <tom@tromey.com>
1039
1040 * Makefile.in (printcmd.o, target-float.o): Remove.
1041 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
1042
1043 2018-09-04 Tom Tromey <tom@tromey.com>
1044
1045 * gnulib/Makefile.in: Remove obsolete comment.
1046 * Makefile.in: Remove obsolete comment.
1047
1048 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
1049
1050 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
1051 line with '+'.
1052
1053 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
1054
1055 * riscv-tdep.c: Add 'prologue-value.h' include.
1056 (struct riscv_unwind_cache): New struct.
1057 (riscv_debug_unwinder): New global.
1058 (riscv_scan_prologue): Update arguments, capture register details
1059 from prologue scan.
1060 (riscv_skip_prologue): Reformat arguments line, move end of
1061 prologue calculation into riscv_scan_prologue.
1062 (riscv_frame_cache): Update return type, create
1063 riscv_unwind_cache, scan the prologue, and fill in remaining cache
1064 details.
1065 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
1066 (riscv_frame_prev_register): Use the trad_frame within the
1067 riscv_unwind_cache.
1068 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
1069 flag.
1070
1071 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
1072
1073 * trad-frame.h (trad_frame_set_realreg): Declare.
1074 (trad_frame_set_addr): Declare.
1075 * trad-frame.c (trad_frame_set_realreg): Define new function.
1076 (trad_frame_set_addr): Define new function.
1077 (trad_frame_set_reg_realreg): Use new function.
1078 (trad_frame_set_reg_addr): Use new function.
1079
1080 2018-09-01 Keith Seitz <keiths@redhat.com>
1081
1082 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
1083 pulongest instead of "%lld".
1084 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
1085 ATTRIBUTE_UNUSED.
1086
1087 2018-08-31 Tom Tromey <tom@tromey.com>
1088
1089 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
1090 variant part type.
1091
1092 2018-08-31 Pedro Alves <palves@redhat.com>
1093
1094 * gdbarch.h: Regenerate.
1095
1096 2018-08-31 Pedro Alves <palves@redhat.com>
1097
1098 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
1099 * target.h (Hardware watchpoint interfaces): Describe
1100 continuable/steppable/non-steppable watchpoints.
1101 * gdbarch.h, gdbarch.c: Regenerate.
1102
1103 2018-08-31 Pedro Alves <palves@redhat.com>
1104
1105 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
1106 Delete.
1107 * s390-linux-nat.c
1108 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
1109 * target.h (target_ops::have_continuable_watchpoint): Delete.
1110 (target_have_continuable_watchpoint): Delete.
1111 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
1112 * target-delegates.c: Regenerate.
1113
1114 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
1115
1116 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
1117 the files present in "gnulib/import/m4/".
1118
1119 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
1120
1121 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
1122 c.sw, c.swsp, and c.sdsp.
1123
1124 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
1125
1126 * riscv-tdep.c (struct riscv_inferior_data): Delete.
1127 (riscv_read_misa_reg): Don't cache value read into inferior data.
1128 (riscv_new_inferior_data): Delete.
1129 (riscv_inferior_data_cleanup): Delete.
1130 (riscv_inferior_data): Delete.
1131 (riscv_invalidate_inferior_data): Delete.
1132 (_initialize_riscv_tdep): Remove initialisation of inferior data.
1133
1134 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
1135
1136 * compile/compile-cplus-types.c
1137 (compile_cplus_instance::leave_scope): Take the address of scope
1138 object.
1139 (compile_cplus_instance::convert_qualified_base): Compare quals
1140 to 0.
1141
1142 2018-08-30 Keith Seitz <keiths@redhat.com>
1143
1144 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
1145 Use "%s" and host_address_to_string instead of "%p" in printf.
1146
1147 2018-08-29 Keith Seitz <keiths@redhat.com>
1148
1149 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
1150 and compile-cplus-types.c.
1151 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
1152 * c-lang.c (cplus_language_defn): Set C++ compile functions.
1153 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
1154 Declare.
1155 * compile/compile-c-support.c: Include compile-cplus.h.
1156 (load_libcompile): Templatize.
1157 (get_compile_context): "New" function.
1158 (c_get_compile_context): Use get_compile_context.
1159 (cplus_get_compile_context): New function.
1160 (cplus_push_user_expression, cplus_pop_user_expression)
1161 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
1162 (cplus_compute_program): Define new structs/functions.
1163 * compile/compile-cplus-symmbols.c: New file.
1164 * compile/compile-cplus-types.c: New file.
1165 * compile/compile-cplus.h: New file.
1166 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
1167 Declare.
1168 * compile/compile-object-load.c (get_out_value_type): Use
1169 strncmp_iw when comparing symbol names.
1170 (compile_object_load): Add mst_bss and mst_data.
1171 * compile/compile.c (_initialize_compile): Remove
1172 -Wno-implicit-function-declaration from `compile_args'.
1173 * compile/gcc-cp-plugin.h: New file.
1174 * NEWS: Mention C++ compile support and new debug options.
1175
1176 2018-08-29 Keith Seitz <keiths@redhat.com>
1177
1178 * linespec.c (collect_info::add_symbol): Make virtual.
1179 (struct symbol_searcher_collect_info): New struct.
1180 (symbol_searcher::find_all_symbols): New method.
1181 * symtab.h (class symbol_searcher): New class.
1182
1183 2018-08-29 Keith Seitz <keiths@redhat.com>
1184
1185 * linespec.c (struct linespec) <function_symbols, label_symbols>:
1186 Change to vector of block_symbol. Update all users.
1187 (struct collect_info) <symbols>: Likewise.
1188 (collect_info::add_symbol): Take block_symbol as argument.
1189 Update all callers.
1190 (decode_compound_collector) <m_symbols>: Change type to vector
1191 of block_symbol. Update all users.
1192 (decode_compound_collector::operator ()): Change parameter type
1193 to block_symbol.
1194 (find_method, find_function_symbols, find_linespec_symbols)
1195 (find_label_symbols_in_block, find_label_symbols): Change symbol
1196 vectors to block_symbol vectors.
1197 * symtab.h (symbol_found_callback_ftype): Change parameter type to
1198 block_symbol.
1199
1200 2018-08-29 Keith Seitz <keiths@redhat.com>
1201
1202 * linespec.c (symbolp): Remove typedef and VEC definitions.
1203 (bound_minimal_symbol_d): Likewise.
1204
1205 2018-08-29 Keith Seitz <keiths@redhat.com>
1206
1207 * linespec.c (decode_compound_collector::decode_compound_collector):
1208 Remove initialization for `m_symtabs'.
1209 (decode_compound_collector::release_symbols): Change return type
1210 to std::vector. Update all callers.
1211 (class decode_compound_collector) <m_symbols>: Change type to
1212 std::vector.
1213 (lookup_prefix_sym): Change return type to std::vector. Update all
1214 callers.
1215 (compare_symbols): Remove.
1216 (std_compare_symbols): Rename to `compare_symbols'.
1217 (find_method): Change `sym_classes' parameter to std::vector.
1218 Update all callers. Use std::sort to sort sym_classes.
1219 (find_linespec_symbols): Remove cleanup.
1220
1221 2018-08-29 Keith Seitz <keiths@redhat.com>
1222
1223 * linespec.c (struct linespec) <minimal_symbols>: Change type to
1224 std::vector. Update all users.
1225 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
1226 (struct collect_info) <minimal_symbols>: Likewise.
1227 (compare_msymbols): Return bool. Change parameters to const
1228 bound_minimal_symbol references.
1229 (find_method, find_function_symbols, find_linespec_symbols): Change
1230 `minsyms' parameter to std::vector. Update all callers.
1231
1232 2018-08-29 Keith Seitz <keiths@redhat.com>
1233
1234 * linespec.c (struct linespec) <label_symbols>: Change type to
1235 std::vector. Update all users.
1236 (find_label_symbols_in_block): Change `result' parameter to
1237 std::vector. Update all callers.
1238 (find_label_symbols): Return std::vector. Update all callers.
1239
1240 2018-08-29 Keith Seitz <keiths@redhat.com>
1241
1242 * linespec.c (struct linespec) <function_symbols>: Change type to
1243 std::vector. Update all users.
1244 (struct collect_info) <function_symbols>: Likewise.
1245 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
1246 (std_compare_symbols): New function.
1247 (find_method, find_function_symbols, find_linespec_symbols)
1248 (find_label_symbols_in_block): Change `symbols' parameter to
1249 std::vector. Update all callers.
1250 (find_label_symbols): Likewise for `function_symbols' and
1251 `label_funcs_ret'.
1252
1253 2018-08-29 Keith Seitz <keiths@redhat.com>
1254
1255 * linespec.c (symtab_vector_up): Define.
1256 (struct linespec) <file_symtabs>: Change type to std::vector *.
1257 Update all uses.
1258 (struct collect_info) <file_symtabs>: Likewise.
1259 (collect_symtabs_from_filename): Return symtab_vector_up.
1260 Update all callers.
1261 (decode_objc): Remove cleanup.
1262 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
1263 (symtab_collector::release_symtabs): Return symtab_vector_up.
1264 Update all callers.
1265 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
1266 Update all users.
1267 (collect_symtabs_from_filename, symtabs_from_filename): Return
1268 symtab_vector_up. Update all callers.
1269
1270 2018-08-29 Tom Tromey <tom@tromey.com>
1271
1272 * csky-tdep.c (csky_analyze_prologue): Use
1273 core_addr_to_string_nz.
1274
1275 2018-08-29 Tom Tromey <tom@tromey.com>
1276
1277 * windows-nat.c (struct xlate_exception) <them>: Change type to
1278 DWORD.
1279 (xlate): Fix formatting. Remove last entry.
1280 (struct xlate_exception, xlate): Comment out.
1281 (windows_nat_target::resume): Use ranged for.
1282
1283 2018-08-29 Jim Wilson <jimw@sifive.com>
1284
1285 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
1286 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
1287 of NT_PRFPREG.
1288 (riscv_linux_nat_target::store_registers): Likewise.
1289
1290 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
1291
1292 PR gdb/23555
1293 PR gdb/23558
1294 * gnulib/aclocal.m4: Regenerate.
1295 * gnulib/config.in: Regenerate.
1296 * gnulib/configure: Regenerate.
1297 * gnulib/import/Makefile.am: Update.
1298 * gnulib/import/Makefile.in: Update.
1299 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
1300 * gnulib/import/_Noreturn.h: ... this.
1301 * gnulib/import/alloca.in.h: Update.
1302 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
1303 * gnulib/import/arg-nonnull.h: ... this.
1304 * gnulib/import/assure.h: Update.
1305 * gnulib/import/at-func.c: Update.
1306 * gnulib/import/basename-lgpl.c: Update.
1307 * gnulib/import/extra/snippet/c++defs.h: Rename to...
1308 * gnulib/import/c++defs.h: ... this.
1309 * gnulib/import/canonicalize-lgpl.c: Update.
1310 * gnulib/import/cdefs.h: Update.
1311 * gnulib/import/chdir-long.c: Update.
1312 * gnulib/import/chdir-long.h: Update.
1313 * gnulib/import/cloexec.c: Update.
1314 * gnulib/import/cloexec.h: Update.
1315 * gnulib/import/close.c: Update.
1316 * gnulib/import/closedir.c: Update.
1317 * gnulib/import/config.charset: Update.
1318 * gnulib/import/dirent-private.h: Update.
1319 * gnulib/import/dirent.in.h: Update.
1320 * gnulib/import/dirfd.c: Update.
1321 * gnulib/import/dirname-lgpl.c: Update.
1322 * gnulib/import/dirname.h: Update.
1323 * gnulib/import/dosname.h: Update.
1324 * gnulib/import/dup-safer-flag.c: Update.
1325 * gnulib/import/dup-safer.c: Update.
1326 * gnulib/import/dup.c: Update.
1327 * gnulib/import/dup2.c: Update.
1328 * gnulib/import/errno.in.h: Update.
1329 * gnulib/import/error.c: Update.
1330 * gnulib/import/error.h: Update.
1331 * gnulib/import/exitfail.c: Update.
1332 * gnulib/import/exitfail.h: Update.
1333 * gnulib/import/extra/update-copyright: Update.
1334 * gnulib/import/fchdir.c: Update.
1335 * gnulib/import/fcntl.c: Update.
1336 * gnulib/import/fcntl.in.h: Update.
1337 * gnulib/import/fd-hook.c: Update.
1338 * gnulib/import/fd-hook.h: Update.
1339 * gnulib/import/fd-safer-flag.c: Update.
1340 * gnulib/import/fd-safer.c: Update.
1341 * gnulib/import/fdopendir.c: Update.
1342 * gnulib/import/filename.h: Update.
1343 * gnulib/import/filenamecat-lgpl.c: Update.
1344 * gnulib/import/filenamecat.h: Update.
1345 * gnulib/import/flexmember.h: Update.
1346 * gnulib/import/float+.h: Update.
1347 * gnulib/import/float.c: Update.
1348 * gnulib/import/float.in.h: Update.
1349 * gnulib/import/fnmatch.c: Update.
1350 * gnulib/import/fnmatch.in.h: Update.
1351 * gnulib/import/fnmatch_loop.c: Update.
1352 * gnulib/import/fpucw.h: Update.
1353 * gnulib/import/frexp.c: Update.
1354 * gnulib/import/frexpl.c: Update.
1355 * gnulib/import/fstat.c: Update.
1356 * gnulib/import/fstatat.c: Update.
1357 * gnulib/import/getcwd-lgpl.c: Update.
1358 * gnulib/import/getcwd.c: Update.
1359 * gnulib/import/getdtablesize.c: Update.
1360 * gnulib/import/getlogin_r.c: Update.
1361 * gnulib/import/getprogname.c: Update.
1362 * gnulib/import/getprogname.h: Update.
1363 * gnulib/import/gettext.h: Update.
1364 * gnulib/import/gettimeofday.c: Update.
1365 * gnulib/import/glob-libc.h: Update.
1366 * gnulib/import/glob.c: Update.
1367 * gnulib/import/glob.in.h: Update.
1368 * gnulib/import/glob_internal.h: Update.
1369 * gnulib/import/glob_pattern_p.c: Update.
1370 * gnulib/import/globfree.c: Update.
1371 * gnulib/import/hard-locale.c: Update.
1372 * gnulib/import/hard-locale.h: Update.
1373 * gnulib/import/intprops.h: Update.
1374 * gnulib/import/inttypes.in.h: Update.
1375 * gnulib/import/isnan.c: Update.
1376 * gnulib/import/isnand-nolibm.h: Update.
1377 * gnulib/import/isnand.c: Update.
1378 * gnulib/import/isnanl-nolibm.h: Update.
1379 * gnulib/import/isnanl.c: Update.
1380 * gnulib/import/itold.c: Update.
1381 * gnulib/import/libc-config.h: Update.
1382 * gnulib/import/limits.in.h: Update.
1383 * gnulib/import/localcharset.c: Update.
1384 * gnulib/import/localcharset.h: Update.
1385 * gnulib/import/localtime-buffer.c: Update.
1386 * gnulib/import/localtime-buffer.h: Update.
1387 * gnulib/import/lstat.c: Update.
1388 * gnulib/import/m4/00gnulib.m4: Update.
1389 * gnulib/import/m4/__inline.m4: Update.
1390 * gnulib/import/m4/absolute-header.m4: Update.
1391 * gnulib/import/m4/alloca.m4: Update.
1392 * gnulib/import/m4/builtin-expect.m4: Update.
1393 * gnulib/import/m4/canonicalize.m4: Update.
1394 * gnulib/import/m4/chdir-long.m4: Update.
1395 * gnulib/import/m4/close.m4: Update.
1396 * gnulib/import/m4/closedir.m4: Update.
1397 * gnulib/import/m4/configmake.m4: Update.
1398 * gnulib/import/m4/d-ino.m4: Update.
1399 * gnulib/import/m4/d-type.m4: Update.
1400 * gnulib/import/m4/dirent_h.m4: Update.
1401 * gnulib/import/m4/dirfd.m4: Update.
1402 * gnulib/import/m4/dirname.m4: Update.
1403 * gnulib/import/m4/double-slash-root.m4: Update.
1404 * gnulib/import/m4/dup.m4: Update.
1405 * gnulib/import/m4/dup2.m4: Update.
1406 * gnulib/import/m4/eealloc.m4: Update.
1407 * gnulib/import/m4/environ.m4: Update.
1408 * gnulib/import/m4/errno_h.m4: Update.
1409 * gnulib/import/m4/error.m4: Update.
1410 * gnulib/import/m4/exponentd.m4: Update.
1411 * gnulib/import/m4/exponentl.m4: Update.
1412 * gnulib/import/m4/extensions.m4: Update.
1413 * gnulib/import/m4/extern-inline.m4: Update.
1414 * gnulib/import/m4/fchdir.m4: Update.
1415 * gnulib/import/m4/fcntl-o.m4: Update.
1416 * gnulib/import/m4/fcntl.m4: Update.
1417 * gnulib/import/m4/fcntl_h.m4: Update.
1418 * gnulib/import/m4/fdopendir.m4: Update.
1419 * gnulib/import/m4/filenamecat.m4: Update.
1420 * gnulib/import/m4/flexmember.m4: Update.
1421 * gnulib/import/m4/float_h.m4: Update.
1422 * gnulib/import/m4/fnmatch.m4: Update.
1423 * gnulib/import/m4/fnmatch_h.m4: Update.
1424 * gnulib/import/m4/fpieee.m4: Update.
1425 * gnulib/import/m4/frexp.m4: Update.
1426 * gnulib/import/m4/frexpl.m4: Update.
1427 * gnulib/import/m4/fstat.m4: Update.
1428 * gnulib/import/m4/fstatat.m4: Update.
1429 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
1430 * gnulib/import/m4/getcwd-path-max.m4: Update.
1431 * gnulib/import/m4/getcwd.m4: Update.
1432 * gnulib/import/m4/getdtablesize.m4: Update.
1433 * gnulib/import/m4/getlogin.m4: Update.
1434 * gnulib/import/m4/getlogin_r.m4: Update.
1435 * gnulib/import/m4/getpagesize.m4: Update.
1436 * gnulib/import/m4/getprogname.m4: Update.
1437 * gnulib/import/m4/gettimeofday.m4: Update.
1438 * gnulib/import/m4/glibc21.m4: Update.
1439 * gnulib/import/m4/glob.m4: Update.
1440 * gnulib/import/m4/glob_h.m4: Update.
1441 * gnulib/import/m4/gnulib-cache.m4: Update.
1442 * gnulib/import/m4/gnulib-common.m4: Update.
1443 * gnulib/import/m4/gnulib-comp.m4: Update.
1444 * gnulib/import/m4/gnulib-tool.m4: Update.
1445 * gnulib/import/m4/hard-locale.m4: Update.
1446 * gnulib/import/m4/include_next.m4: Update.
1447 * gnulib/import/m4/inttypes-pri.m4: Update.
1448 * gnulib/import/m4/inttypes.m4: Update.
1449 * gnulib/import/m4/isnand.m4: Update.
1450 * gnulib/import/m4/isnanl.m4: Update.
1451 * gnulib/import/m4/largefile.m4: Update.
1452 * gnulib/import/m4/limits-h.m4: Update.
1453 * gnulib/import/m4/localcharset.m4: Update.
1454 * gnulib/import/m4/locale-fr.m4: Update.
1455 * gnulib/import/m4/locale-ja.m4: Update.
1456 * gnulib/import/m4/locale-zh.m4: Update.
1457 * gnulib/import/m4/localtime-buffer.m4: Update.
1458 * gnulib/import/m4/longlong.m4: Update.
1459 * gnulib/import/m4/lstat.m4: Update.
1460 * gnulib/import/m4/malloc.m4: Update.
1461 * gnulib/import/m4/malloca.m4: Update.
1462 * gnulib/import/m4/math_h.m4: Update.
1463 * gnulib/import/m4/mbrtowc.m4: Update.
1464 * gnulib/import/m4/mbsinit.m4: Update.
1465 * gnulib/import/m4/mbsrtowcs.m4: Update.
1466 * gnulib/import/m4/mbstate_t.m4: Update.
1467 * gnulib/import/m4/memchr.m4: Update.
1468 * gnulib/import/m4/memmem.m4: Update.
1469 * gnulib/import/m4/mempcpy.m4: Update.
1470 * gnulib/import/m4/memrchr.m4: Update.
1471 * gnulib/import/m4/mkdir.m4: Update.
1472 * gnulib/import/m4/mkstemp.m4: Update.
1473 * gnulib/import/m4/mmap-anon.m4: Update.
1474 * gnulib/import/m4/mode_t.m4: Update.
1475 * gnulib/import/m4/msvc-inval.m4: Update.
1476 * gnulib/import/m4/msvc-nothrow.m4: Update.
1477 * gnulib/import/m4/multiarch.m4: Update.
1478 * gnulib/import/m4/nocrash.m4: Update.
1479 * gnulib/import/m4/off_t.m4: Update.
1480 * gnulib/import/m4/onceonly.m4: Update.
1481 * gnulib/import/m4/open-cloexec.m4: Update.
1482 * gnulib/import/m4/open.m4: Update.
1483 * gnulib/import/m4/openat.m4: Update.
1484 * gnulib/import/m4/opendir.m4: Update.
1485 * gnulib/import/m4/pathmax.m4: Update.
1486 * gnulib/import/m4/rawmemchr.m4: Update.
1487 * gnulib/import/m4/readdir.m4: Update.
1488 * gnulib/import/m4/readlink.m4: Update.
1489 * gnulib/import/m4/realloc.m4: Update.
1490 * gnulib/import/m4/rename.m4: Update.
1491 * gnulib/import/m4/rewinddir.m4: Update.
1492 * gnulib/import/m4/rmdir.m4: Update.
1493 * gnulib/import/m4/save-cwd.m4: Update.
1494 * gnulib/import/m4/secure_getenv.m4: Update.
1495 * gnulib/import/m4/setenv.m4: Update.
1496 * gnulib/import/m4/signal_h.m4: Update.
1497 * gnulib/import/m4/ssize_t.m4: Update.
1498 * gnulib/import/m4/stat-time.m4: Update.
1499 * gnulib/import/m4/stat.m4: Update.
1500 * gnulib/import/m4/std-gnu11.m4: Update.
1501 * gnulib/import/m4/stdbool.m4: Update.
1502 * gnulib/import/m4/stddef_h.m4: Update.
1503 * gnulib/import/m4/stdint.m4: Update.
1504 * gnulib/import/m4/stdio_h.m4: Update.
1505 * gnulib/import/m4/stdlib_h.m4: Update.
1506 * gnulib/import/m4/strchrnul.m4: Update.
1507 * gnulib/import/m4/strdup.m4: Update.
1508 * gnulib/import/m4/strerror.m4: Update.
1509 * gnulib/import/m4/string_h.m4: Update.
1510 * gnulib/import/m4/strstr.m4: Update.
1511 * gnulib/import/m4/strtok_r.m4: Update.
1512 * gnulib/import/m4/sys_socket_h.m4: Update.
1513 * gnulib/import/m4/sys_stat_h.m4: Update.
1514 * gnulib/import/m4/sys_time_h.m4: Update.
1515 * gnulib/import/m4/sys_types_h.m4: Update.
1516 * gnulib/import/m4/tempname.m4: Update.
1517 * gnulib/import/m4/time_h.m4: Update.
1518 * gnulib/import/m4/unistd-safer.m4: Update.
1519 * gnulib/import/m4/unistd_h.m4: Update.
1520 * gnulib/import/m4/warn-on-use.m4: Update.
1521 * gnulib/import/m4/wchar_h.m4: Update.
1522 * gnulib/import/m4/wchar_t.m4: Update.
1523 * gnulib/import/m4/wctype_h.m4: Update.
1524 * gnulib/import/m4/wint_t.m4: Update.
1525 * gnulib/import/malloc.c: Update.
1526 * gnulib/import/malloc/scratch_buffer.h: Update.
1527 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
1528 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
1529 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
1530 * gnulib/import/malloca.c: Update.
1531 * gnulib/import/malloca.h: Update.
1532 * gnulib/import/malloca.valgrind: Update.
1533 * gnulib/import/math.in.h: Update.
1534 * gnulib/import/mbrtowc.c: Update.
1535 * gnulib/import/mbsinit.c: Update.
1536 * gnulib/import/mbsrtowcs-impl.h: Update.
1537 * gnulib/import/mbsrtowcs-state.c: Update.
1538 * gnulib/import/mbsrtowcs.c: Update.
1539 * gnulib/import/memchr.c: Update.
1540 * gnulib/import/memmem.c: Update.
1541 * gnulib/import/mempcpy.c: Update.
1542 * gnulib/import/memrchr.c: Update.
1543 * gnulib/import/mkdir.c: Update.
1544 * gnulib/import/mkstemp.c: Update.
1545 * gnulib/import/msvc-inval.c: Update.
1546 * gnulib/import/msvc-inval.h: Update.
1547 * gnulib/import/msvc-nothrow.c: Update.
1548 * gnulib/import/msvc-nothrow.h: Update.
1549 * gnulib/import/open.c: Update.
1550 * gnulib/import/openat-die.c: Update.
1551 * gnulib/import/openat-priv.h: Update.
1552 * gnulib/import/openat-proc.c: Update.
1553 * gnulib/import/openat.c: Update.
1554 * gnulib/import/openat.h: Update.
1555 * gnulib/import/opendir.c: Update.
1556 * gnulib/import/pathmax.h: Update.
1557 * gnulib/import/pipe-safer.c: Update.
1558 * gnulib/import/rawmemchr.c: Update.
1559 * gnulib/import/readdir.c: Update.
1560 * gnulib/import/readlink.c: Update.
1561 * gnulib/import/realloc.c: Update.
1562 * gnulib/import/ref-add.sin: Update.
1563 * gnulib/import/ref-del.sin: Update.
1564 * gnulib/import/rename.c: Update.
1565 * gnulib/import/rewinddir.c: Update.
1566 * gnulib/import/rmdir.c: Update.
1567 * gnulib/import/same-inode.h: Update.
1568 * gnulib/import/save-cwd.c: Update.
1569 * gnulib/import/save-cwd.h: Update.
1570 * gnulib/import/scratch_buffer.h: Update.
1571 * gnulib/import/secure_getenv.c: Update.
1572 * gnulib/import/setenv.c: Update.
1573 * gnulib/import/signal.in.h: Update.
1574 * gnulib/import/stat-time.c: Update.
1575 * gnulib/import/stat-time.h: Update.
1576 * gnulib/import/stat-w32.c: Update.
1577 * gnulib/import/stat-w32.h: Update.
1578 * gnulib/import/stat.c: Update.
1579 * gnulib/import/stdbool.in.h: Update.
1580 * gnulib/import/stddef.in.h: Update.
1581 * gnulib/import/stdint.in.h: Update.
1582 * gnulib/import/stdio.in.h: Update.
1583 * gnulib/import/stdlib.in.h: Update.
1584 * gnulib/import/str-two-way.h: Update.
1585 * gnulib/import/strchrnul.c: Update.
1586 * gnulib/import/strdup.c: Update.
1587 * gnulib/import/streq.h: Update.
1588 * gnulib/import/strerror-override.c: Update.
1589 * gnulib/import/strerror-override.h: Update.
1590 * gnulib/import/strerror.c: Update.
1591 * gnulib/import/string.in.h: Update.
1592 * gnulib/import/stripslash.c: Update.
1593 * gnulib/import/strnlen1.c: Update.
1594 * gnulib/import/strnlen1.h: Update.
1595 * gnulib/import/strstr.c: Update.
1596 * gnulib/import/strtok_r.c: Update.
1597 * gnulib/import/sys_stat.in.h: Update.
1598 * gnulib/import/sys_time.in.h: Update.
1599 * gnulib/import/sys_types.in.h: Update.
1600 * gnulib/import/tempname.c: Update.
1601 * gnulib/import/tempname.h: Update.
1602 * gnulib/import/time.in.h: Update.
1603 * gnulib/import/unistd--.h: Update.
1604 * gnulib/import/unistd-safer.h: Update.
1605 * gnulib/import/unistd.in.h: Update.
1606 * gnulib/import/unsetenv.c: Update.
1607 * gnulib/import/verify.h: Update.
1608 * gnulib/import/extra/snippet/warn-on-use.h: Update.
1609 * gnulib/import/wchar.in.h: Update.
1610 * gnulib/import/wctype.in.h: Update.
1611 * gnulib/import/xalloc-oversized.h: Update.
1612 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
1613 "53e2c179f26a890fa6685af4b6c1397ee370433b".
1614
1615 2018-08-16 Gary Benson <gbenson@redhat.com>
1616
1617 PR gdb/13000:
1618 * gdb/main.c (captured_main_1): Exit with nonzero status
1619 in batch mode if the last command to be executed failed.
1620 * NEWS: Mention the above.
1621
1622 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
1623
1624 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
1625 end of warning message.
1626
1627 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1628
1629 PR gdb/22943:
1630 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
1631 (aarch64_extract_return_value): Use
1632 aapcs_is_vfp_call_or_return_candidate.
1633 (aarch64_return_in_memory): Likewise.
1634 (aarch64_store_return_value): Likewise.
1635
1636 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1637
1638 * aarch64-tdep.c
1639 (aapcs_is_vfp_call_or_return_candidate): Make static
1640 (pass_in_v_or_stack): Remove function.
1641 (pass_in_v_vfp_candidate): New function.
1642 (aarch64_push_dummy_call): Check for float register candidates.
1643
1644 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1645
1646 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
1647 (aapcs_is_vfp_call_or_return_candidate_1): New function.
1648 (aapcs_is_vfp_call_or_return_candidate): Likewise.
1649
1650 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
1651
1652 PR build/23399
1653 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
1654 (struct ipa_sym_addresses): Rename to...
1655 (struct ipa_sym_addresses_common): ... this.
1656 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
1657
1658 2018-08-28 Tom Tromey <tom@tromey.com>
1659
1660 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1661 (token_fifo): Now a std::vector.
1662 (yylex, c_parse): Update.
1663 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1664 (token_fifo): Now a std::vector.
1665 (yylex, d_parse): Update.
1666 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1667 (token_fifo): Now a std::vector.
1668 (yylex, go_parse): Update.
1669
1670 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
1671
1672 * parser-defs.h (struct type_stack) <elements>: Change type to
1673 std::vector<union type_stack_elt>.
1674 <depth, size>: Remove.
1675 * parse.c (parse_exp_in_context_1): Adjust.
1676 (type_stack_reserve): Remove.
1677 (check_type_stack_depth): Remove.
1678 (insert_into_type_stack): Adjust to std::vector.
1679 (insert_type): Likewise.
1680 (push_type): Likewise.
1681 (push_type_int): Likewise.
1682 (insert_type_address_space): Likewise.
1683 (pop_type): Likewise.
1684 (pop_type_int): Likewise.
1685 (pop_typelist): Likewise.
1686 (pop_type_stack): Likewise.
1687 (append_type_stack): Likewise.
1688 (push_type_stack): Likewise.
1689 (get_type_stack): Likewise.
1690 (type_stack_cleanup): Likewise.
1691 (push_typelist): Likewise.
1692 (follow_types): Likewise.
1693 (_initialize_parse): Likewise.
1694
1695 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
1696
1697 * NEWS: Mention csky target.
1698
1699 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
1700 Hafiz Abid Qadeer <abidh@codesourcery.com>
1701 Don Breazeal <donb@codesourcery.com>
1702
1703 * csky-linux-tdep.c: New file.
1704 * csky-tdep.c: Likewise.
1705 * csky-tdep.h: Likewise.
1706 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
1707 csky-tdep.o.
1708 (HFILES_NO_SRCDIR): Add csky-tdep.h.
1709 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
1710 * configure.tgt: Add csky support.
1711
1712 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
1713
1714 * python/py-framefilter.c (py_print_frame): Print frame architecture
1715 when printing on an MI output.
1716
1717 2018-08-27 Tom Tromey <tom@tromey.com>
1718
1719 PR build/23087:
1720 * configure: Rebuild.
1721 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
1722
1723 2018-08-27 Tom Tromey <tom@tromey.com>
1724
1725 * aarch64-linux-tdep.c
1726 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
1727 casts to int.
1728
1729 2018-08-27 Tom Tromey <tom@tromey.com>
1730
1731 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
1732 unsigned.
1733 (ppc64_standard_linkage1, ppc64_standard_linkage2)
1734 (ppc64_standard_linkage3, ppc64_standard_linkage4)
1735 (ppc64_standard_linkage5, ppc64_standard_linkage6)
1736 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
1737 unsigned.
1738
1739 2018-08-27 Tom Tromey <tom@tromey.com>
1740
1741 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
1742 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
1743
1744 2018-08-27 Tom Tromey <tom@tromey.com>
1745
1746 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
1747 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
1748 ULONGEST_MAX.
1749 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
1750 ULONGEST_MAX.
1751 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
1752 ULONGEST_MAX.
1753 * sparc-linux-tdep.c (sparc32_linux_sigframe)
1754 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
1755 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
1756 ULONGEST_MAX.
1757 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
1758 (ppc64_linux_sigaction_tramp_frame)
1759 (ppc32_linux_sighandler_tramp_frame)
1760 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1761 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
1762 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
1763 * mn10300-linux-tdep.c (am33_linux_sigframe)
1764 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
1765 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
1766 * mips-linux-tdep.c (mips_linux_o32_sigframe)
1767 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
1768 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
1769 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
1770 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
1771 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
1772 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
1773 * microblaze-linux-tdep.c
1774 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1775 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
1776 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
1777 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
1778 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
1779 * common/common-types.h (ULONGEST_MAX): New define.
1780 (CORE_ADDR_MAX): Fix formatting.
1781 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
1782 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
1783 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
1784 (arm_linux_rt_sigreturn_tramp_frame)
1785 (arm_eabi_linux_sigreturn_tramp_frame)
1786 (arm_eabi_linux_rt_sigreturn_tramp_frame)
1787 (thumb2_eabi_linux_sigreturn_tramp_frame)
1788 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
1789 (arm_linux_restart_syscall_tramp_frame)
1790 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
1791 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
1792 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
1793 ULONGEST_MAX.
1794 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
1795
1796 2018-08-27 Tom Tromey <tom@tromey.com>
1797
1798 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
1799 CORE_ADDR_MAX.
1800 * mips-tdep.c (mips_deal_with_atomic_sequence)
1801 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
1802 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
1803 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
1804 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
1805 CORE_ADDR_MAX.
1806 * aarch64-tdep.c (aarch64_software_single_step): Use
1807 CORE_ADDR_MAX.
1808
1809 2018-08-27 Tom Tromey <tom@tromey.com>
1810
1811 * linespec.c (complete_linespec_component): Add cast to "char".
1812 * completer.c (completion_tracker::build_completion_result): Add
1813 cast to "char".
1814
1815 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1816
1817 * solist.h (struct solist, struct target_so_ops): Fix
1818 indentation.
1819
1820 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1821
1822 * ada-tasks.c (ada_task_info_s): Remove typedef.
1823 (DEF_VEC_O(ada_task_info_s)): Remove.
1824 (struct ada_tasks_inferior_data): Initialize fields.
1825 <task_list>: Make an std::vector.
1826 (get_ada_tasks_inferior_data): Allocate with new.
1827 (ada_get_task_number): Adjust.
1828 (get_task_number_from_id): Likewise.
1829 (valid_task_id): Likewise.
1830 (ada_get_task_info_from_ptid): Likewise.
1831 (iterate_over_live_ada_tasks): Likewise.
1832 (add_ada_task): Likewise.
1833 (read_known_tasks): Likewise.
1834 (ada_build_task_list): Likewise.
1835 (print_ada_task_info): Likewise.
1836 (info_task): Likewise.
1837 (task_command_1): Likewise.
1838
1839 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1840
1841 * ada-lang.c (add_angle_brackets): Return std::string.
1842
1843 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
1844
1845 * python/py-threadevent.c (py_get_event_thread): Initialize
1846 pythread.
1847
1848 2018-08-24 Pedro Alves <palves@redhat.com>
1849
1850 * python/py-bpevent.c (create_breakpoint_event_object): Use
1851 copy-initialization.
1852 * python/py-continueevent.c (emit_continue_event): Use
1853 copy-initialization.
1854 * python/py-exitedevent.c (create_exited_event_object): Return a
1855 gdbpy_ref<>.
1856 (emit_exited_event): Use copy-initialization.
1857 * python/py-inferior.c (python_new_inferior)
1858 (python_inferior_deleted, add_thread_object): Use
1859 copy-initialization.
1860 * python/py-infevents.c (create_inferior_call_event_object)
1861 (create_register_changed_event_object)
1862 (create_memory_changed_event_object): Return a gdbpy_ref<>.
1863 (emit_inferior_call_event, emit_memory_changed_event)
1864 (emit_register_changed_event): Use copy-initialization.
1865 * python/py-newobjfileevent.c (create_new_objfile_event_object):
1866 Return a gdbpy_ref<>.
1867 (emit_new_objfile_event): Use copy-initialization.
1868 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
1869 (emit_clear_objfiles_event): Use copy-initialization.
1870 * python/py-signalevent.c (create_signal_event_object): Use
1871 copy-initialization.
1872 * python/py-threadevent.c (create_thread_event_object): Use
1873 copy-initialization.
1874
1875 2018-08-24 Pedro Alves <palves@redhat.com>
1876 Simon Marchi <simon.marchi@ericsson.com>
1877
1878 PR gdb/23379
1879 * python/py-continueevent.c: Include "gdbthread.h".
1880 (create_continue_event_object): Add intro comment. Add 'ptid'
1881 parameter. Use it to find thread to pass to
1882 create_thread_event_object.
1883 (emit_continue_event): Pass PTID down to
1884 create_continue_event_object.
1885 * python/py-event.h (py_get_event_thread): Declare.
1886 (create_thread_event_object): Remove default from 'thread'
1887 parameter.
1888 * python/py-stopevent.c (create_stop_event_object): Use
1889 py_get_event_thread.
1890 * python/py-threadevent.c (get_event_thread): Rename to ...
1891 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
1892 and use it to find the thread.
1893 (create_thread_event_object): Assert that THREAD isn't null.
1894 Don't find the event thread here.
1895
1896 2018-08-23 Kevin Buettner <kevinb@redhat.com>
1897
1898 * block.h (blockrange, blockranges): New struct declarations.
1899 (struct block): Add new field named `ranges'.
1900 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
1901 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
1902 macros for accessing ranges in struct block.
1903 (make_blockranges): New declaration.
1904 block.c (make_blockranges): New function.
1905 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
1906 for block.
1907 * symtab.h (find_pc_partial_function): Add new parameter `block'.
1908 * blockframe.c (cache_pc_function_block): New static global.
1909 (clear_pc_function_cache): Clear cache_pc_function_block.
1910 (find_pc_partial_function): Move comment to symtab.h. Add
1911 support for non-contiguous blocks.
1912 * cli/cli-cmds.c (block.h): Include.
1913 (print_disassembly): Handle printing of non-contiguous blocks.
1914 (disassemble_current_function): Likewise.
1915 (disassemble_command): Likewise.
1916
1917 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
1918 BLOCK_START.
1919 * blockframe.c (get_pc_function_start): Likewise.
1920 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
1921 (gcc_symbol_address): Likewise.
1922 * compile/compile-object-run.c (compile_object_run): Likewise.
1923 * compile/compile.c (get_expr_block_and_pc): Likewise.
1924 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
1925 (func_addr_to_tail_call_list): Likewise.
1926 * findvar.c (default_read_var_value): Likewise.
1927 * inline-frame.c (inline_frame_this_id): Likewise.
1928 (skip-inline_frames): Likewise.
1929 * infcmd.c (until_next_command): Likewise.
1930 * linespec.c (convert_linespec_to_sals): Likewise.
1931 * parse.c (parse_exp_in_context_1): Likewise.
1932 * printcmd.c (build_address_symbolic): likewise.
1933 (info_address_command): Likewise.
1934 symtab.c (find_function_start_sal): Likewise.
1935 (skip_prologue_sal): Likewise.
1936 (find_function_alias_target): Likewise.
1937 (find_gnu_ifunc): Likewise.
1938 * stack.c (find_frame_funname): Likewise.
1939 * symtab.c (fixup_symbol_section): Likewise.
1940 (find_function_start_sal): Likewise.
1941 (skip_prologue_sal): Likewsie.
1942 (find_function_alias_target): Likewise.
1943 (find_gnu_ifunc): Likewise.
1944 * tracepoint.c (info_scope_command): Likewise.
1945 * value.c (value_fn_field): Likewise.
1946
1947 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
1948 in place of find_pc_partial_function.
1949 * blockframe.c (find_function_entry_range_from_pc): New function.
1950 * symtab.h (find_function_entry_range_from_pc): Declare and document.
1951 * objfiles.c (objfile_relocate1): Relocate start and end addresses
1952 for each range in a block.
1953
1954
1955 2018-08-23 Xavier Roirand <roirand@adacore.com>
1956
1957 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
1958 incrementation.
1959
1960 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1961
1962 * solib-svr4.c (read_program_headers_from_bfd): Return
1963 gdb::optional<gdb::byte_vector>.
1964 (svr4_exec_displacement): Adjust.
1965
1966 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1967
1968 * solib-svr4.c (read_program_header): Return
1969 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
1970 (find_program_interpreter): Return
1971 gdb::optional<gdb::byte_vector>.
1972 (scan_dyntag_auxv): Adjust.
1973 (enable_break): Adjust.
1974 (svr4_exec_displacement): Adjust.
1975
1976 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1977
1978 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
1979 * inf-child.c (inf_child_target::terminal_save_inferior): New.
1980
1981 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1982
1983 * guile/scm-string.c (gdbscm_scm_from_printf): Use
1984 string_vprintf.
1985 * guile/scm-utils.c (gdbscm_printf): Likewise.
1986 * serial.c (serial_printf): Likewise.
1987 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
1988
1989 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
1990
1991 * stack.c (print_frame): Print frame architecture when printing on
1992 an MI output.
1993 * NEWS: Mention new "arch" attribute in frame output.
1994
1995 2018-08-21 Alan Hayward <alan.hayward@arm.com>
1996
1997 * arch/aarch64.h (aarch64_regnum): Update comment.
1998
1999 2018-08-21 Alan Hayward <alan.hayward@arm.com>
2000
2001 * NEWS: Add SVE to 8.2 section.
2002
2003 2018-08-21 Pedro Alves <palves@redhat.com>
2004
2005 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
2006 out from gdbscm_parse_function_args.
2007 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
2008 gdbscm_parse_function_args_1.
2009
2010 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
2011
2012 PR gdb/17816
2013 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
2014 operator.
2015
2016 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
2017
2018 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
2019
2020 2018-08-19 Michael Spang <spang@google.com>
2021
2022 PR gdb/11786
2023 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
2024 for PT_TLS segments.
2025
2026 2018-08-18 Kevin Buettner <kevinb@redhat.com>
2027
2028 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
2029 dwarf_variable_value.
2030 * dwarf2-frame.c (class dwarf_expr_executor):
2031 Add override for dwarf_variable_value.
2032 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
2033 (class symbol_needs_eval_context): Likewise.
2034 (indirect_synthetic_pointer): Add forward declaration.
2035 (sect_variable_value): New function.
2036 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
2037 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
2038 for DW_OP_GNU_variable_value.
2039
2040 2018-08-16 Tom Tromey <tom@tromey.com>
2041
2042 * top.c (read_command_file): Update.
2043 (command_line_input): Remove "repeat" argument.
2044 * ada-lang.c (get_selections): Update.
2045 * linespec.c (decode_line_2): Update.
2046 * defs.h (command_line_input): Remove argument.
2047 * cli/cli-script.c (read_next_line): Update.
2048 * python/py-gdb-readline.c: Update.
2049
2050 2018-08-17 Tom Tromey <tom@tromey.com>
2051
2052 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
2053 command_line_input.
2054
2055 2018-08-15 Tom Tromey <tom@tromey.com>
2056
2057 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
2058
2059 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
2060
2061 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
2062 If used, use find_pc_partial_function to find address range
2063 to disassemble.
2064 * mi/mi-main.c (mi_cmd_list_features): Report
2065 "data-disassemble-a-option" feature.
2066 * NEWS: Mention new -data-disassemble option -a.
2067
2068 2018-08-13 Tom Tromey <tom@tromey.com>
2069
2070 * common/common-defs.h (_FORTIFY_SOURCE): Define.
2071
2072 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2073
2074 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
2075 (aarch64_linux_collect_sve_regset): Likewise.
2076 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
2077 * regcache.h (regcache_map_entry_size): New function.
2078
2079 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2080
2081 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
2082 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
2083 (SVE_HEADER_VL_LENGTH): Likewise.
2084 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
2085 (SVE_HEADER_FLAGS_LENGTH): Likewise.
2086 (SVE_HEADER_RESERVED_LENGTH): Likewise.
2087 (SVE_HEADER_SIZE_OFFSET): Likewise.
2088 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
2089 (SVE_HEADER_VL_OFFSET): Likewise.
2090 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
2091 (SVE_HEADER_FLAGS_OFFSET): Likewise.
2092 (SVE_HEADER_RESERVED_OFFSET): Likewise.
2093 (SVE_HEADER_SIZE): Likewise.
2094 (aarch64_linux_core_read_vq): Add function.
2095 (aarch64_linux_core_read_description): Check for SVE section.
2096
2097 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2098
2099 * aarch64-fbsd-tdep.c
2100 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
2101 collect_size.
2102 * aarch64-linux-tdep.c
2103 (aarch64_linux_iterate_over_regset_sections): Likewise.
2104 * alpha-linux-tdep.c
2105 (alpha_linux_iterate_over_regset_sections):
2106 * alpha-nbsd-tdep.c
2107 (alphanbsd_iterate_over_regset_sections): Likewise.
2108 * amd64-fbsd-tdep.c
2109 (amd64fbsd_iterate_over_regset_sections): Likewise.
2110 * amd64-linux-tdep.c
2111 (amd64_linux_iterate_over_regset_sections): Likewise.
2112 * arm-bsd-tdep.c
2113 (armbsd_iterate_over_regset_sections): Likewise.
2114 * arm-fbsd-tdep.c
2115 (arm_fbsd_iterate_over_regset_sections): Likewise.
2116 * arm-linux-tdep.c
2117 (arm_linux_iterate_over_regset_sections): Likewise.
2118 * corelow.c (get_core_registers_cb): Likewise.
2119 (core_target::fetch_registers): Likewise.
2120 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
2121 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
2122 * gdbarch.h (void): Regenerate.
2123 * gdbarch.sh: Add supply_size and collect_size.
2124 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
2125 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
2126 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
2127 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
2128 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
2129 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
2130 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
2131 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
2132 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
2133 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
2134 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
2135 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
2136 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
2137 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
2138 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
2139 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
2140 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
2141 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
2142 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
2143 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
2144 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
2145 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
2146 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
2147 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
2148 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
2149 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
2150 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
2151 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
2152 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
2153 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
2154
2155 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
2156
2157 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
2158 with string_printf.
2159
2160 2018-08-10 Keith Seitz <keiths@redhat.com>
2161
2162 * compile/compile-c-support.c (add_code_header, add_code_footer):
2163 Move into policy class.
2164 (c_push_user_expression, pop_user_expression_nop)
2165 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
2166 (compile_program): New host class.
2167 (c_compile_program): New typedef.
2168 (c_compute_porgram): Use c_compile_program.
2169
2170 2018-08-10 Keith Seitz <keiths@redhat.com>
2171
2172 * compile/compile-internal.h (compile_instance::~compile_instance):
2173 Remove calls to htab_delete.
2174 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
2175 * compile.c (compile_instance::compile_instance): Initialize
2176 htab unique pointers.
2177 (compile_instance::get_cached_type, compile_instance::insert_type)
2178 (compile_instance::error_symbol_once): Update for unique_ptr.
2179
2180 2018-08-10 Keith Seitz <keiths@redhat.com>
2181
2182 * compile/compile-c-symbols.c (struct symbol_error)
2183 (hash_symbol_error, eq_symbol_error, del_symbol_error)
2184 (compile_instance::insert_symbol_error)
2185 (compile_instance::error_symbol_once): Move to ...
2186 * compile/compile.c: ... here.
2187
2188 2018-08-10 Keith Seitz <keiths@redhat.com>
2189
2190 * compile/compile-c-support.c (c_get_compile_context): Use `new'
2191 instead of `new_compile_instance'.
2192 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
2193 Update description.
2194 If the symbol error map is not initialized, create it.
2195 (generate_c_for_for_one_symbol): Do not check/initialize
2196 the symbol error map.
2197 * compile/compile-c-types.c (compile_c_instance): Make a class.
2198 Update all callers.
2199 (compile_instance::compile_instance): Initialize the type cache.
2200 (get_cached_type): New function.
2201 (insert_type): Update description.
2202 (compile_c_instance::m_default_cflags): Define.
2203 (convert_type): Update description. Use get_cached_type.
2204 (delete_instance): Moved to destructor.
2205 (new_compile_instance): Moved to constructor.
2206 * compile/compile-c.h (compile_c_instance): Make class inheriting
2207 from compile_instance.
2208 <base>: Remove field.
2209 <type_map, symbol_err_map>: Move to base class.
2210 <c_plugin>: Rename to `m_plugin' and remove pointer type.
2211 * compile/compile-internal.h (compile_instance): Make class.
2212 <type_map_t, symbol_err_map_t>: Define.
2213 <fe>: Rename to `m_gcc_fe'.
2214 <scope, block, gcc_target_options>: Add `m_' prefix.
2215 <m_type_map, m_symbol_err_map>: New fields, moved from
2216 compile_c_instance.
2217 <destroy>: Remove.
2218 (convert_type, new_compile_instance): Remove.
2219 * compile/compile.c (cleanup_compile_instance): Remove.
2220 (compile_to_object): Use unique_ptr to eliminate cleanups.
2221 (compile_instance::set_print_callback, compile_instance::version)
2222 (compile_instance::set_verbose)
2223 (compile_instance::set_driver_filename)
2224 (compile_instance::set_triplet_regexp)
2225 (compile_instance::set_arguments)
2226 (compile_instance::set_source_file)
2227 (compile_instance::compile): Define.
2228
2229 2018-08-10 Keith Seitz <keiths@redhat.com>
2230
2231 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
2232 * compile/compile-c-types.c: Define GCC_METHODN macros and include
2233 gcc-c-fe.def to define C plugin.
2234 (delete_instance): Delete `c_plugin'.
2235 (new_compile_instance): Initialize `c_plugin'.
2236 * compile/compile-c.h: Include gcc_c_plugin.h.
2237 (struct compile_c_instance) <c_plugin>: New member.
2238 * gcc-c-plugin.h: New file.
2239 Update all callers with API change.
2240
2241 2018-08-10 Keith Seitz <keiths@redhat.com>
2242
2243 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
2244 (HFILES_NO_SRCDIR): ... to here.
2245 Add compile-internal.h and compile-c.h.
2246 * compile/compile-c-support.c: Include compile-c.h.
2247 * compile/compile-c-symbols.c: Include compile-c.h.
2248 (generate_c_for_variable_locations): Update comment.
2249 * compile/compile-c-types.c: Include compile-c.h.
2250 * compile/compile-c.h: New file -- moved C language declarations
2251 from other files here.
2252 * compile/compile-internal.h: Do not include hashtab.h or
2253 common/enum-flags.h.
2254 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
2255 (gcc_convert_symbol, gcc_symbol_address)
2256 (generate_c_for_variable_locations, c_get_mode_for_size)
2257 (c_get_range_decl_name): Definitions moved to compile-c.h.
2258 * compile/compile-loc2c.c: Include compile-c.h.
2259
2260 2018-08-10 Keith Seitz <keiths@redhat.com>
2261
2262 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
2263 (c_symbol_substitution_name): ... this.
2264 Update all callers.
2265
2266 2018-08-10 Keith Seitz <keiths@redhat.com>
2267
2268 * compile/compile-c-support.c (c_compute_program): Use
2269 unique_xmalloc_ptr to eliminate cleanup.
2270 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
2271 Return a unique_xmalloc_ptr and eliminate cleanup.
2272 * compile/compile-internal.h (generate_c_for_variable_locations):
2273 Return unique_xmalloc_ptr and update description.
2274
2275 2018-08-10 Alan Hayward <alan.hayward@arm.com>
2276
2277 * corelow.c (core_target::get_core_register_section): Rename
2278 min_size to section_min_size.
2279
2280 2018-08-09 Jim Wilson <jimw@sifive.com>
2281
2282 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
2283 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
2284 * NEWS: Mention new GNU/Linux RISC-V target.
2285 * configure.host: Add riscv*-*-linux*.
2286 * configure.nat: Add riscv*.
2287 * configure.tgt: Add riscv*-*-linux*.
2288 * riscv-linux-nat.c: New file.
2289 * riscv-linux-tdep.c: New file.
2290
2291 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2292
2293 * infrun.c (resume): Make static, add forward declaration.
2294 (proceed): Update header comment.
2295 * infrun.h (resume): Delete declaration.
2296
2297 2018-08-09 Tom Tromey <tom@tromey.com>
2298
2299 * riscv-tdep.h: Minor formatting fixes.
2300
2301 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
2302
2303 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
2304 * dwarf-index-cache.c (create_dir_and_check): Likewise.
2305 (test_mkdir_recursive): Likewise.
2306 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
2307
2308 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2309
2310 * valarith.c (value_subscripted_rvalue): If an array is not in
2311 memory, and we don't know the upper bound, then we can't know that
2312 the requested element exists or not.
2313
2314 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
2315
2316 * target.c (str_comma_list_concat_elem): Fix typo in comment.
2317 (target_options_to_string): Add comment.
2318
2319 2018-08-08 Tom Tromey <tom@tromey.com>
2320
2321 * unittests/scoped_mmap-selftests.c: Check result of "write".
2322
2323 2018-08-08 Jim Wilson <jimw@sifive.com>
2324
2325 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
2326 (decode_register_index_short): New.
2327 (decode_j_type_insn, decode_cj_type_insn): New.
2328 (decode_b_type_insn, decode_cb_type_insn): New.
2329 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
2330 local xlen. Check xlen when decoding ambiguous compressed insns. In
2331 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
2332 is_c_sw_insn instead of is_sw_insn.
2333 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
2334 (riscv_software_single_step): New.
2335 * riscv-tdep.h (riscv_software_single_step): Declare.
2336
2337 * riscv-tdep.c (riscv_isa_xlen): Drop static.
2338 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
2339
2340 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
2341
2342 PR gdb/18050:
2343 * target.c (dispose_inferior): Don't dispose of inferiors that are
2344 already killed.
2345
2346 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
2347
2348 * remote.c (remote_target::download_tracepoint): Change char* to
2349 const char*.
2350
2351 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
2352
2353 * target.h (target_options_to_string): Return an std::string.
2354 * target.c (str_comma_list_concat_elem): Return void, use
2355 std::string.
2356 (do_option): Likewise.
2357 (target_options_to_string): Return an std::string.
2358 * linux-nat.c (linux_nat_target::wait): Adjust.
2359 * target-debug.h (target_debug_print_options): Adjust.
2360
2361 2018-08-07 Tom Tromey <tom@tromey.com>
2362
2363 * Makefile.in (CPPFLAGS): New variable.
2364 (INTERNAL_CPPFLAGS): Use it.
2365
2366 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2367
2368 * NEWS: Mention the index cache.
2369
2370 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2371
2372 * common/pathstuff.h (get_standard_cache_dir): New.
2373 * common/pathstuff.c (get_standard_cache_dir): New.
2374 * build-id.h (build_id_to_string): New.
2375 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
2376 DEBUG_STR_SUFFIX): Move to here.
2377 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
2378 DEBUG_STR_SUFFIX): Move from there.
2379 (write_psymtabs_to_index): Make non-static, add basename
2380 parameter. Write to temporary files, rename when done.
2381 (save_gdb_index_command): Adjust call to
2382 write_psymtabs_to_index.
2383 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
2384 field.
2385 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
2386 (get_gdb_index_contents_from_cache): New.
2387 (get_gdb_index_contents_from_cache_dwz): New.
2388 (dwarf2_initialize_objfile): Read index from cache.
2389 (dwarf2_build_psymtabs): Save to index.
2390 * dwarf-index-cache.h: New file.
2391 * dwarf-index-cache.c: New file.
2392 * dwarf-index-write.h: New file.
2393
2394 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2395
2396 * gnulib/aclocal.m4: Re-generate.
2397 * gnulib/config.in: Re-generate.
2398 * gnulib/configure: Re-generate.
2399 * gnulib/import/Makefile.am: Re-generate.
2400 * gnulib/import/Makefile.in: Re-generate.
2401 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
2402 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2403 * gnulib/import/m4/mkdir.m4: New file.
2404 * gnulib/import/mkdir.c: New file.
2405 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
2406 module.
2407
2408 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2409
2410 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
2411 * common/scoped_mmap.c: New file.
2412 * common/scoped_mmap.h (destroy): New method.
2413 (~scoped_mmap, reset): Use destroy.
2414 (scoped_mmap): New move constructor.
2415 (mmap_file): New declaration.
2416 * unittests/scoped_mmap-selftests.c (test_normal,
2417 test_invalid_filename, run_tests): New functions.
2418 (_initialize_scoped_mmap_selftests): Register selftest.
2419
2420 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2421
2422 * dwarf2read.c (read_gdb_index_from_section): Rename to...
2423 (read_gdb_index_from_buffer): ... this. Remove section
2424 parameter, add buffer parameter.
2425 (get_gdb_index_contents_ftype,
2426 get_gdb_index_contents_dwz_ftype): New typedefs.
2427 (dwarf2_read_gdb_index): Add callback parameters to get the
2428 index contents.
2429 (get_gdb_index_contents_from_section): New.
2430 (dwarf2_initialize_objfile): Update call to
2431 dwarf2_read_gdb_index.
2432
2433 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2434
2435 * common/filestuff.h (gdb_fopen_cloexec): New overload.
2436 (gdb_open_cloexec): Likewise.
2437 * nat/linux-osdata.c (command_from_pid): Use string_printf.
2438 (commandline_from_pid): Likewise.
2439 (linux_xfer_osdata_threads): Likewise.
2440 (linux_xfer_osdata_fds): Likewise.
2441 * ada-lang.c (is_package_name): Likewise.
2442 * auxv.c (procfs_xfer_auxv): Likewise.
2443 * breakpoint.c (print_one_breakpoint_location): Use
2444 uiout::field_fmt.
2445 (print_one_catch_solib): Use string_printf.
2446 * coff-pe-read.c (add_pe_exported_sym): Likewise.
2447 (add_pe_forwarded_sym): Likewise.
2448 * dwarf2read.c (create_type_unit_group): Likewise.
2449 (build_error_marker_type): Likewise.
2450 * infcall.c (get_function_name): Likewise.
2451 * valprint.c (print_converted_chars_to_obstack): Likewise.
2452 * xtensa-tdep.c (xtensa_register_type): Likewise.
2453
2454 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
2455
2456 * remote.c (remote_target::download_tracepoint): Fix format
2457 string errors.
2458
2459 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2460
2461 * tracefile.c: Include common/byte-vector.h.
2462 (trace_save): Change type of buf to gdb::byte_vector. Initialize
2463 with trace_regblock_size if needed. Update uses of buf.
2464
2465 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2466
2467 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
2468 std::vector<unsigned char>.
2469 * tracepoint.c (collection_list::collection_list): Remove
2470 m_regs_mask initializer from initializer list. Resize
2471 m_regs_mask using the largest remote register number.
2472 (collection_list::add_remote_register): Remove size check on
2473 m_regs_mask. Use at to access element.
2474 (collection_list::stringify): Change type of temp_buf to
2475 gdb::char_vector. Update uses of temp_buf. Resize if needed to
2476 stringify the register mask. Use pack_hex_byte for the register
2477 mask.
2478
2479 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2480
2481 * tracepoint.h (class collection_list) <add_register>: Remove.
2482 <add_remote_register, add_ax_registers, add_local_register>:
2483 Declare.
2484 <add_memrange>: Add scope parameter.
2485 * tracepoint.c (encode_actions_1): Likewise.
2486 (collection_list::add_register): Rename to ...
2487 (collection_list::add_remote_register): ... this. Update
2488 comment.
2489 (collection_list::add_ax_registers, add_local_register): New
2490 methods.
2491 (collection_list::add_memrange): Add scope parameter. Call
2492 add_local_register instead of add_register.
2493 (finalize_tracepoint_aexpr): New function.
2494 (collection_list::collect_symbol): Update calls to add_memrange.
2495 Call add_local_register instead of add_register. Call
2496 add_ax_registers. Call finalize_tracepoint_aexpr.
2497 (encode_actions_1): Get remote regnos for $reg action. Call
2498 add_remote_register, add_ax_registers, and add_local_register.
2499 Update call to add_memrange. Call finalize_tracepoint_aexpr.
2500 (validate_actionline): Call finalize_tracepoint_aexpr.
2501
2502 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2503
2504 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
2505 Replace array buf with gdb::char_vector buf, of size
2506 get_remote_packet_size (). Replace references to buf and
2507 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
2508 and xsnprintf with snprintf. Raise errors if the buffer is too
2509 small.
2510
2511 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2512
2513 * remote.c (remote_target::download_tracepoint): Fix the has_more
2514 predicate in the QTDP action list iteration.
2515
2516 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2517
2518 * remote.c (remote_target::download_tracepoint): Fix indentation
2519 in for block.
2520
2521 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2522
2523 * proc-api.c (_initialize_proc_api): Remove c, unused.
2524 * procfs.c (procfs_init_inferior): Remove signals, unused.
2525 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
2526 unused.
2527
2528 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
2529 Andrew Burgess <andrew.burgess@embecosm.com>
2530
2531 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
2532 'W_STOPCODE (0)' as this could be ambiguous.
2533
2534 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
2535
2536 * ser-tcp.c (net_open): Fix thinko when deciding whether to
2537 disable TCP's Nagle algorithm (use "ai_protocol" instead of
2538 "ai_socktype").
2539
2540 2018-08-02 Tom Tromey <tom@tromey.com>
2541
2542 PR symtab/16842.
2543 * dwarf2read.c (read_func_scope): Set symtab on template parameter
2544 symbols.
2545 (process_structure_scope): Likewise.
2546
2547 2018-08-02 Xavier Roirand <roirand@adacore.com>
2548
2549 PR gdb/22629:
2550 * darwin-nat.c (darwin_kill_inferior): Fix handling of
2551 kill inferior.
2552
2553 2018-08-02 Tom Tromey <tom@tromey.com>
2554
2555 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
2556 (darwin_suspend_inferior, darwin_resume_inferior)
2557 (darwin_decode_notify_message, darwin_resume_inferior_threads)
2558 (darwin_check_new_threads): Check result of get_darwin_inferior.
2559
2560 2018-07-31 Joel Brobecker <brobecker@adacore.com>
2561
2562 GDB 8.1.1 released.
2563
2564 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
2565
2566 * varobj.c (varobj_get_path_expr_parent): Report an error if
2567 parent is a dynamic varobj.
2568
2569 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2570
2571 * gnulib/aclocal.m4: Re-generate.
2572 * gnulib/config.in: Re-generate.
2573 * gnulib/configure: Re-generate.
2574 * gnulib/import/Makefile.in: Re-generate.
2575 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2576 * gnulib/import/m4/onceonly.m4: Re-generate.
2577
2578 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2579
2580 * target-descriptions.c (struct xml_test_tdesc): New.
2581 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
2582 (record_xml_tdesc): Update.
2583 (maintenance_check_xml_descriptions): Update.
2584 * target-descriptions.h (record_xml_tdesc): Update comment.
2585
2586 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
2587
2588 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
2589 checking array bounds are defined.
2590
2591 2018-07-30 Tom Tromey <tom@tromey.com>
2592
2593 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
2594 irreflexivity violation.
2595
2596 2018-07-30 Tom Tromey <tom@tromey.com>
2597
2598 * cli/cli-decode.c (lookup_cmd): Remove lint code.
2599 * value.c (unpack_long): Remove lint code.
2600 * valops.c (value_ind): Remove lint code.
2601 * valarith.c (value_x_binop, value_x_unop, value_equal)
2602 (value_pos): Remove lint code.
2603
2604 2018-07-28 Tom de Vries <tdevries@suse.de>
2605
2606 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
2607 with undefined upper bound as <optimized out>.
2608
2609 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
2610
2611 * gcore.in: Rename variable "name" to "prefix". Expand
2612 "usage" text.
2613
2614 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
2615
2616 * windows-nat.c (windows_nat_target::create_inferior): Update to
2617 call close() in global namespace.
2618
2619 2018-07-26 Tom Tromey <tom@tromey.com>
2620
2621 * dwarf-index-write.c (add_address_entry): Don't add objfile
2622 offsets.
2623 * dbxread.c (find_stab_function): Rename from
2624 find_stab_function_addr. Return a bound_minimal_symbol.
2625 (read_dbx_symtab): Use raw_text_low, raw_text_high.
2626 Don't add objfile offsets.
2627 (end_psymtab): Use raw_text_low, raw_text_high,
2628 MSYMBOL_VALUE_RAW_ADDRESS.
2629 (read_ofile_symtab): Update.
2630 (process_one_symbol): Update.
2631 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
2632 offsets.
2633 (dw2_relocate): Remove.
2634 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
2635 searching addrmap.
2636 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
2637 Update.
2638 (process_psymtab_comp_unit_reader, add_partial_symbol)
2639 (add_partial_subprogram, dwarf2_ranges_read): Update.
2640 (load_partial_dies): Update.
2641 (add_address_entry): Don't add objfile offsets.
2642 (dwarf2_build_include_psymtabs): Update.
2643 (create_addrmap_from_aranges): Don't add objfile offsets.
2644 (dw2_find_pc_sect_compunit_symtab): Update.
2645 * mdebugread.c (parse_symbol): Don't add objfile offsets.
2646 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
2647 Update.
2648 (parse_partial_symbols): Don't add objfile offsets. Use
2649 raw_text_low, raw_text_high. Update.
2650 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
2651 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
2652 or call 'relocate' quick function. Clear psymbol_map.
2653 * psympriv.h (struct partial_symbol) <address>: Add section
2654 offset.
2655 <set_unrelocated_address>: Rename from set_address.
2656 <raw_text_low, raw_text_high>: New methods.
2657 <text_low, text_high>: Add objfile parameter.
2658 (add_psymbol_to_bcache): Add 'section' parameter. Call
2659 set_unrelocated_address.
2660 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2661 (find_pc_psymbol): Update.
2662 (fixup_psymbol_section, relocate_psymtabs): Remove.
2663 (dump_psymtab, psym_functions): Update.
2664 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
2665 parameter.
2666 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
2667 (start_psymtab_common): Update.
2668 * symfile-debug.c (debug_qf_relocate): Remove.
2669 (debug_sym_quick_functions): Update.
2670 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
2671 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
2672 Update.
2673
2674 2018-07-26 Tom Tromey <tromey@redhat.com>
2675
2676 * dbxread.c (end_psymtab): Use text_high_valid and
2677 text_low_valid.
2678 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
2679 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
2680 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2681 Update comment.
2682 <text_low_valid, text_high_valid>: New fields.
2683 <set_text_low, set_text_high>: Update.
2684 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
2685
2686 2018-07-26 Tom Tromey <tom@tromey.com>
2687
2688 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
2689 Update.
2690 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
2691 textlow and texthigh fields.
2692 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
2693 Update.
2694 * mdebugread.c (parse_lines, parse_partial_symbols)
2695 (psymtab_to_symtab_1): Update.
2696 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2697 Rename fields. Update comment. Now private.
2698 <text_low, text_high, set_text_low, set_text_high>: New methods.
2699 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2700 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
2701 (start_psymtab_common, maintenance_info_psymtabs)
2702 (maintenance_check_psymtabs): Update.
2703 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
2704 texthigh fields.
2705 (scan_xcoff_symtab): Update.
2706
2707 2018-07-26 Tom Tromey <tromey@redhat.com>
2708
2709 * psympriv.h (struct partial_symbol) <unrelocated_address,
2710 address, set_address>: New methods.
2711 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
2712 (fixup_psymbol_section, relocate_psymtabs): Update.
2713 (print_partial_symbols): Add 'objfile' parameter. Update.
2714 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
2715 Update.
2716
2717 2018-07-26 Tom Tromey <tom@tromey.com>
2718
2719 * dwarf-index-write.c (write_psymbols, debug_names::insert)
2720 (debug_names::write_psymbols): Update.
2721 * psympriv.h (struct partial_symbol): Derive from
2722 general_symbol_info.
2723 <obj_section>: New method.
2724 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
2725 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2726 (find_pc_sect_psymbol, fixup_psymbol_section)
2727 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
2728 (print_partial_symbols, recursively_search_psymtabs)
2729 (compare_psymbols, psymbol_hash, psymbol_compare)
2730 (add_psymbol_to_bcache, maintenance_check_psymtabs)
2731 (psymbol_name_matches, psym_fill_psymbol_map): Update.
2732
2733 2018-07-26 Tom Tromey <tromey@redhat.com>
2734
2735 * dbxread.c (end_psymtab): Remove dead code.
2736
2737 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
2738
2739 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
2740 DWARF unwinders are disabled.
2741 * dwarf2-frame.c: Add dwarf2read.h include.
2742 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
2743 disabled.
2744 (dwarf2_frame_unwinders_enabled_p): Define.
2745 (show_dwarf_unwinders_enabled_p): New function.
2746 (_initialize_dwarf2_frame): Register switch to control DWARF
2747 unwinder use.
2748 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
2749 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
2750 (show_dwarf_cmdlist): Remove static keyword.
2751 * dwarf2read.h (set_dwarf_cmdlist): Declare.
2752 (show_dwarf_cmdlist): Declare.
2753 * NEWS: Document new feature.
2754
2755 2018-07-26 Tom de Vries <tdevries@suse.de>
2756
2757 PR breakpoints/23366
2758 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
2759
2760 2018-07-26 Tom de Vries <tdevries@suse.de>
2761
2762 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
2763 DW_AT_count can't be translated to a dynamic prop.
2764
2765 2018-07-25 Tom de Vries <tdevries@suse.de>
2766
2767 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
2768 try/catch.
2769
2770 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
2771
2772 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
2773
2774 2018-07-25 Joel Brobecker <brobecker@adacore.com>
2775
2776 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
2777
2778 2018-07-24 Keith Seitz <keiths@redhat.comt
2779
2780 PR symtab/23010
2781 * dwarf2read.c (dw2_add_symbol_to_list): New function.
2782 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
2783 instead of add_symbol_to_list.
2784 (read_file_scope): Call prepare_one_comp_unit before reading
2785 any other DIEs.
2786
2787 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
2788
2789 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
2790
2791 2018-07-24 Tom Tromey <tom@tromey.com>
2792
2793 * utils.c (malloc, realloc, free): Don't declare.
2794 * configure, config.in: Rebuild.
2795 * configure.ac: Don't check for declarations of free, malloc, or
2796 realloc.
2797
2798 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2799
2800 * aarch64-linux-nat.c
2801 (aarch64_linux_nat_target::stopped_data_address): Remove unused
2802 variable.
2803 * arm-linux-nat.c (fetch_regs): Likewise.
2804 (store_regs): Likewise.
2805 (fetch_vfp_regs): Likewise.
2806 (store_vfp_regs): Likewise.
2807 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
2808 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
2809 (arm_linux_nat_target::insert_watchpoint): Likewise.
2810 (arm_linux_nat_target::remove_watchpoint): Likewise.
2811 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
2812 Likewise.
2813 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
2814 Likewise.
2815 * ppc-linux-nat.c (fetch_register): Likewise.
2816 (fetch_all_gp_regs): Likewise.
2817 (fetch_ppc_registers): Likewise.
2818 (store_all_gp_regs): Likewise.
2819 (store_ppc_registers): Likewise.
2820 (hwdebug_insert_point): Likewise.
2821 (can_use_watchpoint_cond_accel): Likewise.
2822 * remote-sim.c (gdb_os_write_stdout): Likewise.
2823
2824 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2825 Tom Tromey <tom@tromey.com>
2826
2827 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
2828 test for it.
2829 * configure: Rebuild.
2830
2831 2018-07-22 Tom Tromey <tom@tromey.com>
2832
2833 * regformats/regdat.sh: Define xmltarget_${name} inside
2834 #ifndef IN_PROCESS_AGENT.
2835
2836 2018-07-22 Tom Tromey <tom@tromey.com>
2837
2838 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
2839
2840 2018-07-22 Tom Tromey <tom@tromey.com>
2841
2842 * symfile.c (reread_symbols): Notify iter, not objfile.
2843
2844 2018-07-22 Tom Tromey <tom@tromey.com>
2845
2846 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
2847 Use arch_ops.
2848 (ravenscar_thread_target::prepare_to_store): Likewise.
2849
2850 2018-07-22 Tom Tromey <tom@tromey.com>
2851
2852 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
2853 unused variable. Call value_fetch_lazy when needed.
2854 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
2855 Remove unused variable. Call value_fetch_lazy when needed.
2856
2857 2018-07-22 Tom Tromey <tom@tromey.com>
2858
2859 * m32c-tdep.c (mark_dma): Return void.
2860 (make_regs): Remove unused declarations.
2861
2862 2018-07-22 Tom Tromey <tom@tromey.com>
2863
2864 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
2865 cmdscm_get_valid_command_smob_arg_unsafe for effect.
2866 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
2867 bkscm_get_valid_block_smob_arg_unsafe for effect.
2868
2869 2018-07-22 Tom Tromey <tom@tromey.com>
2870
2871 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
2872 value_type.
2873
2874 2018-07-22 Tom Tromey <tom@tromey.com>
2875
2876 * windows-nat.c (saved_context): Conditionally define.
2877 * remote.c (remote_target::remote_btrace_maybe_reopen):
2878 Conditionally declare "warned".
2879 * inflow.c (sigquit_ours): Conditionally define.
2880 (new_tty): Move "tty" declaration inside #if.
2881 * guile/guile.c (guile_datadir): Conditionally define.
2882 * charset.c (set_be_le_names): Move some declarations inside #if.
2883 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
2884 #if.
2885 (parse_xml_btrace_conf): Likewise.
2886
2887 2018-07-22 Tom Tromey <tom@tromey.com>
2888
2889 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
2890
2891 2018-07-22 Tom Tromey <tom@tromey.com>
2892
2893 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
2894 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
2895 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
2896 * buildsym-legacy.c (get_macro_table): Remove unused variable.
2897 * stack.c (frame_apply_level_command): Remove unused variable.
2898 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
2899 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
2900 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
2901 unused variable.
2902 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
2903 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
2904 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
2905 variable.
2906 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
2907 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
2908 variable.
2909 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
2910 Remove unused variable.
2911 * cli/cli-script.c (recurse_read_control_structure): Remove unused
2912 variable.
2913 * common/tdesc.c (print_xml_feature::visit): Remove unused
2914 variable.
2915 * compile/compile-object-load.c (store_regs): Remove unused
2916 variables.
2917 * complaints.c (clear_complaints): Remove unused variable.
2918 * corelow.c (core_target_open): Remove unused variable.
2919 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
2920 variable.
2921 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
2922 variable.
2923 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
2924 variable.
2925 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
2926 variable.
2927 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
2928 variable.
2929 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
2930 variable.
2931 * ia64-tdep.c (examine_prologue): Remove unused variable.
2932 * infcall.c (run_inferior_call): Remove unused variable.
2933 * inferior.c (exit_inferior): Remove unused variable.
2934 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
2935 * linespec.c (decode_line_2): Remove unused variable.
2936 * linux-nat.c (super_close): Remove.
2937 * linux-tdep.c (linux_info_proc): Remove unused variable.
2938 * mi/mi-main.c (mi_execute_command): Remove unused variable.
2939 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
2940 Remove unused variable.
2941 * parse.c (find_minsym_type_and_address): Remove unused variable.
2942 * printcmd.c (info_symbol_command, printf_floating): Remove unused
2943 variable.
2944 * python/py-breakpoint.c (bppy_set_commands): Remove unused
2945 variable.
2946 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
2947 variables.
2948 * record-btrace.c (record_btrace_target::store_registers): Remove
2949 unused variable.
2950 (cmd_show_record_btrace_cpu): Remove unused variable.
2951 * riscv-tdep.c (riscv_register_reggroup_p)
2952 (riscv_push_dummy_call, riscv_return_value): Remove unused
2953 variable.
2954 * rust-exp.y (literal): Remove unused variable.
2955 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
2956 unused variable.
2957 <STRUCTOP_ANONYMOUS>: Likewise.
2958 * s390-linux-tdep.c (s390_linux_init_abi_31)
2959 (s390_linux_init_abi_64): Remove unused variable.
2960 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
2961 (file_select_thread, net_windows_open, _initialize_ser_windows):
2962 Remove unused variables.
2963 * symtab.c (find_pc_sect_line): Remove unused variable.
2964 * target-memory.c (compute_garbled_blocks): Remove unused
2965 variable.
2966 (target_write_memory_blocks): Remove unused variable.
2967 * target.c (target_stack::unpush): Remove unused variables.
2968 * tracepoint.c (start_tracing, all_tracepoint_actions)
2969 (merge_uploaded_trace_state_variables)
2970 (print_one_static_tracepoint_marker): Remove unused variable.
2971 * unittests/basic_string_view/element_access/char/1.cc (test01):
2972 Remove unused variable.
2973 * windows-nat.c (windows_continue, windows_add_all_dlls)
2974 (do_initial_windows_stuff, windows_nat_target::create_inferior):
2975 Remove unused variables.
2976
2977 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
2978
2979 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
2980 attr_profile in HAVE_ELF.
2981 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
2982 HAVE_ELF.
2983
2984 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
2985
2986 * frame.c (frame_register_unwind): Change parameter name.
2987 (frame_unwind_register): Likewise.
2988 (frame_unwind_register_value): Likewise.
2989 (frame_unwind_register_signed): Likewise.
2990 (frame_unwind_register_unsigned): Likewise.
2991 * frame.h (frame_register_unwind): Likewise.
2992 (frame_unwind_register): Likewise.
2993 (frame_unwind_register_value): Likewise.
2994 (frame_unwind_register_signed): Likewise.
2995 (frame_unwind_register_unsigned): Likewise.
2996 (frame_unwind_arch): Likewise.
2997
2998 2018-07-20 Maciej W. Rozycki <macro@mips.com>
2999
3000 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
3001 ISA maintenance.
3002
3003 2018-07-20 Maciej W. Rozycki <macro@mips.com>
3004
3005 * mips-linux-nat.c (mips_linux_nat_target::read_description):
3006 Call `get_ptrace_pid' rather than extracting the ptrace PID by
3007 hand.
3008
3009 2018-07-20 Keith Seitz <keiths@redhat.com>
3010
3011 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
3012 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
3013 m_compunit_symtab, m_language>: Add "m_" prefix.
3014 Update all uses.
3015 * buildsym.c: Update all uses.
3016
3017 2018-07-20 Tom Tromey <tom@tromey.com>
3018
3019 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
3020 * buildsym.h (record_line_ftype): Remove typedef.
3021
3022 2018-07-20 Tom Tromey <tom@tromey.com>
3023
3024 * buildsym-legacy.h (augment_type_symtab): Don't declare.
3025 (end_expandable_symtab): Likewise.
3026 (end_symtab_get_static_block): Likewise.
3027 (end_symtab_from_static_block): Likewise.
3028 * buildsym-legacy.c (augment_type_symtab): Remove.
3029 (end_expandable_symtab): Remove.
3030 (end_symtab_get_static_block): Remove.
3031 (end_symtab_from_static_block): Remove.
3032
3033 2018-07-20 Tom Tromey <tom@tromey.com>
3034
3035 * dwarf2read.c: Include buildsym.h.
3036 (struct dwarf2_cu) <builder>: New method.
3037 (fixup_go_packaging): Update.
3038 (process_full_comp_unit, process_full_type_unit): Update. Don't
3039 use scoped_free_pendings.
3040 (using_directives): Add "cu" parameter, remove "language".
3041 (read_import_statement, setup_type_unit_groups, )
3042 (read_func_scope, read_lexical_block_scope)
3043 (dwarf2_record_block_ranges, read_namespace): Update.
3044 (lnp_state_machine::lnp_state_machine): Add cu parameter.
3045 (lnp_state_machine::handle_end_sequence): Update.
3046 (class lnp_state_machine) <m_cu>: New member.
3047 <m_record_line_callback>: Remove.
3048 <m_currently_recording_lines>: New member.
3049 (lnp_state_machine::handle_set_file): Update.
3050 (noop_record_line): Remove.
3051 (dwarf_record_line_p): Add cu parameter.
3052 (dwarf_record_line_1, dwarf_finish_line): Likewise.
3053 (lnp_state_machine::record_line)
3054 (lnp_state_machine::lnp_state_machine)
3055 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
3056 (dwarf_decode_lines): Update.
3057 (dwarf2_start_subfile): Add cu parameter.
3058 (dwarf2_start_symtab, new_symbol): Update.
3059 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
3060 Remove dwarf2_per_objfile parameter.
3061 (dwarf_decode_macros): Update.
3062
3063 2018-07-20 Tom Tromey <tom@tromey.com>
3064
3065 * stabsread.c (define_symbol): Update.
3066 * buildsym-legacy.h (get_buildsym_compunit): Declare.
3067 * dwarf2read.c (new_symbol): Update.
3068 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
3069 * cp-namespace.c: Include buildsym.h.
3070 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
3071 * buildsym-legacy.c (get_buildsym_compunit): New function.
3072
3073 2018-07-20 Tom Tromey <tom@tromey.com>
3074
3075 * xcoffread.c: Include buildsym-legacy.h.
3076 * windows-nat.c: Include buildsym-legacy.h.
3077 * stabsread.c: Include buildsym-legacy.h.
3078 * mdebugread.c: Include buildsym-legacy.h.
3079 * buildsym-legacy.h: New file.
3080 * buildsym-legacy.c: New file, from buildsym.c.
3081 * go32-nat.c: Include buildsym-legacy.h.
3082 * dwarf2read.c: Include buildsym-legacy.h.
3083 * dbxread.c: Include buildsym-legacy.h.
3084 * cp-namespace.c: Include buildsym-legacy.h.
3085 * coffread.c: Include buildsym-legacy.h.
3086 * buildsym.h: Move some contents to buildsym-legacy.h.
3087 * buildsym.c: Include buildsym-legacy.h. Move many functions to
3088 buildsym-legacy.c.
3089 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
3090
3091 2018-07-20 Tom Tromey <tom@tromey.com>
3092
3093 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
3094 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
3095 (buildsym_compunit::buildsym_compunit)
3096 (buildsym_compunit::~buildsym_compunit)
3097 (buildsym_compunit::get_macro_table): Define.
3098
3099 2018-07-20 Tom Tromey <tom@tromey.com>
3100
3101 * buildsym.c (reset_symtab_globals): Remove.
3102 (buildsym_compunit::end_symtab_from_static_block): Update.
3103 (buildsym_compunit::augment_type_symtab): Update.
3104 (end_symtab_from_static_block): Call free_buildsym_compunit.
3105 (augment_type_symtab, end_symtab, end_expandable_symtab):
3106 Likewise.
3107
3108 2018-07-20 Tom Tromey <tom@tromey.com>
3109
3110 * arch-utils.c: Do not include buildsym.h.
3111 * mipsread.c: Do not include buildsym.h.
3112 * machoread.c: Do not include buildsym.h.
3113 * elfread.c: Do not include buildsym.h.
3114
3115 2018-07-20 Tom Tromey <tom@tromey.com>
3116
3117 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
3118 initialization.
3119 (buildsym_compunit): Add new constructor.
3120 (struct buildsym_compunit) <get_last_source_file, finish_block,
3121 record_block_range, start_subfile, patch_subfile_names,
3122 push_subfile, pop_subfile, record_line, get_compunit_symtab,
3123 set_last_source_start_addr, get_last_source_start_addr,
3124 get_local_using_directives, set_local_using_directives,
3125 get_global_using_directives, outermost_context_p,
3126 get_current_context_stack, get_context_stack_depth,
3127 get_current_subfile, get_local_symbols, get_file_symbols,
3128 get_global_symbols, record_debugformat, record_producer,
3129 push_context, pop_context, end_symtab_get_static_block,
3130 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
3131 New public methods.
3132 <record_pending_block, finish_block_internal, make_blockvector,
3133 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
3134 private methods.
3135 Update all users.
3136
3137 2018-05-22 Tom Tromey <tom@tromey.com>
3138
3139 * buildsym.c (record_pending_block): Move earlier. Remove objfile
3140 parameter.
3141 (finish_block_internal): Update.
3142
3143 2018-07-20 Tom Tromey <tom@tromey.com>
3144
3145 * buildsym.c (record_pending_block): Move earlier. Remove objfile
3146 parameter.
3147 (finish_block_internal): Update.
3148
3149 2018-07-20 Tom Tromey <tom@tromey.com>
3150
3151 * buildsym.h (EXTERN): Don't define or undef.
3152 * buildsym.c (EXTERN): Don't define.
3153
3154 2018-07-20 Tom Tromey <tom@tromey.com>
3155
3156 * buildsym.c: Remove TODO comment.
3157
3158 2018-07-20 Tom Tromey <tom@tromey.com>
3159
3160 * coffread.c (coff_symtab_read): Update.
3161 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
3162 (xcoff_new_init): Update.
3163 * mipsread.c (mipscoff_new_init): Update.
3164 * mdebugread.c (mdebug_build_psymtabs): Update.
3165 * elfread.c (elf_new_init): Update.
3166 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
3167 Update.
3168 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
3169 (coffstab_build_psymtabs, elfstab_build_psymtabs)
3170 (stabsect_build_psymtabs): Update.
3171 * buildsym.h (buildsym_init): Don't declare.
3172 * buildsym.c: Update comment.
3173 (prepare_for_building): Remove.
3174 (start_symtab, restart_symtab): Update.
3175 (reset_symtab_globals): Update comment.
3176 (buildsym_init): Remove.
3177
3178 2018-07-20 Tom Tromey <tom@tromey.com>
3179
3180 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
3181 * stabsread.c (patch_block_stabs, define_symbol, read_type)
3182 (read_enum_type, common_block_start, common_block_end)
3183 (cleanup_undefined_types_1, finish_global_stabs): Update.
3184 * mdebugread.c (psymtab_to_symtab_1): Update.
3185 * dwarf2read.c (fixup_go_packaging, read_func_scope)
3186 (read_lexical_block_scope, new_symbol): Update.
3187 * dbxread.c (process_one_symbol): Update.
3188 * coffread.c (coff_symtab_read, process_coff_symbol)
3189 (coff_read_enum_type): Update.
3190 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
3191 declare.
3192 (get_local_symbols, get_file_symbols, get_global_symbols): New
3193 functions.
3194 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
3195 m_global_symbols.
3196 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
3197 (~scoped_free_pendings): Update.
3198 (finish_block, prepare_for_building, reset_symtab_globals)
3199 (end_symtab_get_static_block, end_symtab_with_blockvector)
3200 (augment_type_symtab, push_context): Update.
3201 (get_local_symbols, get_file_symbols, get_global_symbols): New
3202 functions.
3203 (buildsym_init): Update.
3204
3205 2018-07-20 Tom Tromey <tom@tromey.com>
3206
3207 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
3208 (process_full_type_unit): Likewise.
3209 (dwarf2_start_symtab): Set list_in_scope.
3210
3211 2018-07-20 Tom Tromey <tom@tromey.com>
3212
3213 * dwarf2read.c (process_psymtab_comp_unit_reader)
3214 (build_type_psymtabs_reader): Do not set list_in_scope.
3215
3216 2018-07-20 Tom Tromey <tom@tromey.com>
3217
3218 * buildsym.c (free_pendings): Remove.
3219 (add_symbol_to_list, scoped_free_pendings)
3220 (finish_block_internal, buildsym_init): Update.
3221
3222 2018-07-20 Tom Tromey <tom@tromey.com>
3223
3224 * xcoffread.c (read_xcoff_symtab): Update.
3225 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
3226 Update.
3227 * dbxread.c (process_one_symbol): Update.
3228 * coffread.c (coff_symtab_read): Update.
3229 * buildsym.h (finish_block): Update.
3230 * buildsym.c (finish_block): Remove "listhead" argument.
3231 (end_symtab_get_static_block): Update.
3232
3233 2018-07-20 Tom Tromey <tom@tromey.com>
3234
3235 * buildsym.h (class scoped_free_pendings): Remove constructor.
3236 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
3237 method.
3238 <m_pending_block_obstack, m_pending_blocks>: New members.
3239 (pending_block_obstack, pending_blocks): Remove.
3240 (scoped_free_pendings::scoped_free_pendings): Default.
3241 (~scoped_free_pendings): Update.
3242 (free_pending_blocks): Remove.
3243 (finish_block_internal, record_pending_block, make_blockvector)
3244 (end_symtab_get_static_block, augment_type_symtab, push_context)
3245 (buildsym_init): Update.
3246
3247 2018-07-20 Tom Tromey <tom@tromey.com>
3248
3249 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
3250 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
3251 members.
3252 (pending_addrmap, pending_addrmap_obstack)
3253 (pending_addrmap_interesting): Remove.
3254 (scoped_free_pendings, record_block_range, make_blockvector)
3255 (prepare_for_building, reset_symtab_globals, buildsym_init):
3256 Update.
3257
3258 2018-07-20 Tom Tromey <tom@tromey.com>
3259
3260 * xcoffread.c (process_linenos): Update.
3261 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
3262 * mdebugread.c (psymtab_to_symtab_1): Update.
3263 * dwarf2read.c (setup_type_unit_groups)
3264 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
3265 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
3266 * dbxread.c (process_one_symbol): Update.
3267 * coffread.c (coff_symtab_read, enter_linenos)
3268 (process_coff_symbol): Update.
3269 * buildsym.h (current_subfile): Don't declare.
3270 (get_current_subfile): Declare.
3271 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
3272 member.
3273 (start_subfile, free_buildsym_compunit, push_subfile)
3274 (prepare_for_building, start_symtab): Update.
3275 (get_current_subfile): New function.
3276
3277 2018-07-20 Tom Tromey <tom@tromey.com>
3278
3279 * coffread.c (coff_symtab_read): Update.
3280 * xcoffread.c (read_xcoff_symtab): Update.
3281 * dwarf2read.c (new_symbol): Update.
3282 (read_func_scope, read_lexical_block_scope): Update.
3283 * dbxread.c (process_one_symbol): Update.
3284 * buildsym.h (context_stack, context_stack_depth): Don't declare.
3285 (outermost_context_p): Remove macro.
3286 (outermost_context_p, get_current_context_stack)
3287 (get_context_stack_depth): Declare.
3288 (pop_context): Return struct context_stack.
3289 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
3290 member.
3291 (context_stack_size): Remove.
3292 (INITIAL_CONTEXT_STACK_SIZE): Remove.
3293 (prepare_for_building, end_symtab_get_static_block)
3294 (augment_type_symtab, push_context): Update.
3295 (pop_context): Return struct context_stack.
3296 (outermost_context_p, get_current_context_stack)
3297 (get_context_stack_depth): New functions.
3298 (buildsym_init): Update.
3299
3300 2018-07-20 Tom Tromey <tom@tromey.com>
3301
3302 * rust-exp.y: Now a pure parser. Update all rules.
3303 (%union): Move earlier.
3304 (current_parser, work_obstack): Remove globals.
3305 (rust_parser, ~rust_parser): Update.
3306 (class rust_parser) <copy_name, concat3, crate_name, super_name,
3307 lex_character, lex_number, lex_string, lex_identifier,
3308 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
3309 convert_name, convert_params_to_expression,
3310 convert_ast_to_expression, ast_basic_type, ast_operation,
3311 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
3312 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
3313 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
3314 ast_array_type, ast_slice_type, ast_reference_type,
3315 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
3316 (rust_parse): Update.
3317 (rustyyerror, rustyylex): Add parser parameter.
3318 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
3319 (rust_lex_stringish_test, rust_lex_test_sequence)
3320 (rust_lex_test_trailing_dot, rust_lex_test_completion)
3321 (rust_lex_test_push_back, rust_lex_tests): Update.
3322
3323 2018-07-19 Pedro Alves <palves@redhat.com>
3324
3325 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
3326 gdb::unique_xmalloc_ptr.
3327 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
3328 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
3329 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
3330 copy-initialization.
3331 * guile/scm-pretty-print.c (ppscm_print_children): Use
3332 gdb::unique_xmalloc_ptr instead of cleanups.
3333 (gdbscm_apply_val_pretty_printer): Remove cleanups.
3334 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
3335 gdb::unique_xmalloc_ptr.
3336 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3337 Adjust to use gdb::unique_xmalloc_ptr.
3338 * guile/scm-utils.c (extract_arg): Adjust.
3339 * guile/scm-value.c (gdbscm_value_field): Adjust to use
3340 gdb::unique_xmalloc_ptr instead of a cleanup.
3341
3342 2018-07-19 Tom Tromey <tom@tromey.com>
3343
3344 * utils.c (do_value_free_to_mark)
3345 (make_cleanup_value_free_to_mark): Remove.
3346 * utils.h (make_cleanup_value_free_to_mark): Remove.
3347
3348 2018-07-19 Pedro Alves <palves@redhat.com>
3349
3350 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
3351 forwarding reference.
3352
3353 2018-07-18 Pedro Alves <palves@redhat.com>
3354
3355 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
3356 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
3357 cleanup.
3358
3359 2018-07-18 Pedro Alves <palves@redhat.com>
3360
3361 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
3362 exceptions.
3363 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
3364 (gdbscm_wrap): New.
3365 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
3366 directly instead of a cleanup.
3367 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
3368 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
3369 (vlscm_binop_gdbthrow): New, factored out from ...
3370 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
3371 (vlscm_rich_compare): Use gdbscm_wrap.
3372 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
3373 instead of a cleanup.
3374 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
3375 cleanup.
3376 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3377 Use xfree directly instead of a cleanup.
3378 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
3379 Adjust to use gdbscm_wrap and scoped_value_mark.
3380 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
3381 (gdbscm_value_address, gdbscm_value_dereference)
3382 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
3383 scoped_value_mark.
3384 (gdbscm_value_dynamic_type): Use scoped_value_mark.
3385 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
3386 scoped_value_mark.
3387 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
3388 gdbscm_wrap and scoped_value_mark.
3389 (gdbscm_value_to_string): Use xfree directly instead of a
3390 cleanup. Move 'buffer' unique_ptr to TRY scope.
3391 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
3392 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
3393 scoped_value_mark.
3394 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
3395 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
3396 scoped_value_mark.
3397 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
3398 gdbscm_wrap.
3399
3400 2018-07-18 Tom de Vries <tdevries@suse.de>
3401
3402 * findvar.c (default_read_var_value): Also resolve dynamic type for
3403 LOC_OPTIMIZED_OUT vars.
3404
3405 2018-07-18 Maciej W. Rozycki <macro@mips.com>
3406
3407 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
3408 decoding.
3409
3410 2018-07-17 Tom Tromey <tom@tromey.com>
3411
3412 * guile/scm-param.c (pascm_set_func, pascm_show_func)
3413 (compute_enum_list, pascm_set_param_value_x)
3414 (gdbscm_parameter_value): Update.
3415 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
3416 (gdbscm_scm_to_host_string): Update.
3417 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
3418 Update.
3419 * guile/scm-cmd.c (cmdscm_add_completion): Update.
3420 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
3421 * guile/scm-string.c (gdbscm_scm_to_string): Return
3422 unique_xmalloc_ptr.
3423 (gdbscm_scm_to_host_string): Likewise.
3424
3425 2018-07-17 Tom Tromey <tom@tromey.com>
3426
3427 * guile/guile.c (gdbscm_eval_from_control_command): Update.
3428 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
3429 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
3430 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
3431 unique_xmalloc_ptr.
3432
3433 2018-07-17 Tom Tromey <tom@tromey.com>
3434
3435 * guile/scm-param.c (pascm_signal_setshow_error): Update.
3436 * guile/guile-internal.h (gdbscm_exception_message_to_string):
3437 Update.
3438 * guile/scm-cmd.c (cmdscm_function): Update.
3439 * guile/scm-pretty-print.c
3440 (ppscm_print_exception_unless_memory_error): Update.
3441 * guile/scm-exception.c (gdbscm_exception_message_to_string):
3442 Return unique_xmalloc_ptr.
3443
3444 2018-07-17 Tom Tromey <tom@tromey.com>
3445
3446 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
3447 Use string_printf.
3448
3449 2018-07-17 Jim Wilson <jimw@sifive.com>
3450
3451 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
3452 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
3453 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
3454 unecessary braces after EF_RISCV_RVC test. Delete call to
3455 set_gdbarch_decr_pc_after_break.
3456
3457 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
3458 RISCV_LAST_FP_REGNUM + 1.
3459 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
3460
3461 2018-07-17 Tom Tromey <tom@tromey.com>
3462
3463 * configure.ac: Remove --disable-gdbcli.
3464 * configure: Rebuild.
3465 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
3466 (SUBDIR_CLI_CFLAGS): Remove.
3467 (SFILES): Use SUBDIR_CLI_SRCS.
3468 (COMMON_OBS): Use SUBDIR_CLI_OBS.
3469
3470 2018-07-17 Tom Tromey <tom@tromey.com>
3471
3472 PR gdb/18624:
3473 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
3474
3475 2018-07-16 Jim Wilson <jimw@sifive.com>
3476
3477 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
3478
3479 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3480
3481 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
3482 variable.
3483 (libunwind_frame_sniffer): Likewise.
3484 (libunwind_frame_prev_register): Likewise.
3485 (libunwind_sigtramp_frame_sniffer): Likewise.
3486 * ia64-tdep.c (ia64_access_reg): Likewise.
3487 (ia64_access_rse_reg): Likewise.
3488 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
3489 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
3490
3491 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3492
3493 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
3494
3495 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3496
3497 * remote-sim.c (gdbsim_target::close,
3498 gdbsim_target::mourn_inferior): Remove unused variables.
3499
3500 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
3501
3502 * ia64-tdep.c (ktab_buf): New global.
3503 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
3504 (get_kernel_table): Adjust.
3505
3506 2018-07-16 Tom Tromey <tom@tromey.com>
3507
3508 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
3509 * dwarf2read.c (using_directives, new_symbol): Use
3510 outermost_context_p.
3511 * dbxread.c (process_one_symbol): Use outermost_context_p.
3512 * coffread.c (coff_symtab_read): Use outermost_context_p.
3513
3514 2018-07-16 Tom Tromey <tom@tromey.com>
3515
3516 * dwarf2read.c (using_directives, read_func_scope)
3517 (read_lexical_block_scope): Update.
3518 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
3519 * buildsym.h (local_using_directives, global_using_directives):
3520 Don't declare.
3521 (get_local_using_directives, set_local_using_directives)
3522 (get_global_using_directives): Declare.
3523 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
3524 m_global_using_directives>: New members.
3525 (finish_block_internal, prepare_for_building)
3526 (reset_symtab_globals, end_symtab_get_static_block)
3527 (push_context): Update.
3528 (get_local_using_directives, set_local_using_directives)
3529 (get_global_using_directives): New functions.
3530 (buildsym_init): Update.
3531
3532 2018-07-16 Tom Tromey <tom@tromey.com>
3533
3534 * xcoffread.c (xcoff_initial_scan): Don't call
3535 free_pending_blocks.
3536 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
3537 * buildsym.h (class scoped_free_pendings): Add constructor.
3538 (free_pending_blocks): Don't declare.
3539 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
3540 (free_pending_blocks): Now static.
3541
3542 2018-07-16 Tom Tromey <tom@tromey.com>
3543
3544 * buildsym.h (push_subfile, pop_subfile): Update declarations.
3545 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
3546 member.
3547 (struct subfile_stack): Remove.
3548 (subfile_stack): Remove.
3549 (push_subfile, pop_subfile, buildsym_init): Update.
3550
3551 2018-07-16 Tom Tromey <tom@tromey.com>
3552
3553 * buildsym.c (push_subfile): Use gdb_assert.
3554 (pop_subfile): Use gdb_assert.
3555
3556 2018-07-16 Tom Tromey <tom@tromey.com>
3557
3558 * buildsym.h (merge_symbol_lists): Remove.
3559 * buildsym.c (merge_symbol_lists): Remove.
3560
3561 2018-07-16 Tom Tromey <tom@tromey.com>
3562
3563 * stabsread.c (scan_file_globals): Update comment.
3564 * stabsread.h (scan_file_globals): Move from buildsym.h.
3565 * buildsym.h (scan_file_globals): Move to stabsread.h.
3566
3567 2018-07-16 Tom Tromey <tom@tromey.com>
3568
3569 * xcoffread.c (xcoff_new_init): Update.
3570 * mipsread.c (mipscoff_new_init): Update.
3571 * mdebugread.c (mdebug_build_psymtabs): Update.
3572 * elfread.c (elf_new_init): Update.
3573 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
3574 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
3575 * buildsym.h (buildsym_new_init): Don't declare.
3576 * buildsym.c (buildsym_new_init): Remove.
3577
3578 2018-07-16 Tom Tromey <tom@tromey.com>
3579
3580 * stabsread.h (within_function): Move from buildsym.h.
3581 * stabsread.c (start_stabs): Clear within_function.
3582 * coffread.c (coff_start_symtab): Clear within_function.
3583 * buildsym.h (within_function): Move to stabsread.h.
3584 * buildsym.c (prepare_for_building): Update.
3585
3586 2018-07-16 Tom Tromey <tom@tromey.com>
3587
3588 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
3589 * dwarf2read.c (dwarf2_start_symtab): Don't set
3590 processing_gcc_compilation.
3591 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
3592
3593 2018-07-16 Tom Tromey <tom@tromey.com>
3594
3595 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
3596 (next_symbol_text_func): Move from buildsym.h.
3597 * stabsread.c (hashname): Move from buildsym.c.
3598 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
3599 (next_symbol_text_func, hashname): Move to stabsread.h.
3600 * buildsym.c: Don't include bcache.h
3601 (hashname): Move to stasbread.c.
3602
3603 2018-07-16 Tom Tromey <tom@tromey.com>
3604
3605 * buildsym.h (context_stack_size): Don't declare.
3606 * buildsym.c (context_stack_size): New global.
3607
3608 2018-07-16 Tom Tromey <tom@tromey.com>
3609
3610 * dbxread.c (processing_acc_compilation): New global.
3611 * buildsym.h (processing_acc_compilation): Don't declare.
3612
3613 2018-07-16 Tom Tromey <tom@tromey.com>
3614
3615 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
3616 * dbxread.c (read_ofile_symtab): Update.
3617 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
3618 * buildsym.h (last_source_start_addr): Remove.
3619 (set_last_source_start_addr, get_last_source_start_addr):
3620 Declare.
3621 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
3622 parameter.
3623 (struct buildsym_compunit) <m_last_source_start_addr>: New
3624 member.
3625 (prepare_for_building): Remove start_addr parameter.
3626 (start_symtab, restart_symtab, end_symtab_get_static_block)
3627 (end_symtab_with_blockvector): Update.
3628 (set_last_source_start_addr, get_last_source_start_addr): New
3629 functions.
3630
3631 2018-07-16 Tom Tromey <tom@tromey.com>
3632
3633 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
3634 member.
3635 (have_line_numbers): Remove.
3636 (record_line, prepare_for_building, end_symtab_get_static_block)
3637 (augment_type_symtab): Update.
3638
3639 2018-07-16 Tom Tromey <tom@tromey.com>
3640
3641 * buildsym.c (~buildsym_compunit): Free the macro table.
3642 (struct buildsym_compunit) <get_macro_table, release_macros>: New
3643 methods.
3644 <m_pending_macros>: New member.
3645 (pending_macros): Remove.
3646 (~scoped_free_pendings, get_macro_table, prepare_for_building)
3647 (reset_symtab_globals, end_symtab_get_static_block)
3648 (end_symtab_with_blockvector, augment_type_symtab)
3649 (buildsym_init): Update.
3650
3651 2018-07-16 Tom Tromey <tom@tromey.com>
3652
3653 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
3654 parameter.
3655 (buildsym_compunit::set_last_source_file): New method.
3656 <m_last_source_file>: New member.
3657 (prepare_for_building): Remove "name" parameter.
3658 (start_symtab, restart_symtab, reset_symtab_globals): Update.
3659 (last_source_file): Remove.
3660 (set_last_source_file, get_last_source_file): Update.
3661
3662 2018-07-16 Tom Tromey <tom@tromey.com>
3663
3664 * buildsym.c (prepare_for_building): Add assert.
3665
3666 2018-07-16 Tom Tromey <tom@tromey.com>
3667
3668 * buildsym.c (~buildsym_compunit): Update.
3669 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
3670 (start_subfile, patch_subfile_names)
3671 (end_symtab_with_blockvector): Update.
3672
3673 2018-07-16 Tom Tromey <tom@tromey.com>
3674
3675 * buildsym.c (struct buildsym_compunit): Add constructor,
3676 destructor, initializers.
3677 (start_buildsym_compunit): Remove.
3678 (free_buildsym_compunit): Use "delete".
3679 (start_symtab, restart_symtab): Use "new".
3680
3681 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
3682
3683 * symfile.c (set_objfile_default_section_offset): Remove struct
3684 keyword.
3685
3686 2018-07-14 Stafford Horne <shorne@gmail.com>
3687
3688 * (Responsible Maintainers): Add myself as or1k maintainer.
3689
3690 2018-07-13 Tom Tromey <tom@tromey.com>
3691
3692 * symfile.c (set_objfile_default_section_offset): Use extra braces
3693 around initializer.
3694
3695 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
3696
3697 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
3698 non-branching basr.
3699
3700 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3701
3702 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3703 unittests/cli-utils-selftests.c
3704 * unittests/cli-utils-selftests.c: New file.
3705
3706 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3707
3708 * NEWS: Mention new commands. Mention change to 'thread apply'.
3709
3710 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3711
3712 * thread.c (thr_try_catch_cmd): New function.
3713 (thread_apply_all_command): Handle qcs flags.
3714 (thread_apply_command): Handle qcs flags.
3715 (taas_command): New function.
3716 (tfaas_command): New function.
3717 (_initialize_thread): Update to setup the new commands 'taas
3718 and 'tfaas'. Change doc string for 'thread apply'.
3719
3720 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3721
3722 * stack.c: (trailing_outermost_frame): New function, mostly
3723 extracted from backtrace_command_1.
3724 (leading_innermost_frame): New function.
3725 (backtrace_command_1): Update to call trailing_outermost_frame.
3726 (frame_apply_command_count): New function.
3727 (frame_apply_level_command): New function.
3728 (frame_apply_all_command): New function.
3729 (frame_apply_command): New function.
3730 (faas_command): New function.
3731 (frame_cmd_list): New variable.
3732 (_initialize_stack): Update to setup the new commands 'frame apply'
3733 and 'faas'.
3734
3735 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3736
3737 * cli-utils.c (number_or_range_parser::get_number): Only handle
3738 numbers or convenience var as numbers.
3739 (parse_flags): New function.
3740 (parse_flags_qcs): New function.
3741 (number_or_range_parser::finished): Ensure parsing end is detected
3742 before end of string.
3743 * cli-utils.h (parse_flags): New function.
3744 (parse_flags_qcs): New function.
3745 (number_or_range_parser): Remove m_finished bool.
3746 (number_or_range_parser::skip_range): Set m_in_range to false.
3747
3748 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
3749
3750 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
3751 on Windows.
3752
3753 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3754 Jan Kratochvil <jan.kratochvil@redhat.com>
3755 Paul Fertser <fercerpav@gmail.com>
3756 Tsutomu Seki <sekiriki@gmail.com>
3757 Pedro Alves <palves@redhat.com>
3758
3759 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3760 'unittests/parse-connection-spec-selftests.c'.
3761 (COMMON_SFILES): Add 'common/netstuff.c'.
3762 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
3763 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
3764 * common/netstuff.c: New file.
3765 * common/netstuff.h: New file.
3766 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
3767 (wait_for_connect): Update comment. New parameter
3768 'gdb::optional<int> sock' instead of 'struct serial *scb'.
3769 Use 'sock' directly instead of 'scb->fd'.
3770 (try_connect): New function, with code from 'net_open'.
3771 (net_open): Rewrite main loop to deal with multiple
3772 sockets/addresses. Handle IPv6-style hostnames; implement
3773 support for IPv6 connections.
3774 * unittests/parse-connection-spec-selftests.c: New file.
3775
3776 2018-07-11 Pedro Alves <palves@redhat.com>
3777
3778 PR gdb/23377
3779 * remote.c (remote_target::remote_detach_pid): Call
3780 set_current_process.
3781
3782 2018-07-11 Pedro Alves <palves@redhat.com>
3783
3784 * h8300-tdep.c (h8300_gdbarch_init): Remove
3785 set_gdbarch_ecoff_reg_to_regnum calls.
3786
3787 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3788
3789 PR c++/23373
3790 * c-typeprint.c (c_type_print_base_struct_union): Don't print
3791 offsets/sizes for static members of a class/struct.
3792
3793 2018-07-11 Alan Hayward <alan.hayward@arm.com>
3794
3795 * target-descriptions.c (tdesc_register_bitsize): Rename.
3796 * target-descriptions.h (tdesc_register_bitsize): Likewise.
3797 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
3798 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
3799
3800 2018-07-10 Tom Tromey <tom@tromey.com>
3801
3802 * breakpoint.c (moribund_locations): Now static and a
3803 std::vector.
3804 (breakpoint_init_inferior, moribund_breakpoint_here_p)
3805 (build_bpstat_chain, update_global_location_list)
3806 (breakpoint_retire_moribund): Update.
3807 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
3808 VEC.
3809
3810 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
3811
3812 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
3813 (riscv_register_reggroup_p): Use new function, remove unneeded
3814 parenthesis.
3815 (riscv_push_dummy_call): Extend assert to compare against xlen or
3816 flen based on register type.
3817
3818 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
3819
3820 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
3821
3822 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
3823
3824 * remote.c (show_hardware_watchpoint_limit): New function.
3825 (show_hardware_watchpoint_length_limit): New function.
3826 (show_hardware_breakpoint_limit): New function.
3827 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
3828 where appropriate, update help text.
3829
3830 2018-07-09 Tom Tromey <tom@tromey.com>
3831
3832 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
3833 (CLIBS): Don't mention NAT_CLIBS.
3834
3835 2018-07-09 Tom Tromey <tom@tromey.com>
3836
3837 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
3838 (LIBGDB_OBS, clean mostlyclean): Update.
3839 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
3840
3841 2018-07-09 Tom Tromey <tom@tromey.com>
3842
3843 * Makefile.in (%.c: %.y): Use ECHO_YACC.
3844 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
3845 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
3846
3847 2018-07-09 Tom Tromey <tom@tromey.com>
3848
3849 * Makefile.in (ALLDEPFILES): Remove exec.c.
3850 (COMMON_OBS): Remove exec.o.
3851 (COMMON_SFILES): Add exec.c.
3852
3853 2018-07-09 Tom Tromey <tom@tromey.com>
3854
3855 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
3856
3857 2018-07-09 Tom Tromey <tom@tromey.com>
3858
3859 * Makefile.in (clean mostlyclean): Remove stamp-version.
3860 (version.c): Depend on stamp-version.
3861 (stamp-version): New rule, from version.c rule.
3862
3863 2018-07-09 Tom Tromey <tom@tromey.com>
3864
3865 * Makefile.in (init.c): Depend on stamp-init.
3866 (stamp-init): New rule, from init.c rule.
3867 (clean mostlyclean): Remove stamp-init.
3868
3869 2018-07-09 Tom Tromey <tom@tromey.com>
3870
3871 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
3872 SUBDIR_GCC_COMPILE_SRCS.
3873
3874 2018-07-09 Tom Tromey <tom@tromey.com>
3875
3876 * Makefile.in (init.c): Remove some unused sed rules.
3877
3878 2018-07-09 Tom Tromey <tom@tromey.com>
3879
3880 * Makefile.in (TSOBS): Remove.
3881 (INIT_FILES): Update.
3882 (LIBGDB_OBS): Update.
3883 (COMMON_SFILES): Add inflow.c.
3884 (SFILES): Remove inflow.c.
3885
3886 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
3887
3888 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
3889
3890 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
3891
3892 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
3893 get_saveloc_name, is_signal_frame_name, step_name,
3894 init_remote_name, create_addr_space_name,
3895 destroy_addr_space_name, search_unwind_table_name,
3896 find_dyn_list_name): Constify.
3897
3898 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
3899
3900 * darwin-nat.c (darwin_pthread_kill): New function.
3901 (darwin_resume_thread): Use darwin_pthread_kill.
3902
3903 2018-07-05 Tom de Vries <tdevries@suse.de>
3904
3905 * macroexp.c (macro_buffer) <operator=>: New member function.
3906
3907 2018-07-04 Tom Tromey <tom@tromey.com>
3908
3909 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
3910
3911 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
3912
3913 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
3914 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
3915 * maint.c: Likewise.
3916 * top.c: Likewise.
3917
3918 2018-07-04 Joel Brobecker <brobecker@adacore.com>
3919
3920 * NEWS: Create a new section for the next release branch.
3921 Rename the section of the current branch, now that it has
3922 been cut.
3923
3924 2018-07-04 Joel Brobecker <brobecker@adacore.com>
3925
3926 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
3927 * version.in: Bump version to 8.2.50.DATE-git.
3928
3929 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
3930 Pedro Alves <palves@redhat.com>
3931
3932 * linux-nat.c (linux_init_ptrace): Rename to ...
3933 (linux_init_ptrace_procfs): ... this. Call
3934 linux_proc_init_warnings.
3935 (linux_nat_target::post_attach)
3936 (linux_nat_target::post_startup_inferior): Adjust.
3937 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
3938 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
3939
3940 2018-07-04 Tom de Vries <tdevries@suse.de>
3941
3942 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
3943 check ...
3944 (read_comp_unit_head): ... here.
3945
3946 2018-07-03 Tom Tromey <tom@tromey.com>
3947
3948 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
3949 (stop_tracing, tstatus_command)
3950 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
3951 (print_one_static_tracepoint_marker): Update.
3952 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
3953 std::vector.
3954 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
3955 VEC.
3956 (all_tracepoints, static_tracepoints_here): Return std::vector.
3957
3958 2018-07-03 Tom Tromey <tom@tromey.com>
3959
3960 * common/ptid.c (ptid_equal): Remove.
3961 * common/ptid.h (ptid_equal): Don't declare.
3962 * ada-tasks.c: Update.
3963 * breakpoint.c: Update.
3964 * common/agent.c: Update.
3965 * corelow.c: Update.
3966 * darwin-nat-info.c: Update.
3967 * darwin-nat.c: Update.
3968 * dcache.c: Update.
3969 * dtrace-probe.c: Update.
3970 * dummy-frame.c: Update.
3971 * fbsd-nat.c: Update.
3972 * frame.c: Update.
3973 * gdbthread.h: Update.
3974 * gnu-nat.c: Update.
3975 * go32-nat.c: Update.
3976 * inf-loop.c: Update.
3977 * inf-ptrace.c: Update.
3978 * infcall.c: Update.
3979 * infcmd.c: Update.
3980 * inflow.c: Update.
3981 * infrun.c: Update.
3982 * linux-fork.c: Update.
3983 * linux-nat.c: Update.
3984 * linux-thread-db.c: Update.
3985 * mi/mi-cmd-var.c: Update.
3986 * mi/mi-interp.c: Update.
3987 * mi/mi-main.c: Update.
3988 * nto-procfs.c: Update.
3989 * ppc-linux-tdep.c: Update.
3990 * procfs.c: Update.
3991 * python/py-inferior.c: Update.
3992 * python/py-record-btrace.c: Update.
3993 * python/py-record.c: Update.
3994 * ravenscar-thread.c: Update.
3995 * regcache.c: Update.
3996 * remote-sim.c: Update.
3997 * remote.c: Update.
3998 * sol-thread.c: Update.
3999 * solib.c: Update.
4000 * target.c: Update.
4001 * tui/tui-stack.c: Update.
4002 * varobj.c: Update.
4003 * windows-nat.c: Update.
4004 * windows-tdep.c: Update.
4005
4006 2018-07-03 Tom Tromey <tom@tromey.com>
4007
4008 * common/ptid.c (ptid_match): Remove.
4009 * common/ptid.h (ptid_match): Don't declare.
4010 * fbsd-nat.c: Update.
4011 * infcmd.c: Update.
4012 * infrun.c: Update.
4013 * linux-nat.c: Update.
4014 * record-btrace.c: Update.
4015 * regcache.c: Update.
4016 * remote.c: Update.
4017
4018 2018-07-03 Tom Tromey <tom@tromey.com>
4019
4020 * common/ptid.c (ptid_tid_p): Remove.
4021 * common/ptid.h (ptid_tid_p): Don't declare.
4022 * sol-thread.c: Update.
4023
4024 2018-07-03 Tom Tromey <tom@tromey.com>
4025
4026 * common/ptid.c (ptid_lwp_p): Remove.
4027 * common/ptid.h (ptid_lwp_p): Don't declare.
4028 * fbsd-nat.c: Update.
4029 * linux-nat.c: Update.
4030 * nat/linux-procfs.c: Update.
4031 * nat/x86-linux-dregs.c: Update.
4032 * sol-thread.c: Update.
4033
4034 2018-07-03 Tom Tromey <tom@tromey.com>
4035
4036 * common/ptid.c (ptid_is_pid): Remove.
4037 * common/ptid.h (ptid_is_pid): Don't declare.
4038 * infrun.c: Update.
4039 * linux-nat.c: Update.
4040 * mi/mi-interp.c: Update.
4041 * remote.c: Update.
4042 * thread.c: Update.
4043
4044 2018-07-03 Tom Tromey <tom@tromey.com>
4045
4046 * common/ptid.c (ptid_get_tid): Remove.
4047 * common/ptid.h (ptid_get_tid): Don't declare.
4048 * ada-tasks.c: Update.
4049 * aix-thread.c: Update.
4050 * bsd-uthread.c: Update.
4051 * darwin-nat.c: Update.
4052 * fbsd-nat.c: Update.
4053 * i386-darwin-nat.c: Update.
4054 * infrun.c: Update.
4055 * linux-tdep.c: Update.
4056 * nto-procfs.c: Update.
4057 * ppc-ravenscar-thread.c: Update.
4058 * python/py-infthread.c: Update.
4059 * ravenscar-thread.c: Update.
4060 * sol-thread.c: Update.
4061 * sparc-ravenscar-thread.c: Update.
4062 * windows-nat.c: Update.
4063
4064 2018-07-03 Tom Tromey <tom@tromey.com>
4065
4066 * common/ptid.c (ptid_get_lwp): Remove.
4067 * common/ptid.h (ptid_get_lwp): Don't declare.
4068 * aarch64-linux-nat.c: Update.
4069 * ada-tasks.c: Update.
4070 * aix-thread.c: Update.
4071 * amd64-linux-nat.c: Update.
4072 * arm-linux-nat.c: Update.
4073 * corelow.c: Update.
4074 * fbsd-nat.c: Update.
4075 * fbsd-tdep.c: Update.
4076 * gnu-nat.c: Update.
4077 * i386-cygwin-tdep.c: Update.
4078 * i386-gnu-nat.c: Update.
4079 * i386-linux-nat.c: Update.
4080 * ia64-linux-nat.c: Update.
4081 * inf-ptrace.c: Update.
4082 * infrun.c: Update.
4083 * linux-fork.c: Update.
4084 * linux-nat.c: Update.
4085 * linux-tdep.c: Update.
4086 * linux-thread-db.c: Update.
4087 * mips-linux-nat.c: Update.
4088 * nat/aarch64-linux-hw-point.c: Update.
4089 * nat/aarch64-linux.c: Update.
4090 * nat/linux-btrace.c: Update.
4091 * nat/linux-osdata.c: Update.
4092 * nat/linux-procfs.c: Update.
4093 * nat/x86-linux-dregs.c: Update.
4094 * obsd-nat.c: Update.
4095 * ppc-fbsd-nat.c: Update.
4096 * ppc-linux-nat.c: Update.
4097 * procfs.c: Update.
4098 * python/py-infthread.c: Update.
4099 * ravenscar-thread.c: Update.
4100 * remote.c: Update.
4101 * s390-linux-nat.c: Update.
4102 * sol-thread.c: Update.
4103 * sol2-tdep.c: Update.
4104 * spu-linux-nat.c: Update.
4105 * x86-linux-nat.c: Update.
4106 * xtensa-linux-nat.c: Update.
4107
4108 2018-07-03 Tom Tromey <tom@tromey.com>
4109
4110 * common/ptid.c (ptid_get_pid): Remove.
4111 * common/ptid.h (ptid_get_pid): Don't declare.
4112 * aarch64-linux-nat.c: Update.
4113 * ada-lang.c: Update.
4114 * aix-thread.c: Update.
4115 * alpha-bsd-nat.c: Update.
4116 * amd64-fbsd-nat.c: Update.
4117 * amd64-linux-nat.c: Update.
4118 * arm-linux-nat.c: Update.
4119 * arm-nbsd-nat.c: Update.
4120 * auxv.c: Update.
4121 * break-catch-syscall.c: Update.
4122 * breakpoint.c: Update.
4123 * bsd-uthread.c: Update.
4124 * corelow.c: Update.
4125 * ctf.c: Update.
4126 * darwin-nat.c: Update.
4127 * fbsd-nat.c: Update.
4128 * fbsd-tdep.c: Update.
4129 * gcore.c: Update.
4130 * gnu-nat.c: Update.
4131 * hppa-nbsd-nat.c: Update.
4132 * hppa-obsd-nat.c: Update.
4133 * i386-fbsd-nat.c: Update.
4134 * ia64-linux-nat.c: Update.
4135 * inf-ptrace.c: Update.
4136 * infcmd.c: Update.
4137 * inferior.c: Update.
4138 * inferior.h: Update.
4139 * inflow.c: Update.
4140 * infrun.c: Update.
4141 * linux-fork.c: Update.
4142 * linux-nat.c: Update.
4143 * linux-tdep.c: Update.
4144 * linux-thread-db.c: Update.
4145 * m68k-bsd-nat.c: Update.
4146 * mi/mi-interp.c: Update.
4147 * mi/mi-main.c: Update.
4148 * mips-linux-nat.c: Update.
4149 * mips-nbsd-nat.c: Update.
4150 * mips64-obsd-nat.c: Update.
4151 * nat/aarch64-linux-hw-point.c: Update.
4152 * nat/aarch64-linux.c: Update.
4153 * nat/linux-btrace.c: Update.
4154 * nat/linux-osdata.c: Update.
4155 * nat/linux-procfs.c: Update.
4156 * nat/x86-linux-dregs.c: Update.
4157 * nto-procfs.c: Update.
4158 * obsd-nat.c: Update.
4159 * ppc-linux-nat.c: Update.
4160 * ppc-nbsd-nat.c: Update.
4161 * ppc-obsd-nat.c: Update.
4162 * proc-service.c: Update.
4163 * procfs.c: Update.
4164 * python/py-inferior.c: Update.
4165 * python/py-infthread.c: Update.
4166 * ravenscar-thread.c: Update.
4167 * record.c: Update.
4168 * remote-sim.c: Update.
4169 * remote.c: Update.
4170 * rs6000-nat.c: Update.
4171 * s390-linux-nat.c: Update.
4172 * sh-nbsd-nat.c: Update.
4173 * sol-thread.c: Update.
4174 * sparc-nat.c: Update.
4175 * sparc64-tdep.c: Update.
4176 * spu-linux-nat.c: Update.
4177 * spu-tdep.c: Update.
4178 * target-debug.h: Update.
4179 * target.c: Update.
4180 * thread.c: Update.
4181 * tid-parse.c: Update.
4182 * tracefile-tfile.c: Update.
4183 * vax-bsd-nat.c: Update.
4184 * windows-nat.c: Update.
4185 * x86-linux-nat.c: Update.
4186 * x86-nat.c: Update.
4187
4188 2018-07-03 Tom Tromey <tom@tromey.com>
4189
4190 * common/ptid.c (pid_to_ptid): Remove.
4191 * common/ptid.h (pid_to_ptid): Don't declare.
4192 * aix-thread.c: Update.
4193 * arm-linux-nat.c: Update.
4194 * common/ptid.c: Update.
4195 * common/ptid.h: Update.
4196 * corelow.c: Update.
4197 * ctf.c: Update.
4198 * darwin-nat.c: Update.
4199 * fbsd-nat.c: Update.
4200 * fork-child.c: Update.
4201 * gnu-nat.c: Update.
4202 * go32-nat.c: Update.
4203 * inf-ptrace.c: Update.
4204 * infcmd.c: Update.
4205 * inferior.c: Update.
4206 * infrun.c: Update.
4207 * linux-fork.c: Update.
4208 * linux-nat.c: Update.
4209 * nat/aarch64-linux-hw-point.c: Update.
4210 * nat/fork-inferior.c: Update.
4211 * nat/x86-linux-dregs.c: Update.
4212 * nto-procfs.c: Update.
4213 * obsd-nat.c: Update.
4214 * procfs.c: Update.
4215 * progspace.c: Update.
4216 * remote.c: Update.
4217 * rs6000-nat.c: Update.
4218 * s390-linux-nat.c: Update.
4219 * sol-thread.c: Update.
4220 * spu-linux-nat.c: Update.
4221 * target.c: Update.
4222 * top.c: Update.
4223 * tracefile-tfile.c: Update.
4224 * windows-nat.c: Update.
4225
4226 2018-07-03 Tom Tromey <tom@tromey.com>
4227
4228 * common/ptid.h (ptid_build): Don't declare.
4229 * common/ptid.c (ptid_build): Remove.
4230 * aix-thread.c: Update.
4231 * bsd-kvm.c: Update.
4232 * bsd-uthread.c: Update.
4233 * common/agent.c: Update.
4234 * common/ptid.c: Update.
4235 * common/ptid.h: Update.
4236 * corelow.c: Update.
4237 * darwin-nat.c: Update.
4238 * fbsd-nat.c: Update.
4239 * gnu-nat.c: Update.
4240 * linux-fork.c: Update.
4241 * linux-nat.c: Update.
4242 * linux-thread-db.c: Update.
4243 * nat/linux-osdata.c: Update.
4244 * nat/linux-procfs.c: Update.
4245 * nto-procfs.c: Update.
4246 * obsd-nat.c: Update.
4247 * proc-service.c: Update.
4248 * procfs.c: Update.
4249 * ravenscar-thread.c: Update.
4250 * remote-sim.c: Update.
4251 * remote.c: Update.
4252 * sol-thread.c: Update.
4253 * target.c: Update.
4254 * windows-nat.c: Update.
4255
4256 2018-07-03 Tom Tromey <tom@tromey.com>
4257
4258 * infrun.c (follow_exec): Use exit_inferior_silent.
4259 * inferior.c (exit_inferior_num_silent): Remove.
4260 * inferior.h (exit_inferior_num_silent): Don't declare.
4261
4262 2018-07-03 Tom Tromey <tom@tromey.com>
4263
4264 PR cli/23340:
4265 * darwin-nat.c (darwin_attach_pid): Reset inferior and
4266 inferior_ptid on error.
4267
4268 2018-07-02 Maciej W. Rozycki <macro@mips.com>
4269 Simon Marchi <simon.marchi@polymtl.ca>
4270
4271 PR tdep/8282
4272 * disasm.h (gdb_disassembler): Add
4273 `m_disassembler_options_holder'. member
4274 * disasm.c (get_all_disassembler_options): New function.
4275 (gdb_disassembler::gdb_disassembler): Use it.
4276 (gdb_buffered_insn_length_init_dis): Likewise.
4277 (gdb_buffered_insn_length): Adjust accordingly.
4278 (set_disassembler_options): Handle options with arguments.
4279 (show_disassembler_options_sfunc): Likewise. Add a leading new
4280 line if showing options with descriptions.
4281 (disassembler_options_completer): Adapt to using the
4282 `disasm_options_and_args_t' structure.
4283 * mips-tdep.c (mips_disassembler_options): New variable.
4284 (mips_disassembler_options_o32): Likewise.
4285 (mips_disassembler_options_n32): Likewise.
4286 (mips_disassembler_options_n64): Likewise.
4287 (gdb_print_insn_mips): Don't set `disassembler_options'.
4288 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
4289 functions.
4290 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
4291 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
4292 `gdbarch_disassembler_options_implicit' and
4293 `gdbarch_valid_disassembler_options'.
4294 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
4295 `disasm_options_and_args_t' structure.
4296 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
4297 method.
4298 (valid_disassembler_options): Switch from `disasm_options_t' to
4299 the `disasm_options_and_args_t' structure.
4300 * NEWS: Document `set disassembler-options' support for the MIPS
4301 target.
4302 * gdbarch.h: Regenerate.
4303 * gdbarch.c: Regenerate.
4304
4305 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
4306
4307 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
4308
4309 2018-06-29 Joel Brobecker <brobecker@adacore.com>
4310
4311 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
4312 parameter in call to amd64_target_description.
4313 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
4314 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
4315 (amd64fbsd_init_abi): Likewise.
4316 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
4317 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
4318 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
4319 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
4320
4321 2018-06-29 Pedro Alves <palves@redhat.com>
4322
4323 * gdb/amd64-tdep.h (amd64_create_target_description): Add
4324 "segments" parameter.
4325 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
4326 (_initialize_amd64_tdep): Update call to
4327 amd64_create_target_description.
4328 (amd64_target_description): Add "segments" parameter. Adjust
4329 the implementation to use it.
4330 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
4331 call to amd64_create_target_description.
4332 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
4333 * gdb/arch/amd64.h (amd64_create_target_description): Add
4334 "segments" register.
4335 * gdb/arch/amd64.c (amd64_create_target_description): Add
4336 "segments" parameter. Call create_feature_i386_64bit_segments
4337 only if SEGMENTS is true.
4338 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
4339 call to amd64_create_target_description.
4340
4341 2018-06-29 Pedro Alves <palves@redhat.com>
4342
4343 * thread.c (thread_target_id_str): New, factored out from ...
4344 (print_thread_info_1): ... here. Use it to compute the max
4345 "Target Id" column width.
4346
4347 2018-06-29 Pedro Alves <palves@redhat.com>
4348
4349 * remote.c (remote_target::extra_thread_info): Delete
4350 'display_buf' and 'n' locals. from the cache, regardless of
4351 packet mechanims is in use. Use cache for qThreadExtra and qP
4352 methods too.
4353
4354 2018-06-29 Pedro Alves <palves@redhat.com>
4355
4356 * blockframe.c (find_pc_sect_containing_function): New function.
4357 * breakpoint.c (print_breakpoint_location): Don't call
4358 find_pc_sect_function.
4359 * linespec.c (create_sals_line_offset): Record the location's
4360 symbol in the sal.
4361 * linespec.c (convert_address_location_to_sals): Fill in sal's
4362 symbol with find_pc_sect_containing_function.
4363 * symtab.c (find_function_start_sal): Rename to ...
4364 (find_function_start_sal_1): ... this.
4365 (find_function_start_sal): Reimplement as wrapper around
4366 find_function_start_sal_1, and use
4367 find_pc_sect_containing_function to fill in the sal's symbol.
4368 (find_function_start_sal(symbol*, bool)): Adjust.
4369 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
4370 comments.
4371 (find_pc_sect_containing_function): Declare.
4372
4373 2018-06-29 Pedro Alves <palves@redhat.com>
4374
4375 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
4376 true if the the location has no symbol.
4377
4378 2018-06-28 Tom Tromey <tom@tromey.com>
4379
4380 * NEWS: Mention --enable-codesign.
4381 * silent-rules.mk (ECHO_SIGN): New variable.
4382 * configure.ac: Add --enable-codesign.
4383 * configure: Rebuild.
4384 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
4385 (gdb$(EXEEXT)): Optionally invoke codesign.
4386
4387 2018-06-28 Pedro Alves <palves@redhat.com>
4388
4389 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
4390 comments.
4391 (switch_to_thread_no_regs): Adjust comment.
4392 * infcmd.c (stop_pc): Delete.
4393 (post_create_inferior, info_program_command): Replace references
4394 to stop_pc with references to thread_info->suspend.stop_pc.
4395 * inferior.h (stop_pc): Delete declaration.
4396 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
4397 (handle_inferior_event_1, handle_signal_stop)
4398 (process_event_stop_test, keep_going_stepped_thread)
4399 (handle_step_into_function, handle_step_into_function_backward)
4400 (print_stop_location): Replace references to stop_pc with
4401 references to thread_info->suspend.stop_pc.
4402 (struct infcall_suspend_state) <stop_pc>: Delete field.
4403 (save_infcall_suspend_state, restore_infcall_suspend_state):
4404 Remove references to inf_stat->stop_pc.
4405 * linux-fork.c (fork_load_infrun_state): Likewise.
4406 * record-btrace.c (record_btrace_set_replay): Likewise.
4407 * record-full.c (record_full_goto_entry): Likewise.
4408 * remote.c (print_one_stopped_thread): Likewise.
4409 * target.c (target_resume): Extend comment.
4410 * thread.c (set_executing_thread): New.
4411 (set_executing): Use it.
4412 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
4413 Remove references to stop_pc.
4414
4415 2018-06-28 Pedro Alves <palves@redhat.com>
4416
4417 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
4418 Moving fetching stop_pc until after ecs->event_thread is refreshed.
4419
4420 2018-06-28 Tom Tromey <tom@tromey.com>
4421
4422 * coffread.c (coff_symfile_finish): Update.
4423 * xcoffread.c (xcoff_symfile_finish): Update.
4424 * elfread.c (elf_symfile_finish): Update.
4425 * symfile.h (dwarf2_free_objfile): Don't declare.
4426 * dwarf2read.c (_initialize_dwarf2_read): Use
4427 register_objfile_data_with_cleanup.
4428 (dwarf2_free_objfile): Now static. Change signature.
4429
4430 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4431
4432 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
4433 option "-o" to add-symbol-file-load to add an offset to each
4434 section's load address.
4435 * symfile.c (set_objfile_default_section_offset): New function.
4436
4437 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4438
4439 * symfile.c (add_symbol_file_command): Make sure that sections
4440 with the same name are sorted in the same order.
4441
4442 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4443
4444 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
4445 require the second argument. If omitted, load sections at the
4446 addresses specified in the file.
4447
4448 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4449
4450 * symfile.c (symbol_file_command, symbol_file_add_main_1)
4451 (_initialize_symfile): Add option "-o" to symbol-file to add an
4452 offset to each section of the symbol file.
4453
4454 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4455
4456 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
4457
4458 2018-06-27 Tom Tromey <tom@tromey.com>
4459
4460 * stack.c (_initialize_stack): Update "func" help text.
4461
4462 2018-06-27 Tom Tromey <tom@tromey.com>
4463
4464 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
4465 std::vector.
4466 (unwind_infopy_str, pyuw_create_unwind_info)
4467 (unwind_infopy_add_saved_register, pyuw_sniffer)
4468 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
4469 Update.
4470 (struct saved_reg): Add constructor.
4471 <value>: Now a gdbpy_ref<>.
4472
4473 2018-06-27 Tom Tromey <tom@tromey.com>
4474
4475 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
4476
4477 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4478
4479 * gdb-gdb.py.in: Format using autopep8.
4480
4481 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4482
4483 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
4484 (type_lookup_function): Recognize CORE_ADDR values.
4485
4486 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4487
4488 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
4489 print tag_name.
4490
4491 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4492
4493 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
4494 <__lt__>: Add.
4495
4496 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4497
4498 * gdb-gdb.py: Move to...
4499 * gdb-gdb.py.in: ... here.
4500 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
4501 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
4502 dependencies.
4503 (distclean): Remove gdb-gdb.py when cleaning.
4504 (gdb-gdb.py, gdb-gdb.gdb): New rules.
4505 * configure: Re-generate.
4506
4507 2018-06-27 Pedro Alves <palves@redhat.com>
4508
4509 * proc-service.c (get_ps_regcache): New.
4510 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
4511 (ps_lsetfpregs): Use it.
4512
4513 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
4514
4515 PR gdb/21695
4516 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
4517 (dwarf_decode_lines_1): Adjust.
4518
4519 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4520
4521 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
4522 override.
4523 <info_proc>: Likewise.
4524
4525 2018-06-26 Joel Brobecker <brobecker@adacore.com>
4526
4527 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
4528 to windows_fetch_one_register, and only handle the case of
4529 fetching one register. Move the code that reloads the context
4530 and iterates over all registers if R is negative to...
4531 (windows_nat_target::fetch_registers): ... here.
4532 (do_windows_store_inferior_registers): Rename to
4533 windows_store_one_register, and only handle the case of storing
4534 one register. Move the code that handles the case where r is
4535 negative to...
4536 (windows_nat_target::store_registers) ... here.
4537
4538 2018-06-26 Tom Tromey <tom@tromey.com>
4539
4540 PR rust/22574:
4541 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
4542 * rust-lang.c (rust_print_struct_def): Add podata parameter.
4543 Update.
4544 (rust_internal_print_type): Add podata parameter.
4545 (rust_print_type): Update.
4546
4547 2018-06-26 Tom Tromey <tom@tromey.com>
4548
4549 * typeprint.h (struct print_offset_data) <update, finish,
4550 maybe_print_hole>: New methods.
4551 <indentation>: New constant.
4552 * typeprint.c (print_offset_data::indentation): Define.
4553 (print_offset_data::maybe_print_hole, print_offset_data::update)
4554 (print_offset_data::finish): Move from c-typeprint.c and rename.
4555 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
4556 (print_spaces_filtered_with_print_options): Update.
4557 (c_print_type_union_field_offset, maybe_print_hole)
4558 (c_print_type_struct_field_offset): Move to typeprint.c and
4559 rename.
4560 (c_type_print_base_struct_union): Update.
4561
4562 2018-06-25 Pedro Alves <palves@redhat.com>
4563
4564 * gdbthread.h (thread_info_ref, delete_thread)
4565 (delete_thread_silent, first_thread_of_inferior)
4566 (any_thread_of_inferior, switch_to_thread)
4567 (enable_thread_stack_temporaries)
4568 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4569 (get_last_thread_stack_temporary)
4570 (value_in_thread_stack_temporaries, can_access_registers_thread):
4571 Spell out "struct thread_info" instead of just "thread_info".
4572 * inferior.h (notice_new_inferior): Likewise.
4573
4574 2018-06-25 Pedro Alves <palves@redhat.com>
4575
4576 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4577 pass thread_info pointer to delete_thread.
4578 (windows_nat_target::detach): Pass inferior pointer to
4579 detach_inferior.
4580 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
4581 delete_thread.
4582 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
4583 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
4584 and pass a thread_info pointer to delete_thread.
4585 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
4586 pass thread_info pointer to delete_thread.
4587 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
4588 delete_thread_silent call.
4589 * procfs.c (procfs_target::detach): Pass inferior pointer to
4590 detach_inferior.
4591 (procfs_target::wait): Pass thread_info pointer to delete_thread.
4592 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
4593 delete_thread_silent call.
4594 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4595 pass thread_info pointer to delete_thread.
4596 (windows_nat_target::detach): Pass inferior pointer to
4597 delete_inferior.
4598
4599 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4600
4601 * regcache.c (readable_regcache::read_part): Fix asserts.
4602 (reg_buffer::raw_collect_part): New function.
4603 (regcache::write_part): Fix asserts.
4604 (reg_buffer::raw_supply_part): New function.
4605 (regcache::transfer_regset_register): New helper function.
4606 (regcache::transfer_regset): Call new functions.
4607 (regcache_supply_regset): Use gdb_byte*.
4608 (regcache::supply_regset): Likewise.
4609 (regcache_collect_regset): Likewise.
4610 (regcache::collect_regset): Likewise.
4611 * regcache.h (reg_buffer::raw_collect_part): New declaration.
4612 (reg_buffer::raw_supply_part): Likewise.
4613 (regcache::transfer_regset_register): Likewise.
4614 (regcache::transfer_regset): Use gdb_byte*.
4615
4616 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4617
4618 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
4619
4620 2018-06-21 Pedro Alves <palves@redhat.com>
4621
4622 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
4623 instead of a ptid_t. All callers adjusted.
4624 * ada-tasks.c (ada_get_task_number): Likewise. All callers
4625 adjusted.
4626 (print_ada_task_info, display_current_task_id, task_command_1):
4627 Adjust.
4628 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
4629 inferior_thread.
4630 (breakpoint_kind): Adjust.
4631 (remove_breakpoints_pid): Rename to ...
4632 (remove_breakpoints_inf): ... this. Adjust to take an inferior
4633 pointer. All callers adjusted.
4634 (bpstat_clear_actions): Use inferior_thread.
4635 (get_bpstat_thread): New.
4636 (bpstat_do_actions): Use it.
4637 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
4638 to take a thread_info pointer. All callers adjusted.
4639 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
4640 (breakpoint_re_set_thread): Use inferior_thread.
4641 * breakpoint.h (struct inferior): Forward declare.
4642 (bpstat_stop_status): Update.
4643 (remove_breakpoints_pid): Delete.
4644 (remove_breakpoints_inf): New.
4645 * bsd-uthread.c (bsd_uthread_target::wait)
4646 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
4647 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
4648 (maint_btrace_packet_history_cmd)
4649 (maint_btrace_clear_packet_history_cmd): Adjust.
4650 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
4651 inferior_thread.
4652 * cli/cli-interp.c: Include "inferior.h".
4653 * common/refcounted-object.h (struct
4654 refcounted_object_ref_policy): New.
4655 * compile/compile-object-load.c: Include gdbthread.h.
4656 (store_regs): Use inferior_thread.
4657 * corelow.c (core_target::close): Use current_inferior.
4658 (core_target_open): Adjust to use first_thread_of_inferior and use
4659 the current inferior.
4660 * ctf.c (ctf_target::close): Adjust to use current_inferior.
4661 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
4662 <thread>: ... this new field. All references adjusted.
4663 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
4664 Take a thread_info pointer instead of a ptid_t.
4665 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
4666 (dummy_frame_discard, register_dummy_frame_dtor): Take a
4667 thread_info pointer instead of a ptid_t.
4668 * elfread.c: Include "inferior.h".
4669 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
4670 Use inferior_thread.
4671 * eval.c (evaluate_subexp): Likewise.
4672 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
4673 inferior_thread.
4674 * gdb_proc_service.h (struct thread_info): Forward declare.
4675 (struct ps_prochandle) <ptid>: Delete, replaced by ...
4676 <thread>: ... this new field. All references adjusted.
4677 * gdbarch.h, gdbarch.c: Regenerate.
4678 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
4679 'thread' parameter. All implementations and callers adjusted.
4680 * gdbthread.h (thread_info) <set_running>: New method.
4681 (delete_thread, delete_thread_silent): Take a thread_info pointer
4682 instead of a ptid.
4683 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
4684 (first_thread_of_process): Delete, replaced by ...
4685 (first_thread_of_inferior): ... this new function. All callers
4686 adjusted.
4687 (any_live_thread_of_process): Delete, replaced by ...
4688 (any_live_thread_of_inferior): ... this new function. All callers
4689 adjusted.
4690 (switch_to_thread, switch_to_no_thread): Declare.
4691 (is_executing): Delete.
4692 (enable_thread_stack_temporaries): Update comment.
4693 <enable_thread_stack_temporaries>: Take a thread_info pointer
4694 instead of a ptid_t. Incref the thread.
4695 <~enable_thread_stack_temporaries>: Decref the thread.
4696 <m_ptid>: Delete
4697 <m_thr>: New.
4698 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4699 (get_last_thread_stack_temporary)
4700 (value_in_thread_stack_temporaries, can_access_registers_thread):
4701 Take a thread_info pointer instead of a ptid_t. All callers
4702 adjusted.
4703 * infcall.c (get_call_return_value): Use inferior_thread.
4704 (run_inferior_call): Work with thread pointers instead of ptid_t.
4705 (call_function_by_hand_dummy): Work with thread pointers instead
4706 of ptid_t. Use thread_info_ref.
4707 * infcmd.c (proceed_thread_callback): Access thread's state
4708 directly.
4709 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
4710 access thread's state directly.
4711 (continue_command): Use inferior_thread.
4712 (info_program_command): Use find_thread_ptid and access thread
4713 state directly.
4714 (proceed_after_attach_callback): Use thread state directly.
4715 (notice_new_inferior): Take a thread_info pointer instead of a
4716 ptid_t. All callers adjusted.
4717 (exit_inferior): Take an inferior pointer instead of a pid. All
4718 callers adjusted.
4719 (exit_inferior_silent): New.
4720 (detach_inferior): Delete.
4721 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
4722 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
4723 (detach_inferior_command, kill_inferior_command): Use
4724 find_inferior_id instead of valid_gdb_inferior_id and
4725 gdb_inferior_id_to_pid.
4726 (inferior_command): Use inferior and thread pointers.
4727 * inferior.h (struct thread_info): Forward declare.
4728 (notice_new_inferior): Take a thread_info pointer instead of a
4729 ptid_t. All callers adjusted.
4730 (detach_inferior): Delete declaration.
4731 (exit_inferior, exit_inferior_silent): Take an inferior pointer
4732 instead of a pid. All callers adjusted.
4733 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
4734 (valid_gdb_inferior_id): Delete.
4735 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
4736 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
4737 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
4738 ...
4739 <inf>: ... this new field.
4740 <step_ptid>: Delete, replaced by ...
4741 <step_thread>: ... this new field.
4742 (get_displaced_stepping_state): Take an inferior pointer instead
4743 of a pid. All callers adjusted.
4744 (displaced_step_in_progress_any_inferior): Adjust.
4745 (displaced_step_in_progress_thread): Take a thread pointer instead
4746 of a ptid_t. All callers adjusted.
4747 (displaced_step_in_progress, add_displaced_stepping_state): Take
4748 an inferior pointer instead of a pid. All callers adjusted.
4749 (get_displaced_step_closure_by_addr): Adjust.
4750 (remove_displaced_stepping_state): Take an inferior pointer
4751 instead of a pid. All callers adjusted.
4752 (displaced_step_prepare_throw, displaced_step_prepare)
4753 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
4754 All callers adjusted.
4755 (start_step_over): Adjust.
4756 (infrun_thread_ptid_changed): Remove bit updating ptids in the
4757 displaced step queue.
4758 (do_target_resume): Adjust.
4759 (fetch_inferior_event): Use inferior_thread.
4760 (context_switch, get_inferior_stop_soon): Take an
4761 execution_control_state pointer instead of a ptid_t. All callers
4762 adjusted.
4763 (switch_to_thread_cleanup): Delete.
4764 (stop_all_threads): Use scoped_restore_current_thread.
4765 * inline-frame.c: Include "gdbthread.h".
4766 (inline_state) <inline_state>: Take a thread pointer instead of a
4767 ptid_t. All callers adjusted.
4768 <ptid>: Delete, replaced by ...
4769 <thread>: ... this new field.
4770 (find_inline_frame_state): Take a thread pointer instead of a
4771 ptid_t. All callers adjusted.
4772 (skip_inline_frames, step_into_inline_frame)
4773 (inline_skipped_frames, inline_skipped_symbol): Take a thread
4774 pointer instead of a ptid_t. All callers adjusted.
4775 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
4776 (inline_skipped_frames, inline_skipped_symbol): Likewise.
4777 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
4778 pointers directly.
4779 * linux-nat.c (get_detach_signal): Likewise.
4780 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
4781 (thread_db_notice_clone): Adjust.
4782 (thread_db_find_new_threads_silently)
4783 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
4784 a thread pointer instead of a ptid_t. All callers adjusted.
4785 * mi/mi-cmd-var.c: Include "inferior.h".
4786 (mi_cmd_var_update_iter): Update to use thread pointers.
4787 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
4788 inferior directly.
4789 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
4790 out to ...
4791 (mi_output_running): ... this new function.
4792 (mi_on_resume_1): Adjust to use it.
4793 (mi_user_selected_context_changed): Adjust to use inferior_thread.
4794 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
4795 directly.
4796 (interrupt_thread_callback): : Adjust to use thread and inferior
4797 pointers.
4798 * proc-service.c: Include "gdbthread.h".
4799 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
4800 * progspace-and-thread.c: Include "inferior.h".
4801 * progspace.c: Include "inferior.h".
4802 * python/py-exitedevent.c (create_exited_event_object): Adjust to
4803 hold a reference to an inferior_object.
4804 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
4805 inferior_thread.
4806 * python/py-inferior.c (struct inferior_object): Give the type a
4807 tag name instead of a typedef.
4808 (python_on_normal_stop): No need to check if the current thread is
4809 listed.
4810 (inferior_to_inferior_object): Change return type to
4811 inferior_object. All callers adjusted.
4812 (find_thread_object): Delete, bits factored out to ...
4813 (thread_to_thread_object): ... this new function.
4814 * python/py-infthread.c (create_thread_object): Use
4815 inferior_to_inferior_object.
4816 (thpy_is_stopped): Use thread pointer directly.
4817 (gdbpy_selected_thread): Use inferior_thread.
4818 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
4819 field, replaced with ...
4820 <thread>: ... this new field. All users adjusted.
4821 (btpy_insn_or_gap_new): Drop const.
4822 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
4823 callers adjusted.
4824 * python/py-record.c: Include "gdbthread.h".
4825 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4826 a ptid_t. All callers adjusted.
4827 (gdbpy_current_recording): Use inferior_thread.
4828 * python/py-record.h (recpy_record_object) <ptid>: Delete
4829 field, replaced with ...
4830 <thread>: ... this new field. All users adjusted.
4831 (recpy_element_object) <ptid>: Delete
4832 field, replaced with ...
4833 <thread>: ... this new field. All users adjusted.
4834 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4835 a ptid_t. All callers adjusted.
4836 * python/py-threadevent.c: Include "gdbthread.h".
4837 (get_event_thread): Use thread_to_thread_object.
4838 * python/python-internal.h (struct inferior_object): Forward
4839 declare.
4840 (find_thread_object, find_inferior_object): Delete declarations.
4841 (thread_to_thread_object, inferior_to_inferior_object): New
4842 declarations.
4843 * record-btrace.c: Include "inferior.h".
4844 (require_btrace_thread): Use inferior_thread.
4845 (record_btrace_frame_sniffer)
4846 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
4847 (get_thread_current_frame): Use scoped_restore_current_thread and
4848 switch_to_thread.
4849 (get_thread_current_frame): Use thread pointer directly.
4850 (record_btrace_replay_at_breakpoint): Use thread's inferior
4851 pointer directly.
4852 * record-full.c: Include "inferior.h".
4853 * regcache.c: Include "gdbthread.h".
4854 (get_thread_arch_regcache): Use the inferior's address space
4855 directly.
4856 (get_thread_regcache, registers_changed_thread): New.
4857 * regcache.h (get_thread_regcache(thread_info *thread)): New
4858 overload.
4859 (registers_changed_thread): New.
4860 (remote_target) <remote_detach_1>: Swap order of parameters.
4861 (remote_add_thread): <remote_add_thread>: Return the new thread.
4862 (get_remote_thread_info(ptid_t)): New overload.
4863 (remote_target::remote_notice_new_inferior): Use thread pointers
4864 directly.
4865 (remote_target::process_initial_stop_replies): Use
4866 thread_info::set_running.
4867 (remote_target::remote_detach_1, remote_target::detach)
4868 (extended_remote_target::detach): Adjust.
4869 * stack.c (frame_show_address): Use inferior_thread.
4870 * target-debug.h (target_debug_print_thread_info_pp): New.
4871 * target-delegates.c: Regenerate.
4872 * target.c (default_thread_address_space): Delete.
4873 (memory_xfer_partial_1): Use current_inferior.
4874 (target_detach): Use current_inferior.
4875 (target_thread_address_space): Delete.
4876 (generic_mourn_inferior): Use current_inferior.
4877 * target.h (struct target_ops) <thread_address_space>: Delete.
4878 (target_thread_address_space): Delete.
4879 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
4880 pointers directly.
4881 (delete_thread_1, delete_thread, delete_thread_silent): Take a
4882 thread pointer instead of a ptid_t. Adjust all callers.
4883 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
4884 (first_thread_of_process): Delete, replaced by ...
4885 (first_thread_of_inferior): ... this new function. All callers
4886 adjusted.
4887 (any_thread_of_process): Rename to ...
4888 (any_thread_of_inferior): ... this, and take an inferior pointer.
4889 (any_live_thread_of_process): Rename to ...
4890 (any_live_thread_of_inferior): ... this, and take an inferior
4891 pointer.
4892 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4893 (value_in_thread_stack_temporaries)
4894 (get_last_thread_stack_temporary): Take a thread pointer instead
4895 of a ptid_t. Adjust all callers.
4896 (thread_info::set_running): New.
4897 (validate_registers_access): Use inferior_thread.
4898 (can_access_registers_ptid): Rename to ...
4899 (can_access_registers_thread): ... this, and take a thread
4900 pointer.
4901 (print_thread_info_1): Adjust to compare thread pointers instead
4902 of ptids.
4903 (switch_to_no_thread, switch_to_thread): Make extern.
4904 (scoped_restore_current_thread::~scoped_restore_current_thread):
4905 Use m_thread pointer directly.
4906 (scoped_restore_current_thread::scoped_restore_current_thread):
4907 Use inferior_thread.
4908 (thread_command): Use thread pointer directly.
4909 (thread_num_make_value_helper): Use inferior_thread.
4910 * top.c (execute_command): Use inferior_thread.
4911 * tui/tui-interp.c: Include "inferior.h".
4912 * varobj.c (varobj_create): Use inferior_thread.
4913 (value_of_root_1): Use find_thread_global_id instead of
4914 global_thread_id_to_ptid.
4915
4916 2018-06-21 Alan Hayward <alan.hayward@arm.com>
4917
4918 * regcache.c (readable_regcache::read_part): Avoid memcpy when
4919 possible.
4920 (regcache::write_part): Likewise.
4921 (readable_regcache::cooked_read_part): Update comment.
4922 (readable_regcache::cooked_write_part): Likewise.
4923 * regcache.h: (readable_regcache::read_part): Likewise.
4924 (regcache::write_part): Likewise.
4925
4926 2018-06-21 Richard Bunt <richard.bunt@arm.com>
4927 Dirk Schubert <dirk.schubert@arm.com>
4928
4929 * aarch64-linux-nat.c (post_attach): New.
4930 (aarch64_linux_nat_target::post_attach): Override post_attach to
4931 record the number of hardware debug registers.
4932
4933 2018-06-20 Tom Tromey <tom@tromey.com>
4934
4935 * python/py-param.c (add_setshow_generic): Make parameters const.
4936 (parmpy_init): Update.
4937
4938 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
4939
4940 * regcache.h (regcache_cooked_read_ftype): Rename to...
4941 (register_read_ftype): ...this, change type to function_view.
4942 (class reg_buffer) <save>: Remove src parameter.
4943 (readonly_detached_regcache) <readonly_detached_regcache>: Make
4944 parameter non-const in first overload. Remove src parameter in
4945 second overload.
4946 * regcache.c (do_cooked_read): Remove.
4947 (readonly_detached_regcache::readonly_detached_regcache): Make
4948 parameter non-const, adjust call to other constructor.
4949 (reg_buffer::save): Remove src parameter.
4950 * frame.c (do_frame_register_read): Remove.
4951 (frame_save_as_regcache): Use lambda function.
4952 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
4953 parameter to ppu2spu_data *.
4954 (ppu2spu_sniffer): Use lambda function.
4955
4956 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
4957
4958 * record-full.c (record_full_target::insert_breakpoint): Remove
4959 "struct" keyword, add const.
4960
4961 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
4962
4963 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
4964 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
4965 * configure.ac: Remove AC_PREREQ, add missing quoting.
4966 * gnulib/configure.ac: Modernize usage of
4967 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
4968 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
4969 (AUTOMAKE_VERSION): Bump to 1.15.1.
4970 * configure: Re-generate.
4971 * config.in: Re-generate.
4972 * aclocal.m4: Re-generate.
4973 * gnulib/aclocal.m4: Re-generate.
4974 * gnulib/config.in: Re-generate.
4975 * gnulib/configure: Re-generate.
4976 * gnulib/import/Makefile.in: Re-generate.
4977
4978 2018-06-19 Pedro Alves <palves@redhat.com>
4979
4980 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
4981 (lookup_minimal_symbol_by_pc_section): ... here with
4982 gdb_assert_not_reached added.
4983
4984 2018-06-19 Pedro Alves <palves@redhat.com>
4985
4986 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
4987 parameter with a block parameter. Compare location's block symbol
4988 with the frame's block instead of addresses.
4989 (skip_inline_frames): Pass the current block instead of the
4990 frame's address. Break out as soon as we determine the frame
4991 should not be skipped.
4992
4993 2018-06-18 Tom Tromey <tom@tromey.com>
4994
4995 * solib-aix.c (solib_aix_get_section_offsets): Return
4996 unique_xmalloc_ptr.
4997 (solib_aix_solib_create_inferior_hook): Update.
4998
4999 2018-06-18 Tom Tromey <tom@tromey.com>
5000
5001 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
5002
5003 2018-06-18 Tom Tromey <tom@tromey.com>
5004
5005 * solib-frv.c (frv_relocate_main_executable): Use
5006 unique_xmalloc_ptr.
5007 * solib-dsbt.c (dsbt_relocate_main_executable): Use
5008 unique_xmalloc_ptr.
5009
5010 2018-06-18 Tom Tromey <tom@tromey.com>
5011
5012 * objfiles.h (inhibit_section_map_updates): Update.
5013 (resume_section_map_updates, resume_section_map_updates_cleanup):
5014 Remove.
5015 * solib-svr4.c (svr4_handle_solib_event): Update.
5016 * objfiles.c (inhibit_section_map_updates): Return
5017 scoped_restore_tmpl<int>.
5018 (resume_section_map_updates, resume_section_map_updates_cleanup):
5019 Remove.
5020
5021 2018-06-18 Tom Tromey <tom@tromey.com>
5022
5023 * valprint.h (read_string): Update.
5024 * valprint.c (read_string): Change type of "buffer".
5025 (val_print_string): Update.
5026 * python/py-value.c (valpy_string): Update.
5027 * language.h (struct language_defn) <la_get_string>: Change
5028 type of "buffer".
5029 (default_get_string, c_get_string): Update.
5030 * language.c (default_get_string): Change type of "buffer".
5031 * guile/scm-value.c (gdbscm_value_to_string): Update.
5032 * c-lang.c (c_get_string): Change type of "buffer".
5033
5034 2018-06-18 Tom Tromey <tom@tromey.com>
5035
5036 * ser-mingw.c (struct pipe_state_destroyer): New.
5037 (pipe_state_up): New typedef.
5038 (cleanup_pipe_state): Remove.
5039 (pipe_windows_open): Use pipe_state_up. Don't release argv.
5040
5041 2018-06-18 Tom Tromey <tom@tromey.com>
5042
5043 * rust-lang.h (rust_yyerror): Don't declare.
5044 * rust-lang.c (rust_language_defn): Update.
5045 * rust-exp.y (yyerror): Now static.
5046 * parse.c (parse_exp_in_context_1): Update.
5047 * p-lang.h (p_yyerror): Don't declare.
5048 * p-lang.c (p_language_defn): Update.
5049 * p-exp.y (yyerror): Now static.
5050 * opencl-lang.c (opencl_language_defn): Update.
5051 * objc-lang.c (objc_language_defn): Update.
5052 * m2-lang.h (m2_yyerror): Don't declare.
5053 * m2-lang.c (m2_language_defn): Update.
5054 * m2-exp.y (yyerror): Now static.
5055 * language.h (struct language_defn) <la_error>: Remove.
5056 * language.c (unk_lang_error): Remove.
5057 (unknown_language_defn, auto_language_defn): Remove.
5058 * go-lang.h (go_yyerror): Don't declare.
5059 * go-lang.c (go_language_defn): Update.
5060 * go-exp.y (yyerror): Now static.
5061 * f-lang.h (f_yyerror): Don't declare.
5062 * f-lang.c (f_language_defn): Update.
5063 * f-exp.y (yyerror): Now static.
5064 * d-lang.h (d_yyerror): Don't declare.
5065 * d-lang.c (d_language_defn): Update.
5066 * d-exp.y (yyerror): Now static.
5067 * c-lang.h (c_yyerror): Don't declare.
5068 * c-lang.c (c_language_defn, cplus_language_defn)
5069 (asm_language_defn, minimal_language_defn): Update.
5070 * c-exp.y (yyerror): Now static.
5071 * ada-lang.h (ada_yyerror): Don't declare.
5072 * ada-lang.c (ada_language_defn): Update.
5073 * ada-exp.y (yyerror): Now static.
5074
5075 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5076
5077 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
5078 (store_sveregs_to_thread): Likewise.
5079 (aarch64_linux_fetch_inferior_registers): Check for SVE.
5080 (aarch64_linux_store_inferior_registers): Likewise.
5081 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
5082 function.
5083 (aarch64_sve_regs_copy_to_regcache): Likewise.
5084 (aarch64_sve_regs_copy_from_regcache): Likewise.
5085 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
5086 declaration.
5087 (aarch64_sve_regs_copy_to_regcache): Likewise.
5088 (aarch64_sve_regs_copy_from_regcache): Likewise.
5089 (sve_context): Structure from Linux headers.
5090 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
5091 (SVE_SIG_ZREG_SIZE): Likewise.
5092 (SVE_SIG_PREG_SIZE): Likewise.
5093 (SVE_SIG_FFR_SIZE): Likewise.
5094 (SVE_SIG_REGS_OFFSET): Likewise.
5095 (SVE_SIG_ZREGS_OFFSET): Likewise.
5096 (SVE_SIG_ZREG_OFFSET): Likewise.
5097 (SVE_SIG_ZREGS_SIZE): Likewise.
5098 (SVE_SIG_PREGS_OFFSET): Likewise.
5099 (SVE_SIG_PREG_OFFSET): Likewise.
5100 (SVE_SIG_PREGS_SIZE): Likewise.
5101 (SVE_SIG_FFR_OFFSET): Likewise.
5102 (SVE_SIG_REGS_SIZE): Likewise.
5103 (SVE_SIG_CONTEXT_SIZE): Likewise.
5104 (SVE_PT_REGS_MASK): Likewise.
5105 (SVE_PT_REGS_FPSIMD): Likewise.
5106 (SVE_PT_REGS_SVE): Likewise.
5107 (SVE_PT_VL_INHERIT): Likewise.
5108 (SVE_PT_VL_ONEXEC): Likewise.
5109 (SVE_PT_REGS_OFFSET): Likewise.
5110 (SVE_PT_FPSIMD_OFFSET): Likewise.
5111 (SVE_PT_FPSIMD_SIZE): Likewise.
5112 (SVE_PT_SVE_ZREG_SIZE): Likewise.
5113 (SVE_PT_SVE_PREG_SIZE): Likewise.
5114 (SVE_PT_SVE_FFR_SIZE): Likewise.
5115 (SVE_PT_SVE_FPSR_SIZE): Likewise.
5116 (SVE_PT_SVE_FPCR_SIZE): Likewise.
5117 (__SVE_SIG_TO_PT): Likewise.
5118 (SVE_PT_SVE_OFFSET): Likewise.
5119 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
5120 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
5121 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
5122 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
5123 (SVE_PT_SVE_PREG_OFFSET): Likewise.
5124 (SVE_PT_SVE_PREGS_SIZE): Likewise.
5125 (SVE_PT_SVE_FFR_OFFSET): Likewise.
5126 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
5127 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
5128 (SVE_PT_SVE_SIZE): Likewise.
5129 (SVE_PT_SIZE): Likewise.
5130 (HAS_SVE_STATE): New define.
5131
5132 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5133
5134 * nat/aarch64-sve-linux-sigcontext.h: New file.
5135 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
5136 new files.
5137 (SVE_VQ_MIN): Likewise.
5138 (SVE_VQ_MAX): Likewise.
5139 (SVE_VL_MIN): Likewise.
5140 (SVE_VL_MAX): Likewise.
5141 (SVE_NUM_ZREGS): Likewise.
5142 (SVE_NUM_PREGS): Likewise.
5143 (sve_vl_valid): Likewise.
5144 (struct user_sve_header): Likewise.
5145
5146 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
5147 Richard Bunt <Richard.Bunt@arm.com>
5148
5149 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
5150 was requested by GDB.
5151
5152 2018-06-15 Tom de Vries <tdevries@suse.de>
5153
5154 * MAINTAINERS (Write After Approval): Add Tom de Vries.
5155
5156 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
5157
5158 * gnulib/update-gnulib.sh: Print expected versions of
5159 autoconf/aclocal.
5160
5161 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
5162
5163 * arch-utils.c (default_type_align): Use type_length_units.
5164 * gdbtypes.c (type_align): Use type_length_units.
5165
5166 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5167
5168 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
5169 of 'define' command.
5170
5171 2018-06-14 Tom de Vries <tdevries@suse.de>
5172
5173 PR cli/22573
5174 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
5175 get_no_prettyformat_print_options.
5176
5177 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
5178
5179 * sparc-nat.h: Include target.h.
5180 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
5181 <fetch_registers>: Remove this argument in function call.
5182 <store_registers>: Remove this argument in function call, remove
5183 extra semicolon.
5184 <low_forget_process>: Call sparc64_forget_process instead of
5185 sparc_forget_process.
5186
5187 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5188
5189 * procfs.c (_initialize_procfs): Use add_inf_child_target.
5190 (procfs_target::make_corefile_notes): Adjust to new
5191 target_read_alloc return type.
5192
5193 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5194 Stephen Roberts <stephen.roberts@arm.com>
5195
5196 PR gdb/22882
5197 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
5198 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
5199 Move should_notify_stop local into more inner scope.
5200
5201 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5202 Stephen Roberts <stephen.roberts@arm.com>
5203
5204 PR gdb/22882
5205 * infrun.c (resume_1): Add call to mark_async_event_handler.
5206
5207 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5208
5209 * infrun.c (do_target_wait): Change old version of $pc printed.
5210
5211 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
5212
5213 * dwarf2read.c (read_index_from_section): Rename to...
5214 (read_gdb_index_from_section): ... this, update all callers.
5215 (dwarf2_read_index): Rename to...
5216 (dwarf2_read_gdb_index): ... this, update all callers.
5217
5218 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
5219
5220 * gdb/hppa-linux-nat.c
5221 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
5222 hppa_linux_nat_target::fetch_registers.
5223
5224 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5225
5226 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
5227 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
5228 (AARCH64_DWARF_SVE_FFR): Likewise.
5229 (AARCH64_DWARF_SVE_P0): Likewise.
5230 (AARCH64_DWARF_SVE_Z0): Likewise.
5231
5232 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5233
5234 * common/common-regcache.h (raw_compare): New function.
5235 * regcache.c (regcache::raw_compare): Likewise.
5236 * regcache.h (regcache::raw_compare): New declaration.
5237
5238 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5239
5240 * common/common-regcache.h (reg_buffer_common): New structure.
5241 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
5242 (reg_buffer::raw_supply): Likewise.
5243 (reg_buffer::raw_supply_integer): Likewise.
5244 (reg_buffer::raw_supply_zeroed): Likewise.
5245 (reg_buffer::raw_collect): Likewise.
5246 (reg_buffer::raw_collect_integer): Likewise.
5247 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
5248 (reg_buffer::raw_supply): Likewise.
5249 (reg_buffer::raw_supply_integer): Likewise.
5250 (reg_buffer::raw_supply_zeroed): Likewise.
5251 (reg_buffer::raw_collect): Likewise.
5252 (reg_buffer::raw_collect_integer): Likewise.
5253
5254 2018-06-10 Tom Tromey <tom@tromey.com>
5255
5256 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
5257 (class remote_state) <stop_reply_queue>: Now std::vector.
5258 (remote_state::~remote_state)
5259 (remote_target::stop_reply_queue_length): Update.
5260 (struct queue_iter_param, remove_child_of_pending_fork)
5261 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
5262 (check_pending_event_prevents_wildcard_vcont_callback)
5263 (remove_stop_reply_for_inferior)
5264 (remove_stop_reply_of_remote_state)
5265 (remote_notif_remove_once_on_match)
5266 (stop_reply_match_ptid_and_ws)
5267 (remote_kill_child_of_pending_fork): Remove.
5268 (remote_target::remove_new_fork_children)
5269 (remote_target::check_pending_events_prevent_wildcard_vcont)
5270 (remote_target::discard_pending_stop_replies)
5271 (remote_target::discard_pending_stop_replies_in_queue)
5272 (remote_target::remote_notif_remove_queued_reply)
5273 (remote_target::queued_stop_reply)
5274 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
5275 (remote_target::wait, remote_target::kill_new_fork_children)
5276 (remote_target::async): Update.
5277
5278 2018-06-10 Tom Tromey <tom@tromey.com>
5279
5280 * record-full.c (record_full_arch_list_cleanups): Remove.
5281 (record_full_message): Use try/catch.
5282 (record_full_wait_cleanups): Remove.
5283 (record_full_wait_1): Use try/catch.
5284 (record_full_restore): Likewise.
5285
5286 2018-06-10 Tom Tromey <tom@tromey.com>
5287
5288 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
5289 declare VEC. Add constructor.
5290 <in_target_beneath>: Now bool.
5291 (record_full_breakpoints): Now a std::vector, static.
5292 (record_full_sync_record_breakpoints)
5293 (record_full_init_record_breakpoints)
5294 (record_full_target::insert_breakpoint)
5295 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
5296
5297 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
5298
5299 * dwarf2read.c (process_cu_includes): Remove struct keyword.
5300 * serial.c (serial_interface_lookup): Remove struct keyword.
5301
5302 2018-06-10 Tom Tromey <tom@tromey.com>
5303
5304 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
5305 method.
5306 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
5307 a method.
5308 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
5309 method.
5310 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
5311 "beneath" as a method.
5312 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
5313 Use "beneath" as a method.
5314
5315 2018-06-10 Tom Tromey <tom@tromey.com>
5316
5317 * tracefile.c (struct trace_file_writer_deleter): New.
5318 <operator()>: Rename from trace_file_writer_xfree.
5319 (trace_file_writer_up): New typedef.
5320 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
5321
5322 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5323
5324 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
5325 <m_registers, m_register_status>: Change type to
5326 std::unique_ptr.
5327 * regcache.c (reg_buffer::reg_buffer): Use new instead of
5328 XCNEWVEC.
5329
5330 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5331
5332 * common/common-regcache.h (enum register_status): Add
5333 underlying type "signed char".
5334 * regcache.h (reg_buffer) <m_register_status>: Change type to
5335 register_status *.
5336 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
5337 register_status instead of signed char.
5338 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
5339 (reg_buffer::get_register_status): Remove cast.
5340 (readable_regcache::raw_read): Remove cast.
5341 (readable_regcache::cooked_read): Remove cast.
5342
5343 2018-06-09 Tom Tromey <tom@tromey.com>
5344
5345 * source.c (reverse_search_command, forward_search_command): Use
5346 scoped_fd.
5347
5348 2018-06-09 Tom Tromey <tom@tromey.com>
5349
5350 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
5351 (serial_ops_list): Now static, std::vector.
5352 (serial_interface_lookup, serial_add_interface): Update.
5353
5354 2018-06-09 Tom Tromey <tom@tromey.com>
5355
5356 * dwarf2read.c (process_cu_includes): Update.
5357 (process_full_comp_unit): Update.
5358 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
5359 std::vector.
5360
5361 2018-06-08 Paul Koning <paul_koning@dell.com>
5362
5363 PR gdb/23252
5364
5365 * python/python.c (do_start_initialization):
5366 Avoid call to internal Python API.
5367 (init__gdb_module): New function.
5368
5369 2018-06-08 Gary Benson <gbenson@redhat.com>
5370
5371 * linux-thread-db.c (valprint.h): New include.
5372 (struct check_thread_db_info): New structure.
5373 (check_thread_db_on_load, tdb_testinfo): New static globals.
5374 (check_thread_db, check_thread_db_callback): New functions.
5375 (try_thread_db_load_1): Run integrity checks if requested.
5376 (maintenance_check_libthread_db): New function.
5377 (_initialize_thread_db): Register "maint check libthread-db"
5378 and "maint set/show check-libthread-db".
5379 * NEWS: Mention the above new commands.
5380
5381 2018-06-08 Tom Tromey <tom@tromey.com>
5382
5383 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
5384 now a method.
5385
5386 2018-06-08 Tom Tromey <tom@tromey.com>
5387
5388 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
5389
5390 2018-06-08 Tom Tromey <tom@tromey.com>
5391
5392 * common/btrace-common.h (struct btrace_data): Add constructor,
5393 destructor, move assignment operator.
5394 <empty, clear, fini>: New methods.
5395 <format>: Initialize.
5396 (btrace_data_init, btrace_data_fini, btrace_data_clear)
5397 (btrace_data_empty): Don't declare.
5398 * common/btrace-common.c (btrace_data_init): Remove.
5399 (btrace_data::fini): Rename from btrace_data_fini.
5400 (btrace_data::empty): Rename from btrace_data_empty.
5401 (btrace_data::clear): Rename from btrace_data_clear. Return
5402 bool.
5403 * btrace.h (make_cleanup_btrace_data): Don't declare.
5404 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
5405 (parse_xml_btrace): Update.
5406 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
5407 (maint_btrace_clear_packet_history_cmd): Update.
5408
5409 2018-06-07 Pedro Alves <palves@redhat.com>
5410
5411 * target.h (target_ops) <beneath>: Now a method. All references
5412 updated.
5413 (class target_stack): New.
5414 * target.c (g_target_stack): New.
5415 (g_current_top_target): Delete.
5416 (current_top_target): Get the top target out of g_target_stack.
5417 (target_stack::push, target_stack::unpush): New.
5418 (push_target, unpush_target): Reimplement.
5419 (target_is_pushed): Reimplement in terms of g_target_stack.
5420 (target_ops::beneath, target_stack::find_beneath): New.
5421
5422 2018-06-07 Pedro Alves <palves@redhat.com>
5423
5424 * target.h (find_target_beneath): Delete declaration.
5425 * target.c (find_target_beneath): Delete definition.
5426 * aix-thread.c: All callers of find_target_beneath adjusted to
5427 call target_ops::beneath instead.
5428 * bsd-uthread.c: Likewise.
5429 * linux-thread-db.c: Likewise.
5430 * ravenscar-thread.c: Likewise.
5431 * sol-thread.c: Likewise.
5432 * spu-multiarch.c: Likewise.
5433
5434 2018-06-07 Pedro Alves <palves@redhat.com>
5435
5436 * target.h (target_ops) <beneath>: Now a method. All references
5437 updated.
5438 (target_ops) <m_beneath>: New.
5439 * target.c (target_ops::beneath): New.
5440 * corelow.c: Adjust all references to target_ops::beneath.
5441 * linux-thread-db.c: Likewise.
5442 * make-target-delegates: Likewise.
5443 * record-btrace.c: Likewise.
5444 * record-full.c: Likewise.
5445 * remote.c: Likewise.
5446 * target.c: Likewise.
5447 * target-delegates.c: Regenerate.
5448
5449 2018-06-07 Pedro Alves <palves@redhat.com>
5450
5451 * target.h (target_stack): Delete.
5452 (current_top_target): Declare function.
5453 * target.c (target_stack): Delete.
5454 (g_current_top_target): New.
5455 (current_top_target): New function.
5456 * auxv.c: Use current_top_target instead of target_stack
5457 throughout.
5458 * avr-tdep.c: Likewise.
5459 * breakpoint.c: Likewise.
5460 * corefile.c: Likewise.
5461 * elfread.c: Likewise.
5462 * eval.c: Likewise.
5463 * exceptions.c: Likewise.
5464 * frame.c: Likewise.
5465 * gdbarch-selftests.c: Likewise.
5466 * gnu-v3-abi.c: Likewise.
5467 * ia64-tdep.c: Likewise.
5468 * ia64-vms-tdep.c: Likewise.
5469 * infcall.c: Likewise.
5470 * infcmd.c: Likewise.
5471 * infrun.c: Likewise.
5472 * linespec.c: Likewise.
5473 * linux-tdep.c: Likewise.
5474 * minsyms.c: Likewise.
5475 * ppc-linux-nat.c: Likewise.
5476 * ppc-linux-tdep.c: Likewise.
5477 * procfs.c: Likewise.
5478 * regcache.c: Likewise.
5479 * remote.c: Likewise.
5480 * rs6000-tdep.c: Likewise.
5481 * s390-linux-nat.c: Likewise.
5482 * s390-tdep.c: Likewise.
5483 * solib-aix.c: Likewise.
5484 * solib-darwin.c: Likewise.
5485 * solib-dsbt.c: Likewise.
5486 * solib-spu.c: Likewise.
5487 * solib-svr4.c: Likewise.
5488 * solib-target.c: Likewise.
5489 * sparc-tdep.c: Likewise.
5490 * sparc64-tdep.c: Likewise.
5491 * spu-tdep.c: Likewise.
5492 * symfile.c: Likewise.
5493 * symtab.c: Likewise.
5494 * target-descriptions.c: Likewise.
5495 * target-memory.c: Likewise.
5496 * target.c: Likewise.
5497 * target.h: Likewise.
5498 * tracefile-tfile.c: Likewise.
5499 * tracepoint.c: Likewise.
5500 * valops.c: Likewise.
5501 * valprint.c: Likewise.
5502 * value.c: Likewise.
5503 * windows-tdep.c: Likewise.
5504 * mi/mi-main.c: Likewise.
5505
5506 2018-06-07 Tom Tromey <tom@tromey.com>
5507
5508 * valprint.h (build_address_symbolic): Declare.
5509 * printcmd.c (print_address_symbolic): Update.
5510 (build_address_symbolic): Change "name" and "filename" to
5511 std::string.
5512 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
5513 Update.
5514 * defs.h (build_address_symbolic): Remove declaration.
5515
5516 2018-06-07 Alan Hayward <alan.hayward@arm.com>
5517
5518 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
5519 (aarch64_vnv_type): Add function.
5520 (aarch64_pseudo_register_name): Add V regs for SVE.
5521 (aarch64_pseudo_register_type): Likewise.
5522 (aarch64_pseudo_register_reggroup_p): Likewise.
5523 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
5524 (aarch64_pseudo_read_value): Add V regs for SVE.
5525 (aarch64_pseudo_write_2): Use V0 offset for SVE
5526 (aarch64_pseudo_write): Add V regs for SVE.
5527 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
5528
5529 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
5530
5531 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
5532 (sve_vl_from_vq): Likewise.
5533
5534 2018-06-05 Tom Tromey <tom@tromey.com>
5535
5536 * cli/cli-cmds.c (show_version): Update.
5537 * top.c (print_gdb_version): Add "interactive" parameter.
5538 Update.
5539 * main.c (captured_main_1): Update.
5540 * top.h (print_gdb_version): Add "interactive" parameter and a
5541 comment.
5542
5543 2018-06-05 David Malcolm <dmalcolm@redhat.com>
5544
5545 * common/enum-flags.h: Add trailing semicolon to example in
5546 comment.
5547
5548 2018-06-05 Tom Tromey <tom@tromey.com>
5549
5550 PR cli/12326:
5551 * NEWS: Add entry about pager.
5552 * utils.c (pagination_disabled_for_command): New global.
5553 (prompt_for_continue): Allow "c" response to prompt.
5554 (reinitialize_more_filter): Clear
5555 pagination_disabled_for_command.
5556 (fputs_maybe_filtered): Check pagination_disabled_for_command.
5557
5558 2018-06-04 Tom Tromey <tom@tromey.com>
5559
5560 * ada-lang.h (ada_lookup_symbol_list): Update.
5561 * ada-lang.c (resolve_subexp): Update.
5562 (symbols_are_identical_enums): Change type of syms. Remove nsyms
5563 parameter.
5564 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
5565 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
5566 results parameter to std::vector.
5567 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
5568 Update.
5569 * ada-exp.y (block_lookup): Update.
5570 (select_possible_type_sym): Change type of syms. Remove nsyms
5571 parameter.
5572 (write_var_or_type, write_name_assoc): Update.
5573
5574 2018-06-04 Joel Brobecker <brobecker@adacore.com>
5575
5576 * windows-nat.c (windows_nat_target::xfer_partial): Return
5577 TARGET_XFER_E_IO if we need to delegate to the target beneath
5578 but BENEATH is NULL.
5579
5580 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
5581
5582 * Makefile.in (config.status): Add configure.nat as a
5583 dependency.
5584
5585 2018-06-04 Tom Tromey <tom@tromey.com>
5586
5587 * cp-name-parser.y (cpname_state): Add method declarations.
5588 (HANDLE_QUAL): Update.
5589 (cpname_state::d_grab, cpname_state::fill_comp)
5590 (cpname_state::make_operator, cpname_state::make_dtor)
5591 (cpname_state::make_builtin_type, cpname_state::make_name)
5592 (cpname_state::d_qualify, cpname_state::d_int_type)
5593 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
5594 (%union): Move earlier.
5595
5596 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5597
5598 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
5599
5600 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5601
5602 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
5603 (aarch64_pseudo_write_1): Likewise.
5604 (aarch64_pseudo_read_value): Use helper.
5605 (aarch64_pseudo_write): Likewise.
5606
5607 2018-06-04 Pedro Alves <palves@redhat.com>
5608
5609 * darwin-nat.c (darwin_ops): Delete.
5610 (darwin_attach_pid): Use get_native_target.
5611
5612 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5613
5614 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
5615 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
5616
5617 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5618
5619 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
5620 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
5621 (aarch64_gdbarch_init): Check for SVE.
5622 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
5623
5624 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5625
5626 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
5627 * aarch64-tdep.h (aarch64_read_description): Likewise.
5628 * arch/aarch64.c (aarch64_create_target_description): Likewise.
5629 * arch/aarch64.h (aarch64_create_target_description): Likewise.
5630 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
5631 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
5632 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
5633
5634 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
5635
5636 * value.c (value_fetch_lazy_bitfield): New.
5637 (value_fetch_lazy_memory): New.
5638 (value_fetch_lazy_register): New.
5639 (value_fetch_lazy): Factor out to smaller functions.
5640
5641 2018-06-01 Tom Tromey <tom@tromey.com>
5642
5643 * cp-name-parser.y (backslashable, represented): Now const.
5644
5645 2018-06-01 Tom Tromey <tom@tromey.com>
5646
5647 * cp-name-parser.y: Include parser-defs.h.
5648 (parser_fprintf): Remove declaration.
5649
5650 2018-06-01 Tom Tromey <tom@tromey.com>
5651
5652 * cp-name-parser.y: Use %pure-parser, %lex-param, and
5653 %parse-param.
5654 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
5655 (global_result): Remove globals.
5656 (struct cpname_state): New.
5657 (yyparse): Don't declare.
5658 (yylex, yyerror): Move declarations after %union.
5659 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
5660 (make_name): Add state parameter.
5661 Update all callers.
5662 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
5663 parameter.
5664 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
5665 Update.
5666 (yylex): Add lvalp, state parameters.
5667 (yyerror): Add state parameter.
5668 (cp_demangled_name_to_comp): Update.
5669
5670 2018-06-01 Tom Tromey <tom@tromey.com>
5671
5672 * cp-name-parser.y (parser_fprintf): Declare.
5673 (GDB_YY_REMAP_PREFIX): Define.
5674 Include yy-remap.h. Don't redefine yy* identifiers.
5675
5676 2018-06-01 Tom Tromey <tom@tromey.com>
5677
5678 * python/py-type.c (typy_legacy_template_argument): Update.
5679 * cp-support.h (cp_demangled_name_to_comp): Update.
5680 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
5681 parameter to be a "std::string *".
5682 (main): Update.
5683
5684 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
5685
5686 * ada-lex.l: Include "diagnostics.h" instead of
5687 "common/diagnostics.h".
5688 * unittests/environ-selftests.c: Likewise.
5689 * common/diagnostics.h: Moved to ../include.
5690
5691 2018-06-01 Joel Brobecker <brobecker@adacore.com>
5692
5693 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
5694 to language_mode_manual while calling breakpoint_re_set_one.
5695
5696 2018-06-01 Tom Tromey <tom@tromey.com>
5697
5698 * valops.c (value_cast_structs, destructor_name_p): Update.
5699 * symtab.c (gdb_mangle_name): Update.
5700 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
5701 Update.
5702 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
5703 (pascal_object_print_value_fields, pascal_object_print_value):
5704 Update.
5705 * p-typeprint.c (pascal_type_print_derivation_info): Update.
5706 * linespec.c (find_methods): Update.
5707 * gdbtypes.h (type_name_no_tag): Remove.
5708 (type_name_or_error): Rename from type_name_no_tag_or_error.
5709 * gdbtypes.c (type_name_no_tag): Remove.
5710 (type_name_or_error): Rename from type_name_no_tag_or_error.
5711 (lookup_struct_elt_type, check_typedef): Update.
5712 * expprint.c (print_subexp_standard): Update.
5713 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
5714 * d-namespace.c (d_lookup_nested_symbol): Update.
5715 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
5716 (cp_print_class_member): Update.
5717 * cp-namespace.c (cp_lookup_nested_symbol): Update.
5718 * completer.c (add_struct_fields): Update.
5719 * c-typeprint.c (cp_type_print_derivation_info)
5720 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
5721 Update.
5722 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
5723 (ada_prefer_type, ada_is_exception_sym): Update.
5724
5725 2018-06-01 Tom Tromey <tom@tromey.com>
5726
5727 * valops.c (enum_constant_from_type, value_namespace_elt)
5728 (value_maybe_namespace_elt): Update.
5729 * valarith.c (find_size_for_pointer_math): Update.
5730 * target-descriptions.c (make_gdb_type): Update.
5731 * symmisc.c (print_symbol): Update.
5732 * stabsread.c (define_symbol, read_type)
5733 (complain_about_struct_wipeout, add_undefined_type)
5734 (cleanup_undefined_types_1): Update.
5735 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
5736 (rust_range_type_p, val_print_struct, rust_print_struct_def)
5737 (rust_internal_print_type, rust_composite_type)
5738 (rust_evaluate_funcall, rust_evaluate_subexp)
5739 (rust_inclusive_range_type_p): Update.
5740 * python/py-type.c (typy_get_tag): Update.
5741 * p-typeprint.c (pascal_type_print_base): Update.
5742 * mdebugread.c (parse_symbol, parse_type): Update.
5743 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
5744 Update.
5745 * guile/scm-type.c (gdbscm_type_tag): Update.
5746 * go-lang.c (sixg_string_p): Update.
5747 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
5748 Update.
5749 * gdbtypes.h (struct main_type) <tag_name>: Remove.
5750 (TYPE_TAG_NAME): Remove.
5751 * gdbtypes.c (type_name_no_tag): Simplify.
5752 (check_typedef, check_types_equal, recursive_dump_type)
5753 (copy_type_recursive, arch_composite_type): Update.
5754 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
5755 in summary mode when needed.
5756 * eval.c (evaluate_funcall): Update.
5757 * dwarf2read.c (fixup_go_packaging, read_structure_type)
5758 (process_structure_scope, read_enumeration_type)
5759 (read_namespace_type, read_module_type, determine_prefix): Update.
5760 * cp-support.c (inspect_type): Update.
5761 * coffread.c (process_coff_symbol, decode_base_type): Update.
5762 * c-varobj.c (c_is_path_expr_parent): Update.
5763 * c-typeprint.c (c_type_print_base_struct_union): Update.
5764 (c_type_print_base_1): Update. Print struct/class/union/enum in
5765 summary when using C language.
5766 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
5767 (gen_maybe_namespace_elt): Update.
5768 * ada-lang.c (ada_type_name): Simplify.
5769 (empty_record, ada_template_to_fixed_record_type_1)
5770 (template_to_static_fixed_type)
5771 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
5772
5773 2018-06-01 Tom Tromey <tom@tromey.com>
5774
5775 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
5776 c_print_type.
5777 * c-typeprint.c (c_print_type_1): Add "language" parameter.
5778 (c_print_type): Update.
5779 (c_print_type): New overload.
5780 (c_type_print_varspec_prefix, c_type_print_args)
5781 (c_type_print_varspec_suffix, c_print_type_no_offsets)
5782 (c_type_print_base_struct_union, c_type_print_base_1)
5783 (cp_type_print_method_args): Add "language" parameter.
5784 (c_type_print_base): Update.
5785 * c-lang.h (c_print_type): Add new overload.
5786
5787 2018-06-01 Tom Tromey <tom@tromey.com>
5788
5789 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
5790 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
5791
5792 2018-06-01 Alan Hayward <alan.hayward@arm.com>
5793
5794 * aarch64-tdep.c (aarch64_sve_register_names): New const
5795 var.
5796 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
5797 (AARCH64_SVE_Z_REGS_NUM): New define.
5798 (AARCH64_SVE_P_REGS_NUM): Likewise.
5799 (AARCH64_SVE_NUM_REGS): Likewise.
5800
5801 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
5802
5803 * nat/linux-ptrace.h [__alpha__]
5804 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
5805 definitions.
5806
5807 2018-05-31 Maciej W. Rozycki <macro@mips.com>
5808
5809 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
5810 the endianness selected.
5811 * NEWS: Document `set endian auto' mode operation update.
5812
5813 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5814
5815 * Makefile.in: Add new header.
5816 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
5817 (sve_vl_from_vg): Likewise.
5818 (sve_vq_from_vl): Likewise.
5819 (sve_vl_from_vq): Likewise.
5820 (sve_vq_from_vg): Likewise.
5821 (sve_vg_from_vq): Likewise.
5822 * configure.nat: Add new c file.
5823 * nat/aarch64-sve-linux-ptrace.c: New file.
5824 * nat/aarch64-sve-linux-ptrace.h: New file.
5825
5826 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5827
5828 * aarch64-linux-nat.c (aarch64_linux_read_description):
5829 Add parmeter zero.
5830 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
5831 Likewise.
5832 * aarch64-tdep.c (tdesc_aarch64_list): Add.
5833 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
5834 (aarch64_gdbarch_init): Add parmeter zero.
5835 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
5836 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
5837 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
5838 parmeter.
5839 * doc/gdb.texinfo: Describe SVE feature
5840 * features/aarch64-sve.c: New file.
5841
5842 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
5843
5844 PR gdb/23210
5845 * gdbarch.sh (significant_addr_bit): Default to zero when
5846 not set by target architecture.
5847 * gdbarch.c: Re-generated.
5848 * utils.c (address_significant): Update.
5849
5850 2018-05-30 Joel Brobecker <brobecker@adacore.com>
5851
5852 * stack.c (func_command): Remove trailing newline in call to error.
5853
5854 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5855
5856 * regcache.h (regcache_raw_collect): Remove, update callers to
5857 use regcache::raw_collect.
5858 * regcache.c (regcache_raw_collect): Remove.
5859
5860 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5861
5862 * regcache.h (regcache_raw_supply): Remove, update callers to
5863 use detached_regcache::raw_supply.
5864 * regcache.c (regcache_raw_supply): Remove.
5865
5866 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5867
5868 * regcache.h (regcache_cooked_write_part): Remove, update
5869 callers to use regcache::cooked_write_part.
5870 * regcache.c (regcache_cooked_write_part): Remove.
5871
5872 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5873
5874 * regcache.h (regcache_cooked_read_part): Remove, update callers
5875 to use readable_regcache::cooked_read_part.
5876 * regcache.c (regcache_cooked_read_part): Remove.
5877
5878 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5879
5880 * regcache.h (regcache_cooked_read_value): Remove, update
5881 callers to use readable_regcache::cooked_read_value.
5882 * regcache.c (regcache_cooked_read_value): Remove.
5883
5884 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5885
5886 * regcache.h (regcache_cooked_write): Remove, update callers to
5887 use regcache::cooked_write.
5888 * regcache.c (regcache_cooked_write): Remove.
5889
5890 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5891
5892 * regcache.h (regcache_invalidate): Remove, update callers to
5893 use detached_regcache::invalidate instead.
5894 * regcache.c (regcache_invalidate): Remove.
5895
5896 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5897
5898 * regcache.h (regcache_raw_write_part): Remove, update callers
5899 to use regcache::raw_write_part instead.
5900 * regcache.c (regcache_raw_write_part): Remove.
5901
5902 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5903
5904 * regcache.h (regcache_raw_read_part): Remove, update callers to
5905 use readable_regcache::raw_read_part instead.
5906 * regcache.c (regcache_raw_read_part): Remove.
5907
5908 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5909
5910 * regcache.h (regcache_cooked_read): Remove, update callers to
5911 use readable_regcache::cooked_read instead.
5912 * regcache.c (regcache_cooked_read): Remove.
5913
5914 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5915
5916 * regcache.h (regcache_raw_write): Remove, update callers to use
5917 regcache::raw_write instead.
5918 * regcache.c (regcache_raw_write): Remove.
5919
5920 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5921
5922 * regcache.h (regcache_raw_read): Remove, update callers to use
5923 readable_regcache::raw_read instead.
5924 * regcache.c (regcache_raw_read): Remove.
5925
5926 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5927
5928 * regcache.h (regcache_raw_update): Remove, update callers to
5929 use readable_regcache::raw_update instead.
5930 * regcache.c (regcache_raw_update): Remove.
5931
5932 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5933
5934 * regcache.h (regcache_register_status): Remove, update callers
5935 to use reg_buffer::get_register_status directly instead.
5936 * regcache.c (regcache_register_status): Remove.
5937
5938 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5939
5940 * regcache.h (regcache_get_ptid): Remove, update all callers to
5941 call regcache::ptid instead.
5942 * regcache.c (regcache_get_ptid): Remove.
5943
5944 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5945
5946 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
5947
5948 2018-05-30 Pedro Alves <palves@redhat.com>
5949
5950 * common/common-exceptions.h (exception_rethrow): Use
5951 ATTRIBUTE_NORETURN.
5952
5953 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
5954
5955 * breakpoint.c (print_solib_event, check_status_catch_solib):
5956 Remove struct keyword in range-based for loops.
5957 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
5958 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
5959 Likewise.
5960 * linespec.c (find_superclass_methods, search_minsyms_for_name):
5961 Likewise.
5962 * symfile.c (addr_info_make_relative): Likewise.
5963 * thread.c (value_in_thread_stack_temporaries): Likewise.
5964
5965 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
5966
5967 PR gdb/16841
5968 * valops.c (value_struct_elt_for_reference): Call check_typedef on
5969 aggregate type to get its real type before accessing it.
5970
5971 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
5972
5973 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
5974 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
5975 * coff-pe-read.c (add_pe_forwarded_sym): Replace
5976 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
5977 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
5978 * jit.c (jit_breakpoint_re_set_internal): Likewise.
5979 * printcmd.c (info_address_command): Likewise.
5980
5981 2018-05-29 Tom Tromey <tom@tromey.com>
5982
5983 * windows-nat.c (handle_exception): Update fall-through comment.
5984
5985 2018-05-29 Tom Tromey <tom@tromey.com>
5986
5987 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
5988 (struct program_space) <added_solibs>: Now a std::vector.
5989 * breakpoint.c (print_solib_event): Update.
5990 (check_status_catch_solib): Update.
5991 * progspace.c (clear_program_space_solib_cache): Update.
5992 * solib.c (update_solib_list): Update.
5993
5994 2018-05-29 Tom Tromey <tom@tromey.com>
5995
5996 * python/py-type.c (typy_richcompare): Update.
5997 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
5998 * gdbtypes.h (types_deeply_equal): Return bool.
5999 (types_equal): Likewise.
6000 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
6001 declare VEC.
6002 (check_types_equal): Change worklist to std::vector. Return
6003 bool.
6004 (struct type_equality_entry): Add constructor.
6005 (compare_maybe_null_strings): Return bool.
6006 (check_types_worklist): Return bool. Change worklist to
6007 std::vector.
6008 (types_deeply_equal): Use std::vector.
6009 (types_equal): Return bool.
6010 (compare_maybe_null_strings): Simplify.
6011
6012 2018-05-29 Tom Tromey <tom@tromey.com>
6013
6014 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
6015
6016 2018-05-29 Tom Tromey <tom@tromey.com>
6017
6018 * objc-lang.h: Don't include cp-support.h.
6019 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
6020 declare VEC.
6021
6022 2018-05-27 Tom Tromey <tom@tromey.com>
6023
6024 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
6025
6026 2018-05-25 Tom Tromey <tom@tromey.com>
6027
6028 * value.c (value::location): Initialize.
6029
6030 2018-05-25 Tom Tromey <tom@tromey.com>
6031
6032 * dbxread.c (init_bincl_list): Remove.
6033 (bincl_list): Now a std::vector.
6034 (bincls_allocated, next_bincl): Remove.
6035 (free_bincl_list, do_free_bincl_list_cleanup)
6036 (make_cleanup_free_bincl_list): Remove.
6037 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
6038 unique_xmalloc_ptr.
6039 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
6040 (struct header_file_location): Add constructor.
6041 (add_bincl_to_list): Remove.
6042
6043 2018-05-25 Tom Tromey <tom@tromey.com>
6044
6045 * tui/tui.c (tui_enable): Update.
6046 * mi/mi-interp.c (mi_interp::init): Update.
6047 * interps.h (class interp) <name>: New method.
6048 <m_name>: Rename from name.
6049 (~scoped_restore_interp): Update.
6050 * interps.c (interp::interp): Update.
6051 (interp_add, interp_set, interp_lookup_existing)
6052 (current_interp_named_p): Update.
6053
6054 2018-05-25 Tom Tromey <tom@tromey.com>
6055
6056 * interps.c (interp_name): Remove.
6057 * mi/mi-interp.c (mi_interp::init): Update.
6058 * interps.h (interp_name): Remove.
6059 (~scoped_restore_interp): Update.
6060 * tui/tui.c (tui_enable): Update.
6061
6062 2018-05-25 Tom Tromey <tom@tromey.com>
6063
6064 * utils.c (fputs_maybe_filtered): Update.
6065 * linespec.c (decode_line_full): Update.
6066 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
6067 (mi_print_breakpoint_for_event, mi_solib_loaded)
6068 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
6069 (mi_user_selected_context_changed): Update.
6070 * mi/mi-main.c (mi_execute_command): Update.
6071 * cli/cli-script.c (execute_control_command): Update.
6072 * python/python.c (execute_gdb_command): Update.
6073 * solib.c (info_sharedlibrary_command): Update.
6074 * interps.c (interp_ui_out): Remove.
6075 * interps.h (interp_ui_out): Remove.
6076
6077 2018-05-25 Tom Tromey <tom@tromey.com>
6078
6079 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
6080 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
6081 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
6082
6083 2018-05-25 Tom Tromey <tom@tromey.com>
6084
6085 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
6086 * interps.c (interp_exec): Use scoped_restore.
6087
6088 2018-05-25 Tom Tromey <tom@tromey.com>
6089
6090 * remote.c (remote_target::remote_file_get): Use
6091 gdb::byte_vector.
6092 (remote_target::remote_file_put): Likewise.
6093
6094 2018-05-25 Tom Tromey <tom@tromey.com>
6095
6096 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
6097 a std::string.
6098 (get_pe_section_index, add_pe_exported_sym): Update.
6099 (read_pe_exported_syms): Use gdb::def_vector.
6100
6101 2018-05-25 Tom Tromey <tom@tromey.com>
6102
6103 * frame.c (remove_prev_frame): Remove.
6104 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
6105
6106 2018-05-25 Maciej W. Rozycki <macro@mips.com>
6107
6108 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
6109 Remove prototypes.
6110 * mips-linux-nat.c (supply_fpregset): Always call
6111 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
6112 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
6113 `mips_fill_fpregset'.
6114 * mips-linux-tdep.c (mips_supply_fpregset)
6115 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
6116 (mips_fill_fpregset_wrapper): Remove functions.
6117 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
6118 (mips_linux_fpregset): Remove variable.
6119 (mips_linux_iterate_over_regset_sections): Use
6120 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
6121 (mips_linux_o32_sigframe_init): Remove comment.
6122
6123 2018-05-25 Pedro Alves <palves@redhat.com>
6124
6125 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
6126 (struct readahead_cache, struct packet_reg, struct
6127 remote_arch_state, class remote_state): Move higher up in the
6128 file.
6129 (remote_target::m_remote_state): Now an object instead of a pointer.
6130 (remote_target::get_remote_state): Adjust.
6131
6132 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
6133
6134 * stack.c (select_and_print_frame): Delete.
6135 (struct function_bounds): Move struct within function.
6136 (func_command): Most content moved into new function
6137 find_frame_for_function, use new function, print result, add
6138 function comment.
6139 (find_frame_for_function): New function, now returns a result.
6140
6141 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6142
6143 * stack.c (iterate_over_block_arg_vars): Fix comment.
6144 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
6145
6146 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
6147
6148 PR gdb/23203
6149 * frame.c
6150 (scoped_restore_selected_frame::scoped_restore_selected_frame):
6151 Define.
6152 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
6153 Define.
6154 * frame.h (class scoped_restore_selected_frame): New class.
6155 * stack.c (print_frame_local_vars): Remove catching and rethrowing
6156 of any exception, use scoped_restore_selected_frame to restore the
6157 frame instead.
6158
6159 2018-05-24 Pedro Alves <palves@redhat.com>
6160
6161 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
6162 override.
6163
6164 2018-05-23 Tom Tromey <tom@tromey.com>
6165
6166 * complaints.c (struct complaints): Remove.
6167 (symfile_complaint_book): Remove.
6168 (series): New global.
6169 (complaint_internal): Update.
6170 (clear_complaints): Update.
6171
6172 2018-05-23 Tom Tromey <tom@tromey.com>
6173
6174 * complaints.c (counters): New global.
6175 (struct complain): Remove.
6176 (struct complaints) <root>: Remove.
6177 (complaint_sentinel): Remove.
6178 (symfile_complaint_book): Update.
6179 (find_complaint) Remove.
6180 (complaint_internal, clear_complaints): Update.
6181
6182 2018-05-23 Tom Tromey <tom@tromey.com>
6183
6184 * complaints.c (struct complain) <file, line>: Remove.
6185 (find_complaint): Remove file, line parameters.
6186 (complaint_internal): Update.
6187
6188 2018-05-23 Tom Tromey <tom@tromey.com>
6189
6190 * complaints.c (vcomplaint): Remove.
6191 (complaint_internal) Merge in contents of vcomplaint.
6192
6193 2018-05-23 Tom Tromey <tom@tromey.com>
6194
6195 * complaints.c (struct complaints) <explanation>: Remove.
6196 (symfile_explanations): Remove.
6197 (symfile_complaint_book): Update.
6198 (vcomplaint): Update.
6199 (struct explanation): Remove.
6200
6201 2018-05-23 Tom Tromey <tom@tromey.com>
6202
6203 * complaints.c (symfile_complaints): Remove.
6204 (complaint_internal): Remove "complaints" parameter.
6205 (clear_complaints, vcomplaint): Remove "c" parameter.
6206 (get_complaints): Remove.
6207 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
6208 (dwarf2_debug_line_missing_file_complaint)
6209 (dwarf2_debug_line_missing_end_sequence_complaint)
6210 (dwarf2_complex_location_expr_complaint)
6211 (dwarf2_const_value_length_mismatch_complaint)
6212 (dwarf2_section_buffer_overflow_complaint)
6213 (dwarf2_macro_malformed_definition_complaint)
6214 (dwarf2_invalid_attrib_class_complaint)
6215 (create_addrmap_from_index, dw2_symtab_iter_next)
6216 (dw2_expand_marked_cus)
6217 (dw2_debug_names_iterator::find_vec_in_debug_names)
6218 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
6219 (create_debug_type_hash_table, init_cutu_and_read_dies)
6220 (partial_die_parent_scope, add_partial_enumeration)
6221 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
6222 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
6223 (read_import_statement, read_file_scope, create_dwo_cu_reader)
6224 (create_cus_hash_table, create_dwp_hash_table)
6225 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
6226 (dwarf2_rnglists_process, dwarf2_ranges_process)
6227 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
6228 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
6229 (handle_struct_member_die, process_structure_scope)
6230 (read_array_type, read_common_block, read_module_type)
6231 (read_tag_pointer_type, read_typedef, read_base_type)
6232 (read_subrange_type, load_partial_dies, partial_die_info::read)
6233 (partial_die_info::read, partial_die_info::read)
6234 (partial_die_info::read, read_checked_initial_length_and_offset)
6235 (dwarf2_string_attr, read_formatted_entries)
6236 (dwarf_decode_line_header)
6237 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
6238 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
6239 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
6240 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
6241 (get_signatured_type, get_DW_AT_signature_type)
6242 (decode_locdesc, file_file_name, consume_improper_spaces)
6243 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
6244 (dwarf_decode_macro_bytes, dwarf_decode_macros)
6245 (dwarf2_symbol_mark_computed, set_die_type)
6246 (read_attribute_value): Update.
6247 * stap-probe.c (handle_stap_probe, get_stap_base_address):
6248 Update.
6249 * dbxread.c (unknown_symtype_complaint)
6250 (lbrac_mismatch_complaint, repeated_header_complaint)
6251 (set_namestring, function_outside_compilation_unit_complaint)
6252 (read_dbx_symtab, process_one_symbol): Update.
6253 * gdbtypes.c (stub_noname_complaint): Update.
6254 * windows-nat.c (handle_unload_dll): Update.
6255 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
6256 (decode_base_type): Update.
6257 * xcoffread.c (bf_notfound_complaint, ef_complaint)
6258 (eb_complaint, record_include_begin, record_include_end)
6259 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
6260 (process_xcoff_symbol, read_symbol)
6261 (function_outside_compilation_unit_complaint)
6262 (scan_xcoff_symtab): Update.
6263 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
6264 * buildsym.c (finish_block_internal, make_blockvector)
6265 (end_symtab_get_static_block, augment_type_symtab): Update.
6266 * dtrace-probe.c (dtrace_process_dof)
6267 (dtrace_static_probe_ops::get_probes): Update.
6268 * complaints.h (struct complaint): Don't declare.
6269 (symfile_complaints): Remove.
6270 (complaint_internal): Remove "complaints" parameter.
6271 (complaint): Likewise.
6272 (clear_complaints): Likewise.
6273 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6274 (reread_symbols): Update.
6275 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
6276 (dwarf2_frame_cache, decode_frame_entry): Update.
6277 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
6278 * objc-lang.c (lookup_objc_class, lookup_child_selector)
6279 (info_selectors_command): Update.
6280 * macrotab.c (macro_include, check_for_redefinition)
6281 (macro_undef): Update.
6282 * objfiles.c (filter_overlapping_sections): Update.
6283 * stabsread.c (invalid_cpp_abbrev_complaint)
6284 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
6285 (define_symbol, error_type, read_type, rs6000_builtin_type)
6286 (stabs_method_name_from_physname, read_member_functions)
6287 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
6288 (attach_fields_to_type, complain_about_struct_wipeout)
6289 (read_range_type, read_args, common_block_start)
6290 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
6291 Update.
6292 * mdebugread.c (index_complaint, unknown_ext_complaint)
6293 (basic_type_complaint, bad_tag_guess_complaint)
6294 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
6295 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
6296 (parse_procedure, parse_lines)
6297 (function_outside_compilation_unit_complaint)
6298 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
6299 (bad_tag_guess_complaint, reg_value_complaint): Update.
6300 * cp-support.c (demangled_name_complaint): Update.
6301 * macroscope.c (sal_macro_scope): Update.
6302 * dwarf-index-write.c (class debug_names): Update.
6303
6304 2018-05-23 Tom Tromey <tom@tromey.com>
6305
6306 * complaints.c (clear_complaints): Remove "noisy" parameter.
6307 * complaints.h (clear_complaints): Update.
6308 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6309 (reread_symbols): Update.
6310
6311 2018-05-23 Tom Tromey <tom@tromey.com>
6312
6313 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
6314 SUBSEQUENT_MESSAGE.
6315 (vcomplaint, clear_complaints): Update.
6316 (symfile_explanations): Remove some messages.
6317
6318 2018-05-23 Tom Tromey <tom@tromey.com>
6319
6320 * complaints.c (internal_complaint): Remove.
6321 * complaints.h (internal_complaint): Remove.
6322
6323 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6324
6325 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
6326
6327 2018-05-22 Pedro Alves <palves@redhat.com>
6328
6329 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
6330 (remote_fileio_badfd, remote_fileio_return_errno)
6331 (remote_fileio_return_success, remote_fileio_func_open)
6332 (remote_fileio_func_open, remote_fileio_func_close)
6333 (remote_fileio_func_read, remote_fileio_func_write)
6334 (remote_fileio_func_lseek, remote_fileio_func_rename)
6335 (remote_fileio_func_unlink, remote_fileio_func_stat)
6336 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
6337 (remote_fileio_func_isatty, remote_fileio_func_system): Add
6338 remote_target parameter.
6339 (remote_fio_func_map) <func>: Add remote_target parameter.
6340 (do_remote_fileio_request, remote_fileio_request):
6341 * remote-fileio.h (remote_fileio_request):
6342 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
6343 remote_target parameter.
6344 (remote_notif_process, handle_notification): Adjust to pass down
6345 the remote.
6346 (remote_notif_state_allocate): Add remote_target parameter. Save
6347 it.
6348 * remote-notif.h (struct remote_target): Forward declare.
6349 (struct notif_client) <parse, ack, can_get_pending_events>: Add
6350 remote_target parameter.
6351 (struct remote_notif_state) <remote>: New field.
6352 (remote_notif_ack, remote_notif_parse): Add remote_target
6353 parameter.
6354 (remote_notif_state_allocate, remote_notif_state_allocate): Add
6355 remote_target parameter.
6356 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
6357 (threads_listing_context, rmt_thread_action, protocol_feature)
6358 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
6359 (packet_result, struct threads_listing_context, remote_state):
6360 Move definitions and declarations higher up.
6361 (remote_target) <~remote_target>: Declare.
6362 (remote_download_command_source, remote_file_put, remote_file_get)
6363 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
6364 (remote_hostio_pread_vFile, remote_hostio_send_command)
6365 (remote_hostio_set_filesystem, remote_hostio_open)
6366 (remote_hostio_close, remote_hostio_unlink, remote_state)
6367 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
6368 (get_memory_write_packet_size, get_memory_read_packet_size)
6369 (append_pending_thread_resumptions, remote_detach_1)
6370 (append_resumption, remote_resume_with_vcont)
6371 (add_current_inferior_and_thread, wait_ns, wait_as)
6372 (process_stop_reply, remote_notice_new_inferior)
6373 (process_initial_stop_replies, remote_add_thread)
6374 (btrace_sync_conf, remote_btrace_maybe_reopen)
6375 (remove_new_fork_children, kill_new_fork_children)
6376 (discard_pending_stop_replies, stop_reply_queue_length)
6377 (check_pending_events_prevent_wildcard_vcont)
6378 (discard_pending_stop_replies_in_queue, stop_reply)
6379 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
6380 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
6381 (remote_interrupt_as, remote_interrupt_ns)
6382 (remote_get_noisy_reply, remote_query_attached)
6383 (remote_add_inferior, remote_current_thread, get_current_thread)
6384 (set_thread, set_general_thread, set_continue_thread)
6385 (set_general_process, write_ptid)
6386 (remote_unpack_thread_info_response, remote_get_threadinfo)
6387 (parse_threadlist_response, remote_get_threadlist)
6388 (remote_threadlist_iterator, remote_get_threads_with_ql)
6389 (remote_get_threads_with_qxfer)
6390 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
6391 (get_offsets, remote_check_symbols, remote_supported_packet)
6392 (remote_query_supported, remote_packet_size)
6393 (remote_serial_quit_handler, remote_detach_pid)
6394 (remote_vcont_probe, remote_resume_with_hc)
6395 (send_interrupt_sequence, interrupt_query)
6396 (remote_notif_get_pending_events, fetch_register_using_p)
6397 (send_g_packet, process_g_packet, fetch_registers_using_g)
6398 (store_register_using_P, store_registers_using_G)
6399 (set_remote_traceframe, check_binary_download)
6400 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
6401 (remote_xfer_live_readonly_partial, remote_read_bytes)
6402 (remote_send_printf, remote_flash_write, readchar)
6403 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
6404 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
6405 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
6406 (extended_remote_disable_randomization, extended_remote_run)
6407 (send_environment_packet, extended_remote_environment_support)
6408 (extended_remote_set_inferior_cwd, remote_write_qxfer)
6409 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
6410 (packet_command): Now methods of ...
6411 (remote_target): ... this class.
6412 (m_remote_state) <remote_target>: New field.
6413 (struct remote_state) <stop_reply_queue,
6414 remote_async_inferior_event_token, wait_forever_enabled_p>: New
6415 fields.
6416 (remote_state::remote_state): Allocate stop_reply_queue.
6417 (remote_state): Delete global.
6418 (get_remote_state_raw): Delete.
6419 (remote_target::get_remote_state): Allocate m_remote_state on
6420 demand.
6421 (get_current_remote_target): New.
6422 (remote_ops, extended_remote_ops): Delete.
6423 (wait_forever_enabled_p, remote_async_inferior_event_token):
6424 Delete, moved to struct remote_state.
6425 (remote_target::close): Delete self. Destruction bits split to
6426 ...
6427 (remote_target::~remote_target): ... this.
6428 (show_memory_packet_size): Adjust to use
6429 get_current_remote_target.
6430 (struct protocol_feature) <func>: Add remote_target parameter.
6431 All callers adjusted.
6432 (curr_quit_handler_target): New.
6433 (remote_serial_quit_handler): Reimplement.
6434 (remote_target::open_1): Adjust to use get_current_remote_target.
6435 Heap-allocate remote_target/extended_remote_target instances.
6436 (vcont_builder::vcont_builder): Add remote_target parameter, and
6437 save it in m_remote. All callers adjusted.
6438 (vcont_builder::m_remote): New field.
6439 (vcont_builder::restart, vcont_builder::flush)
6440 (vcont_builder::push_action): Use it.
6441 (remote_target::commit_resume): Use it.
6442 (struct queue_iter_param) <remote>: New field.
6443 (remote_target::remove_new_fork_children): Fill in 'remote' field.
6444 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
6445 (check_pending_event_prevents_wildcard_vcont_callback)
6446 (remote_target::check_pending_events_prevent_wildcard_vcont)
6447 (remote_target::discard_pending_stop_replies)
6448 (remote_target::discard_pending_stop_replies_in_queue)
6449 (remote_target::remote_notif_remove_queued_reply): Fill in
6450 'remote' field.
6451 (remote_notif_get_pending_events): New.
6452 (remote_target::readchar, remote_target::remote_serial_write):
6453 Save/restore curr_quit_handler_target.
6454 (putpkt): New.
6455 (kill_new_fork_children): Fill in 'remote' field.
6456 (packet_command): Use get_current_remote_target, defer to
6457 remote_target method of same name.
6458 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
6459 parameter, and save it in m_remote. All callers adjusted.
6460 (scoped_remote_fd::release): Use m_remote.
6461 (scoped_remote_fd::m_remote): New field.
6462 (remote_file_put, remote_file_get, remote_file_delete): Use
6463 get_current_remote_target, defer to remote_target method of same
6464 name.
6465 (remote_btrace_reset): Add remote_state paremeter. Update all
6466 callers.
6467 (remote_async_inferior_event_handler). Pass down 'data'.
6468 (remote_new_objfile): Use get_current_remote_target.
6469 (remote_target::vcont_r_supported): New.
6470 (set_range_stepping): Use get_current_remote_target and
6471 remote_target::vcont_r_supported.
6472 (_initialize_remote): Don't allocate 'remote_state' and
6473 'stop_reply_queue' globals.
6474 * remote.h (struct remote_target): Forward declare.
6475 (getpkt, putpkt, remote_notif_get_pending_events): Add
6476 'remote_target' parameter.
6477
6478 2018-05-22 Pedro Alves <palves@redhat.com>
6479
6480 * remote.c (vcont_builder): Now a class. Make all data members
6481 private.
6482 (vcont_builder) <vcont_builder, restart, flush, push_action>:
6483 Declare methods.
6484 (vcont_builder_restart): Rename to ...
6485 (vcont_builder::restart): ... this.
6486 (vcont_builder_flush): Rename to ...
6487 (vcont_builder::flush): ... this.
6488 (vcont_builder_push_action): Rename to ...
6489 (vcont_builder::push_action): ... this.
6490 (remote_target::commit_resume): Adjust.
6491
6492 2018-05-22 Pedro Alves <palves@redhat.com>
6493
6494 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
6495 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
6496 (get_fixed_memory_packet_size): New.
6497 (get_memory_packet_size): Use it.
6498 (set_memory_packet_size): Don't override the config size with
6499 DEFAULT_MAX_MEMORY_PACKET_SIZE.
6500 (show_memory_packet_size): Use get_fixed_memory_packet_size.
6501 Don't refer to get_memory_packet_size if not connected to a remote
6502 target. Show "(default)" if configured size is 0.
6503
6504 2018-05-22 Pedro Alves <palves@redhat.com>
6505
6506 * remote.c (remote_target::mourn_inferior): Move
6507 discard_pending_stop_replies call here from ...
6508 (_initialize_remote): ... here.
6509
6510 2018-05-22 Pedro Alves <palves@redhat.com>
6511
6512 * remote.c (compare_section_command): Remove set_general_process
6513 call.
6514
6515 2018-05-22 Pedro Alves <palves@redhat.com>
6516
6517 * remote.c (struct packet_reg, struct remote_arch_state):
6518 Move higher up in the file.
6519 (remote_state) <m_arch_states>: Store remote_arch_state values
6520 instead of remote_arch_state pointers.
6521 (remote_state::get_remote_arch_state): Adjust.
6522
6523 2018-05-22 Pedro Alves <palves@redhat.com>
6524
6525 * remote.c: Include <unordered_map>.
6526 (remote_state): Now a class.
6527 (remote_state) <get_remote_arch_state>: Declare method.
6528 <get_remote_arch_state>: New field.
6529 (remote_arch_state) <remote_arch_state>: Declare ctor.
6530 <regs>: Now a unique_ptr.
6531 (remote_gdbarch_data_handle): Delete.
6532 (get_remote_arch_state): Delete.
6533 (remote_state::get_remote_arch_state): New.
6534 (get_remote_state): Adjust to call remote_state's
6535 get_remote_arch_state method.
6536 (init_remote_state): Delete, bits factored out to ...
6537 (remote_arch_state::remote_arch_state): ... this new method.
6538 (get_remote_packet_size, get_memory_packet_size)
6539 (process_g_packet, remote_target::fetch_registers)
6540 (remote_target::prepare_to_store, store_registers_using_G)
6541 (remote_target::store_registers, remote_target::get_trace_status):
6542 Adjust to call remote_state's method.
6543 (_initialize_remote): Remove reference to
6544 remote_gdbarch_data_handle.
6545
6546 2018-05-22 Pedro Alves <palves@redhat.com>
6547
6548 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
6549 pread>: New method declarations.
6550 (remote_target::open_1): Adjust.
6551 (readahead_cache_invalidate): Rename to ...
6552 (readahead_cache::invalidate): ... this, and adjust to be a class
6553 method.
6554 (readahead_cache_invalidate_fd): Rename to ...
6555 (readahead_cache::invalidate_fd): ... this, and adjust to be a
6556 class method.
6557 (remote_hostio_pwrite): Adjust.
6558 (remote_hostio_pread_from_cache): Rename to ...
6559 (readahead_cache::pread): ... this, and adjust to be a class
6560 method.
6561 (remote_hostio_close): Adjust.
6562
6563 2018-05-22 Pedro Alves <palves@redhat.com>
6564
6565 * remote.c (remote_hostio_close_cleanup): Delete.
6566 (class scoped_remote_fd): New.
6567 (remote_file_put, remote_file_get): Use it.
6568
6569 2018-05-22 Pedro Alves <palves@redhat.com>
6570
6571 (struct vCont_action_support): Use bool and initialize all fields.
6572 (struct readahead_cache): Initialize all fields.
6573 (remote_state): Use bool and initialize all fields.
6574 (remote_state::remote_state, remote_state::~remote_state): New.
6575 (new_remote_state): Delete.
6576 (_initialize_remote): Use new to allocate remote_state.
6577
6578 2018-05-22 Pedro Alves <palves@redhat.com>
6579 張俊芝 <zjz@zjz.name>
6580
6581 PR gdb/22973
6582 * c-exp.y: Include "c-support.h".
6583 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
6584 of tolower. Use c_ident_is_alpha to scan names.
6585 * c-lang.c: Include "c-support.h".
6586 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
6587 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
6588 * c-support.h: New file, with bits factored out from ...
6589 * cp-name-parser.y: ... this file.
6590 Include "c-support.h".
6591 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
6592 c-support.h and renamed.
6593 (symbol_end, yylex): Adjust.
6594
6595 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6596
6597 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
6598 parameter type to CORE_ADDR.
6599 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
6600 parameter type in declaration to CORE_ADDR.
6601 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
6602 target_auxv_search to get AT_HWCAP and use the result to get the
6603 target description.
6604 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
6605 to CORE_ADDR. Remove the cast of the return value to unsigned
6606 long. Fix error predicate of target_auxv_search.
6607 (ppc_linux_nat_target::read_description): Change the type of the
6608 hwcap variable to CORE_ADDR.
6609
6610 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6611
6612 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
6613 if the size of fpscr is larger than 32 bits.
6614
6615 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6616
6617 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
6618 (ppc32_linux_vsxregmap): New global.
6619 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
6620 regcache_supply_regset, and regcache_collect_regset.
6621 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
6622 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
6623 (fetch_vsx_register, store_vsx_register): Remove.
6624 (fetch_vsx_registers): Add regno parameter. Get regset using
6625 ppc_linux_vsxregset. Use regset to supply registers.
6626 (store_vsx_registers): Add regno parameter. Get regset using
6627 ppc_linux_vsxregset. Use regset to collect registers.
6628 (fetch_register): Call fetch_vsx_registers instead of
6629 fetch_vsx_register.
6630 (store_register): Call store_vsx_registers instead of
6631 store_vsx_register.
6632 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
6633 new regno parameter.
6634 (store_ppc_registers): Call store_vsx_registers with -1 for the
6635 new regno parameter.
6636 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
6637 (ppc_collect_vsxregset): Remove.
6638
6639 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6640
6641 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
6642 offset fields.
6643 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
6644 for vector register offset fields.
6645 (ppc64_fbsd_reg_offsets): Likewise.
6646 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6647 to vector register offset fields.
6648 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6649 to vector register offset fields.
6650 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
6651 vector register offset fields.
6652 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
6653 initializers for vector register offset fields.
6654 (rs6000_aix64_reg_offsets): Likewise.
6655 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
6656 (ppc_supply_vrregset): Remove.
6657 (ppc_collect_vrregset): Remove.
6658 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
6659 (ppc_linux_vrregset) : New function.
6660 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
6661 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
6662 (ppc32_linux_vrregset): Remove.
6663 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
6664 and use result instead of ppc32_linux_vrregset.
6665 (ppc32_linux_reg_offsets): Remove initializers for vector register
6666 offset fields.
6667 (ppc64_linux_reg_offsets): Likewise.
6668 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
6669 * ppc-linux-nat.c: Include regset.h.
6670 (gdb_vrregset_t): Adjust comment to account for little-endian
6671 mode.
6672 (supply_vrregset, fill_vrregset): Remove.
6673 (fetch_altivec_register, store_altivec_register): Remove.
6674 (fetch_altivec_registers): Add regno parameter. Get regset using
6675 ppc_linux_vrregset. Use regset to supply registers.
6676 (store_altivec_registers): Add regno parameter. Get regset using
6677 ppc_linux_vrregset. Use regset to collect registers.
6678 (fetch_register): Call fetch_altivec_registers instead of
6679 fetch_altivec_register.
6680 (store_register): Call store_altivec_registers instead of
6681 store_altivec_register.
6682 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
6683 the new regno parameter.
6684 (store_ppc_registers): Call store_altivec_registers with -1 for
6685 the new regno parameter.
6686
6687 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6688
6689 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
6690 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
6691 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
6692 (gdb_vrregset_t): Change array type size to
6693 PPC_LINUX_SIZEOF_VRREGSET.
6694 (gdb_vsxregset_t): Change array type size to
6695 PPC_LINUX_SIZEOF_VSXREGSET.
6696 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
6697 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
6698 PPC_LINUX_SIZEOF_VSXREGSET.
6699
6700 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6701
6702 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
6703 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
6704 nat/ppc-linux.c.
6705 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
6706 ppc_linux_target_wordsize with tid.
6707 (ppc_linux_nat_target::read_description): Call ppc_linux_target
6708 wordsize with tid.
6709 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
6710 (ppc64_64bit_inferior_p): Add static and inline specifiers.
6711 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
6712 tid parameter. Remove static specifier.
6713 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
6714 (ppc_linux_target_wordsize): New declaration.
6715
6716 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6717
6718 * arch/ppc-linux-common.c: New file.
6719 * arch/ppc-linux-common.h: New file.
6720 * arch/ppc-linux-tdesc.h: New file.
6721 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
6722 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
6723 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
6724 arch/ppc-linux-tdesc.h.
6725 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
6726 arch/ppc-linux-tdesc.h.
6727 (ppc_linux_nat_target::read_description): Remove target
6728 description matching code. Fill a ppc_linux_features struct and
6729 call ppc_linux_match_description with it. Move comment about ISA
6730 2.05 to ppc-linux-common.c.
6731 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
6732 arch/ppc-linux-tdesc.h.
6733 (ppc_linux_core_read_description): Remove target description
6734 matching code. Fill a ppc_linux_features struct and call
6735 ppc_linux_match_description with it.
6736 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
6737 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
6738 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
6739 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
6740 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
6741 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
6742 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
6743 (tdesc_powerpc_e500l): Remove.
6744
6745 2018-05-22 Joel Brobecker <brobecker@adacore.com>
6746
6747 * ada-lang.c (catch_assert_command): Pass empty string instead
6748 of NULL for excep_string argument.
6749
6750 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6751
6752 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
6753 the width of the requested register exceeds the width of the
6754 `ptrace' data type.
6755
6756 2018-05-21 Tom Tromey <tom@tromey.com>
6757
6758 * printcmd.c (output_command): Remove.
6759 (output_command_const): Rename to output_command.
6760 * valprint.h (output_command): Rename from output_command_const.
6761 * tracepoint.c (trace_dump_actions): Call output_command.
6762
6763 2018-05-21 Tom Tromey <tom@tromey.com>
6764
6765 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
6766 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
6767 * ada-lang.h (create_ada_exception_catchpoint): Update.
6768 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
6769 std::string.
6770 (create_excep_cond_exprs, ~ada_catchpoint)
6771 (should_stop_exception, print_one_exception)
6772 (print_mention_exception, print_recreate_exception): Update.
6773 (ada_get_next_arg): Remove.
6774 (catch_ada_exception_command_split): Use std::string. Change type
6775 of "excep_string", "cond_string".
6776 (catch_ada_exception_command): Update.
6777 (create_ada_exception_catchpoint): Change type of excep_string.
6778 (ada_exception_sal): Remove excep_string parameter.
6779 (~ada_catchpoint): Remove.
6780
6781 2018-05-21 Tom Tromey <tom@tromey.com>
6782
6783 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
6784 cleanup.
6785
6786 2018-05-21 Tom Tromey <tom@tromey.com>
6787
6788 * ada-lang.c (ada_exception_message_1, ada_exception_message):
6789 Return unique_xmalloc_ptr.
6790 (print_it_exception): Update.
6791
6792 2018-05-21 Tom Tromey <tom@tromey.com>
6793
6794 * tracepoint.c (trace_dump_actions): Use std::string.
6795
6796 2018-05-21 Tom Tromey <tom@tromey.com>
6797
6798 * symfile.c (reread_symbols): Use std::string for original_name.
6799
6800 2018-05-21 Tom Tromey <tom@tromey.com>
6801
6802 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
6803 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
6804 constructor.
6805
6806 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
6807
6808 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
6809 instance to...
6810 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
6811 * objfiles.c (get_objfile_bfd_data): Allocate
6812 objfile_per_bfd_storage with obstack_new when allocating on
6813 obstack.
6814
6815 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
6816
6817 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
6818 OBSTACK_ZALLOC.
6819 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
6820 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
6821 * mdebugread.c (mdebug_build_psymtabs): Likewise.
6822 (add_pending): Likewise.
6823 (parse_symbol): Likewise.
6824 (parse_partial_symbols): Likewise.
6825 (psymtab_to_symtab_1): Likewise.
6826 (new_psymtab): Likewise.
6827 (elfmdebug_build_psymtabs): Likewise.
6828 * minsyms.c (terminate_minimal_symbol_table): Likewise.
6829 * objfiles.c (get_objfile_bfd_data): Likewise.
6830 (objfile_register_static_link): Likewise.
6831 * psymtab.c (allocate_psymtab): Likewise.
6832 * stabsread.c (read_member_functions): Likewise.
6833 * xcoffread.c (xcoff_end_psymtab): Likewise.
6834
6835 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
6836
6837 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
6838 compiler supports std::is_trivially_constructible.
6839 * common/poison.h: Include obstack.h.
6840 (IsMallocable): Define to is_trivially_constructible if the
6841 compiler supports it, define to true_type otherwise.
6842 (xobnew): New.
6843 (XOBNEW): Redefine.
6844 (xobnewvec): New.
6845 (XOBNEWVEC): Redefine.
6846 * gdb_obstack.h (obstack_zalloc): New.
6847 (OBSTACK_ZALLOC): Redefine.
6848 (obstack_calloc): New.
6849 (OBSTACK_CALLOC): Redefine.
6850 (obstack_new): New.
6851 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
6852 (gdbarch_obstack): New declaration in gdbarch.h, definition in
6853 gdbarch.c.
6854 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
6855 obstack_calloc/obstack_zalloc.
6856 (gdbarch_obstack_zalloc): Remove.
6857 * target-descriptions.c (tdesc_data_init): Use obstack_new.
6858
6859 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6860
6861 * stack.c (backtrace_command_1): Remove useless variable int i.
6862
6863 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6864
6865 * stack.c (print_frame_info): Fix comment.
6866
6867 2018-05-18 Tom Tromey <tom@tromey.com>
6868
6869 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
6870 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
6871 (~dwarf2_per_objfile): Update
6872 (dwarf2_get_dwz_file): Use new.
6873 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
6874 unique_ptr.
6875
6876 2018-05-18 Tom Tromey <tom@tromey.com>
6877
6878 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
6879 unique_ptr.
6880 * dwarf2read.c (struct dwp_file): Add constructor and
6881 initializers.
6882 (open_and_init_dwp_file): Return a unique_ptr.
6883 (dwarf2_per_objfile, create_dwp_hash_table)
6884 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
6885 (lookup_dwo_unit_in_dwp): Update.
6886 (open_and_init_dwp_file, get_dwp_file): Update.
6887
6888 2018-05-18 Tom Tromey <tom@tromey.com>
6889
6890 * dwarf2read.c (dwarf2_per_objfile): Update.
6891 (struct mapped_index): Add initializers.
6892 (dwarf2_read_index): Use new.
6893 (dw2_symtab_iter_init): Update.
6894 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
6895 unique_ptr.
6896
6897 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6898
6899 * dwarf2read.c (mapped_index) <total_size>: Remove.
6900
6901 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6902
6903 * unittests/format_pieces-selftests.c (test_format_specifier):
6904 Add ARI comments.
6905
6906 2018-05-18 Tom Tromey <tom@tromey.com>
6907
6908 * c-typeprint.c (maybe_print_hole): New function.
6909 (c_print_type_struct_field_offset): Update.
6910 (c_type_print_base_struct_union): Call maybe_print_hole.
6911
6912 2018-05-17 Keith Seitz <keiths@redhat.com>
6913
6914 * breakpoint.c (build_bpstat_chain): New function, moved from
6915 bpstat_stop_status.
6916 (bpstat_stop_status): Add optional parameter, `stop_chain'.
6917 If no stop chain is passed, call build_bpstat_chain to build it.
6918 * breakpoint.h (build_bpstat_chain): Declare.
6919 (bpstat_stop_status): Move documentation here from breakpoint.c.
6920 * infrun.c (handle_signal_stop): Before eliding inlined frames,
6921 build the stop chain and pass it to skip_inline_frames.
6922 Pass this stop chain to bpstat_stop_status.
6923 * inline-frame.c: Include breakpoint.h.
6924 (stopped_by_user_bp_inline_frame): New function.
6925 (skip_inline_frames): Add parameter `stop_chain'.
6926 Move documention to inline-frame.h.
6927 If non-NULL, use stopped_by_user_bp_inline_frame to determine
6928 whether the frame should be elided.
6929 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
6930 Add moved documentation and update for new parameter.
6931
6932 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
6933
6934 PR cli/14975
6935 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6936 unittests/format_pieces-selftests.c.
6937 * common/format.h (format_piece) <operator==>: New.
6938 (format_pieces) <operator[]>: Remove.
6939 * common/format.c (format_pieces::format_pieces): Handle \e.
6940 * unittests/format_pieces-selftests.c: New.
6941
6942 2018-05-17 Tom Tromey <tom@tromey.com>
6943
6944 PR symtab/23010:
6945 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
6946 (dw2_instantiate_symtab): Add skip_partial parameter.
6947 (dw2_find_last_source_symtab, dw2_map_expand_apply)
6948 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
6949 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
6950 (dw2_expand_symtabs_matching_one)
6951 (dw2_find_pc_sect_compunit_symtab)
6952 (dw2_debug_names_lookup_symbol)
6953 (dw2_debug_names_expand_symtabs_for_function): Update.
6954 (init_cutu_and_read_dies): Add skip_partial parameter.
6955 (process_psymtab_comp_unit, build_type_psymtabs_1)
6956 (process_skeletonless_type_unit, load_partial_comp_unit)
6957 (psymtab_to_symtab_1): Update.
6958 (load_full_comp_unit): Add skip_partial parameter.
6959 (process_imported_unit_die, dwarf2_read_addr_index)
6960 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
6961 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
6962 (read_signatured_type): Update.
6963
6964 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
6965
6966 * value.c (release_value): Remove unused variable.
6967 (record_latest_value): Likewise.
6968 (access_value_history): Likewise.
6969 (preserve_values): Likewise.
6970
6971 2018-05-17 Tom Tromey <tom@tromey.com>
6972
6973 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
6974 Initialize.
6975
6976 2018-05-16 Maciej W. Rozycki <macro@mips.com>
6977
6978 PR gdb/22286
6979 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
6980 Also handle registers whose width is not a multiple of
6981 PTRACE_TYPE_RET.
6982 (linux_nat_trad_target::store_register): Likewise.
6983
6984 2018-05-16 Tom Tromey <tom@tromey.com>
6985
6986 * gdbcore.h (core_bfd): Redefine.
6987 * corelow.c (core_target::close): Update.
6988 (core_target_open): Update.
6989 * progspace.h (struct program_space) <cbfd>: Now a
6990 gdb_bfd_ref_ptr.
6991
6992 2018-05-16 Tom Tromey <tom@tromey.com>
6993
6994 PR cli/19551:
6995 * symfile-add-flags.h (enum symfile_add_flags)
6996 <SYMFILE_NOT_FILENAME>: New constant.
6997 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
6998 objfile name from BFD.
6999 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
7000 * minidebug.c (find_separate_debug_file_in_section): Put
7001 ".gnu_debugdata" into BFD's file name.
7002
7003 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
7004
7005 * regcache.c (regcache_read_ftype, regcache_write_ftype):
7006 Remove.
7007
7008 2018-05-15 Tamar Christina <tamar.christina@arm.com>
7009
7010 PR binutils/21446
7011 * aarch64-tdep.c (aarch64_analyze_prologue,
7012 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
7013 Indicate not interested in errors.
7014
7015 2018-05-15 Maciej W. Rozycki <macro@mips.com>
7016
7017 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
7018 Supply the MIPS_ZERO_REGNUM register.
7019
7020 2018-05-15 Maciej W. Rozycki <macro@mips.com>
7021
7022 * mips-tdep.c (mask_address_var): Make variable static.
7023
7024 2018-05-14 Tom Tromey <tom@tromey.com>
7025
7026 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
7027
7028 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
7029
7030 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
7031 FXSAVE_ADDR for the mxcsr register.
7032
7033 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
7034
7035 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
7036
7037 2018-05-11 Pedro Alves <palves@redhat.com>
7038
7039 * corelow.c (core_target) <core_target>: No longer inline.
7040 Initialize m_core_gdbarch, m_core_vec and build the section table
7041 here.
7042 <~core_target>: New.
7043 <core_gdbarch, get_core_register_section>: New methods.
7044 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
7045 factored out from ...
7046 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
7047 (core_ops): Delete.
7048 (sniff_core_bfd): Add gdbarch parameter.
7049 (core_close): Delete, merged into ...
7050 (core_target::close): ... here. Delete self.
7051 (core_close_cleanup): Delete.
7052 (core_target_open): Allocate a core_target on the heap. Use a
7053 unique_ptr instead of a cleanup. Bits moved into the core_target
7054 ctor. Adjust to use core_target methods instead of globals.
7055 (get_core_register_section): Rename to ...
7056 (core_target::get_core_register_section): ... this and adjust.
7057 (struct get_core_registers_cb_data): New.
7058 (get_core_registers_cb): Use it. Use bool.
7059 (core_target::fetch_registers, core_target::files_info)
7060 (core_target::xfer_partial, core_target::read_description)
7061 (core_target::pid_to, core_target::thread_name): Adjust to
7062 reference class fields instead of globals.
7063 * target.h (struct target_ops_deleter, target_ops_up): New.
7064
7065 2018-05-11 Pedro Alves <palves@redhat.com>
7066
7067 * corefile.c (core_file_command): Move to corelow.c.
7068 * corelow.c (the_core_target): Delete.
7069 (core_file_command): Moved from corefile.c. Check exec_bfd
7070 instead of the_core_target. Use target_detach instead of calling
7071 into the_core_target directly.
7072 (maybe_say_no_core_file_now): New.
7073 (core_target::detach): Use it.
7074 (_initialize_corelow): Remove references to the_core_target.
7075 * gdbcore.h (the_core_target): Delete.
7076
7077 2018-05-11 Tom Tromey <tromey@redhat.com>
7078 Pedro Alves <palves@redhat.com>
7079
7080 * corefile.c (core_bfd): Remove.
7081 * gdbcore.h (core_bfd): Now a macro.
7082 * progspace.h (struct program_space) <cbfd>: New field.
7083
7084 2018-05-11 Tom Tromey <tom@tromey.com>
7085
7086 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
7087 gdb::def_vector.
7088
7089 2018-05-10 Tom Tromey <tom@tromey.com>
7090
7091 * configure: Rebuild.
7092 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
7093
7094 2018-05-10 Joel Brobecker <brobecker@adacore.com>
7095
7096 PR server/23158:
7097 * regformats/regdat.sh: Adjust script, following the addition
7098 of the new expedite_regs parameter to init_target_desc.
7099
7100 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
7101
7102 PR gdb/23127
7103 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
7104 set_gdbarch_significant_addr_bit.
7105 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
7106 set_gdbarch_significant_addr_bit.
7107 * utils.c (address_significant): Update to sign extend addr.
7108
7109 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
7110
7111 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
7112 (xtensa_linux_init_abi): Limit tdep->num_regs by
7113 tdep->num_nopriv_regs.
7114 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
7115 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
7116 not initialized.
7117
7118 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
7119
7120 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
7121
7122 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
7123
7124 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
7125 (I387_MXCSR_INIT_VAL): New constant.
7126 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
7127 buffer if it was supplied by the inferior.
7128 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
7129 (i387_xsave_get_clear_bv): New function.
7130 (i387_supply_xsave): Only read x87 control registers from the
7131 xsave buffer if the feature is enabled, and the state will have
7132 been written, otherwise, provide a suitable default.
7133 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
7134 including x87 control registers. Update control registers if they
7135 have changed from the default value, and mark features as enabled
7136 as required.
7137 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
7138
7139 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
7140
7141 * spu-tdep.c (info_spu_event_command): Fix output formatting.
7142
7143 2018-05-07 Tom Tromey <tom@tromey.com>
7144
7145 * configure: Rebuild.
7146 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
7147
7148 2018-05-07 Tom Tromey <tom@tromey.com>
7149
7150 PR tdep/20362:
7151 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
7152 bit. Use correct value for VDIV.
7153
7154 2018-05-04 Tom Tromey <tom@tromey.com>
7155
7156 * configure: Rebuild.
7157 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
7158
7159 2018-05-04 Tom Tromey <tom@tromey.com>
7160
7161 * linux-record.c (record_linux_system_call) <case
7162 RECORD_SYS_RECVFROM>: Add "break".
7163
7164 2018-05-04 Tom Tromey <tom@tromey.com>
7165
7166 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
7167 Add missing "break".
7168 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
7169 Add missing "break".
7170
7171 2018-05-04 Tom Tromey <tom@tromey.com>
7172
7173 * rs6000-tdep.c (ppc_process_record_op4)
7174 (ppc_process_record_op63): Add fall-through comment.
7175
7176 2018-05-04 Tom Tromey <tom@tromey.com>
7177
7178 * i386-tdep.c (i386_process_record): Add fall-through comment.
7179
7180 2018-05-04 Tom Tromey <tom@tromey.com>
7181
7182 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
7183 comment.
7184
7185 2018-05-04 Tom Tromey <tom@tromey.com>
7186
7187 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
7188 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
7189 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
7190 comment.
7191 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
7192 comment.
7193 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
7194 comment.
7195
7196 2018-05-04 Tom Tromey <tom@tromey.com>
7197
7198 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
7199
7200 2018-05-04 Tom Tromey <tom@tromey.com>
7201
7202 * s390-tdep.c (s390_process_record): Fix fall-through comments.
7203 * xcoffread.c (scan_xcoff_symtab): Move comment later.
7204 * symfile.c (section_is_mapped): Fix fall-through comment.
7205 * stabsread.c (define_symbol, read_member_functions): Fix
7206 fall-through comment.
7207 * s390-linux-tdep.c (s390_process_record): Fix fall-through
7208 comment.
7209 * remote.c (remote_wait_as): Fix fall-through comment.
7210 * p-exp.y (yylex): Fix fall-through comment.
7211 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
7212 comment.
7213 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
7214 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
7215 * jv-exp.y (yylex): Fix fall-through comment.
7216 * go-exp.y (lex_one_token): Fix fall-through comment.
7217 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
7218 fall-through comment.
7219 * f-exp.y (yylex): Fix fall-through comment.
7220 * dwarf2read.c (process_die): Fix fall-through comments.
7221 * dbxread.c (process_one_symbol): Fix fall-through comment.
7222 * d-exp.y (lex_one_token): Fix fall-through comment.
7223 * cp-name-parser.y (yylex): Fix fall-through comment.
7224 * coffread.c (coff_symtab_read): Fix fall-through comment.
7225 * c-exp.y (lex_one_token): Fix fall-through comment.
7226 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
7227 comment.
7228 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
7229 comment.
7230
7231 2018-05-04 Tom Tromey <tom@tromey.com>
7232
7233 PR python/22730:
7234 * NEWS: Mention gdb.execute change.
7235 * gdbcmd.h (execute_control_command): Don't declare.
7236 * python/python.c (execute_gdb_command): Use read_command_lines_1,
7237 execute_control_commands, execute_control_commands_to_string.
7238 * cli/cli-script.h (execute_control_commands)
7239 (execute_control_commands_to_string): Declare.
7240 (execute_control_command): Add from_tty parameter.
7241 * cli/cli-script.c (execute_control_commands)
7242 (execute_control_commands_to_string): New functions.
7243 (execute_user_command): Use execute_control_commands.
7244 (execute_control_command_1): Add "from_tty" parameter. Update.
7245 (execute_control_command): Likewise.
7246
7247 2018-05-04 Tom Tromey <tom@tromey.com>
7248
7249 PR python/22731:
7250 * NEWS: Mention that breakpoint commands are writable.
7251 * python/py-breakpoint.c (bppy_set_commands): New function.
7252 (breakpoint_object_getset) <"commands">: Use it.
7253
7254 2018-05-04 Tom Tromey <tom@tromey.com>
7255
7256 * tracepoint.c (actions_command): Update.
7257 * mi/mi-cmd-break.c (mi_command_line_array)
7258 (mi_command_line_array_cnt, mi_command_line_array_ptr)
7259 (mi_read_next_line): Remove.
7260 (mi_cmd_break_commands): Update.
7261 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
7262 function_view.
7263 * cli/cli-script.c (get_command_line): Update.
7264 (process_next_line): Use function_view. Constify.
7265 (recurse_read_control_structure, read_command_lines)
7266 (read_command_lines_1): Change argument types to function_view.
7267 (do_define_command, document_command): Update.
7268 * breakpoint.h (check_tracepoint_command): Don't declare.
7269 * breakpoint.c (check_tracepoint_command): Remove.
7270 (commands_command_1, create_tracepoint_from_upload): Update.
7271
7272 2018-05-04 Tom Tromey <tom@tromey.com>
7273
7274 PR gdb/11750:
7275 * cli/cli-script.h (enum command_control_type) <define_control>:
7276 New constant.
7277 * cli/cli-script.c (multi_line_command_p): Handle define_control.
7278 (build_command_line, execute_control_command_1)
7279 (process_next_line): Likewise.
7280 (do_define_command): New function, extracted from define_command.
7281 (define_command): Use it.
7282
7283 2018-05-04 Tom Tromey <tom@tromey.com>
7284
7285 * tracepoint.c (actions_command): Update.
7286 * cli/cli-script.h (read_command_lines): Update.
7287 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
7288 (MAX_TMPBUF): Remove define.
7289 (define_command): Use string_printf.
7290 (document_command): Likewise.
7291 * breakpoint.c (commands_command_1): Update.
7292
7293 2018-05-04 Tom Tromey <tom@tromey.com>
7294
7295 * top.c (execute_command): Update.
7296 * cli/cli-script.h (print_command_lines): Now varargs.
7297 * cli/cli-script.c (print_command_lines): Now varargs.
7298 (execute_control_command_1) <case while_control, case if_control>:
7299 Update.
7300
7301 2018-05-04 Tom Tromey <tom@tromey.com>
7302
7303 * tracepoint.c (all_tracepoint_actions): Rename from
7304 all_tracepoint_actions_and_cleanup. Change return type.
7305 (actions_command, encode_actions_1, encode_actions)
7306 (trace_dump_actions, tdump_command): Update.
7307 * remote.c (remote_download_command_source): Update.
7308 * python/python.c (gdbpy_eval_from_control_command)
7309 (python_command, python_interactive_command): Update.
7310 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
7311 * guile/guile.c (guile_command)
7312 (gdbscm_eval_from_control_command, guile_command): Update.
7313 * compile/compile.c (compile_code_command)
7314 (compile_print_command, compile_to_object): Update.
7315 * cli/cli-script.h (struct command_lines_deleter): New.
7316 (counted_command_line): New typedef.
7317 (struct command_line): Add constructor, destructor.
7318 <body_list>: Remove.
7319 <body_list_0, body_list_1>: New members.
7320 (command_line_up): Remove typedef.
7321 (read_command_lines, read_command_lines_1, get_command_line):
7322 Update.
7323 (copy_command_lines): Don't declare.
7324 * cli/cli-script.c (build_command_line): Use "new".
7325 (get_command_line): Return counted_command_line.
7326 (print_command_lines, execute_user_command)
7327 (execute_control_command_1, while_command, if_command): Update.
7328 (realloc_body_list): Remove.
7329 (process_next_line, recurse_read_control_structure): Update.
7330 (read_command_lines, read_command_lines_1): Return counted_command_line.
7331 (free_command_lines): Use "delete".
7332 (copy_command_lines): Remove.
7333 (define_command, document_command, show_user_1): Update.
7334 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
7335 a counted_command_line.
7336 * breakpoint.h (counted_command_line): Remove typedef.
7337 (breakpoint_set_commands): Update.
7338 * breakpoint.c (check_no_tracepoint_commands)
7339 (validate_commands_for_breakpoint): Update.
7340 (breakpoint_set_commands): Change commands to be a
7341 counted_command_line.
7342 (commands_command_1, update_dprintf_command_list)
7343 (create_tracepoint_from_upload): Update.
7344
7345 2018-05-04 Tom Tromey <tom@tromey.com>
7346
7347 * cli/cli-decode.h (cmd_list_element): New constructor.
7348 (~cmd_list_element): New destructor.
7349 (struct cmd_list_element): Add initializers.
7350 * cli/cli-decode.c (do_add_cmd): Use "new".
7351 (delete_cmd): Use "delete".
7352
7353 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
7354 Pedro Alves <palves@redhat.com>
7355
7356 PR breakpoints/19806 and support for PR external/20207.
7357 * NEWS: Mention Aarch64 watchpoint improvements.
7358 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
7359 watchpoints and PR external/20207 watchpoints.
7360 * nat/aarch64-linux-hw-point.c
7361 (kernel_supports_any_contiguous_range): New.
7362 (aarch64_watchpoint_offset): New.
7363 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
7364 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
7365 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
7366 (aarch64_align_watchpoint): New parameters aligned_offset_p and
7367 next_addr_orig_p. Support PR external/20207 watchpoints.
7368 (aarch64_downgrade_regs): New.
7369 (aarch64_dr_state_insert_one_point): New parameters offset and
7370 addr_orig.
7371 (aarch64_dr_state_remove_one_point): Likewise.
7372 (aarch64_handle_breakpoint): Update caller.
7373 (aarch64_handle_aligned_watchpoint): Likewise.
7374 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
7375 aligned_offset.
7376 (aarch64_linux_set_debug_regs): Remove const from state. Call
7377 aarch64_downgrade_regs.
7378 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
7379 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
7380 (DR_CONTROL_MASK): ... this.
7381 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
7382 (unsigned int aarch64_watchpoint_offset): New prototype.
7383 (aarch64_linux_set_debug_regs): Remove const from state.
7384 * utils.c (align_up, align_down): Move to ...
7385 * common/common-utils.c (align_up, align_down): ... here.
7386 * utils.h (align_up, align_down): Move to ...
7387 * common/common-utils.h (align_up, align_down): ... here.
7388
7389 2018-05-04 Joel Brobecker <brobecker@adacore.com>
7390
7391 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
7392 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
7393 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
7394 Re-implement to match the ABI as summarized in GCC's
7395 gcc/config/sparc/sparc.c. All callers updated.
7396 (sparc32_store_arguments): Remove assertion.
7397
7398 2018-05-04 Tom Tromey <tom@tromey.com>
7399
7400 * printcmd.c: Don't include tui.h.
7401 (decode_format): Use skip_spaces.
7402
7403 2018-05-04 Tom Tromey <tom@tromey.com>
7404
7405 PR gdb/22619:
7406 * printcmd.c (last_count): New global.
7407 (x_command): Use saved count when repeating.
7408
7409 2018-05-04 Tom Tromey <tom@tromey.com>
7410
7411 * nto-procfs.c (do_closedir_cleanup): Remove.
7412 (procfs_pidlist): Use gdb_dir_up.
7413 * procfs.c (do_closedir_cleanup): Remove.
7414 (proc_update_threads): Use gdb_dir_up.
7415 * common/filestuff.h (struct gdb_dir_deleter): New.
7416 (gdb_dir_up): New typedef.
7417
7418 2018-05-04 Tom Tromey <tom@tromey.com>
7419
7420 * ada-lang.c (print_mention_exception): Use std::string.
7421
7422 2018-05-04 Tom Tromey <tom@tromey.com>
7423
7424 * ada-lang.c (create_excep_cond_exprs): Update.
7425 (ada_exception_catchpoint_cond_string): Use std::string.
7426
7427 2018-05-04 Tom Tromey <tom@tromey.com>
7428
7429 * ada-lang.c (xget_renaming_scope): Return std::string.
7430 (old_renaming_is_invisible): Update.
7431
7432 2018-05-04 Tom Tromey <tom@tromey.com>
7433
7434 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
7435 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
7436
7437 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
7438
7439 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
7440
7441 2018-05-04 Tom Tromey <tom@tromey.com>
7442
7443 * remote.c (remote_query_supported_append): Change type.
7444 (remote_check_symbols): Update.
7445
7446 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
7447
7448 PR gdb/11420
7449 * configure.ac: Prepend libpython.
7450 * python/python-config.py: Likewise.
7451 * configure: Regenerate.
7452
7453 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
7454
7455 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
7456
7457 2018-05-03 Pedro Alves <palves@redhat.com>
7458
7459 * s390-linux-nat.c
7460 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
7461 override. Write 'true' instead of '1'.
7462 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
7463 declaration.
7464
7465 2018-05-02 Pedro Alves <palves@redhat.com>
7466
7467 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
7468 add_inf_child_target.
7469 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
7470 add_inf_child_target.
7471 * aix-thread.c (aix_thread_target_info): New.
7472 (aix_thread_target) <shortname, longname, doc>: Delete.
7473 <info>: New.
7474 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
7475 add_inf_child_target.
7476 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
7477 add_inf_child_target.
7478 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
7479 add_inf_child_target.
7480 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
7481 add_inf_child_target.
7482 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
7483 add_inf_child_target.
7484 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
7485 add_inf_child_target.
7486 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
7487 add_inf_child_target.
7488 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
7489 add_inf_child_target.
7490 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
7491 add_inf_child_target.
7492 * bfd-target.c (target_bfd_target_info): New.
7493 (target_bfd) <shortname, longname, doc>: Delete.
7494 <info>: New.
7495 * bsd-kvm.c (bsd_kvm_target_info): New.
7496 (bsd_kvm_target) <shortname, longname, doc>: Delete.
7497 <info>: New.
7498 (bsd_kvm_target::open): Rename to ...
7499 (bsd_kvm_target_open): ... this. Adjust.
7500 * bsd-uthread.c (bsd_uthread_target_info): New.
7501 (bsd_uthread_target) <shortname, longname, doc>: Delete.
7502 <info>: New.
7503 * corefile.c (core_file_command): Adjust.
7504 * corelow.c (core_target_info): New.
7505 (core_target) <shortname, longname, doc>: Delete.
7506 <info>: New.
7507 (core_target::open): Rename to ...
7508 (core_target_open): ... this. Adjust.
7509 * ctf.c (ctf_target_info): New.
7510 (ctf_target) <shortname, longname, doc>: Delete.
7511 <info>: New.
7512 (ctf_target::open): Rename to ...
7513 (ctf_target_open): ... this.
7514 (_initialize_ctf): Adjust.
7515 * exec.c (exec_target_info): New.
7516 (exec_target) <shortname, longname, doc>: Delete.
7517 <info>: New.
7518 (exec_target::open): Rename to ...
7519 (exec_target_open): ... this.
7520 * gdbcore.h (core_target_open): Declare.
7521 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
7522 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
7523 add_inf_child_target.
7524 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
7525 add_inf_child_target.
7526 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
7527 add_inf_child_target.
7528 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
7529 add_inf_child_target.
7530 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
7531 add_inf_child_target.
7532 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
7533 add_inf_child_target.
7534 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
7535 add_inf_child_target.
7536 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
7537 add_inf_child_target.
7538 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
7539 add_inf_child_target.
7540 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
7541 add_inf_child_target.
7542 * inf-child.c (inf_child_target_info): New.
7543 (inf_child_target::info): New.
7544 (inf_child_open_target): Remove 'target' parameter. Use
7545 get_native_target instead.
7546 (inf_child_target::open): Delete.
7547 (add_inf_child_target): New.
7548 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
7549 Delete.
7550 <info>: New.
7551 (add_inf_child_target): Declare.
7552 (inf_child_open_target): Declare.
7553 * linux-thread-db.c (thread_db_target_info): New.
7554 (thread_db_target) <shortname, longname, doc>: Delete.
7555 <info>: New.
7556 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
7557 add_inf_child_target.
7558 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
7559 add_inf_child_target.
7560 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
7561 add_inf_child_target.
7562 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
7563 add_inf_child_target.
7564 * make-target-delegates (print_class): Adjust.
7565 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
7566 add_inf_child_target.
7567 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
7568 add_inf_child_target.
7569 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
7570 add_inf_child_target.
7571 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
7572 add_inf_child_target.
7573 * nto-procfs.c (nto_native_target_info): New.
7574 (nto_procfs_target_native) <shortname, longname, doc>:
7575 Delete.
7576 <info>: New.
7577 (nto_procfs_target_info): New.
7578 (nto_procfs_target_procfs) <shortname, longname, doc>:
7579 Delete.
7580 <info>: New.
7581 (init_procfs_targets): Adjust.
7582 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
7583 add_inf_child_target.
7584 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
7585 add_inf_child_target.
7586 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
7587 add_inf_child_target.
7588 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
7589 add_inf_child_target.
7590 * ravenscar-thread.c (ravenscar_target_info): New.
7591 (ravenscar_thread_target) <shortname, longname, doc>:
7592 Delete.
7593 <info>: New.
7594 * record-btrace.c (record_btrace_target_info):
7595 (record_btrace_target) <shortname, longname, doc>: Delete.
7596 <info>: New.
7597 (record_btrace_target::open): Rename to ...
7598 (record_btrace_target_open): ... this. Adjust.
7599 * record-full.c (record_longname, record_doc): New.
7600 (record_full_base_target) <shortname, longname, doc>: Delete.
7601 <info>: New.
7602 (record_full_target_info): New.
7603 (record_full_target): <shortname>: Delete.
7604 <info>: New.
7605 (record_full_core_open_1, record_full_open_1): Update comments.
7606 (record_full_base_target::open): Rename to ...
7607 (record_full_open): ... this.
7608 (cmd_record_full_restore): Update.
7609 (_initialize_record_full): Update.
7610 * remote-sim.c (remote_sim_target_info): New.
7611 (gdbsim_target) <shortname, longname, doc>: Delete.
7612 <info>: New.
7613 (gdbsim_target::open): Rename to ...
7614 (gdbsim_target_open): ... this.
7615 (_initialize_remote_sim): Adjust.
7616 * remote.c (remote_doc): New.
7617 (remote_target_info): New.
7618 (remote_target) <shortname, longname, doc>: Delete.
7619 <info>: New.
7620 (extended_remote_target_info): New.
7621 (extended_remote_target) <shortname, longname, doc>: Delete.
7622 <info>: New.
7623 (remote_target::open_1): Make static. Adjust.
7624 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
7625 * s390-linux-nat.c (_initialize_s390_nat): Use
7626 add_inf_child_target.
7627 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
7628 add_inf_child_target.
7629 * sol-thread.c (thread_db_target_info): New.
7630 (sol_thread_target) <shortname, longname, doc>: Delete.
7631 <info>: New.
7632 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
7633 add_inf_child_target.
7634 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
7635 add_inf_child_target.
7636 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
7637 add_inf_child_target.
7638 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
7639 add_inf_child_target.
7640 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
7641 add_inf_child_target.
7642 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
7643 add_inf_child_target.
7644 * spu-linux-nat.c (_initialize_spu_nat): Use
7645 add_inf_child_target.
7646 * spu-multiarch.c (spu_multiarch_target_info): New.
7647 (spu_multiarch_target) <shortname, longname, doc>: Delete.
7648 <info>: New.
7649 * target-delegates.c: Regenerate.
7650 * target.c: Include <unordered_map>.
7651 (target_ops_p): Delete.
7652 (DEF_VEC_P(target_ops_p)): Delete.
7653 (target_factories): New.
7654 (test_target_info): New.
7655 (test_target_ops::info): New.
7656 (open_target): Adjust to use target_factories.
7657 (add_target_with_completer): Rename to ...
7658 (add_target): ... this. Change prototype. Register target_info
7659 and open callback in target_factories. Register target_info in
7660 command context instead of target_ops.
7661 (add_target): Delete old implementation.
7662 (add_deprecated_target_alias): Change prototype. Adjust.
7663 (the_native_target): New.
7664 (set_native_target, get_native_target): New.
7665 (find_default_run_target): Use the_native_target.
7666 (find_attach_target, find_run_target): Simplify.
7667 (target_ops::open): Delete.
7668 (dummy_target_info): New.
7669 (dummy_target::shortname, dummy_target::longname)
7670 (dummy_target::doc): Delete.
7671 (dummy_target::info): New.
7672 (debug_target::shortname, debug_target::longname)
7673 (debug_target::doc): Delete.
7674 (debug_target::info): New.
7675 * target.h (struct target_info): New.
7676 (target_ops::~target_ops): Add comment.
7677 (target_ops::info): New.
7678 (target_ops::shortname, target_ops::longname, target_ops::doc): No
7679 longer virtual. Implement in terms of target_info.
7680 (set_native_target, get_native_target): Declare.
7681 (target_open_ftype): New.
7682 (add_target, add_target_with_completer)
7683 (add_deprecated_target_alias): Change prototype.
7684 (test_target) <shortname, longname, doc>: Delete.
7685 <info>: New.
7686 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
7687 add_inf_child_target.
7688 * tracefile-tfile.c (tfile_target_info): New.
7689 (tfile_target) <shortname, longname, doc>: Delete.
7690 <info>: New.
7691 (tfile_target::open): Rename to ...
7692 (tfile_target_open): ... this.
7693 (_initialize_tracefile_tfile): Adjust.
7694 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
7695 add_inf_child_target.
7696 * windows-nat.c (_initialize_windows_nat): Use
7697 add_inf_child_target.
7698 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
7699 add_inf_child_target.
7700
7701 2018-05-02 Pedro Alves <palves@redhat.com>
7702
7703 * linux-nat.h (linux_nat_target) <low_new_thread,
7704 low_delete_thread, low_new_fork, low_forget_process,
7705 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
7706 New virtual methods.
7707 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7708 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
7709 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
7710 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7711 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
7712 Delete.
7713 * linux-fork.c (delete_fork): Adjust to call low method.
7714 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
7715 (linux_nat_new_fork, linux_nat_forget_process_hook)
7716 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
7717 (linux_nat_status_is_event):
7718 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
7719 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
7720 to call low method.
7721 (sigtrap_is_event): Rename to ...
7722 (linux_nat_target::low_status_is_event): ... this.
7723 (linux_nat_set_status_is_event): Delete.
7724 (save_stop_reason, linux_nat_wait_1)
7725 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
7726 low methods.
7727 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7728 (linux_nat_set_new_fork, linux_nat_set_forget_process)
7729 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7730 (linux_nat_set_prepare_to_resume): Delete.
7731 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
7732 low virtual methods.
7733 * amd64-linux-nat.c: Likewise.
7734 * arm-linux-nat.c: Likewise.
7735 * i386-linux-nat.c: Likewise.
7736 * ia64-linux-nat.c: Likewise.
7737 * mips-linux-nat.c: Likewise.
7738 * ppc-linux-nat.c: Likewise.
7739 * s390-linux-nat.c: Likewise.
7740 * sparc64-linux-nat.c: Likewise.
7741 * x86-linux-nat.c: Likewise.
7742 * x86-linux-nat.h: Include "nat/x86-linux.h".
7743 (x86_linux_nat_target) <low_new_fork, low_forget_process,
7744 low_prepare_to_resume, low_new_thread, low_delete_thread>:
7745 Override methods.
7746
7747 2018-05-02 Pedro Alves <palves@redhat.com>
7748
7749 * target.h (target_ops)
7750 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
7751 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
7752 stopped_by_watchpoint, have_continuable_watchpoint,
7753 stopped_data_address, watchpoint_addr_within_range,
7754 can_accel_watchpoint_condition, can_run, thread_alive,
7755 has_all_memory, has_memory, has_stack, has_registers,
7756 has_execution, can_async_p, is_async_p, supports_non_stop,
7757 always_non_stop_p, can_execute_reverse, supports_multi_process,
7758 supports_enable_disable_tracepoint,
7759 supports_disable_randomization, supports_string_tracing,
7760 supports_evaluation_of_breakpoint_conditions,
7761 can_run_breakpoint_commands, filesystem_is_local,
7762 can_download_tracepoint, get_trace_state_variable_value,
7763 set_trace_notes, get_tib_address, use_agent, can_use_agent,
7764 record_is_replaying, record_will_replay,
7765 augmented_libraries_svr4_read>: Adjust to return bool.
7766 * aarch64-linux-nat.c: All implementations adjusted.
7767 * aix-thread.c: All implementations adjusted.
7768 * arm-linux-nat.c: All implementations adjusted.
7769 * breakpoint.c: All implementations adjusted.
7770 * bsd-kvm.c: All implementations adjusted.
7771 * bsd-uthread.c: All implementations adjusted.
7772 * corelow.c: All implementations adjusted.
7773 * ctf.c: All implementations adjusted.
7774 * darwin-nat.c: All implementations adjusted.
7775 * darwin-nat.h: All implementations adjusted.
7776 * exec.c: All implementations adjusted.
7777 * fbsd-nat.c: All implementations adjusted.
7778 * fbsd-nat.h: All implementations adjusted.
7779 * gnu-nat.c: All implementations adjusted.
7780 * gnu-nat.h: All implementations adjusted.
7781 * go32-nat.c: All implementations adjusted.
7782 * ia64-linux-nat.c: All implementations adjusted.
7783 * inf-child.c: All implementations adjusted.
7784 * inf-child.h: All implementations adjusted.
7785 * inf-ptrace.c: All implementations adjusted.
7786 * inf-ptrace.h: All implementations adjusted.
7787 * linux-nat.c: All implementations adjusted.
7788 * linux-nat.h: All implementations adjusted.
7789 * mips-linux-nat.c: All implementations adjusted.
7790 * nto-procfs.c: All implementations adjusted.
7791 * ppc-linux-nat.c: All implementations adjusted.
7792 * procfs.c: All implementations adjusted.
7793 * ravenscar-thread.c: All implementations adjusted.
7794 * record-btrace.c: All implementations adjusted.
7795 * record-full.c: All implementations adjusted.
7796 * remote-sim.c: All implementations adjusted.
7797 * remote.c: All implementations adjusted.
7798 * s390-linux-nat.c: All implementations adjusted.
7799 * sol-thread.c: All implementations adjusted.
7800 * spu-multiarch.c: All implementations adjusted.
7801 * target-delegates.c: All implementations adjusted.
7802 * target.c: All implementations adjusted.
7803 * target.h: All implementations adjusted.
7804 * tracefile-tfile.c: All implementations adjusted.
7805 * tracefile.c: All implementations adjusted.
7806 * tracefile.h: All implementations adjusted.
7807 * windows-nat.c: All implementations adjusted.
7808 * x86-linux-nat.h: All implementations adjusted.
7809 * x86-nat.h: All implementations adjusted.
7810
7811 2018-05-02 Pedro Alves <palves@redhat.com>
7812
7813 * make-target-delegates (scan_target_h): Don't trim lines here.
7814 Replace sequences of tabs and/or whitespace with a single
7815 whitespace.
7816 (top level, parsing methods): Trim each line before processing it
7817 here.
7818
7819 2018-05-02 Pedro Alves <palves@redhat.com>
7820 John Baldwin <jhb@freebsd.org>
7821
7822 * target.h (enum strata) <debug_stratum>: New.
7823 (struct target_ops) <all delegation methods>: Replace by C++
7824 virtual methods, and drop "to_" prefix. All references updated
7825 throughout.
7826 <to_shortname, to_longname, to_doc, to_data,
7827 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
7828 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
7829 virtual methods. All references updated throughout.
7830 <can_attach, supports_terminal_ours, can_create_inferior,
7831 get_thread_control_capabilities, attach_no_wait>: New
7832 virtual methods.
7833 <insert_breakpoint, remove_breakpoint>: Now
7834 TARGET_DEFAULT_NORETURN methods.
7835 <info_proc>: Now returns bool.
7836 <to_magic>: Delete.
7837 (OPS_MAGIC): Delete.
7838 (current_target): Delete. All references replaced by references
7839 to ...
7840 (target_stack): ... this. New.
7841 (target_shortname, target_longname): Adjust.
7842 (target_can_run): Now a function declaration.
7843 (default_child_has_all_memory, default_child_has_memory)
7844 (default_child_has_stack, default_child_has_registers)
7845 (default_child_has_execution): Remove target_ops parameter.
7846 (complete_target_initialization): Delete.
7847 (memory_breakpoint_target): New template class.
7848 (test_target_ops): Refactor as a C++ class with virtual methods.
7849 * make-target-delegates (NAME_PART): Tighten.
7850 (POINTER_PART, CP_SYMBOL): New.
7851 (SIMPLE_RETURN_PART): Reimplement.
7852 (VEC_RETURN_PART): Expect less.
7853 (RETURN_PART, VIRTUAL_PART): New.
7854 (METHOD): Adjust to C++ virtual methods.
7855 (scan_target_h): Remove reference to C99.
7856 (dname): Output "target_ops::" prefix.
7857 (write_function_header): Adjust to output a C++ class method.
7858 (write_declaration): New.
7859 (write_delegator): Adjust to output a C++ class method.
7860 (tdname): Output "dummy_target::" prefix.
7861 (write_tdefault, write_debugmethod): Adjust to output a C++ class
7862 method.
7863 (tdefault_names, debug_names): Delete.
7864 (return_types, tdefaults, styles, argtypes_array): New.
7865 (top level): All methods are delegators.
7866 (print_class): New.
7867 (top level): Print dummy_target and debug_target classes.
7868 * target-delegates.c: Regenerate.
7869 * target-debug.h (target_debug_print_enum_info_proc_what)
7870 (target_debug_print_thread_control_capabilities)
7871 (target_debug_print_thread_info_p): New.
7872 * target.c (dummy_target): Delete.
7873 (the_dummy_target, the_debug_target): New.
7874 (target_stack): Now extern.
7875 (set_targetdebug): Push/unpush debug target.
7876 (default_child_has_all_memory, default_child_has_memory)
7877 (default_child_has_stack, default_child_has_registers)
7878 (default_child_has_execution): Remove target_ops parameter.
7879 (complete_target_initialization): Delete.
7880 (add_target_with_completer): No longer call
7881 complete_target_initialization.
7882 (target_supports_terminal_ours): Use regular delegation.
7883 (update_current_target): Delete.
7884 (push_target): No longer check magic number. Don't call
7885 update_current_target.
7886 (unpush_target): Don't call update_current_target.
7887 (target_is_pushed): No longer check magic number.
7888 (target_require_runnable): Skip for all stratums over
7889 process_stratum.
7890 (target_ops::info_proc): New.
7891 (target_info_proc): Use find_target_at and
7892 find_default_run_target.
7893 (target_supports_disable_randomization): Use regular delegation.
7894 (target_get_osdata): Use find_target_at.
7895 (target_ops::open, target_ops::close, target_ops::can_attach)
7896 (target_ops::attach, target_ops::can_create_inferior)
7897 (target_ops::create_inferior, target_ops::can_run)
7898 (target_can_run): New.
7899 (default_fileio_target): Use regular delegation.
7900 (target_ops::fileio_open, target_ops::fileio_pwrite)
7901 (target_ops::fileio_pread, target_ops::fileio_fstat)
7902 (target_ops::fileio_close, target_ops::fileio_unlink)
7903 (target_ops::fileio_readlink): New.
7904 (target_fileio_open_1, target_fileio_unlink)
7905 (target_fileio_readlink): Always call the target method. Handle
7906 FILEIO_ENOSYS.
7907 (return_zero, return_zero_has_execution): Delete.
7908 (init_dummy_target): Delete.
7909 (dummy_target::dummy_target, dummy_target::shortname)
7910 (dummy_target::longname, dummy_target::doc)
7911 (debug_target::debug_target, debug_target::shortname)
7912 (debug_target::longname, debug_target::doc): New.
7913 (target_supports_delete_record): Use regular delegation.
7914 (setup_target_debug): Delete.
7915 (maintenance_print_target_stack): Skip debug_stratum.
7916 (initialize_targets): Instantiate the_dummy_target and
7917 the_debug_target.
7918 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
7919 use target_stack.
7920 (target_auxv_search, fprint_target_auxv): Adjust.
7921 (info_auxv_command): Adjust to use target_stack.
7922 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
7923 * exceptions.c (print_flush): Handle a NULL target_stack.
7924 * regcache.c (target_ops_no_register): Refactor as class with
7925 virtual methods.
7926
7927 * exec.c (exec_target): New class.
7928 (exec_ops): Now an exec_target.
7929 (exec_open, exec_close_1, exec_get_section_table)
7930 (exec_xfer_partial, exec_files_info, exec_has_memory)
7931 (exec_make_note_section): Refactor as exec_target methods.
7932 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
7933 Delete.
7934 (exec_target::find_memory_regions): New.
7935 (_initialize_exec): Don't call init_exec_ops.
7936 * gdbcore.h (exec_file_clear): Delete.
7937
7938 * corefile.c (core_target): Delete.
7939 (core_file_command): Adjust.
7940 * corelow.c (core_target): New class.
7941 (the_core_target): New.
7942 (core_close): Remove target_ops parameter.
7943 (core_close_cleanup): Adjust.
7944 (core_target::close): New.
7945 (core_open, core_detach, get_core_registers, core_files_info)
7946 (core_xfer_partial, core_thread_alive, core_read_description)
7947 (core_pid_to_str, core_thread_name, core_has_memory)
7948 (core_has_stack, core_has_registers, core_info_proc): Rework as
7949 core_target methods.
7950 (ignore, core_remove_breakpoint, init_core_ops): Delete.
7951 (_initialize_corelow): Initialize the_core_target.
7952 * gdbcore.h (core_target): Delete.
7953 (the_core_target): New.
7954
7955 * ctf.c: (ctf_target): New class.
7956 (ctf_ops): Now a ctf_target.
7957 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
7958 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
7959 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
7960 methods.
7961 (init_ctf_ops): Delete.
7962 (_initialize_ctf): Don't call it.
7963 * tracefile-tfile.c (tfile_target): New class.
7964 (tfile_ops): Now a tfile_target.
7965 (tfile_open, tfile_close, tfile_files_info)
7966 (tfile_get_tracepoint_status, tfile_trace_find)
7967 (tfile_fetch_registers, tfile_xfer_partial)
7968 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
7969 Refactor as tfile_target methods.
7970 (tfile_xfer_partial_features): Remove target_ops parameter.
7971 (init_tfile_ops): Delete.
7972 (_initialize_tracefile_tfile): Don't call it.
7973 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
7974 (tracefile_has_stack, tracefile_has_registers)
7975 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
7976 tracefile_target methods.
7977 (init_tracefile_ops): Delete.
7978 (tracefile_target::tracefile_target): New.
7979 * tracefile.h: Include "target.h".
7980 (tracefile_target): New class.
7981 (init_tracefile_ops): Delete.
7982
7983 * spu-multiarch.c (spu_multiarch_target): New class.
7984 (spu_ops): Now a spu_multiarch_target.
7985 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
7986 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
7987 (spu_search_memory, spu_mourn_inferior): Refactor as
7988 spu_multiarch_target methods.
7989 (init_spu_ops): Delete.
7990 (_initialize_spu_multiarch): Remove references to init_spu_ops,
7991 complete_target_initialization.
7992
7993 * ravenscar-thread.c (ravenscar_thread_target): New class.
7994 (ravenscar_ops): Now a ravenscar_thread_target.
7995 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
7996 (ravenscar_thread_alive, ravenscar_pid_to_str)
7997 (ravenscar_fetch_registers, ravenscar_store_registers)
7998 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
7999 (ravenscar_stopped_by_hw_breakpoint)
8000 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
8001 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
8002 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
8003 methods.
8004 (init_ravenscar_thread_ops): Delete.
8005 (_initialize_ravenscar): Remove references to
8006 init_ravenscar_thread_ops and complete_target_initialization.
8007
8008 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
8009 (bsd_uthread_target): New class.
8010 (bsd_uthread_ops): Now a bsd_uthread_target.
8011 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
8012 (bsd_uthread_close, bsd_uthread_mourn_inferior)
8013 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
8014 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
8015 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
8016 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
8017 (bsd_uthread_target): Delete function.
8018 (_initialize_bsd_uthread): Remove reference to
8019 complete_target_initialization.
8020
8021 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
8022 (target_bfd): ... this new class.
8023 (target_bfd_xfer_partial, target_bfd_get_section_table)
8024 (target_bfd_close): Refactor as target_bfd methods.
8025 (target_bfd::~target_bfd): New.
8026 (target_bfd_reopen): Adjust.
8027 (target_bfd::close): New.
8028
8029 * record-btrace.c (record_btrace_target): New class.
8030 (record_btrace_ops): Now a record_btrace_target.
8031 (record_btrace_open, record_btrace_stop_recording)
8032 (record_btrace_disconnect, record_btrace_close)
8033 (record_btrace_async, record_btrace_info)
8034 (record_btrace_insn_history, record_btrace_insn_history_range)
8035 (record_btrace_insn_history_from, record_btrace_call_history)
8036 (record_btrace_call_history_range)
8037 (record_btrace_call_history_from, record_btrace_record_method)
8038 (record_btrace_is_replaying, record_btrace_will_replay)
8039 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
8040 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
8041 (record_btrace_store_registers, record_btrace_prepare_to_store)
8042 (record_btrace_to_get_unwinder)
8043 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
8044 (record_btrace_commit_resume, record_btrace_wait)
8045 (record_btrace_stop, record_btrace_can_execute_reverse)
8046 (record_btrace_stopped_by_sw_breakpoint)
8047 (record_btrace_supports_stopped_by_sw_breakpoint)
8048 (record_btrace_stopped_by_hw_breakpoint)
8049 (record_btrace_supports_stopped_by_hw_breakpoint)
8050 (record_btrace_update_thread_list, record_btrace_thread_alive)
8051 (record_btrace_goto_begin, record_btrace_goto_end)
8052 (record_btrace_goto, record_btrace_stop_replaying_all)
8053 (record_btrace_execution_direction)
8054 (record_btrace_prepare_to_generate_core)
8055 (record_btrace_done_generating_core): Refactor as
8056 record_btrace_target methods.
8057 (init_record_btrace_ops): Delete.
8058 (_initialize_record_btrace): Remove reference to
8059 init_record_btrace_ops.
8060 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
8061 the execution_direction global.
8062 (record_full_base_target, record_full_target)
8063 (record_full_core_target): New classes.
8064 (record_full_ops): Now a record_full_target.
8065 (record_full_core_ops): Now a record_full_core_target.
8066 (record_full_target::detach, record_full_target::disconnect)
8067 (record_full_core_target::disconnect)
8068 (record_full_target::mourn_inferior, record_full_target::kill):
8069 New.
8070 (record_full_open, record_full_close, record_full_async): Refactor
8071 as methods of the record_full_base_target class.
8072 (record_full_resume, record_full_commit_resume): Refactor
8073 as methods of the record_full_target class.
8074 (record_full_wait, record_full_stopped_by_watchpoint)
8075 (record_full_stopped_data_address)
8076 (record_full_stopped_by_sw_breakpoint)
8077 (record_full_supports_stopped_by_sw_breakpoint)
8078 (record_full_stopped_by_hw_breakpoint)
8079 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
8080 methods of the record_full_base_target class.
8081 (record_full_store_registers, record_full_xfer_partial)
8082 (record_full_insert_breakpoint, record_full_remove_breakpoint):
8083 Refactor as methods of the record_full_target class.
8084 (record_full_can_execute_reverse, record_full_get_bookmark)
8085 (record_full_goto_bookmark, record_full_execution_direction)
8086 (record_full_record_method, record_full_info, record_full_delete)
8087 (record_full_is_replaying, record_full_will_replay)
8088 (record_full_goto_begin, record_full_goto_end, record_full_goto)
8089 (record_full_stop_replaying): Refactor as methods of the
8090 record_full_base_target class.
8091 (record_full_core_resume, record_full_core_kill)
8092 (record_full_core_fetch_registers)
8093 (record_full_core_prepare_to_store)
8094 (record_full_core_store_registers, record_full_core_xfer_partial)
8095 (record_full_core_insert_breakpoint)
8096 (record_full_core_remove_breakpoint)
8097 (record_full_core_has_execution): Refactor
8098 as methods of the record_full_core_target class.
8099 (record_full_base_target::supports_delete_record): New.
8100 (init_record_full_ops): Delete.
8101 (init_record_full_core_ops): Delete.
8102 (record_full_save): Refactor as method of the
8103 record_full_base_target class.
8104 (_initialize_record_full): Remove references to
8105 init_record_full_ops and init_record_full_core_ops.
8106
8107 * remote.c (remote_target, extended_remote_target): New classes.
8108 (remote_ops): Now a remote_target.
8109 (extended_remote_ops): Now an extended_remote_target.
8110 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
8111 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
8112 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
8113 (remote_pass_signals, remote_set_syscall_catchpoint)
8114 (remote_program_signals, )
8115 (remote_thread_always_alive): Remove target_ops parameter.
8116 (remote_thread_alive, remote_thread_name)
8117 (remote_update_thread_list, remote_threads_extra_info)
8118 (remote_static_tracepoint_marker_at)
8119 (remote_static_tracepoint_markers_by_strid)
8120 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
8121 (remote_open): Refactor as methods of remote_target.
8122 (extended_remote_open, extended_remote_detach)
8123 (extended_remote_attach, extended_remote_post_attach):
8124 (extended_remote_supports_disable_randomization)
8125 (extended_remote_create_inferior): : Refactor as method of
8126 extended_remote_target.
8127 (remote_set_permissions, remote_open_1, remote_detach)
8128 (remote_follow_fork, remote_follow_exec, remote_disconnect)
8129 (remote_resume, remote_commit_resume, remote_stop)
8130 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
8131 (remote_terminal_ours, remote_wait, remote_fetch_registers)
8132 (remote_prepare_to_store, remote_store_registers)
8133 (remote_flash_erase, remote_flash_done, remote_files_info)
8134 (remote_kill, remote_mourn, remote_insert_breakpoint)
8135 (remote_remove_breakpoint, remote_insert_watchpoint)
8136 (remote_watchpoint_addr_within_range)
8137 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
8138 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
8139 (remote_supports_stopped_by_sw_breakpoint)
8140 (remote_stopped_by_hw_breakpoint)
8141 (remote_supports_stopped_by_hw_breakpoint)
8142 (remote_stopped_by_watchpoint, remote_stopped_data_address)
8143 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
8144 (remote_verify_memory): Refactor as methods of remote_target.
8145 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
8146 parameter.
8147 (remote_xfer_partial, remote_get_memory_xfer_limit)
8148 (remote_search_memory, remote_rcmd, remote_memory_map)
8149 (remote_pid_to_str, remote_get_thread_local_address)
8150 (remote_get_tib_address, remote_read_description): Refactor as
8151 methods of remote_target.
8152 (remote_target::fileio_open, remote_target::fileio_pwrite)
8153 (remote_target::fileio_pread, remote_target::fileio_close): New.
8154 (remote_hostio_readlink, remote_hostio_fstat)
8155 (remote_filesystem_is_local, remote_can_execute_reverse)
8156 (remote_supports_non_stop, remote_supports_disable_randomization)
8157 (remote_supports_multi_process, remote_supports_cond_breakpoints)
8158 (remote_supports_enable_disable_tracepoint)
8159 (remote_supports_string_tracing)
8160 (remote_can_run_breakpoint_commands, remote_trace_init)
8161 (remote_download_tracepoint, remote_can_download_tracepoint)
8162 (remote_download_trace_state_variable, remote_enable_tracepoint)
8163 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
8164 (remote_trace_start, remote_get_trace_status)
8165 (remote_get_tracepoint_status, remote_trace_stop)
8166 (remote_trace_find, remote_get_trace_state_variable_value)
8167 (remote_save_trace_data, remote_get_raw_trace_data)
8168 (remote_set_disconnected_tracing, remote_core_of_thread)
8169 (remote_set_circular_trace_buffer, remote_traceframe_info)
8170 (remote_get_min_fast_tracepoint_insn_len)
8171 (remote_set_trace_buffer_size, remote_set_trace_notes)
8172 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
8173 (remote_disable_btrace, remote_teardown_btrace)
8174 (remote_read_btrace, remote_btrace_conf)
8175 (remote_augmented_libraries_svr4_read, remote_load)
8176 (remote_pid_to_exec_file, remote_can_do_single_step)
8177 (remote_execution_direction, remote_thread_handle_to_thread_info):
8178 Refactor as methods of remote_target.
8179 (init_remote_ops, init_extended_remote_ops): Delete.
8180 (remote_can_async_p, remote_is_async_p, remote_async)
8181 (remote_thread_events, remote_upload_tracepoints)
8182 (remote_upload_trace_state_variables): Refactor as methods of
8183 remote_target.
8184 (_initialize_remote): Remove references to init_remote_ops and
8185 init_extended_remote_ops.
8186
8187 * remote-sim.c (gdbsim_target): New class.
8188 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
8189 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
8190 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
8191 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
8192 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
8193 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
8194 Refactor as methods of gdbsim_target.
8195 (gdbsim_ops): Now a gdbsim_target.
8196 (init_gdbsim_ops): Delete.
8197 (gdbsim_cntrl_c): Adjust.
8198 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
8199
8200 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
8201 (the_amd64_linux_nat_target): New.
8202 (amd64_linux_fetch_inferior_registers)
8203 (amd64_linux_store_inferior_registers): Refactor as methods of
8204 amd64_linux_nat_target.
8205 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
8206 * i386-linux-nat.c: Don't include "linux-nat.h".
8207 (i386_linux_nat_target): New class.
8208 (the_i386_linux_nat_target): New.
8209 (i386_linux_fetch_inferior_registers)
8210 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
8211 as methods of i386_linux_nat_target.
8212 (_initialize_i386_linux_nat): Adjust. Set linux_target.
8213 * inf-child.c (inf_child_ops): Delete.
8214 (inf_child_fetch_inferior_registers)
8215 (inf_child_store_inferior_registers): Delete.
8216 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
8217 methods of inf_child_target.
8218 (inf_child_target::supports_terminal_ours)
8219 (inf_child_target::terminal_init)
8220 (inf_child_target::terminal_inferior)
8221 (inf_child_target::terminal_ours_for_output)
8222 (inf_child_target::terminal_ours, inf_child_target::interrupt)
8223 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
8224 New.
8225 (inf_child_open, inf_child_disconnect, inf_child_close)
8226 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
8227 (inf_child_post_startup_inferior, inf_child_can_run)
8228 (inf_child_pid_to_exec_file): Refactor as methods of
8229 inf_child_target.
8230 (inf_child_follow_fork): Delete.
8231 (inf_child_target::can_create_inferior)
8232 (inf_child_target::can_attach): New.
8233 (inf_child_target::has_all_memory, inf_child_target::has_memory)
8234 (inf_child_target::has_stack, inf_child_target::has_registers)
8235 (inf_child_target::has_execution): New.
8236 (inf_child_fileio_open, inf_child_fileio_pwrite)
8237 (inf_child_fileio_pread, inf_child_fileio_fstat)
8238 (inf_child_fileio_close, inf_child_fileio_unlink)
8239 (inf_child_fileio_readlink, inf_child_use_agent)
8240 (inf_child_can_use_agent): Refactor as methods of
8241 inf_child_target.
8242 (return_zero, inf_child_target): Delete.
8243 (inf_child_target::inf_child_target): New.
8244 * inf-child.h: Include "target.h".
8245 (inf_child_target): Delete function prototype.
8246 (inf_child_target): New class.
8247 (inf_child_open_target, inf_child_mourn_inferior)
8248 (inf_child_maybe_unpush_target): Delete.
8249 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
8250 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
8251 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
8252 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
8253 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
8254 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
8255 (inf_ptrace_wait, inf_ptrace_xfer_partial)
8256 (inf_ptrace_thread_alive, inf_ptrace_files_info)
8257 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
8258 methods of inf_ptrace_target.
8259 (inf_ptrace_target): Delete function.
8260 * inf-ptrace.h: Include "inf-child.h".
8261 (inf_ptrace_target): Delete function declaration.
8262 (inf_ptrace_target): New class.
8263 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
8264 * linux-nat.c (linux_target): New.
8265 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
8266 (linux_nat_target::~linux_nat_target): New.
8267 (linux_child_post_attach, linux_child_post_startup_inferior)
8268 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
8269 (linux_child_remove_fork_catchpoint)
8270 (linux_child_insert_vfork_catchpoint)
8271 (linux_child_remove_vfork_catchpoint)
8272 (linux_child_insert_exec_catchpoint)
8273 (linux_child_remove_exec_catchpoint)
8274 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
8275 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
8276 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
8277 (linux_nat_stopped_data_address)
8278 (linux_nat_stopped_by_sw_breakpoint)
8279 (linux_nat_supports_stopped_by_sw_breakpoint)
8280 (linux_nat_stopped_by_hw_breakpoint)
8281 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
8282 (linux_nat_kill, linux_nat_mourn_inferior)
8283 (linux_nat_xfer_partial, linux_nat_thread_alive)
8284 (linux_nat_update_thread_list, linux_nat_pid_to_str)
8285 (linux_nat_thread_name, linux_child_pid_to_exec_file)
8286 (linux_child_static_tracepoint_markers_by_strid)
8287 (linux_nat_is_async_p, linux_nat_can_async_p)
8288 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
8289 (linux_nat_supports_multi_process)
8290 (linux_nat_supports_disable_randomization, linux_nat_async)
8291 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
8292 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
8293 (linux_nat_fileio_open, linux_nat_fileio_readlink)
8294 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
8295 methods of linux_nat_target.
8296 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
8297 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
8298 parameter.
8299 (check_stopped_by_watchpoint): Adjust.
8300 (linux_xfer_partial): Delete.
8301 (linux_target_install_ops, linux_target, linux_nat_add_target):
8302 Delete.
8303 (linux_nat_target::linux_nat_target): New.
8304 * linux-nat.h: Include "inf-ptrace.h".
8305 (linux_nat_target): New.
8306 (linux_target, linux_target_install_ops, linux_nat_add_target):
8307 Delete function declarations.
8308 (linux_target): Declare global.
8309 * linux-thread-db.c (thread_db_target): New.
8310 (thread_db_target::thread_db_target): New.
8311 (thread_db_ops): Delete.
8312 (the_thread_db_target): New.
8313 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
8314 (thread_db_update_thread_list, thread_db_pid_to_str)
8315 (thread_db_extra_thread_info)
8316 (thread_db_thread_handle_to_thread_info)
8317 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
8318 (thread_db_resume): Refactor as methods of thread_db_target.
8319 (init_thread_db_ops): Delete.
8320 (_initialize_thread_db): Remove reference to init_thread_db_ops.
8321 * x86-linux-nat.c: Don't include "linux-nat.h".
8322 (super_post_startup_inferior): Delete.
8323 (x86_linux_nat_target::~x86_linux_nat_target): New.
8324 (x86_linux_child_post_startup_inferior)
8325 (x86_linux_read_description, x86_linux_enable_btrace)
8326 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
8327 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
8328 methods of x86_linux_nat_target.
8329 (x86_linux_create_target): Delete. Bits folded ...
8330 (x86_linux_add_target): ... here. Now takes a linux_nat_target
8331 pointer.
8332 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
8333 (x86_linux_nat_target): New class.
8334 (x86_linux_create_target): Delete.
8335 (x86_linux_add_target): Now takes a linux_nat_target pointer.
8336 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
8337 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
8338 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
8339 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
8340 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
8341 make extern.
8342 (x86_use_watchpoints): Delete.
8343 * x86-nat.h: Include "breakpoint.h" and "target.h".
8344 (x86_use_watchpoints): Delete.
8345 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
8346 (x86_stopped_by_watchpoint, x86_stopped_data_address)
8347 (x86_insert_watchpoint, x86_remove_watchpoint)
8348 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
8349 (x86_stopped_by_hw_breakpoint): New declarations.
8350 (x86_nat_target): New template class.
8351
8352 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
8353 (the_ppc_linux_nat_target): New.
8354 (ppc_linux_fetch_inferior_registers)
8355 (ppc_linux_can_use_hw_breakpoint)
8356 (ppc_linux_region_ok_for_hw_watchpoint)
8357 (ppc_linux_ranged_break_num_registers)
8358 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
8359 (ppc_linux_insert_mask_watchpoint)
8360 (ppc_linux_remove_mask_watchpoint)
8361 (ppc_linux_can_accel_watchpoint_condition)
8362 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
8363 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
8364 (ppc_linux_watchpoint_addr_within_range)
8365 (ppc_linux_masked_watch_num_registers)
8366 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
8367 (ppc_linux_read_description): Refactor as methods of
8368 ppc_linux_nat_target.
8369 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
8370
8371 * procfs.c (procfs_xfer_partial): Delete forward declaration.
8372 (procfs_target): New class.
8373 (the_procfs_target): New.
8374 (procfs_target): Delete function.
8375 (procfs_auxv_parse, procfs_attach, procfs_detach)
8376 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
8377 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
8378 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
8379 (procfs_create_inferior, procfs_update_thread_list)
8380 (procfs_thread_alive, procfs_pid_to_str)
8381 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
8382 (procfs_stopped_data_address, procfs_insert_watchpoint)
8383 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
8384 (proc_find_memory_regions, procfs_info_proc)
8385 (procfs_make_note_section): Refactor as methods of procfs_target.
8386 (_initialize_procfs): Adjust.
8387 * sol-thread.c (sol_thread_target): New class.
8388 (sol_thread_ops): Now a sol_thread_target.
8389 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
8390 (sol_thread_fetch_registers, sol_thread_store_registers)
8391 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
8392 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
8393 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
8394 (init_sol_thread_ops): Delete.
8395 (_initialize_sol_thread): Adjust. Remove references to
8396 init_sol_thread_ops and complete_target_initialization.
8397
8398 * windows-nat.c (windows_nat_target): New class.
8399 (windows_fetch_inferior_registers)
8400 (windows_store_inferior_registers, windows_resume, windows_wait)
8401 (windows_attach, windows_detach, windows_pid_to_exec_file)
8402 (windows_files_info, windows_create_inferior)
8403 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
8404 (windows_close, windows_pid_to_str, windows_xfer_partial)
8405 (windows_get_tib_address, windows_get_ada_task_ptid)
8406 (windows_thread_name, windows_thread_alive): Refactor as
8407 windows_nat_target methods.
8408 (do_initial_windows_stuff): Adjust.
8409 (windows_target): Delete function.
8410 (_initialize_windows_nat): Adjust.
8411
8412 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
8413 (darwin_mourn_inferior, darwin_kill_inferior)
8414 (darwin_create_inferior, darwin_attach, darwin_detach)
8415 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
8416 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
8417 (darwin_supports_multi_process): Refactor as darwin_nat_target
8418 methods.
8419 (darwin_resume_to, darwin_files_info): Delete.
8420 (_initialize_darwin_inferior): Rename to ...
8421 (_initialize_darwin_nat): ... this. Adjust to C++ification.
8422 * darwin-nat.h: Include "inf-child.h".
8423 (darwin_nat_target): New class.
8424 (darwin_complete_target): Delete.
8425 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
8426 (darwin_target): New.
8427 (i386_darwin_fetch_inferior_registers)
8428 (i386_darwin_store_inferior_registers): Refactor as methods of
8429 darwin_nat_target.
8430 (darwin_complete_target): Delete, with ...
8431 (_initialize_i386_darwin_nat): ... bits factored out here.
8432
8433 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
8434 (the_alpha_linux_nat_target): New.
8435 (alpha_linux_register_u_offset): Refactor as
8436 alpha_linux_nat_target method.
8437 (_initialize_alpha_linux_nat): Adjust.
8438 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
8439 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8440 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
8441 methods of linux_nat_trad_target.
8442 (linux_trad_target): Delete.
8443 * linux-nat-trad.h (linux_trad_target): Delete function.
8444 (linux_nat_trad_target): New class.
8445 * mips-linux-nat.c (mips_linux_nat_target): New class.
8446 (super_fetch_registers, super_store_registers, super_close):
8447 Delete.
8448 (the_mips_linux_nat_target): New.
8449 (mips64_linux_regsets_fetch_registers)
8450 (mips64_linux_regsets_store_registers)
8451 (mips64_linux_fetch_registers, mips64_linux_store_registers)
8452 (mips_linux_register_u_offset, mips_linux_read_description)
8453 (mips_linux_can_use_hw_breakpoint)
8454 (mips_linux_stopped_by_watchpoint)
8455 (mips_linux_stopped_data_address)
8456 (mips_linux_region_ok_for_hw_watchpoint)
8457 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
8458 (mips_linux_close): Refactor as methods of mips_linux_nat.
8459 (_initialize_mips_linux_nat): Adjust to C++ification.
8460
8461 * aix-thread.c (aix_thread_target): New class.
8462 (aix_thread_ops): Now an aix_thread_target.
8463 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
8464 (aix_thread_fetch_registers, aix_thread_store_registers)
8465 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
8466 (aix_thread_thread_alive, aix_thread_pid_to_str)
8467 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
8468 Refactor as methods of aix_thread_target.
8469 (init_aix_thread_ops): Delete.
8470 (_initialize_aix_thread): Remove references to init_aix_thread_ops
8471 and complete_target_initialization.
8472 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
8473 (rs6000_nat_target): New class.
8474 (the_rs6000_nat_target): New.
8475 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
8476 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
8477 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
8478 (super_create_inferior): Delete.
8479 (_initialize_rs6000_nat): Adjust to C++ification.
8480
8481 * arm-linux-nat.c (arm_linux_nat_target): New class.
8482 (the_arm_linux_nat_target): New.
8483 (arm_linux_fetch_inferior_registers)
8484 (arm_linux_store_inferior_registers, arm_linux_read_description)
8485 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
8486 (arm_linux_remove_hw_breakpoint)
8487 (arm_linux_region_ok_for_hw_watchpoint)
8488 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
8489 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
8490 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
8491 arm_linux_nat_target.
8492 (_initialize_arm_linux_nat): Adjust to C++ification.
8493
8494 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
8495 (the_aarch64_linux_nat_target): New.
8496 (aarch64_linux_fetch_inferior_registers)
8497 (aarch64_linux_store_inferior_registers)
8498 (aarch64_linux_child_post_startup_inferior)
8499 (aarch64_linux_read_description)
8500 (aarch64_linux_can_use_hw_breakpoint)
8501 (aarch64_linux_insert_hw_breakpoint)
8502 (aarch64_linux_remove_hw_breakpoint)
8503 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
8504 (aarch64_linux_region_ok_for_hw_watchpoint)
8505 (aarch64_linux_stopped_data_address)
8506 (aarch64_linux_stopped_by_watchpoint)
8507 (aarch64_linux_watchpoint_addr_within_range)
8508 (aarch64_linux_can_do_single_step): Refactor as methods of
8509 aarch64_linux_nat_target.
8510 (super_post_startup_inferior): Delete.
8511 (_initialize_aarch64_linux_nat): Adjust to C++ification.
8512
8513 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
8514 (the_hppa_linux_nat_target): New.
8515 (hppa_linux_fetch_inferior_registers)
8516 (hppa_linux_store_inferior_registers): Refactor as methods of
8517 hppa_linux_nat_target.
8518 (_initialize_hppa_linux_nat): Adjust to C++ification.
8519
8520 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
8521 (the_ia64_linux_nat_target): New.
8522 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
8523 (ia64_linux_stopped_data_address)
8524 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
8525 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
8526 ia64_linux_nat_target methods.
8527 (super_xfer_partial): Delete.
8528 (_initialize_ia64_linux_nat): Adjust to C++ification.
8529
8530 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
8531 (the_m32r_linux_nat_target): New.
8532 (m32r_linux_fetch_inferior_registers)
8533 (m32r_linux_store_inferior_registers): Refactor as
8534 m32r_linux_nat_target methods.
8535 (_initialize_m32r_linux_nat): Adjust to C++ification.
8536
8537 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
8538 (the_m68k_linux_nat_target): New.
8539 (m68k_linux_fetch_inferior_registers)
8540 (m68k_linux_store_inferior_registers): Refactor as
8541 m68k_linux_nat_target methods.
8542 (_initialize_m68k_linux_nat): Adjust to C++ification.
8543
8544 * s390-linux-nat.c (s390_linux_nat_target): New class.
8545 (the_s390_linux_nat_target): New.
8546 (s390_linux_fetch_inferior_registers)
8547 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
8548 (s390_insert_watchpoint, s390_remove_watchpoint)
8549 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
8550 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
8551 (s390_auxv_parse, s390_read_description): Refactor as methods of
8552 s390_linux_nat_target.
8553 (_initialize_s390_nat): Adjust to C++ification.
8554
8555 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
8556 (the_sparc_linux_nat_target): New.
8557 (_initialize_sparc_linux_nat): Adjust to C++ification.
8558 * sparc-nat.c (sparc_fetch_inferior_registers)
8559 (sparc_store_inferior_registers): Remove target_ops parameter.
8560 * sparc-nat.h (sparc_fetch_inferior_registers)
8561 (sparc_store_inferior_registers): Remove target_ops parameter.
8562 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
8563 (the_sparc64_linux_nat_target): New.
8564 (_initialize_sparc64_linux_nat): Adjust to C++ification.
8565
8566 * spu-linux-nat.c (spu_linux_nat_target): New class.
8567 (the_spu_linux_nat_target): New.
8568 (spu_child_post_startup_inferior, spu_child_post_attach)
8569 (spu_child_wait, spu_fetch_inferior_registers)
8570 (spu_store_inferior_registers, spu_xfer_partial)
8571 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
8572 methods.
8573 (_initialize_spu_nat): Adjust to C++ification.
8574
8575 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
8576 (the_tilegx_linux_nat_target): New.
8577 (fetch_inferior_registers, store_inferior_registers):
8578 Refactor as methods.
8579 (_initialize_tile_linux_nat): Adjust to C++ification.
8580
8581 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
8582 (the_xtensa_linux_nat_target): New.
8583 (xtensa_linux_fetch_inferior_registers)
8584 (xtensa_linux_store_inferior_registers): Refactor as
8585 xtensa_linux_nat_target methods.
8586 (_initialize_xtensa_linux_nat): Adjust to C++ification.
8587
8588 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
8589 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
8590 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
8591 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
8592 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
8593 (fbsd_stopped_by_sw_breakpoint)
8594 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
8595 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
8596 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
8597 (fbsd_post_startup_inferior, fbsd_post_attach)
8598 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
8599 (fbsd_set_syscall_catchpoint)
8600 (super_xfer_partial, super_resume, super_wait)
8601 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
8602 (fbsd_handle_debug_trap): Remove target_ops parameter.
8603 (fbsd_nat_add_target): Delete.
8604 * fbsd-nat.h: Include "inf-ptrace.h".
8605 (fbsd_nat_add_target): Delete.
8606 (USE_SIGTRAP_SIGINFO): Define.
8607 (fbsd_nat_target): New class.
8608
8609 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
8610 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
8611 (amd64bsd_target): Delete.
8612 * amd64-bsd-nat.h: New file.
8613 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
8614 "x86-bsd-nat.h".
8615 (amd64_fbsd_nat_target): New class.
8616 (the_amd64_fbsd_nat_target): New.
8617 (amd64fbsd_read_description): Refactor as method of
8618 amd64_fbsd_nat_target.
8619 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8620 (_initialize_amd64fbsd_nat): Adjust to C++ification.
8621 * amd64-nat.h (amd64bsd_target): Delete function declaration.
8622 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
8623 (i386bsd_store_inferior_registers): Remove target_ops parameter.
8624 (i386bsd_target): Delete.
8625 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
8626 (i386bsd_fetch_inferior_registers)
8627 (i386bsd_store_inferior_registers): Declare.
8628 (i386_bsd_nat_target): New class.
8629 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
8630 (the_i386_fbsd_nat_target): New.
8631 (i386fbsd_resume, i386fbsd_read_description): Refactor as
8632 i386_fbsd_nat_target methods.
8633 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8634 (_initialize_i386fbsd_nat): Adjust to C++ification.
8635 * x86-bsd-nat.c (super_mourn_inferior): Delete.
8636 (x86bsd_mourn_inferior, x86bsd_target): Delete.
8637 (_initialize_x86_bsd_nat): Adjust to C++ification.
8638 * x86-bsd-nat.h: Include "x86-nat.h".
8639 (x86bsd_target): Delete declaration.
8640 (x86bsd_nat_target): New class.
8641
8642 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
8643 (the_aarch64_fbsd_nat_target): New.
8644 (aarch64_fbsd_fetch_inferior_registers)
8645 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
8646 aarch64_fbsd_nat_target.
8647 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
8648 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
8649 (the_alpha_bsd_nat_target): New.
8650 (alphabsd_fetch_inferior_registers)
8651 (alphabsd_store_inferior_registers): Refactor as
8652 alpha_bsd_nat_target methods.
8653 (_initialize_alphabsd_nat): Refactor as methods of
8654 alpha_bsd_nat_target.
8655 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
8656 (the_amd64_nbsd_nat_target): New.
8657 (_initialize_amd64nbsd_nat): Adjust to C++ification.
8658 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
8659 (the_amd64_obsd_nat_target): New.
8660 (_initialize_amd64obsd_nat): Adjust to C++ification.
8661 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
8662 (the_arm_fbsd_nat_target): New.
8663 (arm_fbsd_fetch_inferior_registers)
8664 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
8665 (_initialize_arm_fbsd_nat): Refactor as methods of
8666 arm_fbsd_nat_target.
8667 (_initialize_arm_fbsd_nat): Adjust to C++ification.
8668 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
8669 (the_arm_netbsd_nat_target): New.
8670 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
8671 arm_netbsd_nat_target.
8672 (_initialize_arm_netbsd_nat): Adjust to C++ification.
8673 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
8674 (the_hppa_nbsd_nat_target): New.
8675 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
8676 hppa_nbsd_nat_target methods.
8677 (_initialize_hppanbsd_nat): Adjust to C++ification.
8678 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
8679 (the_hppa_obsd_nat_target): New.
8680 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
8681 methods of hppa_obsd_nat_target.
8682 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
8683 add_target.
8684 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
8685 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
8686 add_target.
8687 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
8688 (_initialize_i386obsd_nat): Use add_target.
8689 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
8690 (the_m68k_bsd_nat_target): New.
8691 (m68kbsd_fetch_inferior_registers)
8692 (m68kbsd_store_inferior_registers): Refactor as methods of
8693 m68k_bsd_nat_target.
8694 (_initialize_m68kbsd_nat): Adjust to C++ification.
8695 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
8696 (the_mips_fbsd_nat_target): New.
8697 (mips_fbsd_fetch_inferior_registers)
8698 (mips_fbsd_store_inferior_registers): Refactor as methods of
8699 mips_fbsd_nat_target.
8700 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
8701 add_target.
8702 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
8703 (the_mips_nbsd_nat_target): New.
8704 (mipsnbsd_fetch_inferior_registers)
8705 (mipsnbsd_store_inferior_registers): Refactor as methods of
8706 mips_nbsd_nat_target.
8707 (_initialize_mipsnbsd_nat): Adjust to C++ification.
8708 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
8709 (the_mips64_obsd_nat_target): New.
8710 (mips64obsd_fetch_inferior_registers)
8711 (mips64obsd_store_inferior_registers): Refactor as methods of
8712 mips64_obsd_nat_target.
8713 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
8714 add_target.
8715 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
8716 nbsd_nat_target.
8717 * nbsd-nat.h: Include "inf-ptrace.h".
8718 (nbsd_nat_target): New class.
8719 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
8720 (obsd_wait): Refactor as methods of obsd_nat_target.
8721 (obsd_add_target): Delete.
8722 * obsd-nat.h: Include "inf-ptrace.h".
8723 (obsd_nat_target): New class.
8724 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
8725 (the_ppc_fbsd_nat_target): New.
8726 (ppcfbsd_fetch_inferior_registers)
8727 (ppcfbsd_store_inferior_registers): Refactor as methods of
8728 ppc_fbsd_nat_target.
8729 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
8730 add_target.
8731 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
8732 (the_ppc_nbsd_nat_target): New.
8733 (ppcnbsd_fetch_inferior_registers)
8734 (ppcnbsd_store_inferior_registers): Refactor as methods of
8735 ppc_nbsd_nat_target.
8736 (_initialize_ppcnbsd_nat): Adjust to C++ification.
8737 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
8738 (the_ppc_obsd_nat_target): New.
8739 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
8740 methods of ppc_obsd_nat_target.
8741 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
8742 add_target.
8743 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
8744 (the_sh_nbsd_nat_target): New.
8745 (shnbsd_fetch_inferior_registers)
8746 (shnbsd_store_inferior_registers): Refactor as methods of
8747 sh_nbsd_nat_target.
8748 (_initialize_shnbsd_nat): Adjust to C++ification.
8749 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
8750 (inf_ptrace_xfer_partial): Delete.
8751 (sparc_xfer_partial, sparc_target): Delete.
8752 * sparc-nat.h (sparc_fetch_inferior_registers)
8753 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
8754 (sparc_target): Delete function declaration.
8755 (sparc_target): New template class.
8756 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
8757 (_initialize_sparcnbsd_nat): Adjust to C++ification.
8758 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
8759 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
8760 add_target.
8761 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
8762 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
8763 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
8764 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
8765 add_target.
8766 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
8767 (the_vax_bsd_nat_target): New.
8768 (vaxbsd_fetch_inferior_registers)
8769 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
8770 methods.
8771 (_initialize_vaxbsd_nat): Adjust to C++ification.
8772
8773 * bsd-kvm.c (bsd_kvm_target): New class.
8774 (bsd_kvm_ops): Now a bsd_kvm_target.
8775 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
8776 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
8777 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
8778 bsd_kvm_target.
8779 (bsd_kvm_return_one): Delete.
8780 (bsd_kvm_add_target): Adjust to C++ification.
8781
8782 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
8783 (nto_procfs_target_procfs): New classes.
8784 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
8785 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
8786 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
8787 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
8788 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
8789 (procfs_remove_hw_breakpoint, procfs_resume)
8790 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
8791 (procfs_kill_inferior, procfs_store_registers)
8792 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
8793 as methods of nto_procfs_target.
8794 (nto_procfs_ops): Now an nto_procfs_target_procfs.
8795 (nto_native_ops): Delete.
8796 (procfs_open, procfs_native_open): Delete.
8797 (nto_native_ops): Now an nto_procfs_target_native.
8798 (init_procfs_targets): Adjust to C++ification.
8799 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
8800 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
8801 Refactor as methods of nto_procfs_target.
8802
8803 * go32-nat.c (go32_nat_target): New class.
8804 (the_go32_nat_target): New.
8805 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
8806 (go32_store_registers, go32_xfer_partial, go32_files_info)
8807 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
8808 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
8809 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
8810 (go32_pid_to_str): Refactor as methods of go32_nat_target.
8811 (go32_target): Delete.
8812 (_initialize_go32_nat): Adjust to C++ification.
8813
8814 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
8815 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
8816 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
8817 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
8818 gnu_nat_target.
8819 (gnu_target): Delete.
8820 * gnu-nat.h (gnu_target): Delete.
8821 (gnu_nat_target): New class.
8822 * i386-gnu-nat.c (gnu_base_target): New.
8823 (i386_gnu_nat_target): New class.
8824 (the_i386_gnu_nat_target): New.
8825 (_initialize_i386gnu_nat): Adjust to C++ification.
8826
8827 2018-05-02 Pedro Alves <palves@redhat.com>
8828
8829 * bfd-target.c (target_bfd_xclose): Rename to ...
8830 (target_bfd_close): ... this.
8831 (target_bfd_reopen): Adjust.
8832 * target.c (target_close): Remove references to to_xclose.
8833 * target.h (target_ops::to_xclose): Delete.
8834 (target_ops::to_close): Update comments.
8835
8836 2018-05-02 Pedro Alves <palves@redhat.com>
8837
8838 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
8839 "linux-nat.h".
8840 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
8841 * inf-ptrace.c (inf_ptrace_register_u_offset)
8842 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8843 (inf_ptrace_store_register, inf_ptrace_store_registers)
8844 (inf_ptrace_trad_target): Move to ...
8845 * linux-nat-trad.c: ... this new file.
8846 * linux-nat-trad.h: New file.
8847 * linux-nat.c (linux_target_install_ops): Make extern.
8848 (linux_trad_target): Delete.
8849 * linux-nat.h (linux_trad_target): Delete declaration.
8850 (linux_target_install_ops): Declare.
8851 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
8852 "linux-nat.h".
8853
8854 2018-05-02 Pedro Alves <palves@redhat.com>
8855
8856 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8857 procfs_target/add_target here.
8858 * procfs.c (procfs_target): Make static.
8859 (_initialize_procfs): Call add_target here.
8860 * procfs.h (struct target_ops): Remove forward declaration.
8861 (procfs_target): Remove declaration.
8862 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
8863
8864 2018-05-02 Pedro Alves <palves@redhat.com>
8865
8866 * procfs.c (procfs_stopped_by_watchpoint)
8867 (procfs_insert_watchpoint, procfs_remove_watchpoint)
8868 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
8869 Forward declare.
8870 (procfs_use_watchpoints): Delete, move contents...
8871 (procfs_target): ... here.
8872 * procfs.h (procfs_use_watchpoints): Delete declaration.
8873 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8874 procfs_use_watchpoints.
8875 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
8876 procfs_use_watchpoints.
8877
8878 2018-05-02 Tom Tromey <tom@tromey.com>
8879
8880 PR python/20084:
8881 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
8882 and var_zuinteger_unlimited.
8883 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
8884 and PARAM_ZUINTEGER_UNLIMITED.
8885 (set_parameter_value): Handle var_zuinteger and
8886 var_zuinteger_unlimited.
8887 (add_setshow_generic): Likewise.
8888 (parmpy_init): Likewise.
8889
8890 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
8891
8892 PR rust/23124
8893 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
8894 pointer is not null before dereferencing it.
8895
8896 2018-04-30 Tom Tromey <tom@tromey.com>
8897
8898 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
8899 is_mi_like_p.
8900
8901 2018-04-30 Tom Tromey <tom@tromey.com>
8902
8903 * breakpoint.c (mention): Remove use of is_mi_like_p.
8904 (print_mention_ranged_breakpoint): Likewise.
8905 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
8906 of is_mi_like_p.
8907
8908 2018-04-30 Tom Tromey <tom@tromey.com>
8909
8910 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
8911
8912 2018-04-30 Tom Tromey <tom@tromey.com>
8913
8914 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
8915 (info_spu_event_command): Remove some uses of is_mi_like_p.
8916
8917 2018-04-30 Tom Tromey <tom@tromey.com>
8918
8919 * python/py-framefilter.c (py_print_single_arg)
8920 (enumerate_locals, py_print_args, py_print_frame): Remove some
8921 uses of is_mi_like_p.
8922
8923 2018-04-30 Tom Tromey <tom@tromey.com>
8924
8925 * ui-out.c: Update.
8926 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
8927 * ui-out.h (ui_out::is_mi_like_p): Now const.
8928 (ui_out::do_is_mi_like_p): Now const.
8929 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
8930
8931 2018-04-30 Tom Tromey <tom@tromey.com>
8932
8933 * varobj.c (varobj_set_visualizer): Use new_reference.
8934 * python/python.c (gdbpy_decode_line): Use new_reference.
8935 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
8936 new_reference.
8937
8938 2018-04-30 Tom Tromey <tom@tromey.com>
8939
8940 * varobj.c (install_new_value): Use new_reference.
8941 * value.h (value_incref): Return void. Swap intro comment with
8942 value_decref.
8943 * value.c (set_value_parent): Use new_reference.
8944 (value_incref): Return void. Update intro comment.
8945 (release_value): Use new_reference.
8946 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
8947
8948 2018-04-30 Tom Tromey <tom@tromey.com>
8949
8950 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
8951 * gdb_bfd.h (new_bfd_ref): Remove.
8952 (gdb_bfd_open): Update comment.
8953 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
8954 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
8955 (gdb_bfd_fdopenr): Use new_reference.
8956 * exec.c (exec_file_attach): Use new_reference.
8957
8958 2018-04-30 Tom Tromey <tom@tromey.com>
8959
8960 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
8961 method.
8962
8963 2018-04-30 Tom Tromey <tom@tromey.com>
8964
8965 * jit.c (jit_read_code_entry): Use type_align.
8966 * i386-tdep.c (i386_gdbarch_init): Don't call
8967 set_gdbarch_long_long_align_bit.
8968 * gdbarch.sh: Remove long_long_align_bit.
8969 * gdbarch.c, gdbarch.h: Rebuild.
8970 * arc-tdep.c (arc_type_align): New function.
8971 (arc_gdbarch_init): Use arc_type_align. Don't call
8972 set_gdbarch_long_long_align_bit.
8973
8974 2018-04-30 Tom Tromey <tom@tromey.com>
8975
8976 * rust-lang.c (rust_type_alignment): Remove.
8977 (rust_composite_type): Use type_align.
8978
8979 2018-04-30 Tom Tromey <tom@tromey.com>
8980
8981 * NEWS: Mention Type.align.
8982 * python/py-type.c (typy_get_alignof): New function.
8983 (type_object_getset): Add "alignof".
8984
8985 2018-04-30 Tom Tromey <tom@tromey.com>
8986
8987 PR exp/17095:
8988 * NEWS: Update.
8989 * std-operator.def (UNOP_ALIGNOF): New operator.
8990 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
8991 New.
8992 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
8993 * c-lang.c (c_op_print_tab): Add alignof.
8994 * c-exp.y (ALIGNOF): New token.
8995 (exp): Add "ALIGNOF" production.
8996 (ident_tokens): Add _Alignof and alignof.
8997
8998 2018-04-30 Tom Tromey <tom@tromey.com>
8999
9000 * i386-tdep.c (i386_type_align): New function.
9001 (i386_gdbarch_init): Update.
9002 * gdbarch.sh (type_align): New method.
9003 * gdbarch.c, gdbarch.h: Rebuild.
9004 * arch-utils.h (default_type_align): Declare.
9005 * arch-utils.c (default_type_align): New function.
9006 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
9007 (struct type) <align_log2>: New field.
9008 <instance_flags>: Now a bitfield.
9009 (TYPE_RAW_ALIGN): New macro.
9010 (type_align, type_raw_align, set_type_align): Declare.
9011 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
9012 functions.
9013 * dwarf2read.c (quirk_rust_enum): Set type alignment.
9014 (get_alignment, maybe_set_alignment): New functions.
9015 (read_structure_type, read_enumeration_type, read_array_type)
9016 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
9017 (read_subrange_type, read_base_type): Set type alignment.
9018
9019 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
9020
9021 * dwarf2read.c (read_index_from_section): Use bool.
9022
9023 2018-04-29 Fabian Groffen <grobian@gentoo.org>
9024
9025 PR gdb/22950
9026 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
9027 with #ifdef.
9028
9029 2018-04-29 John Reiser <jreiser@BitWagon.com>
9030
9031 PR build/22873
9032 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
9033 last step, and do it atomically.
9034
9035 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
9036
9037 * compile/compile-c-types.c (convert_int, convert_float):
9038 Update for C FE v1.
9039
9040 2018-04-27 Tom Tromey <tom@tromey.com>
9041
9042 PR rust/22545:
9043 * rust-lang.c (rust_inclusive_range_type_p): New function.
9044 (rust_range): Handle inclusive ranges.
9045 (rust_compute_range): Likewise.
9046 * rust-exp.y (struct rust_op) <inclusive>: New field.
9047 (DOTDOTEQ): New constant.
9048 (range_expr): Add "..=" productions.
9049 (operator_tokens): Add "..=" token.
9050 (ast_range): Add "inclusive" parameter.
9051 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
9052 ranges.
9053 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
9054 bounds values.
9055 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
9056 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
9057 Update comments.
9058 * expprint.c (print_subexp_standard): Handle new bounds values.
9059 (dump_subexp_body_standard): Likewise.
9060
9061 2018-04-27 Tom Tromey <tom@tromey.com>
9062
9063 * configure: Rebuild.
9064 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
9065 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
9066 "OVERRIDE".
9067 (class symbol_needs_eval_context): Likewise.
9068 * dwarf2read.c (mock_mapped_index::symbol_name_count)
9069 (mock_mapped_index::symbol_name_at): Use "override". Remove
9070 "virtual".
9071 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
9072 "override".
9073 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
9074 * aarch64-tdep.c (instruction_reader::read): Use "override".
9075 (instruction_reader_test::read): Likewise.
9076 * arm-tdep.c (instruction_reader::read): Use "override".
9077 (instruction_reader_thumb::read): Likewise.
9078
9079 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
9080
9081 PR remote/9665
9082 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
9083 instead of remote_send.
9084 (remote_send): Remove.
9085
9086 2018-04-26 Pedro Alves <palves@redhat.com>
9087
9088 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
9089 find_function_start_sal instead of find_pc_line.
9090
9091 2018-04-26 Pedro Alves <palves@redhat.com>
9092
9093 * breakpoint.c (set_breakpoint_location_function): Handle
9094 mst_data_gnu_ifunc.
9095 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
9096 * elfread.c (elf_symtab_read): Give data symbols with
9097 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
9098 (elf_rel_plt_read): Update comment.
9099 * linespec.c (convert_linespec_to_sals): Handle
9100 mst_data_gnu_ifunc.
9101 (minsym_found): Handle mst_data_gnu_ifunc.
9102 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
9103 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
9104 * parse.c (find_minsym_type_and_address): Handle
9105 mst_data_gnu_ifunc.
9106 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
9107 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
9108 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
9109 comment.
9110 <mst_data_gnu_ifunc>: New enumerator.
9111
9112 2018-04-26 Pedro Alves <palves@redhat.com>
9113
9114 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
9115 (lookup_minimal_symbol_by_pc_section): ... this. Replace
9116 'want_trampoline' parameter by a lookup_msym_prefer parameter.
9117 Handle it.
9118 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
9119 (lookup_minimal_symbol_by_pc): Adjust.
9120 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
9121 (lookup_solib_trampoline_symbol_by_pc): Adjust.
9122 * minsyms.h (lookup_msym_prefer): New enum.
9123 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
9124 parameter by a lookup_msym_prefer parameter.
9125
9126 2018-04-26 Pedro Alves <palves@redhat.com>
9127
9128 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
9129 ends in "@plt" instead of looking at the symbol's section.
9130
9131 2018-04-26 Pedro Alves <palves@redhat.com>
9132
9133 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
9134 all references.
9135 (find_pc_partial_function_gnu_ifunc): Rename to ...
9136 (find_pc_partial_function): ... this, and remove references to
9137 'is_gnu_ifunc_p'.
9138 (find_pc_partial_function): Delete old implementation.
9139 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
9140
9141 2018-04-26 Pedro Alves <palves@redhat.com>
9142
9143 * linespec.c (struct bound_minimal_symbol_search_key): New.
9144 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
9145 skip first line if we found a GNU ifunc minimal symbol by name.
9146 (compare_msymbols): Change parameters to work with a destructured
9147 lhs minsym.
9148 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
9149 functions.
9150
9151 2018-04-26 Pedro Alves <palves@redhat.com>
9152
9153 * breakpoint.c (set_breakpoint_location_function): Don't resolve
9154 ifunc targets here. Instead, if we have an ifunc minsym, use its
9155 address/name.
9156 (add_location_to_breakpoint): Store the minsym and the objfile in
9157 the breakpoint location.
9158 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
9159 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
9160 Record the minsym in the sal.
9161 * symtab.h (symtab_and_line) <msymbol>: New field.
9162
9163 2018-04-26 Pedro Alves <palves@redhat.com>
9164
9165 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
9166 unless we actually resolved the ifunc.
9167
9168 2018-04-26 Pedro Alves <palves@redhat.com>
9169
9170 * c-exp.y (variable production): Prefer ifunc minsyms over
9171 regular function symbols.
9172 * symtab.c (find_gnu_ifunc): New function.
9173 * minsyms.h (lookup_msym_prefer): New enum.
9174 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
9175 parameter by a lookup_msym_prefer parameter.
9176 * symtab.h (find_gnu_ifunc): New declaration.
9177
9178 2018-04-26 Pedro Alves <palves@redhat.com>
9179
9180 * blockframe.c (find_gnu_ifunc_target_type): New function.
9181 (find_function_type): New.
9182 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
9183 return a value with a memory address.
9184 (eval_call): For calls to GNU ifunc functions, try to find the
9185 type of the target function from the type that the resolver
9186 returns.
9187 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
9188 symbols.
9189 * infcall.c (find_function_return_type): Delete.
9190 (find_function_addr): Add 'function_type' parameter. For calls to
9191 GNU ifunc functions, try to find the type of the target function
9192 from the type that the resolver returns, and return it via
9193 FUNCTION_TYPE.
9194 (call_function_by_hand_dummy): Adjust to use the function type
9195 returned by find_function_addr.
9196 (find_function_addr): Add 'function_type' parameter and move
9197 description here.
9198 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
9199 declarations.
9200
9201 2018-04-26 Pedro Alves <palves@redhat.com>
9202
9203 * c-exp.y (variable production): Skip finding an alias for ifunc
9204 symbols.
9205
9206 2018-04-26 Pedro Alves <palves@redhat.com>
9207
9208 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
9209
9210 2018-04-25 Pedro Alves <palves@redhat.com>
9211
9212 * infcmd.c (kill_command): Print the pid as string, not the whole
9213 thread's ptid. Add comment. s/has been killed/killed/ in output
9214 message.
9215 * remote.c (remote_detach_1): Print the pid as string, not the
9216 whole thread's ptid.
9217
9218 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9219 Sergio Durigan Junior <sergiodj@redhat.com>
9220 Pedro Alves <palves@redhat.com>
9221
9222 * infcmd.c (kill_command): Print message when inferior has
9223 been killed.
9224 * inferior.c (print_inferior_events): Remove 'static'. Set as
9225 '1'.
9226 (add_inferior): Improve message printed when
9227 'print_inferior_events' is on.
9228 (exit_inferior): Remove message printed when
9229 'print_inferior_events' is on.
9230 (detach_inferior): Improve message printed when
9231 'print_inferior_events' is on.
9232 (initialize_inferiors): Use 'add_inferior_silent' to set
9233 'current_inferior_'.
9234 * inferior.h (print_inferior_events): Declare here as
9235 'extern'.
9236 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
9237 '[Detaching...]' messages when 'print_inferior_events' is on.
9238 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
9239 as prefix/suffix for messages. Remove periods. Fix erroneous
9240 'Detaching after fork from child...', replace it by '... from
9241 parent...'.
9242 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
9243 prefix/suffix when printing 'Detaching...' messages. Print
9244 them when 'print_inferior_events' is on.
9245 * remote.c (remote_detach_1): Print message when detaching
9246 from inferior and '!is_fork_parent'.
9247
9248 2018-04-24 Tom Tromey <tom@tromey.com>
9249
9250 * cli-out.h: Reindent.
9251
9252 2018-04-24 Tom Tromey <tom@tromey.com>
9253
9254 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
9255 (cli_ui_out::do_field_string): Use fputs_filtered.
9256 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
9257
9258 2018-04-23 Tom Tromey <tom@tromey.com>
9259
9260 * guile/scm-frame.c (gdbscm_frame_read_var): Use
9261 gdb::unique_xmalloc_ptr.
9262
9263 2018-04-23 Tom Tromey <tom@tromey.com>
9264
9265 * configure: Rebuild.
9266
9267 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
9268
9269 PR gdb/23095
9270 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
9271 prepare_for_testing. Set normal_bp to r_debug_state if target
9272 is bsd.
9273
9274 2018-04-21 Pedro Alves <palves@redhat.com>
9275 Rajendra SY <rajendra.sy@gmail.com>
9276
9277 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
9278 * remote.c (extended_remote_attach): In all-stop mode, mark the
9279 thread as executing.
9280
9281 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9282
9283 * thread.c (thread_apply_all_command): Fix comment.
9284 (thread_command): Fix comment.
9285
9286 2018-04-10 Alan Hayward <alan.hayward@arm.com>
9287
9288 * common/tdesc.h (tdesc_create_feature): Remove xml filename
9289 parameter.
9290 * features/aarch64-core.c (create_feature_aarch64_core):
9291 Regenerate.
9292 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
9293 Likewise.
9294 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
9295 Likewise.
9296 * features/i386/32bit-avx512.c
9297 (create_feature_i386_32bit_avx512): Likewise.
9298 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
9299 Likewise.
9300 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
9301 Likewise.
9302 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
9303 Likewise.
9304 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
9305 Likewise.
9306 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
9307 Likewise.
9308 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
9309 Likewise.
9310 * features/i386/64bit-avx512.c
9311 (create_feature_i386_64bit_avx512): Likewise.
9312 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
9313 Likewise.
9314 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
9315 Likewise.
9316 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
9317 Likewise.
9318 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
9319 Likewise.
9320 * features/i386/64bit-segments.c
9321 (create_feature_i386_64bit_segments): Likewise.
9322 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
9323 Likewise.
9324 * features/i386/x32-core.c
9325 (create_feature_i386_x32_core): Likewise.
9326 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
9327 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
9328 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
9329 * target-descriptions.c: In generated code, don't pass xml
9330 filename.
9331
9332 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9333
9334 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
9335 (print_xml_feature::visit_post): Likewise.
9336 (print_xml_feature::visit): Likewise.
9337 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
9338 (print_xml_feature): Add new class.
9339 * regformats/regdat.sh: Null xmltarget on feature targets.
9340 * target-descriptions.c (struct target_desc): Add xmltarget.
9341 (maintenance_check_tdesc_xml_convert): Add unittest function.
9342 (tdesc_get_features_xml): Add function to get xml.
9343 (maintenance_check_xml_descriptions): Test xml generation.
9344 * xml-tdesc.c (string_read_description_xml): Add function.
9345 * xml-tdesc.h (string_read_description_xml): Add declaration.
9346
9347 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9348
9349 * features/Makefile: Add feature marker to targets with new style
9350 target descriptions.
9351 * regformats/aarch64.dat: Regenerate.
9352 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
9353 * regformats/i386/amd64-avx-linux.dat: Likewise.
9354 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
9355 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
9356 * regformats/i386/amd64-linux.dat: Likewise.
9357 * regformats/i386/amd64-mpx-linux.dat: Likewise.
9358 * regformats/i386/amd64.dat: Likewise.
9359 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
9360 * regformats/i386/i386-avx-linux.dat: Likewise.
9361 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
9362 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
9363 * regformats/i386/i386-linux.dat: Likewise.
9364 * regformats/i386/i386-mmx-linux.dat: Likewise.
9365 * regformats/i386/i386-mpx-linux.dat: Likewise.
9366 * regformats/i386/i386.dat: Likewise.
9367 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
9368 * regformats/i386/x32-avx-linux.dat: Likewise.
9369 * regformats/i386/x32-linux.dat: Likewise.
9370 * regformats/tic6x-c62x-linux.dat: Likewise.
9371 * regformats/tic6x-c64x-linux.dat: Likewise.
9372 * regformats/tic6x-c64xp-linux.dat: Likewise.
9373 * regformats/regdat.sh: Parse feature marker.
9374
9375 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9376
9377 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
9378 (tdesc_osabi_name): Likewise.
9379 * target-descriptions.c (tdesc_architecture_name): Add new
9380 function.
9381 (tdesc_osabi_name): Likewise.
9382
9383 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9384
9385 * common/tdesc.c (tdesc_predefined_type): Move to here.
9386 (tdesc_named_type): Likewise.
9387 (tdesc_create_vector): Likewise.
9388 (tdesc_create_struct): Likewise.
9389 (tdesc_set_struct_size): Likewise.
9390 (tdesc_create_union): Likewise.
9391 (tdesc_create_flags): Likewise.
9392 (tdesc_create_enum): Likewise.
9393 (tdesc_add_field): Likewise.
9394 (tdesc_add_typed_bitfield): Likewise.
9395 (tdesc_add_bitfield): Likewise.
9396 (tdesc_add_flag): Likewise.
9397 (tdesc_add_enum_value): Likewise.
9398 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
9399 (struct tdesc_type_vector): Likewise.
9400 (struct tdesc_type_field): Likewise.
9401 (struct tdesc_type_with_fields): Likewise.
9402 (tdesc_create_enum): Add declaration.
9403 (tdesc_add_typed_bitfield): Likewise.
9404 (tdesc_add_enum_value): Likewise.
9405 * target-descriptions.c (tdesc_type_field): Move from here.
9406 (tdesc_type_builtin): Likewise.
9407 (tdesc_type_vector): Likewise.
9408 (tdesc_type_with_fields): Likewise.
9409 (tdesc_predefined_types): Likewise.
9410 (tdesc_named_type): Likewise.
9411 (tdesc_create_vector): Likewise.
9412 (tdesc_create_struct): Likewise.
9413 (tdesc_set_struct_size): Likewise.
9414 (tdesc_create_union): Likewise.
9415 (tdesc_create_flags): Likewise.
9416 (tdesc_create_enum): Likewise.
9417 (tdesc_add_field): Likewise.
9418 (tdesc_add_typed_bitfield): Likewise.
9419 (tdesc_add_bitfield): Likewise.
9420 (tdesc_add_flag): Likewise.
9421 (tdesc_add_enum_value): Likewise.
9422 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
9423 (tdesc_add_typed_bitfield): Likewise.
9424 (tdesc_add_enum_value): Likewise.
9425
9426 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9427
9428 * common/tdesc.c (tdesc_feature::accept): Move to here.
9429 (tdesc_feature::operator==): Likewise.
9430 (tdesc_create_reg): Likewise.
9431 * common/tdesc.h (tdesc_type_kind): Likewise.
9432 (struct tdesc_type): Likewise.
9433 (struct tdesc_feature): Likewise.
9434 * regformats/regdat.sh: Create a feature.
9435 * target-descriptions.c (tdesc_type_kind): Move from here.
9436 (tdesc_type): Likewise.
9437 (tdesc_type_up): Likewise.
9438 (tdesc_feature): Likewise.
9439 (tdesc_create_reg): Likewise.
9440
9441 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9442
9443 * Makefile.in: Add arch/tdesc.c
9444 * common/tdesc.c: New file.
9445 * common/tdesc.h (tdesc_element_visitor): Move to here.
9446 (tdesc_element): Likewise.
9447 (tdesc_reg): Likewise.
9448 (tdesc_reg_up): Likewise.
9449 * regformats/regdef.h (reg): Add offset to constructors.
9450 * target-descriptions.c (tdesc_element_visitor): Move from here.
9451 (tdesc_element): Likewise.
9452 (tdesc_reg): Likewise.
9453 (tdesc_reg_up): Likewise.
9454
9455 2018-04-17 Tom Tromey <tom@tromey.com>
9456
9457 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
9458 discriminant field.
9459
9460 2018-04-17 Tom Tromey <tom@tromey.com>
9461
9462 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
9463
9464 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
9465
9466 * symtab.c (print_symbol_info): Skip printing filename and line
9467 number when `last' is NULL.
9468 (symtab_symbol_info): Use empty string instead of NULL for first
9469 invocation of print_symbol_info.
9470 (rbreak_command): Pass NULL to `last' parameter of
9471 print_symbol_info.
9472
9473 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
9474
9475 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
9476 instead of nullptr.
9477
9478 2018-04-16 Pedro Alves <palves@redhat.com>
9479
9480 * MAINTAINERS (sh): Remove.
9481 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
9482 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
9483 (ALLDEPFILES): Remove sh64-tdep.c.
9484 * NEWS: Mentions that support for SH-5/SH64 is removed.
9485 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
9486 (sh*-*-openbsd*): Ditto.
9487 (sh64-*-elf*): Remove.
9488 (sh*): Remove.
9489 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
9490 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
9491 * sh-tdep.c: No longer include "sh64-tdep.h".
9492 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
9493 * sh64-tdep.c, sh64-tdep.h: Remove files.
9494
9495 2018-04-16 Pedro Alves <palves@redhat.com>
9496
9497 * MAINTAINERS: Remove m88k.
9498 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
9499 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
9500 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
9501 * NEWS: Mention that support for m88k was removed.
9502 * configure.host (m88*-*-*): Remove support.
9503 * configure.nat (m88k-*-*): Remove support.
9504 * configure.tgt (m88*-*-openbsd*): Remove.
9505 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
9506
9507 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
9508
9509 * configure.tgt (x86_tobjs): New variable.
9510 (amd64_tobjs, i386_tobjs): Use it.
9511
9512 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9513
9514 * symtab.c (print_symbol_info): Precede the symbol definition by
9515 the line number when available.
9516 * NEWS: Advertise this enhancement.
9517
9518 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9519
9520 * NEWS (New options): announce set/show record btrace cpu.
9521 * btrace.c: Include record-btrace.h.
9522 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
9523 the vendor is unknown.
9524 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
9525 Maybe overwrite the btrace configuration's cpu.
9526 (btrace_compute_ftrace): Add cpu parameter. Update callers.
9527 (btrace_fetch): Add cpu parameter. Update callers.
9528 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
9529 Maybe overwrite the btrace configuration's cpu. Skip enabling
9530 errata workarounds if the vendor is unknown.
9531 * python/py-record-btrace.c: Include record-btrace.h.
9532 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
9533 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
9534 * record-btrace.c (record_btrace_cpu_state_kind): New.
9535 (record_btrace_cpu): New.
9536 (set_record_btrace_cpu_cmdlist): New.
9537 (record_btrace_get_cpu): New.
9538 (require_btrace_thread, record_btrace_info)
9539 (record_btrace_resume_thread): Call record_btrace_get_cpu.
9540 (cmd_set_record_btrace_cpu_none): New.
9541 (cmd_set_record_btrace_cpu_auto): New.
9542 (cmd_set_record_btrace_cpu): New.
9543 (cmd_show_record_btrace_cpu): New.
9544 (_initialize_record_btrace): Initialize set/show record btrace cpu
9545 commands.
9546 * record-btrace.h (record_btrace_get_cpu): New.
9547
9548 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9549
9550 * record.c (set_record_command): Fix typo in message.
9551
9552 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9553
9554 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
9555
9556 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9557
9558 * infrun.c (process_event_stop_test): Call
9559 gdbarch_in_indirect_branch_thunk.
9560 * gdbarch.sh (in_indirect_branch_thunk): New.
9561 * gdbarch.c: Regenerated.
9562 * gdbarch.h: Regenerated.
9563 * x86-tdep.h: New.
9564 * x86-tdep.c: New.
9565 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
9566 (HFILES_NO_SRCDIR): Add x86-tdep.h.
9567 (ALLDEPFILES): Add x86-tdep.c.
9568 * arch-utils.h (default_in_indirect_branch_thunk): New.
9569 * arch-utils.c (default_in_indirect_branch_thunk): New.
9570 * i386-tdep: Include x86-tdep.h.
9571 (i386_in_indirect_branch_thunk): New.
9572 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
9573 function.
9574 * amd64-tdep: Include x86-tdep.h.
9575 (amd64_in_indirect_branch_thunk): New.
9576 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
9577
9578 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
9579
9580 PR gdb/23053
9581 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
9582 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
9583 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
9584 regression.
9585
9586 2018-04-12 Tom Tromey <tom@tromey.com>
9587
9588 * rust-lang.c (rust_print_struct_def): Remove univariant code.
9589 (rust_evaluate_subexp): Likewise.
9590
9591 2018-04-12 Pedro Alves <palves@redhat.com>
9592
9593 * procfs.c (procfs_detach): Make forward declaration's prototype
9594 match definition's protototype.
9595 (proc_get_LDT_entry): Remove stale do_cleanups call.
9596
9597 2018-04-12 Pedro Alves <palves@redhat.com>
9598
9599 * target.h (target_ops::to_has_exited): Delete.
9600 (target_has_exited): Delete.
9601 * target-delegates.c: Regenerate.
9602
9603 2018-04-11 Pedro Alves <palves@redhat.com>
9604
9605 * target.c (fileio_fh_t::t): Add comment.
9606 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9607 (target_fileio_close): Handle a NULL target.
9608 (invalidate_fileio_fh): New.
9609 (target_close): Call it.
9610 * remote.c (remote_hostio_send_command): No longer check whether
9611 remote_desc is open.
9612
9613 2018-04-11 Pedro Alves <palves@redhat.com>
9614
9615 * target.c (fileio_fh_t): Make it a named struct instead of a
9616 typedef.
9617 (fileio_fh_t::is_closed): New method.
9618 (DEF_VEC_O (fileio_fh_t)): Remove.
9619 (fileio_fhandles): Now a std::vector.
9620 (is_closed_fileio_fh): Delete.
9621 (acquire_fileio_fd): Adjust. Rename parameters.
9622 (release_fileio_fd): Adjust.
9623 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
9624 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9625 (target_fileio_close): Adjust.
9626
9627 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
9628
9629 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
9630 index.
9631
9632 2018-04-10 Pedro Alves <palves@redhat.com>
9633
9634 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
9635 (scoped_finish_thread_state): New class.
9636 * infcmd.c (run_command_1): Use it instead of finish_thread_state
9637 cleanup.
9638 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
9639 (fetch_inferior_event, normal_stop): Likewise.
9640 * thread.c (finish_thread_state_cleanup): Delete.
9641
9642 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9643 Pedro Alves <palves@redhat.com>
9644
9645 * value.c: Include "selftest.h" and "common/array-view.h".
9646 (struct range) <operator ==>: New.
9647 (test_ranges_contain): New.
9648 (check_ranges_vector): New.
9649 (test_insert_into_bit_range_vector): New.
9650 (_initialize_values): Register selftests.
9651 * common/array-view.h (operator==, operator!=): New.
9652
9653 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9654
9655 * common/gdb_vecs.h (unordered_remove): Add overload that takes
9656 an iterator.
9657 * inline-frame.c: Include <algorithm>.
9658 (struct inline_state): Add constructor.
9659 (inline_state_s): Remove.
9660 (DEF_VEC_O(inline_state_s)): Remove.
9661 (inline_states): Change type to std::vector.
9662 (find_inline_frame_state): Adjust to std::vector.
9663 (allocate_inline_frame_state): Remove.
9664 (clear_inline_frame_state): Adjust to std::vector.
9665 (skip_inline_frames): Adjust to std::vector.
9666
9667 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9668
9669 * tracepoint.h (struct trace_state_variable): Add constructor.
9670 <name>: Change type to std::string.
9671 * tracepoint.c (tsv_s): Remove.
9672 (DEF_VEC_O(tsv_s)): Remove.
9673 (tvariables): Change to std::vector.
9674 (create_trace_state_variable): Adjust to std::vector.
9675 (find_trace_state_variable): Likewise.
9676 (find_trace_state_variable_by_number): Likewise.
9677 (delete_trace_state_variable): Likewise.
9678 (trace_variable_command): Adjust to std::string.
9679 (delete_trace_variable_command): Likewise.
9680 (tvariables_info_1): Adjust to std::vector.
9681 (save_trace_state_variables): Likewise.
9682 (start_tracing): Likewise.
9683 (merge_uploaded_trace_state_variables): Adjust to std::vector
9684 and std::string.
9685 * target.h (struct target_ops)
9686 <to_download_trace_state_variable>: Pass reference to
9687 trace_state_variable.
9688 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
9689 * target-delegates.c: Re-generate.
9690 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
9691 (mi_tsv_deleted): Likewise.
9692 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
9693 * remote.c (remote_download_trace_state_variable): Change
9694 pointer to reference and adjust.
9695 * make-target-delegates (parse_argtypes): Handle references.
9696 (write_function_header): Likewise.
9697 (munge_type): Likewise.
9698
9699 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9700
9701 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9702 string_view-selftests.c.
9703 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
9704 testsuite.
9705 * unittests/basic_string_view/cons/char/1.cc: Likewise.
9706 * unittests/basic_string_view/cons/char/2.cc: Likewise.
9707 * unittests/basic_string_view/cons/char/3.cc: Likewise.
9708 * unittests/basic_string_view/element_access/char/1.cc:
9709 Likewise.
9710 * unittests/basic_string_view/element_access/char/empty.cc:
9711 Likewise.
9712 * unittests/basic_string_view/element_access/char/front_back.cc:
9713 Likewise.
9714 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
9715 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
9716 Likewise.
9717 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
9718 Likewise.
9719 * unittests/basic_string_view/modifiers/swap/char/1.cc:
9720 Likewise.
9721 * unittests/basic_string_view/operations/compare/char/1.cc:
9722 Likewise.
9723 * unittests/basic_string_view/operations/compare/char/13650.cc:
9724 Likewise.
9725 * unittests/basic_string_view/operations/copy/char/1.cc:
9726 Likewise.
9727 * unittests/basic_string_view/operations/data/char/1.cc:
9728 Likewise.
9729 * unittests/basic_string_view/operations/find/char/1.cc:
9730 Likewise.
9731 * unittests/basic_string_view/operations/find/char/2.cc:
9732 Likewise.
9733 * unittests/basic_string_view/operations/find/char/3.cc:
9734 Likewise.
9735 * unittests/basic_string_view/operations/find/char/4.cc:
9736 Likewise.
9737 * unittests/basic_string_view/operations/rfind/char/1.cc:
9738 Likewise.
9739 * unittests/basic_string_view/operations/rfind/char/2.cc:
9740 Likewise.
9741 * unittests/basic_string_view/operations/rfind/char/3.cc:
9742 Likewise.
9743 * unittests/basic_string_view/operations/substr/char/1.cc:
9744 Likewise.
9745 * unittests/basic_string_view/operators/char/2.cc: Likewise.
9746 * unittests/string_view-selftests.c: New file.
9747
9748 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9749
9750 * unittests/basic_string_view/capacity/1.cc: New file.
9751 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
9752 * unittests/basic_string_view/cons/char/1.cc: New file.
9753 * unittests/basic_string_view/cons/char/2.cc: New file.
9754 * unittests/basic_string_view/cons/char/3.cc: New file.
9755 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
9756 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
9757 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
9758 * unittests/basic_string_view/element_access/char/1.cc: New file.
9759 * unittests/basic_string_view/element_access/char/2.cc: New file.
9760 * unittests/basic_string_view/element_access/char/empty.cc: New file.
9761 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
9762 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
9763 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
9764 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
9765 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
9766 * unittests/basic_string_view/include.cc: New file.
9767 * unittests/basic_string_view/inserters/char/1.cc: New file.
9768 * unittests/basic_string_view/inserters/char/2.cc: New file.
9769 * unittests/basic_string_view/inserters/char/3.cc: New file.
9770 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
9771 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
9772 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
9773 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
9774 * unittests/basic_string_view/literals/types.cc: New file.
9775 * unittests/basic_string_view/literals/values.cc: New file.
9776 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
9777 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
9778 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
9779 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
9780 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
9781 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
9782 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
9783 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
9784 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
9785 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
9786 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
9787 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
9788 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
9789 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
9790 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
9791 * unittests/basic_string_view/operations/data/char/1.cc: New file.
9792 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
9793 * unittests/basic_string_view/operations/find/char/1.cc: New file.
9794 * unittests/basic_string_view/operations/find/char/2.cc: New file.
9795 * unittests/basic_string_view/operations/find/char/3.cc: New file.
9796 * unittests/basic_string_view/operations/find/char/4.cc: New file.
9797 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
9798 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
9799 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
9800 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
9801 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
9802 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
9803 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
9804 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
9805 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
9806 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
9807 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
9808 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
9809 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
9810 * unittests/basic_string_view/operators/char/2.cc: New file.
9811 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
9812 * unittests/basic_string_view/range_access/char/1.cc: New file.
9813 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
9814 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
9815 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
9816 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
9817 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
9818 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
9819 * unittests/basic_string_view/requirements/typedefs.cc: New file.
9820 * unittests/basic_string_view/typedefs.cc: New file.
9821 * unittests/basic_string_view/types/1.cc: New file.
9822
9823 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9824
9825 * common/gdb_string_view.h: Remove libstdc++ implementation
9826 details, adjust to gdb reality.
9827 * common/gdb_string_view.tcc: Likewise.
9828 * cli/cli-script.c (struct string_view): Remove.
9829 (user_args) <m_args>: Change element type to gdb::string_view.
9830 (user_args::insert_args): Adjust.
9831
9832 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9833
9834 * common/gdb_string_view.h: New file.
9835 * common/gdb_string_view.tcc: New file.
9836
9837 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9838
9839 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
9840 * configure: Re-generate.
9841
9842 2018-04-09 Pedro Alves <palves@redhat.com>
9843
9844 * gdbarch.sh: Include "observable.h" instead of "observer.h".
9845 (set_target_gdbarch): Call
9846 gdb::observers::architecture_changed.notify instead of
9847 observer_notify_architecture_changed.
9848
9849 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9850
9851 * tracepoint.c (struct current_traceframe_cleanup): Remove.
9852 (do_restore_current_traceframe_cleanup): Remove.
9853 (restore_current_traceframe_cleanup_dtor): Remove.
9854 (make_cleanup_restore_current_traceframe): Remove.
9855 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
9856 New.
9857 * tracepoint.h (struct scoped_restore_current_traceframe): New.
9858 * infrun.c (fetch_inferior_event): Use
9859 scoped_restore_current_traceframe.
9860
9861 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9862
9863 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
9864 Remove.
9865 <n_allocated_type_units>: Remove.
9866 <all_type_units>: Change to std::vector.
9867 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9868 to std::vector change.
9869 (dwarf2_per_objfile::get_cutu): Likewise.
9870 (dwarf2_per_objfile::get_tu): Likewise.
9871 (create_signatured_type_table_from_index): Likewise.
9872 (create_signatured_type_table_from_debug_names): Likewise.
9873 (dw2_symtab_iter_next): Likewise.
9874 (dw2_print_stats): Likewise.
9875 (dw2_expand_all_symtabs): Likewise.
9876 (dw2_expand_marked_cus): Likewise.
9877 (dw2_debug_names_iterator::next): Likewise.
9878 (dwarf2_initialize_objfile): Likewise.
9879 (add_signatured_type_cu_to_table): Likewise.
9880 (create_all_type_units): Likewise.
9881 (add_type_unit): Likewise.
9882 (struct tu_abbrev_offset): Add constructor.
9883 (build_type_psymtabs_1): Adjust to std::vector change.
9884 (print_tu_stats): Likewise.
9885 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9886 (write_debug_names): Likewise.
9887
9888 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9889
9890 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
9891 Make an std::vector.
9892 <n_comp_units>: Remove.
9893 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9894 to std::vector change.
9895 (dwarf2_per_objfile::get_cutu): Likewise.
9896 (dwarf2_per_objfile::get_cu): Likewise.
9897 (create_cus_from_index): Likewise.
9898 (create_addrmap_from_index): Likewise.
9899 (create_addrmap_from_aranges): Likewise.
9900 (dwarf2_read_index): Likewise.
9901 (dw2_find_last_source_symtab): Likewise.
9902 (dw2_map_symtabs_matching_filename): Likewise.
9903 (dw2_symtab_iter_next): Likewise.
9904 (dw2_print_stats): Likewise.
9905 (dw2_expand_all_symtabs): Likewise.
9906 (dw2_expand_symtabs_with_fullname): Likewise.
9907 (dw2_expand_marked_cus): Likewise.
9908 (dw2_map_symbol_filenames): Likewise.
9909 (create_cus_from_debug_names): Likewise.
9910 (dwarf2_read_debug_names): Likewise.
9911 (dw2_debug_names_iterator::next): Likewise.
9912 (dwarf2_initialize_objfile): Likewise.
9913 (set_partial_user): Likewise.
9914 (dwarf2_build_psymtabs_hard): Likewise.
9915 (read_comp_units_from_section): Remove arguments, adjust to
9916 std::vector change.
9917 (create_all_comp_units): Adjust to std::vector and
9918 read_comp_units_from_section changes.
9919 (dwarf2_find_containing_comp_unit): Adjust to std::vector
9920 change.
9921 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9922 (psyms_seen_size): Likewise.
9923 (write_gdbindex): Likewise.
9924 (write_debug_names): Likewise.
9925
9926 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9927
9928 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
9929 with dwarf2_per_objfile.
9930 (create_cus_from_index): Likewise.
9931 (create_signatured_type_table_from_index): Likewise.
9932 (dwarf2_read_index): Likewise.
9933 (dwarf2_initialize_objfile): Likewise.
9934 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
9935 per_cu rather than get_dwarf2_per_objfile.
9936
9937 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9938
9939 * dwarf2read.h (struct signatured_type): Forward declare.
9940 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
9941 New methods.
9942 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
9943 (dw2_get_cutu): ...this.
9944 (dwarf2_per_objfile::get_cu): Rename from...
9945 (dw2_get_cu): ...this.
9946 (dwarf2_per_objfile::get_tu): New.
9947 (create_addrmap_from_index): Adjust.
9948 (create_addrmap_from_aranges): Adjust.
9949 (dw2_find_last_source_symtab): Adjust.
9950 (dw2_map_symtabs_matching_filename): Adjust.
9951 (dw2_symtab_iter_next): Adjust.
9952 (dw2_print_stats): Adjust.
9953 (dw2_expand_all_symtabs): Adjust.
9954 (dw2_expand_symtabs_with_fullname): Adjust.
9955 (dw2_expand_marked_cus): Adjust.
9956 (dw_expand_symtabs_matching_file_matcher): Adjust.
9957 (dw2_map_symbol_filenames): Adjust.
9958 (dw2_debug_names_iterator::next): Adjust.
9959 (dwarf2_initialize_objfile): Adjust.
9960 (set_partial_user): Adjust.
9961 (dwarf2_build_psymtabs_hard): Adjust.
9962
9963 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9964
9965 * dwarf2read.c (create_signatured_type_table_from_debug_names):
9966 Remove unused variables.
9967 (dw2_map_symtabs_matching_filename): Likewise.
9968 (dwarf2_record_block_ranges): Likewise.
9969 (dwarf2_read_addr_index): Likewise.
9970 (follow_die_offset): Likewise.
9971
9972 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9973
9974 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
9975 to symbol_file_add_main.
9976
9977 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9978
9979 PR mi/22299
9980 * mi/mi-console.c (do_fputc_async_safe): New.
9981 (mi_console_file::write_async_safe): New.
9982 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
9983 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
9984 New.
9985 * ui-file.c (ui_file::putstrn): Adjust call to
9986 fputstrn_unfiltered.
9987 * utils.c (printchar): Replace do_fputs and do_fprintf
9988 parameters by do_fputc.
9989 (fputstr_filtered): Adjust call to printchar.
9990 (fputstr_unfiltered): Likewise.
9991 (fputstrn_filtered): Likewise.
9992 (fputstrn_unfiltered): Add do_fputc parameter, pass to
9993 printchar.
9994 * utils.h (do_fputc_ftype): New typedef.
9995 (fputstrn_unfiltered): Add do_fputc parameter.
9996
9997 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9998
9999 * regformats/i386/i386-avx.dat: Remove.
10000
10001 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10002
10003 PR gdb/22979
10004 * amd64-tdep.c (amd64_none_init_abi): New function.
10005 (amd64_x32_none_init_abi): New function.
10006 (_initialize_amd64_tdep): Register handlers for x86-64 and
10007 x64_32 with GDB_OSABI_NONE.
10008 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
10009 GDB_OSABI_NONE osabi.
10010
10011 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10012
10013 PR gdb/22980
10014 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
10015 GDB_OSABI_NONE.
10016 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
10017 * osabi.c (gdb_osabi_names): Add "unknown" entry.
10018
10019 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10020
10021 * common/byte-vector.h (char_vector): New type.
10022 * target.h (target_read_alloc): Return
10023 gdb::optional<byte_vector>.
10024 (target_read_stralloc): Return gdb::optional<char_vector>.
10025 (target_get_osdata): Return gdb::optional<char_vector>.
10026 * target.c (target_read_alloc_1): Templatize. Replacement
10027 manual memory management with vector.
10028 (target_read_alloc): Change return type, adjust.
10029 (target_read_stralloc): Change return type, adjust.
10030 (target_get_osdata): Change return type, adjust.
10031 * auxv.c (struct auxv_info) <length>: Remove.
10032 <data>: Change type to gdb::optional<byte_vector>.
10033 (auxv_inferior_data_cleanup): Free auxv_info with delete.
10034 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
10035 (target_auxv_search): Adjust.
10036 (fprint_target_auxv): Adjust.
10037 * avr-tdep.c (avr_io_reg_read_command): Adjust.
10038 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
10039 (linux_make_corefile_notes): Adjust.
10040 * osdata.c (get_osdata): Adjust.
10041 * remote.c (remote_get_threads_with_qxfer): Adjust.
10042 (remote_memory_map): Adjust.
10043 (remote_traceframe_info): Adjust.
10044 (btrace_read_config): Adjust.
10045 (remote_read_btrace): Adjust.
10046 (remote_pid_to_exec_file): Adjust.
10047 * solib-aix.c (solib_aix_get_library_list): Adjust.
10048 * solib-dsbt.c (decode_loadmap): Don't free buf.
10049 (dsbt_get_initial_loadmaps): Adjust.
10050 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
10051 * solib-target.c (solib_target_current_sos): Adjust.
10052 * tracepoint.c (sdata_make_value): Adjust.
10053 * xml-support.c (xinclude_start_include): Adjust.
10054 (xml_fetch_content_from_file): Adjust.
10055 * xml-support.h (xml_fetch_another): Change return type.
10056 (xml_fetch_content_from_file): Change return type.
10057 * xml-syscall.c (xml_init_syscalls_info): Adjust.
10058 * xml-tdesc.c (file_read_description_xml): Adjust.
10059 (fetch_available_features_from_target): Change return type.
10060 (target_fetch_description_xml): Adjust.
10061 (target_read_description_xml): Adjust.
10062
10063 2018-04-06 Tom Tromey <tom@tromey.com>
10064
10065 * value.c (~value): Update.
10066 (struct value) <contents>: Now unique_xmalloc_ptr.
10067 (value_contents_bits_eq, allocate_value_contents)
10068 (value_contents_raw, value_contents_all_raw)
10069 (value_contents_for_printing, value_contents_for_printing_const)
10070 (set_value_enclosing_type): Update.
10071
10072 2018-04-06 Tom Tromey <tom@tromey.com>
10073
10074 * value.c (range_s): Remove typedef, VEC.
10075 (struct range): Add operator<.
10076 (range_lessthan): Remove.
10077 (ranges_contain): Change type.
10078 (~value): Update.
10079 (struct value) <unavailable, optimized_out>: Now std::vector.
10080 (value_entirely_available)
10081 (value_entirely_covered_by_range_vector)
10082 (value_entirely_unavailable, value_entirely_optimized_out):
10083 Update.
10084 (insert_into_bit_range_vector): Change argument type.
10085 (find_first_range_overlap): Likewise.
10086 (struct ranges_and_idx, value_contents_bits_eq)
10087 (require_not_optimized_out, require_available): Update.
10088 (ranges_copy_adjusted): Change argument types.
10089 (value_optimized_out, value_copy, value_fetch_lazy): Update.
10090
10091 2018-04-06 Tom Tromey <tom@tromey.com>
10092
10093 * value.c (~value): Update.
10094 (struct value) <parent>: Now a value_ref_ptr.
10095 (value_parent, set_value_parent, value_address, value_copy):
10096 Update.
10097
10098 2018-04-06 Tom Tromey <tom@tromey.com>
10099
10100 * value.c (struct value): Add constructor, destructor, and member
10101 initializers.
10102 (allocate_value_lazy, value_decref): Update.
10103
10104 2018-04-06 Tom Tromey <tom@tromey.com>
10105
10106 * value.c (struct value) <released, next>: Remove.
10107 (all_values): Now a std::vector.
10108 (allocate_value_lazy): Update.
10109 (value_next): Remove.
10110 (value_mark, value_free_to_mark, release_value)
10111 (value_release_to_mark): Update.
10112
10113 2018-04-06 Tom Tromey <tom@tromey.com>
10114
10115 * value.h (fetch_subexp_value, value_release_to_mark): Update.
10116 (free_value_chain): Remove.
10117 * value.c (free_value_chain): Remove.
10118 (value_release_to_mark): Return a std::vector.
10119 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
10120 std::vector.
10121 (check_condition): Update.
10122 * eval.c (fetch_subexp_value): Change "val_chain" to a
10123 std::vector.
10124 * breakpoint.c (update_watchpoint): Update.
10125 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
10126
10127 2018-04-06 Tom Tromey <tom@tromey.com>
10128
10129 * value.h (free_all_values): Remove.
10130 * value.c (free_all_values): Remove.
10131
10132 2018-04-06 Tom Tromey <tom@tromey.com>
10133
10134 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
10135 (value_history_chain, value_history_count): Remove.
10136 (value_history): New global.
10137 (record_latest_value, access_value_history, show_values)
10138 (preserve_values): Update.
10139
10140 2018-04-06 Tom Tromey <tom@tromey.com>
10141
10142 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
10143 * varobj.c (varobj_set_display_format, varobj_set_value)
10144 (install_default_visualizer, construct_visualizer)
10145 (install_new_value, ~varobj, varobj_get_value_type)
10146 (my_value_of_variable, varobj_editable_p): Update.
10147 * c-varobj.c (c_describe_child, c_value_of_variable)
10148 (cplus_number_of_children, cplus_describe_child): Update.
10149 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
10150 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
10151 (ada_value_of_variable, ada_value_is_changeable_p): Update.
10152
10153 2018-04-06 Tom Tromey <tom@tromey.com>
10154
10155 * printcmd.c (last_examine_address): Change type to
10156 value_ref_ptr.
10157 (do_examine, x_command): Update.
10158
10159 2018-04-06 Tom Tromey <tom@tromey.com>
10160
10161 * value.c (release_value): Update.
10162 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
10163 (struct bpstats) <val>: Now a value_ref_ptr.
10164 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
10165 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
10166 (~watchpoint, print_it_watchpoint, watch_command_1)
10167 (invalidate_bp_value_on_memory_change): Update.
10168
10169 2018-04-06 Tom Tromey <tom@tromey.com>
10170
10171 * varobj.c (varobj_clear_saved_item)
10172 (update_dynamic_varobj_children, install_new_value, ~varobj):
10173 Update.
10174 * value.h (value_incref): Move declaration earlier.
10175 (value_decref): Rename from value_free.
10176 (struct value_ref_policy): New.
10177 (value_ref_ptr): New typedef.
10178 (struct value_deleter): Remove.
10179 (gdb_value_up): Remove typedef.
10180 (release_value): Change return type.
10181 (release_value_or_incref): Remove.
10182 * value.c (set_value_parent): Update.
10183 (value_incref): Change return type.
10184 (value_decref): Rename from value_free.
10185 (value_free_to_mark, free_all_values, free_value_chain): Update.
10186 (release_value): Return value_ref_ptr.
10187 (release_value_or_incref): Remove.
10188 (record_latest_value, set_internalvar, clear_internalvar):
10189 Update.
10190 * stack.c (info_frame_command): Don't call value_free.
10191 * python/py-value.c (valpy_dealloc, valpy_new)
10192 (value_to_value_object): Update.
10193 * printcmd.c (do_examine): Update.
10194 * opencl-lang.c (lval_func_free_closure): Update.
10195 * mi/mi-main.c (register_changed_p): Don't call value_free.
10196 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
10197 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
10198 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
10199 value_free.
10200 * guile/scm-value.c (vlscm_free_value_smob)
10201 (vlscm_scm_from_value): Update.
10202 * frame.c (frame_register_unwind, frame_unwind_register_signed)
10203 (frame_unwind_register_unsigned, get_frame_register_bytes)
10204 (put_frame_register_bytes): Don't call value_free.
10205 * findvar.c (address_from_register): Don't call value_free.
10206 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
10207 * dwarf2loc.c (entry_data_value_free_closure)
10208 (value_of_dwarf_reg_entry, free_pieced_value_closure)
10209 (dwarf2_evaluate_loc_desc_full): Update.
10210 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
10211 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
10212 (~watchpoint, watch_command_1)
10213 (invalidate_bp_value_on_memory_change): Update.
10214 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
10215
10216 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
10217
10218 PR gdb/23022
10219 * warning.m4: Add -Wno-error=deprecated-register.
10220 * configure: Re-generate.
10221
10222 2018-04-05 Tom Tromey <tom@tromey.com>
10223
10224 * linespec.h: Remove include of "vec.h".
10225
10226 2018-04-05 Tom Tromey <tom@tromey.com>
10227
10228 * linespec.c (typep): Remove typedef.
10229 (find_methods, find_superclass_methods): Take a std::vector.
10230 (find_method): Use std::vector.
10231
10232 2018-04-05 Tom Tromey <tom@tromey.com>
10233
10234 * utils.c (compare_strings): Remove.
10235 * utils.h (compare_strings): Remove.
10236 * objc-lang.h (find_imps): Update.
10237 * objc-lang.c (find_methods): Take a std::vector.
10238 (uniquify_strings, find_imps): Likewise.
10239 * linespec.c (find_methods): Take a std::vector.
10240 (decode_objc): Use std::vector.
10241 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
10242 a std::vector.
10243 (find_method, find_function_symbols): Use std::vector.
10244
10245 2018-04-05 Tom Tromey <tom@tromey.com>
10246
10247 * completer.c (completion_tracker::completion_tracker): Remove
10248 cast.
10249 (completion_tracker::discard_completions): Likewise.
10250 * breakpoint.c (ambiguous_names_p): Remove cast.
10251 * ada-lang.c (_initialize_ada_language): Remove cast.
10252 * utils.h (streq): Update.
10253 (streq_hash): Add new declaration.
10254 * utils.c (streq): Return bool.
10255 (streq_hash): New function.
10256
10257 2018-04-05 Tom Tromey <tom@tromey.com>
10258
10259 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
10260 Remove a string copy.
10261
10262 2018-04-05 Tom Tromey <tom@tromey.com>
10263
10264 * linespec.c (filter_results): Use std::vector.
10265 (decode_line_2, decode_line_full): Update.
10266
10267 2018-04-05 Tom Tromey <tom@tromey.com>
10268
10269 * linespec.c (canonical_to_fullform): Return std::string.
10270 (filter_results): Update.
10271 (struct decode_line_2_item): Add constructor.
10272 <fullform, displayform>: Now std::string.
10273 (decode_line_2_compare_items): Now a std::sort comparator.
10274 (decode_line_2): Update.
10275
10276 2018-04-05 Tom Tromey <tom@tromey.com>
10277
10278 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
10279 (unexpected_linespec_error): Update.
10280 (linespec_parse_basic, parse_linespec): Update.
10281
10282 2018-04-05 Tom Tromey <tom@tromey.com>
10283
10284 * linespec.c (linespec_parse_basic): Reindent.
10285
10286 2018-04-05 Tom Tromey <tom@tromey.com>
10287
10288 * minsyms.h (iterate_over_minimal_symbols): Update.
10289 * minsyms.c (iterate_over_minimal_symbols): Take a
10290 gdb::function_view.
10291 * linespec.c (struct collect_minsyms): Remove.
10292 (compare_msyms): Now a std::sort comparator.
10293 (add_minsym): Add parameters.
10294 (search_minsyms_for_name): Update. Use std::vector.
10295
10296 2018-04-03 Tom Tromey <tom@tromey.com>
10297
10298 * mipsread.c (read_alphacoff_dynamic_symtab): Use
10299 gdb::byte_vector.
10300
10301 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10302
10303 * MAINTAINERS (Write After Approval): Add Weimin Pan.
10304
10305 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10306
10307 PR gdb/16959
10308 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
10309 printing static type.
10310
10311 2018-04-01 Tom Tromey <tom@tromey.com>
10312
10313 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
10314 (rs6000_xfer_shared_libraries): Update.
10315
10316 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
10317
10318 * common/gdb_vecs.h (char_ptr): Remove.
10319 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
10320
10321 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10322
10323 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
10324 with std::vector.
10325 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
10326
10327 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10328
10329 * tracepoint.h (struct uploaded_tp): Initialize fields.
10330 <actions, step_actions, cmd_strings>: Change type to
10331 std::vector<char *>.
10332 * tracepoint.c (get_uploaded_tp): Allocate with new.
10333 (free_uploaded_tps): Free with delete.
10334 (parse_tracepoint_definition): Adjust to std::vector change.
10335 * breakpoint.c (read_uploaded_action): Likewise.
10336 (create_tracepoint_from_upload): Likewise.
10337 * ctf.c (ctf_write_uploaded_tp): Likewise.
10338 (SET_ARRAY_FIELD): Likewise.
10339 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
10340
10341 2018-03-30 Tom Tromey <tom@tromey.com>
10342
10343 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
10344 std::unique_ptr.
10345 (svr4_keep_data_in_core): Update.
10346 (svr4_read_so_list): Update.
10347
10348 2018-03-30 Tom Tromey <tom@tromey.com>
10349
10350 * windows-nat.c (handle_output_debug_string, handle_exception):
10351 Update.
10352 * target.h (target_read_string): Update.
10353 * target.c (target_read_string): Change "string" to
10354 unique_xmalloc_ptr.
10355 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
10356 Update.
10357 * solib-frv.c (frv_current_sos): Update.
10358 * solib-dsbt.c (dsbt_current_sos): Update.
10359 * solib-darwin.c (darwin_current_sos): Update.
10360 * linux-thread-db.c (inferior_has_bug): Update.
10361 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
10362 Update. Remove alloca.
10363 * ada-lang.c (ada_main_name): Update.
10364
10365 2018-03-30 Tom Tromey <tom@tromey.com>
10366
10367 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
10368 (struct dwo_file_deleter): New.
10369 (dwo_file_up): New typedef.
10370 (open_and_init_dwo_file): Use dwo_file_up.
10371 (free_dwo_file_cleanup): Remove.
10372
10373 2018-03-30 Tom Tromey <tom@tromey.com>
10374
10375 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
10376 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
10377
10378 2018-03-30 Tom Tromey <tom@tromey.com>
10379
10380 * dwarf2read.c (class free_cached_comp_units): New class.
10381 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
10382 (free_cached_comp_units): Remove function.
10383
10384 2018-03-30 Tom Tromey <tom@tromey.com>
10385
10386 * utils.h (make_cleanup_unpush_target): Remove.
10387 * inf-ptrace.c (struct target_unpusher): New.
10388 (target_unpush_up) New typedef.
10389 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
10390 target_unpush_up.
10391 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
10392
10393 2018-03-27 Tom Tromey <tom@tromey.com>
10394
10395 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
10396
10397 2018-03-27 Pedro Alves <palves@redhat.com>
10398 Tom Tromey <tom@tromey.com>
10399
10400 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
10401 destructor. Now a class.
10402 (gdb_readline_wrapper_cleanup): Remove function.
10403 (gdb_readline_wrapper): Remove cleanups.
10404
10405 2018-03-27 Tom Tromey <tom@tromey.com>
10406
10407 * typeprint.h (struct type_print_options) <local_typedefs,
10408 global_typedefs>: Remove "struct" keyword.
10409 (class typedef_hash_table): New class.
10410 (recursively_update_typedef_hash, add_template_parameters)
10411 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
10412 (find_typedef_in_hash): Don't declare.
10413 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
10414 (typedef_hash_table::recursively_update): Rename from
10415 recursively_update_typedef_hash. Now a member.
10416 (typedef_hash_table::add_template_parameters): Rename from
10417 add_template_parameters. Now a member.
10418 (typedef_hash_table::typedef_hash_table): Now a constructor;
10419 rename from create_typedef_hash.
10420 (typedef_hash_table::~typedef_hash_table): Now a destructor;
10421 rename from free_typedef_hash.
10422 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
10423 (do_free_global_table): Remove.
10424 (typedef_hash_table::typedef_hash_table): New constructor; renamed
10425 from copy_type_recursive.
10426 (create_global_typedef_table): Remove.
10427 (typedef_hash_table::find_global_typedef): Now a member of
10428 typedef_hash_table.
10429 (typedef_hash_table::find_typedef): Rename from
10430 find_typedef_in_hash; now a member.
10431 (whatis_exp): Update.
10432 * extension.h (struct ext_lang_type_printers): Add constructor and
10433 destructor.
10434 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
10435 declare.
10436 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
10437 Now a constructor; rename from start_ext_lang_type_printers.
10438 (ext_lang_type_printers): Now a destructor; rename from
10439 free_ext_lang_type_printers.
10440 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
10441 Update.
10442 (c_type_print_base_struct_union): Update. Remove cleanups.
10443
10444 2018-03-27 Tom Tromey <tom@tromey.com>
10445
10446 * dwarf-index-write.c: Include <cmath>.
10447
10448 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10449
10450 * NEWS: Add entry describing new "set|show varsize-limit" command.
10451 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
10452 command.
10453 * printcmd.c (_initialize_printcmd): Add "set var" alias of
10454 "set variable".
10455
10456 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
10457
10458 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
10459 dwarf-index-write.c
10460 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
10461 * dwarf-index-common.c: New file.
10462 * dwarf-index-common.h: New file.
10463 * dwarf-index-write.c: New file.
10464 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
10465 (struct dwarf2_section_info): Move from here.
10466 (dwarf2_section_info_def): Likewise.
10467 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
10468 (offset_type): Likewise.
10469 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
10470 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
10471 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
10472 (byte_swap): Likewise.
10473 (MAYBE_SWAP): Likewise.
10474 (dwarf2_per_cu_ptr): Likewise.
10475 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
10476 (struct tu_stats): Likewise.
10477 (struct dwarf2_per_objfile): Likewise.
10478 (struct dwarf2_per_cu_data): Likewise.
10479 (struct signatured_type): Likewise.
10480 (sig_type_ptr): Likewise.
10481 (DEF_VEC_P (sig_type_ptr)): Likewise.
10482 (INDEX4_SUFFIX): Likewise.
10483 (INDEX5_SUFFIX): Likewise.
10484 (DEBUG_STR_SUFFIX): Likewise.
10485 (dwarf2_read_section): Make non-static.
10486 (mapped_index_string_hash): Move from here.
10487 (dwarf5_djb_hash): Likewise.
10488 (file_write): Likewise.
10489 (class data_buf): Likewise.
10490 (struct symtab_index_entry): Likewise.
10491 (struct mapped_symtab): Likewise.
10492 (find_slot): Likewise.
10493 (hash_expand): Likewise.
10494 (add_index_entry): Likewise.
10495 (uniquify_cu_indices): Likewise.
10496 (class c_str_view): Likewise.
10497 (class c_str_view_hasher): Likewise.
10498 (class vector_hasher): Likewise.
10499 (write_hash_table): Likewise.
10500 (psym_index_map): Likewise.
10501 (struct addrmap_index_data): Likewise.
10502 (add_address_entry): Likewise.
10503 (add_address_entry_worker): Likewise.
10504 (write_address_map): Likewise.
10505 (symbol_kind): Likewise.
10506 (write_psymbols): Likewise.
10507 (struct signatured_type_index_data): Likewise.
10508 (write_one_signatured_type): Likewise.
10509 (recursively_count_psymbols): Likewise.
10510 (recursively_write_psymbols): Likewise.
10511 (class debug_names): Likewise.
10512 (check_dwarf64_offsets): Likewise.
10513 (psyms_seen_size): Likewise.
10514 (write_gdbindex): Likewise.
10515 (write_debug_names): Likewise.
10516 (assert_file_size): Likewise.
10517 (write_psymtabs_to_index): Likewise.
10518 (save_gdb_index_command): Likewise.
10519 (_initialize_dwarf2_read): Don't register the "save gdb-index"
10520 command.
10521 * dwarf2read.h: New file.
10522
10523 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10524
10525 PR gdb/22670
10526 * dwarf2read.c (dwarf2_physname): Do not return the demangled
10527 symbol name if the CU's language stores symbol names in linkage
10528 format.
10529 * language.h (struct language_defn)
10530 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
10531 all instances of this struct.
10532
10533 2018-03-26 Tom Tromey <tom@tromey.com>
10534
10535 * stack.c (backtrace_command_1): Remove verbose code.
10536
10537 2018-03-26 Tom Tromey <tom@tromey.com>
10538
10539 * python/py-framefilter.c (py_print_type): Don't catch
10540 exceptions. Return void.
10541 (py_print_value): Likewise.
10542 (py_print_single_arg): Likewise.
10543 (enumerate_args): Don't catch exceptions.
10544 (py_print_args): Likewise.
10545 (py_print_frame): Likewise.
10546 (gdbpy_apply_frame_filter): Catch exceptions here.
10547
10548 2018-03-26 Tom Tromey <tom@tromey.com>
10549
10550 * stack.c (_initialize_stack): Remove trailing newlines from help
10551 text. Add "Usage" line to "backtrace" help.
10552
10553 2018-03-26 Tom Tromey <tom@tromey.com>
10554
10555 PR python/16486:
10556 * python/py-framefilter.c (py_print_args): Call wrap_hint.
10557
10558 2018-03-26 Tom Tromey <tom@tromey.com>
10559
10560 * python/py-framefilter.c (py_print_single_arg): Return
10561 EXT_LANG_BT_ERROR from catch.
10562
10563 2018-03-26 Tom Tromey <tom@tromey.com>
10564
10565 PR backtrace/15584:
10566 * stack.c (backtrace_command_1): Move some code into no-filters
10567 "if".
10568
10569 2018-03-26 Tom Tromey <tom@tromey.com>
10570
10571 * python/py-framefilter.c (throw_quit_or_print_exception): New
10572 function.
10573 (gdbpy_apply_frame_filter): Use it.
10574
10575 2018-03-26 Tom Tromey <tom@tromey.com>
10576
10577 PR cli/17716:
10578 * python/py-framefilter.c (py_print_type, py_print_value)
10579 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
10580 RETURN_MASK_ERROR.
10581
10582 2018-03-26 Tom Tromey <tom@tromey.com>
10583
10584 * python/py-framefilter.c (enumerate_args): Use
10585 gdb::unique_xmalloc_ptr.
10586
10587 2018-03-26 Tom Tromey <tom@tromey.com>
10588
10589 * python/py-framefilter.c (py_print_frame): Return
10590 EXT_LANG_BT_OK.
10591 (gdbpy_apply_frame_filter): Update comment.
10592 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
10593 Remove.
10594 <EXT_LANG_BT_NO_FILTERS>: Change value.
10595
10596 2018-03-26 Tom Tromey <tom@tromey.com>
10597
10598 PR backtrace/15582:
10599 * stack.c (backtrace_command): Parse "hide" argument.
10600 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
10601 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
10602 constant.
10603
10604 2018-03-26 Tom Tromey <tom@tromey.com>
10605
10606 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
10607 add "flags".
10608 (backtrace_command): Remove "fulltrace", add "flags".
10609
10610 2018-03-26 Tom Tromey <tom@tromey.com>
10611
10612 * stack.c (backtrace_command): Rewrite command line parsing.
10613
10614 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10615
10616 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
10617
10618 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10619
10620 * filename-seen-cache.h: Add include guard.
10621
10622 2018-03-26 Keith Seitz <keiths@redhat.com>
10623
10624 * symfile.c (place_section): Remove "struct" from section_addr_info
10625 in comment.
10626 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
10627 "struct" keyword from section_addr_info.
10628
10629 2018-03-26 Alan Hayward <alan.hayward@arm.com>
10630
10631 * regformats/regdef.h (reg): Add constructors.
10632
10633 2018-03-25 Pedro Alves <palves@redhat.com>
10634
10635 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
10636 if then/else bodies in var_func_name extraction.
10637
10638 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
10639
10640 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
10641 lookup_minimal_symbol() to find symbol entry.
10642 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
10643
10644 2018-03-23 Keith Seitz <keiths@redhat.com>
10645
10646 PR c++/22968
10647 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
10648 nested type definitions for C++, too.
10649
10650 2018-03-23 Tom Tromey <tom@tromey.com>
10651
10652 * machoread.c (struct oso_el): Add a constructor. Don't define as
10653 a typedef.
10654 (macho_register_oso): Remove.
10655 (macho_symtab_read): Take a std::vector.
10656 (oso_el_compare_name): Now a std::sort comparator.
10657 (macho_symfile_read_all_oso): Take a std::vector.
10658 (macho_symfile_read): Use std::vector. Remove cleanups.
10659
10660 2018-03-22 Tom Tromey <tom@tromey.com>
10661
10662 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
10663 (record_full_goto_bookmark): Use std::string.
10664
10665 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10666
10667 PR tdep/18295
10668 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
10669 a single mask.
10670
10671 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10672
10673 * rs6000-tdep.c (store_insn_p): New function.
10674 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
10675 and cr_reg to their unshifted values. Use store_insn_p to
10676 match LR saves using either R1 or fdata->alloca_reg. Use
10677 store_insn_p to match CR saves. Set alloca_reg_offset
10678 when alloca_reg and framep are set. Remove lr_reg shift
10679 when assigning to fdata->lr_register.
10680
10681 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
10682
10683 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
10684 command line args instead of emitting a warning.
10685
10686 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10687
10688 * tracepoint.h (struct static_tracepoint_marker): Initialize
10689 fields, define default constructor, move constructor and move
10690 assignment, disable the rest.
10691 <str_id, extra>: Make std::string.
10692 (release_static_tracepoint_marker): Remove.
10693 (free_current_marker): Remove.
10694 * tracepoint.c (free_current_marker): Remove.
10695 (parse_static_tracepoint_marker_definition): Adjust to
10696 std::string, use new hex2str overload.
10697 (release_static_tracepoint_marker): Remove.
10698 (print_one_static_tracepoint_marker): Get marker by reference
10699 and adjust to std::string.
10700 (info_static_tracepoint_markers_command): Adjust to std::vector
10701 changes
10702 * target.h (static_tracepoint_marker_p): Remove typedef.
10703 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
10704 (struct target_ops) <to_static_tracepoint_marker_at>: Return
10705 bool.
10706 <to_static_tracepoint_markers_by_strid>: Return std::vector.
10707 * target-debug.h
10708 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
10709 (target_debug_print_std_vector_static_tracepoint_marker): New.
10710 (target_debug_print_struct_static_tracepoint_marker_p): Rename
10711 to...
10712 (target_debug_print_static_tracepoint_marker_p): ... this.
10713 * target-delegates.c: Re-generate.
10714 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
10715 Make std::string.
10716 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
10717 (decode_static_tracepoint_spec): Adjust to std::vector.
10718 (tracepoint_print_one_detail): Adjust to std::string.
10719 (strace_marker_decode_location): Adjust to std::string.
10720 (update_static_tracepoint): Adjust to std::string, remove call
10721 to release_static_tracepoint_marker.
10722 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
10723 Adjust to std::vector.
10724 * remote.c (remote_static_tracepoint_marker_at): Return bool.
10725 (remote_static_tracepoint_markers_by_strid): Adjust to
10726 std::vector.
10727 * common/rsp-low.h (hex2str): New overload with explicit count
10728 of bytes.
10729 * common/rsp-low.c (hex2str): New overload with explicit count
10730 of bytes.
10731 * unittests/rsp-low-selftests.c (test_hex2str): New function.
10732 (_initialize_rsp_low_selftests): Add test_hex2str test.
10733 * unittests/tracepoint-selftests.c
10734 (test_parse_static_tracepoint_marker_definition): Adjust to
10735 std::string.
10736
10737 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10738
10739 * tracepoint.c (parse_static_tracepoint_marker_definition):
10740 Consider case where the definition is followed by more
10741 definitions.
10742 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10743 tracepoint-selftests.c.
10744 * unittests/tracepoint-selftests.c: New.
10745
10746 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10747
10748 * MAINTAINERS (Write After Approval): Add Pedro Franco de
10749 Carvalho.
10750
10751 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10752
10753 * symtab.c (find_pc_sect_line): fixed indentation.
10754
10755 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10756
10757 * symtab.c (find_pc_sect_line): now uses binary search.
10758
10759 2018-03-19 Tom Tromey <tom@tromey.com>
10760
10761 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
10762 "IDENT" production.
10763
10764 2018-03-19 Pedro Alves <palves@redhat.com>
10765 Tom Tromey <tom@tromey.com>
10766
10767 * unittests/observable-selftests.c: New file.
10768 * common/observable.h: New file.
10769 * observable.h: New file.
10770 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
10771 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
10772 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
10773 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
10774 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
10775 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
10776 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
10777 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
10778 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
10779 python/py-breakpoint.c, python/py-finishbreakpoint.c,
10780 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
10781 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
10782 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
10783 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
10784 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
10785 tui/tui-interp.c, valops.c: Update all users.
10786 * tui/tui-hooks.c (tui_bp_created_observer)
10787 (tui_bp_deleted_observer, tui_bp_modified_observer)
10788 (tui_inferior_exit_observer, tui_before_prompt_observer)
10789 (tui_normal_stop_observer, tui_register_changed_observer):
10790 Remove.
10791 (tui_observers_token): New global.
10792 (attach_or_detach, tui_attach_detach_observers): New functions.
10793 (tui_install_hooks, tui_remove_hooks): Use
10794 tui_attach_detach_observers.
10795 * record-btrace.c (record_btrace_thread_observer): Remove.
10796 (record_btrace_thread_observer_token): New global.
10797 * observer.sh: Remove.
10798 * observer.c: Rename to observable.c.
10799 * observable.c (namespace gdb_observers): Define new objects.
10800 (observer_debug): Move into gdb_observers namespace.
10801 (struct observer, struct observer_list, xalloc_observer_list_node)
10802 (xfree_observer_list_node, generic_observer_attach)
10803 (generic_observer_detach, generic_observer_notify): Remove.
10804 (_initialize_observer): Update.
10805 Don't include observer.inc.
10806 * Makefile.in (generated_files): Remove observer.h, observer.inc.
10807 (clean mostlyclean): Likewise.
10808 (observer.h, observer.inc): Remove targets.
10809 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
10810 (COMMON_SFILES): Use observable.c, not observer.c.
10811 * .gitignore: Remove observer.h.
10812
10813 2018-03-18 Tom Tromey <tom@tromey.com>
10814
10815 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
10816 gdb::def_vector.
10817 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
10818
10819 2018-03-17 Tom Tromey <tom@tromey.com>
10820
10821 * auto-load.c (auto_load_objfile_script_1): Use std::string.
10822
10823 2018-03-17 Tom Tromey <tom@tromey.com>
10824
10825 * target.c (class scoped_target_fd): New.
10826 (target_fileio_close_cleanup): Remove.
10827 (target_fileio_read_alloc_1): Use scoped_target_fd.
10828
10829 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
10830
10831 * silent-rules.mk: New.
10832 * Makefile.in: Include silent-rules.mk
10833 (srcdir, VPATH, top_srcdir): Move up.
10834 (COMPILE): Add ECHO_CXX.
10835 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
10836 (init.c): Add ECHO_INIT_C.
10837 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
10838 (version.c): Add ECHO_GEN.
10839 (printcmd.o): Add ECHO_CXX.
10840 (target-float.o): Add ECHO_CXX.
10841 (ada-exp.o): Add ECHO_CXX.
10842 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
10843 (insight$(EXEEXT)): Add ECHO_CXXLD.
10844 * gnulib/configure.ac: Add AM_SILENT_RULES.
10845 * gnulib/aclocal.m4: Re-generate.
10846 * gnulib/configure: Re-generate.
10847 * gnulib/import/Makefile.in: Re-generate.
10848
10849 2018-03-16 Tom Tromey <tom@tromey.com>
10850
10851 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
10852 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
10853 * utils.c (do_free_section_addr_info)
10854 (make_cleanup_free_section_addr_info): Remove.
10855 * symfile.h (struct other_sections): Add constructor.
10856 (struct section_addr_info): Remove.
10857 (section_addr_info): New typedef.
10858 (struct sym_fns) <sym_offsets>: Change type of parameter.
10859 (build_section_addr_info_from_objfile)
10860 (relative_addr_info_to_section_offsets, addr_info_make_relative)
10861 (default_symfile_offsets, symbol_file_add)
10862 (symbol_file_add_from_bfd)
10863 (build_section_addr_info_from_section_table): Update.
10864 (alloc_section_addr_info, free_section_addr_info): Don't declare.
10865 * symfile.c (alloc_section_addr_info): Remove.
10866 (build_section_addr_info_from_section_table): Change return type.
10867 Update.
10868 (build_section_addr_info_from_bfd)
10869 (build_section_addr_info_from_objfile): Likewise.
10870 (free_section_addr_info): Remove.
10871 (relative_addr_info_to_section_offsets): Change type of "addrs".
10872 (addrs_section_compar): Now a std::sort comparator.
10873 (addrs_section_sort): Change return type.
10874 (addr_info_make_relative): Change type of "addrs". Update.
10875 (default_symfile_offsets, syms_from_objfile_1)
10876 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
10877 (symbol_file_add_separate): Update.
10878 (symbol_file_add): Change type of "addrs". Update.
10879 (add_symbol_file_command): Update. Remove cleanups.
10880 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
10881 cleanups.
10882 * symfile-debug.c (debug_sym_offsets): Change type of "info".
10883 * solib.c (solib_read_symbols): Update.
10884 * objfiles.c (objfile_relocate): Update. Remove cleanups.
10885 * machoread.c (macho_symfile_offsets): Update.
10886 * jit.c (jit_bfd_try_read_symtab): Update.
10887
10888 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
10889
10890 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10891 unittests/utils-selftests.c.
10892 * unittests/utils-selftests.c: New file.
10893
10894 2018-03-14 Tom Tromey <tom@tromey.com>
10895
10896 PR cli/14977:
10897 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
10898 for NULL.
10899
10900 2018-03-14 Tom Tromey <tom@tromey.com>
10901
10902 PR cli/19918:
10903 * printcmd.c (printf_pointer): Allow "-" in format.
10904
10905 2018-03-14 Tom Tromey <tom@tromey.com>
10906
10907 * printcmd.c (_initialize_printcmd): Add usage to printf.
10908
10909 2018-03-14 Yao Qi <qiyao@sourceware.org>
10910
10911 * MAINTAINERS: Update my email address.
10912
10913 2018-03-13 Tom Tromey <tom@tromey.com>
10914
10915 * machoread.c (macho_check_dsym): Change filenamep to a
10916 std::string*.
10917 (macho_symfile_read): Update.
10918 * symfile.c (load_command): Use std::string.
10919
10920 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
10921
10922 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
10923 to error message string.
10924 (riscv_register_name): Use xsnprintf instead of sprintf.
10925 (riscv_insn::fetch_instruction): Use gdb_assert instead of
10926 internal_error.
10927 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
10928 error.
10929 (riscv_push_dummy_call): Likewise.
10930
10931 2018-03-12 Tom Tromey <tom@tromey.com>
10932
10933 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
10934 Use gdb::byte_vector.
10935 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
10936
10937 2018-03-12 Yao Qi <yao.qi@linaro.org>
10938
10939 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
10940 parameter type to readable_regcache.
10941 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
10942 the declaration.
10943
10944 2018-03-11 Tom Tromey <tom@tromey.com>
10945
10946 * dwarf2read.c (struct nextfield): Add initializers.
10947 (struct nextfnfield): Remove.
10948 (struct fnfieldlist): Add initializers. Remove "length" and
10949 "head", use std::vector.
10950 (struct decl_field_list): Remove.
10951 (struct field_info): Add initializers.
10952 <fields, baseclasses>: Now std::vector.
10953 <nbaseclasses, nfnfields, typedef_field_list_count,
10954 nested_types_list_count>: Remove.
10955 (dwarf2_add_field, dwarf2_add_type_defn)
10956 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
10957 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
10958 (process_structure_scope): Update.
10959
10960 2018-03-11 Tom Tromey <tom@tromey.com>
10961
10962 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
10963 for use by std::sort.
10964 (build_type_psymtabs_1): Use std::vector.
10965
10966 2018-03-09 Eli Zaretskii <eliz@gnu.org>
10967
10968 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
10969 and LIBMPFR in the printed configuration.
10970
10971 2018-03-08 Tom Tromey <tom@tromey.com>
10972
10973 * source.c (get_filename_and_charpos): Use scoped_fd.
10974 * nto-procfs.c (procfs_open_1): Use scoped_fd.
10975 (procfs_pidlist): Likewise.
10976 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
10977 (iterate_over_mappings): Likewise.
10978
10979 2018-03-08 Tom Tromey <tom@tromey.com>
10980
10981 * infcall.c (struct call_return_meta_info)
10982 <stack_temporaries_enabled>: Remove.
10983 (get_call_return_value, call_function_by_hand_dummy): Update.
10984 * thread.c (disable_thread_stack_temporaries): Remove.
10985 (enable_thread_stack_temporaries): Remove.
10986 (thread_stack_temporaries_enabled_p): Return bool.
10987 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
10988 (get_last_thread_stack_temporary): Update.
10989 * eval.c (evaluate_subexp): Update.
10990 * gdbthread.h (class enable_thread_stack_temporaries): Now a
10991 class, not a function.
10992 (value_ptr, value_vec): Remove typedefs.
10993 (class thread_info) <stack_temporaries_enabled>: Now bool.
10994 <stack_temporaries>: Now a std::vector.
10995 (thread_stack_temporaries_enabled_p)
10996 (value_in_thread_stack_temporaries): Return bool.
10997
10998 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
10999
11000 * remote.c (putpkt_binary): Fix omitted bytes reporting.
11001 (getpkt_or_notif_sane_1): Likewise.
11002
11003 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11004
11005 * build-id.c (build_id_to_debug_bfd): Use std::string.
11006
11007 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11008
11009 * build-id.c (find_separate_debug_file_by_buildid): Return
11010 std::string.
11011 * build-id.h (find_separate_debug_file_by_buildid): Return
11012 std::string.
11013 * coffread.c (coff_symfile_read): Adjust to std::string.
11014 * elfread.c (elf_symfile_read): Adjust to std::string.
11015 * symfile.c (separate_debug_file_exists): Change parameter to
11016 std::string.
11017 (find_separate_debug_file): Return std::string.
11018 (find_separate_debug_file_by_debuglink): Return std::string.
11019 * symfile.h (find_separate_debug_file_by_debuglink): Return
11020 std::string.
11021
11022 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11023
11024 * common/xml-utils.c (xml_escape_text): Move code to...
11025 (xml_escape_text_append): ... this new function.
11026 * common/xml-utils.h (xml_escape_text_append): New declaration.
11027 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
11028 New function.
11029 (_initialize_xml_utils): register test_xml_escape_text_append as
11030 a selftest.
11031
11032 2018-03-07 Alan Hayward <alan.hayward@arm.com>
11033
11034 * defs.h: Remove MAX_REGISTER_SIZE.
11035 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
11036 asserts.
11037 * python/py-unwind.c (pyuw_sniffer): Likewise.
11038
11039 2018-03-07 Tom Tromey <tom@tromey.com>
11040
11041 * linux-tdep.c (linux_info_proc): Update.
11042 * target.h (struct target_ops) <to_fileio_readlink>: Return
11043 optional<string>.
11044 (target_fileio_readlink): Return optional<string>.
11045 * remote.c (remote_hostio_readlink): Return optional<string>.
11046 * inf-child.c (inf_child_fileio_readlink): Return
11047 optional<string>.
11048 * target.c (target_fileio_readlink): Return optional<string>.
11049
11050 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
11051
11052 * regcache.c (cooked_read_test): Add riscv to the list of
11053 architectures that have a save_reggroup.
11054
11055 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
11056
11057 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
11058 value is not a dynamic class object.
11059
11060 2018-03-06 Tom Tromey <tom@tromey.com>
11061
11062 * rust-exp.y: Formatting fixes.
11063
11064 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11065
11066 * riscv-tdep.c (riscv_register_name): Remove target description
11067 support.
11068 (riscv_gdbarch_init): Remove target description check.
11069
11070 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11071
11072 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
11073 comment.
11074 * riscv-tdep.h: Likewise.
11075
11076 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11077
11078 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
11079 (riscv_pseudo_register_write): Delete.
11080 (riscv_gdbarch_init): Remove all use of pseudo registers.
11081
11082 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11083
11084 * record-btrace.c (btrace_print_lines): Replace cleanup
11085 parameter with RAII equivalents.
11086 (btrace_insn_history): Replace cleanup with RAII equivalents.
11087 * ui-out.h (make_cleanup_ui_out_list_begin_end,
11088 make_cleanup_ui_out_tuple_begin_end): Remove.
11089 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
11090 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
11091 make_cleanup_ui_out_list_begin_end): Remove.
11092
11093 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11094
11095 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
11096 parameter types to std::vector. Use bool.
11097 (record_btrace_wait): Replace VEC(tp_t) with
11098 std::vector<thread_info *>.
11099 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
11100
11101 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11102
11103 * record-btrace.c (record_btrace_disable_callback): Remove.
11104 (struct scoped_btrace_disable): New.
11105 (record_btrace_open): Use scoped_btrace_disable.
11106
11107 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11108
11109 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
11110 reading values from registers.
11111
11112 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11113
11114 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
11115 where appropriate.
11116
11117 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11118
11119 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
11120 change parameter type. Use GDB's print functions, and use
11121 core_addr_to_string where appropriate.
11122 (riscv_push_dummy_call): Use core_addr_to_string where
11123 appropriate, update call to riscv_print_arg_location, and reindent
11124 a few lines.
11125 (riscv_return_value): Update call to riscv_print_arg_location.
11126
11127 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11128 Tim Newsome <tim@sifive.com>
11129 Albert Ou <a0u@eecs.berkeley.edu>
11130 Darius Rad <darius@bluespec.com>
11131
11132 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
11133 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
11134 (ALLDEPFILES): Add riscv-tdep.c
11135 * configure.tgt: Add riscv support.
11136 * riscv-tdep.c: New file.
11137 * riscv-tdep.h: New file.
11138 * NEWS: Mention new target.
11139 * MAINTAINERS: Add entry for riscv.
11140
11141 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11142
11143 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
11144 fields within aggregates.
11145
11146 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
11147
11148 * record-btrace.c (btrace_print_lines): Change type of flags to
11149 gdb_disassembly_flags.
11150
11151 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11152
11153 * fbsd-nat.c: Include "inf-ptrace.h".
11154 (USE_SIGTRAP_SIGINFO): Conditionally define.
11155 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
11156 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
11157 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
11158 function.
11159 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
11160 Likewise.
11161 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
11162 Likewise.
11163 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
11164 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
11165 "supports_stopped_by_hw_breakpoint" target methods.
11166
11167 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11168
11169 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
11170 * fbsd-nat.c (debug_fbsd_nat): New variable.
11171 (show_fbsd_nat_debug): New function.
11172 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
11173 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
11174
11175 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11176
11177 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
11178 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
11179 prototype.
11180 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
11181 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
11182 method.
11183
11184 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11185
11186 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
11187 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
11188
11189 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11190
11191 * charset.c (struct charset_vector): New.
11192 (charsets): Change type to charset_vector.
11193 (find_charset_names): Adjust.
11194 (add_one): Adjust.
11195 (_initialize_charset): Adjust.
11196
11197 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11198
11199 * progspace.h (struct program_space) <deleted_solibs>: Change
11200 type to std::vector<std::string>.
11201 * progspace.c (clear_program_space_solib_cache): Adjust.
11202 * breakpoint.c (print_solib_event): Adjust.
11203 (check_status_catch_solib): Adjust.
11204 * solib.c (update_solib_list): Adjust.
11205 * ui-out.h (class ui_out) <field_string>: New overload.
11206 * ui-out.c (ui_out::field_string): New overload.
11207
11208 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11209
11210 * progspace.h (struct program_space): Add constructor and
11211 destructor, initialize fields.
11212 (add_program_space): Remove.
11213 * progspace.c (add_program_space): Rename to...
11214 (program_space::program_space): ... this.
11215 (release_program_space): Rename to...
11216 (program_space::~program_space): ... this.
11217 (delete_program_space): Use delete to delete program_space.
11218 (initialize_progspace): Use new to allocate program_space.
11219 * inferior.c (add_inferior_with_spaces): Likewise.
11220 (clone_inferior_command): Likewise.
11221 * infrun.c (follow_fork_inferior): Likewise.
11222 (handle_vfork_child_exec_or_exit): Likewise.
11223
11224 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11225
11226 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
11227 (delim_string_to_char_ptr_vec): Return std::vector of
11228 gdb::unique_xmalloc_ptr.
11229 (dirnames_to_char_ptr_vec_append): Take std::vector of
11230 gdb::unique_xmalloc_ptr.
11231 (dirnames_to_char_ptr_vec): Return std::vector of
11232 gdb::unique_xmalloc_ptr.
11233 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
11234 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
11235 (delim_string_to_char_ptr_vec): Return an std::vector of
11236 gdb::unique_xmalloc_ptr, adjust the code.
11237 (dirnames_to_char_ptr_vec_append): Take an std::vector of
11238 gdb::unique_xmalloc_ptr, adjust the code.
11239 (dirnames_to_char_ptr_vec): Return an std::vector of
11240 gdb::unique_xmalloc_ptr, adjust the code.
11241 * auto-load.c (auto_load_safe_path_vec): Change type to
11242 std::vector of gdb::unique_xmalloc_ptr.
11243 (auto_load_expand_dir_vars): Return an std::vector of
11244 gdb::unique_xmalloc_ptr, adjust the code.
11245 (auto_load_safe_path_vec_update): Adjust.
11246 (filename_is_in_auto_load_safe_path_vec): Adjust.
11247 (auto_load_objfile_script_1): Adjust.
11248 * build-id.c (build_id_to_debug_bfd): Adjust.
11249 * linux-thread-db.c (thread_db_load_search): Adjust.
11250 * source.c (add_path): Adjust.
11251 (openp): Adjust.
11252 * symfile.c (find_separate_debug_file): Adjust.
11253 * utils.c (do_free_char_ptr_vec): Remove.
11254 (make_cleanup_free_char_ptr_vec): Remove.
11255
11256 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
11257
11258 PR gdb/22907
11259 * common/pathstuff.c: Conditionally include "<windows.h>".
11260
11261 2018-03-01 Georg Sauthoff <mail@georg.so>
11262
11263 PR gdb/22888
11264 * gcore.in: Quote variables and switch interpreter to bash.
11265
11266 2018-03-01 Tom Tromey <tom@tromey.com>
11267
11268 * dwarf2read.c (alloc_discriminant_info): Fix default_index
11269 assertion. Add assertion for discriminant_index.
11270 (quirk_rust_enum): Use correct base type name in univariant case.
11271
11272 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
11273
11274 * record.c (get_call_history_modifiers): Return a
11275 record_print_flags.
11276 (cmd_record_call_history): Adjust.
11277 * record-btrace.c (record_btrace_call_history): Adjust.
11278 (record_btrace_call_history_range): Adjust.
11279 (record_btrace_call_history_from): Adjust.
11280 * target-debug.h (target_debug_print_record_print_flags): New.
11281 * target-delegates.c: Re-generate.
11282 * target.c (target_call_history): Change flags type.
11283 (target_call_history_from): Likewise.
11284 (target_call_history_range): Likewise.
11285 * target.h (struct target_ops) <target_call_history>: Likewise.
11286 (target_call_history_from): Likewise.
11287 (target_call_history_range): Likewise.
11288
11289 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11290 Simon Marchi <simon.marchi@polymtl.ca>
11291
11292 * common/common-utils.c: Include "sys/stat.h".
11293 (is_regular_file): Move here from "source.c"; change return
11294 type to "bool".
11295 * common/common-utils.h (is_regular_file): New prototype.
11296 * common/pathstuff.c (contains_dir_separator): New function.
11297 * common/pathstuff.h (contains_dir_separator): New prototype.
11298 * source.c: Don't include "sys/stat.h".
11299 (is_regular_file): Move to "common/common-utils.c".
11300
11301 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11302
11303 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
11304 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
11305 * auto-load.c: Include "common/pathstuff.h".
11306 * common/common-def.h (current_directory): Move here.
11307 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
11308 function.
11309 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
11310 prototype.
11311 * common/pathstuff.c: New file.
11312 * common/pathstuff.h: New file.
11313 * compile/compile.c: Include "common/pathstuff.h".
11314 * defs.h (current_directory): Move to "common/common-defs.h".
11315 * dwarf2read.c: Include "common/pathstuff.h".
11316 * exec.c: Likewise.
11317 * guile/scm-safe-call.c: Likewise.
11318 * linux-thread-db.c: Likewise.
11319 * main.c: Likewise.
11320 * nto-tdep.c: Likewise.
11321 * objfiles.c: Likewise.
11322 * source.c: Likewise.
11323 * symtab.c: Likewise.
11324 * utils.c: Include "common/pathstuff.h".
11325 (gdb_realpath): Move to "common/pathstuff.c".
11326 (gdb_realpath_keepfile): Likewise.
11327 (gdb_abspath): Likewise.
11328 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
11329 (gdb_realpath_keepfile): Likewise.
11330 (gdb_abspath): Likewise.
11331
11332 2018-02-28 John Baldwin <jhb@FreeBSD.org>
11333
11334 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
11335 wildcard process pid for super_resume for kernels with a
11336 specific bug.
11337
11338 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
11339
11340 * compile/compile.c (get_args): Add additional comments
11341 explaining function.
11342
11343 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
11344 Tom Tromey <tom@tromey.com>
11345
11346 * target.h (memory_write_request_s): Remove typedef. Don't define
11347 VEC.
11348 (target_write_memory_blocks): Change argument to std::vector.
11349 (struct memory_write_request): Add constructor.
11350 * target-memory.c (compare_block_starting_address): Return bool.
11351 Change argument types.
11352 (claim_memory): Change arguments to use std::vector.
11353 (split_regular_and_flash_blocks, blocks_to_erase)
11354 (compute_garbled_blocks): Likewise.
11355 (cleanup_request_data, cleanup_write_requests_vector): Remove.
11356 (target_write_memory_blocks): Change argument to std::vector.
11357 * symfile.c (struct load_section_data): Add constructor and
11358 destructor. Use std::vector for "requests".
11359 (struct load_progress_data): Add initializers.
11360 (load_section_callback): Update. Use "new".
11361 (clear_memory_write_data): Remove.
11362 (generic_load): Update.
11363
11364 2018-02-27 Alan Hayward <alan.hayward@arm.com>
11365
11366 * arch/aarch64.h: Use common/tdesc.h.
11367
11368 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11369
11370 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
11371 architecture with a 64-bit ABI.
11372
11373 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11374
11375 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
11376 ahead of target description loading.
11377
11378 2018-02-26 Tom Tromey <tom@tromey.com>
11379
11380 * stack.c (backtrace_command_1): Update.
11381 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
11382 of "flags".
11383 * python/py-framefilter.c (py_print_frame)
11384 (gdbpy_apply_frame_filter): Change type of "flags".
11385 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
11386 of "flags".
11387 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
11388 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
11389 * extension.h (enum frame_filter_flag): Rename from
11390 frame_filter_flags.
11391 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
11392 (apply_ext_lang_frame_filter): Change type of "flags".
11393 * extension.c (apply_ext_lang_frame_filter): Change type of
11394 "flags".
11395 * extension-priv.h (struct extension_language_ops)
11396 <apply_frame_filter>: Change type of "flags".
11397
11398 2018-02-26 Tom Tromey <tom@tromey.com>
11399
11400 PR python/16497:
11401 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
11402 off-by-one in py_end computation.
11403 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
11404 PRINT_MORE_FRAMES.
11405 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
11406 constant.
11407
11408 2018-02-26 Tom Tromey <tom@tromey.com>
11409
11410 * dwarf2read.c (struct variant_field): New.
11411 (struct nextfield) <variant>: New field.
11412 (dwarf2_add_field): Handle DW_TAG_variant_part.
11413 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
11414 discriminated union.
11415 (read_structure_type): Handle DW_TAG_variant_part.
11416 (handle_struct_member_die): New function, extracted from
11417 process_structure_scope. Handle DW_TAG_variant.
11418 (process_structure_scope): Handle discriminated unions. Call
11419 handle_struct_member_die.
11420
11421 2018-02-26 Tom Tromey <tom@tromey.com>
11422
11423 * rust-lang.h (rust_last_path_segment): Declare.
11424 * rust-lang.c (rust_last_path_segment): Now public. Change
11425 contract.
11426 (struct disr_info): Remove.
11427 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
11428 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
11429 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
11430 (rust_enum_p, rust_enum_variant): New function.
11431 (rust_underscore_fields): Remove "offset" parameter.
11432 (rust_print_enum): New function.
11433 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
11434 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
11435 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
11436 enums.
11437 (rust_internal_print_type): New function, from rust_print_type.
11438 Remove enum code.
11439 (rust_print_type): Call rust_internal_print_type.
11440 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
11441 Update enum handling.
11442 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
11443 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
11444 (rust_union_quirks): New functions.
11445 (process_full_comp_unit, process_full_type_unit): Call
11446 rust_union_quirks.
11447 (process_structure_scope): Update rust_unions if necessary.
11448
11449 2018-02-26 Tom Tromey <tom@tromey.com>
11450
11451 * value.h (value_union_variant): Declare.
11452 * valops.c (value_union_variant): New function.
11453 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
11454 (struct discriminant_info): New.
11455 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
11456 enumerator.
11457 (struct main_type) <flag_discriminated_union>: New field.
11458
11459 2018-02-26 Tom Tromey <tom@tromey.com>
11460
11461 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11462 unittests/unpack-selftests.c.
11463 * unittests/unpack-selftests.c: New file.
11464 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
11465
11466 2018-02-26 Yao Qi <yao.qi@linaro.org>
11467
11468 * dwarf2read.c (struct partial_die_info) <read>: New method.
11469 (read_partial_die): Remove the declaration.
11470 (load_partial_dies): Update.
11471 (partial_die_info::partial_die_info):
11472 (read_partial_die): Change it to partial_die_info::read.
11473
11474 2018-02-26 Yao Qi <yao.qi@linaro.org>
11475
11476 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
11477 (fixup_partial_die): Remove declaration.
11478 (scan_partial_symbols): Update.
11479 (partial_die_parent_scope): Likewise.
11480 (partial_die_full_name): Likewise.
11481 (fixup_partial_die): Change it to partial_die_info::fixup.
11482
11483 2018-02-26 Yao Qi <yao.qi@linaro.org>
11484
11485 * dwarf2read.c (read_partial_die): Update the declaration.
11486 (load_partial_dies): Caller update.
11487 (read_partial_die): Remove one argument abbrev_len.
11488
11489 2018-02-26 Yao Qi <yao.qi@linaro.org>
11490
11491 * dwarf2read.c (struct partial_die_info): Add ctor, delete
11492 assignment operator.
11493 (load_partial_dies): Use ctor and copy ctor.
11494 (read_partial_die): Update.
11495 (dwarf2_cu::find_partial_die): Use ctor.
11496
11497 2018-02-26 Yao Qi <yao.qi@linaro.org>
11498
11499 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
11500 (find_partial_die_in_comp_unit): Change it to
11501 dwarf2_cu::find_partial_die.
11502 (find_partial_die): Update.
11503
11504 2018-02-26 Yao Qi <yao.qi@linaro.org>
11505
11506 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
11507 is NULL.
11508
11509 2018-02-26 Yao Qi <yao.qi@linaro.org>
11510
11511 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
11512
11513 2018-02-26 Alan Hayward <alan.hayward@arm.com>
11514
11515 * arch/amd64.h: Use common/tdesc.h.
11516 * arch/i386.c: Likewise.
11517 * arch/i386.h: Likewise.
11518 * arch/tic6x.c: Likewise.
11519 * arch/tdesc.h: Move file from here...
11520 * common/tdesc.h: ...to here.
11521 * features/aarch64-core.c: Regenerate.
11522 * features/aarch64-fpu.c: Regenerate.
11523 * features/i386/32bit-avx.c: Regenerate.
11524 * features/i386/32bit-avx512.c: Regenerate.
11525 * features/i386/32bit-core.c: Regenerate.
11526 * features/i386/32bit-linux.c: Regenerate.
11527 * features/i386/32bit-mpx.c: Regenerate.
11528 * features/i386/32bit-pkeys.c: Regenerate.
11529 * features/i386/32bit-sse.c: Regenerate.
11530 * features/i386/64bit-avx.c: Regenerate.
11531 * features/i386/64bit-avx512.c: Regenerate.
11532 * features/i386/64bit-core.c: Regenerate.
11533 * features/i386/64bit-linux.c: Regenerate.
11534 * features/i386/64bit-mpx.c: Regenerate.
11535 * features/i386/64bit-pkeys.c: Regenerate.
11536 * features/i386/64bit-segments.c: Regenerate.
11537 * features/i386/64bit-sse.c: Regenerate.
11538 * features/i386/x32-core.c: Regenerate.
11539 * features/tic6x-c6xp.c: Regenerate.
11540 * features/tic6x-core.c: Regenerate.
11541 * features/tic6x-gp.c: Regenerate.
11542 * target-descriptions.c: Use common/tdesc.h.
11543 * target-descriptions.h: Likewise.
11544
11545 2018-02-24 Tom Tromey <tom@tromey.com>
11546
11547 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
11548 (try_thread_db_load_from_dir, thread_db_load_search): Use
11549 std::string.
11550 (info_auto_load_libthread_db_compare): Return bool. Change
11551 argument types.
11552 (info_auto_load_libthread_db): Use std::vector, std::string.
11553 Remove cleanups.
11554
11555 2018-02-24 Tom Tromey <tom@tromey.com>
11556
11557 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
11558 std::string.
11559 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
11560 std::string*.
11561 * gdbarch.c: Rebuild.
11562 * gdbarch.h: Rebuild.
11563 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
11564 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
11565 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
11566 std::string*.
11567
11568 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
11569
11570 * gdbtypes.h (sect_offset): Change type to uint64_t.
11571 (sect_offset_str): New function.
11572 * dwarf2read.c (create_addrmap_from_aranges): Use
11573 sect_offset_str.
11574 (error_check_comp_unit_head): Likewise.
11575 (create_debug_type_hash_table): Likewise.
11576 (read_cutu_die_from_dwo): Likewise.
11577 (init_cutu_and_read_dies): Likewise.
11578 (init_cutu_and_read_dies_no_follow): Likewise.
11579 (process_psymtab_comp_unit_reader): Likewise.
11580 (partial_die_parent_scope): Likewise.
11581 (peek_die_abbrev): Likewise.
11582 (process_queue): Likewise.
11583 (dwarf2_physname): Likewise.
11584 (read_namespace_alias): Likewise.
11585 (read_import_statement): Likewise.
11586 (create_dwo_cu_reader): Likewise.
11587 (create_cus_hash_table): Likewise.
11588 (lookup_dwo_cutu): Likewise.
11589 (inherit_abstract_dies): Likewise.
11590 (read_func_scope): Likewise.
11591 (read_call_site_scope): Likewise.
11592 (dwarf2_add_member_fn): Likewise.
11593 (read_common_block): Likewise.
11594 (read_module_type): Likewise.
11595 (read_typedef): Likewise.
11596 (read_subrange_type): Likewise.
11597 (load_partial_dies): Likewise.
11598 (read_partial_die): Likewise.
11599 (find_partial_die): Likewise.
11600 (read_str_index): Likewise.
11601 (dwarf2_string_attr): Likewise.
11602 (build_error_marker_type): Likewise.
11603 (lookup_die_type): Likewise.
11604 (dump_die_shallow): Likewise.
11605 (follow_die_ref): Likewise.
11606 (dwarf2_fetch_die_loc_sect_off): Likewise.
11607 (dwarf2_fetch_constant_bytes): Likewise.
11608 (follow_die_sig): Likewise.
11609 (get_signatured_type): Likewise.
11610 (get_DW_AT_signature_type): Likewise.
11611 (dwarf2_find_containing_comp_unit): Likewise.
11612 (set_die_type): Likewise.
11613
11614 2018-02-21 John Baldwin <jhb@FreeBSD.org>
11615
11616 * arch/aarch64.c: Include "common-defs.h".
11617 * arch/amd64.c: Likewise.
11618 * arch/i386.c: Likewise.
11619
11620 2018-02-21 Tom Tromey <tom@tromey.com>
11621
11622 * value.h: (extract_field_op): Update.
11623 * eval.c (extract_field_op): Return a const char *.
11624 * expression.h (parse_expression_for_completion): Update.
11625 * completer.c (complete_expression): Update.
11626 (add_struct_fields): Make fieldname const.
11627 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
11628 (mark_completion_tag, parse_exp_in_context_1): Update.
11629 (parse_expression_for_completion): Change "name" to
11630 unique_xmalloc_ptr*.
11631
11632 2018-02-21 Tom Tromey <tom@tromey.com>
11633
11634 * infcall.c (call_function_by_hand_dummy): Use std::vector.
11635
11636 2018-02-21 Yao Qi <yao.qi@linaro.org>
11637
11638 * avr-tdep.c (avr_read_pc): Change parameter type to
11639 readable_regcache.
11640 * gdbarch.sh (read_pc): Likewise.
11641 * gdbarch.c: Re-generated.
11642 * gdbarch.h: Re-generated.
11643 * hppa-tdep.c (hppa_read_pc): Change parameter type to
11644 readable_regcache.
11645 * ia64-tdep.c (ia64_read_pc): Likewise.
11646 * mips-tdep.c (mips_read_pc): Likewise.
11647 * spu-tdep.c (spu_read_pc): Likewise.
11648
11649 2018-02-21 Yao Qi <yao.qi@linaro.org>
11650
11651 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
11652 * regcache-dump.c: New file.
11653 * regcache.c: Move register_dump to regcache-dump.c.
11654 (maintenance_print_registers): Likewise.
11655 (maintenance_print_raw_registers): Likewise.
11656 (maintenance_print_cooked_registers): Likewise.
11657 (maintenance_print_register_groups): Likewise.
11658 (maintenance_print_remote_registers): Likewise.
11659 (_initialize_regcache): Likewise.
11660 * regcache.h (register_dump): Moved from regcache.c.
11661
11662 2018-02-21 Yao Qi <yao.qi@linaro.org>
11663
11664 * regcache.c (regcache::regcache): Update.
11665 (regcache::invalidate): Move it to detached_regcache::invalidate.
11666 (get_thread_arch_aspace_regcache): Update.
11667 (regcache::raw_update): Update.
11668 (regcache::cooked_read): Remove some code.
11669 (regcache::cooked_read_value): Likewise.
11670 (regcache::raw_write): Remove assert on m_readonly_p.
11671 (regcache::raw_supply_integer): Move it to
11672 detached_regcache::raw_supply_integer.
11673 (regcache::raw_supply_zeroed): Likewise.
11674 * regcache.h (detached_regcache) <raw_supply_integer>: New
11675 declaration.
11676 <raw_supply_zeroed, invalidate>: Likewise.
11677 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
11678 <invalidate>: Likewise.
11679 <m_readonly_p>: Removed.
11680
11681 2018-02-21 Yao Qi <yao.qi@linaro.org>
11682
11683 * infcmd.c (get_return_value): Let stop_regs point to
11684 get_current_regcache.
11685 * regcache.c (regcache::regcache): Remove.
11686 (register_dump_reg_buffer): New class.
11687 (regcache_print): Adjust.
11688 * regcache.h (regcache): Remove constructors.
11689
11690 2018-02-21 Yao Qi <yao.qi@linaro.org>
11691
11692 * regcache.c (class register_dump): New class.
11693 (register_dump_regcache, register_dump_none): New class.
11694 (register_dump_remote, register_dump_groups): New class.
11695 (regcache_print): Update.
11696 * regcache.h (regcache_dump_what): Move it to regcache.c.
11697 (regcache) <dump>: Remove.
11698
11699 2018-02-21 Yao Qi <yao.qi@linaro.org>
11700
11701 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
11702 reg_buffer_rw *.
11703 (jit_unwind_reg_set_impl): Call raw_supply.
11704 (jit_frame_sniffer): Use reg_buffer_rw.
11705 * record-full.c (record_full_core_regbuf): Change its type.
11706 (record_full_core_open_1): Use reg_buffer_rw.
11707 (record_full_close): Likewise.
11708 (record_full_core_fetch_registers): Use regcache->raw_supply.
11709 (record_full_core_store_registers): Likewise.
11710 * regcache.c (regcache::get_register_status): Move it to
11711 reg_buffer.
11712 (regcache_raw_set_cached_value): Remove.
11713 (regcache::raw_set_cached_value): Remove.
11714 (regcache::raw_write): Call raw_supply.
11715 (regcache::raw_supply): Move it to reg_buffer_rw.
11716 * regcache.h (regcache_raw_set_cached_value): Remove.
11717 (reg_buffer_rw): New class.
11718
11719 2018-02-21 Yao Qi <yao.qi@linaro.org>
11720
11721 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
11722 readonly_detached_regcache.
11723 (dummy_frame_prev_register): Use regcache->cooked_read.
11724 * frame.c (frame_save_as_regcache): Change return type.
11725 (frame_pop): Update.
11726 * frame.h (frame_save_as_regcache): Update declaration.
11727 * inferior.h (get_infcall_suspend_state_regcache): Update
11728 declaration.
11729 * infrun.c (infcall_suspend_state) <registers>: use
11730 readonly_detached_regcache.
11731 (save_infcall_suspend_state): Don't use regcache_dup.
11732 (get_infcall_suspend_state_regcache): Change return type.
11733 * linux-fork.c (struct fork_info) <savedregs>: Change to
11734 readonly_detached_regcache.
11735 <pc>: New field.
11736 (fork_save_infrun_state): Don't use regcache_dup.
11737 (info_checkpoints_command): Adjust.
11738 * mi/mi-main.c (register_changed_p): Update declaration.
11739 (mi_cmd_data_list_changed_registers): Use
11740 readonly_detached_regcache.
11741 (register_changed_p): Change parameter type to
11742 readonly_detached_regcache.
11743 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
11744 readonly_detached_regcache.
11745 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
11746 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
11747 New.
11748 (regcache::save): Move it to reg_buffer.
11749 (regcache::restore): Change parameter type.
11750 (regcache_dup): Remove.
11751 * regcache.h (reg_buffer) <save>: New method.
11752 (readonly_detached_regcache): New class.
11753 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
11754 readonly_detached_regcache.
11755 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
11756
11757 2018-02-21 Yao Qi <yao.qi@linaro.org>
11758
11759 * frame.c (frame_save_as_regcache): Use regcache method save.
11760 (frame_pop): Use regcache method restore.
11761 * infrun.c (restore_infcall_suspend_state): Likewise.
11762 * linux-fork.c (fork_load_infrun_state): Likewise.
11763 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
11764 save.
11765 * regcache.c (regcache_save): Remove.
11766 (regcache::restore): More asserts.
11767 (regcache_cpy): Remove.
11768 * regcache.h (regcache_save): Remove the declaration.
11769 (regcache::restore): Move from private to public.
11770 Remove the friend declaration of regcache_cpy.
11771 (regcache_cpy): Remove declaration.
11772
11773 2018-02-21 Yao Qi <yao.qi@linaro.org>
11774
11775 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
11776 parameter type to 'readable_regcache *'.
11777 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
11778 * arm-tdep.c (arm_neon_quad_read): Likewise.
11779 (arm_pseudo_read): Likewise.
11780 * avr-tdep.c (avr_pseudo_register_read): Likewise.
11781 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
11782 * frv-tdep.c (frv_pseudo_register_read): Likewise.
11783 * gdbarch.c: Re-generated.
11784 * gdbarch.h: Re-generated.
11785 * gdbarch.sh (pseudo_register_read): Change parameter type to
11786 'readable_regcache *'.
11787 (pseudo_register_read_value): Likewise.
11788 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
11789 (h8300_pseudo_register_read): Likewise.
11790 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
11791 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
11792 (i386_pseudo_register_read_into_value): Likewise.
11793 (i386_pseudo_register_read_value): Likewise.
11794 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
11795 declaration.
11796 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
11797 * m32c-tdep.c (m32c_raw_read): Likewise.
11798 (m32c_read_flg): Likewise.
11799 (m32c_banked_register): Likewise.
11800 (m32c_banked_read): Likewise.
11801 (m32c_sb_read): Likewise.
11802 (m32c_part_read): Likewise.
11803 (m32c_cat_read): Likewise.
11804 (m32c_r3r2r1r0_read): Likewise.
11805 (m32c_pseudo_register_read): Likewise.
11806 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
11807 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
11808 (mep_pseudo_cr64_read): Likewise.
11809 (mep_pseudo_register_read): Likewise.
11810 * mips-tdep.c (mips_pseudo_register_read): Likewise.
11811 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
11812 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
11813 * regcache.c (regcache::raw_read): Move it to readable_regcache.
11814 (regcache::cooked_read): Likewise.
11815 (regcache::cooked_read_value): Likewise.
11816 (regcache_cooked_read_signed):
11817 (regcache::cooked_read): Likewise.
11818 * regcache.h (readable_regcache): New class.
11819 (regcache): Inherit readable_regcache. Move some methods to
11820 readable_regcache.
11821 * rl78-tdep.c (rl78_pseudo_register_read): Change
11822 parameter type to 'readable_regcache *'.
11823 * rs6000-tdep.c (do_regcache_raw_read): Remove.
11824 (e500_pseudo_register_read): Change parameter type to
11825 'readable_regcache *'.
11826 (dfp_pseudo_register_read): Likewise.
11827 (vsx_pseudo_register_read): Likewise.
11828 (efpr_pseudo_register_read): Likewise.
11829 * s390-tdep.c (s390_pseudo_register_read): Likewise.
11830 * sh-tdep.c (sh_pseudo_register_read): Likewise.
11831 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
11832 (sh64_pseudo_register_read): Likewise.
11833 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
11834 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
11835 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
11836 (spu_pseudo_register_read): Likewise.
11837 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
11838 (xtensa_pseudo_register_read): Likewise.
11839
11840 2018-02-21 Yao Qi <yao.qi@linaro.org>
11841
11842 * regcache.c (regcache::regcache): Call reg_buffer ctor.
11843 (regcache::arch): Move it to reg_buffer::arch.
11844 (regcache::register_buffer): Likewise.
11845 (regcache::assert_regnum): Likewise.
11846 (regcache::num_raw_registers): Likewise.
11847 * regcache.h (reg_buffer): New class.
11848 (regcache): Inherit reg_buffer.
11849
11850 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
11851
11852 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
11853 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
11854
11855 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
11856
11857 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
11858
11859 2018-02-19 Alan Hayward <alan.hayward@arm.com>
11860
11861 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
11862 (SFILES): Remove common/*.c files.
11863 (COMMON_OBS): Remove some *.o files built from common/*.c files.
11864 * common/common.host: Add common reference.
11865 * configure.ac: Likewise.
11866 * configure: Regenerate.
11867
11868 2018-02-16 Yao Qi <yao.qi@linaro.org>
11869
11870 * block.c (block_namespace_info): Inherit allocate_on_obstack.
11871 (block_initialize_namespace): Use new.
11872 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
11873 (dwarf2_free_objfile): Use delete.
11874 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
11875 (copy_type_recursive): Use new.
11876 * gdb_obstack.h (allocate_on_obstack): New.
11877
11878 2018-02-15 Yao Qi <yao.qi@linaro.org>
11879
11880 PR gdb/22849
11881 * inferior.c (exit_inferior_1): Reset inf->control.
11882
11883 2018-02-15 Joel Brobecker <brobecker@adacore.com>
11884
11885 * ada-lang.c (ada_to_fixed_value_create): Delete advance
11886 declaration.
11887
11888 2018-02-14 Pedro Alves <palves@redhat.com>
11889
11890 * frame-unwind.c (frame_unwind_try_unwinder): Always call
11891 frame_cleanup_after_sniffer on exception.
11892
11893 2018-02-14 Tom Tromey <tom@tromey.com>
11894
11895 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
11896 const.
11897 (solib_bfd_open): Make pathname const.
11898 * solib.c (solib_bfd_open): Make pathname const.
11899 * solib-spu.c (spu_bfd_fopen): Make name const.
11900 (spu_bfd_open): Make pathname const.
11901 * solib-darwin.c (darwin_bfd_open): Make pathname const.
11902 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
11903
11904 2018-02-14 Tom Tromey <tom@tromey.com>
11905
11906 * symfile.c (symfile_bfd_open): Update.
11907 * source.h (openp, source_full_path_of, find_and_open_source):
11908 Change argument type to unique_xmalloc_ptr.
11909 * source.c (openp): Take a unique_xmalloc_ptr.
11910 (source_full_path_of, find_and_open_source): Likewise.
11911 (open_source_file, symtab_to_fullname): Update.
11912 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
11913 unique_xmalloc_ptr.
11914 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
11915 (exec_file_find): Update.
11916 * psymtab.c (psymtab_to_fullname): Update.
11917 * nto-tdep.h (nto_find_and_open_solib): Update.
11918 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
11919 unique_xmalloc_ptr.
11920 * exec.c (exec_file_attach): Update.
11921 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
11922 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
11923
11924 2018-02-14 Tom Tromey <tom@tromey.com>
11925
11926 * solib.c: Include source.h.
11927 * nto-tdep.c: Include source.h.
11928 * mi/mi-cmd-env.c: Include source.h.
11929 * infcmd.c: Include source.h.
11930 * exec.c: Include source.h.
11931 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
11932 (add_path, directory_switch, source_path, init_source_path): Move
11933 declarations...
11934 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
11935 (add_path, directory_switch, source_path, init_source_path):
11936 ...here.
11937
11938 2018-02-14 Tom Tromey <tom@tromey.com>
11939
11940 * solist.h (exec_file_find, solib_find): Return
11941 unique_xmalloc_ptr.
11942 (solib_bfd_fopen): Take a const char *.
11943 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
11944 (exec_file_find, solib_find): Likewise.
11945 (solib_bfd_fopen): Do not take ownership of "pathname".
11946 (solib_bfd_open): Use unique_xmalloc_ptr.
11947 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
11948 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
11949 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
11950 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
11951
11952 2018-02-14 Joel Brobecker <brobecker@adacore.com>
11953
11954 * ada-lang.c (name_match_type_from_name): Remove reference to
11955 ada_name_for_lookup in function's documentation.
11956 * ada-lang.h (ada_name_for_lookup): Delete declaration.
11957
11958 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
11959
11960 * defs.h (enum openp_flags): New enum.
11961 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
11962 Move to enum openp_flags.
11963 (openp_flags): New enum flags.
11964 (openp): Change parameter type to openp_flags.
11965 * source.c (openp): Change parameter type to openp_flags.
11966 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
11967 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
11968
11969 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
11970
11971 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
11972 per-command.
11973
11974 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
11975
11976 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
11977 into...
11978 (class dwarf2_queue_guard): ...the destructor of this new class.
11979 (dw2_do_instantiate_symtab): Create instance of the new class
11980 dwarf2_queue_guard, remove cleanup.
11981
11982 2018-02-09 Tom Tromey <tom@tromey.com>
11983
11984 * source.c (find_source_lines): Don't reference past the end of
11985 the vector.
11986
11987 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11988
11989 * remote.c (remote_btrace_maybe_reopen): Change error message.
11990 * btrace.c (btrace_enable): Likewise.
11991 (parse_xml_btrace): Likewise.
11992 (parse_xml_btrace_conf): Likewise.
11993
11994 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11995
11996 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
11997 (linux_enable_pt, linux_enable_bts): Call
11998 diagnose_perf_event_open_fail.
11999
12000 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12001
12002 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
12003 Remove parameter and change return type. Update callers. Move it.
12004 (linux_enable_bts, linux_enable_pt): Improve error message.
12005 (linux_enable_pt): Remove zero buffer size check.
12006 (linux_enable_btrace): Improve error messages. Remove NULL return
12007 check.
12008
12009 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12010
12011 * btrace.c (btrace_enable): Remove target_supports_btrace call.
12012 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
12013 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
12014 (linux_supports_pt, linux_supports_btrace): Remove.
12015 (linux_enable_bts): Call cpu_supports_bts.
12016 * nat/linux-btrace.h (linux_supports_btrace): Remove.
12017 * remote.c (remote_supports_btrace): Remove.
12018 (init_remote_ops): Remove remote_supports_btrace.
12019 * target-delegates.c: Regenerated.
12020 * target.c (target_supports_btrace): Remove.
12021 * target.h (target_ops) <to_supports_btrace>: Remove
12022 (target_supports_btrace): Remove.
12023 * x86-linux-nat.c (x86_linux_create_target): Remove
12024 linux_supports_btrace.
12025
12026 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12027
12028 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
12029 btrace failed.
12030 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
12031 exception and use message in own exception.
12032
12033 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12034
12035 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
12036 (perf_event_pt_event_type): Use gdb_file_up.
12037 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
12038 scoped_fd, and scoped_mmap.
12039
12040 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12041
12042 * common/scoped_mmap.h: New.
12043 * unittests/scoped_mmap-selftest.c: New.
12044 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12045 unittests/scoped_mmap-selftest.c.
12046
12047 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12048
12049 * common/scoped_fd.h: New.
12050 * unittests/scoped_fd-selftest.c: New.
12051 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12052 unittests/scoped_fd-selftest.c.
12053
12054 2018-02-09 Tom Tromey <tom@tromey.com>
12055
12056 * auto-load.c (auto_load_section_scripts): Use
12057 gdb::unique_xmalloc_ptr.
12058
12059 2018-02-09 Tom Tromey <tom@tromey.com>
12060
12061 * auto-load.c (execute_script_contents): Use std::string.
12062
12063 2018-02-09 Joel Brobecker <brobecker@adacore.com>
12064
12065 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
12066 Python function, rather than a new command.
12067
12068 2018-02-08 Tom Tromey <tom@tromey.com>
12069
12070 * solib.c (solib_find_1): Use std::string.
12071 (solib_bfd_fopen): Use unique_xmalloc_ptr.
12072
12073 2018-02-08 Tom Tromey <tom@tromey.com>
12074
12075 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
12076
12077 2018-02-08 Tom Tromey <tom@tromey.com>
12078
12079 * source.c (find_source_lines): Use gdb::def_vector.
12080
12081 2018-02-08 Tom Tromey <tom@tromey.com>
12082
12083 * macrocmd.c (struct temporary_macro_definition): New.
12084 (macro_define_command): Use temporary_macro_definition. Remove
12085 cleanups.
12086 (free_macro_definition_ptr): Remove.
12087
12088 2018-02-08 Tom Tromey <tom@tromey.com>
12089
12090 * macroexp.c (maybe_expand): Use std::string.
12091
12092 2018-02-08 Tom Tromey <tom@tromey.com>
12093
12094 * macroexp.c (struct macro_buffer): Add initializers for some
12095 members.
12096 (init_buffer, init_shared_buffer, free_buffer)
12097 (free_buffer_return_text): Remove.
12098 (macro_buffer): New constructors.
12099 (~macro_buffer): New destructor.
12100 (macro_buffer::set_shared): New method.
12101 (macro_buffer::resize_buffer, macro_buffer::appendc)
12102 (macro_buffer::appendmem): Now methods, not free functions.
12103 (set_token, append_tokens_without_splicing, stringify)
12104 (macro_stringify): Update.
12105 (gather_arguments): Change return type. Remove argc_p argument,
12106 add args_ptr argument. Use std::vector.
12107 (substitute_args): Remove argc argument. Accept std::vector.
12108 (expand): Update. Use std::vector.
12109 (scan, macro_expand, macro_expand_next): Update.
12110
12111 2018-02-08 Tom Tromey <tom@tromey.com>
12112
12113 * symtab.c (default_collect_symbol_completion_matches_break_on):
12114 Use unique_xmalloc_ptr.
12115 * macroscope.h: (sal_macro_scope, user_macro_scope)
12116 (default_macro_scope): Return unique_xmalloc_ptr.
12117 * macroscope.c (sal_macro_scope, user_macro_scope)
12118 (default_macro_scope): Return unique_xmalloc_ptr.
12119 * macroexp.h (macro_expand, macro_expand_once): Return
12120 unique_xmalloc_ptr.
12121 * macroexp.c (macro_expand, macro_expand_once): Return
12122 unique_xmalloc_ptr.
12123 * macrocmd.c (macro_expand_command, macro_expand_once_command)
12124 (info_macro_command, info_macros_command): Use
12125 unique_xmalloc_ptr.
12126 * compile/compile-c-support.c (write_macro_definitions): Use
12127 unique_xmalloc_ptr.
12128 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
12129
12130 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
12131
12132 * value.c (value_static_field): Assign field type instead of
12133 containing type when returning an optimized out value.
12134
12135 2018-02-06 Yao Qi <yao.qi@linaro.org>
12136
12137 * ft32-tdep.c (ft32_read_pc): Remove.
12138 (ft32_write_pc): Remove.
12139 (ft32_gdbarch_init): Update.
12140 * m32r-tdep.c (m32r_read_pc): Remove.
12141 (m32r_gdbarch_init): Update.
12142 * mep-tdep.c (mep_read_pc): Remove.
12143 (mep_gdbarch_init): Update.
12144 * microblaze-tdep.c (microblaze_write_pc): Remove.
12145 (microblaze_gdbarch_init): Update.
12146 * mn10300-tdep.c (mn10300_read_pc): Remove.
12147 (mn10300_write_pc): Remove.
12148 (mn10300_gdbarch_init): Update.
12149 * moxie-tdep.c (moxie_read_pc): Remove.
12150 (moxie_write_pc): Remove.
12151 (moxie_gdbarch_init): Update.
12152
12153 2018-02-06 Yao Qi <yao.qi@linaro.org>
12154
12155 * expprint.c (print_subexp_standard): Handle
12156 OP_F77_UNDETERMINED_ARGLIST.
12157 (dump_subexp_body_standard): Likewise.
12158
12159 2018-02-05 Alan Hayward <alan.hayward@arm.com>
12160
12161 * target-descriptions.c (tdesc_element_visitor) Add empty
12162 implementations.
12163 (tdesc_type): Move make_gdb_type from here.
12164 (tdesc_type_builtin): Likewise.
12165 (tdesc_type_vector): Likewise.
12166 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
12167 (make_gdb_type_struct): Move from tdesc_type_with_fields.
12168 (make_gdb_type_union): Likewise.
12169 (make_gdb_type_flags): Likewise.
12170 (make_gdb_type_enum): Likewise.
12171 (make_gdb_type): New function.
12172 (tdesc_register_type): Use static make_gdb_type.
12173
12174 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
12175
12176 * infcmd.c (default_print_one_register_info): Align natural-format
12177 column values consistently one under another.
12178 (pad_to_column): New function.
12179
12180 2018-02-05 Joel Brobecker <brobecker@adacore.com>
12181
12182 * dwarf2read.c (dwarf2_physname): Move commment.
12183
12184 2018-02-01 Leszek Swirski <leszeks@google.com>
12185
12186 * varobj.c (varobj_formatted_print_options): Allow recursive
12187 pretty printing if pretty printing is enabled.
12188
12189 2018-02-01 Leszek Swirski <leszeks@google.com>
12190
12191 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
12192 names after a structop as a filename.
12193
12194 2018-02-01 Yao Qi <yao.qi@linaro.org>
12195
12196 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
12197 (arm_record_coproc_data_proc): Likewise.
12198
12199 2018-02-01 Yao Qi <yao.qi@linaro.org>
12200
12201 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
12202
12203 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
12204
12205 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
12206 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
12207
12208 2018-01-31 Pedro Alves <palves@redhat.com>
12209
12210 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
12211 * inflow.c (child_terminal_save_inferior): Wrap reference to
12212 tcgetpgrp in HAVE_TERMIOS_H.
12213 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
12214 _WIN32.
12215 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
12216 always iterate over all inferiors.
12217 (gdbsim_cntrl_c): Adjust.
12218 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
12219
12220 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12221
12222 * gdbtypes.c (lookup_array_range_type): Make sure the array's
12223 index type is objfile-owned if the element type is as well.
12224
12225 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12226
12227 GDB 8.1 released.
12228
12229 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
12230
12231 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
12232 "features/s390x-linux64.c".
12233 (_initialize_s390_linux_tdep): Remove initialization of tdescs
12234 s390_linux32 and s390x_linux64.
12235 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
12236 default tdesc.
12237 * s390-tdep.c: Include "features/s390-linux32.c" and
12238 "features/s390x-linux64.c".
12239 (s390_tdesc_valid): Add check for tdesc_has_registers.
12240 (s390_gdbarch_init): Make sure there is always a valid tdesc.
12241 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
12242 tdesc_s390x_linux64.
12243 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
12244 tdesc_s390x_linux64 to...
12245 * s390-tdep.h: ...here.
12246
12247 2018-01-30 Pedro Alves <palves@redhat.com>
12248
12249 PR gdb/13211
12250 * config.in, configure: Regenerate.
12251 * configure.ac: Check for getpgid.
12252 * go32-nat.c (go32_pass_ctrlc): New.
12253 (go32_target): Install it.
12254 * inf-child.c (inf_child_target): Install
12255 child_terminal_save_inferior, child_pass_ctrlc and
12256 child_interrupt.
12257 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
12258 (inf_ptrace_target): No longer install it.
12259 * infcmd.c (interrupt_target_1): Adjust.
12260 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
12261 (child_interrupt): Declare.
12262 (inferior::terminal_state): New.
12263 * inflow.c (struct terminal_info): Update comments.
12264 (inferior_process_group): Delete.
12265 (terminal_is_ours): Delete.
12266 (gdb_tty_state): New.
12267 (child_terminal_init): Adjust.
12268 (is_gdb_terminal, sharing_input_terminal_1)
12269 (sharing_input_terminal): New functions.
12270 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
12271 Set the process's actual process group in the foreground if
12272 possible. Handle is_ours_for_output/is_ours distinction. Don't
12273 mark terminal as the inferior's if not sharing GDB's terminal.
12274 Don't check attach_flag.
12275 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
12276 pass down a target_terminal_state.
12277 (child_terminal_save_inferior): New, factored out from ...
12278 (child_terminal_ours_1): ... this. Handle
12279 target_terminal_state::is_ours_for_output.
12280 (child_interrupt, child_pass_ctrlc): New.
12281 (inflow_inferior_exit): Clear the inferior's terminal_state.
12282 (copy_terminal_info): Copy the inferior's terminal state.
12283 (_initialize_inflow): Remove reference to terminal_is_ours.
12284 * inflow.h (inferior_process_group): Delete.
12285 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
12286 * procfs.c (procfs_target): Don't install procfs_interrupt.
12287 (procfs_interrupt): Delete.
12288 * remote.c (remote_serial_quit_handler): Adjust.
12289 (remote_interrupt): Remove ptid parameter. Adjust.
12290 * target-delegates.c: Regenerate.
12291 * target.c: Include "terminal.h".
12292 (target_terminal::terminal_state): Rename to ...
12293 (target_terminal::m_terminal_state): ... this.
12294 (target_terminal::init): Adjust.
12295 (target_terminal::inferior): Adjust to per-inferior
12296 terminal_state.
12297 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
12298 (target_terminal::ours, target_terminal::ours_for_output): Use
12299 target_terminal_is_ours_kind.
12300 (target_interrupt): Remove ptid parameter. Adjust.
12301 (default_target_pass_ctrlc): Adjust.
12302 * target.h (target_ops::to_terminal_save_inferior): New field.
12303 (target_ops::to_interrupt): Remove ptid_t parameter.
12304 (target_interrupt): Remove ptid_t parameter. Update comment.
12305 (target_pass_ctrlc): Update comment.
12306 * target/target.h (target_terminal_state): New scoped enum,
12307 factored out of ...
12308 (target_terminal::terminal_state): ... here.
12309 (target_terminal::inferior): Update comments.
12310 (target_terminal::restore_inferior): New.
12311 (target_terminal::is_inferior, target_terminal::is_ours)
12312 (target_terminal::is_ours_for_output): Adjust.
12313 (target_terminal::scoped_restore_terminal_state): Adjust to
12314 rename, and call restore_inferior() instead of inferior().
12315 (target_terminal::scoped_restore_terminal_state::m_state): Change
12316 type.
12317 (target_terminal::terminal_state): Rename to ...
12318 (target_terminal::m_terminal_state): ... this and change type.
12319
12320 2018-01-30 Pedro Alves <palves@redhat.com>
12321
12322 * linux-nat.c (wait_for_signal): New function.
12323 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
12324 directly.
12325 (async_terminal_is_ours)
12326 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
12327 (linux_nat_add_target): Don't override
12328 to_terminal_inferior/to_terminal_ours.
12329
12330 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
12331
12332 * remote.c (remote_follow_fork): Don't call "detach_inferior".
12333
12334 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
12335
12336 * dwarf2read.c (free_dwo_files): Add forward-declaration.
12337 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
12338 dwarf2_per_objfile_free here.
12339 (dwarf2_per_objfile_free): Remove.
12340 (_initialize_dwarf2_read): Don't register
12341 dwarf2_per_objfile_free as a registry cleanup.
12342
12343 2018-01-27 Eli Zaretskii <eliz@gnu.org>
12344
12345 Avoid compilation errors in MinGW native builds
12346
12347 The error is triggered by including python-internal.h, and the
12348 error message is:
12349
12350 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
12351 from build-gnulib/import/math.h:27,
12352 from d:/usr/Python26/include/pyport.h:235,
12353 from d:/usr/Python26/include/Python.h:58,
12354 from python/python-internal.h:94,
12355 from python/py-arch.c:24:
12356 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
12357 using ::hypot;
12358 ^~~~~
12359
12360 This happens because Python headers define 'hypot' to expand t
12361 '_hypot' in the Windows builds.
12362 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
12363 'hypoth'. This avoids a compilation error.
12364
12365 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12366
12367 * MAINTAINERS (Write After Approval): Fix ordering.
12368
12369 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12370
12371 * MAINTAINERS (Write After Approval): Add Alan Hayward.
12372
12373 2018-01-26 Alan Modra <amodra@gmail.com>
12374
12375 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
12376 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
12377 Remove nop. Make const. Comment.
12378 (powerpc32_plt_stub_so_2): New.
12379 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
12380 Correct count. Update uses.
12381 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
12382 Move common code reading PLT entry word. Correct
12383 powerpc32_plt_stub PLT address calculation.
12384 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
12385 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
12386 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
12387 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
12388 (ppc64_standard_linkage8): Likewise.
12389 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
12390 Correct insns description.
12391 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
12392
12393 2018-01-24 Pedro Alves <palves@redhat.com>
12394
12395 GCC PR libstdc++/83906
12396 * gdbtypes.c (operator==(const dynamic_prop &,
12397 const dynamic_prop &)): New.
12398 (operator==(const range_bounds &, const range_bounds &)): New.
12399 (check_types_equal): Use them instead of memcmp.
12400 * gdbtypes.h (operator==(const dynamic_prop &,
12401 const dynamic_prop &)): Declare.
12402 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
12403 (operator==(const range_bounds &, const range_bounds &)): Declare.
12404 (operator!=(const range_bounds &, const range_bounds &)): Declare.
12405
12406 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12407
12408 * s390-linux-tdep.c (s390_record_address_mask)
12409 (s390_record_calc_disp_common, s390_record_calc_disp)
12410 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12411 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12412 (s390_process_record): Move to s390-tdep.c.
12413 (s390_linux_init_abi_any): Adjust.
12414 * s390-tdep.c (s390_record_address_mask)
12415 (s390_record_calc_disp_common, s390_record_calc_disp)
12416 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12417 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12418 (s390_process_record): Moved from s390-linux-tdep.c
12419 (s390_gdbarch_init): Adjust.
12420
12421 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12422
12423 * s390-linux-nat.c (s390-tdep.h): New include.
12424 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
12425 (HFILES_NO_SRCDIR): Add s390-tdep.h.
12426 (ALLDEPFILES): Add s390-tdep.c.
12427 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
12428 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
12429 * s390-tdep.h: ...this. New file.
12430 * s390-linux-tdep.c (s390-tdep.h): New include.
12431 (_initialize_s390_tdep): Rename to...
12432 (_initialize_s390_linux_tdep): ...this and adjust.
12433 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
12434 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
12435 s390-tdep.h.
12436 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
12437 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
12438 (s390_is_partial_instruction, s390_software_single_step)
12439 (is_non_branch_ril, s390_displaced_step_copy_insn)
12440 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
12441 (s390_prologue_data, s390_addr, s390_store, s390_load)
12442 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
12443 (s390_register_call_saved, s390_guess_tracepoint_registers)
12444 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
12445 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
12446 (s390_pseudo_register_name, s390_pseudo_register_type)
12447 (s390_pseudo_register_read, s390_pseudo_register_write)
12448 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
12449 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
12450 (s390_addr_bits_remove, s390_address_class_type_flags)
12451 (s390_address_class_type_flags_to_name)
12452 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
12453 (s390_function_arg_float, s390_function_arg_vector)
12454 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
12455 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
12456 (s390_frame_align, s390_register_return_value, s390_return_value)
12457 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
12458 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
12459 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
12460 (s390_trad_frame_prev_register, s390_unwind_cache)
12461 (s390_prologue_frame_unwind_cache)
12462 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
12463 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
12464 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
12465 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
12466 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
12467 (s390_frame_base_address, s390_local_base_address)
12468 (s390_frame_base, s390_gcc_target_options)
12469 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
12470 (s390_validate_reg_range, s390_tdesc_valid)
12471 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
12472 * s390-tdep.c: ...this. New file.
12473
12474 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12475
12476 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
12477 (s390_process_record, s390_gdbarch_tdep_alloc)
12478 (s390_linux_init_abi_any): Use/set new hook.
12479
12480 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12481
12482 * s390-linux-tdep.c (osabi.h): New include.
12483 (s390_linux_init_abi_31, s390_linux_init_abi_64)
12484 (s390_linux_init_abi_any): New functions.
12485 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
12486
12487 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12488
12489 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
12490 tdesc_has_registers check
12491
12492 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12493
12494 * s390-linux-tdep.c (s390_tdesc_valid): New function.
12495 (s390_validate_reg_range): New macro.
12496 (s390_gdbarch_init): Adjust.
12497
12498 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12499
12500 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
12501 (s390_gdbarch_tdep_alloc): Adjust.
12502 (s390_gdbarch_init): Adjust.
12503
12504 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12505
12506 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
12507 <have_tdb>: Change type to bool.
12508 (s390_gdbarch_tdep_alloc): Adjust.
12509 (s390_gdbarch_init): Adjust.
12510
12511 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12512
12513 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
12514 (gdbarch_tdep) <have_upper, have_vx>: New fields.
12515 (s390_gdbarch_tdep_alloc): New function.
12516 (s390_gdbarch_init): Allocate tdep at start and use its fields
12517 instead of separate variables.
12518
12519 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12520
12521 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
12522 when looking for cached gdbarch and add comment for remaining.
12523
12524 2018-01-22 Pedro Alves <palves@redhat.com>
12525 Sergio Durigan Junior <sergiodj@redhat.com>
12526
12527 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
12528 case.
12529
12530 2018-01-22 Maciej W. Rozycki <macro@mips.com>
12531
12532 * MAINTAINERS: Update my company e-mail address.
12533
12534 2018-01-22 Yao Qi <yao.qi@linaro.org>
12535
12536 * regcache.c (cooked_write_test): New function.
12537 (_initialize_regcache): Register the test.
12538
12539 2018-01-22 Yao Qi <yao.qi@linaro.org>
12540
12541 * ia64-tdep.c (ia64_pseudo_register_read): Call
12542 regcache->cooked_read instead of regcache_cooked_read_unsigned.
12543 * m32c-tdep.c (m32c_cat_read): Likewise.
12544 (m32c_r3r2r1r0_read): Likewise.
12545 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
12546 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
12547
12548 2018-01-22 Yao Qi <yao.qi@linaro.org>
12549
12550 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
12551 method raw_read instead of regcache_raw_read.
12552 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
12553 * arm-tdep.c (arm_neon_quad_read): Likewise.
12554 * avr-tdep.c (avr_pseudo_register_read): Likewise.
12555 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
12556 * frv-tdep.c (frv_pseudo_register_read): Likewise.
12557 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
12558 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
12559 (i386_pseudo_register_read_into_value): Likewise.
12560 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
12561 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
12562 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
12563 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
12564 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
12565 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
12566 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
12567 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
12568 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
12569
12570 2018-01-22 Yao Qi <yao.qi@linaro.org>
12571
12572 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
12573 * configure.tgt: Remove target mt.
12574 * mt-tdep.c: Remove.
12575 * regcache.c (cooked_read_test): Remove the check for mt.
12576
12577 2018-01-22 Yao Qi <yao.qi@linaro.org>
12578
12579 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
12580 instead of gdbarch_pseudo_register_read_value.
12581
12582 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12583
12584 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
12585 language is Ada.
12586
12587 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12588
12589 * linespec.c (create_sals_line_offset): Remove code that preserved
12590 the symtab_and_line's line number.
12591
12592 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12593
12594 * varobj.c (varobj_create): Don't set valid_block when creating a
12595 floating varobj.
12596
12597 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12598
12599 * varobj.c (varobj_create): Remove out of date comment.
12600
12601 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12602
12603 PR mi/20395
12604 * ada-exp.y (write_var_from_sym): Pass extra parameter when
12605 updating innermost block.
12606 * parse.c (innermost_block_tracker::update): Take extra type
12607 parameter, and check types match before updating innermost block.
12608 (write_dollar_variable): Update innermost block for registers.
12609 * parser-defs.h (enum innermost_block_tracker_type): New enum.
12610 (innermost_block_tracker::innermost_block_tracker): Initialise
12611 m_types member.
12612 (innermost_block_tracker::reset): Take type parameter.
12613 (innermost_block_tracker::update): Take type parameter, and pass
12614 type through as needed.
12615 (innermost_block_tracker::m_types): New member.
12616 * varobj.c (varobj_create): Pass type when reseting innermost
12617 block.
12618
12619 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12620
12621 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
12622 * ada-lang.c (resolve_subexp): Likewise.
12623 * breakpoint.c (set_breakpoint_condition) Likewise.
12624 (watch_command_1) Likewise.
12625 * c-exp.y (variable): Likewise.
12626 * d-exp.y (PrimaryExpression): Likewise.
12627 * f-exp.y (variable): Likewise.
12628 * go-exp.y (variable): Likewise.
12629 * m2-exp.y (variable): Likewise.
12630 * objfiles.c (objfile::~objfile): Likewise.
12631 * p-exp.y (variable): Likewise.
12632 * parse.c (innermost_block): Change type.
12633 * parser-defs.h (class innermost_block_tracker): New.
12634 (innermost_block): Change to innermost_block_tracker.
12635 * printcmd.c (display_command): Switch to innermost_block API.
12636 (do_one_display): Likewise.
12637 * rust-exp.y (do_one_display): Likewise.
12638 * symfile.c (clear_symtab_users): Likewise.
12639 * varobj.c (varobj_create): Switch to innermost_block API, replace
12640 use of innermost_block with block stored on varobj object.
12641
12642 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12643
12644 * expression.h (innermost_block): Remove declaration.
12645 * varobj.c: Add 'parser-defs.h' include.
12646
12647 2018-01-19 Tom Tromey <tom@tromey.com>
12648
12649 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
12650 symbols in the static and global blocks.
12651
12652 2018-01-19 James Clarke <jrtc27@jrtc27.com>
12653
12654 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
12655 gdb_ptrace.h, and move including gdb_wait.h ...
12656 * nat/linux-ptrace.h: ... to here.
12657
12658 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12659
12660 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
12661 inf_ptrace_detach_success.
12662 (inf_ptrace_detach_success): Add inferior parameter, use it
12663 instead of inferior_ptid, pass it to detach_inferior.
12664 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
12665 parameter.
12666 * inferior.c (detach_inferior): Add overload that takes an
12667 inferior object.
12668 * inferior.h (detach_inferior): Likewise.
12669 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
12670 use inferior_ptid, adjust call to inf_ptrace_detach_success.
12671 * linux-thread-db.c (thread_db_detach): Use inf parameter.
12672
12673 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12674
12675 * target.h (struct target_ops) <to_detach>: Add inferior
12676 parameter.
12677 (target_detach): Likewise.
12678 * target.c (dispose_inferior): Pass inferior down.
12679 (target_detach): Pass inferior down. Assert that it is equal to
12680 the current inferior.
12681 * aix-thread.c (aix_thread_detach): Pass inferior down.
12682 * corefile.c (core_file_command): Pass current_inferior() down.
12683 * corelow.c (core_detach): Add inferior parameter.
12684 * darwin-nat.c (darwin_detach): Likewise.
12685 * gnu-nat.c (gnu_detach): Likewise.
12686 * inf-ptrace.c (inf_ptrace_detach): Likewise.
12687 * infcmd.c (detach_command): Pass current_inferior() down to
12688 target_detach.
12689 * infrun.c (follow_fork_inferior): Pass parent_inf to
12690 target_detach.
12691 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
12692 target_detach.
12693 * linux-nat.c (linux_nat_detach): Add inferior parameter.
12694 * linux-thread-db.c (thread_db_detach): Likewise.
12695 * nto-procfs.c (procfs_detach): Likewise.
12696 * procfs.c (procfs_detach): Likewise.
12697 * record.c (record_detach): Likewise.
12698 * record.h (struct inferior): Forward-declare.
12699 (record_detach): Add inferior parameter.
12700 * remote-sim.c (gdbsim_detach): Likewise.
12701 * remote.c (remote_detach_1): Likewise.
12702 (remote_detach): Likewise.
12703 (extended_remote_detach): Likewise.
12704 * sol-thread.c (sol_thread_detach): Likewise.
12705 * target-debug.h (target_debug_print_inferior_p): New macro.
12706 * target-delegates.c: Re-generate.
12707 * top.c (kill_or_detach): Pass inferior down to target_detach.
12708 * windows-nat.c (windows_detach): Add inferior parameter.
12709
12710 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12711
12712 * target.h (struct target_ops) <to_detach>: Remove args
12713 parameter.
12714 (target_detach): Likewise.
12715 * target.c (dispose_inferior): Adjust.
12716 (target_detach): Remove args parameter, adjust.
12717 * aix-thread.c (aix_thread_detach): Adjust.
12718 * corefile.c (core_file_command): Adjust.
12719 * corelow.c (core_detach): Adjust.
12720 * darwin-nat.c (darwin_detach): Adjust.
12721 * gnu-nat.c (gnu_detach): Adjust.
12722 * inf-ptrace.c (inf_ptrace_detach): Adjust.
12723 * infcmd.c (detach_command): Adjust
12724 * infrun.c (follow_fork_inferior): Adjust.
12725 (handle_vfork_child_exec_or_exit): Adjust.
12726 * linux-fork.c (linux_fork_detach): Remove args parameter.
12727 * linux-fork.h (linux_fork_detach): Likewise.
12728 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
12729 * linux-thread-db.c (thread_db_detach): Likewise.
12730 * nto-procfs.c (procfs_detach): Likewise.
12731 * procfs.c (procfs_detach): Likewise.
12732 (do_detach): Remove signo parameter.
12733 * record.c (record_detach): Remove args parameter.
12734 * record.h (record_detach): Likewise.
12735 * remote-sim.c (gdbsim_detach): Likewise.
12736 * remote.c (remote_detach_1): Likewise.
12737 (remote_detach): Likewise.
12738 (extended_remote_detach): Likewise.
12739 * sol-thread.c (sol_thread_detach): Likewise.
12740 * target-delegates.c: Re-generate.
12741 * top.c (struct qt_args) <args>: Remove field.
12742 (kill_or_detach): Don't pass args.
12743 (quit_force): Don't set args.
12744 * windows-nat.c (windows_detach): Remove args parameter.
12745
12746 2018-01-19 Yao Qi <yao.qi@linaro.org>
12747
12748 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
12749 (arm_linux_init_abi): Install it.
12750
12751 2018-01-19 Yao Qi <yao.qi@linaro.org>
12752
12753 * osabi.c (gdb_osabi_names): Extend the regexp for
12754 arm-linux-gnueabihf.
12755
12756 2018-01-18 Yao Qi <yao.qi@linaro.org>
12757
12758 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
12759 m_abbrevs.
12760 (abbrev_table::add_abbrev): Update.
12761 (abbrev_table::lookup_abbrev): Update.
12762
12763 2018-01-18 Yao Qi <yao.qi@linaro.org>
12764
12765 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
12766
12767 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
12768
12769 * compile/compile.c (compile_to_object): Convert "triplet_rx"
12770 to "std::string".
12771
12772 2018-01-17 Tom Tromey <tom@tromey.com>
12773
12774 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
12775
12776 2018-01-17 Tom Tromey <tom@tromey.com>
12777
12778 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
12779 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
12780 (create_array_type_with_stride): Update.
12781 * dwarf2read.c (set_die_type): Update.
12782
12783 2018-01-17 Tom Tromey <tom@tromey.com>
12784
12785 * dwarf2read.c (delayed_method_info): Remove typedef.
12786 (dwarf2_cu::method_info): Now a std::vector.
12787 (add_to_method_list): Update.
12788 (free_delayed_list): Remove.
12789 (compute_delayed_physnames): Update.
12790 (process_full_comp_unit, process_full_type_unit): Clear the method
12791 list. Remove cleanups.
12792 (psymtab_include_file_name): Add name_holder parameter. Use
12793 unique_xmalloc_ptr.
12794 (dwarf_decode_lines): Update.
12795
12796 2018-01-17 Tom Tromey <tom@tromey.com>
12797 Simon Marchi <simon.marchi@ericsson.com>
12798
12799 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
12800 (dwarf2_per_objfile::free_cached_comp_units)
12801 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12802 (init_cutu_and_read_dies_no_follow): Update.
12803 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
12804 (dwarf2_cu::~dwarf2_cu): New.
12805 (free_heap_comp_unit, free_stack_comp_unit): Remove.
12806 (age_cached_comp_units, free_one_cached_comp_unit): Update.
12807
12808 2018-01-17 Tom Tromey <tom@tromey.com>
12809 Simon Marchi <simon.marchi@ericsson.com>
12810
12811 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
12812 (struct die_reader_specs) <abbrev_table>: New member.
12813 (struct abbrev_table): Add constructor.
12814 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
12815 <abbrev_obstack>: Now an auto_obstack.
12816 (abbrev_table_up): New typedef.
12817 (init_cu_die_reader): Add abbrev_table parameter.
12818 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
12819 Add result_dwo_abbrev_table.
12820 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12821 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
12822 Update.
12823 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
12824 parameter.
12825 (skip_children): Update.
12826 (abbrev_table::alloc_abbrev): Rename from
12827 abbrev_table_alloc_abbrev.
12828 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
12829 (abbrev_table::lookup_abbrev): Rename from
12830 abbrev_table_lookup_abbrev.
12831 (abbrev_table_read_table): Return abbrev_table_up.
12832 (abbrev_table_free, abbrev_table_free_cleanup)
12833 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
12834 (load_partial_dies): Update.
12835
12836 2018-01-17 Tom Tromey <tom@tromey.com>
12837
12838 * dwarf2read.c (dwarf2_compute_name): Update comment.
12839 (read_func_scope, read_variable): Update.
12840 (new_symbol): Remove.
12841 (new_symbol_full): Rename to new_symbol.
12842
12843 2018-01-17 Mike Gulick <mgulick@mathworks.com>
12844
12845 PR gdb/16577
12846 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
12847 a warning instead of throwing an error, set section size to 0 and return
12848 NULL.
12849 * gdb_bfd.h (gdb_bfd_map_section): Update description.
12850
12851 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
12852
12853 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
12854 std::string.
12855 (linux_ptrace_attach_fail_reason_string): Likewise.
12856 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
12857 Likewise.
12858 (linux_ptrace_attach_fail_reason_string): Likewise.
12859 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
12860
12861 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
12862
12863 * linux-nat.c (linux_nat_attach): Remove xstrdup.
12864
12865 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
12866
12867 PR gdb/21559
12868 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
12869 checking for fs_base/gs_base fields in struct user_regs_struct.
12870 * configure: Regenerate.
12871
12872 2018-01-17 Yao Qi <yao.qi@linaro.org>
12873
12874 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
12875 function.
12876 (aarch64_linux_init_abi): Install it to gdbarch hook
12877 gcc_target_options.
12878
12879 2018-01-15 Pedro Alves <palves@redhat.com>
12880
12881 * common/signals-state-save-restore.c
12882 (save_original_signals_state): Fix typos.
12883
12884 2017-01-12 Tom Tromey <tom@tromey.com>
12885 Sergio Durigan Junior <sergiodj@redhat.com>
12886
12887 * Makefile.in (install-only): Install gdb-add-index.
12888
12889 2018-01-12 John Baldwin <jhb@FreeBSD.org>
12890
12891 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
12892
12893 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
12894
12895 * infrun.c (keep_going_pass_signal): Clear step-over info when
12896 insert_breakpoints fails.
12897
12898 2018-01-11 Pedro Alves <palves@redhat.com>
12899
12900 PR gdb/22583
12901 * infrun.c (resume): Rename to ...
12902 (resume_1): ... this.
12903 (resume): Reimplement as wrapper around resume_1.
12904
12905 2018-01-11 Pedro Alves <palves@redhat.com>
12906
12907 PR remote/22597
12908 * remote.c (remote_parse_stop_reply): Default to the last-set
12909 general thread instead of to 'magic_null_ptid'.
12910
12911 2018-01-10 Pedro Alves <palves@redhat.com>
12912
12913 * language.h (language_get_symbol_name_matcher): Rename ...
12914 (get_symbol_name_matcher): ... this.
12915 * language.c (language_get_symbol_name_matcher): Ditto.
12916 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
12917 callers adjusted.
12918
12919 2018-01-10 Pedro Alves <palves@redhat.com>
12920
12921 PR gdb/22670
12922 * dwarf2read.c
12923 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
12924 Adjust to use language_get_symbol_name_matcher instead of
12925 language_defn::la_get_symbol_name_matcher.
12926 * language.c (language_get_symbol_name_matcher): If in Ada mode
12927 and the lookup name is a verbatim match, return Ada's matcher.
12928 * language.h (language_get_symbol_name_matcher): Adjust comment.
12929 (ada_lookup_name_info::verbatim_p):: New method.
12930
12931 2018-01-10 Pedro Alves <palves@redhat.com>
12932
12933 PR gdb/22670
12934 * ada-lang.c (ada_collect_symbol_completion_matches): If the
12935 minsym's language is language_auto or language_cplus, pass down
12936 language_ada instead.
12937 * symtab.c (compare_symbol_name): Don't frob symbol language here.
12938
12939 2018-01-10 Pedro Alves <palves@redhat.com>
12940
12941 PR gdb/22670
12942 * minsyms.c (linkage_name_str): New function.
12943 (iterate_over_minimal_symbols): Use it.
12944
12945 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12946
12947 * NEWS: Document that 'info proc' now works on FreeBSD.
12948
12949 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12950
12951 * configure.ac: Check for kinfo_getfile in libutil.
12952 * configure: Regenerate.
12953 * config.in: Regenerate.
12954 * fbsd-nat.c: Include "fbsd-tdep.h".
12955 (fbsd_fetch_cmdline): New.
12956 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
12957 rather than calling error.
12958 (fbsd_info_proc): New.
12959 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
12960 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
12961 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
12962
12963 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12964
12965 * fbsd-nat.c (struct free_deleter): Remove.
12966 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
12967
12968 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12969
12970 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
12971 NULL for an empty pathname.
12972
12973 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12974
12975 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
12976 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
12977 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
12978 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
12979 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
12980 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
12981 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
12982 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
12983 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
12984 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
12985 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
12986 (fbsd_core_fetch_timeval, fbsd_print_sigset)
12987 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
12988 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
12989 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
12990
12991 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
12992
12993 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
12994 (gnu_xfer_auxv): New function.
12995 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
12996 TARGET_OBJECT_AUXV.
12997
12998 2018-01-08 Yao Qi <yao.qi@linaro.org>
12999 Simon Marchi <simon.marchi@ericsson.com>
13000
13001 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
13002 common/selftest.c.
13003 (COMMON_OBS): Remove selftest.o.
13004 * configure.ac: Append selftest-arch.c and common/selftest.c to
13005 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
13006 * configure: Re-generated.
13007 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
13008 GDB_SELF_TEST.
13009 (maintenance_info_selftests): Likewise.
13010
13011 2018-01-08 Xavier Roirand <roirand@adacore.com>
13012
13013 * ada-valprint.c (val_print_packed_array_elements): Use
13014 proper number of elements when printing an array indexed
13015 by an enumeration type.
13016
13017 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13018
13019 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
13020 (dw2_get_file_names_reader): Adjust.
13021 (lookup_dwo_signatured_type): Adjust.
13022 (lookup_dwp_signatured_type): Adjust.
13023 (lookup_signatured_type): Adjust.
13024 (create_type_unit_group): Adjust.
13025 (get_type_unit_group): Adjust.
13026 (process_psymtab_comp_unit_reader): Adjust.
13027 (build_type_psymtabs_reader): Adjust.
13028 (scan_partial_symbols): Adjust.
13029 (add_partial_symbol): Adjust.
13030 (add_partial_subprogram): Adjust.
13031 (peek_die_abbrev): Adjust.
13032 (fixup_go_packaging): Adjust.
13033 (process_imported_unit_die): Adjust.
13034 (dwarf2_compute_name): Adjust.
13035 (dwarf2_physname): Adjust.
13036 (read_import_statement): Adjust.
13037 (handle_DW_AT_stmt_list): Adjust.
13038 (read_file_scope): Adjust.
13039 (read_func_scope): Adjust.
13040 (read_lexical_block_scope): Adjust.
13041 (read_call_site_scope): Adjust.
13042 (read_variable): Adjust.
13043 (dwarf2_rnglists_process): Adjust.
13044 (dwarf2_ranges_process): Adjust.
13045 (dwarf2_ranges_read): Adjust.
13046 (dwarf2_get_pc_bounds): Adjust.
13047 (dwarf2_record_block_ranges): Adjust.
13048 (dwarf2_add_field): Adjust.
13049 (dwarf2_add_member_fn): Adjust.
13050 (read_structure_type): Adjust.
13051 (process_structure_scope): Adjust.
13052 (read_enumeration_type): Adjust.
13053 (read_array_type): Adjust.
13054 (mark_common_block_symbol_computed): Adjust.
13055 (read_common_block): Adjust.
13056 (read_namespace_type): Adjust.
13057 (read_namespace): Adjust.
13058 (read_module_type): Adjust.
13059 (read_tag_pointer_type): Adjust.
13060 (read_tag_ptr_to_member_type): Adjust.
13061 (read_tag_string_type): Adjust.
13062 (read_subroutine_type): Adjust.
13063 (read_typedef): Adjust.
13064 (read_base_type): Adjust.
13065 (attr_to_dynamic_prop): Adjust.
13066 (read_subrange_type): Adjust.
13067 (read_unspecified_type): Adjust.
13068 (dwarf2_read_abbrevs): Adjust.
13069 (load_partial_dies): Adjust.
13070 (read_partial_die): Adjust.
13071 (find_partial_die): Adjust.
13072 (guess_partial_die_structure_name): Adjust.
13073 (fixup_partial_die): Adjust.
13074 (read_attribute_value): Adjust.
13075 (read_addr_index): Adjust.
13076 (read_addr_index_from_leb128): Adjust.
13077 (read_str_index): Adjust.
13078 (dwarf2_string_attr): Adjust.
13079 (get_debug_line_section): Adjust.
13080 (dwarf_decode_line_header): Adjust.
13081 (lnp_state_machine::check_line_address): Adjust.
13082 (dwarf_decode_lines_1): Adjust.
13083 (dwarf_decode_lines): Adjust.
13084 (dwarf2_start_symtab): Adjust.
13085 (var_decode_location): Adjust.
13086 (new_symbol_full): Adjust.
13087 (dwarf2_const_value_data): Adjust.
13088 (dwarf2_const_value_attr): Adjust.
13089 (dwarf2_const_value): Adjust.
13090 (die_type): Adjust.
13091 (die_containing_type): Adjust.
13092 (build_error_marker_type): Adjust.
13093 (lookup_die_type): Adjust.
13094 (guess_full_die_structure_name): Adjust.
13095 (anonymous_struct_prefix): Adjust.
13096 (determine_prefix): Adjust.
13097 (dwarf2_name): Adjust.
13098 (follow_die_ref_or_sig): Adjust.
13099 (follow_die_offset): Adjust.
13100 (follow_die_ref): Adjust.
13101 (follow_die_sig_1): Adjust.
13102 (follow_die_sig): Adjust.
13103 (get_signatured_type): Adjust.
13104 (get_DW_AT_signature_type): Adjust.
13105 (decode_locdesc): Adjust.
13106 (dwarf_decode_macros): Adjust.
13107 (cu_debug_loc_section): Adjust.
13108 (fill_in_loclist_baton): Adjust.
13109 (dwarf2_symbol_mark_computed): Adjust.
13110 (init_one_comp_unit): Don't assign
13111 dwarf2_cu::dwarf2_per_objfile.
13112 (set_die_type): Adjust.
13113
13114 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13115
13116 * dwarf2read.c (struct mapped_debug_names): Add constructor.
13117 <dwarf2_per_objfile>: New field.
13118 (dwarf2_per_objfile): Remove global.
13119 (get_dwarf2_per_objfile): New function.
13120 (set_dwarf2_per_objfile): New function.
13121 (dwarf2_build_psymtabs_hard): Change objfile parameter to
13122 dwarf2_per_objfile.
13123 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
13124 (read_abbrev_offset): Likewise.
13125 (read_indirect_string): Likewise.
13126 (read_indirect_line_string): Likewise.
13127 (read_indirect_string_at_offset): Likewise.
13128 (read_indirect_string_from_dwz): Likewise.
13129 (dwarf2_find_containing_comp_unit): Change objfile parameter to
13130 dwarf2_per_objfile.
13131 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
13132 (create_all_comp_units): Change objfile parameter to
13133 dwarf2_per_objfile.
13134 (create_all_type_units): Likewise.
13135 (process_queue): Add dwarf2_per_objfile parameter.
13136 (read_and_check_comp_unit_head): Likewise.
13137 (lookup_dwo_unit_in_dwp): Likewise.
13138 (get_dwp_file): Likewise.
13139 (process_cu_includes): Likewise.
13140 (struct free_dwo_file_cleanup_data): New struct.
13141 (dwarf2_has_info): Use get_dwarf2_per_objfile and
13142 set_dwarf2_per_objfile.
13143 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
13144 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
13145 context, adjust calls.
13146 (dw2_instantiate_symtab): Likewise.
13147 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
13148 (dw2_get_cu): Likewise.
13149 (create_cu_from_index_list): Change objfile parameter to
13150 dwarf2_per_objfile.
13151 (create_cus_from_index_list): Get dwarf2_per_objfile from
13152 context, adjust calls.
13153 (create_cus_from_index): Likewise.
13154 (create_signatured_type_table_from_index): Change objfile
13155 parameter to dwarf2_per_objfile.
13156 (create_signatured_type_table_from_debug_names): Change objfile
13157 parameter to dwarf2_per_objfile.
13158 (create_addrmap_from_index): Likewise.
13159 (create_addrmap_from_aranges): Likewise.
13160 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
13161 (dw2_setup): Remove.
13162 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
13163 context.
13164 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
13165 get_dwarf2_per_objfile.
13166 (dw2_forget_cached_source_info): Likewise.
13167 (dw2_map_symtabs_matching_filename): Likewise.
13168 (struct dw2_symtab_iterator) <index>: Remove.
13169 <dwarf2_per_objfile>: New field.
13170 (dw2_symtab_iter_init): Replace index parameter with
13171 dwarf2_per_objfile.
13172 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
13173 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
13174 (dw2_print_stats): Likewise.
13175 (dw2_dump): Likewise.
13176 (dw2_expand_symtabs_for_function): Likewise.
13177 (dw2_expand_all_symtabs): Likewise.
13178 (dw2_expand_symtabs_with_fullname): Likewise.
13179 (dw2_expand_marked_cus): Replace index and objfile parameters
13180 with dwarf2_per_objfile.
13181 (dw_expand_symtabs_matching_file_matcher): Add
13182 dwarf2_per_objfile parameter and adjust calls.
13183 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
13184 adjust calls.
13185 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
13186 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
13187 adjust calls.
13188 (create_cus_from_debug_names_list): Replace objfile parameter
13189 with dwarf2_per_objfile and adjust calls.
13190 (create_cus_from_debug_names): Likewise.
13191 (dwarf2_read_debug_names): Likewise.
13192 (mapped_debug_names::namei_to_name): Adjust call.
13193 (dw2_debug_names_iterator::next): Likewise.
13194 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
13195 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
13196 (dw2_debug_names_dump): Likewise.
13197 (dw2_debug_names_expand_symtabs_for_function): Likewise.
13198 (dw2_debug_names_expand_symtabs_matching): Likewise.
13199 (dwarf2_initialize_objfile): Likewise.
13200 (dwarf2_build_psymtabs): Likewise.
13201 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
13202 this_cu.
13203 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
13204 (read_and_check_comp_unit_head): Likewise.
13205 (read_abbrev_offset): Likewise.
13206 (create_debug_type_hash_table): Likewise.
13207 (create_debug_types_hash_table): Likewise.
13208 (create_all_type_units): Replace objfile parameter with
13209 dwarf2_per_objfile.
13210 (add_type_unit): Add dwarf2_per_objfile parameter.
13211 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
13212 with dwarf2_per_objfile.
13213 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
13214 (lookup_dwp_signatured_type): Likewise.
13215 (lookup_signatured_type): Likewise.
13216 (read_cutu_die_from_dwo): Likewise.
13217 (init_tu_and_read_dwo_dies): Likewise.
13218 (init_cutu_and_read_dies): Likewise.
13219 (init_cutu_and_read_dies_no_follow): Likewise.
13220 (allocate_type_unit_groups_table): Add objfile parameter.
13221 (create_type_unit_group): Use dwarf2_per_objfile from cu.
13222 (get_type_unit_group): Likewise.
13223 (process_psymtab_comp_unit): Update call.
13224 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
13225 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
13226 (print_tu_stats): Likewise.
13227 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
13228 in void* parameter.
13229 (build_type_psymtabs): Change objfile parameter to
13230 dwarf2_per_objfile.
13231 (process_skeletonless_type_unit): Use dwarf2_per_objfile
13232 passed in void* parameter.
13233 (process_skeletonless_type_units): Change objfile parameter to
13234 dwarf2_per_objfile.
13235 (set_partial_user): Likewise.
13236 (dwarf2_build_psymtabs_hard): Likewise.
13237 (read_comp_units_from_section): Likewise.
13238 (create_all_comp_units): Likewise.
13239 (scan_partial_symbols): Update calls.
13240 (add_partial_symbol): Likewise.
13241 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
13242 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
13243 (process_queue): Add dwarf2_per_objfile parameter.
13244 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
13245 (compute_compunit_symtab_includes): Likewise.
13246 (process_cu_includes): Add dwarf2_per_objfile parameter.
13247 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
13248 (process_full_type_unit): Likewise.
13249 (process_imported_unit_die): Update call.
13250 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
13251 (read_file_scope): Likewise.
13252 (allocate_dwo_file_hash_table): Add objfile parameter.
13253 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
13254 (create_cus_hash_table): Likewise.
13255 (create_dwp_hash_table): Likewise.
13256 (create_dwo_unit_in_dwp_v1): Likewise.
13257 (create_dwp_v2_section): Likewise.
13258 (create_dwo_unit_in_dwp_v2): Likewise.
13259 (lookup_dwo_unit_in_dwp): Likewise.
13260 (try_open_dwop_file): Likewise.
13261 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
13262 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
13263 cleanup to include a reference to dwarf2_per_objfile.
13264 (open_dwp_file): Add dwarf2_per_objfile parameter.
13265 (open_and_init_dwp_file): Likewise.
13266 (get_dwp_file): Likewise.
13267 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
13268 (queue_and_load_all_dwo_tus): Update call.
13269 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
13270 data.
13271 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
13272 (dwarf2_ranges_process): Likewise.
13273 (dwarf2_get_pc_bounds): Likewise.
13274 (mark_common_block_symbol_computed): Likewise.
13275 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
13276 (dwarf2_read_abbrevs): Update call.
13277 (read_partial_die): Use dwarf2_per_objfile from cu.
13278 (find_partial_die): Likewise.
13279 (fixup_partial_die): Likewise.
13280 (read_attribute_value): Likewise.
13281 (read_indirect_string_at_offset_from): Add objfile parameter.
13282 (read_indirect_string_at_offset): Add dwarf2_per_objfile
13283 parameter.
13284 (read_indirect_string_from_dwz): Add objfile parameter.
13285 (read_indirect_string): Add objfile parameter.
13286 (read_addr_index_1): Add dwarf2_per_objfile parameter.
13287 (read_addr_index): Use dwarf2_per_objfile from cu.
13288 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
13289 call dw2_setup.
13290 (read_str_index): Use dwarf2_per_objfile from cu.
13291 (get_debug_line_section): Likewise.
13292 (read_formatted_entries): Add dwarf2_per_objfile parameter.
13293 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
13294 (new_symbol_full): Use dwarf2_per_objfile from cu.
13295 (build_error_marker_type): Likewise.
13296 (lookup_die_type): Likewise.
13297 (determine_prefix): Likewise.
13298 (follow_die_offset): Likewise.
13299 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
13300 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
13301 (dwarf2_fetch_die_type_sect_off): Likewise.
13302 (dwarf2_get_die_type): Likewise.
13303 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
13304 (get_signatured_type): Likewise.
13305 (get_DW_AT_signature_type): Likewise.
13306 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
13307 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
13308 (cu_debug_loc_section): Likewise.
13309 (fill_in_loclist_baton): Likewise.
13310 (dwarf2_symbol_mark_computed): Likewise.
13311 (dwarf2_find_containing_comp_unit): Change objfile parameter to
13312 dwarf2_per_objfile.
13313 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
13314 parameter.
13315 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
13316 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
13317 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
13318 (set_die_type): Use dwarf2_free_objfile from cu.
13319 (get_die_type_at_offset): Likewise.
13320 (dwarf2_per_objfile_free): Don't assign global variable.
13321 (debug_names) <constructor>: Add dwarf2_per_objfile
13322 parameter, update m_debugstrlookup construction.
13323 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
13324 parameter.
13325 <m_dwarf2_per_objfile>: New field.
13326 <lookup>: Use m_dwarf2_per_objfile.
13327 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
13328 (psyms_seen_size): Likewise.
13329 (write_gdbindex): Replace objfile parameter with
13330 dwarf2_per_objfile.
13331 (write_debug_names): Likewise.
13332 (write_psymtabs_to_index): Likewise.
13333 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
13334 calls.
13335
13336 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13337
13338 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
13339 <dwarf2_per_objfile>: New field.
13340 (struct dwarf2_per_cu_data) <objfile>: Remove.
13341 <dwarf2_per_objfile>: New field.
13342 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
13343 of objfile.
13344 (create_signatured_type_table_from_index): Likewise.
13345 (create_debug_type_hash_table): Likewise.
13346 (fill_in_sig_entry_from_dwo_entry): Likewise.
13347 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
13348 (create_type_unit_group): Assign dwarf2_per_objfile instead of
13349 objfile.
13350 (create_partial_symtab): Access objfile through
13351 dwarf2_per_objfile.
13352 (process_psymtab_comp_unit_reader): Likewise.
13353 (read_comp_units_from_section): Likewise.
13354 (scan_partial_symbols): Likewise.
13355 (add_partial_symbol): Likewise.
13356 (add_partial_subprogram): Likewise.
13357 (peek_die_abbrev): Likewise.
13358 (fixup_go_packaging): Likewise.
13359 (process_full_comp_unit): Likewise.
13360 (process_full_type_unit): Likewise.
13361 (process_imported_unit_die): Likewise.
13362 (dwarf2_compute_name): Likewise.
13363 (dwarf2_physname): Likewise.
13364 (read_import_statement): Likewise.
13365 (create_cus_hash_table): Assign dwarf2_physname instead of
13366 objfile.
13367 (read_func_scope): Access objfile through dwarf2_per_objfile.
13368 (read_lexical_block_scope): Likewise.
13369 (read_call_site_scope): Likewise.
13370 (read_variable): Likewise.
13371 (dwarf2_rnglists_process): Likewise.
13372 (dwarf2_ranges_process): Likewise.
13373 (dwarf2_ranges_read): Likewise.
13374 (dwarf2_record_block_ranges): Likewise.
13375 (dwarf2_add_field): Likewise.
13376 (dwarf2_add_member_fn): Likewise.
13377 (read_structure_type): Likewise.
13378 (process_structure_scope): Likewise.
13379 (read_enumeration_type): Likewise.
13380 (read_array_type): Likewise.
13381 (read_common_block): Likewise.
13382 (read_namespace_type): Likewise.
13383 (read_namespace): Likewise.
13384 (read_module_type): Likewise.
13385 (read_tag_pointer_type): Likewise.
13386 (read_tag_ptr_to_member_type): Likewise.
13387 (read_tag_string_type): Likewise.
13388 (read_subroutine_type): Likewise.
13389 (read_typedef): Likewise.
13390 (read_base_type): Likewise.
13391 (attr_to_dynamic_prop): Likewise.
13392 (read_subrange_type): Likewise.
13393 (read_unspecified_type): Likewise.
13394 (load_partial_dies): Likewise.
13395 (read_partial_die): Likewise.
13396 (find_partial_die): Likewise.
13397 (guess_partial_die_structure_name): Likewise.
13398 (fixup_partial_die): Likewise.
13399 (read_attribute_value): Likewise.
13400 (read_addr_index_from_leb128): Likewise.
13401 (dwarf2_read_addr_index): Likewise.
13402 (dwarf2_string_attr): Likewise.
13403 (lnp_state_machine::check_line_address): Likewise.
13404 (dwarf_decode_lines_1): Likewise.
13405 (dwarf_decode_lines): Likewise.
13406 (dwarf2_start_symtab): Likewise.
13407 (var_decode_location): Likewise.
13408 (new_symbol_full): Likewise.
13409 (dwarf2_const_value_data): Likewise.
13410 (dwarf2_const_value_attr): Likewise.
13411 (dwarf2_const_value): Likewise.
13412 (die_type): Likewise.
13413 (die_containing_type): Likewise.
13414 (lookup_die_type): Likewise.
13415 (guess_full_die_structure_name): Likewise.
13416 (anonymous_struct_prefix): Likewise.
13417 (dwarf2_name): Likewise.
13418 (follow_die_ref_or_sig): Likewise.
13419 (follow_die_offset): Likewise.
13420 (follow_die_ref): Likewise.
13421 (dwarf2_fetch_die_loc_sect_off): Likewise.
13422 (dwarf2_fetch_constant_bytes): Likewise.
13423 (dwarf2_fetch_die_type_sect_off): Likewise.
13424 (dwarf2_get_die_type): Likewise.
13425 (follow_die_sig): Likewise.
13426 (decode_locdesc): Likewise.
13427 (dwarf2_per_cu_objfile): Likewise.
13428 (dwarf2_per_cu_text_offset): Likewise.
13429 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
13430 objfile.
13431 (set_die_type): Access objfile through
13432 dwarf2_per_objfile.
13433
13434 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13435
13436 * valprint.c (converted_character_d): Remove typedef.
13437 (DEF_VEC_O (converted_character_d)): Remove.
13438 (count_next_character): Use std::vector.
13439 (print_converted_chars_to_obstack): Likewise.
13440 (generic_printstr): Likewise.
13441
13442 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13443
13444 * xml-support.h (struct gdb_xml_value): Add constructor.
13445 <value>: Change type to unique_xmalloc_ptr.
13446 (gdb_xml_value_s): Remove typedef.
13447 (DEF_VEC_O (gdb_xml_value_s)): Remove.
13448 (gdb_xml_element_start_handler): Change parameter type to
13449 std::vector.
13450 (xml_find_attribute): Likewise.
13451 * xml-support.c (xml_find_attribute): Change parameter type to
13452 std::vector and adjust.
13453 (gdb_xml_values_cleanup): Remove.
13454 (gdb_xml_parser::start_element): Adjust to std::vector.
13455 (xinclude_start_include): Change paraeter type to std::vector
13456 and adjust.
13457 * btrace.c (check_xml_btrace_version): Likewise.
13458 (parse_xml_btrace_block): Likewise.
13459 (parse_xml_btrace_pt_config_cpu): Likewise.
13460 (parse_xml_btrace_pt): Likewise.
13461 (parse_xml_btrace_conf_bts): Likewise.
13462 (parse_xml_btrace_conf_pt): Likewise.
13463 * memory-map.c (memory_map_start_memory): Likewise.
13464 (memory_map_start_property): Likewise.
13465 * osdata.c (osdata_start_osdata): Likewise.
13466 (osdata_start_item): Likewise.
13467 (osdata_start_column): Likewise.
13468 * remote.c (start_thread): Likewise.
13469 * solib-aix.c (library_list_start_library): Likewise.
13470 (library_list_start_list): Likewise.
13471 * solib-svr4.c (library_list_start_library): Likewise.
13472 (svr4_library_list_start_list): Likewise.
13473 * solib-target.c (library_list_start_segment): Likewise.
13474 (library_list_start_section): Likewise.
13475 (library_list_start_library): Likewise.
13476 (library_list_start_list): Likewise.
13477 * tracepoint.c (traceframe_info_start_memory): Likewise.
13478 (traceframe_info_start_tvar): Likewise.
13479 * xml-syscall.c (syscall_start_syscall): Likewise.
13480 * xml-tdesc.c (tdesc_start_target): Likewise.
13481 (tdesc_start_feature): Likewise.
13482 (tdesc_start_reg): Likewise.
13483 (tdesc_start_union): Likewise.
13484 (tdesc_start_struct): Likewise.
13485 (tdesc_start_flags): Likewise.
13486 (tdesc_start_enum): Likewise.
13487 (tdesc_start_field): Likewise.
13488 (tdesc_start_enum_value): Likewise.
13489 (tdesc_start_vector): Likewise.
13490
13491 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13492
13493 * extension.h (struct xmethod_worker) <clone>: Remove.
13494 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
13495 Remove.
13496 (python_xmethod_worker::clone): Remove.
13497 * valops.c (find_overload_match): Use std::move instead of
13498 clone.
13499
13500 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13501
13502 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
13503 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
13504 <free_xmethod_worker_data>: Remove.
13505 <get_matching_xmethod_workers>: Chance VEC to std::vector.
13506 <get_xmethod_arg_types>: Remove.
13507 <get_xmethod_result_type>: Remove.
13508 <invoke_xmethod>: Remove.
13509 * extension.c (new_xmethod_worker): Remove.
13510 (clone_xmethod_worker): Remove.
13511 (get_matching_xmethod_workers): Return void, pass std::vector by
13512 pointer.
13513 (get_xmethod_arg_types): Rename to...
13514 (xmethod_worker::get_arg_types): ... this, and adjust.
13515 (get_xmethod_result_type): Rename to...
13516 (xmethod_worker::get_result_type): ... this, and adjust.
13517 (invoke_xmethod): Remove.
13518 (free_xmethod_worker): Remove.
13519 (free_xmethod_worker_vec): Remove.
13520 * extension.h (enum ext_lang_rc): Move here from
13521 extension-priv.h.
13522 (struct xmethod_worker): Add constructor and destructor.
13523 <data>: Remove.
13524 <value>: Remove.
13525 <invoke, clone, do_get_result_type, do_get_arg_types>: New
13526 virtual pure methods.
13527 <get_arg_types, get_result_type>: New methods.
13528 (xmethod_worker_ptr): Remove typedef.
13529 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
13530 (xmethod_worker_vec): Remove typedef.
13531 (xmethod_worker_up): New typedef.
13532 (invoke_xmethod): Remove.
13533 (clone_xmethod_worker): Remove.
13534 (free_xmethod_worker): Remove.
13535 (free_xmethod_worker_vec): Remove.
13536 (get_xmethod_arg_types): Remove.
13537 (get_xmethod_result_type): Remove.
13538 * valops.c (find_method_list): Use std::vector, don't use
13539 intermediate vector.
13540 (value_find_oload_method_list): Use std::vector.
13541 (find_overload_match): Use std::vector.
13542 (find_oload_champ): Use std::vector.
13543 * value.c (value_free): Use operator delete.
13544 (value_of_xmethod): Rename to...
13545 (value_from_xmethod): ... this. Don't assign
13546 xmethod_worker::value, take rvalue-reference.
13547 (result_type_of_xmethod): Adjust.
13548 (call_xmethod): Adjust.
13549 * value.h: Include extension.h.
13550 (struct xmethod_worker): Don't forward-declare.
13551 (value_of_xmethod): Rename to...
13552 (value_from_xmethod): ... this, take rvalue-reference.
13553 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
13554 (struct python_xmethod_worker): ... this, add constructor and
13555 destructor.
13556 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
13557 (gdbpy_free_xmethod_worker_data): Rename to...
13558 (python_xmethod_worker::~python_xmethod_worker): ... this and
13559 adjust.
13560 (gdbpy_clone_xmethod_worker_data): Rename to...
13561 (python_xmethod_worker::clone): ... this and adjust.
13562 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
13563 temporary vector.
13564 (gdbpy_get_xmethod_arg_types): Rename to...
13565 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
13566 (gdbpy_get_xmethod_result_type): Rename to...
13567 (python_xmethod_worker::do_get_result_type): ... this and
13568 adjust.
13569 (gdbpy_invoke_xmethod): Rename to...
13570 (python_xmethod_worker::invoke): ... this and adjust.
13571 (new_python_xmethod_worker): Rename to...
13572 (python_xmethod_worker::python_xmethod_worker): ... this and
13573 adjust.
13574 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
13575 Remove.
13576 (gdbpy_free_xmethod_worker_data): Remove.
13577 (gdbpy_get_matching_xmethod_workers): Use std::vector.
13578 (gdbpy_get_xmethod_arg_types): Remove.
13579 (gdbpy_get_xmethod_result_type): Remove.
13580 (gdbpy_invoke_xmethod): Remove.
13581 * python/python.c (python_extension_ops): Remove obsolete
13582 callbacks.
13583
13584 2018-01-05 Pedro Alves <palves@redhat.com>
13585
13586 PR gdb/18653
13587 * common/signals-state-save-restore.c
13588 (save_original_signals_state): New parameter 'quiet'. Warn if we
13589 find a custom handler preinstalled, instead of internal erroring.
13590 But only warn if !quiet.
13591 * common/signals-state-save-restore.h
13592 (save_original_signals_state): New parameter 'quiet'.
13593 * main.c (captured_main_1): Move save_original_signals_state call
13594 after option handling, and pass QUIET.
13595
13596 2018-01-05 Pedro Alves <palves@redhat.com>
13597
13598 * spu-tdep.c (spu_catch_start): Pass
13599 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
13600
13601 2018-01-05 Pedro Alves <palves@redhat.com>
13602
13603 PR gdb/22670
13604 * ada-lang.c (literal_symbol_name_matcher): New function.
13605 (ada_get_symbol_name_matcher): Use it for
13606 symbol_name_match_type::SEARCH_NAME.
13607 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
13608 it down instead of assuming symbol_name_match_type::FULL.
13609 * block.h (block_lookup_symbol): New parameter 'match_type'.
13610 * c-valprint.c (print_unpacked_pointer): Use
13611 lookup_symbol_search_name instead of lookup_symbol.
13612 * compile/compile-object-load.c (get_out_value_type): Pass down
13613 symbol_name_match_type::SEARCH_NAME.
13614 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
13615 symbol_name_match_type::FULL.
13616 * cp-support.c (cp_get_symbol_name_matcher): Handle
13617 symbol_name_match_type::SEARCH_NAME.
13618 * infrun.c (insert_exception_resume_breakpoint): Use
13619 lookup_symbol_search_name.
13620 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
13621 * psymtab.c (maintenance_check_psymtabs): Use
13622 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
13623 * stack.c (print_frame_args): Use lookup_symbol_search_name and
13624 SYMBOL_SEARCH_NAME.
13625 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
13626 if symbol_name_match_type::SEARCH_NAME.
13627 (lookup_symbol_in_language): Pass down
13628 symbol_name_match_type::FULL.
13629 (lookup_symbol_search_name): New.
13630 (lookup_language_this): Pass down
13631 symbol_name_match_type::SEARCH_NAME.
13632 (lookup_symbol_aux, lookup_local_symbol): New parameter
13633 'match_type'. Pass it down.
13634 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
13635 (lookup_symbol_search_name): New declaration.
13636 (lookup_symbol_in_block): New 'match_type' parameter.
13637
13638 2018-01-05 Pedro Alves <palves@redhat.com>
13639
13640 PR gdb/22670
13641 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
13642 ada_lookup_symbol.
13643 (ada_lookup_symbol): Reimplement in terms of
13644 ada_lookup_symbol_list, bits factored out from
13645 ada_lookup_encoded_symbol.
13646
13647 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13648
13649 * ada-exp.y (write_object_renaming): When subscripting an array
13650 using a symbol as the index, pass the block in call to
13651 ada_lookup_encoded_symbol when looking that symbol up.
13652
13653 2018-01-05 Jerome Guitton <guitton@adacore.com>
13654
13655 * ada-lang.c (ada_array_length): Use ada_index_type instead of
13656 TYPE_INDEX_TYPE.
13657
13658 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13659
13660 * ada-lang.c (ada_to_fixed_value_create): Add handling of
13661 the case where VALUE_LVAL (val0) is not lval_memory.
13662
13663 2018-01-05 Xavier Roirand <roirand@adacore.com>
13664
13665 * ada-valprint.c (print_optional_low_bound): Handle
13666 character-indexed array printing like boolean-indexed array
13667 printing.
13668
13669 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13670
13671 * NEWS: Create a new section for the next release branch.
13672 Rename the section of the current branch, now that it has
13673 been cut.
13674
13675 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13676
13677 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
13678 * version.in: Bump version to 8.1.50.DATE-git.
13679
13680 2018-01-03 Xavier Roirand <roirand@adacore.com>
13681
13682 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
13683 Add field.
13684 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
13685 Add field.
13686 (default_exception_support_info) <catch_handlers_sym>: Add field.
13687 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
13688 (ada_exception_name_addr_1): Add "catch handlers" handling.
13689 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
13690 Update all callers.
13691 (create_excep_cond_exprs) <ex>: Add parameter.
13692 (re_set_exception): Update create_excep_cond_exprs call.
13693 (print_it_exception, print_one_exception, print_mention_exception)
13694 (print_recreate_exception): Add "catch handler" handling.
13695 (allocate_location_catch_handlers, re_set_catch_handlers)
13696 (check_status_catch_handlers, print_it_catch_handlers)
13697 (print_one_catch_handlers, print_mention_catch_handlers)
13698 (print_recreate_catch_handlers): New function.
13699 (catch_handlers_breakpoint_ops): New variable.
13700 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
13701 Add parameter. Add "catch handler" handling.
13702 (ada_exception_sym_name, ada_exception_breakpoint_ops):
13703 Add "catch handler" handling.
13704 (ada_exception_catchpoint_cond_string): Add "catch handler"
13705 handling.
13706 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
13707 call.
13708 (catch_ada_handlers_command): New function.
13709 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
13710 operations structure.
13711 (_initialize_ada_language): Add "catch handlers" command entry.
13712 * NEWS: Document "catch handlers" feature.
13713
13714 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13715
13716 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
13717 account when creating the array type of the slice.
13718 (ada_value_slice): Likewise.
13719
13720 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13721
13722 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
13723 New enum value.
13724 (create_array_type_with_stride): Add byte_stride_prop parameter.
13725 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
13726 New parameter. Update all callers in this file.
13727 (array_type_has_dynamic_stride): New function.
13728 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
13729 of arrays with dynamic byte strides.
13730 * dwarf2read.c (read_array_type): Add support for dynamic
13731 DW_AT_byte_stride attributes.
13732
13733 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13734
13735 * dwarf2read.c (read_unspecified_type): Treat
13736 DW_TAG_enumeration_type DIEs from Ada units as stubs.
13737
13738 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13739
13740 Update copyright year range in all GDB files.
13741
13742 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13743
13744 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
13745 and gdb/testsuite/gdb.base/step-line.c.
13746
13747 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13748
13749 * copyright.py (main): Dump the contents of
13750 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
13751 even if BY_HAND is empty.
13752
13753 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13754
13755 * top.c (print_gdb_version): Update Copyright year in version
13756 message.
13757
13758 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13759
13760 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
13761
13762 For older changes see ChangeLog-2017.
13763 \f
13764 Local Variables:
13765 mode: change-log
13766 left-margin: 8
13767 fill-column: 74
13768 version-control: never
13769 coding: utf-8
13770 End:
This page took 0.529561 seconds and 4 git commands to generate.