Support TLS variables on FreeBSD/amd64.
[external/binutils.git] / gdb / ChangeLog
1 2019-03-12  John Baldwin  <jhb@FreeBSD.org>
2
3         * amd64-fbsd-tdep.c (amd64fbsd_get_thread_local_address): New.
4         (amd64fbsd_init_abi): Install gdbarch
5         "fetch_tls_load_module_address" and "get_thread_local_address"
6         methods.
7
8 2019-03-12  John Baldwin  <jhb@FreeBSD.org>
9
10         * fbsd-tdep.c (fbsd_pspace_data_handle): New variable.
11         (struct fbsd_pspace_data): New type.
12         (get_fbsd_pspace_data, fbsd_pspace_data_cleanup)
13         (fbsd_read_integer_by_name, fbsd_fetch_rtld_offsets)
14         (fbsd_get_tls_index, fbsd_get_thread_local_address): New function.
15         (_initialize_fbsd_tdep): Initialize 'fbsd_pspace_data_handle'.
16         * fbsd-tdep.c (fbsd_get_thread_local_address): New prototype.
17
18 2019-03-12  John Baldwin  <jhb@FreeBSD.org>
19
20         * gdbtypes.c (lookup_struct_elt): New function.
21         (lookup_struct_elt_type): Reimplement via lookup_struct_elt.
22         * gdbtypes.h (struct struct_elt): New type.
23         (lookup_struct_elt): New prototype.
24
25 2019-03-12  John Baldwin  <jhb@FreeBSD.org>
26
27         * gdbtypes.c (lookup_struct_elt_type): Update comment and
28         remove disabled code block.
29
30 2019-03-12  John Baldwin  <jhb@FreeBSD.org>
31
32         * gdbarch.sh (get_thread_local_address): New method.
33         * gdbarch.h, gdbarch.c: Regenerate.
34         * target.c (target_translate_tls_address): Use
35         gdbarch_get_thread_local_address if present instead of
36         target::get_thread_local_address.
37
38 2019-03-12  John Baldwin  <jhb@FreeBSD.org>
39
40         * target.h (target::get_thread_local_address): Update comment.
41
42 2019-03-12  John Baldwin  <jhb@FreeBSD.org>
43
44         * solib-svr4.c (svr4_fetch_objfile_link_map): Look for
45         objfile->separate_debug_objfile_backlink if not NULL.
46
47 2019-03-12  John Baldwin  <jhb@FreeBSD.org>
48
49         * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
50         tdep->fsbase_regnum instead of constants for fs_base and gs_base.
51         (amd64bsd_store_inferior_registers): Likewise.
52         * amd64-fbsd-nat.c (amd64_fbsd_nat_target::read_description):
53         Enable segment base registers.
54         * i386-bsd-nat.c (i386bsd_fetch_inferior_registers): Use
55         PT_GETFSBASE and PT_GETGSBASE.
56         (i386bsd_store_inferior_registers): Use PT_SETFSBASE and
57         PT_SETGSBASE.
58         * i386-fbsd-nat.c (i386_fbsd_nat_target::read_description): Enable
59         segment base registers.
60         * i386-fbsd-tdep.c (i386fbsd_core_read_description): Likewise.
61
62 2019-03-12  John Baldwin  <jhb@FreeBSD.org>
63
64         * amd64-fbsd-nat.c (amd64_fbsd_nat_target::read_description):
65         Update calls to i386_target_description to add 'segments'
66         parameter.
67         * amd64-tdep.c (amd64_init_abi): Set tdep->fsbase_regnum.  Don't
68         add segment base registers.
69         * arch/i386.c (i386_create_target_description): Add 'segments'
70         parameter to enable segment base registers.
71         * arch/i386.h (i386_create_target_description): Likewise.
72         * features/i386/32bit-segments.xml: New file.
73         * features/i386/32bit-segments.c: Generate.
74         * i386-fbsd-nat.c (i386_fbsd_nat_target::read_description): Update
75         call to i386_target_description to add 'segments' parameter.
76         * i386-fbsd-tdep.c (i386fbsd_core_read_description): Likewise.
77         * i386-go32-tdep.c (i386_go32_init_abi): Likewise.
78         * i386-linux-tdep.c (i386_linux_read_description): Likewise.
79         * i386-tdep.c (i386_validate_tdesc_p): Add segment base registers
80         if feature is present.
81         (i386_gdbarch_init): Pass I386_NUM_REGS to set_gdbarch_num_regs.
82         Add 'segments' parameter to call to i386_target_description.
83         (i386_target_description): Add 'segments' parameter to enable
84         segment base registers.
85         (_initialize_i386_tdep) [GDB_SELF_TEST]: Add 'segments' parameter
86         to call to i386_target_description.
87         * i386-tdep.h (struct gdbarch_tdep): Add 'fsbase_regnum'.
88         (enum i386_regnum): Add I386_FSBASE_REGNUM and I386_GSBASE_REGNUM.
89         Define I386_NUM_REGS.
90         (i386_target_description): Add 'segments' parameter to enable
91         segment base registers.
92
93 2019-03-12  Eli Zaretskii  <eliz@gnu.org>
94
95         PR/24325
96         * source-cache.c: #undef open and close, to avoid unresolved
97         externals during linking.
98
99 2019-03-12  Tom Tromey  <tromey@adacore.com>
100
101         * remote.c (magic_null_ptid, not_sent_ptid, any_thread_ptid): Now
102         const.  Add initializers.
103         (_initialize_remote): Don't initialize ptid globals.
104
105 2019-03-12  Pedro Alves  <palves@redhat.com>
106
107         * yy-remap.h [TEST_CPNAMES] (YYFPRINTF): Don't define.
108
109 2019-03-12  Pedro Alves  <palves@redhat.com>
110
111         * cp-name-parser.y (main): Remove unused 'len' variable.
112
113 2019-03-12  Tom Tromey  <tromey@adacore.com>
114
115         * common/ptid.c (null_ptid, minus_one_ptid): Now const.
116         * common/ptid.h (null_ptid, minus_one_ptid): Now const.
117
118 2019-03-12  Tom Tromey  <tromey@adacore.com>
119
120         * linux-nat.c (iterate_over_lwps): Update.
121         (stop_callback): Remove parameter.
122         (stop_wait_callback, detach_callback, resume_set_callback)
123         (select_singlestep_lwp_callback, set_ignore_sigint)
124         (status_callback, resumed_callback, resume_clear_callback)
125         (kill_callback, kill_wait_callback, linux_nat_stop_lwp): Remove
126         data parameter.
127         (linux_nat_target::detach, linux_nat_target::resume)
128         (linux_stop_and_wait_all_lwps, select_event_lwp)
129         (linux_nat_filter_event, linux_nat_wait_1)
130         (linux_nat_target::kill, linux_nat_target::stop)
131         (linux_nat_target::stop): Update.
132         (linux_nat_resume_callback): Change type.
133         (resume_stopped_resumed_lwps, count_events_callback)
134         (select_event_lwp_callback): Likewise.
135         (linux_stop_lwp, linux_nat_stop_lwp): Update.
136         * arm-linux-nat.c (struct update_registers_data): Remove.
137         (update_registers_callback): Change type.
138         (arm_linux_insert_hw_breakpoint1): Update.
139         * nat/x86-linux-dregs.c (update_debug_registers_callback): Remove
140         parameter.
141         (x86_linux_dr_set_addr): Update.
142         (x86_linux_dr_set_control): Update.
143         * nat/linux-nat.h (iterate_over_lwps_ftype): Remove parameter.
144         (iterate_over_lwps): Use gdb::function_view.
145         * nat/aarch64-linux-hw-point.c (struct
146         aarch64_dr_update_callback_param): Remove.
147         (debug_reg_change_callback): Change type.
148         (aarch64_notify_debug_reg_change): Update.
149         * s390-linux-nat.c (s390_refresh_per_info): Update.
150
151 2019-03-11  Tom Tromey  <tromey@adacore.com>
152
153         * dwarf2read.c (dwarf2_find_containing_comp_unit): Remove
154         redundant assignment to "this_cu".
155
156 2019-03-08  Simon Marchi  <simon.marchi@efficios.com>
157
158         * gdbtypes.c (rank_one_type): Remove unnecessary cases from switch.
159
160 2019-03-08  Simon Marchi  <simon.marchi@efficios.com>
161
162         * gdbtypes.c (rank_one_type_parm_set): New function extracted
163         from...
164         (rank_one_type): ... this.
165
166 2019-03-08  Simon Marchi  <simon.marchi@efficios.com>
167
168         * gdbtypes.c (rank_one_type_parm_struct): New function extracted
169         from...
170         (rank_one_type): ... this.
171
172 2019-03-08  Simon Marchi  <simon.marchi@efficios.com>
173
174         * gdbtypes.c (rank_one_type_parm_complex): New function extracted
175         from...
176         (rank_one_type): ... this.
177
178 2019-03-08  Simon Marchi  <simon.marchi@efficios.com>
179
180         * gdbtypes.c (rank_one_type_parm_float): New function extracted
181         from...
182         (rank_one_type): ... this.
183
184 2019-03-08  Simon Marchi  <simon.marchi@efficios.com>
185
186         * gdbtypes.c (rank_one_type_parm_bool): New function extracted
187         from...
188         (rank_one_type): ... this.
189
190 2019-03-08  Simon Marchi  <simon.marchi@efficios.com>
191
192         * gdbtypes.c (rank_one_type_parm_range): New function extracted
193         from...
194         (rank_one_type): ... this.
195
196 2019-03-08  Simon Marchi  <simon.marchi@efficios.com>
197
198         * gdbtypes.c (rank_one_type_parm_char): New function extracted
199         from...
200         (rank_one_type): ... this.
201
202 2019-03-08  Simon Marchi  <simon.marchi@efficios.com>
203
204         * gdbtypes.c (rank_one_type_parm_enum): New function extracted
205         from...
206         (rank_one_type): ... this.
207
208 2019-03-08  Simon Marchi  <simon.marchi@efficios.com>
209
210         * gdbtypes.c (rank_one_type_parm_int): New function extracted
211         from...
212         (rank_one_type): ... this.
213
214 2019-03-08  Simon Marchi  <simon.marchi@efficios.com>
215
216         * gdbtypes.c (rank_one_type_parm_func): New function extracted
217         from...
218         (rank_one_type): ... this.
219
220 2019-03-08  Simon Marchi  <simon.marchi@efficios.com>
221
222         * gdbtypes.c (rank_one_type_parm_array): New function extracted
223         from...
224         (rank_one_type): ... this.
225
226 2019-03-08  Simon Marchi  <simon.marchi@efficios.com>
227
228         * gdbtypes.c (rank_one_type_parm_ptr): New function extracted
229         from...
230         (rank_one_type): ... this.
231
232 2019-02-27  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
233
234         * inferior.c (initialize_inferiors): Ensure 'help set/show print
235         inferior-events' shows the example events.
236
237 2019-03-08  Eli Zaretskii  <eliz@gnu.org>
238
239         Support styling on native MS-Windows console
240
241         PR/24315
242         * utils.c (can_emit_style_escape) [_WIN32]: Don't disable styling
243         on MS-Windows if $TERM is not defined.
244
245         * cli/cli-style.c: Set cli_styling to 1 in the MinGW build.
246
247         * posix-hdep.c (gdb_console_fputs):
248         * mingw-hdep.c (rgb_to_16colors, gdb_console_fputs): New
249         functions.
250         * ui-file.h (gdb_console_fputs): Add prototype.
251
252         * ui-file.c (stdio_file::puts): Call gdb_console_fputs, and fall
253         back to fputs only if the former returns zero.
254
255 2019-03-07  Tom Tromey  <tom@tromey.com>
256
257         * symmisc.c (print_symbol_bcache_statistics): Update.
258         (print_objfile_statistics): Update.
259         * symfile.c (allocate_symtab): Update.
260         * stabsread.c: Don't include bcache.h.
261         * psymtab.h (struct psymbol_bcache): Don't declare.
262         (class psymtab_storage) <psymbol_cache>: Now a bcache.
263         (psymbol_bcache_init, psymbol_bcache_free)
264         (psymbol_bcache_get_bcache): Don't declare.
265         * psymtab.c (struct psymbol_bcache): Remove.
266         (psymtab_storage::psymtab_storage): Update.
267         (psymtab_storage::~psymtab_storage): Update.
268         (psymbol_bcache_init, psymbol_bcache_free)
269         (psymbol_bcache_get_bcache, psymbol_bcache_full): Remove.
270         (add_psymbol_to_bcache): Update.
271         (allocate_psymtab): Update.
272         * objfiles.h (struct objfile_per_bfd_storage) <filename_cache,
273         macro_cache>: No longer pointers.
274         * objfiles.c (get_objfile_bfd_data): Don't call bcache_xmalloc.
275         (free_objfile_per_bfd_storage): Don't call bcache_xfree.
276         * macrotab.c (macro_bcache): Update.
277         * macroexp.c: Don't include bcache.h.
278         * gdbtypes.c (check_types_worklist): Update.
279         (types_deeply_equal): Remove TRY/CATCH.  Update.
280         * elfread.c (elf_symtab_read): Update.
281         * dwarf2read.c: Don't include bcache.h.
282         * buildsym.c (buildsym_compunit::get_macro_table): Update.
283         * bcache.h (bcache, bcache_full, bcache_xffree, bcache_xmalloc)
284         (print_bcache_statistics, bcache_memory_used): Don't declare.
285         (struct bcache): Move from bcache.c.  Add constructor, destructor,
286         methods.  Rename all data members.
287         * bcache.c (struct bcache): Move to bcache.h.
288         (bcache::expand_hash_table): Rename from expand_hash_table.
289         (bcache): Remove.
290         (bcache::insert): Rename from bcache_full.
291         (bcache::compare): Rename from bcache_compare.
292         (bcache_xmalloc): Remove.
293         (bcache::~bcache): Rename from bcache_xfree.
294         (bcache::print_statistics): Rename from print_bcache_statistics.
295         (bcache::memory_used): Rename from bcache_memory_used.
296
297 2019-03-07  Pedro Alves  <palves@redhat.com>
298
299         * infrun.c (normal_stop): Also check for
300         TARGET_WAITKIND_NO_RESUMED before referring to inferior_thread().
301
302 2019-03-07  Andrew Burgess  <andrew.burgess@embecosm.com>
303
304         * f-lang.c (value_from_host_double): Moved to...
305         * value.c (value_from_host_double): ...here.
306         * value.h (value_from_host_double): Declare.
307         * guile/scm-math.c (vlscm_convert_typed_number): Use
308         value_from_host_double.
309         (vlscm_convert_number): Likewise.
310         * guile/scm-value.c (gdbscm_value_to_real): Likewise.
311         * python/py-value.c (convert_value_from_python): Likewise.
312
313 2019-03-06  Tom Tromey  <tom@tromey.com>
314
315         * gcore.c (write_gcore_file): Use SCOPE_EXIT.
316
317 2019-03-06  Tom Tromey  <tom@tromey.com>
318
319         * utils.h (free_current_contents): Don't declare.
320         * utils.c (free_current_contents): Remove.
321
322 2019-03-06  Tom Tromey  <tom@tromey.com>
323
324         * top.c (quit_force): Update.
325         * main.c (captured_command_loop): Update.
326         * common/new-op.c (operator new): Update.
327         * common/common-exceptions.c (struct catcher)
328         <save_cleanup_chain>: Remove member.
329         (exceptions_state_mc_init): Update.
330         (exception_try_scope_entry): Return nullptr.
331         (exception_try_scope_exit, exception_rethrow)
332         (throw_exception_sjlj, throw_exception_cxx): Update.
333         * common/cleanups.h (make_cleanup, make_cleanup_dtor)
334         (all_cleanups, do_cleanups, discard_cleanups)
335         (discard_final_cleanups, save_cleanups, save_final_cleanups)
336         (restore_cleanups, restore_final_cleanups): Don't declare.
337         (do_final_cleanups): Remove parameter.
338         * common/cleanups.c (cleanup_chain, make_cleanup)
339         (make_cleanup_dtor, all_cleanups, do_cleanups)
340         (discard_my_cleanups, discard_cleanups)
341         (discard_final_cleanups, save_my_cleanups, save_cleanups)
342         (save_final_cleanups, restore_my_cleanups, restore_cleanups)
343         (null_cleanup): Remove.
344         (do_final_cleanups): Remove parameter.
345
346 2019-03-06  Tom Tromey  <tom@tromey.com>
347
348         * remote.c (remote_target::remote_parse_stop_reply): Use
349         unique_xmalloc_ptr.
350
351 2019-03-06  Tom Tromey  <tom@tromey.com>
352
353         * stabsread.c (struct stabs_field_info): Rename from field_info.
354         <list, fnlist>: Add initializers.
355         <obstack>: New member.
356         (read_member_functions, read_struct_fields, read_baseclasses):
357         Allocate on obstack.  Don't use cleanups.
358         (read_one_struct_field, read_member_functions, read_struct_fields)
359         (read_baseclasses, read_tilde_fields, attach_fn_fields_to_type)
360         (attach_fields_to_type, read_cpp_abbrev, read_member_functions)
361         (read_struct_type): Update.
362
363 2019-03-06  Tom Tromey  <tom@tromey.com>
364
365         * nat/linux-namespaces.c (linux_mntns_access_fs): Use SCOPE_EXIT.
366         * common/filestuff.h (make_cleanup_close): Don't declare.
367         * common/filestuff.c (do_close_cleanup, make_cleanup_close):
368         Remove.
369
370 2019-03-06  Tom Tromey  <tom@tromey.com>
371
372         * solib-aix.c: Use make_scope_exit.
373
374 2019-03-06  Tom Tromey  <tom@tromey.com>
375
376         * solib-svr4.c (svr4_parse_libraries, svr4_current_sos_direct):
377         Use make_scope_exit.
378
379 2019-03-06  Tom Tromey  <tom@tromey.com>
380
381         * solib-svr4.c (disable_probes_interface): Remove parameter.
382         (svr4_handle_solib_event): Use make_scope_exit.
383
384 2019-03-06  Tom Tromey  <tom@tromey.com>
385
386         * remote.c (struct stop_reply_deleter): Remove.
387         (stop_reply_up): Update.
388         (struct stop_reply): Derive from notif_event.  Don't typedef.
389         <regcache>: Now a std::vector.
390         (stop_reply_xfree): Remove.
391         (stop_reply::~stop_reply): Rename from stop_reply_dtr.
392         (remote_notif_stop_alloc_reply): Return a unique_ptr.  Use new.
393         (remote_target::discard_pending_stop_replies): Use delete.
394         (remote_target::remote_parse_stop_reply): Update.
395         (remote_target::process_stop_reply): Update.
396         * remote-notif.h (struct notif_event): Add virtual destructor.
397         Remove "dtr" member.
398         (struct notif_client) <alloc_event>: Return a unique_ptr.
399         (notif_event_xfree): Don't declare.
400         (notif_event_up): New typedef.
401         * remote-notif.c (remote_notif_ack, remote_notif_parse): Update.
402         (notif_event_xfree, do_notif_event_xfree): Remove.
403         (remote_notif_state_xfree): Update.
404
405 2019-03-06  Tom Tromey  <tom@tromey.com>
406
407         * infrun.c (displaced_step_clear_cleanup): Now a
408         forward_scope_exit type.
409         (displaced_step_prepare_throw): Update.
410         (displaced_step_fixup): Update.
411
412 2019-03-06  Tom Tromey  <tom@tromey.com>
413
414         * inferior.h (class inferior): Update comment.
415         * gdbthread.h (class thread_info): Update comment.
416
417 2019-03-06  Joel Brobecker  <brobecker@adacore.com>
418             Tom Tromey  <tom@tromey.com>
419
420         * stabsread.h (struct stab_section_list): Remove.
421         (coffstab_build_psymtabs): Update.
422         * dbxread.c (symbuf_sections): Now a std::vector.
423         (sect_idx): New global.
424         (fill_symbuf): Update.
425         (coffstab_build_psymtabs): Change type of stabsects parameter.
426         Update.
427         * coffread.c (struct coff_symfile_info) <stabsects>: Now a
428         std::vector.
429         (linetab, linetab_offset, linetab_size, stringtab): Move earlier.
430         (coff_locate_sections): Update.
431         (coff_symfile_read): Remove cleanups.  Update.
432         (init_stringtab): Add storage parameter.
433         (free_stringtab, free_stringtab_cleanup): Remove.
434         (init_lineno): Add storage parameter.
435         (free_linetab, free_linetab_cleanup): Remove.
436
437 2019-03-06  Pedro Alves  <palves@redhat.com>
438
439         * linux-fork.c (fork_info::clobber_regs): Delete.
440         (fork_load_infrun_state): Remove reference to 'clobber_regs'.
441         (fork_save_infrun_state): Remove 'clobber_regs' parameter.  Update
442         comment.  Adjust.
443         (scoped_switch_fork_info::scoped_switch_fork_info)
444         (checkpoint_command, linux_fork_context): Adjust
445         fork_save_infrun_state calls.
446
447 2019-03-06  Pedro Alves  <palves@redhat.com>
448
449         * linux-fork.c (inf_has_multiple_thread_cb): Delete.
450         (inf_has_multiple_threads): Return 'bool' and rewrite using
451         inferior_info::threads().
452
453 2019-03-06  Pedro Alves  <palves@redhat.com>
454
455         * linux-fork.c: Include <list>.
456         (fork_list): Now a std::list instance.
457         (fork_info): Add ctor, dtor, and in-class initialize all fields.
458         (forks_exist_p, find_last_fork): Adjust.
459         (new_fork): Delete.
460         (one_fork_p): New.
461         (add_fork): Adjust.
462         (free_fork): Delete, folded into fork_info::~fork_info().
463         (delete_fork, find_fork_ptid, find_fork_id, find_fork_pid):
464         Adjust.
465         (init_fork_list): Delete.
466         (linux_fork_killall, linux_fork_mourn_inferior)
467         (linux_fork_detach, info_checkpoints_command): Adjust.
468         (_initialize_linux_fork): No longer call init_fork_list.
469
470 2019-03-06  Pedro Alves  <palves@redhat.com>
471
472         * linux-fork.c (new_fork): New, split out of ...
473         (add_fork): ... this.  Return void.  Move "first fork" special
474         case from here, to ...
475         (checkpoint_command): ... here.
476         * linux-linux.h (add_fork): Return void.
477
478 2019-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
479
480         * f-exp.y (direct_abs_decl): Handle TYPE*SIZE type names.
481
482 2019-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
483             Chris January  <chris.january@arm.com>
484             David Lecomber  <david.lecomber@arm.com>
485
486         * f-exp.y: New token, UNOP_INTRINSIC.
487         (exp): New pattern using UNOP_INTRINSIC token.
488         (f77_keywords): Add 'abs' keyword.
489         * f-lang.c: Add 'target-float.h' and 'math.h' includes.
490         (value_from_host_double): New function.
491         (evaluate_subexp_f): Support UNOP_ABS.
492
493 2019-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
494
495         * f-lang.c (build_fortran_types): Use TYPE_CODE_CHAR for character
496         types.
497
498 2019-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
499
500         * f-exp.y (convert_to_kind_type): Handle integer (kind=8).
501         * f-lang.c (build_fortran_types): Setup builtin_integer_s8.
502         * f-lang.h (struct builtin_f_type): Add builtin_integer_s8 field.
503
504 2019-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
505
506         * f-exp.y (convert_to_kind_type): Handle more type kinds.
507
508 2019-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
509             Chris January  <chris.january@arm.com>
510
511         * expprint.c (dump_subexp_body_standard): Support UNOP_KIND.
512         * f-exp.y: Define 'KIND' token.
513         (exp): New pattern for KIND expressions.
514         (ptype): Handle types with a kind extension.
515         (direct_abs_decl): Extend to spot kind extensions.
516         (f77_keywords): Add 'kind' to the list.
517         (push_kind_type): New function.
518         (convert_to_kind_type): New function.
519         * f-lang.c (evaluate_subexp_f): Support UNOP_KIND.
520         * parse.c (operator_length_standard): Likewise.
521         * parser-defs.h (enum type_pieces): Add tp_kind.
522         * std-operator.def: Add UNOP_KIND.
523
524 2019-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
525
526         * f-exp.y (f_parse): Set yydebug.
527
528 2019-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
529
530         * f-lang.c (evaluate_subexp_f): New function.
531         (exp_descriptor_f): New global.
532         (f_language_defn): Use exp_descriptor_f instead of
533         exp_descriptor_standard.
534
535 2019-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
536
537         * f-exp.y (struct token): Add comments.
538         (dot_ops): Remove uppercase versions and the end marker.
539         (f77_keywords): Likewise.
540         (yylex): Use ARRAY_SIZE to iterate over dot_ops, assert all
541         entries in the dot_ops array are case insensitive, and use
542         strncasecmp to compare strings.  Also some whitespace cleanup in
543         this area.  Similar for the f77_keywords array, except entries in
544         this list might be case sensitive.
545
546 2019-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
547
548         * f-exp.y (struct f77_boolean_val): Add comments.
549         (boolean_values): Remove uppercase versions, and end marker.
550         (yylex): Use ARRAY_SIZE for iterating over boolean_values array,
551         and use strncasecmp to achieve case insensitivity.  Additionally,
552         perform whitespace cleanup around this code.
553
554 2019-03-06  Tom Tromey  <tromey@adacore.com>
555
556         * remote-sim.c (gdbsim_target_open): Use result of
557         gdb_argv::release.
558
559 2019-03-06  Richard Bunt  <richard.bunt@arm.com>
560         Dirk Schubert  <dirk.schubert@arm.com>
561         Chris January  <chris.january@arm.com>
562
563         * eval.c (evaluate_subexp_standard): Call Fortran argument
564         wrapping logic.
565         * f-lang.c (struct value): A value which can be passed into a
566         Fortran function call.
567         (fortran_argument_convert): Wrap Fortran arguments in a pointer
568         where appropriate.
569         (struct type): Value ready for a Fortran function call.
570         (fortran_preserve_arg_pointer): Undo check_typedef, the pointer
571         is needed.
572         * f-lang.h (fortran_argument_convert): Declaration.
573         (fortran_preserve_arg_pointer): Declaration.
574         * infcall.c (value_arg_coerce): Call Fortran argument logic.
575
576 2019-03-05  Tom Tromey  <tromey@adacore.com>
577
578         * python/py-prettyprint.c (print_string_repr): Remove #if.
579         * python/py-utils.c (unicode_to_encoded_string): Remove #if.
580
581 2019-03-05  Tom Tromey  <tromey@adacore.com>
582
583         * target.c (the_dummy_target): Move later.  Change type to
584         "dummy_target".
585         (initialize_targets): Don't initialize the_dummy_target.
586
587 2019-03-05  Tom Tromey  <tromey@adacore.com>
588
589         * gdb_bfd.c (gdb_bfd_fdopenr): Remove.
590         * gdb_bfd.h (gdb_bfd_fdopenr): Don't declare.
591
592 2019-03-05  Tom Tromey  <tromey@adacore.com>
593
594         * windows-nat.c (windows_nat_target::attach)
595         (windows_nat_target::detach): Don't call gdb_flush.
596         * valprint.c (generic_val_print, val_print, val_print_string):
597         Don't call gdb_flush.
598         * utils.c (defaulted_query): Don't call gdb_flush.
599         * typeprint.c (print_type_scalar): Don't call gdb_flush.
600         * target.c (target_announce_detach): Don't call gdb_flush.
601         * sparc64-tdep.c (adi_print_versions): Don't call gdb_flush.
602         * remote.c (extended_remote_target::attach): Don't call
603         gdb_flush.
604         * procfs.c (procfs_target::detach): Don't call gdb_flush.
605         * printcmd.c (do_examine): Don't call gdb_flush.
606         (info_display_command): Don't call gdb_flush.
607         * p-valprint.c (pascal_val_print): Don't call gdb_flush.
608         * nto-procfs.c (nto_procfs_target::attach): Don't call gdb_flush.
609         * memattr.c (info_mem_command): Don't call gdb_flush.
610         * mdebugread.c (mdebug_build_psymtabs): Don't call gdb_flush.
611         * m2-valprint.c (m2_val_print): Don't call gdb_flush.
612         * infrun.c (follow_exec, handle_command): Don't call gdb_flush.
613         * inf-ptrace.c (inf_ptrace_target::attach): Don't call gdb_flush.
614         * hppa-tdep.c (unwind_command): Don't call gdb_flush.
615         * gnu-nat.c (gnu_nat_target::attach): Don't call gdb_flush.
616         (gnu_nat_target::detach): Don't call gdb_flush.
617         * f-valprint.c (f_val_print): Don't call gdb_flush.
618         * darwin-nat.c (darwin_nat_target::attach): Don't call gdb_flush.
619         * cli/cli-script.c (read_command_lines): Don't call gdb_flush.
620         * cli/cli-cmds.c (shell_escape, print_disassembly): Don't call
621         gdb_flush.
622         * c-valprint.c (c_val_print): Don't call gdb_flush.
623         * ada-valprint.c (ada_print_scalar): Don't call gdb_flush.
624
625 2019-03-05  Tom Tromey  <tromey@adacore.com>
626
627         * varobj.c (update_dynamic_varobj_children): Update.
628         (install_default_visualizer): Use reset, not release.
629         * value.c (set_internalvar): Update.
630         * dwarf2loc.c (value_of_dwarf_reg_entry): Update.
631         * common/gdb_ref_ptr.h (class ref_ptr) <release>: Add
632         ATTRIBUTE_UNUSED_RESULT.
633
634 2019-03-05  Tom Tromey  <tromey@adacore.com>
635
636         * remote.c (class scoped_remote_fd) <release>: Add
637         ATTRIBUTE_UNUSED_RESULT.
638
639 2019-03-05  Tom Tromey  <tromey@adacore.com>
640
641         * macroexp.c (struct macro_buffer) <release>: Add
642         ATTRIBUTE_UNUSED_RESULT.
643
644 2019-03-05  Tom Tromey  <tromey@adacore.com>
645
646         * nat/linux-btrace.c (linux_enable_bts, linux_enable_pt): Update.
647         * common/scoped_mmap.h (class scoped_mmap) <release>: Add
648         ATTRIBUTE_UNUSED_RESULT.
649
650 2019-03-05  Tom Tromey  <tromey@adacore.com>
651
652         * common/scoped_fd.h (class scoped_fd) <release>: Add
653         ATTRIBUTE_UNUSED_RESULT.
654
655 2019-03-05  Tom Tromey  <tromey@adacore.com>
656
657         * parser-defs.h (struct parser_state) <release>: Add
658         ATTRIBUTE_UNUSED_RESULT.
659
660 2019-03-05  Tom Tromey  <tromey@adacore.com>
661
662         * utils.h (class gdb_argv) <release>: Add
663         ATTRIBUTE_UNUSED_RESULT.
664         * common/common-defs.h (ATTRIBUTE_UNUSED_RESULT): Define.
665
666 2019-03-02  Eli Zaretskii  <eliz@gnu.org>
667
668         * xml-syscall.c (xml_list_syscalls_by_group): Drop 'struct' from
669         for-loop range, to avoid compiler warnings.
670
671         * tui/tui.c (tui_enable) [__MINGW32__]: Don't declare 'cap', to
672         avoid compiler warnings about unused variables.
673
674         * NEWS: Mention end of support for native debugging on MS-Windows
675         before XP.
676
677         PR gdb/24292
678         * common/netstuff.c:
679         * gdbserver/gdbreplay.c
680         * gdbserver/remote-utils.c:
681         * ser-tcp.c:
682         * unittests/parse-connection-spec-selftests.c [USE_WIN32API]:
683         Include ws2tcpip.h instead of wsiapi.h and winsock2.h.  Redefine
684         _WIN32_WINNT to 0x0501 if defined to a smaller value, as
685         'getaddrinfo' and 'freeaddrinfo' were not available before
686         Windows XP, and mingw.org's MinGW headers by default define
687         _WIN32_WINNT to 0x500.
688
689 2019-03-01  Gary Benson <gbenson@redhat.com>
690
691         * coffread.c (coff_start_symtab): Remove unnecessary xstrdup.
692
693 2019-02-28  Brian Vandenberg  <phantall@gmail.com>
694             Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
695
696         PR gdb/8527
697         * procfs.c (proc_wait_for_stop): Wrap write of PCWSTOP in
698         set_sigint_trap, clear_sigint_trap.
699
700 2019-02-27  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
701
702         * target.c (target_detach): Clear the regcache and the
703         frame cache.
704
705 2019-02-27  Pedro Alves  <palves@redhat.com>
706
707         * utils.c (set_screen_size): When we cap the height/width sizes,
708         tweak the corresponding command variable to show "unlimited":
709
710 2019-02-27  Saagar Jha  <saagar@saagarjha.com>
711             Pedro Alves  <palves@redhat.com>
712
713         * utils.c (set_screen_size): Reduce "infinite" rows and columns
714         before calling rl_set_screen_size.
715
716 2019-02-27  Tom Tromey  <tromey@adacore.com>
717
718         * configure.ac (HAVE_LIBPYTHON2_4, HAVE_LIBPYTHON2_5): Never
719         define.
720         * python/py-value.c: Remove Python 2.4 workaround.
721         * python/py-utils.c (gdb_pymodule_addobject): Remove Python 2.4
722         workaround.
723         * python/py-type.c (convert_field, gdbpy_initialize_types): Remove
724         Python 2.4 workaround.
725         * python/python-internal.h: Remove Python 2.4 comment.
726         (Py_ssize_t): Don't define.
727         (PyVarObject_HEAD_INIT, Py_TYPE): Don't define.
728         (gdb_Py_DECREF): Remove Python 2.4 workaround.
729         (gdb_PyObject_GetAttrString, PyObject_GetAttrString): Remove.
730         (gdb_PyObject_HasAttrString, PyObject_HasAttrString): Remove.
731         * python/python.c (do_start_initialization): Remove Python 2.4
732         workaround.
733         * python/py-prettyprint.c (class dummy_python_frame): Remove.
734         (print_children): Remove Python 2.4 workaround.
735         * python/py-inferior.c (buffer_procs): Remove Python 2.4
736         workaround.
737         (CHARBUFFERPROC_NAME): Remove.
738         * python/py-breakpoint.c (gdbpy_initialize_breakpoints): Remove
739         Python 2.4 workaround.
740
741 2019-02-27  Kevin Buettner  <kevinb@redhat.com>
742
743         * NEWS: Note minimum Python version.
744
745 2019-02-27  Kevin Buettner  <kevinb@redhat.com>
746
747         * python/py-inferior.c (infpy_write_memory): Remove non-IS_PY3K
748         code from these functions.  Remove corresponding ifdefs.  Use
749         Py_buffer_up instead of explicit calls to PyBuffer_Release.
750         Remove gotos and target of gotos.
751         (infpy_search_memory): Likewise.
752
753 2019-02-27  Andrew Burgess  <andrew.burgess@embecosm.com>
754
755         * gdb/hppa-tdep.c (hppa_dummy_id): Delete.
756         (hppa_gdbarch_init): Don't register deleted functions with
757         gdbarch.
758
759 2019-02-27  Andrew Burgess  <andrew.burgess@embecosm.com>
760
761         * gdb/h8300-tdep.c (h8300_unwind_pc): Delete.
762         (h8300_unwind_sp): Delete.
763         (h8300_dummy_id): Delete.
764         (h8300_gdbarch_init): Don't register deleted functions with
765         gdbarch.
766
767 2019-02-27  Andrew Burgess  <andrew.burgess@embecosm.com>
768
769         * gdb/ft32-tdep.c (ft32_dummy_id): Delete.
770         (ft32_unwind_pc): Delete.
771         (ft32_unwind_sp): Delete.
772         (ft32_gdbarch_init): Don't register deleted functions with
773         gdbarch.
774
775 2019-02-27  Andrew Burgess  <andrew.burgess@embecosm.com>
776
777         * gdb/frv-tdep.c (frv_dummy_id): Delete.
778         (frv_unwind_pc): Delete.
779         (frv_unwind_sp): Delete.
780         (frv_gdbarch_init): Don't register deleted functions with
781         gdbarch.
782
783 2019-02-27  Andrew Burgess  <andrew.burgess@embecosm.com>
784
785         * gdb/riscv-tdep.c (riscv_dummy_id): Delete.
786         (riscv_unwind_pc): Delete.
787         (riscv_unwind_sp): Delete.
788         (riscv_gdbarch_init): Don't register deleted functions with
789         gdbarch.
790
791 2019-02-27  Andrew Burgess  <andrew.burgess@embecosm.com>
792
793         * gdb/csky-tdep.c (csky_dummy_id): Delete.
794         (csky_unwind_pc): Delete.
795         (csky_unwind_sp): Delete.
796         (csky_gdbarch_init): Don't register deleted functions with
797         gdbarch.
798
799 2019-02-27  Andrew Burgess  <andrew.burgess@embecosm.com>
800
801         * gdb/cris-tdep.c (cris_dummy_id): Delete.
802         (cris_unwind_pc): Delete.
803         (cris_unwind_sp): Delete.
804         (cris_gdbarch_init): Don't register deleted functions with
805         gdbarch.
806
807 2019-02-27  Andrew Burgess  <andrew.burgess@embecosm.com>
808
809         * gdb/bfin-tdep.c (bfin_dummy_id): Delete.
810         (bfin_unwind_pc): Delete.
811         (bfin_gdbarch_init): Don't register deleted functions with gdbarch.
812
813 2019-02-27  Andrew Burgess  <andrew.burgess@embecosm.com>
814
815         * gdb/arm-tdep.c (arm_dummy_id): Delete.
816         (arm_unwind_pc): Delete.
817         (arm_unwind_sp): Delete.
818         (arm_gdbarch_init): Don't register deleted functions with gdbarch.
819
820 2019-02-27  Andrew Burgess  <andrew.burgess@embecosm.com>
821
822         * gdb/arc-tdep.c (arc_dummy_id): Delete.
823         (arc_unwind_pc): Delete.
824         (arc_unwind_sp): Delete.
825         (arc_gdbarch_init): Don't register deleted functions with gdbarch.
826
827 2019-02-27  Andrew Burgess  <andrew.burgess@embecosm.com>
828
829         * gdb/alpha-tdep.c (alpha_dummy_id): Delete.
830         (alpha_unwind_pc): Delete.
831         (alpha_gdbarch_init): Don't register deleted functions with
832         gdbarch.
833
834 2019-02-27  Andrew Burgess  <andrew.burgess@embecosm.com>
835
836         * gdb/aarch64-tdep.c (aarch64_dummy_id): Delete.
837         (aarch64_unwind_pc): Delete.
838         (aarch64_unwind_sp): Delete.
839         (aarch64_gdbarch_init): Don't register deleted functions with
840         gdbarch.
841
842 2019-02-27  Andrew Burgess  <andrew.burgess@embecosm.com>
843
844         * gdbtypes.c (type_align): Don't consider static members when
845         computing structure alignment.
846
847 2019-02-27  Andrew Burgess  <andrew.burgess@embecosm.com>
848
849         * arc-tdep.c (arc_type_align): Provide alignment for basic types,
850         return 0 for other types.
851         * arch-utils.c (default_type_align): Always return 0.
852         * gdbarch.h: Regenerate.
853         * gdbarch.sh (type_align): Extend comment.
854         * gdbtypes.c (type_align): Add additional comments, always call
855         gdbarch_type_align before applying the default rules.
856         * i386-tdep.c (i386_type_align): Return 0 as the default rule,
857         generic code will then apply a suitable default.
858         * nios2-tdep.c (nios2_type_align): Provide alignment for basic
859         types, return 0 for other types.
860
861 2019-02-27  Joel Brobecker  <brobecker@adacore.com>
862
863         * NEWS: Create a new section for the next release branch.
864         Rename the section of the current branch, now that it has
865         been cut.
866
867 2019-02-27  Joel Brobecker  <brobecker@adacore.com>
868
869         GDB 8.3 branch created (143420fb0d5ae54323ba9953f0818c194635228d):
870         * version.in: Bump version to 8.3.50.DATE-git.
871
872 2019-02-26  Simon Marchi  <simon.marchi@efficios.com>
873
874         * aix-thread.c (ptid_cmp): Remove unused variable.
875         (get_signaled_thread): Likewise.
876         (store_regs_user_thread): Likewise.
877         (store_regs_kernel_thread): Likewise.
878         (fetch_regs_kernel_thread): Remove shadowed variable.
879
880 2019-02-26  Andrew Burgess  <andrew.burgess@embecosm.com>
881
882         * features/riscv/32bit-cpu.xml: Add register numbers.
883         * features/riscv/32bit-fpu.c: Regenerate.
884         * features/riscv/32bit-fpu.xml: Add register numbers.
885         * features/riscv/64bit-cpu.xml: Add register numbers.
886         * features/riscv/64bit-fpu.c: Regenerate.
887         * features/riscv/64bit-fpu.xml: Add register numbers.
888
889 2019-02-26  Kevin Buettner  <kevinb@redhat.com>
890
891         * NEWS: Mention two argument form of gdb.Value constructor.
892         * python/py-value.c (convert_buffer_and_type_to_value): New
893         function.
894         (valpy_new): Parse arguments via gdb_PyArg_ParseTupleAndKeywords.
895         Add support for handling an optional second argument.  Call
896         convert_buffer_and_type_to_value as appropriate.
897         * python/python-internal.h (Py_buffer_deleter): New struct.
898         (Py_buffer_up): New typedef.
899
900 2019-02-25  John Baldwin  <jhb@FreeBSD.org>
901
902         * dwarf2read.c (dwarf2_get_dwz_file): Reset dwz_bfd to nullptr
903         instead of releasing ownership.
904
905 2019-02-25  Jordan Rupprecht  <rupprecht@google.com>
906
907         * dwarf2read.c (open_and_init_dwp_file): Call
908         elf_numsections instead of bfd_count_sections to initialize
909         dwp_file->num_sections.
910
911 2019-02-25  Tom Tromey  <tromey@adacore.com>
912
913         * solib-darwin.c (darwin_get_dyld_bfd): Don't release dyld_bfd.
914
915 2019-02-23  Sergio Durigan Junior  <sergiodj@redhat.com>
916
917         * gcore.in: Add '--readnever' option when invoking GDB.
918
919 2019-02-22  Simon Marchi  <simon.marchi@polymtl.ca>
920
921         * MAINTAINERS: Update my email address.
922
923 2019-02-22  Simon Marchi  <simon.marchi@polymtl.ca>
924
925         * build-id.c (build_id_to_debug_bfd_1): New function.
926         (build_id_to_debug_bfd): Look for separate debug file in
927         sysroot.
928
929 2019-02-22  Andrew Burgess  <andrew.burgess@embecosm.com>
930
931         * gdbarch.sh: Update the copyright year range that is placed into
932         generated files.
933
934 2019-02-22  Keith Seitz  <keiths@redhat.com>
935
936         PR symtab/23853
937         * linespec.c (create_sals_line_offset): Search for the default
938         symtab's filename instead of its fullname.
939
940 2019-02-21  Alan Hayward  <alan.hayward@arm.com>
941
942         * NEWS: Update style defaults.
943
944 2019-02-21  Alan Hayward  <alan.hayward@arm.com>
945
946         * main.c (captured_main_1): Disable styling in batch mode.
947
948 2019-02-20  Tom Tromey  <tom@tromey.com>
949
950         * symtab.c (symtab_symbol_info): Fix typos.
951
952 2019-02-20  Tom Tromey  <tromey@adacore.com>
953
954         * findcmd.c (_initialize_mem_search): Use upper case for
955         metasyntactic variables.
956
957 2019-02-20  Alan Hayward  <alan.hayward@arm.com>
958
959         * aarch64-tdep.c (aarch64_add_reggroups): New function.
960         (aarch64_gdbarch_init): Call aarch64_add_reggroups.
961
962 2019-02-19  Simon Marchi  <simon.marchi@polymtl.ca>
963
964         * top.h (source_file_name): Change to std::string.
965         * top.c (source_file_name): Likewise.
966         (command_line_input): Adjust.
967         * cli/cli-script.c (script_from_file): Adjust.
968
969 2019-02-19  Tom Tromey  <tromey@adacore.com>
970
971         * ravenscar-thread.c
972         (ravenscar_thread_target::update_thread_list): Don't call
973         ada_build_task_list.
974         * ada-lang.h (ada_build_task_list): Don't declare.
975         * ada-tasks.c (struct ada_tasks_inferior_data)
976         <task_list_valid_p>: Now bool.
977         (read_known_tasks, ada_task_list_changed)
978         (ada_tasks_invalidate_inferior_data): Update.
979         (read_known_tasks_array): Return bool.
980         (read_known_tasks_list): Likewise.
981         (read_known_tasks): Return void.
982         (ada_build_task_list): Now static.
983
984 2019-02-18  Andrew Burgess  <andrew.burgess@embecosm.com>
985
986         * gdbtypes.c (type_align): Allow alignment of TYPE_CODE_METHODPTR
987         and TYPE_CODE_MEMBERPTR to be overridden by the gdbarch.
988
989 2019-02-18  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
990
991         * ada-task.c (_initialize_tasks): Use 'with_cleanup' register
992         variant for ada_tasks_pspace_data_handle and
993         ada_tasks_inferior_data_handle.
994         (ada_tasks_pspace_data_cleanup): New function.
995         (ada_tasks_inferior_data_cleanup): New function.
996
997 2019-02-17  Tom Tromey  <tom@tromey.com>
998
999         * macrotab.h (macro_source_fullname): Return a std::string.
1000         * macrotab.c (macro_include, check_for_redefinition)
1001         (macro_undef, macro_lookup_definition, foreach_macro)
1002         (foreach_macro_in_scope): Update.
1003         (macro_source_fullname): Return a std::string.
1004         * macrocmd.c (show_pp_source_pos): Update.
1005
1006 2019-02-17  Tom Tromey  <tom@tromey.com>
1007
1008         * macrocmd.c (show_pp_source_pos): Style the file names.
1009
1010 2019-02-17  Tom Tromey  <tom@tromey.com>
1011
1012         PR tui/24197:
1013         * tui/tui-source.c (tui_set_source_content_nil): Rewrite.
1014
1015 2019-02-17  Tom Tromey  <tom@tromey.com>
1016
1017         * ada-lang.c (user_select_syms): Use filtered printing.
1018         * utils.c (wrap_style): New global.
1019         (desired_style): Remove.
1020         (emit_style_escape): Add stream parameter.
1021         (set_output_style, reset_terminal_style, prompt_for_continue):
1022         Update.
1023         (flush_wrap_buffer): Only flush gdb_stdout.
1024         (wrap_here): Set wrap_style.
1025         (fputs_maybe_filtered): Clear the wrap buffer on exception.  Don't
1026         treat escape sequences as a character.  Change when wrap buffer is
1027         flushed.
1028         (fputs_styled): Do not set the output style when the default is
1029         requested.
1030         * ui-style.h (struct ui_file_style) <is_default>: New method.
1031         * source.c (print_source_lines_base): Emit escape sequences in one
1032         piece.
1033
1034 2019-02-17  Joel Brobecker  <brobecker@adacore.com>
1035
1036         * gdbtypes.c (type_align): Handle TYPE_CODE_RANGE the same as
1037         integers and enumeration types.
1038
1039 2019-02-17  Joel Brobecker  <brobecker@adacore.com>
1040
1041         * ada-lang.c (standard_lookup): Use ada_lookup_encoded_symbol
1042         instead of lookup_symbol_in_language
1043         (do_exact_match): New function.
1044         (ada_get_symbol_name_matcher): Return do_exact_match when
1045         doing a verbatim match.
1046
1047 2019-02-15  Tom Tromey  <tromey@adacore.com>
1048
1049         * ravenscar-thread.c (ravenscar_thread_target::resume)
1050         (ravenscar_thread_target::wait): Special case wildcard requests.
1051
1052 2019-02-15  Tom Tromey  <tromey@adacore.com>
1053
1054         * ravenscar-thread.c (base_ptid): Remove.
1055         (struct ravenscar_thread_target) <close>: New method.
1056         <m_base_ptid>: New member.
1057         <update_inferior_ptid, active_task, task_is_currently_active,
1058         runtime_initialized>: Declare methods.
1059         <ravenscar_thread_target>: Add constructor.
1060         (ravenscar_thread_target::task_is_currently_active)
1061         (ravenscar_thread_target::update_inferior_ptid)
1062         (ravenscar_runtime_initialized): Rename.  Now methods.
1063         (ravenscar_thread_target::resume, ravenscar_thread_target::wait)
1064         (ravenscar_thread_target::update_thread_list): Update.
1065         (ravenscar_thread_target::active_task): Now method.
1066         (ravenscar_thread_target::store_registers)
1067         (ravenscar_thread_target::prepare_to_store)
1068         (ravenscar_thread_target::prepare_to_store)
1069         (ravenscar_thread_target::mourn_inferior): Update.
1070         (ravenscar_inferior_created): Use "new" to create target.
1071         (ravenscar_thread_target::get_ada_task_ptid): Update.
1072         (_initialize_ravenscar): Don't initialize base_ptid.
1073         (ravenscar_ops): Remove global.
1074
1075 2019-02-15  Tom Tromey  <tromey@adacore.com>
1076
1077         * target.h (push_target): Declare new overload.
1078         * target.c (push_target): New overload, taking an rvalue reference.
1079         * remote.c (remote_target::open_1): Use push_target overload.
1080         * corelow.c (core_target_open): Use push_target overload.
1081
1082 2019-02-15  Tom Tromey  <tromey@adacore.com>
1083
1084         * ravenscar-thread.c (is_ravenscar_task)
1085         (ravenscar_task_is_currently_active): Return bool.
1086         (ravenscar_update_inferior_ptid, get_running_thread_msymbol)
1087         (_initialize_ravenscar): Remove "(void)".
1088         (has_ravenscar_runtime, ravenscar_runtime_initialized): Likewise.
1089         Return bool.
1090
1091 2019-02-15  Tom Tromey  <tromey@adacore.com>
1092
1093         * ravenscar-thread.c (ravenscar_runtime_initializer)
1094         (has_ravenscar_runtime, get_running_thread_id)
1095         (ravenscar_thread_target::resume): Fix indentation.
1096
1097 2019-02-15  Tom Tromey  <tromey@adacore.com>
1098
1099         * sparc-ravenscar-thread.c (struct sparc_ravenscar_ops): Derive
1100         from ravenscar_arch_ops.
1101         (sparc_ravenscar_ops::fetch_registers)
1102         (sparc_ravenscar_ops::store_registers): Now methods.
1103         (sparc_ravenscar_prepare_to_store): Remove.
1104         (sparc_ravenscar_ops): Redefine.
1105         * ravenscar-thread.h (struct ravenscar_arch_ops): Add virtual
1106         methods and destructor.  Remove members.
1107         * ravenscar-thread.c (ravenscar_thread_target::fetch_registers)
1108         (ravenscar_thread_target::store_registers)
1109         (ravenscar_thread_target::prepare_to_store): Update.
1110         * ppc-ravenscar-thread.c (ppc_ravenscar_generic_prepare_to_store):
1111         Remove.
1112         (struct ppc_ravenscar_powerpc_ops): Derive from
1113         ravenscar_arch_ops.
1114         (ppc_ravenscar_powerpc_ops::fetch_registers)
1115         (ppc_ravenscar_powerpc_ops::store_registers): Now methods.
1116         (ppc_ravenscar_powerpc_ops): Redefine.
1117         (struct ppc_ravenscar_e500_ops): Derive from ravenscar_arch_ops.
1118         (ppc_ravenscar_e500_ops::fetch_registers)
1119         (ppc_ravenscar_e500_ops::store_registers): Now methods.
1120         (ppc_ravenscar_e500_ops): Redefine.
1121         * aarch64-ravenscar-thread.c
1122         (aarch64_ravenscar_generic_prepare_to_store): Remove.
1123         (struct aarch64_ravenscar_ops): Derive from ravenscar_arch_ops.
1124         (aarch64_ravenscar_fetch_registers)
1125         (aarch64_ravenscar_store_registers): Now methods.
1126         (aarch64_ravenscar_ops): Redefine.
1127
1128 2019-02-15  Tom Tromey  <tromey@adacore.com>
1129
1130         * ravenscar-thread.c (ravenscar_thread_target::stopped_by_sw_breakpoint)
1131         (ravenscar_thread_target::stopped_by_hw_breakpoint)
1132         (ravenscar_thread_target::stopped_by_watchpoint)
1133         (ravenscar_thread_target::stopped_data_address)
1134         (ravenscar_thread_target::core_of_thread): Use scoped_restore.
1135
1136 2019-02-15  Tom Tromey  <tromey@adacore.com>
1137
1138         * ravenscar-thread.c: Fix some typos.
1139
1140 2019-02-15  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
1141             Tom Tromey  <tromey@adacore.com>
1142
1143         * ada-lang.c (ada_exception_sal): Change addr_string to a
1144         std::string.
1145         (create_ada_exception_catchpoint): Update.
1146
1147 2019-02-15  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
1148             Tom Tromey  <tromey@adacore.com>
1149
1150         * breakpoint.c (~bp_location): Rename from bp_location_dtor.
1151         (bp_location_ops): Remove.
1152         (base_breakpoint_allocate_location): Update.
1153         (free_bp_location): Update.
1154         * ada-lang.c (class ada_catchpoint_location)
1155         <ada_catchpoint_location>: Remove ops parameter.
1156         (ada_catchpoint_location_dtor): Remove.
1157         (ada_catchpoint_location_ops): Remove.
1158         (allocate_location_exception): Update.
1159         * breakpoint.h (struct bp_location_ops): Remove.
1160         (class bp_location) <bp_location>: Remove bp_location_ops
1161         parameter.
1162         <~bp_location>: Add destructor.
1163         <ops>: Remove.
1164
1165 2019-02-14  Thomas Schwinge  <thomas@codesourcery.com>
1166             Pedro Alves  <palves@redhat.com>
1167
1168         * remote.c (remote_target::remote_parse_stop_reply): Avoid using
1169         'PATH_MAX'.
1170
1171 2019-02-14  David Michael  <fedora.dm0@gmail.com>
1172             Samuel Thibault  <samuel.thibault@gnu.org>
1173             Thomas Schwinge  <thomas@codesourcery.com>
1174
1175         * gnu-nat.c (S_proc_getmsgport_reply, S_proc_task2proc_reply)
1176         (S_proc_pid2proc_reply): Adjust to Hurd "proc" interface changes.
1177
1178 2019-02-14  Thomas Schwinge  <thomas@codesourcery.com>
1179
1180         * gnu-nat.c (gnu_write_inferior, parse_int_arg, _parse_bool_arg)
1181         (check_empty): Use "const char *".
1182
1183         * gnu-nat.c (gnu_nat_target::detach): Instead of
1184         'detach_inferior (pid)' call
1185         'detach_inferior (find_inferior_pid (pid))'.
1186
1187         * configure.nat [gdb_host == i386gnu] (NATDEPFILES): Add
1188         'nat/fork-inferior.o'.
1189         * gnu-nat.c: #include "nat/fork-inferior.h".
1190
1191         * gnu-nat.c (gnu_nat_target::detach): Instead of
1192         'inf_child_maybe_unpush_target (ops)' call 'maybe_unpush_target'.
1193         * gnu-nat.h: #include "inf-child.h".
1194         * i386-gnu-nat.c (gnu_fetch_registers): Rename/move to
1195         'i386_gnu_nat_target::fetch_registers'.
1196         (gnu_store_registers): Rename/move to
1197         'i386_gnu_nat_target::store_registers'.
1198
1199         * config/i386/nm-i386gnu.h: Don't "#include" any files.
1200         * gnu-nat.h (mach_thread_info): New function.
1201         * gnu-nat.c (thread_takeover_sc_cmd): Use it.
1202
1203         * config/i386/nm-i386gnu.h (gnu_target_pid_to_str): Remove.
1204
1205 2019-02-14  Frederic Konrad  <konrad@adacore.com>
1206
1207         * riscv-rdep.c (riscv_type_alignment): Handle TYPE_CODE_RANGE.
1208
1209 2019-02-14  Joel Brobecker  <brobecker@adacore.com>
1210
1211         * windows-nat.c (windows_add_thread): Add new parameter
1212         "main_thread_p" with default value set to false.  Update
1213         function documentation as well as all callers.
1214         (windows_delete_thread): Likewise.
1215         (fake_create_process): Update call to windows_add_thread.
1216         (get_windows_debug_event) <CREATE_THREAD_DEBUG_EVENT>
1217         <CREATE_PROCESS_DEBUG_EVENT>: Likewise.
1218         <EXIT_THREAD_DEBUG_EVENT, EXIT_PROCESS_DEBUG_EVENT>: Update
1219         call to windows_delete_thread.
1220
1221 2019-02-13  Simon Marchi  <simon.marchi@ericsson.com>
1222
1223         * MAINTAINERS: Add Andrew Burgess as global maintainer.
1224
1225 2019-02-12  John Baldwin  <jhb@FreeBSD.org>
1226
1227         * symfile.c (find_separate_debug_file): Use canonical path of
1228         sysroot with child_path instead of gdb_sysroot if it is valid.
1229
1230 2019-02-12  John Baldwin  <jhb@FreeBSD.org>
1231
1232         * symfile.c (find_separate_debug_file): Use child_path to
1233         determine if an object file is under a sysroot.
1234
1235 2019-02-12  John Baldwin  <jhb@FreeBSD.org>
1236
1237         * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1238         unittests/child-path-selftests.c.
1239         * common/pathstuff.c (child_path): New function.
1240         * common/pathstuff.h (child_path): New prototype.
1241         * unittests/child-path-selftests.c: New file.
1242
1243 2019-02-12  John Baldwin  <jhb@FreeBSD.org>
1244
1245         * symfile.c (find_separate_debug_file): Look for separate debug
1246         files in debug directories under the sysroot.
1247
1248 2019-02-12  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
1249
1250         * symtab.h (struct minimal_symbol data_p): New const method.
1251         (struct minimal_symbol text_p): Likewise.
1252         * symtab.c (output_source_filename): Use file name style
1253         to print file name.
1254         (print_symbol_info): Likewise.
1255         (print_msymbol_info): Use address style to print addresses.
1256         Use function name style to print executable text symbols.
1257         (expand_symtab_containing_pc): Use data_p.
1258         (find_pc_sect_compunit_symtab): Likewise.
1259
1260 2019-02-12  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
1261
1262         * breakpoint.c (describe_other_breakpoints): Use address style
1263         to print addresses.
1264         (say_where): Likewise.
1265
1266 2019-02-12  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
1267
1268         * ada-typeprint.c (print_func_type): Print function name
1269         style to print function name.
1270         * c-typeprint.c (c_print_type_1): Likewise.
1271
1272 2019-02-11  Alan Hayward  <alan.hayward@arm.com>
1273
1274         * aarch64-linux-tdep.c (aarch64_linux_get_syscall_number): Check
1275         for execve.
1276
1277 2019-02-10  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
1278
1279         * c-exp.y (direct_abs_decl): Use emplace_back to record the
1280         type_stack.
1281
1282 2019-02-10  Joel Brobecker  <brobecker@adacore.com>
1283
1284         * ada-varobj.c (ada_value_is_changeable_p): Add handling of
1285         TYPE_CODE_REF types.
1286
1287 2019-02-08  Jim Wilson  <jimw@sifive.com>
1288
1289         * riscv-linux-tdep.c (riscv_linux_fregmap): New.
1290         (riscv_linux_fregset): New.
1291         (riscv_linux_iterate_over_regset_sections): Call cb for .reg2 section.
1292
1293 2019-02-07  Tom Tromey  <tom@tromey.com>
1294
1295         * thread.c (thread_cancel_execution_command): Update.
1296         * thread-fsm.h (struct thread_fsm): Add constructor, destructor,
1297         methods.
1298         (struct thread_fsm_ops): Remove.
1299         (thread_fsm_ctor, thread_fsm_delete, thread_fsm_clean_up)
1300         (thread_fsm_should_stop, thread_fsm_return_value)
1301         (thread_fsm_set_finished, thread_fsm_finished_p)
1302         (thread_fsm_async_reply_reason, thread_fsm_should_notify_stop):
1303         Don't declare.
1304         * mi/mi-interp.c (mi_on_normal_stop_1): Update.
1305         * infrun.c (clear_proceed_status_thread)
1306         (clean_up_just_stopped_threads_fsms, fetch_inferior_event)
1307         (print_stop_event): Update.
1308         * infcmd.c (struct step_command_fsm): Inherit from thread_fsm.
1309         Add constructor.
1310         (step_command_fsm_ops): Remove.
1311         (new_step_command_fsm): Remove.
1312         (step_1): Update.
1313         (step_command_fsm::should_stop): Rename from
1314         step_command_fsm_should_stop.
1315         (step_command_fsm::clean_up): Rename from
1316         step_command_fsm_clean_up.
1317         (step_command_fsm::do_async_reply_reason): Rename from
1318         step_command_fsm_async_reply_reason.
1319         (struct until_next_fsm): Inherit from thread_fsm.  Add
1320         constructor.
1321         (until_next_fsm_ops): Remove.
1322         (new_until_next_fsm): Remove.
1323         (until_next_fsm::should_stop): Rename from
1324         until_next_fsm_should_stop.
1325         (until_next_fsm::clean_up): Rename from until_next_fsm_clean_up.
1326         (until_next_fsm::do_async_reply_reason): Rename from
1327         until_next_fsm_async_reply_reason.
1328         (struct finish_command_fsm): Inherit from thread_fsm.  Add
1329         constructor.  Change type of breakpoint.
1330         (finish_command_fsm_ops): Remove.
1331         (new_finish_command_fsm): Remove.
1332         (finish_command_fsm::should_stop): Rename from
1333         finish_command_fsm_should_stop.
1334         (finish_command_fsm::clean_up): Rename from
1335         finish_command_fsm_clean_up.
1336         (finish_command_fsm::return_value): Rename from
1337         finish_command_fsm_return_value.
1338         (finish_command_fsm::do_async_reply_reason): Rename from
1339         finish_command_fsm_async_reply_reason.
1340         (finish_command): Update.
1341         * infcall.c (struct call_thread_fsm): Inherit from thread_fsm.
1342         Add constructor.
1343         (call_thread_fsm_ops): Remove.
1344         (call_thread_fsm::call_thread_fsm): Rename from
1345         new_call_thread_fsm.
1346         (call_thread_fsm::should_stop): Rename from
1347         call_thread_fsm_should_stop.
1348         (call_thread_fsm::should_notify_stop): Rename from
1349         call_thread_fsm_should_notify_stop.
1350         (run_inferior_call, call_function_by_hand_dummy): Update.
1351         * cli/cli-interp.c (should_print_stop_to_console): Update.
1352         * breakpoint.c (struct until_break_fsm): Inherit from thread_fsm.
1353         Add constructor.  Change type of location_breakpoint,
1354         caller_breakpoint.
1355         (until_break_fsm_ops): Remove.
1356         (new_until_break_fsm): Remove.
1357         (until_break_fsm::should_stop): Rename from
1358         until_break_fsm_should_stop.
1359         (until_break_fsm::clean_up): Rename from
1360         until_break_fsm_clean_up.
1361         (until_break_fsm::do_async_reply_reason): Rename from
1362         until_break_fsm_async_reply_reason.
1363         (until_break_command): Update.
1364         * thread-fsm.c: Remove.
1365         * Makefile.in (COMMON_SFILES): Remove thread-fsm.c.
1366
1367 2019-02-07  Tom Tromey  <tom@tromey.com>
1368
1369         * yy-remap.h: Add include guard.
1370         * xtensa-tdep.h: Add include guard.
1371         * xcoffread.h: Rename include guard.
1372         * varobj-iter.h: Add include guard.
1373         * tui/tui.h: Rename include guard.
1374         * tui/tui-winsource.h: Rename include guard.
1375         * tui/tui-wingeneral.h: Rename include guard.
1376         * tui/tui-windata.h: Rename include guard.
1377         * tui/tui-win.h: Rename include guard.
1378         * tui/tui-stack.h: Rename include guard.
1379         * tui/tui-source.h: Rename include guard.
1380         * tui/tui-regs.h: Rename include guard.
1381         * tui/tui-out.h: Rename include guard.
1382         * tui/tui-layout.h: Rename include guard.
1383         * tui/tui-io.h: Rename include guard.
1384         * tui/tui-hooks.h: Rename include guard.
1385         * tui/tui-file.h: Rename include guard.
1386         * tui/tui-disasm.h: Rename include guard.
1387         * tui/tui-data.h: Rename include guard.
1388         * tui/tui-command.h: Rename include guard.
1389         * tic6x-tdep.h: Add include guard.
1390         * target/waitstatus.h: Rename include guard.
1391         * target/wait.h: Rename include guard.
1392         * target/target.h: Rename include guard.
1393         * target/resume.h: Rename include guard.
1394         * target-float.h: Rename include guard.
1395         * stabsread.h: Add include guard.
1396         * rs6000-tdep.h: Add include guard.
1397         * riscv-fbsd-tdep.h: Add include guard.
1398         * regformats/regdef.h: Rename include guard.
1399         * record.h: Rename include guard.
1400         * python/python.h: Rename include guard.
1401         * python/python-internal.h: Rename include guard.
1402         * python/py-stopevent.h: Rename include guard.
1403         * python/py-ref.h: Rename include guard.
1404         * python/py-record.h: Rename include guard.
1405         * python/py-record-full.h: Rename include guard.
1406         * python/py-record-btrace.h: Rename include guard.
1407         * python/py-instruction.h: Rename include guard.
1408         * python/py-events.h: Rename include guard.
1409         * python/py-event.h: Rename include guard.
1410         * procfs.h: Add include guard.
1411         * proc-utils.h: Add include guard.
1412         * p-lang.h: Add include guard.
1413         * or1k-tdep.h: Rename include guard.
1414         * observable.h: Rename include guard.
1415         * nto-tdep.h: Rename include guard.
1416         * nat/x86-linux.h: Rename include guard.
1417         * nat/x86-linux-dregs.h: Rename include guard.
1418         * nat/x86-gcc-cpuid.h: Add include guard.
1419         * nat/x86-dregs.h: Rename include guard.
1420         * nat/x86-cpuid.h: Rename include guard.
1421         * nat/ppc-linux.h: Rename include guard.
1422         * nat/mips-linux-watch.h: Rename include guard.
1423         * nat/linux-waitpid.h: Rename include guard.
1424         * nat/linux-ptrace.h: Rename include guard.
1425         * nat/linux-procfs.h: Rename include guard.
1426         * nat/linux-osdata.h: Rename include guard.
1427         * nat/linux-nat.h: Rename include guard.
1428         * nat/linux-namespaces.h: Rename include guard.
1429         * nat/linux-btrace.h: Rename include guard.
1430         * nat/glibc_thread_db.h: Rename include guard.
1431         * nat/gdb_thread_db.h: Rename include guard.
1432         * nat/gdb_ptrace.h: Rename include guard.
1433         * nat/fork-inferior.h: Rename include guard.
1434         * nat/amd64-linux-siginfo.h: Rename include guard.
1435         * nat/aarch64-sve-linux-sigcontext.h: Rename include guard.
1436         * nat/aarch64-sve-linux-ptrace.h: Rename include guard.
1437         * nat/aarch64-linux.h: Rename include guard.
1438         * nat/aarch64-linux-hw-point.h: Rename include guard.
1439         * mn10300-tdep.h: Add include guard.
1440         * mips-linux-tdep.h: Add include guard.
1441         * mi/mi-parse.h: Rename include guard.
1442         * mi/mi-out.h: Rename include guard.
1443         * mi/mi-main.h: Rename include guard.
1444         * mi/mi-interp.h: Rename include guard.
1445         * mi/mi-getopt.h: Rename include guard.
1446         * mi/mi-console.h: Rename include guard.
1447         * mi/mi-common.h: Rename include guard.
1448         * mi/mi-cmds.h: Rename include guard.
1449         * mi/mi-cmd-break.h: Rename include guard.
1450         * m2-lang.h: Add include guard.
1451         * location.h: Rename include guard.
1452         * linux-record.h: Rename include guard.
1453         * linux-nat.h: Add include guard.
1454         * linux-fork.h: Add include guard.
1455         * i386-darwin-tdep.h: Rename include guard.
1456         * hppa-linux-offsets.h: Add include guard.
1457         * guile/guile.h: Rename include guard.
1458         * guile/guile-internal.h: Rename include guard.
1459         * gnu-nat.h: Rename include guard.
1460         * gdb-stabs.h: Rename include guard.
1461         * frv-tdep.h: Add include guard.
1462         * f-lang.h: Add include guard.
1463         * event-loop.h: Add include guard.
1464         * darwin-nat.h: Rename include guard.
1465         * cp-abi.h: Rename include guard.
1466         * config/sparc/nm-sol2.h: Rename include guard.
1467         * config/nm-nto.h: Rename include guard.
1468         * config/nm-linux.h: Add include guard.
1469         * config/i386/nm-i386gnu.h: Rename include guard.
1470         * config/djgpp/nl_types.h: Rename include guard.
1471         * config/djgpp/langinfo.h: Rename include guard.
1472         * compile/gcc-cp-plugin.h: Add include guard.
1473         * compile/gcc-c-plugin.h: Add include guard.
1474         * compile/compile.h: Rename include guard.
1475         * compile/compile-object-run.h: Rename include guard.
1476         * compile/compile-object-load.h: Rename include guard.
1477         * compile/compile-internal.h: Rename include guard.
1478         * compile/compile-cplus.h: Rename include guard.
1479         * compile/compile-c.h: Rename include guard.
1480         * common/xml-utils.h: Rename include guard.
1481         * common/x86-xstate.h: Rename include guard.
1482         * common/version.h: Rename include guard.
1483         * common/vec.h: Rename include guard.
1484         * common/tdesc.h: Rename include guard.
1485         * common/selftest.h: Rename include guard.
1486         * common/scoped_restore.h: Rename include guard.
1487         * common/scoped_mmap.h: Rename include guard.
1488         * common/scoped_fd.h: Rename include guard.
1489         * common/safe-iterator.h: Rename include guard.
1490         * common/run-time-clock.h: Rename include guard.
1491         * common/refcounted-object.h: Rename include guard.
1492         * common/queue.h: Rename include guard.
1493         * common/ptid.h: Rename include guard.
1494         * common/print-utils.h: Rename include guard.
1495         * common/preprocessor.h: Rename include guard.
1496         * common/pathstuff.h: Rename include guard.
1497         * common/observable.h: Rename include guard.
1498         * common/netstuff.h: Rename include guard.
1499         * common/job-control.h: Rename include guard.
1500         * common/host-defs.h: Rename include guard.
1501         * common/gdb_wait.h: Rename include guard.
1502         * common/gdb_vecs.h: Rename include guard.
1503         * common/gdb_unlinker.h: Rename include guard.
1504         * common/gdb_unique_ptr.h: Rename include guard.
1505         * common/gdb_tilde_expand.h: Rename include guard.
1506         * common/gdb_sys_time.h: Rename include guard.
1507         * common/gdb_string_view.h: Rename include guard.
1508         * common/gdb_splay_tree.h: Rename include guard.
1509         * common/gdb_setjmp.h: Rename include guard.
1510         * common/gdb_ref_ptr.h: Rename include guard.
1511         * common/gdb_optional.h: Rename include guard.
1512         * common/gdb_locale.h: Rename include guard.
1513         * common/gdb_assert.h: Rename include guard.
1514         * common/filtered-iterator.h: Rename include guard.
1515         * common/filestuff.h: Rename include guard.
1516         * common/fileio.h: Rename include guard.
1517         * common/environ.h: Rename include guard.
1518         * common/common-utils.h: Rename include guard.
1519         * common/common-types.h: Rename include guard.
1520         * common/common-regcache.h: Rename include guard.
1521         * common/common-inferior.h: Rename include guard.
1522         * common/common-gdbthread.h: Rename include guard.
1523         * common/common-exceptions.h: Rename include guard.
1524         * common/common-defs.h: Rename include guard.
1525         * common/common-debug.h: Rename include guard.
1526         * common/cleanups.h: Rename include guard.
1527         * common/buffer.h: Rename include guard.
1528         * common/btrace-common.h: Rename include guard.
1529         * common/break-common.h: Rename include guard.
1530         * cli/cli-utils.h: Rename include guard.
1531         * cli/cli-style.h: Rename include guard.
1532         * cli/cli-setshow.h: Rename include guard.
1533         * cli/cli-script.h: Rename include guard.
1534         * cli/cli-interp.h: Rename include guard.
1535         * cli/cli-decode.h: Rename include guard.
1536         * cli/cli-cmds.h: Rename include guard.
1537         * charset-list.h: Add include guard.
1538         * buildsym-legacy.h: Rename include guard.
1539         * bfin-tdep.h: Add include guard.
1540         * ax.h: Rename include guard.
1541         * arm-linux-tdep.h: Add include guard.
1542         * arm-fbsd-tdep.h: Add include guard.
1543         * arch/xtensa.h: Rename include guard.
1544         * arch/tic6x.h: Add include guard.
1545         * arch/i386.h: Add include guard.
1546         * arch/arm.h: Rename include guard.
1547         * arch/arm-linux.h: Rename include guard.
1548         * arch/arm-get-next-pcs.h: Rename include guard.
1549         * arch/amd64.h: Add include guard.
1550         * arch/aarch64-insn.h: Rename include guard.
1551         * arch-utils.h: Rename include guard.
1552         * annotate.h: Add include guard.
1553         * amd64-darwin-tdep.h: Rename include guard.
1554         * aarch64-linux-tdep.h: Add include guard.
1555         * aarch64-fbsd-tdep.h: Add include guard.
1556         * aarch32-linux-nat.h: Add include guard.
1557
1558 2019-02-06  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
1559
1560         * macrotab.c (macro_define_internal): New function that
1561         factorizes macro_define_object_internal and macro_define_function
1562         code.
1563         (macro_define_object_internal): Use macro_define_internal.
1564         (macro_define_function): Likewise.
1565
1566 2019-02-06  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
1567
1568         * macrocmd.c (extract_identifier): Return
1569         a gdb::unique_xmalloc_ptr<char> instead of a char *, and update
1570         callers.
1571
1572 2019-02-06  John Baldwin  <jhb@FreeBSD.org>
1573
1574         * fbsd-nat.c (fbsd_fetch_cmdline): Join arguments with spaces.
1575
1576 2019-02-05  Tom Tromey  <tom@tromey.com>
1577
1578         * target.c (target_stack::unpush): Move assertion earlier.
1579
1580 2019-01-30  Tom Tromey  <tom@tromey.com>
1581
1582         PR python/23615:
1583         * python/python.c (execute_gdb_command): Use gdbpy_allow_threads.
1584         (gdbpy_parse_and_eval): Likewise.
1585         * python/python-internal.h (gdbpy_allow_threads): New class.
1586
1587 2019-01-28  John Baldwin  <jhb@FreeBSD.org>
1588
1589         * aarch64-fbsd-tdep.c (aarch64_fbsd_gregmap)
1590         (aarch64_fbsd_fpregmap): Move earlier.
1591         (AARCH64_MCONTEXT_REG_SIZE, AARCH64_MCONTEXT_FPREG_SIZE): Delete.
1592         (aarch64_fbsd_sigframe_init): Use trad_frame_set_reg_regmap
1593         instead of individual calls to trad_frame_set_reg_addr.
1594         * arm-fbsd-tdep.c (arm_fbsd_gregmap, arm_fbsd_vfpregmap): Move
1595         earlier.
1596         (ARM_MCONTEXT_REG_SIZE, ARM_MCONTEXT_VFP_REG_SIZE): Delete.
1597         (arm_fbsd_sigframe_init): Use trad_frame_set_reg_regmap
1598         instead of individual calls to trad_frame_set_reg_addr.
1599
1600 2019-01-28  Alan Hayward  <alan.hayward@arm.com>
1601
1602         * CONTRIBUTE: Replace contribution list with wiki link.
1603
1604 2019-01-25  Tom Tromey  <tom@tromey.com>
1605
1606         * Makefile.in (GDB_CFLAGS): Don't add -I for common.
1607
1608 2019-01-25  Tom Tromey  <tom@tromey.com>
1609
1610         * xtensa-linux-nat.c: Fix common/ includes.
1611         * xml-support.h: Fix common/ includes.
1612         * xml-support.c: Fix common/ includes.
1613         * x86-linux-nat.c: Fix common/ includes.
1614         * windows-nat.c: Fix common/ includes.
1615         * varobj.h: Fix common/ includes.
1616         * varobj.c: Fix common/ includes.
1617         * value.c: Fix common/ includes.
1618         * valops.c: Fix common/ includes.
1619         * utils.c: Fix common/ includes.
1620         * unittests/xml-utils-selftests.c: Fix common/ includes.
1621         * unittests/utils-selftests.c: Fix common/ includes.
1622         * unittests/unpack-selftests.c: Fix common/ includes.
1623         * unittests/tracepoint-selftests.c: Fix common/ includes.
1624         * unittests/style-selftests.c: Fix common/ includes.
1625         * unittests/string_view-selftests.c: Fix common/ includes.
1626         * unittests/scoped_restore-selftests.c: Fix common/ includes.
1627         * unittests/scoped_mmap-selftests.c: Fix common/ includes.
1628         * unittests/scoped_fd-selftests.c: Fix common/ includes.
1629         * unittests/rsp-low-selftests.c: Fix common/ includes.
1630         * unittests/parse-connection-spec-selftests.c: Fix common/
1631         includes.
1632         * unittests/optional-selftests.c: Fix common/ includes.
1633         * unittests/offset-type-selftests.c: Fix common/ includes.
1634         * unittests/observable-selftests.c: Fix common/ includes.
1635         * unittests/mkdir-recursive-selftests.c: Fix common/ includes.
1636         * unittests/memrange-selftests.c: Fix common/ includes.
1637         * unittests/memory-map-selftests.c: Fix common/ includes.
1638         * unittests/lookup_name_info-selftests.c: Fix common/ includes.
1639         * unittests/function-view-selftests.c: Fix common/ includes.
1640         * unittests/environ-selftests.c: Fix common/ includes.
1641         * unittests/copy_bitwise-selftests.c: Fix common/ includes.
1642         * unittests/common-utils-selftests.c: Fix common/ includes.
1643         * unittests/cli-utils-selftests.c: Fix common/ includes.
1644         * unittests/array-view-selftests.c: Fix common/ includes.
1645         * ui-file.c: Fix common/ includes.
1646         * tui/tui-io.c: Fix common/ includes.
1647         * tracepoint.h: Fix common/ includes.
1648         * tracepoint.c: Fix common/ includes.
1649         * tracefile-tfile.c: Fix common/ includes.
1650         * top.h: Fix common/ includes.
1651         * top.c: Fix common/ includes.
1652         * thread.c: Fix common/ includes.
1653         * target/waitstatus.h: Fix common/ includes.
1654         * target/waitstatus.c: Fix common/ includes.
1655         * target.h: Fix common/ includes.
1656         * target.c: Fix common/ includes.
1657         * target-memory.c: Fix common/ includes.
1658         * target-descriptions.c: Fix common/ includes.
1659         * symtab.h: Fix common/ includes.
1660         * symfile.c: Fix common/ includes.
1661         * stap-probe.c: Fix common/ includes.
1662         * spu-linux-nat.c: Fix common/ includes.
1663         * sparc-nat.c: Fix common/ includes.
1664         * source.c: Fix common/ includes.
1665         * solib.c: Fix common/ includes.
1666         * solib-target.c: Fix common/ includes.
1667         * ser-unix.c: Fix common/ includes.
1668         * ser-tcp.c: Fix common/ includes.
1669         * ser-pipe.c: Fix common/ includes.
1670         * ser-base.c: Fix common/ includes.
1671         * selftest-arch.c: Fix common/ includes.
1672         * s12z-tdep.c: Fix common/ includes.
1673         * rust-exp.y: Fix common/ includes.
1674         * rs6000-aix-tdep.c: Fix common/ includes.
1675         * riscv-tdep.c: Fix common/ includes.
1676         * remote.c: Fix common/ includes.
1677         * remote-notif.h: Fix common/ includes.
1678         * remote-fileio.h: Fix common/ includes.
1679         * remote-fileio.c: Fix common/ includes.
1680         * regcache.h: Fix common/ includes.
1681         * regcache.c: Fix common/ includes.
1682         * record-btrace.c: Fix common/ includes.
1683         * python/python.c: Fix common/ includes.
1684         * python/py-type.c: Fix common/ includes.
1685         * python/py-inferior.c: Fix common/ includes.
1686         * progspace.h: Fix common/ includes.
1687         * producer.c: Fix common/ includes.
1688         * procfs.c: Fix common/ includes.
1689         * proc-api.c: Fix common/ includes.
1690         * printcmd.c: Fix common/ includes.
1691         * ppc-linux-nat.c: Fix common/ includes.
1692         * parser-defs.h: Fix common/ includes.
1693         * osdata.c: Fix common/ includes.
1694         * obsd-nat.c: Fix common/ includes.
1695         * nat/x86-linux.c: Fix common/ includes.
1696         * nat/x86-linux-dregs.c: Fix common/ includes.
1697         * nat/x86-dregs.h: Fix common/ includes.
1698         * nat/x86-dregs.c: Fix common/ includes.
1699         * nat/ppc-linux.c: Fix common/ includes.
1700         * nat/mips-linux-watch.h: Fix common/ includes.
1701         * nat/mips-linux-watch.c: Fix common/ includes.
1702         * nat/linux-waitpid.c: Fix common/ includes.
1703         * nat/linux-ptrace.h: Fix common/ includes.
1704         * nat/linux-ptrace.c: Fix common/ includes.
1705         * nat/linux-procfs.c: Fix common/ includes.
1706         * nat/linux-personality.c: Fix common/ includes.
1707         * nat/linux-osdata.c: Fix common/ includes.
1708         * nat/linux-namespaces.c: Fix common/ includes.
1709         * nat/linux-btrace.h: Fix common/ includes.
1710         * nat/linux-btrace.c: Fix common/ includes.
1711         * nat/fork-inferior.c: Fix common/ includes.
1712         * nat/amd64-linux-siginfo.c: Fix common/ includes.
1713         * nat/aarch64-sve-linux-ptrace.c: Fix common/ includes.
1714         * nat/aarch64-linux.c: Fix common/ includes.
1715         * nat/aarch64-linux-hw-point.h: Fix common/ includes.
1716         * nat/aarch64-linux-hw-point.c: Fix common/ includes.
1717         * namespace.h: Fix common/ includes.
1718         * mips-linux-tdep.c: Fix common/ includes.
1719         * minsyms.c: Fix common/ includes.
1720         * mi/mi-parse.h: Fix common/ includes.
1721         * mi/mi-main.c: Fix common/ includes.
1722         * mi/mi-cmd-env.c: Fix common/ includes.
1723         * memrange.h: Fix common/ includes.
1724         * memattr.c: Fix common/ includes.
1725         * maint.h: Fix common/ includes.
1726         * maint.c: Fix common/ includes.
1727         * main.c: Fix common/ includes.
1728         * machoread.c: Fix common/ includes.
1729         * location.c: Fix common/ includes.
1730         * linux-thread-db.c: Fix common/ includes.
1731         * linux-nat.c: Fix common/ includes.
1732         * linux-fork.c: Fix common/ includes.
1733         * inline-frame.c: Fix common/ includes.
1734         * infrun.c: Fix common/ includes.
1735         * inflow.c: Fix common/ includes.
1736         * inferior.h: Fix common/ includes.
1737         * inferior.c: Fix common/ includes.
1738         * infcmd.c: Fix common/ includes.
1739         * inf-ptrace.c: Fix common/ includes.
1740         * inf-child.c: Fix common/ includes.
1741         * ia64-linux-nat.c: Fix common/ includes.
1742         * i387-tdep.c: Fix common/ includes.
1743         * i386-tdep.c: Fix common/ includes.
1744         * i386-linux-tdep.c: Fix common/ includes.
1745         * i386-linux-nat.c: Fix common/ includes.
1746         * i386-go32-tdep.c: Fix common/ includes.
1747         * i386-fbsd-tdep.c: Fix common/ includes.
1748         * i386-fbsd-nat.c: Fix common/ includes.
1749         * guile/scm-type.c: Fix common/ includes.
1750         * guile/guile.c: Fix common/ includes.
1751         * go32-nat.c: Fix common/ includes.
1752         * gnu-nat.c: Fix common/ includes.
1753         * gdbthread.h: Fix common/ includes.
1754         * gdbarch-selftests.c: Fix common/ includes.
1755         * gdb_usleep.c: Fix common/ includes.
1756         * gdb_select.h: Fix common/ includes.
1757         * gdb_bfd.c: Fix common/ includes.
1758         * gcore.c: Fix common/ includes.
1759         * fork-child.c: Fix common/ includes.
1760         * findvar.c: Fix common/ includes.
1761         * fbsd-nat.c: Fix common/ includes.
1762         * event-top.c: Fix common/ includes.
1763         * event-loop.c: Fix common/ includes.
1764         * dwarf2read.c: Fix common/ includes.
1765         * dwarf2loc.c: Fix common/ includes.
1766         * dwarf2-frame.c: Fix common/ includes.
1767         * dwarf-index-cache.c: Fix common/ includes.
1768         * dtrace-probe.c: Fix common/ includes.
1769         * disasm-selftests.c: Fix common/ includes.
1770         * defs.h: Fix common/ includes.
1771         * csky-tdep.c: Fix common/ includes.
1772         * cp-valprint.c: Fix common/ includes.
1773         * cp-support.h: Fix common/ includes.
1774         * cp-support.c: Fix common/ includes.
1775         * corelow.c: Fix common/ includes.
1776         * completer.h: Fix common/ includes.
1777         * completer.c: Fix common/ includes.
1778         * compile/compile.c: Fix common/ includes.
1779         * compile/compile-loc2c.c: Fix common/ includes.
1780         * compile/compile-cplus-types.c: Fix common/ includes.
1781         * compile/compile-cplus-symbols.c: Fix common/ includes.
1782         * command.h: Fix common/ includes.
1783         * cli/cli-dump.c: Fix common/ includes.
1784         * cli/cli-cmds.c: Fix common/ includes.
1785         * charset.c: Fix common/ includes.
1786         * build-id.c: Fix common/ includes.
1787         * btrace.h: Fix common/ includes.
1788         * btrace.c: Fix common/ includes.
1789         * breakpoint.h: Fix common/ includes.
1790         * breakpoint.c: Fix common/ includes.
1791         * ax.h: 
1792         (enum agent_op): Fix common/ includes.
1793         * ax-general.c (struct aop_map): Fix common/ includes.
1794         * ax-gdb.c: Fix common/ includes.
1795         * auxv.c: Fix common/ includes.
1796         * auto-load.c: Fix common/ includes.
1797         * arm-tdep.c: Fix common/ includes.
1798         * arch/riscv.c: Fix common/ includes.
1799         * arch/ppc-linux-common.c: Fix common/ includes.
1800         * arch/i386.c: Fix common/ includes.
1801         * arch/arm.c: Fix common/ includes.
1802         * arch/arm-linux.c: Fix common/ includes.
1803         * arch/arm-get-next-pcs.c: Fix common/ includes.
1804         * arch/amd64.c: Fix common/ includes.
1805         * arch/aarch64.c: Fix common/ includes.
1806         * arch/aarch64-insn.c: Fix common/ includes.
1807         * arch-utils.c: Fix common/ includes.
1808         * amd64-windows-tdep.c: Fix common/ includes.
1809         * amd64-tdep.c: Fix common/ includes.
1810         * amd64-sol2-tdep.c: Fix common/ includes.
1811         * amd64-obsd-tdep.c: Fix common/ includes.
1812         * amd64-nbsd-tdep.c: Fix common/ includes.
1813         * amd64-linux-tdep.c: Fix common/ includes.
1814         * amd64-linux-nat.c: Fix common/ includes.
1815         * amd64-fbsd-tdep.c: Fix common/ includes.
1816         * amd64-fbsd-nat.c: Fix common/ includes.
1817         * amd64-dicos-tdep.c: Fix common/ includes.
1818         * amd64-darwin-tdep.c: Fix common/ includes.
1819         * agent.c: Fix common/ includes.
1820         * ada-lang.h: Fix common/ includes.
1821         * ada-lang.c: Fix common/ includes.
1822         * aarch64-tdep.c: Fix common/ includes.
1823
1824 2019-01-25  Tom Tromey  <tom@tromey.com>
1825
1826         * common/create-version.sh: Use common/version.h.
1827
1828 2019-01-24  Pedro Alves  <palves@redhat.com>
1829
1830         * infrun.c (signal_stop, signal_print, signal_program)
1831         (signal_catch, signal_pass): Now arrays instead of pointers.
1832         (update_signals_program_target, do_target_resume)
1833         (signal_catch_update, handle_command, _initialize_infrun): Adjust.
1834         * linux-nat.c (linux_nat_target::pass_signals)
1835         (linux_nat_target::create_inferior, linux_nat_target::attach):
1836         Adjust.
1837         * linux-nat.h (linux_nat_target::pass_signals): Adjust.
1838         * nto-procfs.c (nto_procfs_target::pass_signals): Adjust.
1839         * procfs.c (procfs_target::pass_signals): Adjust.
1840         * record-full.c (record_full_target::resume): Adjust.
1841         * remote.c (remote_target::pass_signals)
1842         (remote_target::program_signals): Adjust.
1843         * target-debug.h (target_debug_print_signals): Now takes a
1844         gdb::array_view as parameter.  Adjust.
1845         * target.h (target_ops) <pass_signals, program_signals>: Replace
1846         pointer and length parameters with gdb::array_view.
1847         (target_pass_signals, target_program_signals): Likewise.
1848         * target-delegates.c: Regenerate.
1849
1850 2019-01-24  Pedro Alves  <palves@redhat.com>
1851
1852         * common/forward-scope-exit.h
1853         (forward_scope_exit::forward_scope_exit): Pass arguments to
1854         m_bind_function directly, instead of creating a std::bind and
1855         copying that.
1856
1857 2019-01-24  Alan Hayward  <alan.hayward@arm.com>
1858
1859         * aarch64-tdep.c (aapcs_is_vfp_call_or_return_candidate_1): Check
1860         for static members.
1861         (pass_in_v_vfp_candidate): Likewise.
1862
1863 2019-01-23  Tom Tromey  <tom@tromey.com>
1864             Pedro Alves  <palves@redhat.com>
1865
1866         * regcache.c (class regcache_invalidator): Remove.
1867         (regcache::raw_write): Use make_scope_exit.
1868
1869 2019-01-23  Tom Tromey  <tom@tromey.com>
1870
1871         * ui-out.h (class ui_out_emit_type): Update comment.
1872
1873 2019-01-23  Tom Tromey  <tom@tromey.com>
1874
1875         * infrun.c (fetch_inferior_event): Update comment.
1876
1877 2019-01-23  Tom Tromey  <tom@tromey.com>
1878             Pedro Alves  <palves@redhat.com>
1879
1880         * infrun.c (reinstall_readline_callback_handler_cleanup): Remove
1881         parameter.
1882         (fetch_inferior_event): Use SCOPE_EXIT.
1883
1884
1885 2019-01-23  Tom Tromey  <tom@tromey.com>
1886             Pedro Alves  <palves@redhat.com>
1887
1888         * infrun.c (disable_thread_events): Delete.
1889         (stop_all_threads): Use SCOPE_EXIT.
1890
1891 2019-01-23  Tom Tromey  <tom@tromey.com>
1892             Pedro Alves  <palves@redhat.com>
1893
1894         * symfile.c: Include forward-scope-exit.h.
1895         (clear_symtab_users_cleanup): Replace forward declaration with
1896         a FORWARD_SCOPE_EXIT.
1897         (syms_from_objfile_1): Use the forward_scope_exit and
1898         gdb::optional instead of cleanup_function.
1899         (reread_symbols): Use the forward_scope_exit instead of
1900         cleanup_function.
1901         (clear_symtab_users_cleanup): Remove function.
1902
1903 2019-01-23  Tom Tromey  <tom@tromey.com>
1904             Pedro Alves  <palves@redhat.com>
1905
1906         * linux-nat.c: Include scope-exit.h.
1907         (cleanup_target_stop): Remove.
1908         (linux_nat_target::static_tracepoint_markers_by_strid): Use
1909         SCOPE_EXIT.
1910
1911 2019-01-23  Tom Tromey  <tom@tromey.com>
1912             Pedro Alves  <palves@redhat.com>
1913
1914         * infcall.c (cleanup_delete_std_terminate_breakpoint): Remove.
1915         (call_function_by_hand_dummy): Use SCOPE_EXIT.
1916
1917 2019-01-23  Tom Tromey  <tom@tromey.com>
1918             Andrew Burgess  <andrew.burgess@embecosm.com>
1919             Pedro Alves  <palves@redhat.com>
1920
1921         * infrun.c (fetch_inferior_event): Use scope_exit.
1922         * utils.h (make_bpstat_clear_actions_cleanup): Don't declare.
1923         * top.c (execute_command): Use scope_exit.
1924         * breakpoint.c (bpstat_do_actions): Use scope_exit.
1925         * utils.c (do_bpstat_clear_actions_cleanup)
1926         (make_bpstat_clear_actions_cleanup): Remove.
1927
1928 2019-01-23  Tom Tromey  <tom@tromey.com>
1929             Pedro Alves  <palves@redhat.com>
1930
1931         * infrun.c: Include "common/scope-exit.h"
1932         (delete_just_stopped_threads_infrun_breakpoints_cleanup): Remove.
1933         (wait_for_inferior): Use SCOPE_EXIT.
1934         (fetch_inferior_event): Use scope_exit.
1935
1936 2019-01-23  Tom Tromey  <tom@tromey.com>
1937             Pedro Alves  <palves@redhat.com>
1938
1939         * breakpoint.c (create_breakpoint): Remove cleanup.
1940
1941 2019-01-23  Tom Tromey  <tom@tromey.com>
1942             Andrew Burgess  <andrew.burgess@embecosm.com>
1943             Pedro Alves  <palves@redhat.com>
1944
1945 2019-01-23  Pedro Alves  <palves@redhat.com>
1946
1947         * gdbarch-selftests.c (struct on_exit): Use SCOPE_EXIT.
1948
1949 2019-01-23  Pedro Alves  <palves@redhat.com>
1950             Andrew Burgess  <andrew.burgess@embecosm.com>
1951
1952         * gdbthread.h: Include "common/forward-scope-exit.h".
1953         (scoped_finish_thread_state): Redefine custom class in terms of
1954         forward_scope_exit.
1955
1956 2019-01-23  Pedro Alves  <palves@redhat.com>
1957             Andrew Burgess  <andrew.burgess@embecosm.com>
1958
1959         * common/forward-scope-exit.h: New file.
1960
1961 2019-01-23  Pedro Alves  <palves@redhat.com>
1962             Andrew Burgess  <andrew.burgess@embecosm.com>
1963             Tom Tromey  <tom@tromey.com>
1964
1965         * common/scope-exit.h: New file.
1966
1967 2019-01-23  Pedro Alves  <palves@redhat.com>
1968
1969         * common/preprocessor.h (ESC): Rename to ...
1970         (ESC_PARENS): ... this.
1971         * common/valid-expr.h (CHECK_VALID_EXPR_1, CHECK_VALID_EXPR_2)
1972         (CHECK_VALID_EXPR_3, CHECK_VALID_EXPR_4): Adjust.
1973
1974 2019-01-23  Tom Tromey  <tom@tromey.com>
1975
1976         * language.h (class scoped_switch_to_sym_language_if_auto):
1977         Initialize m_lang in both cases.
1978
1979 2019-01-23  Alan Hayward  <alan.hayward@arm.com>
1980
1981         * nat/aarch64-linux.c (aarch64_linux_new_thread): Replace XNEW
1982         with XCNEW.
1983
1984 2019-01-22  Tom Tromey  <tom@tromey.com>
1985
1986         * corelow.c: Do not include sys/file.h.
1987
1988 2019-01-22  Tom Tromey  <tom@tromey.com>
1989
1990         * tui/tui-wingeneral.h: Include gdb_curses.h.
1991
1992 2019-01-22  Tom Tromey  <tom@tromey.com>
1993
1994         * source-cache.h (class source_cache) <get_source_lines,
1995         get_plain_source_lines, extract_lines>: Rename "lines" parameter.
1996
1997 2019-01-22  Tom Tromey  <tom@tromey.com>
1998
1999         * remote-fileio.h (struct remote_target): Declare.
2000
2001 2019-01-22  Tom Tromey  <tom@tromey.com>
2002
2003         * python/py-arch.c: Do not include py-ref.h.
2004         * python/py-bpevent.c: Do not include py-ref.h.
2005         * python/py-cmd.c: Do not include py-ref.h.
2006         * python/py-continueevent.c: Do not include py-ref.h.
2007         * python/py-event.h: Do not include py-ref.h.
2008         * python/py-evtregistry.c: Do not include py-ref.h.
2009         * python/py-finishbreakpoint.c: Do not include py-ref.h.
2010         * python/py-frame.c: Do not include py-ref.h.
2011         * python/py-framefilter.c: Do not include py-ref.h.
2012         * python/py-function.c: Do not include py-ref.h.
2013         * python/py-infevents.c: Do not include py-ref.h.
2014         * python/py-linetable.c: Do not include py-ref.h.
2015         * python/py-objfile.c: Do not include py-ref.h.
2016         * python/py-param.c: Do not include py-ref.h.
2017         * python/py-prettyprint.c: Do not include py-ref.h.
2018         * python/py-progspace.c: Do not include py-ref.h.
2019         * python/py-symbol.c: Do not include py-ref.h.
2020         * python/py-symtab.c: Do not include py-ref.h.
2021         * python/py-type.c: Do not include py-ref.h.
2022         * python/py-unwind.c: Do not include py-ref.h.
2023         * python/py-utils.c: Do not include py-ref.h.
2024         * python/py-value.c: Do not include py-ref.h.
2025         * python/py-varobj.c: Do not include py-ref.h.
2026         * python/py-xmethods.c: Do not include py-ref.h.
2027         * python/python.c: Do not include py-ref.h.
2028         * varobj.c: Do not include py-ref.h.
2029
2030 2019-01-22  Tom Tromey  <tom@tromey.com>
2031
2032         * objfiles.h (struct objfile_per_bfd_storage): Use "struct"
2033         keyword for bcache.
2034
2035 2019-01-22  Tom Tromey  <tom@tromey.com>
2036
2037         * compile/compile-cplus-types.c: Remove a comment by #include.
2038
2039 2019-01-22  Tom Tromey  <tom@tromey.com>
2040
2041         * compile/gcc-c-plugin.h: Include compile-internal.h.
2042
2043 2019-01-22  Tom Tromey  <tom@tromey.com>
2044
2045         * stabsread.c (EXTERN): Do not define.
2046         (symnum, next_symbol_text_func, processing_gcc_compilation)
2047         (within_function, global_sym_chain, global_stabs)
2048         (previous_stab_code, this_object_header_files)
2049         (n_this_object_header_files)
2050         (n_allocated_this_object_header_files): Define.
2051         * stabsread.h (EXTERN): Never define.  Use "extern".
2052
2053 2019-01-22  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
2054
2055         * event-top.c (handle_line_of_input): use unique_xmalloc_ptr for
2056         history_value.
2057
2058 2019-01-21  Tom Tromey  <tom@tromey.com>
2059
2060         * ui-out.c: Fix includes.
2061         * tui/tui-source.c: Fix includes.
2062         * target.c: Fix includes.
2063         * remote.c: Fix includes.
2064         * regcache.c: Fix includes.
2065         * python/py-block.c: Fix includes.
2066         * printcmd.c: Fix includes.
2067         * or1k-tdep.c: Fix includes.
2068         * mi/mi-main.c: Fix includes.
2069         * m32r-tdep.c: Fix includes.
2070         * csky-tdep.c: Fix includes.
2071         * compile/compile-cplus-types.c: Fix includes.
2072         * cli/cli-interp.c: Fix includes.
2073
2074 2019-01-21  Alan Hayward  <alan.hayward@arm.com>
2075
2076         * aarch64-tdep.c (aapcs_is_vfp_call_or_return_candidate_1): Check
2077         for padding.
2078
2079 2019-01-16  Tom Tromey  <tom@tromey.com>
2080
2081         * objfiles.h (struct minimal_symbol_iterator): Rename.  Move
2082         earlier.
2083         (struct objfile) <msymbols_range>: Move from top level.
2084         <msymbols>: New method.
2085         (class objfile_msymbols): Remove.
2086         * symtab.c (default_collect_symbol_completion_matches_break_on):
2087         Update.
2088         * symmisc.c (dump_msymbols): Update.
2089         * stabsread.c (scan_file_globals): Update.
2090         * objc-lang.c (info_selectors_command, info_classes_command)
2091         (find_methods): Update.
2092         * minsyms.c (find_solib_trampoline_target): Update.
2093         * hppa-tdep.c (hppa_lookup_stub_minimal_symbol): Update.
2094         * coffread.c (coff_symfile_read): Update.
2095         * ada-lang.c (ada_lookup_simple_minsym)
2096         (ada_collect_symbol_completion_matches): Update.
2097
2098 2019-01-16  Tom Tromey  <tom@tromey.com>
2099
2100         * objfiles.h (class objfile_msymbols) <iterator>: Change argument
2101         type.  Remove no-argument constructor.
2102         <iterator::operator++>: Simplify.
2103         <begin>: Update.
2104         <end>: Use minimal_symbol_count.
2105
2106 2019-01-16  Tom Tromey  <tom@tromey.com>
2107
2108         * objfiles.h (struct objfile) <psymtabs>: New method.
2109         (class objfile_psymtabs): Remove.
2110         * psymtab.h (class psymtab_storage) <partial_symtab_range>: New
2111         typedef.
2112         <range>: New method.
2113         (require_partial_symbols): Change return type.
2114         * psymtab.c (require_partial_symbols)
2115         (psym_expand_symtabs_matching): Update.
2116         * mdebugread.c (parse_partial_symbols): Update.
2117         * dbxread.c (dbx_end_psymtab): Update.
2118
2119 2019-01-15  Tom Tromey  <tom@tromey.com>
2120
2121         * symtab.c (lookup_objfile_from_block)
2122         (lookup_symbol_in_objfile_symtabs)
2123         (basic_lookup_transparent_type_1, find_pc_sect_compunit_symtab)
2124         (find_line_symtab, info_sources_command)
2125         (default_collect_symbol_completion_matches_break_on)
2126         (make_source_files_completion_list): Update.
2127         * symmisc.c (print_objfile_statistics, dump_objfile)
2128         (maintenance_print_symbols, maintenance_info_symtabs)
2129         (maintenance_check_symtabs, maintenance_info_line_tables):
2130         Update.
2131         * source.c (select_source_symtab)
2132         (forget_cached_source_info_for_objfile): Update.
2133         * objfiles.h (class objfile_compunits): Remove.
2134         (struct objfile) <compunits_range>: New typedef.
2135         (compunits): New method.
2136         * objfiles.c (objfile_relocate1): Update.
2137         * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_files): Update.
2138         * maint.c (count_symtabs_and_blocks): Update.
2139         * linespec.c (iterate_over_all_matching_symtabs): Update.
2140         * cp-support.c (add_symbol_overload_list_qualified): Update.
2141         * coffread.c (coff_symtab_read): Update.
2142         * ada-lang.c (add_nonlocal_symbols)
2143         (ada_collect_symbol_completion_matches)
2144         (ada_add_global_exceptions): Update.
2145
2146 2019-01-15  Tom Tromey  <tom@tromey.com>
2147
2148         * progspace.h (program_space) <objfiles_safe_range>: New
2149         typedef.
2150         <objfiles_safe>: New method.
2151         * objfiles.h (class all_objfiles_safe): Remove.
2152         * objfiles.c (free_all_objfiles, objfile_purge_solibs): Update.
2153         * jit.c (jit_inferior_exit_hook): Update.
2154
2155 2019-01-17  Tom Tromey  <tom@tromey.com>
2156
2157         * progspace.h (program_space) <objfiles_range>: New typedef.
2158         <objfiles>: New method.
2159         <objfiles_head>: Rename from objfiles.
2160         (object_files): Update.
2161         * guile/scm-progspace.c (gdbscm_progspace_objfiles): Update.
2162         * guile/scm-pretty-print.c
2163         (ppscm_find_pretty_printer_from_objfiles): Update.
2164         * guile/scm-objfile.c (gdbscm_objfiles): Update.
2165         * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
2166         Update.
2167         * python/py-progspace.c (pspy_get_objfiles): Update.
2168         * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
2169         Update.
2170         * python/py-objfile.c (objfpy_lookup_objfile_by_name)
2171         (objfpy_lookup_objfile_by_build_id): Update.
2172         * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_files): Update.
2173         * windows-tdep.c (windows_iterate_over_objfiles_in_search_order):
2174         Update.
2175         * symtab.c (iterate_over_symtabs, matching_obj_sections)
2176         (expand_symtab_containing_pc, lookup_objfile_from_block)
2177         (lookup_static_symbol, basic_lookup_transparent_type)
2178         (find_pc_sect_compunit_symtab, find_symbol_at_address)
2179         (find_line_symtab, info_sources_command)
2180         (default_collect_symbol_completion_matches_break_on)
2181         (make_source_files_completion_list, find_main_name): Update.
2182         * symmisc.c (print_symbol_bcache_statistics)
2183         (print_objfile_statistics, maintenance_print_symbols)
2184         (maintenance_print_msymbols, maintenance_print_objfiles)
2185         (maintenance_info_symtabs, maintenance_check_symtabs)
2186         (maintenance_expand_symtabs, maintenance_info_line_tables):
2187         Update.
2188         * symfile.c (remove_symbol_file_command, overlay_invalidate_all)
2189         (find_pc_overlay, find_pc_mapped_section, list_overlays_command)
2190         (map_overlay_command, unmap_overlay_command)
2191         (simple_overlay_update, expand_symtabs_matching)
2192         (map_symbol_filenames): Update.
2193         * symfile-debug.c (set_debug_symfile): Update.
2194         * spu-tdep.c (spu_overlay_update, spu_objfile_from_frame):
2195         Update.
2196         * source.c (select_source_symtab, forget_cached_source_info):
2197         Update.
2198         * solib.c (solib_read_symbols): Update.
2199         * solib-spu.c (append_ocl_sos): Update.
2200         * psymtab.c (maintenance_print_psymbols)
2201         (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
2202         * probe.c (parse_probes_in_pspace, find_probe_by_pc): Update.
2203         * printcmd.c (info_symbol_command): Update.
2204         * ppc-linux-tdep.c (ppc_linux_spe_context_inferior_created):
2205         Update.
2206         * objfiles.h (class all_objfiles): Remove.
2207         * objfiles.c (have_partial_symbols, have_full_symbols)
2208         (have_minimal_symbols, qsort_cmp, update_section_map)
2209         (shared_objfile_contains_address_p)
2210         (default_iterate_over_objfiles_in_search_order): Update.
2211         * objc-lang.c (info_selectors_command, info_classes_command)
2212         (find_methods): Update.
2213         * minsyms.c (find_solib_trampoline_target): Update.
2214         * maint.c (maintenance_info_sections)
2215         (maintenance_translate_address, count_symtabs_and_blocks):
2216         Update.
2217         * main.c (captured_main_1): Update.
2218         * linux-thread-db.c (try_thread_db_load_from_pdir)
2219         (has_libpthread): Update.
2220         * linespec.c (iterate_over_all_matching_symtabs)
2221         (search_minsyms_for_name): Update.
2222         * jit.c (jit_find_objf_with_entry_addr): Update.
2223         * hppa-tdep.c (find_unwind_entry)
2224         (hppa_lookup_stub_minimal_symbol): Update.
2225         * gcore.c (gcore_create_callback, objfile_find_memory_regions):
2226         Update.
2227         * elfread.c (elf_gnu_ifunc_resolve_by_cache)
2228         (elf_gnu_ifunc_resolve_by_got): Update.
2229         * dwarf2-frame.c (dwarf2_frame_find_fde): Update.
2230         * dwarf-index-write.c (save_gdb_index_command): Update.
2231         * cp-support.c (add_symbol_overload_list_qualified): Update.
2232         * breakpoint.c (create_overlay_event_breakpoint)
2233         (create_longjmp_master_breakpoint)
2234         (create_std_terminate_master_breakpoint)
2235         (create_exception_master_breakpoint): Update.
2236         * blockframe.c (find_pc_partial_function): Update.
2237         * ada-lang.c (ada_lookup_simple_minsym, add_nonlocal_symbols)
2238         (ada_collect_symbol_completion_matches)
2239         (ada_add_global_exceptions): Update.
2240
2241 2019-01-17  Tom Tromey  <tom@tromey.com>
2242
2243         * solib-target.c (lm_info_target_p): Remove typedef.  Don't
2244         declare VEC.
2245         (solib_target_parse_libraries): Change return type.
2246         (library_list_start_segment, library_list_start_section)
2247         (library_list_end_library, library_list_start_library); Update.
2248         (solib_target_free_library_list): Remove.
2249         (solib_target_parse_libraries): Remove cleanup.  Change return
2250         type.
2251         (solib_target_current_sos): Update.
2252
2253 2019-01-17  Tom Tromey  <tromey@bapiya>
2254
2255         * valprint.c: Replace "the the" with "the".
2256         * symtab.c: Replace "the the" with "the".
2257         * solib.c: Replace "the the" with "the".
2258         * solib-dsbt.c: Replace "the the" with "the".
2259         * linespec.c: Replace "the the" with "the".
2260         * dwarf2loc.h: Replace "the the" with "the".
2261         * amd64-windows-tdep.c: Replace "the the" with "the".
2262         * aarch64-tdep.c: Replace "the the" with "the".
2263
2264 2019-01-16  Keith Seitz  <keiths@redhat.com>
2265
2266         PR gdb/23773
2267         * dwarf2read.c (dwarf2_cu) <ancestor>: New field.
2268         <builder>: Rename to ..
2269         <m_builder>: ... this and make private.
2270         (dwarf2_cu::get_builder): New method.  Change all users of
2271         `builder' to use this method.
2272         (dwarf2_start_symtab): Move to ...
2273         (dwarf2_cu::start_symtab): ... here.  Update all callers
2274         (setup_type_unit_groups): Move to ...
2275         (dwarf2_cu::setup_type_unit_groups): ... here.  Update all
2276         callers.
2277         (dwarf2_cu::reset_builder): New method.
2278         (process_full_compunit, process_full_type_unit): Use
2279         dwarf2_cu::reset_builder.
2280         (follow_die_offset): Record the ancestor CU if it is different
2281         from the followed DIE's CU.
2282         (follow_die_sig_1): Likewise.
2283
2284 2019-01-15  Tom Tromey  <tom@tromey.com>
2285
2286         * remote.c (class remote_state) <buf>: Now a char_vector.
2287         <buf_size>: Remove.
2288         (remote_target::getpkt): Change type of buf.  Remove sizeof_buf
2289         parameter.
2290         (remote_target::getpkt_or_notif_sane_1)
2291         (remote_target::getpkt_sane)
2292         (remote_target::getpkt_or_notif_sane): Likewise.
2293         (class remote_target) <putpkt>: New overload.
2294         (remote_target::read_frame): Change type of "buf_p".  Remove
2295         sizeof_p parameter.
2296         (packet_ok): New overload.
2297         (packet_check_result): New overload.
2298         Update all uses.
2299
2300 2019-01-14  Tom Tromey  <tom@tromey.com>
2301
2302         * remote-notif.c (handle_notification, remote_notif_ack)
2303         (remote_notif_parse): Make "buf" const.
2304         * remote-notif.h (struct notif_client) <parse, ack>: Make "buf"
2305         const.
2306         (remote_notif_parse, remote_notif_ack, handle_notification):
2307         Likewise.
2308         * remote.c (remote_notif_stop_parse): Make "buf" const.
2309         (remote_target::remote_parse_stop_reply): Make "buf" const.
2310         (remote_notif_stop_ack): Make "buf" const.
2311
2312 2019-01-14  Tom Tromey  <tom@tromey.com>
2313
2314         * remote.c (remote_console_output): Make parameter const.
2315
2316 2019-01-14  Tom Tromey  <tom@tromey.com>
2317
2318         * target-debug.h (target_debug_print_signals): Constify.
2319         * nto-procfs.c (nto_procfs_target::pass_signals): Update.
2320         * procfs.c (procfs_target::pass_signals): Update.
2321         * linux-nat.c (linux_nat_target::pass_signals): Update.
2322         * linux-nat.h (class linux_nat_target) <pass_signals>: Update.
2323         * target-delegates.c: Rebuild.
2324         * remote.c (remote_target::program_signals): Update.
2325         (remote_target::pass_signals): Update.
2326         * target.c (target_pass_signals): Constify argument.
2327         (target_program_signals): Likewise.
2328         * target.h (struct target_ops) <pass_signals, program_signals>:
2329         Constify argument.
2330         (target_pass_signals, target_program_signals): Constify argument.
2331
2332 2019-01-14  Tom Tromey  <tom@tromey.com>
2333
2334         PR tui/28819:
2335         * tui/tui-io.c (gdb_wgetch): Print \r when needed.
2336
2337 2019-01-14  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
2338
2339         * ppc-tdep.h (struct gdbarch_tdep) <ppc_v0_alias_regnum>: New
2340         field.
2341         * rs6000-tdep.c: Include reggroups.h.
2342         (IS_V_ALIAS_PSEUDOREG): Define.
2343         (rs6000_register_name): Return names for the "vX" aliases.
2344         (rs6000_pseudo_register_type): Return type for the "vX" aliases.
2345         (rs6000_pseudo_register_reggroup_p): Restore.  Handle "vX"
2346         aliases.  Call default_register_reggroup_p for all other
2347         pseudo-registers.
2348         (v_alias_pseudo_register_read, v_alias_pseudo_register_write):
2349         New functions.
2350         (rs6000_pseudo_register_read, rs6000_pseudo_register_write):
2351         Handle "vX" aliases.
2352         (v_alias_pseudo_register_collect): New function.
2353         (rs6000_ax_pseudo_register_collect): Handle "vX" aliases.
2354         (rs6000_gdbarch_init): Initialize "vX" aliases as
2355         pseudo-registers.  Restore registration of
2356         rs6000_pseudo_register_reggroup_p with
2357         set_tdesc_pseudo_register_reggroup_p.
2358
2359 2019-01-13  Max Filippov  <jcmvbkbc@gmail.com>
2360
2361         * xtensa-linux-tdep.c (xtensa_linux_init_abi): Update
2362         tdep->num_pseudo_regs. Add calls to set_gdbarch_num_regs and
2363         set_gdbarch_num_pseudo_regs.
2364
2365 2019-01-12  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
2366
2367         * cli/cli-style.h (class cli_style_option): <add_setshow_commands>
2368         Remove arg prefixname, add do_set and do_show.
2369         Add member functions set_list and show_list.
2370         * cli/cli-style.c (class cli_style_option): Update accordingly.
2371         (style_set_list): Move to file scope.
2372         (style_show_list): Likewise.
2373         (set_style): Call help_list.
2374         (show_style): Call cmd_show_list.
2375         (_initialize_cli_style): New macro STYLE_ADD_SETSHOW_COMMANDS.
2376         Update to use the new macro.
2377
2378 2019-10-12  Joel Brobecker  <brobecker@adacore.com>
2379
2380         * ada-lang.c (_initialize_ada_language): Expand the help text
2381         for the "catch exception" command.
2382
2383 2019-01-12  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
2384
2385         * symtab.c (matching_obj_sections): Initialize obj,
2386         declare it closer to its usage.
2387
2388 2019-01-10  Tom Tromey  <tom@tromey.com>
2389
2390         * thread-iter.h (inf_threads_iterator): Use next_iterator.
2391         (basic_inf_threads_range): Remove.
2392         (inf_threads_range, inf_non_exited_threads_range)
2393         (safe_inf_threads_range): Use next_adapter.
2394
2395 2019-01-10  Keith Seitz  <keiths@redhat.com>
2396
2397         PR gdb/23712
2398         PR symtab/23010
2399         * dwarf2read.c (dw2_add_symbol_to_list): Remove.
2400         (fixup_go_packaging, new_symbol): Use add_symbol_to_list.
2401
2402 2019-01-10  Keith Seitz  <keiths@redhat.com>
2403
2404         PR gdb/23712
2405         PR symtab/23010
2406         * dictionary.c (pending_to_vector): Remove.
2407         (dict_create_hashed_1, dict_create_linear_1, dict_add_pending_1):
2408         Remove _1 suffix, replacing functions of the same name.  Update
2409         all callers.
2410         (dict_create_hashed, dict_create_hashed_expandable)
2411         (dict_create_linear, dict_create_linear_expandable, dict_free)
2412         (dict_add_symbol, dict_add_pending, dict_size, dict_empty):
2413         Make functions static.
2414
2415 2019-01-10  Keith Seitz  <keiths@redhat.com>
2416
2417         PR gdb/23712
2418         PR symtab/23010
2419         * dictionary.h (struct dictionary): Replace declaration with
2420         multidictionary.
2421         (dict_create_hashed, dict_create_hashed_expandable)
2422         (dict_create_linear, dict_create_linear_expandable)
2423         (dict_free, dict_add_symbol, dict_add_pending, dict_empty)
2424         (dict_iterator_first, dict_iterator_next, dict_iter_match_first)
2425         (dict_iter_match_next, dict_size): Rename to "mdict_" versions
2426         taking multidictionary argument.
2427         [ALL_DICT_SYMBOLS]: Update for multidictionary.
2428         * block.h (struct block) <dict>: Change to multidictionary
2429         and rename `multidict'.
2430         * block.c, buildsym.c, jit.c, mdebugread.c, objfiles.c,
2431         symmisc.c: Update all dictionary references to multidictionary.
2432
2433 2019-01-10  Keith Seitz  <keiths@redhat.com>
2434
2435         PR gdb/23712
2436         PR symtab/23010
2437         * dictionary.c: Include unordered_map.
2438         (pending_to_vector): New function.
2439         (dict_create_hashed_1, dict_create_linear_1, dict_add_pending_1):
2440         Rewrite the non-"_1" functions to take vector instead
2441         of linked list.
2442         (dict_create_hashed, dict_create_linear, dict_add_pending): Use the
2443         "new" _1 versions of the same name.
2444         (multidictionary): Define.
2445         (std::hash<enum language): New definition.
2446         (collate_pending_symbols_by_language, mdict_create_hashed)
2447         (mdict_create_hashed_expandable, mdict_create_linear)
2448         (mdict_create_linear_expandable, mdict_free)
2449         (find_language_dictionary, create_new_language_dictionary)
2450         (mdict_add_symbol, mdict_add_pending, mdict_iterator_first)
2451         (mdict_iterator_next, mdict_iter_match_first, mdict_iter_match_next)
2452         (mdict_size, mdict_empty): New functions.
2453         * dictionary.h (mdict_iterator): Define.
2454
2455 2019-01-10  Pedro Alves  <palves@redhat.com>
2456
2457         * breakpoint.c (read_uploaded_action)
2458         (create_tracepoint_from_upload): Adjust to use
2459         gdb::unique_xmalloc_ptr.
2460         * ctf.c (ctf_write_uploaded_tp):
2461         (SET_ARRAY_FIELD): Use emplace_back.
2462         (SET_STRING_FIELD): Adjust to use gdb::unique_xmalloc_ptr.
2463         * tracefile-tfile.c (tfile_write_uploaded_tp):
2464         * tracepoint.c (parse_tracepoint_definition): Adjust to use
2465         gdb::unique_xmalloc_ptr.
2466         * tracepoint.h (struct uploaded_tp) <cond, actions, step_actions,
2467         at_string, cond_string, cmd_strings>: Replace char pointers
2468         with gdb::unique_xmalloc_ptr.
2469
2470 2019-01-10  Pedro Alves  <palves@redhat.com>
2471
2472         * solib-target.c (library_list_start_library): Don't xstrdup name.
2473
2474 2019-01-10  Pedro Alves  <palves@redhat.com>
2475
2476         * mdebugread.c (parse_partial_symbols): Use
2477         gdb::unique_xmalloc_ptr to manage heap-allocated 'stabsstring'.
2478
2479 2019-01-10  Andrew Burgess  <andrew.burgess@embecosm.com>
2480
2481         * linux-fork.c (scoped_switch_fork_info)
2482         <~scoped_switch_fork_info>: Fix incorrect variable name.
2483
2484 2019-01-10  Andrew Burgess  <andrew.burgess@embecosm.com>
2485
2486         * linux-fork.c (scoped_switch_fork_info)
2487         <scoped_switch_fork_info>: Make explicit.
2488         <~scoped_switch_fork_info>: Wrap core in TRY/CATCH.
2489
2490 2019-01-10  Tom Tromey  <tom@tromey.com>
2491
2492         * objfiles.h (objfile::reset_psymtabs): Update.
2493         * objfiles.c (objfile::objfile): Update.
2494         * psymtab.h (psymtab_storage::obstack): Update.
2495         (psymtab_storage::m_obstack): Use gdb::optional.
2496         (class psymtab_storage): Update comment.  Remove objfile
2497         parameter.
2498         * psymtab.c (psymtab_storage::psymtab_storage): Update.
2499
2500 2019-01-10  Tom Tromey  <tom@tromey.com>
2501
2502         * psymtab.h (psymtab_storage::allocate_psymtab): New method.
2503         <free_psymtabs>: Now private.
2504         * psymtab.c (psymtab_storage::allocate_psymtab): Implement.
2505         (allocate_psymtab): Use new method.
2506
2507 2019-01-10  Tom Tromey  <tom@tromey.com>
2508
2509         * xcoffread.c (xcoff_end_psymtab): Use allocate_dependencies.
2510         * psymtab.h (psymtab_storage::allocate_dependencies): New method.
2511         * mdebugread.c (parse_partial_symbols): Use
2512         allocate_dependencies.
2513         * dwarf2read.c (dwarf2_create_include_psymtab): Use
2514         allocate_dependencies.
2515         (process_psymtab_comp_unit_reader)
2516         (build_type_psymtab_dependencies): Likewise.
2517         * dbxread.c (dbx_end_psymtab): Use allocate_dependencies.
2518
2519 2019-01-10  Tom Tromey  <tom@tromey.com>
2520
2521         * psymtab.c (add_psymbol_to_bcache): Pass psymtab obstack to
2522         PSYMBOL_SET_LANGUAGE.
2523         (allocate_psymtab): Allocate psymtab on the psymtab obstack.
2524
2525 2019-01-10  Tom Tromey  <tom@tromey.com>
2526
2527         * psymtab.h (psymtab_storage::obstack): New method.
2528         <m_obstack>: Rename from obstack; now private.
2529         * psymtab.c (psymtab_storage): Update.
2530         * dwarf2read.c (create_addrmap_from_index)
2531         (create_addrmap_from_aranges, dwarf2_build_psymtabs_hard):
2532         Update.
2533
2534 2019-01-10  Tom Tromey  <tom@tromey.com>
2535
2536         * symfile.c (reread_symbols): Call objfile->reset_psymtabs.
2537         * objfiles.h (objfile::reset_psymtabs): New method.
2538
2539 2019-01-10  Tom Tromey  <tom@tromey.com>
2540
2541         * symmisc.c (print_symbol_bcache_statistics): Update.
2542         (print_objfile_statistics): Update.
2543         * symfile.c (reread_symbols): Update.
2544         * psymtab.h (class psymtab_storage): New.
2545         * psymtab.c (psymtab_storage): New constructor.
2546         (~psymtab_storage): New destructor.
2547         (require_partial_symbols): Update.
2548         (ALL_OBJFILE_PSYMTABS_REQUIRED): Rewrite.
2549         (find_pc_sect_psymtab, find_pc_sect_psymbol)
2550         (match_partial_symbol, lookup_partial_symbol, dump_psymtab)
2551         (psym_dump, recursively_search_psymtabs, psym_has_symbols)
2552         (psym_find_compunit_symtab_by_address, sort_pst_symbols)
2553         (start_psymtab_common, end_psymtab_common)
2554         (add_psymbol_to_bcache, add_psymbol_to_list, init_psymbol_list)
2555         (allocate_psymtab): Update.
2556         (psymtab_storage::discard_psymtab): Rename from discard_psymtab.
2557         Update.
2558         (dump_psymtab_addrmap, maintenance_print_psymbols)
2559         (maintenance_check_psymtabs): Update.
2560         (class objfile_psymtabs): Move to objfiles.h.
2561         * psympriv.h (discard_psymtab): Now inline.
2562         (psymtab_discarder::psymtab_discarder): Update.
2563         (psymtab_discarder::~psymtab_discarder): Update.
2564         (ALL_OBJFILE_PSYMTABS): Rewrite.
2565         * objfiles.h (struct objfile) <psymtabs, psymtabs_addrmap,
2566         free_psymtabs, psymbol_cache, global_psymbols, static_psymbols>:
2567         Remove fields.
2568         <partial_symtabs>: New field.
2569         (class objfile_psymtabs): Move from psymtab.h.  Update.
2570         * objfiles.c (objfile::objfile): Initialize partial_symtabs, not
2571         psymbol_cache.
2572         (objfile::~objfile): Don't destroy psymbol_cache.
2573         * mdebugread.c (parse_partial_symbols): Update.
2574         * dwarf2read.c (create_addrmap_from_index)
2575         (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
2576         (process_psymtab_comp_unit_reader, dwarf2_build_psymtabs_hard)
2577         (add_partial_subprogram, dwarf2_ranges_read): Update.
2578         * dwarf-index-write.c (write_address_map)
2579         (write_one_signatured_type, recursively_write_psymbols)
2580         (class debug_names, class debug_names, write_psymtabs_to_index):
2581         Update.
2582
2583 2019-01-10  Tom Tromey  <tom@tromey.com>
2584
2585         * symtab.h (SYMBOL_SET_NAMES): Update.
2586         (symbol_set_names): Update.
2587         (MSYMBOL_SET_NAMES): Update.
2588         * symtab.c (symbol_set_names): Change argument to be an
2589         objfile_per_bfd_storage.
2590         * psymtab.c (add_psymbol_to_bcache): Update.
2591         * psympriv.h (PSYMBOL_SET_NAMES): Take per_bfd argument.
2592
2593 2019-01-10  Tom Tromey  <tom@tromey.com>
2594
2595         * symtab.c (create_demangled_names_hash): Change argument to be an
2596         objfile_per_bfd_storage.
2597         (symbol_set_names): Update.
2598
2599 2019-01-10  Tom Tromey  <tom@tromey.com>
2600
2601         * xcoffread.c (xcoff_initial_scan): Unconditionally call
2602         init_psymbol_list.
2603         * psymtab.c (init_psymbol_list): Do nothing if already called.
2604         * psympriv.h (init_psymbol_list): Add comment.
2605         * dwarf2read.c (dwarf2_build_psymtabs): Unconditionally call
2606         init_psymbol_list.
2607         * dbxread.c (dbx_symfile_read): Unconditionally call
2608         init_psymbol_list.
2609
2610 2019-01-10  Tom Tromey  <tom@tromey.com>
2611
2612         * xcoffread.c (scan_xcoff_symtab): Update.
2613         * psymtab.c (add_psymbol_to_list): Replace "list" parameter with
2614         "where".
2615         * mdebugread.c (parse_partial_symbols)
2616         (handle_psymbol_enumerators): Update.
2617         * dwarf2read.c (add_partial_symbol, load_partial_dies): Update.
2618         * dbxread.c (read_dbx_symtab): Update.
2619         * psympriv.h (psymbol_placement): New enum.
2620         (add_psymbol_to_list): Update.
2621
2622 2019-01-10  Tom Tromey  <tom@tromey.com>
2623
2624         * xcoffread.c (xcoff_start_psymtab): Remove global_psymbols and
2625         static_psymbols parameters.
2626         (scan_xcoff_symtab): Update.
2627         * psymtab.c (start_psymtab_common): Remove global_psymbols and
2628         static_psymbols parameters.
2629         * psympriv.h (start_psymtab_common): Update.
2630         * mdebugread.c (parse_partial_symbols): Update.
2631         * dwarf2read.c (create_partial_symtab): Update.
2632         * dbxread.c (read_dbx_symtab): Update.
2633         (start_psymtab): Remove global_psymbols and static_psymbols
2634         parameters.
2635
2636 2019-01-10  Tom Tromey  <tom@tromey.com>
2637
2638         * xcoffread.c (xcoff_end_psymtab): Remove some initializations.
2639         * psymtab.c (allocate_psymtab): Add comment.
2640         * psympriv.h (allocate_psymtab): Add comment.
2641         * dwarf2read.c (dwarf2_create_include_psymtab): Remove some
2642         initializations.
2643         * dbxread.c (dbx_end_psymtab): Remove some initializations.
2644
2645 2019-01-10  Tom Tromey  <tom@tromey.com>
2646
2647         * symfile.h (mdebug_build_psymtabs, elfmdebug_build_psymtabs):
2648         Don't declare.
2649         * mipsread.c: Include mdebugread.h.
2650         * mdebugread.h (mdebug_build_psymtabs, elfmdebug_build_psymtabs):
2651         Declare.
2652         * elfread.c: Include mdebugread.h.
2653
2654 2019-01-09  Tom Tromey  <tom@tromey.com>
2655
2656         * dbxread.c (dbx_end_psymtab): Use objfile_psymtabs.
2657         * mdebugread.c (parse_partial_symbols): Use objfile_psymtabs.
2658         * psymtab.c (ALL_OBJFILE_PSYMTABS_REQUIRED): Remove.
2659         (psym_map_symtabs_matching_filename, find_pc_sect_psymtab)
2660         (psym_lookup_symbol, psym_find_last_source_symtab)
2661         (psym_forget_cached_source_info, psym_print_stats)
2662         (psym_expand_symtabs_for_function, psym_expand_all_symtabs)
2663         (psym_expand_symtabs_with_fullname, psym_map_symbol_filenames)
2664         (psym_map_matching_symbols, psym_expand_symtabs_matching)
2665         (psym_find_compunit_symtab_by_address)
2666         (maintenance_print_psymbols, maintenance_info_psymtabs)
2667         (maintenance_check_psymtabs): Use ranged for.
2668         * psymtab.h (class objfile_psymtabs): New.
2669         (require_partial_symbols): Return objfile_psymtabs.
2670         * psympriv.h (ALL_OBJFILE_PSYMTABS): Remove.
2671
2672 2019-01-09  Tom Tromey  <tom@tromey.com>
2673
2674         * symfile.c (overlay_invalidate_all, find_pc_overlay)
2675         (find_pc_mapped_section, list_overlays_command)
2676         (map_overlay_command, unmap_overlay_command)
2677         (simple_overlay_update): Use all_objfiles.
2678         * spu-tdep.c (spu_overlay_update): Use all_objfiles.
2679         * printcmd.c (info_symbol_command): Use all_objfiles.
2680         * objfiles.h (ALL_OBJSECTIONS): Remove.
2681         * maint.c (maintenance_translate_address): Use all_objfiles.
2682         * gcore.c (gcore_create_callback): Use all_objfiles.
2683         (objfile_find_memory_regions): Likewise.
2684
2685 2019-01-09  Tom Tromey  <tom@tromey.com>
2686
2687         * symtab.c (find_line_symtab, info_sources_command)
2688         (make_source_files_completion_list): Use objfile_compunits.
2689         * source.c (select_source_symtab): Use objfile_compunits.
2690         * objfiles.h (struct objfile): Update comment.
2691         (ALL_OBJFILES): Remove.
2692         (ALL_FILETABS): Remove.
2693         * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_files): Use
2694         objfile_compunits.
2695
2696 2019-01-09  Tom Tromey  <tom@tromey.com>
2697
2698         * symmisc.c (print_objfile_statistics, dump_objfile)
2699         (maintenance_print_symbols): Use compunit_filetabs.
2700         * source.c (forget_cached_source_info_for_objfile): Use
2701         compunit_filetabs.
2702         * objfiles.h (ALL_OBJFILE_FILETABS): Remove.
2703         (ALL_FILETABS): Use compunit_filetabs.
2704         * objfiles.c (objfile_relocate1): Use compunit_filetabs.
2705         * coffread.c (coff_symtab_read): Use compunit_filetabs.
2706
2707 2019-01-09  Tom Tromey  <tom@tromey.com>
2708
2709         * symtab.h (ALL_COMPUNIT_FILETABS): Remove.
2710         (compunit_filetabs): New.
2711         * symtab.c (iterate_over_some_symtabs, find_pc_sect_line): Use
2712         compunit_filetabs.
2713         (info_sources_command, make_source_files_completion_list): Remove
2714         declaration.
2715         * symmisc.c (print_objfile_statistics, dump_objfile)
2716         (maintenance_print_symbols): Remove declaration.
2717         (maintenance_info_symtabs): Use compunit_filetabs.
2718         (maintenance_info_line_tables): Likewise.
2719         * source.c (select_source_symtab): Change local variable name.
2720         (forget_cached_source_info_for_objfile): Remove declaration.
2721         * objfiles.h (ALL_OBJFILE_FILETABS): Use compunit_filetabs.
2722         * objfiles.c (objfile_relocate1): Remove declaration.
2723         * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_files): Remove
2724         declaration.
2725         * maint.c (count_symtabs_and_blocks): Use compunit_filetabs.
2726         * coffread.c (coff_symtab_read): Remove declaration.
2727         * buildsym.c (buildsym_compunit::end_symtab_with_blockvector): Use
2728         compunit_filetabs.
2729
2730 2019-01-09  Tom Tromey  <tom@tromey.com>
2731
2732         * symtab.c (lookup_objfile_from_block)
2733         (find_pc_sect_compunit_symtab, search_symbols)
2734         (default_collect_symbol_completion_matches_break_on): Use
2735         objfile_compunits.
2736         * objfiles.h (ALL_COMPUNITS): Remove.
2737         * maint.c (count_symtabs_and_blocks): Use objfile_compunits.
2738         * cp-support.c (add_symbol_overload_list_qualified): Use
2739         objfile_compunits.
2740         * ada-lang.c (ada_collect_symbol_completion_matches)
2741         (ada_add_global_exceptions): Use objfile_compunits.
2742
2743 2019-01-09  Tom Tromey  <tom@tromey.com>
2744
2745         * source.c (select_source_symtab)
2746         (forget_cached_source_info_for_objfile): Remove declaration.
2747         * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_files): Remove
2748         declaration.
2749         * maint.c (count_symtabs_and_blocks): Remove declaration.
2750         * cp-support.c (add_symbol_overload_list_qualified): Remove
2751         declaration.
2752         * coffread.c (coff_symtab_read): Remove declaration.
2753         * symtab.c (lookup_symbol_in_objfile_symtabs)
2754         (basic_lookup_transparent_type_1): Use objfile_compunits.
2755         (lookup_objfile_from_block, find_pc_sect_compunit_symtab)
2756         (info_sources_command, search_symbols)
2757         (default_collect_symbol_completion_matches_break_on)
2758         (make_source_files_completion_list): Remove declaration.
2759         * ada-lang.c (add_nonlocal_symbols): Use objfile_compunits.
2760         (ada_collect_symbol_completion_matches)
2761         (ada_add_global_exceptions): Remove declaration.
2762         * linespec.c (iterate_over_all_matching_symtabs): Use
2763         objfile_compunits.
2764         * objfiles.h (ALL_OBJFILE_COMPUNITS): Remove.
2765         (class objfile_compunits): New.
2766         (ALL_COMPUNITS): Use objfile_compunits.
2767         * symmisc.c (print_objfile_statistics, maintenance_info_symtabs)
2768         (maintenance_check_symtabs, maintenance_info_line_tables): Use
2769         objfile_compunits.
2770         * objfiles.c (objfile_relocate1): Use objfile_compunits.
2771
2772 2019-01-09  Tom Tromey  <tom@tromey.com>
2773
2774         * symtab.c (search_symbols)
2775         (default_collect_symbol_completion_matches_break_on): Use
2776         objfile_msymbols.
2777         * ada-lang.c (ada_lookup_simple_minsym)
2778         (ada_collect_symbol_completion_matches): Use objfile_msymbols.
2779         * minsyms.c (find_solib_trampoline_target): Use objfile_msymbols.
2780         * hppa-tdep.c (hppa_lookup_stub_minimal_symbol): Use
2781         objfile_msymbols.
2782         * coffread.c (coff_symfile_read): Use objfile_msymbols.
2783         * symmisc.c (dump_msymbols): Use objfile_msymbols.
2784         * objc-lang.c (find_methods): Use objfile_msymbols.
2785         (info_selectors_command, info_classes_command): Likewise.
2786         * stabsread.c (scan_file_globals): Use objfile_msymbols.
2787         * objfiles.h (class objfile_msymbols): New.
2788         (ALL_OBJFILE_MSYMBOLS): Remove.
2789         (ALL_MSYMBOLS): Remove.
2790
2791 2019-01-09  Tom Tromey  <tom@tromey.com>
2792
2793         * common/next-iterator.h (next_adapter): Add Iterator template
2794         parameter.
2795         * objfiles.h (ALL_OBJFILES_SAFE): Remove.
2796         (class all_objfiles_safe): New.
2797         * jit.c (jit_inferior_exit_hook): Use all_objfiles_safe.
2798         * objfiles.c (put_objfile_before): Update comment.
2799         (add_separate_debug_objfile): Likewise.
2800         (free_all_objfiles): Use all_objfiles_safe.
2801         (objfile_purge_solibs): Likewise.
2802
2803 2019-01-09  Tom Tromey  <tom@tromey.com>
2804
2805         * symtab.c (iterate_over_symtabs, matching_obj_sections)
2806         (expand_symtab_containing_pc, lookup_static_symbol)
2807         (basic_lookup_transparent_type, find_pc_sect_compunit_symtab)
2808         (find_symbol_at_address, find_line_symtab, find_main_name): Use
2809         all_objfiles.
2810         * probe.c (find_probe_by_pc, collect_probes): Use all_objfiles.
2811         * breakpoint.c (create_overlay_event_breakpoint)
2812         (create_longjmp_master_breakpoint)
2813         (create_std_terminate_master_breakpoint)
2814         (create_exception_master_breakpoint): Use all_objfiles.
2815         * linux-thread-db.c (try_thread_db_load_from_pdir)
2816         (has_libpthread): Use all_objfiles.
2817         * ada-lang.c (add_nonlocal_symbols): Use all_objfiles.
2818         * linespec.c (iterate_over_all_matching_symtabs)
2819         (search_minsyms_for_name): Use all_objfiles.
2820         * maint.c (maintenance_info_sections): Use all_objfiles.
2821         * main.c (captured_main_1): Use all_objfiles.
2822         * spu-tdep.c (spu_objfile_from_frame): Use all_objfiles.
2823         * guile/scm-objfile.c (gdbscm_objfiles): Use all_objfiles.
2824         * guile/scm-pretty-print.c
2825         (ppscm_find_pretty_printer_from_objfiles): Use all_objfiles.
2826         * solib-spu.c (append_ocl_sos): Use all_objfiles.
2827         * symmisc.c (maintenance_print_symbols): Use all_objfiles.
2828         (maintenance_print_msymbols): Use all_objfiles.
2829         * source.c (select_source_symtab): Use all_objfiles.
2830         * jit.c (jit_find_objf_with_entry_addr): Use all_objfiles.
2831         * symfile.c (remove_symbol_file_command)
2832         (expand_symtabs_matching, map_symbol_filenames): Use
2833         all_objfiles.
2834         * ppc-linux-tdep.c (ppc_linux_spe_context_inferior_created): Use
2835         all_objfiles.
2836         * dwarf2-frame.c (dwarf2_frame_find_fde): Use all_objfiles.
2837         * objc-lang.c (find_methods): Use all_objfiles.
2838         * objfiles.c (have_partial_symbols, have_full_symbols)
2839         (have_minimal_symbols, qsort_cmp)
2840         (default_iterate_over_objfiles_in_search_order): Use
2841         all_objfiles.
2842         * hppa-tdep.c (find_unwind_entry): Use all_objfiles.
2843         * psymtab.c (maintenance_print_psymbols): Use all_objfiles.
2844         (maintenance_check_psymtabs): Use all_objfiles.
2845         (ALL_PSYMTABS): Remove.
2846         * compile/compile-object-run.c (do_module_cleanup): Use
2847         all_objfiles.
2848         * blockframe.c (find_pc_partial_function): Use all_objfiles.
2849         * cp-support.c (add_symbol_overload_list_qualified): Use
2850         all_objfiles.
2851         * windows-tdep.c (windows_iterate_over_objfiles_in_search_order):
2852         Use all_objfiles.
2853         * dwarf-index-write.c (save_gdb_index_command): Use all_objfiles.
2854         * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): Use
2855         all_objfiles.
2856         * python/py-objfile.c (objfpy_lookup_objfile_by_name)
2857         (objfpy_lookup_objfile_by_build_id): Use all_objfiles.
2858         * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
2859         Uses all_objfiles.
2860         * solib.c (solib_read_symbols): Use all_objfiles
2861
2862 2019-01-09  Tom Tromey  <tom@tromey.com>
2863
2864         * probe.c (parse_probes_in_pspace): Use all_objfiles.
2865         * guile/scm-progspace.c (gdbscm_progspace_objfiles): Use
2866         all_objfiles.
2867         * objfiles.h (ALL_PSPACE_OBJFILES): Remove.
2868         * symmisc.c (print_symbol_bcache_statistics)
2869         (print_objfile_statistics, maintenance_print_objfiles)
2870         (maintenance_info_symtabs, maintenance_check_symtabs)
2871         (maintenance_expand_symtabs, maintenance_info_line_tables): Use
2872         all_objfiles.
2873         * source.c (forget_cached_source_info): Use all_objfiles.
2874         * symfile-debug.c (set_debug_symfile): Use all_objfiles.
2875         * elfread.c (elf_gnu_ifunc_resolve_by_cache)
2876         (elf_gnu_ifunc_resolve_by_got): Use all_objfiles.
2877         * objfiles.c (update_section_map): Use all_objfiles.
2878         (shared_objfile_contains_address_p): Likewise.
2879         * psymtab.c (maintenance_info_psymtabs): Use all_objfiles.
2880         * python/py-progspace.c (pspy_get_objfiles): Use all_objfiles.
2881
2882 2019-01-09  Tom Tromey  <tom@tromey.com>
2883
2884         * common/next-iterator.h: New file.
2885         * objfiles.h (class all_objfiles): New.
2886         (struct objfile_iterator): New.
2887
2888 2019-01-09  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
2889
2890         * NEWS: Move the description of the changed "frame", "select-frame",
2891          and "info frame" commands to the Changed commands section.
2892
2893 2019-01-09  Simon Marchi  <simon.marchi@ericsson.com>
2894
2895         * gdbtypes.c (check_stub_method_group): Remove handling of old
2896         mangling schemes.
2897         * linespec.c (find_methods): Likewise.
2898         * stabsread.c (read_member_functions): Likewise.
2899         * valops.c (search_struct_method): Likewise.
2900         (value_struct_elt_for_reference): Likewise.
2901         * NEWS: Mention this change.
2902
2903 2019-01-09  Andrew Burgess  <andrew.burgess@embecosm.com>
2904
2905         * cli/cli-cmds.c (list_command): Pass a source_lines_range to
2906         print_source_lines.
2907         * source.c (print_source_lines_base): Update line number check.
2908         (print_source_lines): New function.
2909         (source_lines_range::source_lines_range): New function.
2910         * source.h (class source_lines_range): New class.
2911         (print_source_lines): New declaration.
2912
2913 2019-01-09  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
2914
2915         * linespec.c (linespec_state_destructor): Free self->canonical_names.
2916
2917 2019-01-08  Tom Tromey  <tom@tromey.com>
2918             Simon Marchi  <simon.marchi@ericsson.com>
2919
2920         PR gdb/24060
2921         * ada-exp.y (DOLLAR_VARIABLE): Rename from SPECIAL_VARIABLE.
2922         * ada-lex.l (DOLLAR_VARIABLE): Likewise.
2923         * c-exp.y (DOLLAR_VARIABLE): Rename from VARIABLE.
2924         * f-exp.y (DOLLAR_VARIABLE): Likewise.
2925         * m2-exp.y (DOLLAR_VARIABLE): Rename from INTERNAL_VAR.
2926         * p-exp.y (DOLLAR_VARIABLE): Rename from VARIABLE.
2927
2928 2019-01-08  Andrew Burgess  <andrew.burgess@embecosm.com>
2929
2930         * source.c (select_source_symtab): Move header comment to
2931         declaration in source.h.
2932         (forget_cached_source_info_for_objfile): Likewise.
2933         (forget_cached_source_info): Likewise.
2934         (identify_source_line): Likewise.
2935         * source.h (identify_source_line): Move declaration from symtab.h
2936         and add comment from source.c
2937         (print_source_lines): Likewise.
2938         (forget_cached_source_info_for_objfile): Likewise.
2939         (forget_cached_source_info): Likewise.
2940         (select_source_symtab): Likewise.
2941         (enum print_source_lines_flag): Move definition from symtab.h.
2942         * symtab.h (identify_source_line): Move declaration to source.h.
2943         (print_source_lines): Likewise.
2944         (forget_cached_source_info_for_objfile): Likewise.
2945         (forget_cached_source_info): Likewise.
2946         (select_source_symtab): Likewise.
2947         (enum print_source_lines_flag): Move definition to source.h.
2948         * tui/tui-hooks.c: Add 'source.h' include.
2949
2950 2019-01-08  Andrew Burgess  <andrew.burgess@embecosm.com>
2951
2952         * source.c (print_source_lines_base): Handle requests to print
2953         reverse line number sequences, and guard against empty lines
2954         string.
2955
2956 2019-01-08  Andrew Burgess  <andrew.burgess@embecosm.com>
2957
2958         * source.c (print_source_lines_base): Fix skip of '\r' if next
2959         character is '\n'.
2960
2961 2019-01-06  Tom Tromey  <tom@tromey.com>
2962
2963         * c-exp.y (struct c_parse_state) <macro_original_text,
2964         expansion_obstack>: New member.
2965         (macro_original_text, expansion_obstack): Remove globals.
2966         (scan_macro_expansion, scanning_macro_expansion)
2967         (finished_macro_expansion): Update.
2968         (scan_macro_cleanup): Remove.
2969         (yylex, c_parse): Update.
2970
2971 2019-01-06  Tom Tromey  <tom@tromey.com>
2972
2973         * c-exp.y (struct c_parse_state) <strings>: New member.
2974         (operator_stoken): Update.
2975
2976 2019-01-06  Tom Tromey  <tom@tromey.com>
2977
2978         * parser-defs.h (type_ptr): Remove typedef.  Don't declare VEC.
2979         (union type_stack_elt) <typelist_val>: Now a pointer to
2980         std::vector.
2981         (type_stack_cleanup): Don't declare.
2982         (push_typelist): Update.
2983         * parse.c (pop_typelist): Return a std::vector.
2984         (push_typelist): Take a std::vector.
2985         (follow_types): Update.  Do not free args.
2986         (type_stack_cleanup): Remove.
2987         * c-exp.y (struct c_parse_state): New.
2988         (cpstate): New global.
2989         (type_aggregate_p, exp, ptr_operator, parameter_typelist)
2990         (nonempty_typelist): Update.
2991         (func_mod): Create a new vector.
2992         (c_parse): Create a c_parse_state.
2993         (check_parameter_typelist): Do not delete params.
2994         (function_method): Update.  Do not delete type_list.
2995
2996 2019-01-06  Tom Tromey  <tom@tromey.com>
2997
2998         PR gdb/28155:
2999         * python/py-finishbreakpoint.c (bpfinishpy_init): Use
3000         check_typedef.
3001         * infcmd.c (finish_command_fsm_should_stop): Use check_typedef.
3002         (print_return_value): Likewise.
3003
3004 2019-01-05  Tom Tromey  <tom@tromey.com>
3005
3006         * contrib/cleanup_check.py: Remove.
3007         * contrib/gcc-with-excheck: Remove.
3008         * contrib/exsummary.py: Remove.
3009         * contrib/excheck.py: Remove.
3010
3011 2019-01-05  Joel Brobecker  <brobecker@adacore.com>
3012
3013         * thread.c (delete_thread_1): Add gdb_assert that THR is not
3014         NULL. Initialize tpprev to NULL instead of assigning it
3015         to NULL on the next statement.
3016         * windows-nat.c (windows_delete_thread): Remove check for
3017         main_thread_id before printing thread exit notifications.
3018         (get_windows_debug_event) <EXIT_THREAD_DEBUG_EVENT>:
3019         Remove thread ID check against main_thread_id.
3020         <CREATE_PROCESS_DEBUG_EVENT>: Remove call to
3021         windows_delete_thread.
3022         <EXIT_PROCESS_DEBUG_EVENT>: Add call to windows_delete_thread.
3023
3024 2019-01-04  Tom Tromey  <tom@tromey.com>
3025
3026         * compile/compile.c (_initialize_compile): Use upper case for
3027         metasyntactic variables.
3028         * symmisc.c (_initialize_symmisc): Use upper case for
3029         metasyntactic variables.
3030         * psymtab.c (_initialize_psymtab): Use upper case for
3031         metasyntactic variables.
3032         * demangle.c (demangle_command): Use upper case for metasyntactic
3033         variables.
3034         (_initialize_demangler): Likewise.
3035         * ax-gdb.c (_initialize_ax_gdb): Use upper case for metasyntactic
3036         variables.
3037
3038 2019-01-03  Tom Tromey  <tom@tromey.com>
3039
3040         * tui/tui-source.c (tui_set_source_content): Use xstrdup.
3041
3042 2019-01-03  Tom Tromey  <tom@tromey.com>
3043
3044         * python/py-symtab.c (salpy_str): Update.
3045         (struct salpy_sal_object) <symtab>: Now a PyObject.
3046         (salpy_dealloc): Update.
3047         (del_objfile_sal): Use gdbpy_ref.
3048
3049 2019-01-03  Tom Tromey  <tom@tromey.com>
3050
3051         * python/py-type.c (convert_field): Use new_reference.  Return
3052         gdbpy_ref.
3053         (make_fielditem): Return gdbpy_ref.
3054         (typy_fields): Update.
3055         (typy_getitem): Update.
3056         (field_name): Return gdbpy_ref.  Use new_reference.
3057         (typy_iterator_iternext): Update.
3058
3059 2019-01-03  Tom Tromey  <tom@tromey.com>
3060
3061         * python/py-record.c (gdbpy_stop_recording): Use Py_RETURN_NONE.
3062
3063 2019-01-03  Tom Tromey  <tom@tromey.com>
3064
3065         * python/py-value.c (valpy_dealloc): Use Py_XDECREF.
3066         * python/py-type.c (typy_fields_items): Use gdbpy_ref.
3067         * python/py-progspace.c (pspy_set_printers): Use gdbpy_ref.
3068         (pspy_set_frame_filters, pspy_set_frame_unwinders)
3069         (pspy_set_type_printers): Likewise.
3070         * python/py-function.c (fnpy_init): Use gdbpy_ref.
3071         * python/py-cmd.c (cmdpy_init): Use gdbpy_ref.
3072         * python/py-objfile.c (objfpy_set_printers): Use gdbpy_ref.
3073         (objfpy_set_frame_filters, objfpy_set_frame_unwinders)
3074         (objfpy_set_type_printers): Likewise.
3075
3076 2019-01-03  Tom Tromey  <tom@tromey.com>
3077
3078         * python/python.c (gdbpy_enter, ~gdbpy_enter): Update.
3079         (gdbpy_print_stack): Use gdbpy_err_fetch.
3080         * python/python-internal.h (class gdbpy_err_fetch): New class.
3081         (class gdbpy_enter) <m_error_type, m_error_value,
3082         m_error_traceback>: Remove.
3083         <m_error>: New member.
3084         (gdbpy_exception_to_string): Don't declare.
3085         * python/py-varobj.c (py_varobj_iter_next): Use gdbpy_err_fetch.
3086         * python/py-value.c (convert_value_from_python): Use
3087         gdbpy_err_fetch.
3088         * python/py-utils.c (gdbpy_err_fetch::to_string): Rename from
3089         gdbpy_exception_to_string.
3090         (gdbpy_handle_exception): Use gdbpy_err_fetch.
3091         * python/py-prettyprint.c (print_stack_unless_memory_error): Use
3092         gdbpy_err_fetch.
3093
3094 2019-01-03  Andrew Burgess  <andrew.burgess@embecosm.com>
3095
3096         * linux-nat.c (delete_lwp_cleanup): Delete.
3097         (struct lwp_deleter): New struct.
3098         (lwp_info_up): New typedef.
3099         (linux_nat_target::follow_fork): Delete cleanup, and make use of
3100         lwp_info_up.
3101
3102 2019-01-03  Andrew Burgess  <andrew.burgess@embecosm.com>
3103
3104         * linux-fork.c (class scoped_switch_fork_info): New class.
3105         (inferior_call_waitpid): Update to use scoped_switch_fork_info.
3106
3107 2019-01-03  Andrew Burgess  <andrew.burgess@embecosm.com>
3108
3109         * valops.c (find_overload_match): Remove use of null_cleanup, and
3110         calls to do_cleanups.
3111
3112 2019-01-03  Andrew Burgess  <andrew.burgess@embecosm.com>
3113
3114         * compile/compile-cplus-types.c
3115         (compile_cplus_instance::decl_name): Handle changes to
3116         cp_func_name.
3117         * cp-support.c (cp_func_name): Update header comment, update
3118         return type.
3119         * cp-support.h (cp_func_name): Update return type in declaration.
3120         * valops.c (find_overload_match): Move temp_func local to top
3121         level of function and change its type.  Use temp_func to hold and
3122         delete temporary string obtained from cp_func_name.
3123
3124 2019-01-03  Andrew Burgess  <andrew.burgess@embecosm.com>
3125
3126         * remote.c (remote_target::remote_check_symbols): Convert `msg` to
3127         gdb::char_vector, remove cleanup, and update uses of `msg`.
3128
3129 2019-01-03  Jim Wilson  <jimw@sifive.com>
3130
3131         * riscv-tdep.c (riscv_freg_feature): Drop s0 name from f8.
3132
3133 2019-01-02  Tom Tromey  <tom@tromey.com>
3134
3135         * xml-tdesc.c (xml_cache): Hold a target_desc_up.
3136         (tdesc_parse_xml): Remove cleanups.
3137         * target-descriptions.h (make_cleanup_free_target_description):
3138         Don't declare.
3139         (target_desc_deleter): New struct.
3140         (target_desc_up): New typedef.
3141         * target-descriptions.c (target_desc_deleter::operator()): Rename
3142         from free_target_description.
3143         (make_cleanup_free_target_description): Remove.
3144
3145 2019-01-02  Tom Tromey  <tom@tromey.com>
3146
3147         * linespec.c (struct linespec_parser): Rename from ls_parser.  Add
3148         constructor, destructor.
3149         (linespec_parser): Remove typedef.
3150         (~linespec_parser): Rename from linespec_parser_delete.
3151         (linespec_lex_to_end, linespec_complete_label)
3152         (linespec_complete): Update.
3153         (decode_line_full): Remove cleanups.
3154         (decode_line_1): Update.
3155
3156 2019-01-02  Tom Tromey  <tom@tromey.com>
3157
3158         * python/python-internal.h (inferior_to_inferior_object): Change
3159         return type.
3160         * python/py-exitedevent.c (create_exited_event_object): Update.
3161         * python/py-inferior.c (inferior_to_inferior_object): Return
3162         gdbpy_ref.
3163         (python_new_inferior, python_inferior_deleted)
3164         (thread_to_thread_object, delete_thread_object)
3165         (build_inferior_list, gdbpy_selected_inferior): Update.
3166         * python/py-infthread.c (create_thread_object): Update.  Also fail
3167         if inferior_to_inferior_object fails.
3168
3169 2019-01-02  Simon Marchi  <simon.marchi@ericsson.com>
3170
3171         * inferior.h (class inferior) <displaced_step_state>: New field.
3172         * infrun.h (struct displaced_step_state): Move here from
3173         infrun.c.  Initialize fields, add constructor.
3174         <inf>: Remove field.
3175         <reset>: New method.
3176         * infrun.c (struct displaced_step_inferior_state): Move to
3177         infrun.h.
3178         (displaced_step_inferior_states): Remove.
3179         (get_displaced_stepping_state): Adust.
3180         (displaced_step_in_progress_any_inferior): Adjust.
3181         (displaced_step_in_progress_thread): Adjust.
3182         (displaced_step_in_progress): Adjust.
3183         (add_displaced_stepping_state): Remove.
3184         (get_displaced_step_closure_by_addr): Adjust.
3185         (remove_displaced_stepping_state): Remove.
3186         (infrun_inferior_exit): Call displaced_step_state.reset.
3187         (use_displaced_stepping): Don't check for NULL.
3188         (displaced_step_prepare_throw): Call
3189         get_displaced_stepping_state.
3190         (displaced_step_fixup): Don't check for NULL.
3191         (prepare_for_detach): Don't check for NULL.
3192
3193 2019-01-02  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
3194
3195         * infcall.c (call_function_by_hand_dummy): cleanup/destroy sm
3196          in case of call that did not complete.
3197
3198 2019-01-02  Andrey Utkin  <autkin@undo.io>
3199
3200         * symfile.c (find_separate_debug_file): Fix search of debug files for
3201         remote debuggee.
3202
3203 2019-01-02  Tom Tromey  <tom@tromey.com>
3204
3205         * python/py-inferior.c (gdbpy_initialize_inferior): Fix
3206         indentation.
3207         * python/py-frame.c (frapy_older): Remove cast.
3208         (frapy_newer): Likewise.
3209         * python/py-breakpoint.c (local_setattro): Remove cast.
3210         * python/py-arch.c (archpy_name): Remove local variable.
3211         * python/py-type.c (gdbpy_lookup_type): Remove cast.
3212
3213 2019-01-02  Joel Brobecker  <brobecker@adacore.com>
3214
3215         * unittests/basic_string_view/element_access/char/empty.cc:
3216         Fix year range in copyright header.
3217
3218 2019-01-01  Andrew Burgess  <andrew.burgess@embecosm.com>
3219
3220         * arch/riscv.h (struct riscv_gdbarch_features) <hw_float_abi>:
3221         Delete.
3222         <operator==>: Update with for removed field.
3223         <hash>: Likewise.
3224         * riscv-tdep.h (struct gdbarch_tdep) <features>: Renamed to...
3225         <isa_features>: ...this.
3226         <abi_features>: New field.
3227         (riscv_isa_flen): Update comment.
3228         (riscv_abi_xlen): New declaration.
3229         (riscv_abi_flen): New declaration.
3230         * riscv-tdep.c (riscv_isa_xlen): Update to get answer from
3231         isa_features.
3232         (riscv_abi_xlen): New function.
3233         (riscv_isa_flen): Update to get answer from isa_features.
3234         (riscv_abi_flen): New function.
3235         (riscv_has_fp_abi): Update to get answer from abi_features.
3236         (riscv_call_info::riscv_call_info): Use abi xlen and flen, not isa
3237         xlen and flen.
3238         (riscv_call_info) <xlen, flen>: Update comment.
3239         (riscv_call_arg_struct): Remove invalid assertions
3240         (riscv_features_from_gdbarch_info): Update now hw_float_abi field
3241         is removed.
3242         (riscv_gdbarch_init): Gather isa features and abi features
3243         separately, ensure both match on the gdbarch when reusing an old
3244         gdbarch.  Relax an error check to allow 32-bit abi float to run on
3245         a target with 64-bit float hardware.
3246
3247 2019-01-01  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
3248
3249         * source.c (search_command_helper): Stop reverse search
3250         when line 1 has been searched.
3251
3252 2019-01-01  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
3253
3254         * record-full.c (record_full_base_target::close): Rewrite
3255         record_full_core_buf_list free logic.
3256
3257 2019-01-01  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
3258
3259         * break-catch-syscall.c (print_one_catch_syscall): xfree
3260         the last text.
3261
3262 2019-01-01  Joel Brobecker  <brobecker@adacore.com>
3263
3264         * top.c (print_gdb_version): Update Copyright year in version
3265         message.
3266
3267 2019-01-01  Joel Brobecker  <brobecker@adacore.com>
3268
3269         Update copyright year range in all GDB files.
3270
3271 2019-01-01, 19  Joel Brobecker  <brobecker@adacore.com>
3272
3273         * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2018.
3274
3275 For older changes see ChangeLog-2018.
3276 \f
3277 Local Variables:
3278 mode: change-log
3279 left-margin: 8
3280 fill-column: 74
3281 version-control: never
3282 coding: utf-8
3283 End:
3284