Constify remote_console_output
[external/binutils.git] / gdb / ChangeLog
1 2019-01-14  Tom Tromey  <tom@tromey.com>
2
3         * remote.c (remote_console_output): Make parameter const.
4
5 2019-01-14  Tom Tromey  <tom@tromey.com>
6
7         * target-debug.h (target_debug_print_signals): Constify.
8         * nto-procfs.c (nto_procfs_target::pass_signals): Update.
9         * procfs.c (procfs_target::pass_signals): Update.
10         * linux-nat.c (linux_nat_target::pass_signals): Update.
11         * linux-nat.h (class linux_nat_target) <pass_signals>: Update.
12         * target-delegates.c: Rebuild.
13         * remote.c (remote_target::program_signals): Update.
14         (remote_target::pass_signals): Update.
15         * target.c (target_pass_signals): Constify argument.
16         (target_program_signals): Likewise.
17         * target.h (struct target_ops) <pass_signals, program_signals>:
18         Constify argument.
19         (target_pass_signals, target_program_signals): Constify argument.
20
21 2019-01-14  Tom Tromey  <tom@tromey.com>
22
23         PR tui/28819:
24         * tui/tui-io.c (gdb_wgetch): Print \r when needed.
25
26 2019-01-14  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
27
28         * ppc-tdep.h (struct gdbarch_tdep) <ppc_v0_alias_regnum>: New
29         field.
30         * rs6000-tdep.c: Include reggroups.h.
31         (IS_V_ALIAS_PSEUDOREG): Define.
32         (rs6000_register_name): Return names for the "vX" aliases.
33         (rs6000_pseudo_register_type): Return type for the "vX" aliases.
34         (rs6000_pseudo_register_reggroup_p): Restore.  Handle "vX"
35         aliases.  Call default_register_reggroup_p for all other
36         pseudo-registers.
37         (v_alias_pseudo_register_read, v_alias_pseudo_register_write):
38         New functions.
39         (rs6000_pseudo_register_read, rs6000_pseudo_register_write):
40         Handle "vX" aliases.
41         (v_alias_pseudo_register_collect): New function.
42         (rs6000_ax_pseudo_register_collect): Handle "vX" aliases.
43         (rs6000_gdbarch_init): Initialize "vX" aliases as
44         pseudo-registers.  Restore registration of
45         rs6000_pseudo_register_reggroup_p with
46         set_tdesc_pseudo_register_reggroup_p.
47
48 2019-01-13  Max Filippov  <jcmvbkbc@gmail.com>
49
50         * xtensa-linux-tdep.c (xtensa_linux_init_abi): Update
51         tdep->num_pseudo_regs. Add calls to set_gdbarch_num_regs and
52         set_gdbarch_num_pseudo_regs.
53
54 2019-01-12  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
55
56         * cli/cli-style.h (class cli_style_option): <add_setshow_commands>
57         Remove arg prefixname, add do_set and do_show.
58         Add member functions set_list and show_list.
59         * cli/cli-style.c (class cli_style_option): Update accordingly.
60         (style_set_list): Move to file scope.
61         (style_show_list): Likewise.
62         (set_style): Call help_list.
63         (show_style): Call cmd_show_list.
64         (_initialize_cli_style): New macro STYLE_ADD_SETSHOW_COMMANDS.
65         Update to use the new macro.
66
67 2019-10-12  Joel Brobecker  <brobecker@adacore.com>
68
69         * ada-lang.c (_initialize_ada_language): Expand the help text
70         for the "catch exception" command.
71
72 2019-01-12  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
73
74         * symtab.c (matching_obj_sections): Initialize obj,
75         declare it closer to its usage.
76
77 2019-01-10  Tom Tromey  <tom@tromey.com>
78
79         * thread-iter.h (inf_threads_iterator): Use next_iterator.
80         (basic_inf_threads_range): Remove.
81         (inf_threads_range, inf_non_exited_threads_range)
82         (safe_inf_threads_range): Use next_adapter.
83
84 2019-01-10  Keith Seitz  <keiths@redhat.com>
85
86         PR gdb/23712
87         PR symtab/23010
88         * dwarf2read.c (dw2_add_symbol_to_list): Remove.
89         (fixup_go_packaging, new_symbol): Use add_symbol_to_list.
90
91 2019-01-10  Keith Seitz  <keiths@redhat.com>
92
93         PR gdb/23712
94         PR symtab/23010
95         * dictionary.c (pending_to_vector): Remove.
96         (dict_create_hashed_1, dict_create_linear_1, dict_add_pending_1):
97         Remove _1 suffix, replacing functions of the same name.  Update
98         all callers.
99         (dict_create_hashed, dict_create_hashed_expandable)
100         (dict_create_linear, dict_create_linear_expandable, dict_free)
101         (dict_add_symbol, dict_add_pending, dict_size, dict_empty):
102         Make functions static.
103
104 2019-01-10  Keith Seitz  <keiths@redhat.com>
105
106         PR gdb/23712
107         PR symtab/23010
108         * dictionary.h (struct dictionary): Replace declaration with
109         multidictionary.
110         (dict_create_hashed, dict_create_hashed_expandable)
111         (dict_create_linear, dict_create_linear_expandable)
112         (dict_free, dict_add_symbol, dict_add_pending, dict_empty)
113         (dict_iterator_first, dict_iterator_next, dict_iter_match_first)
114         (dict_iter_match_next, dict_size): Rename to "mdict_" versions
115         taking multidictionary argument.
116         [ALL_DICT_SYMBOLS]: Update for multidictionary.
117         * block.h (struct block) <dict>: Change to multidictionary
118         and rename `multidict'.
119         * block.c, buildsym.c, jit.c, mdebugread.c, objfiles.c,
120         symmisc.c: Update all dictionary references to multidictionary.
121
122 2019-01-10  Keith Seitz  <keiths@redhat.com>
123
124         PR gdb/23712
125         PR symtab/23010
126         * dictionary.c: Include unordered_map.
127         (pending_to_vector): New function.
128         (dict_create_hashed_1, dict_create_linear_1, dict_add_pending_1):
129         Rewrite the non-"_1" functions to take vector instead
130         of linked list.
131         (dict_create_hashed, dict_create_linear, dict_add_pending): Use the
132         "new" _1 versions of the same name.
133         (multidictionary): Define.
134         (std::hash<enum language): New definition.
135         (collate_pending_symbols_by_language, mdict_create_hashed)
136         (mdict_create_hashed_expandable, mdict_create_linear)
137         (mdict_create_linear_expandable, mdict_free)
138         (find_language_dictionary, create_new_language_dictionary)
139         (mdict_add_symbol, mdict_add_pending, mdict_iterator_first)
140         (mdict_iterator_next, mdict_iter_match_first, mdict_iter_match_next)
141         (mdict_size, mdict_empty): New functions.
142         * dictionary.h (mdict_iterator): Define.
143
144 2019-01-10  Pedro Alves  <palves@redhat.com>
145
146         * breakpoint.c (read_uploaded_action)
147         (create_tracepoint_from_upload): Adjust to use
148         gdb::unique_xmalloc_ptr.
149         * ctf.c (ctf_write_uploaded_tp):
150         (SET_ARRAY_FIELD): Use emplace_back.
151         (SET_STRING_FIELD): Adjust to use gdb::unique_xmalloc_ptr.
152         * tracefile-tfile.c (tfile_write_uploaded_tp):
153         * tracepoint.c (parse_tracepoint_definition): Adjust to use
154         gdb::unique_xmalloc_ptr.
155         * tracepoint.h (struct uploaded_tp) <cond, actions, step_actions,
156         at_string, cond_string, cmd_strings>: Replace char pointers
157         with gdb::unique_xmalloc_ptr.
158
159 2019-01-10  Pedro Alves  <palves@redhat.com>
160
161         * solib-target.c (library_list_start_library): Don't xstrdup name.
162
163 2019-01-10  Pedro Alves  <palves@redhat.com>
164
165         * mdebugread.c (parse_partial_symbols): Use
166         gdb::unique_xmalloc_ptr to manage heap-allocated 'stabsstring'.
167
168 2019-01-10  Andrew Burgess  <andrew.burgess@embecosm.com>
169
170         * linux-fork.c (scoped_switch_fork_info)
171         <~scoped_switch_fork_info>: Fix incorrect variable name.
172
173 2019-01-10  Andrew Burgess  <andrew.burgess@embecosm.com>
174
175         * linux-fork.c (scoped_switch_fork_info)
176         <scoped_switch_fork_info>: Make explicit.
177         <~scoped_switch_fork_info>: Wrap core in TRY/CATCH.
178
179 2019-01-10  Tom Tromey  <tom@tromey.com>
180
181         * objfiles.h (objfile::reset_psymtabs): Update.
182         * objfiles.c (objfile::objfile): Update.
183         * psymtab.h (psymtab_storage::obstack): Update.
184         (psymtab_storage::m_obstack): Use gdb::optional.
185         (class psymtab_storage): Update comment.  Remove objfile
186         parameter.
187         * psymtab.c (psymtab_storage::psymtab_storage): Update.
188
189 2019-01-10  Tom Tromey  <tom@tromey.com>
190
191         * psymtab.h (psymtab_storage::allocate_psymtab): New method.
192         <free_psymtabs>: Now private.
193         * psymtab.c (psymtab_storage::allocate_psymtab): Implement.
194         (allocate_psymtab): Use new method.
195
196 2019-01-10  Tom Tromey  <tom@tromey.com>
197
198         * xcoffread.c (xcoff_end_psymtab): Use allocate_dependencies.
199         * psymtab.h (psymtab_storage::allocate_dependencies): New method.
200         * mdebugread.c (parse_partial_symbols): Use
201         allocate_dependencies.
202         * dwarf2read.c (dwarf2_create_include_psymtab): Use
203         allocate_dependencies.
204         (process_psymtab_comp_unit_reader)
205         (build_type_psymtab_dependencies): Likewise.
206         * dbxread.c (dbx_end_psymtab): Use allocate_dependencies.
207
208 2019-01-10  Tom Tromey  <tom@tromey.com>
209
210         * psymtab.c (add_psymbol_to_bcache): Pass psymtab obstack to
211         PSYMBOL_SET_LANGUAGE.
212         (allocate_psymtab): Allocate psymtab on the psymtab obstack.
213
214 2019-01-10  Tom Tromey  <tom@tromey.com>
215
216         * psymtab.h (psymtab_storage::obstack): New method.
217         <m_obstack>: Rename from obstack; now private.
218         * psymtab.c (psymtab_storage): Update.
219         * dwarf2read.c (create_addrmap_from_index)
220         (create_addrmap_from_aranges, dwarf2_build_psymtabs_hard):
221         Update.
222
223 2019-01-10  Tom Tromey  <tom@tromey.com>
224
225         * symfile.c (reread_symbols): Call objfile->reset_psymtabs.
226         * objfiles.h (objfile::reset_psymtabs): New method.
227
228 2019-01-10  Tom Tromey  <tom@tromey.com>
229
230         * symmisc.c (print_symbol_bcache_statistics): Update.
231         (print_objfile_statistics): Update.
232         * symfile.c (reread_symbols): Update.
233         * psymtab.h (class psymtab_storage): New.
234         * psymtab.c (psymtab_storage): New constructor.
235         (~psymtab_storage): New destructor.
236         (require_partial_symbols): Update.
237         (ALL_OBJFILE_PSYMTABS_REQUIRED): Rewrite.
238         (find_pc_sect_psymtab, find_pc_sect_psymbol)
239         (match_partial_symbol, lookup_partial_symbol, dump_psymtab)
240         (psym_dump, recursively_search_psymtabs, psym_has_symbols)
241         (psym_find_compunit_symtab_by_address, sort_pst_symbols)
242         (start_psymtab_common, end_psymtab_common)
243         (add_psymbol_to_bcache, add_psymbol_to_list, init_psymbol_list)
244         (allocate_psymtab): Update.
245         (psymtab_storage::discard_psymtab): Rename from discard_psymtab.
246         Update.
247         (dump_psymtab_addrmap, maintenance_print_psymbols)
248         (maintenance_check_psymtabs): Update.
249         (class objfile_psymtabs): Move to objfiles.h.
250         * psympriv.h (discard_psymtab): Now inline.
251         (psymtab_discarder::psymtab_discarder): Update.
252         (psymtab_discarder::~psymtab_discarder): Update.
253         (ALL_OBJFILE_PSYMTABS): Rewrite.
254         * objfiles.h (struct objfile) <psymtabs, psymtabs_addrmap,
255         free_psymtabs, psymbol_cache, global_psymbols, static_psymbols>:
256         Remove fields.
257         <partial_symtabs>: New field.
258         (class objfile_psymtabs): Move from psymtab.h.  Update.
259         * objfiles.c (objfile::objfile): Initialize partial_symtabs, not
260         psymbol_cache.
261         (objfile::~objfile): Don't destroy psymbol_cache.
262         * mdebugread.c (parse_partial_symbols): Update.
263         * dwarf2read.c (create_addrmap_from_index)
264         (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
265         (process_psymtab_comp_unit_reader, dwarf2_build_psymtabs_hard)
266         (add_partial_subprogram, dwarf2_ranges_read): Update.
267         * dwarf-index-write.c (write_address_map)
268         (write_one_signatured_type, recursively_write_psymbols)
269         (class debug_names, class debug_names, write_psymtabs_to_index):
270         Update.
271
272 2019-01-10  Tom Tromey  <tom@tromey.com>
273
274         * symtab.h (SYMBOL_SET_NAMES): Update.
275         (symbol_set_names): Update.
276         (MSYMBOL_SET_NAMES): Update.
277         * symtab.c (symbol_set_names): Change argument to be an
278         objfile_per_bfd_storage.
279         * psymtab.c (add_psymbol_to_bcache): Update.
280         * psympriv.h (PSYMBOL_SET_NAMES): Take per_bfd argument.
281
282 2019-01-10  Tom Tromey  <tom@tromey.com>
283
284         * symtab.c (create_demangled_names_hash): Change argument to be an
285         objfile_per_bfd_storage.
286         (symbol_set_names): Update.
287
288 2019-01-10  Tom Tromey  <tom@tromey.com>
289
290         * xcoffread.c (xcoff_initial_scan): Unconditionally call
291         init_psymbol_list.
292         * psymtab.c (init_psymbol_list): Do nothing if already called.
293         * psympriv.h (init_psymbol_list): Add comment.
294         * dwarf2read.c (dwarf2_build_psymtabs): Unconditionally call
295         init_psymbol_list.
296         * dbxread.c (dbx_symfile_read): Unconditionally call
297         init_psymbol_list.
298
299 2019-01-10  Tom Tromey  <tom@tromey.com>
300
301         * xcoffread.c (scan_xcoff_symtab): Update.
302         * psymtab.c (add_psymbol_to_list): Replace "list" parameter with
303         "where".
304         * mdebugread.c (parse_partial_symbols)
305         (handle_psymbol_enumerators): Update.
306         * dwarf2read.c (add_partial_symbol, load_partial_dies): Update.
307         * dbxread.c (read_dbx_symtab): Update.
308         * psympriv.h (psymbol_placement): New enum.
309         (add_psymbol_to_list): Update.
310
311 2019-01-10  Tom Tromey  <tom@tromey.com>
312
313         * xcoffread.c (xcoff_start_psymtab): Remove global_psymbols and
314         static_psymbols parameters.
315         (scan_xcoff_symtab): Update.
316         * psymtab.c (start_psymtab_common): Remove global_psymbols and
317         static_psymbols parameters.
318         * psympriv.h (start_psymtab_common): Update.
319         * mdebugread.c (parse_partial_symbols): Update.
320         * dwarf2read.c (create_partial_symtab): Update.
321         * dbxread.c (read_dbx_symtab): Update.
322         (start_psymtab): Remove global_psymbols and static_psymbols
323         parameters.
324
325 2019-01-10  Tom Tromey  <tom@tromey.com>
326
327         * xcoffread.c (xcoff_end_psymtab): Remove some initializations.
328         * psymtab.c (allocate_psymtab): Add comment.
329         * psympriv.h (allocate_psymtab): Add comment.
330         * dwarf2read.c (dwarf2_create_include_psymtab): Remove some
331         initializations.
332         * dbxread.c (dbx_end_psymtab): Remove some initializations.
333
334 2019-01-10  Tom Tromey  <tom@tromey.com>
335
336         * symfile.h (mdebug_build_psymtabs, elfmdebug_build_psymtabs):
337         Don't declare.
338         * mipsread.c: Include mdebugread.h.
339         * mdebugread.h (mdebug_build_psymtabs, elfmdebug_build_psymtabs):
340         Declare.
341         * elfread.c: Include mdebugread.h.
342
343 2019-01-09  Tom Tromey  <tom@tromey.com>
344
345         * dbxread.c (dbx_end_psymtab): Use objfile_psymtabs.
346         * mdebugread.c (parse_partial_symbols): Use objfile_psymtabs.
347         * psymtab.c (ALL_OBJFILE_PSYMTABS_REQUIRED): Remove.
348         (psym_map_symtabs_matching_filename, find_pc_sect_psymtab)
349         (psym_lookup_symbol, psym_find_last_source_symtab)
350         (psym_forget_cached_source_info, psym_print_stats)
351         (psym_expand_symtabs_for_function, psym_expand_all_symtabs)
352         (psym_expand_symtabs_with_fullname, psym_map_symbol_filenames)
353         (psym_map_matching_symbols, psym_expand_symtabs_matching)
354         (psym_find_compunit_symtab_by_address)
355         (maintenance_print_psymbols, maintenance_info_psymtabs)
356         (maintenance_check_psymtabs): Use ranged for.
357         * psymtab.h (class objfile_psymtabs): New.
358         (require_partial_symbols): Return objfile_psymtabs.
359         * psympriv.h (ALL_OBJFILE_PSYMTABS): Remove.
360
361 2019-01-09  Tom Tromey  <tom@tromey.com>
362
363         * symfile.c (overlay_invalidate_all, find_pc_overlay)
364         (find_pc_mapped_section, list_overlays_command)
365         (map_overlay_command, unmap_overlay_command)
366         (simple_overlay_update): Use all_objfiles.
367         * spu-tdep.c (spu_overlay_update): Use all_objfiles.
368         * printcmd.c (info_symbol_command): Use all_objfiles.
369         * objfiles.h (ALL_OBJSECTIONS): Remove.
370         * maint.c (maintenance_translate_address): Use all_objfiles.
371         * gcore.c (gcore_create_callback): Use all_objfiles.
372         (objfile_find_memory_regions): Likewise.
373
374 2019-01-09  Tom Tromey  <tom@tromey.com>
375
376         * symtab.c (find_line_symtab, info_sources_command)
377         (make_source_files_completion_list): Use objfile_compunits.
378         * source.c (select_source_symtab): Use objfile_compunits.
379         * objfiles.h (struct objfile): Update comment.
380         (ALL_OBJFILES): Remove.
381         (ALL_FILETABS): Remove.
382         * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_files): Use
383         objfile_compunits.
384
385 2019-01-09  Tom Tromey  <tom@tromey.com>
386
387         * symmisc.c (print_objfile_statistics, dump_objfile)
388         (maintenance_print_symbols): Use compunit_filetabs.
389         * source.c (forget_cached_source_info_for_objfile): Use
390         compunit_filetabs.
391         * objfiles.h (ALL_OBJFILE_FILETABS): Remove.
392         (ALL_FILETABS): Use compunit_filetabs.
393         * objfiles.c (objfile_relocate1): Use compunit_filetabs.
394         * coffread.c (coff_symtab_read): Use compunit_filetabs.
395
396 2019-01-09  Tom Tromey  <tom@tromey.com>
397
398         * symtab.h (ALL_COMPUNIT_FILETABS): Remove.
399         (compunit_filetabs): New.
400         * symtab.c (iterate_over_some_symtabs, find_pc_sect_line): Use
401         compunit_filetabs.
402         (info_sources_command, make_source_files_completion_list): Remove
403         declaration.
404         * symmisc.c (print_objfile_statistics, dump_objfile)
405         (maintenance_print_symbols): Remove declaration.
406         (maintenance_info_symtabs): Use compunit_filetabs.
407         (maintenance_info_line_tables): Likewise.
408         * source.c (select_source_symtab): Change local variable name.
409         (forget_cached_source_info_for_objfile): Remove declaration.
410         * objfiles.h (ALL_OBJFILE_FILETABS): Use compunit_filetabs.
411         * objfiles.c (objfile_relocate1): Remove declaration.
412         * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_files): Remove
413         declaration.
414         * maint.c (count_symtabs_and_blocks): Use compunit_filetabs.
415         * coffread.c (coff_symtab_read): Remove declaration.
416         * buildsym.c (buildsym_compunit::end_symtab_with_blockvector): Use
417         compunit_filetabs.
418
419 2019-01-09  Tom Tromey  <tom@tromey.com>
420
421         * symtab.c (lookup_objfile_from_block)
422         (find_pc_sect_compunit_symtab, search_symbols)
423         (default_collect_symbol_completion_matches_break_on): Use
424         objfile_compunits.
425         * objfiles.h (ALL_COMPUNITS): Remove.
426         * maint.c (count_symtabs_and_blocks): Use objfile_compunits.
427         * cp-support.c (add_symbol_overload_list_qualified): Use
428         objfile_compunits.
429         * ada-lang.c (ada_collect_symbol_completion_matches)
430         (ada_add_global_exceptions): Use objfile_compunits.
431
432 2019-01-09  Tom Tromey  <tom@tromey.com>
433
434         * source.c (select_source_symtab)
435         (forget_cached_source_info_for_objfile): Remove declaration.
436         * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_files): Remove
437         declaration.
438         * maint.c (count_symtabs_and_blocks): Remove declaration.
439         * cp-support.c (add_symbol_overload_list_qualified): Remove
440         declaration.
441         * coffread.c (coff_symtab_read): Remove declaration.
442         * symtab.c (lookup_symbol_in_objfile_symtabs)
443         (basic_lookup_transparent_type_1): Use objfile_compunits.
444         (lookup_objfile_from_block, find_pc_sect_compunit_symtab)
445         (info_sources_command, search_symbols)
446         (default_collect_symbol_completion_matches_break_on)
447         (make_source_files_completion_list): Remove declaration.
448         * ada-lang.c (add_nonlocal_symbols): Use objfile_compunits.
449         (ada_collect_symbol_completion_matches)
450         (ada_add_global_exceptions): Remove declaration.
451         * linespec.c (iterate_over_all_matching_symtabs): Use
452         objfile_compunits.
453         * objfiles.h (ALL_OBJFILE_COMPUNITS): Remove.
454         (class objfile_compunits): New.
455         (ALL_COMPUNITS): Use objfile_compunits.
456         * symmisc.c (print_objfile_statistics, maintenance_info_symtabs)
457         (maintenance_check_symtabs, maintenance_info_line_tables): Use
458         objfile_compunits.
459         * objfiles.c (objfile_relocate1): Use objfile_compunits.
460
461 2019-01-09  Tom Tromey  <tom@tromey.com>
462
463         * symtab.c (search_symbols)
464         (default_collect_symbol_completion_matches_break_on): Use
465         objfile_msymbols.
466         * ada-lang.c (ada_lookup_simple_minsym)
467         (ada_collect_symbol_completion_matches): Use objfile_msymbols.
468         * minsyms.c (find_solib_trampoline_target): Use objfile_msymbols.
469         * hppa-tdep.c (hppa_lookup_stub_minimal_symbol): Use
470         objfile_msymbols.
471         * coffread.c (coff_symfile_read): Use objfile_msymbols.
472         * symmisc.c (dump_msymbols): Use objfile_msymbols.
473         * objc-lang.c (find_methods): Use objfile_msymbols.
474         (info_selectors_command, info_classes_command): Likewise.
475         * stabsread.c (scan_file_globals): Use objfile_msymbols.
476         * objfiles.h (class objfile_msymbols): New.
477         (ALL_OBJFILE_MSYMBOLS): Remove.
478         (ALL_MSYMBOLS): Remove.
479
480 2019-01-09  Tom Tromey  <tom@tromey.com>
481
482         * common/next-iterator.h (next_adapter): Add Iterator template
483         parameter.
484         * objfiles.h (ALL_OBJFILES_SAFE): Remove.
485         (class all_objfiles_safe): New.
486         * jit.c (jit_inferior_exit_hook): Use all_objfiles_safe.
487         * objfiles.c (put_objfile_before): Update comment.
488         (add_separate_debug_objfile): Likewise.
489         (free_all_objfiles): Use all_objfiles_safe.
490         (objfile_purge_solibs): Likewise.
491
492 2019-01-09  Tom Tromey  <tom@tromey.com>
493
494         * symtab.c (iterate_over_symtabs, matching_obj_sections)
495         (expand_symtab_containing_pc, lookup_static_symbol)
496         (basic_lookup_transparent_type, find_pc_sect_compunit_symtab)
497         (find_symbol_at_address, find_line_symtab, find_main_name): Use
498         all_objfiles.
499         * probe.c (find_probe_by_pc, collect_probes): Use all_objfiles.
500         * breakpoint.c (create_overlay_event_breakpoint)
501         (create_longjmp_master_breakpoint)
502         (create_std_terminate_master_breakpoint)
503         (create_exception_master_breakpoint): Use all_objfiles.
504         * linux-thread-db.c (try_thread_db_load_from_pdir)
505         (has_libpthread): Use all_objfiles.
506         * ada-lang.c (add_nonlocal_symbols): Use all_objfiles.
507         * linespec.c (iterate_over_all_matching_symtabs)
508         (search_minsyms_for_name): Use all_objfiles.
509         * maint.c (maintenance_info_sections): Use all_objfiles.
510         * main.c (captured_main_1): Use all_objfiles.
511         * spu-tdep.c (spu_objfile_from_frame): Use all_objfiles.
512         * guile/scm-objfile.c (gdbscm_objfiles): Use all_objfiles.
513         * guile/scm-pretty-print.c
514         (ppscm_find_pretty_printer_from_objfiles): Use all_objfiles.
515         * solib-spu.c (append_ocl_sos): Use all_objfiles.
516         * symmisc.c (maintenance_print_symbols): Use all_objfiles.
517         (maintenance_print_msymbols): Use all_objfiles.
518         * source.c (select_source_symtab): Use all_objfiles.
519         * jit.c (jit_find_objf_with_entry_addr): Use all_objfiles.
520         * symfile.c (remove_symbol_file_command)
521         (expand_symtabs_matching, map_symbol_filenames): Use
522         all_objfiles.
523         * ppc-linux-tdep.c (ppc_linux_spe_context_inferior_created): Use
524         all_objfiles.
525         * dwarf2-frame.c (dwarf2_frame_find_fde): Use all_objfiles.
526         * objc-lang.c (find_methods): Use all_objfiles.
527         * objfiles.c (have_partial_symbols, have_full_symbols)
528         (have_minimal_symbols, qsort_cmp)
529         (default_iterate_over_objfiles_in_search_order): Use
530         all_objfiles.
531         * hppa-tdep.c (find_unwind_entry): Use all_objfiles.
532         * psymtab.c (maintenance_print_psymbols): Use all_objfiles.
533         (maintenance_check_psymtabs): Use all_objfiles.
534         (ALL_PSYMTABS): Remove.
535         * compile/compile-object-run.c (do_module_cleanup): Use
536         all_objfiles.
537         * blockframe.c (find_pc_partial_function): Use all_objfiles.
538         * cp-support.c (add_symbol_overload_list_qualified): Use
539         all_objfiles.
540         * windows-tdep.c (windows_iterate_over_objfiles_in_search_order):
541         Use all_objfiles.
542         * dwarf-index-write.c (save_gdb_index_command): Use all_objfiles.
543         * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): Use
544         all_objfiles.
545         * python/py-objfile.c (objfpy_lookup_objfile_by_name)
546         (objfpy_lookup_objfile_by_build_id): Use all_objfiles.
547         * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
548         Uses all_objfiles.
549         * solib.c (solib_read_symbols): Use all_objfiles
550
551 2019-01-09  Tom Tromey  <tom@tromey.com>
552
553         * probe.c (parse_probes_in_pspace): Use all_objfiles.
554         * guile/scm-progspace.c (gdbscm_progspace_objfiles): Use
555         all_objfiles.
556         * objfiles.h (ALL_PSPACE_OBJFILES): Remove.
557         * symmisc.c (print_symbol_bcache_statistics)
558         (print_objfile_statistics, maintenance_print_objfiles)
559         (maintenance_info_symtabs, maintenance_check_symtabs)
560         (maintenance_expand_symtabs, maintenance_info_line_tables): Use
561         all_objfiles.
562         * source.c (forget_cached_source_info): Use all_objfiles.
563         * symfile-debug.c (set_debug_symfile): Use all_objfiles.
564         * elfread.c (elf_gnu_ifunc_resolve_by_cache)
565         (elf_gnu_ifunc_resolve_by_got): Use all_objfiles.
566         * objfiles.c (update_section_map): Use all_objfiles.
567         (shared_objfile_contains_address_p): Likewise.
568         * psymtab.c (maintenance_info_psymtabs): Use all_objfiles.
569         * python/py-progspace.c (pspy_get_objfiles): Use all_objfiles.
570
571 2019-01-09  Tom Tromey  <tom@tromey.com>
572
573         * common/next-iterator.h: New file.
574         * objfiles.h (class all_objfiles): New.
575         (struct objfile_iterator): New.
576
577 2019-01-09  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
578
579         * NEWS: Move the description of the changed "frame", "select-frame",
580          and "info frame" commands to the Changed commands section.
581
582 2019-01-09  Simon Marchi  <simon.marchi@ericsson.com>
583
584         * gdbtypes.c (check_stub_method_group): Remove handling of old
585         mangling schemes.
586         * linespec.c (find_methods): Likewise.
587         * stabsread.c (read_member_functions): Likewise.
588         * valops.c (search_struct_method): Likewise.
589         (value_struct_elt_for_reference): Likewise.
590         * NEWS: Mention this change.
591
592 2019-01-09  Andrew Burgess  <andrew.burgess@embecosm.com>
593
594         * cli/cli-cmds.c (list_command): Pass a source_lines_range to
595         print_source_lines.
596         * source.c (print_source_lines_base): Update line number check.
597         (print_source_lines): New function.
598         (source_lines_range::source_lines_range): New function.
599         * source.h (class source_lines_range): New class.
600         (print_source_lines): New declaration.
601
602 2019-01-09  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
603
604         * linespec.c (linespec_state_destructor): Free self->canonical_names.
605
606 2019-01-08  Tom Tromey  <tom@tromey.com>
607             Simon Marchi  <simon.marchi@ericsson.com>
608
609         PR gdb/24060
610         * ada-exp.y (DOLLAR_VARIABLE): Rename from SPECIAL_VARIABLE.
611         * ada-lex.l (DOLLAR_VARIABLE): Likewise.
612         * c-exp.y (DOLLAR_VARIABLE): Rename from VARIABLE.
613         * f-exp.y (DOLLAR_VARIABLE): Likewise.
614         * m2-exp.y (DOLLAR_VARIABLE): Rename from INTERNAL_VAR.
615         * p-exp.y (DOLLAR_VARIABLE): Rename from VARIABLE.
616
617 2019-01-08  Andrew Burgess  <andrew.burgess@embecosm.com>
618
619         * source.c (select_source_symtab): Move header comment to
620         declaration in source.h.
621         (forget_cached_source_info_for_objfile): Likewise.
622         (forget_cached_source_info): Likewise.
623         (identify_source_line): Likewise.
624         * source.h (identify_source_line): Move declaration from symtab.h
625         and add comment from source.c
626         (print_source_lines): Likewise.
627         (forget_cached_source_info_for_objfile): Likewise.
628         (forget_cached_source_info): Likewise.
629         (select_source_symtab): Likewise.
630         (enum print_source_lines_flag): Move definition from symtab.h.
631         * symtab.h (identify_source_line): Move declaration to source.h.
632         (print_source_lines): Likewise.
633         (forget_cached_source_info_for_objfile): Likewise.
634         (forget_cached_source_info): Likewise.
635         (select_source_symtab): Likewise.
636         (enum print_source_lines_flag): Move definition to source.h.
637         * tui/tui-hooks.c: Add 'source.h' include.
638
639 2019-01-08  Andrew Burgess  <andrew.burgess@embecosm.com>
640
641         * source.c (print_source_lines_base): Handle requests to print
642         reverse line number sequences, and guard against empty lines
643         string.
644
645 2019-01-08  Andrew Burgess  <andrew.burgess@embecosm.com>
646
647         * source.c (print_source_lines_base): Fix skip of '\r' if next
648         character is '\n'.
649
650 2019-01-06  Tom Tromey  <tom@tromey.com>
651
652         * c-exp.y (struct c_parse_state) <macro_original_text,
653         expansion_obstack>: New member.
654         (macro_original_text, expansion_obstack): Remove globals.
655         (scan_macro_expansion, scanning_macro_expansion)
656         (finished_macro_expansion): Update.
657         (scan_macro_cleanup): Remove.
658         (yylex, c_parse): Update.
659
660 2019-01-06  Tom Tromey  <tom@tromey.com>
661
662         * c-exp.y (struct c_parse_state) <strings>: New member.
663         (operator_stoken): Update.
664
665 2019-01-06  Tom Tromey  <tom@tromey.com>
666
667         * parser-defs.h (type_ptr): Remove typedef.  Don't declare VEC.
668         (union type_stack_elt) <typelist_val>: Now a pointer to
669         std::vector.
670         (type_stack_cleanup): Don't declare.
671         (push_typelist): Update.
672         * parse.c (pop_typelist): Return a std::vector.
673         (push_typelist): Take a std::vector.
674         (follow_types): Update.  Do not free args.
675         (type_stack_cleanup): Remove.
676         * c-exp.y (struct c_parse_state): New.
677         (cpstate): New global.
678         (type_aggregate_p, exp, ptr_operator, parameter_typelist)
679         (nonempty_typelist): Update.
680         (func_mod): Create a new vector.
681         (c_parse): Create a c_parse_state.
682         (check_parameter_typelist): Do not delete params.
683         (function_method): Update.  Do not delete type_list.
684
685 2019-01-06  Tom Tromey  <tom@tromey.com>
686
687         PR gdb/28155:
688         * python/py-finishbreakpoint.c (bpfinishpy_init): Use
689         check_typedef.
690         * infcmd.c (finish_command_fsm_should_stop): Use check_typedef.
691         (print_return_value): Likewise.
692
693 2019-01-05  Tom Tromey  <tom@tromey.com>
694
695         * contrib/cleanup_check.py: Remove.
696         * contrib/gcc-with-excheck: Remove.
697         * contrib/exsummary.py: Remove.
698         * contrib/excheck.py: Remove.
699
700 2019-01-05  Joel Brobecker  <brobecker@adacore.com>
701
702         * thread.c (delete_thread_1): Add gdb_assert that THR is not
703         NULL. Initialize tpprev to NULL instead of assigning it
704         to NULL on the next statement.
705         * windows-nat.c (windows_delete_thread): Remove check for
706         main_thread_id before printing thread exit notifications.
707         (get_windows_debug_event) <EXIT_THREAD_DEBUG_EVENT>:
708         Remove thread ID check against main_thread_id.
709         <CREATE_PROCESS_DEBUG_EVENT>: Remove call to
710         windows_delete_thread.
711         <EXIT_PROCESS_DEBUG_EVENT>: Add call to windows_delete_thread.
712
713 2019-01-04  Tom Tromey  <tom@tromey.com>
714
715         * compile/compile.c (_initialize_compile): Use upper case for
716         metasyntactic variables.
717         * symmisc.c (_initialize_symmisc): Use upper case for
718         metasyntactic variables.
719         * psymtab.c (_initialize_psymtab): Use upper case for
720         metasyntactic variables.
721         * demangle.c (demangle_command): Use upper case for metasyntactic
722         variables.
723         (_initialize_demangler): Likewise.
724         * ax-gdb.c (_initialize_ax_gdb): Use upper case for metasyntactic
725         variables.
726
727 2019-01-03  Tom Tromey  <tom@tromey.com>
728
729         * tui/tui-source.c (tui_set_source_content): Use xstrdup.
730
731 2019-01-03  Tom Tromey  <tom@tromey.com>
732
733         * python/py-symtab.c (salpy_str): Update.
734         (struct salpy_sal_object) <symtab>: Now a PyObject.
735         (salpy_dealloc): Update.
736         (del_objfile_sal): Use gdbpy_ref.
737
738 2019-01-03  Tom Tromey  <tom@tromey.com>
739
740         * python/py-type.c (convert_field): Use new_reference.  Return
741         gdbpy_ref.
742         (make_fielditem): Return gdbpy_ref.
743         (typy_fields): Update.
744         (typy_getitem): Update.
745         (field_name): Return gdbpy_ref.  Use new_reference.
746         (typy_iterator_iternext): Update.
747
748 2019-01-03  Tom Tromey  <tom@tromey.com>
749
750         * python/py-record.c (gdbpy_stop_recording): Use Py_RETURN_NONE.
751
752 2019-01-03  Tom Tromey  <tom@tromey.com>
753
754         * python/py-value.c (valpy_dealloc): Use Py_XDECREF.
755         * python/py-type.c (typy_fields_items): Use gdbpy_ref.
756         * python/py-progspace.c (pspy_set_printers): Use gdbpy_ref.
757         (pspy_set_frame_filters, pspy_set_frame_unwinders)
758         (pspy_set_type_printers): Likewise.
759         * python/py-function.c (fnpy_init): Use gdbpy_ref.
760         * python/py-cmd.c (cmdpy_init): Use gdbpy_ref.
761         * python/py-objfile.c (objfpy_set_printers): Use gdbpy_ref.
762         (objfpy_set_frame_filters, objfpy_set_frame_unwinders)
763         (objfpy_set_type_printers): Likewise.
764
765 2019-01-03  Tom Tromey  <tom@tromey.com>
766
767         * python/python.c (gdbpy_enter, ~gdbpy_enter): Update.
768         (gdbpy_print_stack): Use gdbpy_err_fetch.
769         * python/python-internal.h (class gdbpy_err_fetch): New class.
770         (class gdbpy_enter) <m_error_type, m_error_value,
771         m_error_traceback>: Remove.
772         <m_error>: New member.
773         (gdbpy_exception_to_string): Don't declare.
774         * python/py-varobj.c (py_varobj_iter_next): Use gdbpy_err_fetch.
775         * python/py-value.c (convert_value_from_python): Use
776         gdbpy_err_fetch.
777         * python/py-utils.c (gdbpy_err_fetch::to_string): Rename from
778         gdbpy_exception_to_string.
779         (gdbpy_handle_exception): Use gdbpy_err_fetch.
780         * python/py-prettyprint.c (print_stack_unless_memory_error): Use
781         gdbpy_err_fetch.
782
783 2019-01-03  Andrew Burgess  <andrew.burgess@embecosm.com>
784
785         * linux-nat.c (delete_lwp_cleanup): Delete.
786         (struct lwp_deleter): New struct.
787         (lwp_info_up): New typedef.
788         (linux_nat_target::follow_fork): Delete cleanup, and make use of
789         lwp_info_up.
790
791 2019-01-03  Andrew Burgess  <andrew.burgess@embecosm.com>
792
793         * linux-fork.c (class scoped_switch_fork_info): New class.
794         (inferior_call_waitpid): Update to use scoped_switch_fork_info.
795
796 2019-01-03  Andrew Burgess  <andrew.burgess@embecosm.com>
797
798         * valops.c (find_overload_match): Remove use of null_cleanup, and
799         calls to do_cleanups.
800
801 2019-01-03  Andrew Burgess  <andrew.burgess@embecosm.com>
802
803         * compile/compile-cplus-types.c
804         (compile_cplus_instance::decl_name): Handle changes to
805         cp_func_name.
806         * cp-support.c (cp_func_name): Update header comment, update
807         return type.
808         * cp-support.h (cp_func_name): Update return type in declaration.
809         * valops.c (find_overload_match): Move temp_func local to top
810         level of function and change its type.  Use temp_func to hold and
811         delete temporary string obtained from cp_func_name.
812
813 2019-01-03  Andrew Burgess  <andrew.burgess@embecosm.com>
814
815         * remote.c (remote_target::remote_check_symbols): Convert `msg` to
816         gdb::char_vector, remove cleanup, and update uses of `msg`.
817
818 2019-01-03  Jim Wilson  <jimw@sifive.com>
819
820         * riscv-tdep.c (riscv_freg_feature): Drop s0 name from f8.
821
822 2019-01-02  Tom Tromey  <tom@tromey.com>
823
824         * xml-tdesc.c (xml_cache): Hold a target_desc_up.
825         (tdesc_parse_xml): Remove cleanups.
826         * target-descriptions.h (make_cleanup_free_target_description):
827         Don't declare.
828         (target_desc_deleter): New struct.
829         (target_desc_up): New typedef.
830         * target-descriptions.c (target_desc_deleter::operator()): Rename
831         from free_target_description.
832         (make_cleanup_free_target_description): Remove.
833
834 2019-01-02  Tom Tromey  <tom@tromey.com>
835
836         * linespec.c (struct linespec_parser): Rename from ls_parser.  Add
837         constructor, destructor.
838         (linespec_parser): Remove typedef.
839         (~linespec_parser): Rename from linespec_parser_delete.
840         (linespec_lex_to_end, linespec_complete_label)
841         (linespec_complete): Update.
842         (decode_line_full): Remove cleanups.
843         (decode_line_1): Update.
844
845 2019-01-02  Tom Tromey  <tom@tromey.com>
846
847         * python/python-internal.h (inferior_to_inferior_object): Change
848         return type.
849         * python/py-exitedevent.c (create_exited_event_object): Update.
850         * python/py-inferior.c (inferior_to_inferior_object): Return
851         gdbpy_ref.
852         (python_new_inferior, python_inferior_deleted)
853         (thread_to_thread_object, delete_thread_object)
854         (build_inferior_list, gdbpy_selected_inferior): Update.
855         * python/py-infthread.c (create_thread_object): Update.  Also fail
856         if inferior_to_inferior_object fails.
857
858 2019-01-02  Simon Marchi  <simon.marchi@ericsson.com>
859
860         * inferior.h (class inferior) <displaced_step_state>: New field.
861         * infrun.h (struct displaced_step_state): Move here from
862         infrun.c.  Initialize fields, add constructor.
863         <inf>: Remove field.
864         <reset>: New method.
865         * infrun.c (struct displaced_step_inferior_state): Move to
866         infrun.h.
867         (displaced_step_inferior_states): Remove.
868         (get_displaced_stepping_state): Adust.
869         (displaced_step_in_progress_any_inferior): Adjust.
870         (displaced_step_in_progress_thread): Adjust.
871         (displaced_step_in_progress): Adjust.
872         (add_displaced_stepping_state): Remove.
873         (get_displaced_step_closure_by_addr): Adjust.
874         (remove_displaced_stepping_state): Remove.
875         (infrun_inferior_exit): Call displaced_step_state.reset.
876         (use_displaced_stepping): Don't check for NULL.
877         (displaced_step_prepare_throw): Call
878         get_displaced_stepping_state.
879         (displaced_step_fixup): Don't check for NULL.
880         (prepare_for_detach): Don't check for NULL.
881
882 2019-01-02  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
883
884         * infcall.c (call_function_by_hand_dummy): cleanup/destroy sm
885          in case of call that did not complete.
886
887 2019-01-02  Andrey Utkin  <autkin@undo.io>
888
889         * symfile.c (find_separate_debug_file): Fix search of debug files for
890         remote debuggee.
891
892 2019-01-02  Tom Tromey  <tom@tromey.com>
893
894         * python/py-inferior.c (gdbpy_initialize_inferior): Fix
895         indentation.
896         * python/py-frame.c (frapy_older): Remove cast.
897         (frapy_newer): Likewise.
898         * python/py-breakpoint.c (local_setattro): Remove cast.
899         * python/py-arch.c (archpy_name): Remove local variable.
900         * python/py-type.c (gdbpy_lookup_type): Remove cast.
901
902 2019-01-02  Joel Brobecker  <brobecker@adacore.com>
903
904         * unittests/basic_string_view/element_access/char/empty.cc:
905         Fix year range in copyright header.
906
907 2019-01-01  Andrew Burgess  <andrew.burgess@embecosm.com>
908
909         * arch/riscv.h (struct riscv_gdbarch_features) <hw_float_abi>:
910         Delete.
911         <operator==>: Update with for removed field.
912         <hash>: Likewise.
913         * riscv-tdep.h (struct gdbarch_tdep) <features>: Renamed to...
914         <isa_features>: ...this.
915         <abi_features>: New field.
916         (riscv_isa_flen): Update comment.
917         (riscv_abi_xlen): New declaration.
918         (riscv_abi_flen): New declaration.
919         * riscv-tdep.c (riscv_isa_xlen): Update to get answer from
920         isa_features.
921         (riscv_abi_xlen): New function.
922         (riscv_isa_flen): Update to get answer from isa_features.
923         (riscv_abi_flen): New function.
924         (riscv_has_fp_abi): Update to get answer from abi_features.
925         (riscv_call_info::riscv_call_info): Use abi xlen and flen, not isa
926         xlen and flen.
927         (riscv_call_info) <xlen, flen>: Update comment.
928         (riscv_call_arg_struct): Remove invalid assertions
929         (riscv_features_from_gdbarch_info): Update now hw_float_abi field
930         is removed.
931         (riscv_gdbarch_init): Gather isa features and abi features
932         separately, ensure both match on the gdbarch when reusing an old
933         gdbarch.  Relax an error check to allow 32-bit abi float to run on
934         a target with 64-bit float hardware.
935
936 2019-01-01  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
937
938         * source.c (search_command_helper): Stop reverse search
939         when line 1 has been searched.
940
941 2019-01-01  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
942
943         * record-full.c (record_full_base_target::close): Rewrite
944         record_full_core_buf_list free logic.
945
946 2019-01-01  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
947
948         * break-catch-syscall.c (print_one_catch_syscall): xfree
949         the last text.
950
951 2019-01-01  Joel Brobecker  <brobecker@adacore.com>
952
953         * top.c (print_gdb_version): Update Copyright year in version
954         message.
955
956 2019-01-01  Joel Brobecker  <brobecker@adacore.com>
957
958         Update copyright year range in all GDB files.
959
960 2019-01-01  Joel Brobecker  <brobecker@adacore.com>
961
962         * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2018.
963
964 For older changes see ChangeLog-2018.
965 \f
966 Local Variables:
967 mode: change-log
968 left-margin: 8
969 fill-column: 74
970 version-control: never
971 coding: utf-8
972 End:
973