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