hurd: make function cast stronger
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2
3 * reply_mig_hack.awk (Error return): Cast function through
4 void *, to bypass compiler function call check.
5
6 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
7
8 * config/i386/i386gnu.mn (%_reply_S.c): Add dependency on
9 $(srcdir)/reply_mig_hack.awk.
10
11 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
12
13 * gnu-nat.h (gnu_debug_flag): Set type to bool.
14
15 2020-05-30 Jonny Grant <jg@jguk.org>
16
17 * configure.ac (ACX_BUGURL): change bug URL to https.
18
19 2020-05-30 Pedro Alves <palves@redhat.com>
20
21 * cp-support.c (replace_typedefs_template): New.
22 (replace_typedefs_qualified_name): Handle
23 DEMANGLE_COMPONENT_TEMPLATE.
24
25 2020-05-29 Simon Marchi <simon.marchi@efficios.com>
26
27 * dwarf2/comp-unit.c, dwarf2/comp-unit.h, dwarf2/index-cache.c,
28 dwarf2/index-cache.h, dwarf2/index-write.c,
29 dwarf2/index-write.h, dwarf2/line-header.c,
30 dwarf2/line-header.h, dwarf2/macro.c, dwarf2/macro.h,
31 dwarf2/read.c, dwarf2/read.h: Rename struct dwarf2_per_objfile
32 variables and fields from `dwarf2_per_objfile` to just
33 `per_objfile` throughout.
34
35 2020-05-28 Simon Marchi <simon.marchi@polymtl.ca>
36
37 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
38 <push_dwarf_reg_entry_value>: Add comment.
39
40 2020-05-28 Kevin Buettner <kevinb@redhat.com>
41 Keith Seitz <keiths@redhat.com>
42
43 * python/python.c (do_start_initialization): Call PyEval_SaveThread
44 instead of PyEval_ReleaseLock.
45 (class gdbpy_gil): Move to earlier in file.
46 (finalize_python): Set gdb_python_initialized.
47 (gdbpy_check_quit_flag): Acquire GIL via gdbpy_gil. Return early
48 when not initialized.
49
50 2020-05-28 Simon Marchi <simon.marchi@efficios.com>
51
52 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
53 <push_dwarf_reg_entry_value>: Remove assert. Override
54 per_objfile with caller_per_objfile.
55
56 2020-05-28 Tom de Vries <tdevries@suse.de>
57
58 * dwarf2/read.c (dw2_symtab_iter_next, dw2_expand_marked_cus): Limit
59 PR gold/15646 workaround to symbol kind "type".
60
61 2020-05-27 Tom Tromey <tromey@adacore.com>
62
63 * dwarf2/read.c (load_partial_dies): Use add_partial_symbol.
64
65 2020-05-27 Tom Tromey <tromey@adacore.com>
66
67 * dwarf2/abbrev.h (struct abbrev_table) <lookup_abbrev>: Inline.
68 Use htab_find_with_hash.
69 <add_abbrev>: Remove "abbrev_number" parameter.
70 * dwarf2/abbrev.c (abbrev_table::add_abbrev): Remove
71 "abbrev_number" parameter. Use htab_find_slot_with_hash.
72 (hash_abbrev): Add comment.
73 (abbrev_table::lookup_abbrev): Move to header file.
74 (abbrev_table::read): Update.
75
76 2020-05-27 Tom Tromey <tromey@adacore.com>
77
78 * dwarf2/read.c (struct partial_die_info) <name>: Declare new
79 method.
80 <canonical_name>: New member.
81 <raw_name>: Rename from "name".
82 (partial_die_info): Initialize canonical_name.
83 (scan_partial_symbols): Check raw_name.
84 (partial_die_parent_scope, partial_die_full_name)
85 (add_partial_symbol, add_partial_subprogram)
86 (add_partial_enumeration, load_partial_dies): Use "name" method.
87 (partial_die_info::name): New method.
88 (partial_die_info::read, guess_partial_die_structure_name)
89 (partial_die_info::fixup): Update.
90
91 2020-05-27 Tom Tromey <tromey@adacore.com>
92
93 * dwarf2/attribute.h (struct attribute) <form_is_ref>: Inline.
94 <get_ref_die_offset>: Inline.
95 <get_ref_die_offset_complaint>: New method.
96 * dwarf2/attribute.c (attribute::form_is_ref): Move to header.
97 (attribute::get_ref_die_offset_complaint): Rename from
98 get_ref_die_offset. Just issue complaint.
99
100 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
101
102 * cli/cli-cmds.c (shell_escape): Move exit_status_set_internal_vars.
103
104 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
105
106 * exec.c (exec_file_attach): Use errno value of first openp failure.
107
108 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
109
110 * nat/windows-nat.c (windows_thread_info::~windows_thread_info):
111 Don't close thread handle.
112
113 2020-05-27 Tom Tromey <tom@tromey.com>
114 Simon Marchi <simon.marchi@efficios.com>
115
116 * objfiles.h (struct objfile) <partial_symtabs>: Now a
117 shared_ptr.
118 * dwarf2/read.h (struct dwarf2_per_objfile) <partial_symtabs>: New
119 member.
120 * dwarf2/read.c (dwarf2_per_bfd_bfd_data_key,
121 dwarf2_per_bfd_objfile_data_key>: New globals.
122 (dwarf2_has_info): Use shared dwarf2_per_bfd if possible.
123 (dwarf2_get_section_info): Use get_dwarf2_per_objfile.
124 (dwarf2_initialize_objfile): Consider cases where per_bfd can be
125 shared.
126 (dwarf2_build_psymtabs): Set objfile::partial_symtabs and
127 short-circuit when sharing.
128 (dwarf2_build_psymtabs): Set dwarf2_per_objfile::partial_symtabs.
129 (dwarf2_psymtab::expand_psymtab): Use free_cached_comp_units.
130
131 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
132
133 * dwarf2/read.h (struct dwarf2_per_bfd) <line_header_hash>: Move
134 to...
135 (struct dwarf2_per_objfile) <line_header_hash>: ... here.
136 * dwarf2/read.c (handle_DW_AT_stmt_list): Update.
137
138 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
139
140 * dwarf2/read.c (struct mapped_index_base) <symbol_name_at,
141 build_name_components, find_name_components_bounds>:
142 Add per_objfile parameter.
143 (struct mapped_index) <symbol_name_at>: Likewise.
144 (struct mapped_debug_names): Remove constructor.
145 <dwarf2_per_objfile>: Remove field.
146 <namei_to_name, symbol_name_at>: Add per_objfile parameter.
147 (mapped_index_base::find_name_components_bounds,
148 mapped_index_base::build_name_components,
149 dw2_expand_symtabs_matching_symbol): Likewise.
150 (class mock_mapped_index) <symbol_name_at>: Likewise.
151 (check_match): Likewise.
152 (check_find_bounds_finds): Likewise.
153 (test_mapped_index_find_name_component_bounds): Update.
154 (CHECK_MATCH): Update.
155 (dw2_expand_symtabs_matching): Update.
156 (class dw2_debug_names_iterator) <dw2_debug_names_iterator>: Add
157 per_objfile parameter.
158 <find_vec_in_debug_names>: Likewise.
159 <m_per_objfile>: New field.
160 (mapped_debug_names::namei_to_name): Add dwarf2_per_objfile
161 parameter.
162 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
163 (dw2_debug_names_iterator::next): Update.
164 (dw2_debug_names_lookup_symbol): Update.
165 (dw2_debug_names_expand_symtabs_for_function): Update.
166 (dw2_debug_names_map_matching_symbols): Update.
167 (dw2_debug_names_expand_symtabs_matching): Update.
168 (dwarf2_read_debug_names): Update.
169
170 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
171
172 * dwarf2/read.h (struct dwarf2_cu): Forward-declare.
173 (struct dwarf2_per_bfd) <free_cached_comp_units>: Remove,
174 move to dwarf2_per_objfile.
175 <read_in_chain>: Remove.
176 (struct dwarf2_per_objfile) <get_cu, set_cu, remove_cu,
177 remove_all_cus, age_comp_units>: New methods.
178 <m_dwarf2_cus>: New member.
179 (struct dwarf2_per_cu_data) <cu>: Remove.
180 * dwarf2/read.c (struct dwarf2_cu) <read_in_chain>: Remove.
181 (age_cached_comp_units, free_one_cached_comp_unit): Remove,
182 moved to methods of dwarf2_per_objfile.
183 (dwarf2_clear_marks): Remove.
184 (dwarf2_queue_item::~dwarf2_queue_item): Update.
185 (dwarf2_per_bfd::~dwarf2_per_bfd): Don't free dwarf2_cus.
186 (dwarf2_per_bfd::free_cached_comp_units): Remove.
187 (dwarf2_per_objfile::remove_all_cus): New.
188 (class free_cached_comp_units) <~free_cached_comp_units>:
189 Update.
190 (load_cu): Update.
191 (dw2_do_instantiate_symtab): Adjust.
192 (fill_in_sig_entry_from_dwo_entry): Adjust.
193 (cutu_reader::init_tu_and_read_dwo_dies): Update.
194 (cutu_reader::cutu_reader): Likewise.
195 (cutu_reader::keep): Use dwarf2_per_objfile::set_cu.
196 (cutu_reader::cutu_reader): Use dwarf2_per_objfile::get_cu.
197 (process_psymtab_comp_unit): Use dwarf2_per_objfile::remove_cu
198 and dwarf2_per_objfile::age_comp_units.
199 (load_partial_comp_unit): Update.
200 (maybe_queue_comp_unit): Use dwarf2_per_objfile::get_cu.
201 (process_queue): Likewise.
202 (find_partial_die): Use dwarf2_per_objfile::get_cu instead of cu
203 backlink.
204 (dwarf2_read_addr_index): Likewise.
205 (follow_die_offset): Likewise.
206 (dwarf2_fetch_die_loc_sect_off): Likewise.
207 (dwarf2_fetch_constant_bytes): Likewise.
208 (dwarf2_fetch_die_type_sect_off): Likewise.
209 (follow_die_sig_1): Likewise.
210 (load_full_type_unit): Likewise.
211 (read_signatured_type): Likewise.
212 (dwarf2_cu::dwarf2_cu): Don't set cu field.
213 (dwarf2_cu::~dwarf2_cu): Remove.
214 (dwarf2_per_objfile::get_cu): New.
215 (dwarf2_per_objfile::set_cu): New.
216 (age_cached_comp_units): Rename to...
217 (dwarf2_per_objfile::age_comp_units): ... this. Adjust
218 to std::unordered_map.
219 (free_one_cached_comp_unit): Rename to...
220 (dwarf2_per_objfile::remove_cu): ... this. Adjust
221 to std::unordered_map.
222 (dwarf2_per_objfile::~dwarf2_per_objfile): New.
223 (dwarf2_mark_helper): Use dwarf2_per_objfile::get_cu, expect
224 a dwarf2_per_objfile in data.
225 (dwarf2_mark): Pass dwarf2_per_objfile in data to htab_traverse.
226 (dwarf2_clear_marks): Remove.
227
228 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
229
230 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Replace
231 `int use_existing_cu` parameter with `dwarf2_cu *existing_cu`.
232 (init_tu_and_read_dwo_dies): Likewise.
233 (cutu_reader::init_tu_and_read_dwo_dies): Likewise.
234 (cutu_reader::cutu_reader): Likewise.
235 (load_partial_comp_unit): Likewise.
236 (process_psymtab_comp_unit): Update.
237 (build_type_psymtabs_1): Update.
238 (process_skeletonless_type_unit): Update.
239 (load_full_comp_unit): Update.
240 (find_partial_die): Update.
241 (dwarf2_read_addr_index): Update.
242 (read_signatured_type): Update.
243
244 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
245
246 * dwarf2/read.h (struct dwarf2_per_cu_data) <m_header,
247 m_header_read_in>: New fields.
248 <get_header>: New method.
249 * dwarf2/read.c (per_cu_header_read_in): Remove.
250 (dwarf2_per_cu_data::get_header): New.
251 (dwarf2_per_cu_data::addr_size): Update.
252 (dwarf2_per_cu_data::offset_size): Update.
253 (dwarf2_per_cu_data::ref_addr_size): Update.
254
255 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
256
257 * dwarf2/read.c (load_cu): Return dwarf2_cu.
258 (dw2_do_instantiate_symtab): Update.
259 (queue_and_load_all_dwo_tus): Change parameter from
260 dwarf2_per_cu_data to dwarf2_cu.
261 (dwarf2_fetch_die_loc_sect_off): Update.
262 (dwarf2_fetch_constant_bytes): Update.
263 (dwarf2_fetch_die_type_sect_off): Update.
264
265 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
266
267 * dwarf2/read.c (process_full_comp_unit,
268 process_full_type_unit): Remove per_cu, per_objfile paramters.
269 Add dwarf2_cu parameter.
270 (process_queue): Update.
271
272 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
273
274 * dwarf2/read.c (create_cu_from_index_list): Replace
275 dwarf2_per_objfile parameter with dwarf2_per_bfd.
276 (create_cus_from_index_list): Likewise.
277 (create_cus_from_index): Likewise.
278 (create_signatured_type_table_from_index): Likewise.
279 (create_cus_from_debug_names_list): Likewise.
280 (create_cus_from_debug_names): Likewise.
281 (dwarf2_read_gdb_index): Update.
282 (dwarf2_read_debug_names): Update.
283
284 2020-05-27 Tom Tromey <tom@tromey.com>
285 Simon Marchi <simon.marchi@efficios.com>
286
287 * dwarf2/read.h (struct dwarf2_per_objfile)
288 <get_type_for_signatured_type, set_type_for_signatured_type>:
289 New methods.
290 <m_type_map>: New member.
291 (struct signatured_type) <type>: Remove.
292 * dwarf2/read.c
293 (dwarf2_per_objfile::get_type_for_signatured_type,
294 dwarf2_per_objfile::set_type_for_signatured_type): New.
295 (get_signatured_type): Use new methods.
296
297 2020-05-27 Tom Tromey <tom@tromey.com>
298 Simon Marchi <simon.marchi@efficios.com>
299
300 * dwarf2/read.h (struct type_unit_group_unshareable): New.
301 (struct dwarf2_per_objfile) <type_units>: New member.
302 <get_type_unit_group_unshareable>: New method.
303 * dwarf2/read.c (struct type_unit_group) <compunit_symtab,
304 num_symtabs, symtabs>: Remove; move to
305 type_unit_group_unshareable.
306 (dwarf2_per_objfile::get_type_unit_group_unshareable): New.
307 (process_full_type_unit, dwarf2_cu::setup_type_unit_groups)
308 (dwarf2_cu::setup_type_unit_groups): Use type_unit_group_unshareable.
309
310 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
311
312 * dwarf2/read.h (struct dwarf2_per_cu_data):
313 <dwarf2_per_objfile>: Remove.
314 * dwarf2/read.c (create_cu_from_index_list): Don't assign
315 dwarf2_per_objfile.
316 (create_signatured_type_table_from_index): Likewise.
317 (create_signatured_type_table_from_debug_names): Likewise.
318 (create_debug_type_hash_table): Likewise.
319 (fill_in_sig_entry_from_dwo_entry): Likewise.
320 (create_type_unit_group): Likewise.
321 (read_comp_units_from_section): Likewise.
322 (create_cus_hash_table): Likewise.
323
324 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
325
326 * dwarf2/read.c (process_psymtab_comp_unit): Remove reference to
327 dwarf2_per_cu_data::dwarf2_per_objfile.
328 (compute_compunit_symtab_includes): Likewise.
329 (dwarf2_cu::start_symtab): Likewise.
330
331 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
332
333 * dwarf2/read.h (dwarf2_get_die_type): Add dwarf2_per_objfile
334 parameter.
335 * dwarf2/read.c (get_die_type_at_offset): Likewise.
336 (read_namespace_alias): Update.
337 (lookup_die_type): Update.
338 (dwarf2_get_die_type): Add dwarf2_per_objfile parameter.
339 * dwarf2/loc.c (class dwarf_evaluate_loc_desc) <get_base_type>:
340 Update.
341 (disassemble_dwarf_expression): Update.
342
343 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
344
345 * dwarf2/read.h (struct dwarf2_queue_item): Add
346 dwarf2_per_objfile parameter, assign new parameter.
347 <per_objfile>: New field.
348 * dwarf2/read.c (free_one_cached_comp_unit): Add
349 dwarf2_per_objfile parameter.
350 (queue_comp_unit): Likewise.
351 (dw2_do_instantiate_symtab): Update.
352 (process_psymtab_comp_unit): Update.
353 (maybe_queue_comp_unit): Add dwarf2_per_objfile parameter.
354 (process_imported_unit_die): Update.
355 (queue_and_load_dwo_tu): Update.
356 (follow_die_offset): Update.
357 (follow_die_sig_1): Update.
358
359 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
360
361 * dwarf2/read.h (struct dwarf2_per_cu_data) <objfile>: Remove.
362 * dwarf2/read.c (dwarf2_compute_name): Pass per_objfile down.
363 (read_call_site_scope): Assign per_objfile.
364 (dwarf2_per_cu_data::objfile): Remove.
365 * gdbtypes.h (struct call_site) <per_objfile>: New member.
366 * dwarf2/loc.h (dwarf2_evaluate_loc_desc): Add
367 dwarf2_per_objfile parameter.
368 * dwarf2/loc.c (dwarf2_evaluate_loc_desc_full): Add
369 dwarf2_per_objfile parameter.
370 (dwarf_expr_reg_to_entry_parameter): Add output
371 dwarf2_per_objfile parameter.
372 (locexpr_get_frame_base): Update.
373 (class dwarf_evaluate_loc_desc) <get_tls_address>: Update.
374 <push_dwarf_reg_entry_value>: Update.
375 <call_site_to_target_addr>: Update.
376 (dwarf_entry_parameter_to_value): Add dwarf2_per_objfile
377 parameter.
378 (value_of_dwarf_reg_entry): Update.
379 (rw_pieced_value): Update.
380 (indirect_synthetic_pointer): Update.
381 (dwarf2_evaluate_property): Update.
382 (dwarf2_loc_desc_get_symbol_read_needs): Add dwarf2_per_objfile
383 parameter.
384 (locexpr_read_variable): Update.
385 (locexpr_get_symbol_read_needs): Update.
386 (loclist_read_variable): Update.
387
388 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
389
390 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
391 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
392 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
393 parameter.
394 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
395 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
396 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
397 parameter.
398 * dwarf2/loc.c (indirect_synthetic_pointer, per_cu_dwarf_call,
399 sect_variable_value): Add dwarf2_per_objfile parameter.
400 (class dwarf_evaluate_loc_desc) <dwarf_call,
401 dwarf_variable_value>: Update.
402 (fetch_const_value_from_synthetic_pointer): Add
403 dwarf2_per_objfile parameter.
404 (fetch_const_value_from_synthetic_pointer): Update.
405 (coerced_pieced_ref): Update.
406 (class symbol_needs_eval_context) <dwarf_call,
407 dwarf_variable_value>: Update.
408 (dwarf2_compile_expr_to_ax): Update.
409
410 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
411
412 * dwarf2/loc.c (allocate_piece_closure): Add dwarf2_per_objfile
413 parameter.
414 (dwarf2_evaluate_loc_desc_full): Update.
415
416 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
417
418 * dwarf2/read.h (dwarf2_read_addr_index): Add dwarf2_per_objfile
419 parameter.
420 * dwarf2/read.c (dwarf2_read_addr_index): Likewise.
421 * dwarf2/loc.c (decode_debug_loclists_addresses): Add
422 dwarf2_per_objfile parameter.
423 (decode_debug_loc_dwo_addresses): Likewise.
424 (dwarf2_find_location_expression): Update.
425 (class dwarf_evaluate_loc_desc) <get_addr_index>: Update.
426 (locexpr_describe_location_piece): Add dwarf2_per_objfile
427 parameter.
428 (disassemble_dwarf_expression): Add dwarf2_per_objfile
429 parameter.
430 (locexpr_describe_location_1): Likewise.
431 (locexpr_describe_location): Update.
432
433 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
434
435 * dwarf2/read.h (struct dwarf2_per_cu_data) <text_offset>:
436 Remove.
437 * dwarf2/read.c (dwarf2_per_cu_data::text_offset): Remove.
438 * dwarf2/loc.c (dwarf2_find_location_expression): Update.
439 (dwarf2_compile_property_to_c): Update.
440 (dwarf2_compile_expr_to_ax): Add dwarf2_per_objfile parameter,
441 use text offset from objfile.
442 (locexpr_tracepoint_var_ref): Update.
443 (locexpr_generate_c_location): Update.
444 (loclist_describe_location): Update.
445 (loclist_tracepoint_var_ref): Update.
446 * dwarf2/compile.h (compile_dwarf_bounds_to_c): Add
447 dwarf2_per_objfile parameter.
448 * dwarf2/loc2c.c (do_compile_dwarf_expr_to_c): Likewise,
449 use text offset from objfile.
450 (compile_dwarf_expr_to_c): Add dwarf2_per_objfile parameter.
451
452 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
453
454 * dwarf2/expr.h (struct dwarf_expr_context)
455 <dwarf_expr_context>: Add dwarf2_per_objfile parameter.
456 <offset>: Remove.
457 <per_objfile>: New member.
458 * dwarf2/expr.c (dwarf_expr_context::dwarf_expr_context): Add
459 dwarf2_per_objfile parameter. Don't set offset, set
460 per_objfile.
461 (dwarf_expr_context::execute_stack_op): Use offset from objfile.
462 * dwarf2/frame.c (dwarf2_frame_find_fde): Return (by parameter)
463 a dwarf2_per_objfile object instead of an offset.
464 (class dwarf_expr_executor) <dwarf_expr_executor>: Add
465 constructor.
466 (execute_stack_op): Add dwarf2_per_objfile parameter, pass it
467 to dwarf2_expr_executor constructor. Don't set offset.
468 (dwarf2_fetch_cfa_info): Update.
469 (struct dwarf2_frame_cache) <text_offset>: Remove.
470 <per_objfile>: New field.
471 (dwarf2_frame_cache): Update.
472 (dwarf2_frame_prev_register): Update.
473 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
474 <dwarf_evaluate_loc_desc>: Add constructor.
475 (dwarf2_evaluate_loc_desc_full): Update.
476 (dwarf2_locexpr_baton_eval): Update.
477 (class symbol_needs_eval_context) <symbol_needs_eval_context>:
478 Add constructor.
479 (dwarf2_loc_desc_get_symbol_read_needs): Update.
480
481 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
482
483 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_type,
484 addr_sized_int_type>: Move to dwarf2_cu.
485 <int_type>: Move to dwarf2_per_objfile.
486 (struct dwarf2_per_objfile) <int_type>: Move here.
487 * dwarf2/read.c (struct dwarf2_cu) <addr_type,
488 addr_sized_int_type>: Move here.
489 (read_func_scope): Update.
490 (read_array_type): Update.
491 (read_tag_string_type): Update.
492 (attr_to_dynamic_prop): Update.
493 (dwarf2_per_cu_data::int_type): Rename to...
494 (dwarf2_per_objfile::int_type): ... this.
495 (dwarf2_per_cu_data::addr_sized_int_type): Rename to...
496 (dwarf2_cu::addr_sized_int_type): ... this.
497 (read_subrange_type): Update.
498 (dwarf2_per_cu_data::addr_type): Rename to...
499 (dwarf2_cu::addr_type): ... this.
500 (set_die_type): Update.
501
502 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
503
504 * dwarf2/read.c (queue_and_load_all_dwo_tus): Access per_objfile
505 data through per_cu->cu.
506
507 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
508
509 * dwarf2/read.c (lookup_dwo_comp_unit): Change
510 dwarf2_per_cu_data parameter fo dwarf2_cu.
511 (lookup_dwo_type_unit): Likewise.
512 (read_cutu_die_from_dwo): Likewise.
513 (lookup_dwo_unit): Likewise.
514 (open_and_init_dwo_file): Likewise.
515 (lookup_dwo_cutu): Likewise.
516 (lookup_dwo_comp_unit): Likewise.
517 (lookup_dwo_type_unit): Likewise.
518 (cutu_reader::init_tu_and_read_dwo_dies): Update.
519 (cutu_reader::cutu_reader): Update.
520
521 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
522
523 * dwarf2/read.c (process_full_comp_unit): Add dwarf2_per_objfile
524 parameter.
525 (process_full_type_unit): Likewise.
526 (process_queue): Update.
527
528 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
529
530 * dwarf2/read.c (recursively_compute_inclusions): Add
531 dwarf2_per_objfile parameter.
532 (compute_compunit_symtab_includes): Likewise.
533 (process_cu_includes): Update.
534
535 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
536
537 * dwarf2/read.c (create_partial_symtab): Add dwarf2_per_objfile
538 parameter.
539 (create_type_unit_group): Update.
540 (process_psymtab_comp_unit_reader): Update.
541 (build_type_psymtabs_reader): Update.
542
543 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
544
545 * dwarf2/read.c (cutu_reader::keep): Access dwarf2_per_objfile
546 object through m_this_cu->cu.
547
548 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
549
550 * dwarf2/read.c (queue_and_load_dwo_tu): Expect a dwarf2_cu as
551 the info parameter.
552 (queue_and_load_all_dwo_tus): Pass per_cu->cu.
553
554 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
555
556 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Add
557 per_objfile parameter.
558 (load_full_type_unit): Add per_objfile parameter.
559 (read_signatured_type): Likewise.
560 (load_full_comp_unit): Likewise.
561 (load_cu): Likewise.
562 (dw2_do_instantiate_symtab): Likewise.
563 (dw2_get_file_names): Likewise.
564 (dw2_map_symtabs_matching_filename): Update.
565 (dw_expand_symtabs_matching_file_matcher): Update.
566 (dw2_map_symbol_filenames): Update.
567 (process_psymtab_comp_unit): Add per_objfile parameter.
568 (build_type_psymtabs_1): Update.
569 (process_skeletonless_type_unit): Update.
570 (dwarf2_build_psymtabs_hard): Update.
571 (load_partial_comp_unit): Add per_objfile parameter.
572 (scan_partial_symbols): Update.
573 (load_full_comp_unit): Add per_objfile parameter.
574 (process_imported_unit_die): Update.
575 (create_cus_hash_table): Update.
576 (find_partial_die): Update.
577 (dwarf2_read_addr_index): Update.
578 (follow_die_offset): Update.
579 (dwarf2_fetch_die_loc_sect_off): Update.
580 (dwarf2_fetch_constant_bytes): Update.
581 (dwarf2_fetch_die_type_sect_off): Update.
582 (follow_die_sig_1): Update.
583 (load_full_type_unit): Add per_objfile parameter.
584 (read_signatured_type): Likewise.
585
586 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
587
588 * dwarf2/read.c (lookup_dwo_unit): Use bfd_get_filename instead
589 of objfile_name.
590
591 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
592
593 * dwarf2/read.h (struct dwarf2_per_bfd) <obfd>: New member.
594 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
595 * dwarf2/read.c (dwarf2_per_bfd::dwarf2_per_bfd): Assign obfd
596 field.
597 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
598 (create_cus_from_index): Update.
599 (dwarf2_read_gdb_index): Update.
600 (create_cus_from_debug_names): Update.
601 (dwarf2_read_debug_names): Update.
602 (get_abbrev_section_for_cu): Update.
603 (create_all_comp_units): Update.
604 (read_attribute_value): Update.
605 (get_debug_line_section): Update.
606 * dwarf2/index-cache.c (index_cache::store): Update.
607 * dwarf2/index-write.c (save_gdb_index_command): Update.
608 * dwarf2/macro.c (dwarf_decode_macro_bytes): Update.
609
610 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
611
612 * dwarf2/read.h (struct dwarf2_per_cu_data) <per_bfd>: New
613 member.
614 * dwarf2/read.c (dwarf2_per_bfd::allocate_per_cu): Initialize
615 dwarf2_per_cu_data::per_bfd.
616 (dwarf2_per_bfd::allocate_signatured_type): Likewise.
617 (create_type_unit_group): Likewise.
618 (queue_comp_unit): Remove reference to
619 per_cu->dwarf2_per_objfile.
620 (maybe_queue_comp_unit): Likewise.
621 (fill_in_sig_entry_from_dwo_entry): Assign new field.
622 (create_cus_hash_table): Assign new field.
623
624 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
625
626 * dwarf2/read.c: Replace
627 dwarf2_cu->per_cu->dwarf2_per_objfile references with
628 dwarf2_cu->per_objfile throughout.
629
630 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
631
632 * dwarf2/read.c (dw2_do_instantiate_symtab): Add per_objfile
633 parameter, don't use per_cu->dwarf2_per_objfile.
634 (dw2_instantiate_symtab): Likewise.
635 (dw2_find_last_source_symtab): Update.
636 (dw2_map_expand_apply): Update.
637 (dw2_lookup_symbol): Update.
638 (dw2_expand_symtabs_for_function): Update.
639 (dw2_expand_all_symtabs): Update.
640 (dw2_expand_symtabs_with_fullname): Update.
641 (dw2_expand_symtabs_matching_one): Add per_objfile parameter,
642 don't use per_cu->dwarf2_per_objfile.
643 (dw2_expand_marked_cus): Update.
644 (dw2_find_pc_sect_compunit_symtab): Update.
645 (dw2_debug_names_lookup_symbol): Update.
646 (dw2_debug_names_expand_symtabs_for_function): Update.
647 (dw2_debug_names_map_matching_symbols): Update.
648 (dwarf2_psymtab::expand_psymtab): Update.
649
650 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
651
652 * dwarf2/read.c (struct dwarf2_cu) <dwarf2_cu>: Add parameter.
653 <per_objfile>: New member.
654 (class cutu_reader) <init_tu_and_read_dwo_dies>: Add parameter.
655 (cutu_reader::init_tu_and_read_dwo_dies): Add parameter, update
656 call to dwarf2_cu.
657 (cutu_reader::cutu_reader): Update.
658 (dwarf2_cu::dwarf2_cu): Add parameter, initialize per_objfile.
659
660 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
661
662 * dwarf2/read.h (struct dwarf2_per_bfd) <die_type_hash>: Move to
663 struct dwarf2_per_objfile.
664 (struct dwarf2_per_objfile) <die_type_hash>: Move from struct
665 dwarf2_per_bfd.
666 * dwarf2/read.c (set_die_type): Update.
667 (get_die_type_at_offset): Update.
668
669 2020-05-27 Tom Tromey <tom@tromey.com>
670 Simon Marchi <simon.marchi@efficios.com>
671
672 * dwarf2/read.h (struct dwarf2_per_bfd) <num_psymtabs>: New
673 method.
674 (struct dwarf2_per_objfile) <resize_symtabs, symtab_set_p,
675 get_symtab, set_symtab>: New methods.
676 <m_symtabs>: New field.
677 (struct dwarf2_psymtab): Derive from partial_symtab.
678 <readin_p, get_compunit_symtab>: Declare methods.
679 * dwarf2/read.c (dwarf2_per_objfile::symtab_set_p,
680 dwarf2_per_objfile::get_symtab, dwarf2_per_objfile::set_symtab):
681 New methods.
682 (struct dwarf2_per_cu_quick_data) <compunit_symtab>: Remove.
683 (dw2_do_instantiate_symtab, dw2_instantiate_symtab)
684 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
685 (dw2_symtab_iter_next, dw2_print_stats)
686 (dw2_expand_symtabs_with_fullname)
687 (dw2_expand_symtabs_matching_one)
688 (dw_expand_symtabs_matching_file_matcher)
689 (dw2_find_pc_sect_compunit_symtab, dw2_map_symbol_filenames)
690 (dw2_debug_names_iterator::next)
691 (dw2_debug_names_map_matching_symbols)
692 (fill_in_sig_entry_from_dwo_entry, dwarf2_psymtab::read_symtab)
693 (process_queue, dwarf2_psymtab::expand_psymtab): Update.
694 (dwarf2_psymtab::readin_p, dwarf2_psymtab::get_compunit_symtab):
695 New methods.
696 (get_compunit_symtab, process_full_comp_unit)
697 (process_full_type_unit): Update.
698 (dwarf2_build_psymtabs, dwarf2_initialize_objfile, add_type_unit): Call
699
700 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
701
702 * dwarf2/read.h (dwarf2_per_objfile): Rename to dwarf2_per_bfd,
703 then introduce a new dwarf2_per_objfile type.
704 <read_line_string>: Move to the new dwarf2_per_objfile type.
705 <objfile>: Likewise.
706 (dwarf2_per_bfd): Rename dwarf2_per_objfile to this.
707 * dwarf2/read.c: Replace references to dwarf2_per_objfile with
708 dwarf2_per_objfile->per_bfd.
709 (dwarf2_per_objfile::dwarf2_per_objfile): Rename to...
710 (dwarf2_per_bfd::dwarf2_per_bfd): ... this.
711 (dwarf2_per_objfile::free_cached_comp_units): Rename to...
712 (dwarf2_per_bfd::free_cached_comp_units): ... this.
713 (dwarf2_has_info): Allocate dwarf2_per_bfd.
714 (dwarf2_per_objfile::locate_sections): Rename to...
715 (dwarf2_per_bfd::locate_sections): ... this.
716 (dwarf2_per_objfile::get_cutu): Rename to...
717 (dwarf2_per_bfd::get_cutu): ... this.
718 (dwarf2_per_objfile::get_cu): Rename to...
719 (dwarf2_per_bfd::get_cu): ... this.
720 (dwarf2_per_objfile::get_tu): Rename to...
721 (dwarf2_per_bfd::get_tu): ... this.
722 (dwarf2_per_objfile::allocate_per_cu): Rename to...
723 (dwarf2_per_bfd::allocate_per_cu): ... this.
724 (dwarf2_per_objfile::allocate_signatured_type): Rename to...
725 (dwarf2_per_bfd::allocate_signatured_type): ... this.
726 (get_gdb_index_contents_ftype): Change parameter from
727 dwarf2_per_objfile to dwarf2_per_bfd.
728 * dwarf2/macro.c, dwarf2/index-write.c: Replace references to
729 dwarf2_per_objfile with dwarf2_per_objfile->per_bfd.
730
731 2020-05-27 Tom Tromey <tom@tromey.com>
732 Simon Marchi <simon.marchi@efficios.com>
733
734 * dwarf2/loc.c (struct piece_closure) <per_objfile>: New member.
735 (allocate_piece_closure): Set "per_objfile" member.
736 (dwarf2_find_location_expression, dwarf2_locexpr_baton_eval)
737 (locexpr_describe_location, loclist_describe_location): Use new
738 member.
739 * dwarf2/read.c (read_call_site_scope)
740 (mark_common_block_symbol_computed, attr_to_dynamic_prop)
741 (dwarf2_const_value_attr, dwarf2_fetch_die_loc_sect_off)
742 (fill_in_loclist_baton, dwarf2_symbol_mark_computed,
743 handle_data_member_location): Set per_objfile member.
744 * dwarf2/loc.h (struct dwarf2_locexpr_baton) <per_objfile>: New
745 member.
746 (struct dwarf2_loclist_baton) <per_objfile>: New member.
747
748 2020-05-27 Tom Tromey <tom@tromey.com>
749
750 * dwarf2/read.h (struct dwarf2_per_objfile) <allocate_per_cu,
751 allocate_signatured_type>: Declare new methods.
752 <m_num_psymtabs>: New member.
753 (struct dwarf2_per_cu_data) <index>: New member.
754 * dwarf2/read.c (dwarf2_per_objfile::allocate_per_cu)
755 (dwarf2_per_objfile::allocate_signatured_type): New methods.
756 (create_cu_from_index_list): Use allocate_per_cu.
757 (create_signatured_type_table_from_index)
758 (create_signatured_type_table_from_debug_names)
759 (create_debug_type_hash_table, add_type_unit)
760 (read_comp_units_from_section): Use allocate_signatured_type.
761
762 2020-05-27 Tom Tromey <tom@tromey.com>
763
764 * psymtab.c (partial_map_expand_apply)
765 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
766 (psym_lookup_global_symbol_language)
767 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
768 (psym_print_stats, psym_expand_symtabs_for_function)
769 (psym_map_symbol_filenames, psym_map_matching_symbols)
770 (psym_expand_symtabs_matching)
771 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
772 (maintenance_check_psymtabs): Update.
773 * psympriv.h (struct partial_symtab) <readin_p,
774 get_compunit_symtab>: Add objfile parameter.
775 (struct standard_psymtab) <readin_p, get_compunit_symtab>:
776 Likewise.
777 * dwarf2/read.c (struct dwarf2_include_psymtab) <readin_p,
778 get_compunit_symtab>: Likewise.
779 (dwarf2_psymtab::expand_psymtab): Pass objfile argument.
780
781 2020-05-27 Tom Tromey <tom@tromey.com>
782
783 * dwarf2/read.h (struct dwarf2_per_objfile) <obstack>: New
784 member.
785 * dwarf2/read.c (delete_file_name_entry): Fix comment.
786 (create_cu_from_index_list)
787 (create_signatured_type_table_from_index)
788 (create_signatured_type_table_from_debug_names)
789 (dw2_get_file_names_reader, dwarf2_initialize_objfile)
790 (dwarf2_create_include_psymtab)
791 (create_debug_type_hash_table, add_type_unit)
792 (create_type_unit_group, read_comp_units_from_section)
793 (dwarf2_compute_name, create_cus_hash_table)
794 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
795 (create_dwo_unit_in_dwp_v2, open_and_init_dwp_file): Use new
796 obstack.
797 (dw2_get_real_path): Likewise. Change argument to
798 dwarf2_per_objfile.
799
800 2020-05-27 Luis Machado <luis.machado@linaro.org>
801
802 PR tdep/26000
803 * arm-tdep.c (thumb_analyze_prologue): Fix instruction matching
804 for ldrd (immediate).
805
806 2020-05-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
807
808 * command.h: Add comment giving the name of class_tui.
809 * cli/cli-cmds.c (_initialize_cli_cmds): If TUI defined,
810 create the fake command for the help for class_tui.
811
812 2020-05-26 Tom Tromey <tromey@adacore.com>
813
814 * ada-lang.c (ada_print_array_index): Change type. Call val_atr.
815 (ada_value_ptr_subscript): Don't call pos_atr on the lower bound.
816 (val_atr): New function.
817 (value_val_atr): Use it.
818 * ada-valprint.c (print_optional_low_bound): Change low bound
819 handling for enums.
820 (val_print_packed_array_elements): Don't call discrete_position.
821 * gdbtypes.c (get_discrete_bounds) <TYPE_CODE_RANGE>: Call
822 discrete_position for enum types.
823 * language.c (default_print_array_index): Change type.
824 * language.h (struct language_defn) <la_print_array_index>: Add
825 index_type parameter, change type of index_value.
826 (LA_PRINT_ARRAY_INDEX): Add index_type parameter.
827 (default_print_array_index): Update.
828 * valprint.c (maybe_print_array_index): Don't call
829 value_from_longest. Update.
830 (value_print_array_elements): Don't call discrete_position.
831
832 2020-05-26 Tom Tromey <tromey@adacore.com>
833
834 * ada-lang.c (value_val_atr): Handle TYPE_CODE_RANGE.
835 * gdbtypes.c (discrete_position): Handle TYPE_CODE_RANGE.
836
837 2020-05-25 Cristiano De Alti <cristiano_dealti@hotmail.com>
838
839 PR gdb/13519
840 * avr-tdep.c (avr_integer_to_address): Return data or code
841 address accordingly to the second 'type' argument of the
842 function.
843
844 2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
845
846 * infcmd.c, inferior.h: (construct_inferior_arguments):
847 Moved function from here to gdbsupport/common-inferior.{h,cc}
848
849 2020-05-23 Tom Tromey <tom@tromey.com>
850
851 Revert commit eca1f90c:
852 * NEWS: Remove entry for completion styling.
853 * completer.c (_rl_completion_prefix_display_length): Move
854 declaration later.
855 (gdb_fnprint): Revert.
856 (gdb_display_match_list_1): Likewise.
857 * cli/cli-style.c (completion_prefix_style)
858 (completion_difference_style, completion_suffix_style): Remove.
859 (_initialize_cli_style): Revert.
860 * cli/cli-style.h (completion_prefix_style)
861 (completion_difference_style, completion_suffix_style): Don't
862 declare.
863
864 2020-05-24 Pedro Alves <palves@redhat.com>
865
866 * symtab.c (completion_list_add_name): Return boolean indication
867 of whether the symbol matched.
868 (completion_list_add_symbol): Don't try to remove C++ aliases if
869 the symbol didn't match in the first place.
870 * symtab.h (completion_list_add_name): Return bool.
871
872 2020-05-23 Simon Marchi <simon.marchi@polymtl.ca>
873
874 * gdbtypes.h (TYPE_FIELD): Remove. Replace all uses with
875 type::field.
876
877 2020-05-23 Joel Brobecker <brobecker@adacore.com>
878
879 GDB 9.2 released.
880
881 2020-05-23 Tom Tromey <tom@tromey.com>
882
883 * NEWS: Add entry for completion styling.
884 * completer.c (_rl_completion_prefix_display_length): Move
885 declaration earlier.
886 (gdb_fnprint): Use completion_style.
887 (gdb_display_match_list_1): Likewise.
888 * cli/cli-style.c (completion_prefix_style)
889 (completion_difference_style, completion_suffix_style): New
890 globals.
891 (_initialize_cli_style): Register new globals.
892 * cli/cli-style.h (completion_prefix_style)
893 (completion_difference_style, completion_suffix_style): Declare.
894
895 2020-05-23 Pedro Alves <palves@redhat.com>
896
897 * utils.c: Include "gdbsupport/gdb-safe-ctype.h".
898 (parse_escape): Use ISDIGIT instead of isdigit.
899 (puts_debug): Use gdb_isprint instead of isprint.
900 (fprintf_symbol_filtered): Use ISALNUM instead of isalnum.
901 (cp_skip_operator_token, skip_ws, strncmp_iw_with_mode): Use
902 ISSPACE instead of isspace.
903 (strncmp_iw_with_mode): Use TOLOWER instead of tolower and ISSPACE
904 instead of isspace.
905 (strcmp_iw_ordered): Use ISSPACE instead of isspace.
906 (string_to_core_addr): Use TOLOWER instead of tolower, ISXDIGIT
907 instead of isxdigit and ISDIGIT instead of isdigit.
908
909 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
910
911 * gdbtypes.h (struct type) <field>: New method.
912 (TYPE_FIELDS): Remove, replace all uses with either type::fields
913 or type::field.
914
915 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
916
917 * gdbtypes.h (struct type) <fields, set_fields>: New methods.
918 (TYPE_FIELDS): Use type::fields. Change all call sites that
919 modify the propery to use type::set_fields instead.
920
921 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
922
923 * gdbtypes.h (TYPE_NFIELDS): Remove. Change all cal sites to use
924 type::num_fields instead.
925
926 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
927
928 * gdbtypes.h (struct type) <num_fields, set_num_fields>: New
929 methods.
930 (TYPE_NFIELDS): Use type::num_fields. Change all call sites
931 that modify the number of fields to use type::set_num_fields
932 instead.
933
934 2020-05-22 Tom Tromey <tromey@adacore.com>
935
936 * compile/compile-object-load.h (munmap_list_free): Don't
937 declare.
938
939 2020-05-22 Andrew Burgess <andrew.burgess@embecosm.com>
940
941 * annotate.c (annotate_source_line): Update return type, add call
942 to update current symtab and line.
943 * annotate.h (annotate_source_line): Update return type, and
944 extend header comment.
945 * source.c (info_line_command): Check annotation_level before
946 calling annotate_source_line.
947 * stack.c (print_frame_info): If calling annotate_source_line
948 returns true, then don't print any other source line information.
949
950 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
951
952 * lm32-tdep.c (lm32_register_reggroup_p): Fix condition.
953
954 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
955
956 * coffread.c (patch_type): Remove NULL check before xfree.
957 * corefile.c (set_gnutarget): Likewise.
958 * cp-abi.c (set_cp_abi_as_auto_default): Likewise.
959 * exec.c (build_section_table): Likewise.
960 * remote.c (remote_target::pass_signals): Likewise.
961 * utils.c (n_spaces): Likewise.
962 * cli/cli-script.c (document_command): Likewise.
963 * i386-windows-tdep.c (core_process_module_section): Likewise.
964 * linux-fork.c (struct fork_info) <~fork_info>: Likewise.
965
966 2020-05-20 Simon Marchi <simon.marchi@efficios.com>
967
968 * symfile.c (reread_symbols): Clear objfile's section_offsets
969 vector and section indices, re-compute them by calling
970 sym_offsets.
971
972 2020-05-20 Tom Tromey <tromey@adacore.com>
973
974 * ada-lang.c (bound_name, MAX_ADA_DIMENS): Remove.
975 (desc_one_bound, desc_index_type): Compute field name.
976
977 2020-05-20 Tom de Vries <tdevries@suse.de>
978
979 PR symtab/25833
980 * dwarf2/read.c (dw2_map_matching_symbols): Handle .gdb_index.
981
982 2020-05-20 Alan Modra <amodra@gmail.com>
983
984 PR 25993
985 * solib-darwin.c (darwin_bfd_open): Don't strdup pathname for
986 bfd_set_filename.
987 * solib-aix.c (solib_aix_bfd_open): Use std::string for name
988 passed to bfd_set_filename.
989 * symfile-mem.c (add_vsyscall_page): Likewise for string
990 passed to symbol_file_add_from_memory.
991 (symbol_file_add_from_memory): Make name param a const char* and
992 don't strdup.
993
994 2020-05-20 Alan Modra <amodra@gmail.com>
995
996 * coff-pe-read.c (read_pe_exported_syms): Use bfd_get_filename
997 rather than accessing bfd->filename directly.
998 * dtrace-probe.c (dtrace_static_probe_ops::get_probes): Likewise,
999 and use bfd_section_name.
1000 * dwarf2/frame.c (decode_frame_entry): Likewise.
1001 * exec.c (exec_set_section_address): Likewise.
1002 * solib-aix.c (solib_aix_bfd_open): Likewise.
1003 * stap-probe.c (get_stap_base_address): Likewise.
1004 * symfile.c (reread_symbols): Likewise.
1005
1006 2020-05-19 Tom Tromey <tromey@adacore.com>
1007
1008 * sparc64-tdep.c (adi_tag_fd): Update call to target_fileio_open.
1009
1010 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
1011
1012 * dwarf2/read.c (quirk_rust_enum): Allocate enough fields.
1013
1014 2020-05-19 Pedro Alves <palves@redhat.com>
1015
1016 * NEWS (set exec-file-mismatch): Adjust entry.
1017 * exec.c: Include "build-id.h".
1018 (validate_exec_file): Try to match build IDs instead of filenames.
1019 * gdb_bfd.c (struct gdb_bfd_open_closure): New.
1020 (gdb_bfd_iovec_fileio_open): Adjust to use gdb_bfd_open_closure
1021 and pass down 'warn_if_slow'.
1022 (gdb_bfd_open): Add 'warn_if_slow' parameter. Use
1023 gdb_bfd_open_closure to pass it down.
1024 * gdb_bfd.h (gdb_bfd_open): Add 'warn_if_slow' parameter.
1025
1026 2020-05-19 Pedro Alves <palves@redhat.com>
1027
1028 * gdb_bfd.c (gdb_bfd_iovec_fileio_open): Adjust.
1029 * target.c (target_fileio_open_1): Rename to target_fileio_open
1030 and make extern. Use bool.
1031 (target_fileio_open, target_fileio_open_warn_if_slow): Delete.
1032 (target_fileio_read_alloc_1): Adjust.
1033 * target.h (target_fileio_open): Add 'warn_if_slow' parameter.
1034 (target_fileio_open_warn_if_slow): Delete declaration.
1035
1036 2020-05-19 Pedro Alves <palves@redhat.com>
1037
1038 * gdb_bfd.h: (gdb_bfd_open): Default to 'fd' parameter to -1.
1039 Adjust all callers.
1040
1041 2020-05-19 Yoshinori Sato <ysato@users.sourceforge.jp>
1042
1043 * h8300-tdep.c (h8300_is_argument_spill): Change how we check
1044 whether disp is negative.
1045
1046 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
1047
1048 * symfile.h (struct symfile_segment_data)
1049 <~symfile_segment_data>: Remove.
1050 <segment_info>: Change to std::vector.
1051 * symfile.c (default_symfile_segments): Update.
1052 * elfread.c (elf_symfile_segments): Update.
1053
1054 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
1055
1056 * symfile.h (struct symfile_segment_data) <struct segment>: New.
1057 <segments>: New.
1058 <segment_bases, segment_sizes>: Remove.
1059 * symfile.c (default_symfile_segments): Update.
1060 * elfread.c (elf_symfile_segments): Update.
1061 * remote.c (remote_target::get_offsets): Update.
1062 * solib-target.c (solib_target_relocate_section_addresses):
1063 Update.
1064
1065 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
1066
1067 * symfile.h (struct symfile_segment_data): Initialize fields.
1068 <~symfile_segment_data>: Add.
1069 (symfile_segment_data_up): New.
1070 (struct sym_fns) <sym_segments>: Return a
1071 symfile_segment_data_up.
1072 (default_symfile_segments): Return a symfile_segment_data_up.
1073 (free_symfile_segment_data): Remove.
1074 (get_symfile_segment_data): Return a symfile_segment_data_up.
1075 * symfile.c (default_symfile_segments): Likewise.
1076 (get_symfile_segment_data): Likewise.
1077 (free_symfile_segment_data): Remove.
1078 (symfile_find_segment_sections): Update.
1079 * elfread.c (elf_symfile_segments): Return a
1080 symfile_segment_data_up.
1081 * remote.c (remote_target::get_offsets): Update.
1082 * solib-target.c (solib_target_relocate_section_addresses):
1083 Update.
1084 * symfile-debug.c (debug_sym_segments): Return a
1085 symfile_segment_data_up.
1086
1087 2020-05-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1088
1089 PR build/25981
1090 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64] (regmap):
1091 Hardcode register numbers.
1092
1093 PR build/25981
1094 * procfs.c [(__i386__ || __x86_64__) && sun] (proc_get_LDT_entry,
1095 procfs_find_LDT_entry): Remove.
1096 * procfs.h [(__i386__ || __x86_64__) && sun] (struct ssd,
1097 procfs_find_LDT_entry): Remove.
1098 * sol-thread.c [(__i386__ || __x86_64__) && sun] (ps_lgetLDT):
1099 Remove.
1100
1101 2020-05-17 Pedro Alves <palves@redhat.com>
1102 Andrew Burgess <andrew.burgess@embecosm.com>
1103 Keno Fischer <keno@juliacomputing.com>
1104
1105 PR gdb/25741
1106 * breakpoint.c (build_target_condition_list): Update comments.
1107 (build_target_command_list): Update comments and skip matching
1108 locations.
1109 (insert_bp_location): Move "set breakpoint auto-hw on" handling to
1110 a separate function. Simplify "set breakpoint auto-hw off"
1111 handling.
1112 (insert_breakpoints): Update comment.
1113 (tracepoint_locations_match): New parameter. For breakpoints,
1114 compare location types too, if the caller wants to.
1115 (handle_automatic_hardware_breakpoints): New functions.
1116 (bp_location_is_less_than): Also sort by location type and
1117 hardware breakpoint length.
1118 (update_global_location_list): Handle "set breakpoint auto-hw on"
1119 here.
1120 (update_breakpoint_locations): Ask breakpoint_locations_match to
1121 ignore location types.
1122
1123 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
1124
1125 * gdbtypes.h (TYPE_NAME): Remove. Change all cal sites to use
1126 type::name instead.
1127
1128 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
1129
1130 * gdbtypes.h (struct type) <name, set_name>: New methods.
1131 (TYPE_CODE): Use type::name. Change all call sites used to set
1132 the name to use type::set_name instead.
1133
1134 2020-05-16 Tom Tromey <tom@tromey.com>
1135
1136 * top.c (quit_force): Update.
1137 * infrun.c (handle_no_resumed): Update.
1138 * top.h (all_uis): New function.
1139 (ALL_UIS): Remove.
1140
1141 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
1142
1143 * mips-linux-tdep.c (mips_linux_in_dynsym_stub): Fix condition.
1144
1145 2020-05-16 Pedro Alves <palves@redhat.com>
1146
1147 * ia64-linux-nat.c
1148 (ia64_linux_nat_target) <enable_watchpoints_in_psr(ptid_t)>:
1149 Declare method.
1150 (enable_watchpoints_in_psr): Now a method of ia64_linux_nat_target.
1151
1152 2020-05-15 Simon Marchi <simon.marchi@efficios.com>
1153
1154 * sparc64-tdep.c (adi_stat_t): Remove typedef (leaving struct).
1155 (sparc64_adi_info): Likewise.
1156
1157 2020-05-15 Tom Tromey <tom@tromey.com>
1158
1159 * symtab.c (lookup_language_this, lookup_symbol_aux): Use
1160 block_objfile.
1161 (lookup_objfile_from_block): Remove.
1162 (lookup_symbol_in_block, lookup_symbol_in_static_block)
1163 (lookup_global_symbol): Use block_objfile.
1164 * symtab.h (lookup_objfile_from_block): Don't declare.
1165 * printcmd.c (clear_dangling_display_expressions): Use
1166 block_objfile.
1167 * parse.c (operator_check_standard): Use block_objfile.
1168
1169 2020-05-15 Tom Tromey <tom@tromey.com>
1170
1171 * language.c (language_alloc_type_symbol): Set
1172 SYMBOL_SECTION.
1173 * symtab.c (initialize_objfile_symbol): Remove.
1174 (allocate_symbol): Remove.
1175 (allocate_template_symbol): Remove.
1176 * dwarf2/read.c (fixup_go_packaging): Use "new".
1177 (new_symbol): Use "new".
1178 (read_variable): Don't call initialize_objfile_symbol. Use
1179 "new".
1180 (read_func_scope): Use "new".
1181 * xcoffread.c (process_xcoff_symbol): Don't call
1182 initialize_objfile_symbol.
1183 (SYMBOL_DUP): Remove.
1184 * coffread.c (process_coff_symbol, coff_read_enum_type): Use
1185 "new".
1186 * symtab.h (allocate_symbol, initialize_objfile_symbol)
1187 (allocate_template_symbol): Don't declare.
1188 (struct symbol): Add copy constructor. Change defaults.
1189 * jit.c (finalize_symtab): Use "new".
1190 * ctfread.c (ctf_add_enum_member_cb, new_symbol, ctf_add_var_cb):
1191 Use "new".
1192 * stabsread.c (patch_block_stabs, define_symbol, read_enum_type)
1193 (common_block_end): Use "new".
1194 * mdebugread.c (parse_symbol): Use "new".
1195 (new_symbol): Likewise.
1196
1197 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1198
1199 * NEWS: Mention changes to help and apropos.
1200
1201 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1202
1203 * command.h (enum command_class): Improve comments, document
1204 that class_alias is for user-defined aliases, give the class
1205 name for each class, remove unused class_xdb.
1206 * cli/cli-decode.c (add_com_alias): Document THECLASS intended usage.
1207 * breakpoint.c (_initialize_breakpoint): Replace class_alias
1208 by a precise class.
1209 * infcmd.c (_initialize_infcmd): Likewise.
1210 * reverse.c (_initialize_reverse): Likewise.
1211 * stack.c (_initialize_stack): Likewise.
1212 * symfile.c (_initialize_symfile): Likewise.
1213 * tracepoint.c (_initialize_tracepoint): Likewise.
1214
1215 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1216
1217 * cli/cli-decode.c (apropos_cmd): Produce output for aliases
1218 when their aliased command is traversed.
1219 (help_cmd): Add fput_command_names_styled call to
1220 output command name and aliases when command has an alias.
1221
1222 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1223
1224 * cli/cli-decode.h (help_cmd_list): Remove declaration.
1225 * cli/cli-decode.c (help_cmd_list): Declare as static,
1226 remove prefix argument, use bool for recurse arg, rework to show the aliases of
1227 a command together with the command.
1228 (fput_command_name_styled, fput_command_names_styled): New functions.
1229 (print_help_for_command): Remove prefix arg, use bool for recurse arg, use
1230 fput_command_name_styled.
1231 (help_list, help_all): Update callers to remove prefix arg and use bool recurse.
1232 * cli/cli-cmds.c (_initialize_cli_cmds): Update alias_command doc.
1233
1234 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1235
1236 * cli/cli-setshow.h (cmd_show_list): Remove prefix argument.
1237 * cli/cli-decode.c (do_show_prefix_cmd): Likewise.
1238 * command.h (cmd_show_list): Likewise.
1239 * dwarf2/index-cache.c (show_index_cache_command): Likewise.
1240 * cli/cli-setshow.c (cmd_show_list): Use the prefix to produce the output. Skip aliases.
1241
1242 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1243
1244 * unittests/command-def-selftests.c (traverse_command_structure):
1245 Verify all commands of a list have the same prefix command and
1246 that only the top cmdlist commands have a null prefix.
1247
1248 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1249
1250 * cli/cli-decode.c (lookup_cmd_for_prefix): Return the aliased command
1251 as prefix, not one of its aliases.
1252 (set_cmd_prefix): Remove.
1253 (do_add_cmd): Centralize the setting of the prefix of a command, when
1254 command is defined after its full chain of prefix commands.
1255 (add_alias_cmd): Remove call to set_cmd_prefix, as do_add_cmd does it.
1256 (add_setshow_cmd_full): Likewise.
1257 (update_prefix_field_of_prefixed_commands): New function.
1258 (add_prefix_cmd): Replace non working call to set_cmd_prefix by
1259 update_prefix_field_of_prefixed_commands.
1260 * gdb/remote-fileio.c (initialize_remote_fileio): Use the real
1261 addresses of remote_set_cmdlist and remote_show_cmdlist given
1262 as argument, not the address of an argument.
1263 * gdb/remote-fileio.h (initialize_remote_fileio): Likewise.
1264 * gdb/remote.c (_initialize_remote): Likewise.
1265
1266 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1267
1268 * cli/cli-cmds.c (alias_command): Check for an existing alias
1269 using lookup_cmd_composition, as valid_command_p is too strict
1270 and forbids aliases that are the prefix of an existing alias
1271 or command.
1272 * cli/cli-decode.c (lookup_cmd_composition): Ensure a prefix
1273 command is properly recognised as a valid command.
1274
1275 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1276
1277 * unittests/help-doc-selftests.c: Rename to
1278 unittests/command-def-selftests.c
1279 * unittests/command-def-selftests.c (help_doc_tests): Update some
1280 comments.
1281 (command_structure_tests, traverse_command_structure): New namespace
1282 and function.
1283 (command_structure_invariants_tests): New function.
1284 (_initialize_command_def_selftests) Renamed from
1285 _initialize_help_doc_selftests, register command_structure_invariants
1286 selftest.
1287
1288 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1289
1290 * cli/cli-cmds.c (_initialize_cli_cmds): Define 'info set' as
1291 an alias of 'show'.
1292
1293 2020-05-15 Joel Brobecker <brobecker@adacore.com>
1294
1295 * ada-lang.h: (ada_is_gnat_encoded_fixed_point_type): Renames
1296 ada_is_fixed_point_type. Update all callers.
1297 (gnat_encoded_fixed_point_delta): Renames ada_delta. Update
1298 all callers.
1299 * ada-lang.c (gnat_encoded_fixed_type_info): Renames fixed_type_info.
1300 Update all callers.
1301 * ada-typeprint.c (print_gnat_encoded_fixed_point_type): Renames
1302 print_fixed_point_type. Update all callers.
1303 * ada-valprint.c (ada_value_print_num): Replace call to
1304 ada_is_fixed_point_type by ada_is_gnat_encoded_fixed_point_type.
1305
1306 2020-05-14 Kevin Buettner <kevinb@redhat.com>
1307
1308 * nat/linux-btrace.c (btrace_this_cpu): Add check for AMD
1309 processors.
1310 (cpu_supports_bts): Add CV_AMD case.
1311
1312 2020-05-14 Laurent Morichetti <Laurent.Morichetti@amd.com>
1313 Simon Marchi <simon.marchi@efficios.com>
1314
1315 * infrun.c (stop_all_threads): Collect multiple wait events at
1316 each pass.
1317
1318 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
1319
1320 * gdbtypes.h (TYPE_CODE): Remove. Change all call sites to use
1321 type::code instead.
1322
1323 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
1324
1325 * gdbtypes.h (struct type) <code, set_code>: New methods.
1326 (TYPE_CODE): Use type::code. Change all call sites used to set
1327 the code to use type::set_code instead.
1328
1329 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1330 Tom de Vries <tdevries@suse.de>
1331 Pedro Alves <palves@redhat.com>
1332
1333 PR threads/25478
1334 * infrun.c (stop_all_threads): Do NOT ignore
1335 TARGET_WAITKIND_NO_RESUMED, TARGET_WAITKIND_THREAD_EXITED,
1336 TARGET_WAITKIND_EXITED, TARGET_WAITKIND_SIGNALLED wait statuses
1337 received.
1338 (handle_no_resumed): Remove code handling a live inferior with no
1339 threads.
1340 * remote.c (has_single_non_exited_thread): New.
1341 (remote_target::update_thread_list): Do not delete a thread if is
1342 the last thread of the process.
1343 * thread.c (thread_select): Call delete_exited_threads instead of
1344 prune_threads.
1345
1346 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1347
1348 * infrun.c (stop_all_threads): Enable/disable thread events of all
1349 targets. Move a debug message denoting the end of the function
1350 into the SCOPED_EXIT block.
1351
1352 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1353
1354 * process-stratum-target.h: Include <set>.
1355 (all_non_exited_process_targets, switch_to_target_no_thread): New
1356 function declarations.
1357 * process-stratum-target.c (all_non_exited_process_targets)
1358 (switch_to_target_no_thread): New function implementations.
1359
1360 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1361
1362 * infrun.c (handle_inferior_event): Extract out a piece of code
1363 into...
1364 (mark_non_executing_threads): ...this new function.
1365
1366 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1367
1368 * infrun.c (resume_1): Move a 'regcache_read_pc' call down to first
1369 use.
1370
1371 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1372
1373 * regcache.c (regcache_read_pc_protected): New function
1374 implementation that returns 0 if the PC cannot read via
1375 'regcache_read_pc'.
1376 * infrun.c (proceed): Call 'regcache_read_pc_protected'
1377 instead of 'regcache_read_pc'.
1378 (keep_going_pass_signal): Ditto.
1379
1380 2020-05-13 Tom Tromey <tromey@adacore.com>
1381
1382 * ada-lang.c (align_value): Remove.
1383 (ada_template_to_fixed_record_type_1): Use align_up.
1384
1385 2020-05-13 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1386
1387 * async-event.c: Update the copyright year.
1388 * async-event.h: Update the copyright year.
1389
1390 2020-05-12 Simon Marchi <simon.marchi@efficios.com>
1391
1392 * objfiles.h (is_addr_in_objfile,
1393 shared_objfile_contains_address_p): Return bool.
1394 * objfile.c (is_addr_in_objfile,
1395 shared_objfile_contains_address_p): Return bool.
1396
1397 2020-05-11 Tom Tromey <tromey@adacore.com>
1398
1399 * cli/cli-cmds.c (info_command): Restore.
1400 (_initialize_cli_cmds): Use add_prefix_command for "info".
1401 * gdb-gdb.gdb.in: Restore breakpoint on info_command.
1402
1403 2020-05-11 Tom Tromey <tromey@adacore.com>
1404
1405 * ada-lang.c (ada_value_primitive_field): Now public.
1406 * ada-lang.h (ada_value_primitive_field): Declare.
1407 * ada-valprint.c (print_field_values): Use
1408 ada_value_primitive_field for wrapper fields.
1409
1410 2020-05-11 Tom de Vries <tdevries@suse.de>
1411
1412 * dwarf2/index-write.c (debug_names::psymbol_tag): Handle
1413 MODULE_DOMAIN.
1414
1415 2020-05-11 Tom de Vries <tdevries@suse.de>
1416
1417 PR symtab/25941
1418 * dwarf2/read.c (create_cus_from_debug_names_list): Initialize CUs
1419 with length 0, if not gdb-produced.
1420 (cutu_reader::cutu_reader): Set CU length to actual length if 0.
1421
1422 2020-05-09 Tom de Vries <tdevries@suse.de>
1423
1424 PR gdb/25955
1425 * break-catch-throw.c (check_status_exception_catchpoint): Fix name
1426 calculation.
1427
1428 2020-05-09 Tom Tromey <tom@tromey.com>
1429
1430 * top.c (server_command): Now bool.
1431 * top.h (server_command): Now bool.
1432
1433 2020-05-08 Tom Tromey <tromey@adacore.com>
1434
1435 * dwarf2/read.c (read_lexical_block_scope): Don't process a DIE
1436 already being processed.
1437
1438 2020-05-08 Tom Tromey <tom@tromey.com>
1439
1440 * printcmd.c (struct display) <next>: Remove.
1441 <display>: New constructor.
1442 <exp_string>: Now a std::string.
1443 <enabled_p>: Now a bool.
1444 (display_number): Move definition earlier.
1445 (displays): Rename from display_chain. Now a std::vector.
1446 (ALL_DISPLAYS, ALL_DISPLAYS_SAFE): Remove.
1447 (display_command): Update.
1448 (do_one_display, disable_display)
1449 (enable_disable_display_command, do_enable_disable_display):
1450 Update.
1451 (free_display): Remove.
1452 (clear_displays): Rewrite.
1453 (delete_display): Update.
1454 (map_display_numbers): Use function_view. Remove "data"
1455 parameter. Update.
1456 (do_delete_display): Remove.
1457 (undisplay_command): Update.
1458 (do_one_display, do_displays, disable_display)
1459 (info_display_command): Update.
1460 (do_enable_disable_display): Remove.
1461 (enable_disable_display_command)
1462 (clear_dangling_display_expressions): Update.
1463
1464 2020-05-08 Tom Tromey <tom@tromey.com>
1465
1466 * symtab.c (set_symbol_cache_size)
1467 (maintenance_print_symbol_cache, maintenance_flush_symbol_cache)
1468 (maintenance_print_symbol_cache_statistics): Update.
1469 * symmisc.c (print_symbol_bcache_statistics)
1470 (print_objfile_statistics, maintenance_print_objfiles)
1471 (maintenance_info_symtabs, maintenance_check_symtabs)
1472 (maintenance_expand_symtabs, maintenance_info_line_tables):
1473 Update.
1474 * symfile-debug.c (set_debug_symfile): Update.
1475 * source.c (forget_cached_source_info): Update.
1476 * python/python.c (gdbpy_progspaces): Update.
1477 * psymtab.c (maintenance_info_psymtabs): Update.
1478 * probe.c (parse_probes): Update.
1479 * linespec.c (iterate_over_all_matching_symtabs)
1480 (collect_symtabs_from_filename, search_minsyms_for_name): Update.
1481 * guile/scm-progspace.c (gdbscm_progspaces): Update.
1482 * exec.c (exec_target::close): Update.
1483 * ada-tasks.c (ada_tasks_new_objfile_observer): Update.
1484 * breakpoint.c (print_one_breakpoint_location)
1485 (create_longjmp_master_breakpoint)
1486 (create_std_terminate_master_breakpoint): Update.
1487 * progspace.c (program_spaces): Now a std::vector.
1488 (maybe_new_address_space): Update.
1489 (add_program_space): Remove.
1490 (program_space::program_space): Update.
1491 (remove_program_space): Update.
1492 (number_of_program_spaces): Remove.
1493 (print_program_space, update_address_spaces): Update.
1494 * progspace.h (program_spaces): Change type.
1495 (ALL_PSPACES): Remove.
1496 (number_of_program_spaces): Don't declare.
1497 (struct program_space) <next>: Remove.
1498
1499 2020-05-08 Tom Tromey <tom@tromey.com>
1500
1501 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Update.
1502 * solib-svr4.c (svr4_fetch_objfile_link_map): Update.
1503 (enable_break): Update.
1504 * solib-frv.c (frv_fdpic_find_global_pointer): Update.
1505 (frv_fdpic_find_canonical_descriptor): Update.
1506 (frv_fetch_objfile_link_map): Update.
1507 * progspace.c (program_space::free_all_objfiles): Update.
1508 (program_space::solibs): New method.
1509 * progspace.h (struct program_space) <solibs>: New method.
1510 * solist.h (master_so_list): Don't declare.
1511 (ALL_SO_LIBS): Remove.
1512 * solib.h (so_list_head): Remove.
1513 (update_solib_list): Update comment.
1514 * solib.c (master_so_list): Remove.
1515 (solib_used, update_solib_list, solib_add)
1516 (info_sharedlibrary_command, clear_solib)
1517 (reload_shared_libraries_1, remove_user_added_objfile): Update.
1518
1519 2020-05-08 Tom Tromey <tom@tromey.com>
1520
1521 * extension.c (extension_languages): Now a std::array.
1522 (ALL_EXTENSION_LANGUAGES): Remove.
1523 (get_ext_lang_defn, get_ext_lang_of_file)
1524 (eval_ext_lang_from_control_command): Update.
1525 (finish_ext_lang_initialization)
1526 (auto_load_ext_lang_scripts_for_objfile)
1527 (ext_lang_type_printers::ext_lang_type_printers)
1528 (apply_ext_lang_type_printers)
1529 (ext_lang_type_printers::~ext_lang_type_printers)
1530 (apply_ext_lang_val_pretty_printer, apply_ext_lang_frame_filter)
1531 (preserve_ext_lang_values, get_breakpoint_cond_ext_lang)
1532 (breakpoint_ext_lang_cond_says_stop, check_quit_flag)
1533 (get_matching_xmethod_workers, ext_lang_colorize)
1534 (ext_lang_before_prompt): Update.
1535 (ALL_ENABLED_EXTENSION_LANGUAGES): Remove.
1536
1537 2020-05-08 Tom Tromey <tom@tromey.com>
1538
1539 * symtab.h (class demangle_result_storage) <set_malloc_ptr>: New
1540 overload.
1541 <swap_string, m_string>: Remove.
1542 * symtab.c (demangle_for_lookup, completion_list_add_symbol):
1543 Update.
1544 * stabsread.c (define_symbol, read_type): Update.
1545 * linespec.c (find_linespec_symbols): Update.
1546 * gnu-v3-abi.c (gnuv3_get_typeid): Update.
1547 * dwarf2/read.c (dwarf2_canonicalize_name): Update.
1548 * dbxread.c (read_dbx_symtab): Update.
1549 * cp-support.h (cp_canonicalize_string_full)
1550 (cp_canonicalize_string, cp_canonicalize_string_no_typedefs):
1551 Return unique_xmalloc_ptr.
1552 * cp-support.c (inspect_type): Update.
1553 (cp_canonicalize_string_full): Return unique_xmalloc_ptr.
1554 (cp_canonicalize_string_no_typedefs, cp_canonicalize_string):
1555 Likewise.
1556 * c-typeprint.c (print_name_maybe_canonical): Update.
1557 * break-catch-throw.c (check_status_exception_catchpoint):
1558 Update.
1559
1560 2020-05-08 Tom de Vries <tdevries@suse.de>
1561
1562 * infrun.c (follow_fork): Copy current_line and current_symtab to
1563 child thread.
1564
1565 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
1566
1567 * async-event.c (struct async_signal_handler, struct
1568 async_event_handler): Reformat, remove typedef.
1569
1570 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
1571
1572 * gdbtypes.h (TYPE_DYN_PROP_LIST): Remove. Update all users
1573 access thistype->main_type->dyn_prop_list directly.
1574
1575 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
1576
1577 * gdbtypes.h (struct type) <remove_dyn_prop>: New method.
1578 (remove_dyn_prop): Remove. Update all users to use
1579 type::remove_dyn_prop.
1580 * gdbtypes.c (remove_dyn_prop): Rename to...
1581 (type::remove_dyn_prop): ... this.
1582
1583 2020-05-07 Simon Marchi via Gdb-patches <gdb-patches@sourceware.org>
1584
1585 * gdbtypes.h (struct type) <add_dyn_prop>: New method.
1586 (add_dyn_prop): Remove. Update all users to use
1587 type::add_dyn_prop.
1588 * gdbtypes.c (add_dyn_prop): Rename to...
1589 (type::add_dyn_prop): ... this.
1590
1591 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
1592
1593 * gdbtypes.h (struct type) <get_dyn_prop>: New method.
1594 (get_dyn_prop): Remove. Update all users to use
1595 type::dyn_prop.
1596 * gdbtypes.c (get_dyn_prop): Rename to...
1597 (type::dyn_prop): ... this.
1598
1599 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
1600
1601 * gdbtypes.h (struct main_type) <flag_static>: Remove.
1602
1603 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
1604
1605 * amd64-tdep.c (amd64_analyze_prologue): Check for `endbr64`
1606 instruction, skip it if it's there.
1607
1608 2020-05-05 Simon Marchi <simon.marchi@efficios.com>
1609
1610 * gdbtypes.h (struct main_type) <flag_incomplete>: Remove.
1611
1612 2020-05-04 Simon Marchi <simon.marchi@efficios.com>
1613
1614 * gdbtypes.h (TYPE_INCOMPLETE): Remove.
1615 * gdbtypes.c (recursive_dump_type): Remove use of
1616 TYPE_INCOMPLETE.
1617
1618 2020-05-03 Tom Tromey <tom@tromey.com>
1619
1620 * breakpoint.c (catch_command, tcatch_command): Remove.
1621 (_initialize_breakpoint): Use add_basic_prefix_cmd,
1622 add_show_prefix_cmd.
1623 (set_breakpoint_cmd, show_breakpoint_cmd): Remove
1624 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
1625 Remove.
1626 (add_internal_problem_command): Use add_basic_prefix_cmd,
1627 add_show_prefix_cmd.
1628 * mips-tdep.c (set_mipsfpu_command): Remove.
1629 (_initialize_mips_tdep): Use add_basic_prefix_cmd.
1630 * dwarf2/index-cache.c (set_index_cache_command): Remove.
1631 (_initialize_index_cache): Use add_basic_prefix_cmd.
1632 * memattr.c (dummy_cmd): Remove.
1633 (_initialize_mem): Use add_basic_prefix_cmd, add_show_prefix_cmd.
1634 * tui/tui-win.c (set_tui_cmd, show_tui_cmd): Remove.
1635 (_initialize_tui_win): Use add_basic_prefix_cmd,
1636 add_show_prefix_cmd.
1637 * cli/cli-logging.c (set_logging_command): Remove.
1638 (_initialize_cli_logging): Use add_basic_prefix_cmd,
1639 add_show_prefix_cmd.
1640 (show_logging_command): Remove.
1641 * target.c (target_command): Remove.
1642 (add_target): Use add_basic_prefix_cmd.
1643
1644 2020-05-02 Hannes Domani <ssbssa@yahoo.de>
1645
1646 * gdbtypes.h (enum dynamic_prop_node_kind): Fix typo.
1647
1648 2020-05-01 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1649
1650 * gdb-gdb.gdb-in: Remove breakpoint on disappeared function
1651 info_command.
1652
1653 2020-04-30 Kamil Rytarowski <n54@gmx.com>
1654
1655 * nbsd-nat.c (nbsd_enable_proc_events)
1656 (nbsd_nat_target::post_startup_inferior): Add.
1657 (nbsd_nat_target::post_attach): Call `nbsd_enable_proc_events'.
1658 (nbsd_nat_target::update_thread_list): Rewrite.
1659 (nbsd_nat_target::wait): Handle "PTRACE_LWP_EXIT" and
1660 "PTRACE_LWP_CREATE".
1661 * nbsd-nat.h (nbsd_nat_target::post_startup_inferior): Add.
1662
1663 2020-04-30 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1664
1665 * stack.c (_initialize_stack): Remove duplicated creation
1666 of "frame" command and "f" alias.
1667
1668 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
1669
1670 PR gdb/18706
1671 * gdbtypes.c (check_typedef): Calculate size of array of
1672 stubbed type.
1673
1674 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
1675
1676 PR gdb/15559
1677 * i386-tdep.c (i386_push_dummy_call): Call
1678 i386_thiscall_push_dummy_call.
1679 (i386_thiscall_push_dummy_call): New function.
1680 * i386-tdep.h (i386_thiscall_push_dummy_call): Declare.
1681 * i386-windows-tdep.c (i386_windows_push_dummy_call): New function.
1682 (i386_windows_init_abi): Call set_gdbarch_push_dummy_call.
1683
1684 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
1685
1686 * gdbarch.sh (do_read): Add shellcheck disable directive for
1687 warning SC2162.
1688
1689 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
1690
1691 * gdbarch.sh: Use ${foo:-} where shellcheck would report a
1692 "referenced but not assigned" warning.
1693
1694 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
1695
1696 * gdbarch.sh: Remove code that sets fallbackdefault.
1697
1698 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
1699
1700 * gdbarch.sh: Use shell operators && and || instead of
1701 -a and -o.
1702
1703 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
1704
1705 * gdbarch.sh: Use $(...) instead of `...`.
1706
1707 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
1708
1709 * gdbarch.sh: Use double quotes around variables.
1710
1711 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
1712
1713 * gdbarch.sh: Use %s with printf, instead of variables in the
1714 format string.
1715
1716 2020-04-29 Tom Tromey <tromey@adacore.com>
1717
1718 PR ada/25875:
1719 * dwarf2/read.c (update_enumeration_type_from_children): Compute
1720 type fields here.
1721 (read_enumeration_type): Call
1722 update_enumeration_type_from_children later. Update comments.
1723 (process_enumeration_scope): Don't create type fields.
1724
1725 2020-04-29 Kamil Rytarowski <n54@gmx.com>
1726
1727 * nbsd-tdep.c: Include "xml-syscall.h".
1728 (nbsd_init_abi): Call `set_xml_syscall_file_name'.
1729
1730 2020-04-29 Kamil Rytarowski <n54@gmx.com>
1731
1732 * nbsd-nat.c: Include "sys/wait.h".
1733 (nbsd_resume, nbsd_nat_target::resume, nbsd_wait)
1734 (nbsd_nat_target::wait, nbsd_nat_target::insert_exec_catchpoint)
1735 (nbsd_nat_target::remove_exec_catchpoint)
1736 (nbsd_nat_target::set_syscall_catchpoint): Add.
1737 * nbsd-nat.h (nbsd_nat_target::resume, nbsd_nat_target::wait)
1738 (nbsd_nat_target::insert_exec_catchpoint)
1739 (nbsd_nat_target::remove_exec_catchpoint)
1740 (nbsd_nat_target::set_syscall_catchpoint): Add.
1741 * nbsd-tdep.c (nbsd_get_syscall_number): Add.
1742 (nbsd_init_abi): Call `set_gdbarch_get_syscall_number' and pass
1743 `nbsd_get_syscall_number'.
1744
1745 2020-04-29 Tom Tromey <tom@tromey.com>
1746
1747 * stack.c (print_block_frame_labels): Remove.
1748
1749 2020-04-29 Hannes Domani <ssbssa@yahoo.de>
1750
1751 PR gdb/17320
1752 * ada-valprint.c (val_print_packed_array_elements): Move array
1753 end bracket to new line.
1754 (ada_val_print_string): Remove extra spaces before first array
1755 element.
1756 * c-valprint.c (c_value_print_array): Likewise.
1757 * m2-valprint.c (m2_print_array_contents): Likewise.
1758 (m2_value_print_inner): Likewise.
1759 * p-valprint.c (pascal_value_print_inner): Likewise.
1760 * valprint.c (generic_val_print_array): Likewise.
1761 (value_print_array_elements): Move first array element and array
1762 end bracket to new line.
1763
1764 2020-04-29 Tom de Vries <tdevries@suse.de>
1765
1766 PR symtab/25889
1767 * linespec.c (find_method): Fix ix calculation.
1768
1769 2020-04-28 Kamil Rytarowski <n54@gmx.com>
1770
1771 * syscalls/update-netbsd.sh: New file.
1772 * syscalls/netbsd.xml: Regenerate.
1773 * data-directory/Makefile.in: Register `netbsd.xml' in
1774 `SYSCALLS_FILES'.
1775
1776 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
1777
1778 * syscalls/update-freebsd.sh: Add double quotes.
1779
1780 2020-04-28 Tom Tromey <tom@tromey.com>
1781
1782 * NEWS: Update.
1783 * python/py-cmd.c (gdbpy_initialize_commands): Add COMMAND_TUI.
1784 (cmdpy_init): Allow class_tui.
1785
1786 2020-04-28 Mark Williams <mark@myosotissp.com>
1787
1788 PR gdb/24480
1789 * dwarf2read.c: Add missing assingments to list_in_scope when
1790 start_symtab was already called.
1791
1792 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
1793
1794 PR gdb/25881
1795 * dwarf2/read.c (offset_map_type): Use
1796 gdb:hash_enum<sect_offset> as hash function.
1797
1798 2020-04-28 Tom de Vries <tdevries@suse.de>
1799
1800 * dwarf2/read.c (process_structure_scope): Add symbol for struct decl
1801 with DW_AT_signature.
1802
1803 2020-04-27 Simon Marchi <simon.marchi@efficios.com>
1804
1805 * configure.ac: Remove check for fs_base/gs_base in
1806 user_regs_struct.
1807 * configure: Re-generate.
1808 * config.in: Re-generate.
1809 * amd64-nat.c (amd64_native_gregset_reg_offset): Adjust.
1810 * amd64-linux-nat.c (amd64_linux_nat_target::fetch_registers,
1811 amd64_linux_nat_target::store_registers, ps_get_thread_area, ): Adjust.
1812
1813 2020-04-27 Luis Machado <luis.machado@linaro.org>
1814
1815 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Handle
1816 problematic inline frame unwinding situation.
1817 * frame.c (frame_id_computed_p): New function.
1818 * frame.h (frame_id_computed_p): New prototype.
1819
1820 2020-04-26 Tom Tromey <tom@tromey.com>
1821
1822 * command.h (enum command_class) <class_pseudo>: Remove.
1823
1824 2020-04-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1825
1826 * cli/cli-decode.c (lookup_cmd_composition): Fix comments
1827 and whitespace.
1828
1829 2020-04-25 Kamil Rytarowski <n54@gmx.com>
1830
1831 * inf-ptrace.c (inf_ptrace_target::wait): Remove
1832 `PT_GET_PROCESS_STATE' block.
1833
1834 2020-04-24 Tom Tromey <tom@tromey.com>
1835
1836 * symtab.h (symbol_get_demangled_name): Don't declare.
1837 * symtab.c (symbol_get_demangled_name): Remove.
1838 (general_symbol_info::natural_name)
1839 (general_symbol_info::demangled_name): Update.
1840
1841 2020-04-24 Tom Tromey <tom@tromey.com>
1842
1843 PR rust/25025:
1844 * dwarf2/read.c (dwarf2_physname): Do not demangle for Rust.
1845
1846 2020-04-24 Tom Tromey <tom@tromey.com>
1847
1848 PR symtab/12707:
1849 * dwarf2/read.c (add_partial_symbol): Use the linkage name if it
1850 exists.
1851 (new_symbol): Likewise.
1852 * compile/compile-object-load.c (get_out_value_type): Use
1853 symbol_matches_search_name.
1854
1855 2020-04-24 Tom Tromey <tom@tromey.com>
1856
1857 * dwarf2/read.c (add_partial_symbol): Do not call
1858 compute_and_set_names.
1859
1860 2020-04-24 Tom Tromey <tom@tromey.com>
1861
1862 * dwarf2/read.c (add_partial_symbol): Use new add_psymbol_to_list
1863 overload.
1864
1865 2020-04-24 Tom Tromey <tom@tromey.com>
1866
1867 * psymtab.c (add_psymbol_to_bcache): Simplify calling convention.
1868 (add_psymbol_to_list): New overload. Make old overload call new
1869 one.
1870 * psympriv.h (add_psymbol_to_list): New overload.
1871
1872 2020-04-24 Tom Tromey <tom@tromey.com>
1873
1874 * dwarf2/read.c (partial_die_info::read) <case
1875 DW_AT_linkage_name>: Use value_as_string.
1876 (dwarf2_string_attr): Use value_as_string.
1877 * dwarf2/attribute.h (struct attribute) <value_as_string>: Declare
1878 method.
1879 * dwarf2/attribute.c (attribute::value_as_string): New method.
1880
1881 2020-04-24 Tom Tromey <tom@tromey.com>
1882
1883 * symtab.c (general_symbol_info::natural_name)
1884 (general_symbol_info::demangled_name): Check for language_rust.
1885
1886 2020-04-24 Tom Tromey <tom@tromey.com>
1887
1888 * dwarf2/read.c (dw2_linkage_name): Move Rust "{" hack here...
1889 (dwarf2_physname): ... from here.
1890 (partial_die_info::read): Add Rust "{" hack.
1891
1892 2020-04-24 Tom Tromey <tom@tromey.com>
1893
1894 * symtab.h (struct general_symbol_info) <set_demangled_name>: New
1895 method.
1896 (symbol_set_demangled_name): Don't declare.
1897 * symtab.c (general_symbol_info::set_demangled_name): Rename from
1898 symbol_set_demangled_name.
1899 (general_symbol_info::set_language)
1900 (general_symbol_info::compute_and_set_names): Update.
1901 * minsyms.c (minimal_symbol_reader::install): Update.
1902 * dwarf2/read.c (new_symbol): Update.
1903
1904 2020-04-24 Tom Tromey <tromey@adacore.com>
1905
1906 PR python/23662:
1907 * python/py-type.c (convert_field): Handle
1908 FIELD_LOC_KIND_DWARF_BLOCK.
1909 (typy_get_sizeof): Handle TYPE_HAS_DYNAMIC_LENGTH.
1910 (typy_get_dynamic): Nw function.
1911 (type_object_getset): Add "dynamic".
1912 * NEWS: Add entry.
1913
1914 2020-04-24 Tom Tromey <tromey@adacore.com>
1915
1916 * ada-typeprint.c (print_choices, print_variant_part)
1917 (print_record_field_types_dynamic): New functions.
1918 (print_record_field_types): Use print_record_field_types_dynamic.
1919
1920 2020-04-24 Tom Tromey <tromey@adacore.com>
1921
1922 * dwarf2/read.c (handle_data_member_location): New overload.
1923 (dwarf2_add_field): Use it.
1924 (decode_locdesc): Add "computed" parameter. Update comment.
1925 * gdbtypes.c (is_dynamic_type_internal): Also look for
1926 FIELD_LOC_KIND_DWARF_BLOCK.
1927 (resolve_dynamic_struct): Handle FIELD_LOC_KIND_DWARF_BLOCK.
1928 * gdbtypes.c (is_dynamic_type_internal): Add special case for C++
1929 virtual base classes.
1930 * gnu-v3-abi.c (gnuv3_baseclass_offset): Handle
1931 FIELD_LOC_KIND_DWARF_BLOCK.
1932
1933 2020-04-24 Tom Tromey <tromey@adacore.com>
1934
1935 * dwarf2/read.c (read_structure_type): Handle dynamic length.
1936 * gdbtypes.c (is_dynamic_type_internal): Check
1937 TYPE_HAS_DYNAMIC_LENGTH.
1938 (resolve_dynamic_type_internal): Use TYPE_DYNAMIC_LENGTH.
1939 * gdbtypes.h (TYPE_HAS_DYNAMIC_LENGTH, TYPE_DYNAMIC_LENGTH):
1940 New macros.
1941 (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_SIZE>: New
1942 constant.
1943
1944 2020-04-24 Tom Tromey <tromey@adacore.com>
1945
1946 * dwarf2/read.c (struct variant_field): Rewrite.
1947 (struct variant_part_builder): New.
1948 (struct nextfield): Remove "variant" field. Add "offset".
1949 (struct field_info): Add "current_variant_part" and
1950 "variant_parts".
1951 (alloc_discriminant_info): Remove.
1952 (alloc_rust_variant): New function.
1953 (quirk_rust_enum): Update.
1954 (dwarf2_add_field): Set "offset" member. Don't handle
1955 DW_TAG_variant_part.
1956 (offset_map_type): New typedef.
1957 (convert_variant_range, create_one_variant)
1958 (create_one_variant_part, create_variant_parts)
1959 (add_variant_property): New functions.
1960 (dwarf2_attach_fields_to_type): Call add_variant_property.
1961 (read_structure_type): Don't handle DW_TAG_variant_part.
1962 (handle_variant_part, handle_variant): New functions.
1963 (handle_struct_member_die): Use them.
1964 (process_structure_scope): Don't handle variant parts.
1965 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): Remove.
1966 (struct discriminant_info): Remove.
1967 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: Remove.
1968 (struct main_type) <flag_discriminated_union>: Remove.
1969 * rust-lang.c (rust_enum_p, rust_empty_enum_p): Rewrite.
1970 (rust_enum_variant): Return int. Remove "contents". Rewrite.
1971 (rust_print_enum, rust_print_struct_def, rust_evaluate_subexp):
1972 Update.
1973 * valops.c (value_union_variant): Remove.
1974 * value.h (value_union_variant): Don't declare.
1975
1976 2020-04-24 Tom Tromey <tromey@adacore.com>
1977
1978 * ada-lang.c (ada_discrete_type_high_bound, ada_discrete_type_low)
1979 (ada_value_primitive_packed_val): Update.
1980 * ada-valprint.c (ada_value_print_1): Update.
1981 * dwarf2/loc.c (evaluate_for_locexpr_baton): New struct.
1982 (dwarf2_locexpr_baton_eval): Take a property_addr_info rather than
1983 just an address. Use evaluate_for_locexpr_baton.
1984 (dwarf2_evaluate_property): Update.
1985 * dwarf2/loc.h (struct property_addr_info) <valaddr>: Now an
1986 array_view.
1987 * findvar.c (default_read_var_value): Update.
1988 * gdbtypes.c (compute_variant_fields_inner)
1989 (resolve_dynamic_type_internal): Update.
1990 (resolve_dynamic_type): Change type of valaddr parameter.
1991 * gdbtypes.h (resolve_dynamic_type): Update.
1992 * valarith.c (value_subscripted_rvalue): Update.
1993 * value.c (value_from_contents_and_address): Update.
1994
1995 2020-04-24 Tom Tromey <tromey@adacore.com>
1996
1997 * dwarf2/loc.c (dwarf2_locexpr_baton_eval): Add
1998 "push_initial_value" parameter.
1999 (dwarf2_evaluate_property): Likewise.
2000 * dwarf2/loc.h (dwarf2_evaluate_property): Update.
2001
2002 2020-04-24 Tom Tromey <tromey@adacore.com>
2003
2004 * gdbtypes.c (is_dynamic_type_internal): Check for variant parts.
2005 (variant::matches, compute_variant_fields_recurse)
2006 (compute_variant_fields_inner, compute_variant_fields): New
2007 functions.
2008 (resolve_dynamic_struct): Check for DYN_PROP_VARIANT_PARTS.
2009 Use resolved_type after type is made.
2010 (operator==): Add new cases.
2011 * gdbtypes.h (TYPE_HAS_VARIANT_PARTS): New macro.
2012 (struct discriminant_range, struct variant, struct variant_part):
2013 New.
2014 (union dynamic_prop_data) <variant_parts, original_type>: New
2015 members.
2016 (enum dynamic_prop_node_kind) <DYN_PROP_VARIANT_PARTS>: New constant.
2017 (enum dynamic_prop_kind) <PROP_TYPE, PROP_VARIANT_PARTS>: New
2018 constants.
2019 * value.c (unpack_bits_as_long): Now public.
2020 * value.h (unpack_bits_as_long): Declare.
2021
2022 2020-04-24 Tom Tromey <tromey@adacore.com>
2023
2024 * rs6000-tdep.c (struct ppc_variant): Rename from "variant".
2025 (variants, find_variant_by_arch, rs6000_gdbarch_init): Update.
2026
2027 2020-04-24 Hannes Domani <ssbssa@yahoo.de>
2028
2029 * windows-tdep.c (exception_values): Add WOW64 exception numbers.
2030
2031 2020-04-24 Kamil Rytarowski <n54@gmx.com>
2032
2033 * inf-ptrace.h (follow_fork, insert_fork_catchpoint)
2034 (remove_fork_catchpoint, post_startup_inferior)
2035 (post_attach): Move...
2036 * obsd-nat.h (follow_fork, insert_fork_catchpoint)
2037 (remove_fork_catchpoint, post_startup_inferior)
2038 (post_attach): ...here.
2039 * inf-ptrace.c (follow_fork, insert_fork_catchpoint)
2040 (remove_fork_catchpoint, post_startup_inferior)
2041 (post_attach): Move...
2042 * obsd-nat.c (follow_fork, insert_fork_catchpoint)
2043 (remove_fork_catchpoint, post_startup_inferior)
2044 (post_attach): ...here.
2045
2046 2020-04-24 Tom Tromey <tromey@adacore.com>
2047
2048 * nat/windows-nat.h (struct windows_thread_info)
2049 <pc_adjusted>: New member.
2050 * windows-nat.c (windows_fetch_one_register): Check
2051 pc_adjusted.
2052 (windows_nat_target::get_windows_debug_event)
2053 (windows_nat_target::wait): Set pc_adjusted.
2054
2055 2020-04-24 Tom de Vries <tdevries@suse.de>
2056
2057 * contrib/cc-with-tweaks.sh: Remove <exec>.gdb-index file handling.
2058 Run gdb-add-index inside temp dir.
2059
2060 2020-04-23 Tom Tromey <tromey@adacore.com>
2061
2062 * windows-tdep.c (is_linked_with_cygwin_dll): Always update "iter"
2063 in loop.
2064
2065 2020-04-23 Luis Machado <luis.machado@linaro.org>
2066
2067 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Use
2068 get_frame_register instead of gdbarch_unwind_pc.
2069
2070 2020-04-23 Tom de Vries <tdevries@suse.de>
2071
2072 * symtab.c (lookup_global_symbol): Prefer def over decl.
2073
2074 2020-04-23 Tom de Vries <tdevries@suse.de>
2075
2076 PR symtab/25807
2077 * block.c (best_symbol, better_symbol): Promote to external.
2078 * block.h (best_symbol, better_symbol): Declare.
2079 * symtab.c (lookup_symbol_in_objfile_symtabs): Prefer def over
2080 decl.
2081
2082 2020-04-23 Tom Tromey <tromey@adacore.com>
2083
2084 PR ada/25837:
2085 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Store a
2086 "const char *", not a "const std::string &".
2087 <name_and_matcher::operator==>: Update.
2088 * unittests/lookup_name_info-selftests.c: Change type of
2089 "result".
2090
2091 2020-04-23 Tom Tromey <tom@tromey.com>
2092
2093 * inferior.h (iterate_over_inferiors): Don't declare.
2094 * inferior.c (iterate_over_inferiors): Remove.
2095 * darwin-nat.c (find_inferior_task_it, find_inferior_pid_it):
2096 Remove.
2097 (darwin_find_inferior_by_task, darwin_find_inferior_by_pid): Don't
2098 use iterate_over_inferiors.
2099 (darwin_resume_inferior_it)
2100 (struct resume_inferior_threads_param)
2101 (darwin_resume_inferior_threads_it): Remove.
2102 (darwin_nat_target::resume): Don't use iterate_over_inferiors.
2103
2104 2020-04-23 Tom de Vries <tdevries@suse.de>
2105
2106 * blockframe.c (find_pc_partial_function): Use
2107 find_pc_sect_compunit_symtab rather than
2108 objfile->sf->qf->find_pc_sect_compunit_symtab.
2109
2110 2020-04-22 Tom de Vries <tdevries@suse.de>
2111
2112 PR symtab/25764
2113 * dwarf2/read.c (scan_partial_symbols): Allow external variable decls
2114 in psymtabs.
2115
2116 2020-04-22 Tom de Vries <tdevries@suse.de>
2117
2118 PR symtab/25801
2119 * psymtab.c (psym_map_symtabs_matching_filename): Don't skip shared
2120 symtabs.
2121
2122 2020-04-22 Tom de Vries <tdevries@suse.de>
2123
2124 PR symtab/25700
2125 * dwarf2/read.c (dwarf2_build_psymtabs_hard): Don't create psymtab for
2126 CU if already created.
2127
2128 2020-04-21 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2129
2130 * infrun.c (displaced_step_fixup): Switch to the event_thread
2131 before calling displaced_step_restore, not after.
2132
2133 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
2134
2135 * record-btrace.c (record_btrace_enable_warn): Ignore thread if
2136 its inferior is not recorded by us.
2137 (record_btrace_target_open): Replace call to
2138 all_non_exited_threads () with call to current_inferior
2139 ()->non_exited_threads ().
2140 (record_btrace_target::stop_recording): Likewise.
2141 (record_btrace_target::close): Likewise.
2142 (record_btrace_target::wait): Likewise.
2143 (record_btrace_target::record_stop_replaying): Likewise.
2144
2145 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
2146
2147 * btrace.c (btrace_enable): Throw an error on double enables and
2148 when enabling recording fails.
2149 (btrace_disable): Throw an error if the thread is not recorded.
2150
2151 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
2152
2153 * record-btrace.c (record_btrace_target::fetch_registers): Forward
2154 request if we do not have a thread_info.
2155
2156 2020-04-21 Tom de Vries <tdevries@suse.de>
2157
2158 PR gdb/25471
2159 * thread.c
2160 (scoped_restore_current_thread::scoped_restore_current_thread): Catch
2161 exception in get_frame_id.
2162
2163 2020-04-20 Tom Tromey <tromey@adacore.com>
2164
2165 * python/python.c (struct gdbpy_event): Mark move constructor as
2166 noexcept.
2167 * python/py-tui.c (class gdbpy_tui_window_maker): Mark move
2168 constructor as noexcept.
2169 * completer.h (struct completion_result): Mark move constructor as
2170 noexcept.
2171 * completer.c (completion_result::completion_result): Use
2172 initialization style. Don't call reset_match_list.
2173
2174 2020-04-20 Mihails Strasuns <mihails.strasuns@intel.com>
2175
2176 * MAINTAINERS (Write After Approval): Add myself.
2177
2178 2020-04-18 Tom Tromey <tom@tromey.com>
2179
2180 * windows-tdep.c (init_w32_command_list)
2181 (w32_prefix_command_valid): Restore.
2182 (_initialize_windows_tdep): Call init_w32_command_list.
2183
2184 2020-04-18 Tom Tromey <tom@tromey.com>
2185
2186 * xcoffread.c (enter_line_range, scan_xcoff_symtab): Update.
2187 * value.c (value_fn_field): Update.
2188 * valops.c (find_function_in_inferior)
2189 (value_allocate_space_in_inferior): Update.
2190 * tui/tui-winsource.c (tui_update_source_windows_with_line):
2191 Update.
2192 * tui/tui-source.c (tui_source_window::set_contents): Update.
2193 * symtab.c (lookup_global_or_static_symbol)
2194 (find_function_start_sal_1, skip_prologue_sal)
2195 (print_msymbol_info, find_gnu_ifunc, symbol_arch): Update.
2196 * symmisc.c (dump_msymbols, dump_symtab_1)
2197 (maintenance_print_one_line_table): Update.
2198 * symfile.c (init_entry_point_info, section_is_mapped)
2199 (list_overlays_command, simple_read_overlay_table)
2200 (simple_overlay_update_1): Update.
2201 * stap-probe.c (handle_stap_probe): Update.
2202 * stabsread.c (dbx_init_float_type, define_symbol)
2203 (read_one_struct_field, read_enum_type, read_range_type): Update.
2204 * source.c (info_line_command): Update.
2205 * python/python.c (gdbpy_source_objfile_script)
2206 (gdbpy_execute_objfile_script): Update.
2207 * python/py-type.c (save_objfile_types): Update.
2208 * python/py-objfile.c (py_free_objfile): Update.
2209 * python/py-inferior.c (python_new_objfile): Update.
2210 * psymtab.c (psym_find_pc_sect_compunit_symtab, dump_psymtab)
2211 (dump_psymtab_addrmap_1, maintenance_info_psymtabs)
2212 (maintenance_check_psymtabs): Update.
2213 * printcmd.c (info_address_command): Update.
2214 * objfiles.h (struct objfile) <arch>: New method, from
2215 get_objfile_arch.
2216 (get_objfile_arch): Don't declare.
2217 * objfiles.c (get_objfile_arch): Remove.
2218 (filter_overlapping_sections): Update.
2219 * minsyms.c (msymbol_is_function): Update.
2220 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines)
2221 (output_nondebug_symbol): Update.
2222 * mdebugread.c (parse_symbol, basic_type, parse_partial_symbols)
2223 (mdebug_expand_psymtab): Update.
2224 * machoread.c (macho_add_oso_symfile): Update.
2225 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap):
2226 Update.
2227 * linux-fork.c (checkpoint_command): Update.
2228 * linespec.c (convert_linespec_to_sals): Update.
2229 * jit.c (finalize_symtab): Update.
2230 * infrun.c (insert_exception_resume_from_probe): Update.
2231 * ia64-tdep.c (ia64_find_unwind_table): Update.
2232 * hppa-tdep.c (internalize_unwinds): Update.
2233 * gdbtypes.c (get_type_arch, init_float_type, objfile_type):
2234 Update.
2235 * gcore.c (call_target_sbrk): Update.
2236 * elfread.c (record_minimal_symbol, elf_symtab_read)
2237 (elf_rel_plt_read, elf_gnu_ifunc_record_cache)
2238 (elf_gnu_ifunc_resolve_by_got): Update.
2239 * dwarf2/read.c (create_addrmap_from_index)
2240 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
2241 (read_debug_names_from_section)
2242 (process_psymtab_comp_unit_reader, add_partial_symbol)
2243 (add_partial_subprogram, process_full_comp_unit)
2244 (read_file_scope, read_func_scope, read_lexical_block_scope)
2245 (read_call_site_scope, dwarf2_ranges_read)
2246 (dwarf2_record_block_ranges, dwarf2_add_field)
2247 (mark_common_block_symbol_computed, read_tag_pointer_type)
2248 (read_tag_string_type, dwarf2_init_float_type)
2249 (dwarf2_init_complex_target_type, read_base_type)
2250 (partial_die_info::read, partial_die_info::read)
2251 (read_attribute_value, dwarf_decode_lines_1, new_symbol)
2252 (dwarf2_fetch_die_loc_sect_off): Update.
2253 * dwarf2/loc.c (dwarf2_find_location_expression)
2254 (class dwarf_evaluate_loc_desc, rw_pieced_value)
2255 (dwarf2_evaluate_loc_desc_full, dwarf2_locexpr_baton_eval)
2256 (dwarf2_loc_desc_get_symbol_read_needs)
2257 (locexpr_describe_location_piece, locexpr_describe_location_1)
2258 (loclist_describe_location): Update.
2259 * dwarf2/index-write.c (write_debug_names): Update.
2260 * dwarf2/frame.c (dwarf2_build_frame_info): Update.
2261 * dtrace-probe.c (dtrace_process_dof): Update.
2262 * dbxread.c (read_dbx_symtab, dbx_end_psymtab)
2263 (process_one_symbol): Update.
2264 * ctfread.c (ctf_init_float_type, read_base_type): Update.
2265 * coffread.c (coff_symtab_read, enter_linenos, decode_base_type)
2266 (coff_read_enum_type): Update.
2267 * cli/cli-cmds.c (edit_command, list_command): Update.
2268 * buildsym.c (buildsym_compunit::finish_block_internal): Update.
2269 * breakpoint.c (create_overlay_event_breakpoint)
2270 (create_longjmp_master_breakpoint)
2271 (create_std_terminate_master_breakpoint)
2272 (create_exception_master_breakpoint, get_sal_arch): Update.
2273 * block.c (block_gdbarch): Update.
2274 * annotate.c (annotate_source_line): Update.
2275
2276 2020-04-17 Tom Tromey <tromey@adacore.com>
2277
2278 * auto-load.c (show_auto_load_cmd): Remove.
2279 (auto_load_show_cmdlist_get): Use add_show_prefix_cmd.
2280 * arc-tdep.c (_initialize_arc_tdep): Use add_show_prefix_cmd.
2281 (maintenance_print_arc_command): Remove.
2282 * tui/tui-win.c (tui_command): Remove.
2283 (tui_get_cmd_list): Use add_basic_prefix_cmd.
2284 * tui/tui-layout.c (tui_layout_command): Remove.
2285 (_initialize_tui_layout): Use add_basic_prefix_cmd.
2286 * python/python.c (user_set_python, user_show_python): Remove.
2287 (_initialize_python): Use add_basic_prefix_cmd,
2288 add_show_prefix_cmd.
2289 * guile/guile.c (set_guile_command, show_guile_command): Remove.
2290 (install_gdb_commands): Use add_basic_prefix_cmd,
2291 add_show_prefix_cmd.
2292 (info_guile_command): Remove.
2293 * dwarf2/read.c (set_dwarf_cmd, show_dwarf_cmd): Remove.
2294 (_initialize_dwarf2_read): Use add_basic_prefix_cmd,
2295 add_show_prefix_cmd.
2296 * cli/cli-style.h (class cli_style_option) <add_setshow_commands>:
2297 Remove do_set and do_show parameters.
2298 * cli/cli-style.c (set_style, show_style): Remove.
2299 (_initialize_cli_style): Use add_basic_prefix_cmd,
2300 add_show_prefix_cmd.
2301 (cli_style_option::add_setshow_commands): Remove do_set and
2302 do_show parameters.
2303 (cli_style_option::add_setshow_commands): Use
2304 add_basic_prefix_cmd, add_show_prefix_cmd.
2305 (STYLE_ADD_SETSHOW_COMMANDS): Remove macro.
2306 (set_style_name): Remove.
2307 * cli/cli-dump.c (dump_command, append_command): Remove.
2308 (srec_dump_command, ihex_dump_command, verilog_dump_command)
2309 (tekhex_dump_command, binary_dump_command)
2310 (binary_append_command): Remove.
2311 (_initialize_cli_dump): Use add_basic_prefix_cmd.
2312 * windows-tdep.c (w32_prefix_command_valid): Remove global.
2313 (init_w32_command_list): Remove; move into ...
2314 (_initialize_windows_tdep): ... here. Use add_basic_prefix_cmd.
2315 * valprint.c (set_print, show_print, set_print_raw)
2316 (show_print_raw): Remove.
2317 (_initialize_valprint): Use add_basic_prefix_cmd,
2318 add_show_prefix_cmd.
2319 * typeprint.c (set_print_type, show_print_type): Remove.
2320 (_initialize_typeprint): Use add_basic_prefix_cmd,
2321 add_show_prefix_cmd.
2322 * record.c (set_record_command, show_record_command): Remove.
2323 (_initialize_record): Use add_basic_prefix_cmd,
2324 add_show_prefix_cmd.
2325 * cli/cli-cmds.c (_initialize_cli_cmds): Use add_basic_prefix_cmd,
2326 add_show_prefix_cmd.
2327 (info_command, show_command, set_debug, show_debug): Remove.
2328 * top.h (set_history, show_history): Don't declare.
2329 * top.c (set_history, show_history): Remove.
2330 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
2331 (unset_tdesc_cmd): Remove.
2332 (_initialize_target_descriptions): Use add_basic_prefix_cmd,
2333 add_show_prefix_cmd.
2334 * symtab.c (info_module_command): Remove.
2335 (_initialize_symtab): Use add_basic_prefix_cmd.
2336 * symfile.c (overlay_command): Remove.
2337 (_initialize_symfile): Use add_basic_prefix_cmd.
2338 * sparc64-tdep.c (info_adi_command): Remove.
2339 (_initialize_sparc64_adi_tdep): Use add_basic_prefix_cmd.
2340 * sh-tdep.c (show_sh_command, set_sh_command): Remove.
2341 (_initialize_sh_tdep): Use add_basic_prefix_cmd,
2342 add_show_prefix_cmd.
2343 * serial.c (serial_set_cmd, serial_show_cmd): Remove.
2344 (_initialize_serial): Use add_basic_prefix_cmd,
2345 add_show_prefix_cmd.
2346 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Remove.
2347 (_initialize_ser_tcp): Use add_basic_prefix_cmd,
2348 add_show_prefix_cmd.
2349 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command)
2350 (_initialize_rs6000_tdep): Use add_basic_prefix_cmd,
2351 add_show_prefix_cmd.
2352 * riscv-tdep.c (show_riscv_command, set_riscv_command)
2353 (show_debug_riscv_command, set_debug_riscv_command): Remove.
2354 (_initialize_riscv_tdep): Use add_basic_prefix_cmd,
2355 add_show_prefix_cmd.
2356 * remote.c (remote_command, set_remote_cmd): Remove.
2357 (_initialize_remote): Use add_basic_prefix_cmd.
2358 * record-full.c (set_record_full_command)
2359 (show_record_full_command): Remove.
2360 (_initialize_record_full): Use add_basic_prefix_cmd,
2361 add_show_prefix_cmd.
2362 * record-btrace.c (cmd_set_record_btrace)
2363 (cmd_show_record_btrace, cmd_set_record_btrace_bts)
2364 (cmd_show_record_btrace_bts, cmd_set_record_btrace_pt)
2365 (cmd_show_record_btrace_pt): Remove.
2366 (_initialize_record_btrace): Use add_basic_prefix_cmd,
2367 add_show_prefix_cmd.
2368 * ravenscar-thread.c (set_ravenscar_command)
2369 (show_ravenscar_command): Remove.
2370 (_initialize_ravenscar): Use add_basic_prefix_cmd,
2371 add_show_prefix_cmd.
2372 * mips-tdep.c (show_mips_command, set_mips_command)
2373 (_initialize_mips_tdep): Use add_basic_prefix_cmd,
2374 add_show_prefix_cmd.
2375 * maint.c (maintenance_command, maintenance_info_command)
2376 (maintenance_check_command, maintenance_print_command)
2377 (maintenance_set_cmd, maintenance_show_cmd): Remove.
2378 (_initialize_maint_cmds): Use add_basic_prefix_cmd,
2379 add_show_prefix_cmd.
2380 (show_per_command_cmd): Remove.
2381 * maint-test-settings.c (maintenance_set_test_settings_cmd):
2382 Remove.
2383 (maintenance_show_test_settings_cmd): Remove.
2384 (_initialize_maint_test_settings): Use add_basic_prefix_cmd,
2385 add_show_prefix_cmd.
2386 * maint-test-options.c (maintenance_test_options_command):
2387 Remove.
2388 (_initialize_maint_test_options): Use add_basic_prefix_cmd.
2389 * macrocmd.c (macro_command): Remove
2390 (_initialize_macrocmd): Use add_basic_prefix_cmd.
2391 * language.c (set_check, show_check): Remove.
2392 (_initialize_language): Use add_basic_prefix_cmd,
2393 add_show_prefix_cmd.
2394 * infcmd.c (unset_command): Remove.
2395 (_initialize_infcmd): Use add_basic_prefix_cmd.
2396 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Remove.
2397 (_initialize_i386_tdep): Use add_basic_prefix_cmd,
2398 add_show_prefix_cmd.
2399 * go32-nat.c (go32_info_dos_command): Remove.
2400 (_initialize_go32_nat): Use add_basic_prefix_cmd.
2401 * cli/cli-decode.c (do_prefix_cmd, add_basic_prefix_cmd)
2402 (do_show_prefix_cmd, add_show_prefix_cmd): New functions.
2403 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Remove.
2404 (_initialize_frame): Use add_basic_prefix_cmd,
2405 add_show_prefix_cmd.
2406 * dcache.c (set_dcache_command, show_dcache_command): Remove.
2407 (_initialize_dcache): Use add_basic_prefix_cmd,
2408 add_show_prefix_cmd.
2409 * cp-support.c (maint_cplus_command): Remove.
2410 (_initialize_cp_support): Use add_basic_prefix_cmd.
2411 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
2412 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
2413 (maint_btrace_pt_show_cmd, _initialize_btrace): Use
2414 add_basic_prefix_cmd, add_show_prefix_cmd.
2415 * breakpoint.c (save_command): Remove.
2416 (_initialize_breakpoint): Use add_basic_prefix_cmd.
2417 * arm-tdep.c (set_arm_command, show_arm_command): Remove.
2418 (_initialize_arm_tdep): Use add_basic_prefix_cmd,
2419 add_show_prefix_cmd.
2420 * ada-lang.c (maint_set_ada_cmd, maint_show_ada_cmd)
2421 (set_ada_command, show_ada_command): Remove.
2422 (_initialize_ada_language): Use add_basic_prefix_cmd,
2423 add_show_prefix_cmd.
2424 * command.h (add_basic_prefix_cmd, add_show_prefix_cmd): Declare.
2425
2426 2020-04-16 Kamil Rytarowski <n54@gmx.com>
2427
2428 * nbsd-nat.c (inf_ptrace_target::auxv_parse): Remove.
2429 * nbsd-nat.h (inf_ptrace_target::auxv_parse): Likewise.
2430
2431 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
2432
2433 * windows-tdep.c (is_linked_with_cygwin_dll): Add filename to
2434 warning messages.
2435
2436 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
2437
2438 * windows-tdep.c (is_linked_with_cygwin_dll): Consider case where
2439 import table is not at beginning of .idata section.
2440
2441 2020-04-16 Pedro Alves <palves@redhat.com>
2442
2443 * inferior.c (delete_inferior): Use delete operator directly
2444 instead of delete_program_space.
2445 * progspace.c (add_program_space): New, factored out from
2446 program_space::program_space.
2447 (remove_program_space): New, factored out from
2448 delete_program_space.
2449 (program_space::program_space): Remove intro comment. Rewrite.
2450 (program_space::~program_space): Remove intro comment. Call
2451 remove_program_space.
2452 (delete_program_space): Delete.
2453 * progspace.h (program_space::program_space): Make explicit. Move
2454 intro comment here, adjusted.
2455 (program_space::~program_space): Move intro comment here,
2456 adjusted.
2457 (delete_program_space): Remove.
2458
2459 2020-04-16 Tom Tromey <tromey@adacore.com>
2460
2461 * windows-nat.c (windows_nat::handle_access_violation): New
2462 function.
2463 * nat/windows-nat.h (handle_access_violation): Declare.
2464 * nat/windows-nat.c (handle_exception): Move Cygwin code to
2465 windows-nat.c. Call handle_access_violation.
2466
2467 2020-04-16 Tom de Vries <tdevries@suse.de>
2468
2469 PR symtab/25791
2470 * dwarf2/index-write.c (write_gdbindex): Generate CU table entries for
2471 CUs without psymtab.
2472
2473 2020-04-16 Kevin Buettner <kevinb@redhat.com>
2474
2475 * python/python.c (do_start_initialization): Don't call
2476 PyEval_InitThreads for Python 3.9 and beyond.
2477
2478 2020-04-15 Kamil Rytarowski <n54@gmx.com>
2479
2480 * obsd-nat.c (obsd_nat_target::update_thread_list): Pass "this" to
2481 thread functions.
2482 (obsd_nat_target::wait): Likewise.
2483
2484 2020-04-15 Tom Tromey <tromey@adacore.com>
2485
2486 * windows-nat.c (DEBUG_EXEC, DEBUG_EVENTS, DEBUG_MEM)
2487 (DEBUG_EXCEPT): Use debug_printf.
2488
2489 2020-04-15 Andrew Burgess <andrew.burgess@embecosm.com>
2490
2491 * completer.c (class completion_tracker::completion_hash_entry)
2492 <hash_name>: New member function.
2493 (completion_tracker::discard_completions): New callback to hash a
2494 completion_hash_entry, pass this to htab_create_alloc.
2495
2496 2016-01-20 Jon Turney <jon.turney@dronecode.org.uk>
2497
2498 * windows-nat.c (windows_make_so): Warn rather than stopping with
2499 an error if realpath() fails.
2500
2501 2020-04-14 Kamil Rytarowski <n54@gmx.com>
2502
2503 * nbsd-nat.c (nbsd_pid_to_kinfo_proc2): New.
2504 (nbsd_nat_target::info_proc): Add do_status.
2505
2506 2020-04-14 Simon Marchi <simon.marchi@polymtl.ca>
2507 Tom de Vries <tdevries@suse.de>
2508
2509 PR symtab/25718
2510 * psympriv.h (struct partial_symtab::read_symtab)
2511 (struct partial_symtab::expand_psymtab)
2512 (struct partial_symtab::read_dependencies): Update comments.
2513 * dwarf2/read.c (struct dwarf2_include_psymtab::read_symtab): Call
2514 read_symtab for includer.
2515 (struct dwarf2_include_psymtab::expand_psymtab): Assert false.
2516 (struct dwarf2_include_psymtab::readin_p): Call readin_p () for includer.
2517 (struct dwarf2_include_psymtab::m_readin): Remove.
2518 (struct dwarf2_include_psymtab::includer): New member function.
2519 (dwarf2_psymtab::expand_psymtab): Assert !readin.
2520
2521 2020-04-14 Tom de Vries <tdevries@suse.de>
2522
2523 PR symtab/25720
2524 * symmisc.c (maintenance_expand_symtabs): Call expand_symtabs_matching
2525 with NULL symbol_matcher and lookup_name.
2526 * psymtab.c (psym_expand_symtabs_matching): Handle NULL symbol_matcher
2527 and lookup_name.
2528 * dwarf2/read.c (dw2_expand_symtabs_matching)
2529 (dw2_debug_names_expand_symtabs_matching): Same.
2530 * symfile.h (struct quick_symbol_functions::expand_symtabs_matching):
2531 Make lookup_name a pointer. Update comment.
2532 * symtab.c (global_symbol_searcher::expand_symtabs): Handle
2533 lookup_name being a pointer.
2534 * symfile.c (expand_symtabs_matching): Same.
2535 * symfile-debug.c (debug_qf_expand_symtabs_matching): Same.
2536 * linespec.c (iterate_over_all_matching_symtabs): Same.
2537
2538 2020-04-13 Tom Tromey <tom@tromey.com>
2539
2540 * run-on-main-thread.c: Update include.
2541 * unittests/main-thread-selftests.c: Update include.
2542 * tui/tui-win.c: Update include.
2543 * tui/tui-io.c: Update include.
2544 * tui/tui-interp.c: Update include.
2545 * tui/tui-hooks.c: Update include.
2546 * top.h: Update include.
2547 * top.c: Update include.
2548 * ser-base.c: Update include.
2549 * remote.c: Update include.
2550 * remote-notif.c: Update include.
2551 * remote-fileio.c: Update include.
2552 * record-full.c: Update include.
2553 * record-btrace.c: Update include.
2554 * python/python.c: Update include.
2555 * posix-hdep.c: Update include.
2556 * mingw-hdep.c: Update include.
2557 * mi/mi-main.c: Update include.
2558 * mi/mi-interp.c: Update include.
2559 * main.c: Update include.
2560 * linux-nat.c: Update include.
2561 * interps.c: Update include.
2562 * infrun.c: Update include.
2563 * inf-loop.c: Update include.
2564 * event-top.c: Update include.
2565 * event-loop.c: Move to ../gdbsupport/.
2566 * event-loop.h: Move to ../gdbsupport/.
2567 * async-event.h: Update include.
2568 * Makefile.in (COMMON_SFILES, HFILES_NO_SRCDIR): Update.
2569
2570 2020-04-13 Tom Tromey <tom@tromey.com>
2571
2572 * tui/tui-win.c: Include async-event.h.
2573 * remote.c: Include async-event.h.
2574 * remote-notif.c: Include async-event.h.
2575 * record-full.c: Include async-event.h.
2576 * record-btrace.c: Include async-event.h.
2577 * infrun.c: Include async-event.h.
2578 * event-top.c: Include async-event.h.
2579 * event-loop.h: Move some declarations to async-event.h.
2580 * event-loop.c: Don't include ser-event.h or top.h. Move some
2581 code to async-event.c.
2582 * async-event.h: New file.
2583 * async-event.c: New file.
2584 * Makefile.in (COMMON_SFILES): Add async-event.c.
2585 (HFILES_NO_SRCDIR): Add async-event.h.
2586
2587 2020-04-13 Tom Tromey <tom@tromey.com>
2588
2589 * utils.c (flush_streams): New function.
2590 * event-loop.c (gdb_wait_for_event): Call flush_streams.
2591
2592 2020-04-13 Tom Tromey <tom@tromey.com>
2593
2594 * event-loop.c (handle_file_event): Use warning, not
2595 printf_unfiltered.
2596
2597 2020-04-13 Tom Tromey <tom@tromey.com>
2598
2599 * event-loop.c: Include <chrono>.
2600
2601 2020-04-13 Tom Tromey <tom@tromey.com>
2602
2603 * gdb_select.h: Move to ../gdbsupport/.
2604 * event-loop.c: Update include path.
2605 * top.c: Update include path.
2606 * ser-base.c: Update include path.
2607 * ui-file.c: Update include path.
2608 * ser-tcp.c: Update include path.
2609 * guile/scm-ports.c: Update include path.
2610 * posix-hdep.c: Update include path.
2611 * ser-unix.c: Update include path.
2612 * gdb_usleep.c: Update include path.
2613 * mingw-hdep.c: Update include path.
2614 * inflow.c: Update include path.
2615 * infrun.c: Update include path.
2616 * event-top.c: Update include path.
2617
2618 2020-04-13 Tom Tromey <tom@tromey.com>
2619
2620 * configure: Rebuild.
2621 * configure.ac: Remove checks that are now in GDB_AC_COMMON.
2622
2623 2020-04-13 Tom Tromey <tom@tromey.com>
2624
2625 * event-loop.h (start_event_loop): Don't declare.
2626 * event-loop.c (start_event_loop): Move...
2627 * main.c (start_event_loop): ...here. Now static.
2628
2629 2020-04-13 Sergio Durigan Junior <sergiodj@sergiodj.net>
2630
2631 * MAINTAINERS: Update my email address.
2632
2633 2020-04-12 Kamil Rytarowski <n54@gmx.com>
2634
2635 * nbsd-nat.c (nbsd_nat_target::info_proc): Add IP_MINIMAL and
2636 IP_ALL.
2637
2638 2020-04-12 Kamil Rytarowski <n54@gmx.com>
2639
2640 * nbsd-nat.c (nbsd_pid_to_cmdline): Add.
2641 (nbsd_nat_target::info_proc): Add do_cmdline.
2642
2643 2020-04-12 Kamil Rytarowski <n54@gmx.com>
2644
2645 * nbsd-nat.c (nbsd_pid_to_cwd): Add.
2646 (nbsd_nat_target::info_proc): Add do_cwd.
2647
2648 2020-04-12 Kamil Rytarowski <n54@gmx.com>
2649
2650 * nbsd-nat.c (nbsd_nat_target::info_proc): Add do_exe.
2651
2652 2020-04-11 Kamil Rytarowski <n54@gmx.com>
2653
2654 * nbsd-nat.c; Include "nbsd-tdep.h" and "gdbarch.h".
2655 * nbsd-nat.c (nbsd_nat_target::find_memory_regions)
2656 (nbsd_nat_target::info_proc): New functions.
2657 * nbsd-nat.c (kinfo_get_vmmap): New function.
2658 * nbsd-nat.c (nbsd_nat_target::info_proc) Use
2659 nbsd_info_proc_mappings_header and nbsd_info_proc_mappings_entry.
2660 * nbsd-tdep.c (nbsd_info_proc_mappings_header)
2661 (nbsd_info_proc_mappings_entry, nbsd_vm_map_entry_flags): New
2662 functions.
2663 * nbsd-tdep.c (KINFO_VME_PROT_READ, KINFO_VME_PROT_WRITE)
2664 (KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
2665 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
2666 (KINFO_VME_FLAG_PAGEABLE, KINFO_VME_FLAG_GROWS_UP)
2667 (KINFO_VME_FLAG_GROWS_DOWN): New.
2668
2669 2020-04-10 Artur Shepilko <nomadbyte@gmail.com>
2670
2671 * utils.c (copy_bitwise): Use unsigned 0 constant as operand of
2672 bit shift.
2673
2674 2020-04-10 Tom Tromey <tromey@adacore.com>
2675
2676 * symfile.c (symbol_file_add_separate): Preserve OBJF_MAINLINE.
2677
2678 2020-04-10 Tom Tromey <tromey@adacore.com>
2679
2680 * symtab.c (get_symbol_address, get_msymbol_address): Skip
2681 separate debug files.
2682
2683 2020-04-10 Hannes Domani <ssbssa@yahoo.de>
2684
2685 * nat/windows-nat.c (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
2686 Move to...
2687 * nat/windows-nat.h (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
2688 ... here.
2689 * windows-nat.c (windows_nat_target::get_windows_debug_event):
2690 Check for STATUS_WX86_BREAKPOINT.
2691 (windows_nat_target::wait): Same.
2692
2693 2020-04-10 Tom de Vries <tdevries@suse.de>
2694
2695 PR cli/25808
2696 * python/lib/gdb/__init__.py: Initialize lexer with stripnl=False.
2697
2698 2020-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2699
2700 * MAINTAINERS (Global Maintainers): Add Tom de Vries.
2701 (Write After Approval): Remove Tom de Vries.
2702
2703 2020-04-09 Bernd Edlinger <bernd.edlinger@hotmail.de>
2704
2705 revert partially:
2706 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
2707
2708 * buildsym.c (record_line): Fix undefined behavior and preserve
2709 lines at eof.
2710
2711 2020-04-09 Kamil Rytarowski <n54@gmx.com>
2712
2713 * auxv.h (svr4_auxv_parse): New.
2714 * auxv.c (default_auxv_parse): Split into default_auxv_parse
2715 and generic_auxv_parse.
2716 (svr4_auxv_parse): Add.
2717 * obsd-tdep.c: Include "auxv.h".
2718 (obsd_auxv_parse): Remove.
2719 (obsd_init_abi): Remove comment.
2720 (obsd_init_abi): Change set_gdbarch_auxv_parse passed argument
2721 from `obsd_auxv_parse' to `svr4_auxv_parse'.
2722 * nbsd-tdep.c: Include "auxv.h".
2723 (nbsd_init_abi): Call set_gdbarch_auxv_parse.
2724
2725 2020-04-08 Tom Tromey <tromey@adacore.com>
2726
2727 * nat/windows-nat.h (last_wait_event): Don't declare.
2728 (wait_for_debug_event): Update comment.
2729 * nat/windows-nat.c (last_wait_event): Now static.
2730
2731 2020-04-08 Tom Tromey <tromey@adacore.com>
2732
2733 * windows-nat.c (wait_for_debug_event): Move to
2734 nat/windows-nat.c.
2735 * nat/windows-nat.h (wait_for_debug_event): Declare.
2736 * nat/windows-nat.c (wait_for_debug_event): Move from
2737 windows-nat.c. No longer static.
2738
2739 2020-04-08 Tom Tromey <tromey@adacore.com>
2740
2741 * windows-nat.c (get_windows_debug_event): Use
2742 fetch_pending_stop.
2743 * nat/windows-nat.h (fetch_pending_stop): Declare.
2744 * nat/windows-nat.c (fetch_pending_stop): New function.
2745
2746 2020-04-08 Tom Tromey <tromey@adacore.com>
2747
2748 * windows-nat.c (windows_continue): Use matching_pending_stop and
2749 continue_last_debug_event.
2750 * nat/windows-nat.h (matching_pending_stop)
2751 (continue_last_debug_event): Declare.
2752 * nat/windows-nat.c (DEBUG_EVENTS): New define.
2753 (matching_pending_stop, continue_last_debug_event): New
2754 functions.
2755
2756 2020-04-08 Tom Tromey <tromey@adacore.com>
2757
2758 * windows-nat.c (MS_VC_EXCEPTION): Move to nat/windows-nat.c.
2759 (handle_exception_result): Move to nat/windows-nat.h.
2760 (DEBUG_EXCEPTION_SIMPLE): Remove.
2761 (windows_nat::handle_ms_vc_exception): New function.
2762 (handle_exception): Move to nat/windows-nat.c.
2763 (get_windows_debug_event): Update.
2764 (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP): Move to
2765 nat/windows-nat.c.
2766 * nat/windows-nat.h (handle_ms_vc_exception): Declare.
2767 (handle_exception_result): Move from windows-nat.c.
2768 (handle_exception): Declare.
2769 * nat/windows-nat.c (MS_VC_EXCEPTION, handle_exception)
2770 (STATUS_WX86_SINGLE_STEP, STATUS_WX86_BREAKPOINT): Move from
2771 windows-nat.c.
2772
2773 2020-04-08 Tom Tromey <tromey@adacore.com>
2774
2775 * windows-nat.c (exception_count, event_count): Remove.
2776 (handle_exception, get_windows_debug_event)
2777 (do_initial_windows_stuff): Update.
2778
2779 2020-04-08 Tom Tromey <tromey@adacore.com>
2780
2781 * windows-nat.c (windows_nat::handle_load_dll)
2782 (windows_nat::handle_unload_dll): Rename. No longer static.
2783 * nat/windows-nat.h (handle_load_dll, handle_unload_dll):
2784 Declare.
2785
2786 2020-04-08 Tom Tromey <tromey@adacore.com>
2787
2788 * complaints.h (stop_whining): Declare at top-level.
2789 (complaint): Don't declare stop_whining.
2790
2791 2020-04-08 Tom Tromey <tromey@adacore.com>
2792
2793 * windows-nat.c (windows_nat::handle_output_debug_string):
2794 Rename. No longer static.
2795 * nat/windows-nat.h (handle_output_debug_string): Declare.
2796
2797 2020-04-08 Tom Tromey <tromey@adacore.com>
2798
2799 * windows-nat.c (current_process_handle, current_process_id)
2800 (main_thread_id, last_sig, current_event, last_wait_event)
2801 (current_windows_thread, desired_stop_thread_id, pending_stops)
2802 (struct pending_stop, siginfo_er): Move to nat/windows-nat.c.
2803 (display_selectors, fake_create_process)
2804 (get_windows_debug_event): Update.
2805 * nat/windows-nat.h (current_process_handle, current_process_id)
2806 (main_thread_id, last_sig, current_event, last_wait_event)
2807 (current_windows_thread, desired_stop_thread_id, pending_stops)
2808 (struct pending_stop, siginfo_er): Move from windows-nat.c.
2809 * nat/windows-nat.c (current_process_handle, current_process_id)
2810 (main_thread_id, last_sig, current_event, last_wait_event)
2811 (current_windows_thread, desired_stop_thread_id, pending_stops)
2812 (siginfo_er): New globals. Move from windows-nat.c.
2813
2814 2020-04-08 Tom Tromey <tromey@adacore.com>
2815
2816 * windows-nat.c (get_image_name): Move to nat/windows-nat.c.
2817 (handle_load_dll): Update.
2818 * nat/windows-nat.c (get_image_name): Move from windows-nat.c.
2819
2820 2020-04-08 Tom Tromey <tromey@adacore.com>
2821
2822 * windows-nat.c (enum thread_disposition_type): Move to
2823 nat/windows-nat.h.
2824 (windows_nat::thread_rec): Rename from thread_rec. No longer
2825 static.
2826 (windows_add_thread, windows_nat_target::fetch_registers)
2827 (windows_nat_target::store_registers, handle_exception)
2828 (windows_nat_target::resume, get_windows_debug_event)
2829 (windows_nat_target::get_tib_address)
2830 (windows_nat_target::thread_name)
2831 (windows_nat_target::thread_alive): Update.
2832 * nat/windows-nat.h (enum thread_disposition_type): Move from
2833 windows-nat.c.
2834 (thread_rec): Declare.
2835
2836 2020-04-08 Tom Tromey <tromey@adacore.com>
2837
2838 * windows-nat.c: Add "using namespace".
2839 * nat/windows-nat.h: Wrap contents in windows_nat namespace.
2840 * nat/windows-nat.c: Wrap contents in windows_nat namespace.
2841
2842 2020-04-08 Tom Tromey <tromey@adacore.com>
2843
2844 * nat/windows-nat.h (struct windows_thread_info): Declare
2845 destructor.
2846 * nat/windows-nat.c (~windows_thread_info): New.
2847
2848 2020-04-08 Tom Tromey <tromey@adacore.com>
2849
2850 PR gdb/22992
2851 * windows-nat.c (current_event): Update comment.
2852 (last_wait_event, desired_stop_thread_id): New globals.
2853 (struct pending_stop): New.
2854 (pending_stops): New global.
2855 (windows_nat_target) <stopped_by_sw_breakpoint>
2856 <supports_stopped_by_sw_breakpoint>: New methods.
2857 (windows_fetch_one_register): Add assertions. Adjust PC.
2858 (windows_continue): Handle pending stops. Suspend other threads
2859 when stepping. Use last_wait_event
2860 (wait_for_debug_event): New function.
2861 (get_windows_debug_event): Use wait_for_debug_event. Handle
2862 pending stops. Queue spurious stops.
2863 (windows_nat_target::wait): Set stopped_at_software_breakpoint.
2864 (windows_nat_target::kill): Use wait_for_debug_event.
2865 * nat/windows-nat.h (struct windows_thread_info)
2866 <stopped_at_software_breakpoint>: New field.
2867 * nat/windows-nat.c (windows_thread_info::resume): Clear
2868 stopped_at_software_breakpoint.
2869
2870 2020-04-08 Tom Tromey <tromey@adacore.com>
2871
2872 * windows-nat.c (enum thread_disposition_type): New.
2873 (thread_rec): Replace "get_context" parameter with "disposition";
2874 change type.
2875 (windows_add_thread, windows_nat_target::fetch_registers)
2876 (windows_nat_target::store_registers, handle_exception)
2877 (windows_nat_target::resume, get_windows_debug_event)
2878 (windows_nat_target::get_tib_address)
2879 (windows_nat_target::thread_name)
2880 (windows_nat_target::thread_alive): Update.
2881
2882 2020-04-08 Tom Tromey <tromey@adacore.com>
2883
2884 * windows-nat.c (thread_rec): Use windows_thread_info::suspend.
2885 (windows_continue): Use windows_continue::resume.
2886 * nat/windows-nat.h (struct windows_thread_info) <suspend,
2887 resume>: Declare new methods.
2888 * nat/windows-nat.c: New file.
2889 * configure.nat (NATDEPFILES): Add nat/windows-nat.o when needed.
2890
2891 2020-04-08 Tom Tromey <tromey@adacore.com>
2892
2893 * windows-nat.c (windows_add_thread, windows_delete_thread)
2894 (windows_nat_target::fetch_registers)
2895 (windows_nat_target::store_registers, fake_create_process)
2896 (windows_nat_target::resume, windows_nat_target::resume)
2897 (get_windows_debug_event, windows_nat_target::wait)
2898 (windows_nat_target::pid_to_str)
2899 (windows_nat_target::get_tib_address)
2900 (windows_nat_target::get_ada_task_ptid)
2901 (windows_nat_target::thread_name)
2902 (windows_nat_target::thread_alive): Use lwp, not tid.
2903
2904 2020-04-08 Tom Tromey <tromey@adacore.com>
2905
2906 * windows-nat.c (handle_exception)
2907 (windows_nat_target::thread_name): Update.
2908 * nat/windows-nat.h (windows_thread_info): Remove destructor.
2909 <name>: Now unique_xmalloc_ptr.
2910
2911 2020-04-08 Tom Tromey <tromey@adacore.com>
2912
2913 * windows-nat.c (thread_rec)
2914 (windows_nat_target::fetch_registers): Update.
2915 * nat/windows-nat.h (struct windows_thread_info) <suspended>:
2916 Update comment.
2917 <debug_registers_changed, reload_context>: Now bool.
2918
2919 2020-04-08 Tom Tromey <tromey@adacore.com>
2920
2921 * windows-nat.c (windows_add_thread): Use new.
2922 (windows_init_thread_list, windows_delete_thread): Use delete.
2923 (get_windows_debug_event): Update.
2924 * nat/windows-nat.h (struct windows_thread_info): Add constructor,
2925 destructor, and initializers.
2926
2927 2020-04-08 Tom Tromey <tromey@adacore.com>
2928
2929 * windows-nat.c (struct windows_thread_info): Remove.
2930 * nat/windows-nat.h: New file.
2931
2932 2020-04-08 Tom Tromey <tromey@adacore.com>
2933
2934 * windows-nat.c (struct windows_thread_info) <tid>: Rename from "id".
2935 (thread_rec, windows_add_thread, windows_delete_thread)
2936 (windows_continue): Update.
2937
2938 2020-04-08 Tom Tromey <tromey@adacore.com>
2939
2940 * windows-nat.c (struct windows_thread_info): Remove typedef.
2941 (thread_head): Remove.
2942 (thread_list): New global.
2943 (thread_rec, windows_add_thread, windows_init_thread_list)
2944 (windows_delete_thread, windows_continue): Update.
2945
2946 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
2947
2948 * windows-tdep.h (windows_init_abi): Add comment.
2949 (cygwin_init_abi): New declaration.
2950 * windows-tdep.c: Split signal enumeration in two, one for
2951 Windows and one for Cygwin.
2952 (windows_gdb_signal_to_target): Only deal with signal of the
2953 Windows OS ABI.
2954 (cygwin_gdb_signal_to_target): New function.
2955 (windows_init_abi): Rename to windows_init_abi_common, don't set
2956 gdb_signal_to_target gdbarch method. Add new new function with
2957 this name.
2958 (cygwin_init_abi): New function.
2959 * amd64-windows-tdep.c (amd64_windows_init_abi_common): Add
2960 comment. Don't call windows_init_abi.
2961 (amd64_windows_init_abi): Add comment, call windows_init_abi.
2962 (amd64_cygwin_init_abi): Add comment, call cygwin_init_abi.
2963 * i386-windows-tdep.c (i386_windows_init_abi): Rename to
2964 i386_windows_init_abi_common, don't call windows_init_abi. Add
2965 a new function of this name.
2966 (i386_cygwin_init_abi): New function.
2967 (_initialize_i386_windows_tdep): Bind i386_cygwin_init_abi to
2968 OS ABI Cygwin.
2969
2970 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
2971
2972 * dwarf2/read.c (read_gdb_index_from_buffer): Remove objfile
2973 parameter.c.
2974 (dwarf2_read_gdb_index): Update.
2975
2976 2020-04-07 Kamil Rytarowski <n54@gmx.com>
2977
2978 * nbsd-tdep.c: Include "objfiles.h".
2979 (nbsd_skip_solib_resolver): New.
2980 (nbsd_init_abi): Call set_gdbarch_skip_solib_resolver().
2981
2982 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
2983
2984 * dwarf2/loc.c (loclist_describe_location): Call the function decode_debug_loclists_
2985 addresses if DWARF version is 5 or more because DW_LLE_start* or DW_LLE_offset_pair
2986 with DW_LLE_base_addressx are being emitted in DWARFv5.
2987 Add the newly added kind DW_LOC_OFFSET_PAIR also.
2988 The length of location description is an unsigned ULEB integer in DWARFv5 instead of
2989 unsigned integer.
2990
2991 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
2992
2993 * dwarf2/loc.c (enum debug_loc_kind): Add a new kind DEBUG_LOC_OFFSET_PAIR.
2994 (dwarf2_find_location_expression): Call the function decode_debug_loclists_
2995 addresses if DWARF version is 5 or more. DW_LLE_start* or DW_LLE_offset_pair
2996 with DW_LLE_base_addressx are being emitted in DWARFv5 instead of DW_LLE_GNU*.
2997 Add applicable base address if the entry is DW_LLE_offset_pair from DWO.
2998 (decode_debug_loclists_addresses): Return DEBUG_LOC_OFFSET_PAIR instead of
2999 DEBUG_LOC_START_END in case of DW_LLE_offset_pair.
3000
3001
3002 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
3003
3004 * dwarf2/read.c (cu_debug_loc_section): Added the declaration for the function.
3005 (read_loclist_index): New function definition.
3006 (lookup_loclist_base): New function definition.
3007 (read_loclist_header): New function definition.
3008 (dwarf2_cu): Add loclist_base and loclist_header field.
3009 (dwarf2_locate_dwo_sections): Handle .debug_loclists.dwo section.
3010 (read_full_die_1): Read the value of DW_AT_loclists_base.
3011 (read_attribute_reprocess): Handle DW_FORM_loclistx.
3012 (read_attribute_value): Handle DW_FORM_loclistx.
3013 (skip_one_die): Handle DW_FORM_loclistx.
3014 (loclist_header): New structure declaration.
3015 * dwarf2/attribute.c (form_is_section_offset): Handle DW_FORM_loclistx.
3016
3017 2020-04-07 Simon Marchi <simon.marchi@polymtl.ca>
3018
3019 * dwarf2/read.h (struct dwarf2_psymtab): Remove two-parameters
3020 constructor. Remove `addr` parameter from other constructor and
3021 add `per_cu` parameter.
3022 * dwarf2/read.c (create_partial_symtab): Update.
3023
3024 2020-04-07 Tom de Vries <tdevries@suse.de>
3025
3026 PR symtab/25796
3027 * dwarf2/read.c (can_have_DW_AT_const_value_p): New function.
3028 (partial_die_info::fixup): Inherit has_const_value.
3029
3030 2020-04-07 Tom de Vries <tdevries@suse.de>
3031
3032 * psymtab.c (maintenance_check_psymtabs): Skip static LOC_BLOCK
3033 symbols without address.
3034
3035 2020-04-06 Kamil Rytarowski <n54@gmx.com>
3036
3037 * nbsd-nat.h (struct thread_info): Add forward declaration.
3038 (nbsd_nat_target::thread_alive): Add.
3039 (nbsd_nat_target::thread_name): Likewise.
3040 (nbsd_nat_target::update_thread_list): Likewise.
3041 (update_thread_list::post_attach): Likewise.
3042 (post_attach::pid_to_str): Likewise.
3043 * nbsd-nat.c: Include "gdbthread.h" and "inferior.h".
3044 (nbsd_thread_lister): Add.
3045 (nbsd_nat_target::thread_alive): Likewise.
3046 (nbsd_nat_target::thread_name): Likewise.
3047 (nbsd_add_threads): Likewise.
3048 (update_thread_list::post_attach): Likewise.
3049 (nbsd_nat_target::update_thread_list): Likewise.
3050 (post_attach::pid_to_str): Likewise.
3051
3052 2020-04-06 Tom Tromey <tromey@adacore.com>
3053
3054 * ada-valprint.c (print_variant_part): Extract the variant field.
3055 (print_field_values): Use the field as the outer value when
3056 recursing.
3057
3058 2020-04-06 Tom Tromey <tromey@adacore.com>
3059
3060 * sh-nbsd-tdep.c: Include nbsd-tdep.h.
3061 * ppc-nbsd-tdep.c: Include nbsd-tdep.h.
3062 * mips-nbsd-tdep.c (mipsnbsd_init_abi): Add missing ";".
3063 * arm-nbsd-tdep.c: Include nbsd-tdep.h.
3064 * hppa-nbsd-tdep.c: Include nbsd-tdep.h.
3065
3066 2020-04-06 Tom Tromey <tromey@adacore.com>
3067
3068 * dwarf2/read.c (read_base_type) <DW_ATE_complex_float>: Handle
3069 TYPE_CODE_ERROR.
3070
3071 2020-04-06 Kamil Rytarowski <n54@gmx.com>
3072
3073 * nbsd-tdep.c: Include "gdbarch.h".
3074 Define enum with NetBSD signal numbers.
3075 (nbsd_gdb_signal_from_target, nbsd_gdb_signal_to_target): New.
3076 * alpha-nbsd-tdep.c (alphanbsd_init_abi): Call nbsd_init_abi().
3077 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
3078 * arm-nbsd-tdep.c (arm_netbsd_elf_init_abi): Likewise.
3079 * hppa-nbsd-tdep.c (hppanbsd_init_abi): Likewise.
3080 * i386-nbsd-tdep.c (i386nbsd_init_abi): Likewise.
3081 * mips-nbsd-tdep.c (nbsd_init_abi): Likewise.
3082 * ppc-nbsd-tdep.c (ppcnbsd_init_abi): Likewise.
3083 * sh-nbsd-tdep.c (shnbsd_init_abi): Likewise.
3084 * sparc-nbsd-tdep.c (sparc32nbsd_init_abi): Likewise.
3085 * sparc64-nbsd-tdep.c (sparc64nbsd_init_abi): Likewise.
3086 * vax-nbsd-tdep.c (vaxnbsd_elf_init_abi): Likewise.
3087
3088 2020-04-03 Hannes Domani <ssbssa@yahoo.de>
3089
3090 PR gdb/25325
3091 * dwarf2/read.c (read_enumeration_type): Fix typed enum attributes.
3092
3093 2020-04-03 Tom Tromey <tromey@adacore.com>
3094
3095 * dwarf2/loc.c (disassemble_dwarf_expression) <DW_OP_const_type>:
3096 Read constant block.
3097
3098 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
3099
3100 * gdb_bfd.h: Include gdbsupport/byte-vector.h.
3101 (gdb_bfd_get_full_section_contents): New declaration.
3102 * gdb_bfd.c (gdb_bfd_get_full_section_contents): New function.
3103 * windows-tdep.c (is_linked_with_cygwin_dll): Use
3104 gdb_bfd_get_full_section_contents.
3105
3106 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
3107
3108 * exec.c (build_section_table): Replace internal_error with
3109 gdb_assert.
3110 (section_table_xfer_memory_partial): Likewise.
3111 * mdebugread.c (parse_partial_symbols): Likewise.
3112 * psymtab.c (lookup_partial_symbol): Likewise.
3113 * utils.c (wrap_here): Likewise.
3114
3115 2020-04-02 Tom Tromey <tromey@adacore.com>
3116
3117 * f-lang.c (build_fortran_types): Use arch_type to initialize
3118 builtin_complex_s32 in the TYPE_CODE_ERROR case.
3119
3120 2020-04-02 Tom Tromey <tromey@adacore.com>
3121
3122 * dwarf2/read.c (partial_die_info::read): Do not create a vector
3123 of attributes.
3124
3125 2020-04-02 Andrew Burgess <andrew.burgess@embecosm.com>
3126 Bernd Edlinger <bernd.edlinger@hotmail.de>
3127 Tom Tromey <tromey@adacore.com>
3128
3129 * buildsym.c (buildsym_compunit::record_line): Remove
3130 deduplication code.
3131
3132 2020-04-02 Tom de Vries <tdevries@suse.de>
3133
3134 PR ada/24671
3135 * dwarf2/read.c (dw2_map_matching_symbols): Handle -readnow.
3136
3137 2020-04-02 Tom de Vries <tdevries@suse.de>
3138
3139 * dwarf2/read.c (dwarf2_gdb_index_functions,
3140 dwarf2_debug_names_functions): Init lookup_global_symbol_language with
3141 NULL.
3142 * psymtab.c (psym_lookup_global_symbol_language): New function.
3143 (psym_functions): Init psym_lookup_global_symbol_language with
3144 psym_lookup_global_symbol_language.
3145 * symfile-debug.c (debug_sym_quick_functions): Init
3146 lookup_global_symbol_language with NULL.
3147 * symfile.c (set_initial_language): Remove fixme comment.
3148 * symfile.h (struct quick_symbol_functions): Add
3149 lookup_global_symbol_language.
3150 * symtab.c (find_quick_global_symbol_language): New function.
3151 (find_main_name): Use find_quick_global_symbol_language.
3152
3153 2020-04-01 Simon Marchi <simon.marchi@polymtl.ca>
3154
3155 * windows-tdep.c (is_linked_with_cygwin_dll): Fix style.
3156
3157 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
3158
3159 * buildsym.c (record_line): Fix undefined behavior and preserve
3160 lines at eof.
3161
3162 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
3163
3164 * buildsym.c (record_line): Fix the resizing condition.
3165
3166 2020-04-01 Tom Tromey <tom@tromey.com>
3167
3168 * value.h (value_literal_complex): Add comment.
3169 * valops.c (value_literal_complex): Refer to value.h.
3170
3171 2020-04-01 Tom Tromey <tom@tromey.com>
3172
3173 * c-exp.y (FLOAT_KEYWORD, COMPLEX): New tokens.
3174 (scalar_type): New rule, from typebase.
3175 (typebase): Use scalar_type. Recognize complex types.
3176 (field_name): Handle FLOAT_KEYWORD.
3177 (ident_tokens): Add _Complex and __complex__.
3178
3179 2020-04-01 Tom Tromey <tom@tromey.com>
3180
3181 PR exp/25299:
3182 * valarith.c (promotion_type, complex_binop): New functions.
3183 (scalar_binop): Handle complex numbers. Use promotion_type.
3184 (value_pos, value_neg, value_complement): Handle complex numbers.
3185
3186 2020-04-01 Tom Tromey <tom@tromey.com>
3187
3188 * c-exp.y (COMPLEX_INT, COMPLEX_FLOAT): New tokens.
3189 (exp) <COMPLEX_INT, COMPLEX_FLOAT>: New rules.
3190 (parse_number): Handle complex numbers.
3191
3192 2020-04-01 Tom Tromey <tom@tromey.com>
3193
3194 * c-valprint.c (c_decorations): Change complex suffix to "i".
3195
3196 2020-04-01 Tom Tromey <tom@tromey.com>
3197
3198 * valprint.c (generic_value_print_complex): Use accessors.
3199 * value.h (value_real_part, value_imaginary_part): Declare.
3200 * valops.c (value_real_part, value_imaginary_part): New
3201 functions.
3202 * value.c (creal_internal_fn, cimag_internal_fn): Use accessors.
3203
3204 2020-04-01 Tom Tromey <tom@tromey.com>
3205
3206 * stabsread.c (rs6000_builtin_type, read_sun_floating_type)
3207 (read_range_type): Update.
3208 * mdebugread.c (basic_type): Update.
3209 * go-lang.c (build_go_types): Use init_complex_type.
3210 * gdbtypes.h (struct main_type) <complex_type>: New member.
3211 (init_complex_type): Update.
3212 (arch_complex_type): Don't declare.
3213 * gdbtypes.c (init_complex_type): Remove "objfile" parameter.
3214 Make name if none given. Use alloc_type_copy. Look for cached
3215 complex type.
3216 (arch_complex_type): Remove.
3217 (gdbtypes_post_init): Use init_complex_type.
3218 * f-lang.c (build_fortran_types): Use init_complex_type.
3219 * dwarf2/read.c (read_base_type): Update.
3220 * d-lang.c (build_d_types): Use init_complex_type.
3221 * ctfread.c (read_base_type): Update.
3222
3223 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3224
3225 * infrun.c (stop_all_threads): Update assertion, plus when
3226 stopping threads, take into account that we might be trying
3227 to stop an all-stop target.
3228 (stop_waiting): Call 'stop_all_threads' if there exists a
3229 non-stop target.
3230
3231 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3232
3233 * target.h (exists_non_stop_target): New function declaration.
3234 * target.c (exists_non_stop_target): New function.
3235
3236 2020-04-01 Hannes Domani <ssbssa@yahoo.de>
3237
3238 PR gdb/24789
3239 * eval.c (is_integral_or_integral_reference): New function.
3240 (evaluate_subexp_standard): Allow integer references in
3241 pointer arithmetic.
3242
3243 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3244
3245 * remote.c (remote_target::remote_parse_stop_reply): Remove the
3246 check for no ptid in the stop reply when the target is non-stop.
3247
3248 2020-04-01 Tom Tromey <tromey@adacore.com>
3249
3250 * symtab.h (class lookup_name_info) <lookup_name_info>: Change
3251 "name" parameter to rvalue reference. Initialize m_name_holder.
3252 <lookup_name_info>: New overloads.
3253 <name>: Return gdb::string_view.
3254 <c_str>: New method.
3255 <make_ignore_params>: Update.
3256 <search_name_hash>: Update.
3257 <language_lookup_name>: Return const char *.
3258 <m_name>: Change type.
3259 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info)
3260 (demangle_for_lookup_info::demangle_for_lookup_info): Update.
3261 (lookup_name_info::match_any): Update.
3262 * psymtab.c (match_partial_symbol, lookup_partial_symbol):
3263 Update.
3264 * minsyms.c (linkage_name_str): Update.
3265 * language.c (default_symbol_name_matcher): Update.
3266 * dwarf2/read.c (mapped_index_base::find_name_components_bounds):
3267 Update.
3268 * ada-lang.c (ada_fold_name): Change parameter to string_view.
3269 (ada_lookup_name_info::ada_lookup_name_info): Update.
3270 (literal_symbol_name_matcher): Update.
3271
3272 2020-04-01 Tom Tromey <tromey@adacore.com>
3273
3274 * psymtab.c (psymtab_search_name): Remove function.
3275 (psym_lookup_symbol): Create search name and lookup name here.
3276 (lookup_partial_symbol): Remove "name" parameter; add
3277 lookup_name.
3278 (psym_expand_symtabs_for_function): Update.
3279
3280 2020-03-31 Joel Jones <joelkevinjones@gmail.com>
3281
3282 PR tui/25597:
3283 * python/py-tui.c: Include gdb_curses.h inside of #ifdef TUI.
3284
3285 2020-03-31 Tom Tromey <tromey@adacore.com>
3286
3287 * dwarf2/abbrev.c (abbrev_table::read): Conditionally call
3288 memcpy.
3289
3290 2020-03-30 Nelson Chu <nelson.chu@sifive.com>
3291
3292 * features/riscv/32bit-csr.xml: Regenerated.
3293 * features/riscv/64bit-csr.xml: Regenerated.
3294
3295 2020-03-30 Tom Tromey <tromey@adacore.com>
3296
3297 * ada-valprint.c (print_variant_part): Update.
3298 * ada-lang.h (ada_which_variant_applies): Update.
3299 * ada-lang.c (ada_which_variant_applies): Remove outer_type and
3300 outer_valaddr parameters; replace with "outer" value parameter.
3301 (to_fixed_variant_branch_type): Update.
3302
3303 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3304
3305 * ppc-linux-nat.c: Include <algorithm>, <unordered_map>, and
3306 <list>. Remove inclusion of observable.h.
3307 (PPC_DEBUG_CURRENT_VERSION): Move up define.
3308 (struct arch_lwp_info): New struct.
3309 (class ppc_linux_dreg_interface): New class.
3310 (struct ppc_linux_process_info): New struct.
3311 (struct ppc_linux_nat_target) <low_delete_thread, low_new_fork>
3312 <low_new_clone, low_forget_process, low_prepare_to_resume>
3313 <copy_thread_dreg_state, mark_thread_stale>
3314 <mark_debug_registers_changed, register_hw_breakpoint>
3315 <clear_hw_breakpoint, register_wp, clear_wp>
3316 <can_use_watchpoint_cond_accel, calculate_dvc, check_condition>
3317 <num_memory_accesses, get_trigger_type>
3318 <create_watchpoint_request, hwdebug_point_cmp>
3319 <init_arch_lwp_info, get_arch_lwp_info>
3320 <low_stopped_by_watchpoint, low_stopped_data_address>: Declare as
3321 methods.
3322 <struct ptid_hash>: New inner struct.
3323 <m_dreg_interface, m_process_info, m_installed_hw_bps>: Declare
3324 members.
3325 (saved_dabr_value, hwdebug_info, max_slots_number)
3326 (struct hw_break_tuple, struct thread_points, ppc_threads)
3327 (have_ptrace_hwdebug_interface)
3328 (hwdebug_find_thread_points_by_tid)
3329 (hwdebug_insert_point, hwdebug_remove_point): Remove.
3330 (ppc_linux_nat_target::can_use_hw_breakpoint): Use
3331 m_dreg_interface, remove call to PTRACE_SET_DEBUGREG.
3332 (ppc_linux_nat_target::region_ok_for_hw_watchpoint): Add comment,
3333 use m_dreg_interface.
3334 (hwdebug_point_cmp): Change to...
3335 (ppc_linux_nat_target::hwdebug_point_cmp): ...this method. Use
3336 reference arguments instead of pointers.
3337 (ppc_linux_nat_target::ranged_break_num_registers): Use
3338 m_dreg_interface.
3339 (ppc_linux_nat_target::insert_hw_breakpoint): Add comment, use
3340 m_dreg_interface. Call register_hw_breakpoint.
3341 (ppc_linux_nat_target::remove_hw_breakpoint): Add comment, use
3342 m_dreg_interface. Call clear_hw_breakpoint.
3343 (get_trigger_type): Change to...
3344 (ppc_linux_nat_target::get_trigger_type): ...this method. Add
3345 comment.
3346 (ppc_linux_nat_target::insert_mask_watchpoint): Update comment,
3347 use m_dreg_interface. Call register_hw_breakpoint.
3348 (ppc_linux_nat_target::remove_mask_watchpoint): Update comment,
3349 use m_dreg_interface. Call clear_hw_breakpoint.
3350 (can_use_watchpoint_cond_accel): Change to...
3351 (ppc_linux_nat_target::can_use_watchpoint_cond_accel): ...this
3352 method. Update comment, use m_dreg_interface and
3353 m_process_info.
3354 (calculate_dvc): Change to...
3355 (ppc_linux_nat_target::calculate_dvc): ...this method. Use
3356 m_dreg_interface.
3357 (num_memory_accesses): Change to...
3358 (ppc_linux_nat_target::num_memory_accesses): ...this method.
3359 (check_condition): Change to...
3360 (ppc_linux_nat_target::check_condition): ...this method.
3361 (ppc_linux_nat_target::can_accel_watchpoint_condition): Update
3362 comment, use m_dreg_interface.
3363 (create_watchpoint_request): Change to...
3364 (ppc_linux_nat_target::create_watchpoint_request): ...this
3365 method. Use m_dreg_interface.
3366 (ppc_linux_nat_target::insert_watchpoint): Add comment, use
3367 m_dreg_interface. Call register_hw_breakpoint or register_wp.
3368 (ppc_linux_nat_target::remove_watchpoint): Add comment, use
3369 m_dreg_interface. Call clear_hw_breakpoint or clear_wp.
3370 (ppc_linux_nat_target::low_forget_process)
3371 (ppc_linux_nat_target::low_new_fork)
3372 (ppc_linux_nat_target::low_new_clone)
3373 (ppc_linux_nat_target::low_delete_thread)
3374 (ppc_linux_nat_target::low_prepare_to_resume): New methods.
3375 (ppc_linux_nat_target::low_new_thread): Remove previous logic,
3376 only call mark_thread_stale.
3377 (ppc_linux_thread_exit): Remove.
3378 (ppc_linux_nat_target::stopped_data_address): Change to...
3379 (ppc_linux_nat_target::low_stopped_data_address): This. Add
3380 comment, use m_dreg_interface and m_thread_hw_breakpoints.
3381 (ppc_linux_nat_target::stopped_by_watchpoint): Change to...
3382 (ppc_linux_nat_target::stopped_by_watchpoint): This. Add
3383 comment. Call low_stopped_data_address.
3384 (ppc_linux_nat_target::watchpoint_addr_within_range): Use
3385 m_dreg_interface.
3386 (ppc_linux_nat_target::masked_watch_num_registers): Use
3387 m_dreg_interface.
3388 (ppc_linux_nat_target::copy_thread_dreg_state)
3389 (ppc_linux_nat_target::mark_thread_stale)
3390 (ppc_linux_nat_target::mark_debug_registers_changed)
3391 (ppc_linux_nat_target::register_hw_breakpoint)
3392 (ppc_linux_nat_target::clear_hw_breakpoint)
3393 (ppc_linux_nat_target::register_wp)
3394 (ppc_linux_nat_target::clear_wp)
3395 (ppc_linux_nat_target::init_arch_lwp_info)
3396 (ppc_linux_nat_target::get_arch_lwp_info): New methods.
3397 (_initialize_ppc_linux_nat): Remove observer callback.
3398
3399 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3400
3401 * ppc-linux-nat.c (ppc_linux_nat_target::store_registers)
3402 (ppc_linux_nat_target::auxv_parse)
3403 (ppc_linux_nat_target::read_description)
3404 (supply_gregset, fill_gregset, supply_fpregset, fill_fpregset):
3405 Move up.
3406
3407 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3408
3409 * linux-nat.h (low_new_clone): New method.
3410 * linux-nat.c (linux_handle_extended_wait): Call low_new_clone.
3411
3412 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
3413
3414 * dbxread.c (dbx_psymtab_to_symtab_1): Rename to...
3415 (dbx_expand_psymtab): ... this.
3416 (start_psymtab): Update.
3417 * mdebugread.c (psymtab_to_symtab_1): Rename to...
3418 (mdebug_expand_psymtab): ... this.
3419 (parse_partial_symbols): Update.
3420 (new_psymtab): Update.
3421 * xcoffread.c (xcoff_psymtab_to_symtab_1): Rename to...
3422 (xcoff_expand_psymtab): ... this.
3423 (xcoff_start_psymtab): Update.
3424
3425 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
3426
3427 * psympriv.h (partial_symtab) <read_dependencies>: Rename to...
3428 <expand_dependencies>: ... this.
3429 * psymtab.c (partial_symtab::read_dependencies): Rename to...
3430 (partial_symtab::expand_dependencies): ... this.
3431 * dwarf2/read.c (dwarf2_include_psymtab) <expand_psymtab>:
3432 Update.
3433 (dwarf2_psymtab::expand_psymtab): Update.
3434 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
3435 * mdebugread.c (psymtab_to_symtab_1): Update.
3436 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
3437
3438 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
3439
3440 * psympriv.h (discard_psymtab): Remove.
3441 * dbxread.c (dbx_end_psymtab): Update.
3442 * xcoffread.c (xcoff_end_psymtab): Update.
3443
3444 2020-03-28 Tom Tromey <tom@tromey.com>
3445
3446 * dwarf2/attribute.h (struct attribute) <form_is_constant>: Update
3447 comment.
3448
3449 2020-03-28 Tom Tromey <tom@tromey.com>
3450
3451 * dwarf2/read.c (read_attribute_reprocess): Fix formatting.
3452
3453 2020-03-27 Hannes Domani <ssbssa@yahoo.de>
3454
3455 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
3456
3457 2020-03-26 John Baldwin <jhb@FreeBSD.org>
3458
3459 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_BSDFLAGS.
3460
3461 2020-03-26 Tom Tromey <tom@tromey.com>
3462
3463 * dwarf2/read.c (handle_data_member_location, dwarf2_add_field)
3464 (mark_common_block_symbol_computed, read_tag_string_type)
3465 (attr_to_dynamic_prop, read_subrange_type): Update.
3466 (dwarf2_get_ref_die_offset, dwarf2_get_attr_constant_value): Move
3467 to be methods on struct attribute.
3468 (skip_one_die, process_imported_unit_die, read_namespace_alias)
3469 (read_call_site_scope, partial_die_info::read)
3470 (partial_die_info::read, lookup_die_type, follow_die_ref):
3471 Update.
3472 * dwarf2/attribute.c (attribute::get_ref_die_offset): New method,
3473 from dwarf2_get_ref_die_offset.
3474 (attribute::constant_value): New method, from
3475 dwarf2_get_attr_constant_value.
3476 * dwarf2/attribute.h (struct attribute) <get_ref_die_offset>:
3477 Declare method.
3478 <constant_value>: New method.
3479
3480 2020-03-26 Tom Tromey <tom@tromey.com>
3481
3482 * dwarf2/read.c (dwarf_unit_type_name, dwarf_tag_name)
3483 (dwarf_attr_name, dwarf_form_name, dwarf_bool_name)
3484 (dwarf_type_encoding_name): Move to stringify.c.
3485 * Makefile.in (COMMON_SFILES): Add dwarf2/stringify.c.
3486 * dwarf2/stringify.c: New file.
3487 * dwarf2/stringify.h: New file.
3488
3489 2020-03-26 Tom Tromey <tom@tromey.com>
3490
3491 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>:
3492 Rewrite.
3493
3494 2020-03-26 Tom Tromey <tom@tromey.com>
3495
3496 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>: New
3497 methods.
3498 * dwarf2/read.c (lookup_addr_base): Move to die.h.
3499 (lookup_ranges_base): Likewise.
3500 (read_cutu_die_from_dwo, read_full_die_1): Update.
3501
3502 2020-03-26 Tom Tromey <tom@tromey.com>
3503
3504 * dwarf2/read.c (read_import_statement, read_file_scope)
3505 (read_type_unit_scope, inherit_abstract_dies, read_func_scope)
3506 (read_lexical_block_scope, read_call_site_scope)
3507 (dwarf2_get_subprogram_pc_bounds, get_scope_pc_bounds)
3508 (handle_struct_member_die, process_structure_scope)
3509 (update_enumeration_type_from_children)
3510 (process_enumeration_scope, read_array_type, read_common_block)
3511 (read_namespace, read_module, read_subroutine_type): Update.
3512 (sibling_die): Remove.
3513
3514 2020-03-26 Tom Tromey <tom@tromey.com>
3515
3516 * dwarf2/read.c (lookup_addr_base, lookup_ranges_base)
3517 (build_type_psymtabs_reader, read_structure_type)
3518 (read_enumeration_type, read_full_die_1): Update.
3519 (dwarf2_attr_no_follow): Move to die.h.
3520 * dwarf2/die.h (struct die_info) <attr>: New method.
3521
3522 2020-03-26 Tom Tromey <tom@tromey.com>
3523
3524 * dwarf2/read.c (struct dwarf2_cu) <base_known>: Remove.
3525 <base_address>: Now an optional.
3526 (dwarf2_find_base_address, dwarf2_rnglists_process)
3527 (dwarf2_ranges_process, fill_in_loclist_baton)
3528 (dwarf2_symbol_mark_computed): Update.
3529
3530 2020-03-26 Tom Tromey <tom@tromey.com>
3531
3532 * dwarf2/read.c (struct die_info): Move to die.h.
3533 * dwarf2/die.h: New file.
3534
3535 2020-03-26 Tom Tromey <tom@tromey.com>
3536
3537 * dwarf2/line-header.h (dwarf_decode_line_header): Declare.
3538 * dwarf2/read.c
3539 (dwarf2_statement_list_fits_in_line_number_section_complaint):
3540 Move to line-header.c.
3541 (read_checked_initial_length_and_offset, read_formatted_entries):
3542 Likewise.
3543 (dwarf_decode_line_header): Split into two.
3544 * dwarf2/line-header.c
3545 (dwarf2_statement_list_fits_in_line_number_section_complaint):
3546 Move from read.c.
3547 (read_checked_initial_length_and_offset, read_formatted_entries):
3548 Likewise.
3549 (dwarf_decode_line_header): New function, split from read.c.
3550
3551 2020-03-26 Tom Tromey <tom@tromey.com>
3552
3553 * dwarf2/read.h (struct dwarf2_per_objfile) <read_line_string>:
3554 Declare method.
3555 * dwarf2/read.c (read_attribute_value): Update.
3556 (dwarf2_per_objfile::read_line_string): Rename from
3557 read_indirect_line_string.
3558 (read_formatted_entries): Update.
3559
3560 2020-03-26 Tom Tromey <tom@tromey.com>
3561
3562 * dwarf2/macro.c (dwarf_decode_macro_bytes): Use objfile local
3563 variable.
3564
3565 2020-03-26 Tom Tromey <tom@tromey.com>
3566
3567 * dwarf2/macro.h (dwarf_decode_macros): Make section parameter
3568 const.
3569 * dwarf2/macro.c (skip_form_bytes, skip_unknown_opcode)
3570 (dwarf_decode_macro_bytes, dwarf_decode_macros): Make section
3571 parameter const.
3572
3573 2020-03-26 Tom Tromey <tom@tromey.com>
3574
3575 * dwarf2/read.c (dwarf_decode_macros): Make "lh" const.
3576 * dwarf2/macro.h (dwarf_decode_macros): Constify "lh" parameter.
3577 * dwarf2/macro.c (macro_start_file): Constify "lh" parameter.
3578 (dwarf_decode_macro_bytes, dwarf_decode_macros): Likewise.
3579
3580 2020-03-26 Tom Tromey <tom@tromey.com>
3581
3582 * dwarf2/line-header.h (struct line_header) <is_valid_file_index,
3583 file_names_size, file_full_name, file_file_name>: Use const.
3584 <file_name_at, file_names>: Add const overload.
3585 * dwarf2/line-header.c (line_header::file_file_name)
3586 (line_header::file_full_name): Update.
3587
3588 2020-03-26 Tom Tromey <tom@tromey.com>
3589
3590 * dwarf2/read.c (dwarf2_macro_malformed_definition_complaint)
3591 (macro_start_file, consume_improper_spaces)
3592 (parse_macro_definition, skip_form_bytes, skip_unknown_opcode)
3593 (dwarf_parse_macro_header, dwarf_decode_macro_bytes)
3594 (dwarf_decode_macros): Move to macro.c.
3595 * dwarf2/macro.c: New file.
3596 * dwarf2/macro.h: New file.
3597 * Makefile.in (COMMON_SFILES): Add dwarf2/macro.c.
3598
3599 2020-03-26 Tom Tromey <tom@tromey.com>
3600
3601 * dwarf2/section.h (struct dwarf2_section_info) <read_string>: New
3602 method.
3603 * dwarf2/section.c: New method. From
3604 read_indirect_string_at_offset_from.
3605 * dwarf2/read.c (mapped_debug_names::namei_to_name): Update.
3606 (read_indirect_string_at_offset_from): Move to section.c.
3607 (read_indirect_string_at_offset): Rewrite.
3608 (read_indirect_line_string_at_offset): Remove.
3609 (read_indirect_string, read_indirect_line_string)
3610 (dwarf_decode_macro_bytes): Update.
3611
3612 2020-03-26 Tom Tromey <tom@tromey.com>
3613
3614 * dwarf2/section.h (struct dwarf2_section_info)
3615 <overload_complaint>: Declare.
3616 (dwarf2_section_buffer_overflow_complaint): Don't declare.
3617 * dwarf2/section.c (dwarf2_section_info::overflow_complaint):
3618 Rename from dwarf2_section_buffer_overflow_complaint.
3619 * dwarf2/read.c (skip_one_die, partial_die_info::read)
3620 (skip_form_bytes, dwarf_decode_macro_bytes): Update.
3621
3622 2020-03-26 Tom Tromey <tom@tromey.com>
3623
3624 * dwarf2/section.h (dwarf2_section_buffer_overflow_complaint):
3625 Declare.
3626 * dwarf2/section.c (dwarf2_section_buffer_overflow_complaint):
3627 Move from read.c.
3628 * dwarf2/read.c (dwarf2_section_buffer_overflow_complaint): Move
3629 to section.c.
3630
3631 2020-03-26 Tom Tromey <tom@tromey.com>
3632
3633 * dwarf2/read.c (dwarf_decode_macros): Split into two overloads.
3634
3635 2020-03-26 Tom Tromey <tom@tromey.com>
3636
3637 * dwarf2/read.c (macro_start_file): Change "cu" parameter to
3638 "builder".
3639 (dwarf_decode_macro_bytes): Likewise. Add dwarf2_per_objfile
3640 parameter.
3641 (dwarf_decode_macros): Update.
3642
3643 2020-03-26 Tom Tromey <tom@tromey.com>
3644
3645 * dwarf2/read.c (read_attribute_value): Update.
3646 (read_indirect_string_from_dwz): Move to dwz.c; change into
3647 method.
3648 (dwarf_decode_macro_bytes): Update.
3649 * dwarf2/dwz.h (struct dwz_file) <read_string>: Declare method.
3650 * dwarf2/dwz.c: New file.
3651 * Makefile.in (COMMON_SFILES): Add dwz.c.
3652
3653 2020-03-26 Tom Tromey <tom@tromey.com>
3654
3655 * dwarf2/read.h (struct dwz_file): Move to dwz.h.
3656 * dwarf2/read.c: Add include.
3657 * dwarf2/index-write.c: Add include.
3658 * dwarf2/index-cache.c: Add include.
3659 * dwarf2/dwz.h: New file.
3660
3661 2020-03-25 Tom Tromey <tom@tromey.com>
3662
3663 * compile/compile-object-load.c (get_out_value_type): Mention
3664 correct symbol name in error message.
3665
3666 2020-03-25 Hannes Domani <ssbssa@yahoo.de>
3667
3668 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
3669
3670 2020-03-25 Tom de Vries <tdevries@suse.de>
3671
3672 * symtab.h (is_main_symtab_of_compunit_symtab): New function.
3673 * symmisc.c (dump_symtab_1): Print user and includes fields.
3674 (maintenance_info_symtabs): Same.
3675
3676 2020-03-25 Andrew Burgess <andrew.burgess@embecosm.com>
3677
3678 PR gdb/25534
3679 * riscv-tdep.c (riscv_arg_info::c_offset): Update comment.
3680 (riscv_regcache_cooked_write): New function.
3681 (riscv_push_dummy_call): Use new function.
3682 (riscv_return_value): Likewise.
3683
3684 2020-03-24 Simon Marchi <simon.marchi@polymtl.ca>
3685
3686 * fbsd-nat.c (fbsd_nat_target::follow_fork): Change bool to int.
3687 * fbsd-nat.h (class fbsd_nat_target) <follow_fork>: Likewise.
3688 * inf-ptrace.c (inf_ptrace_target::follow_fork): Likewise.
3689 * inf-ptrace.h (struct inf_ptrace_target) <follow_fork>: Likewise.
3690 * infrun.c (follow_fork): Likewise.
3691 (follow_fork_inferior): Likewise.
3692 * linux-nat.c (linux_nat_target::follow_fork): Likewise.
3693 * linux-nat.h (class linux_nat_target): Likewise.
3694 * remote.c (class remote_target) <follow_fork>: Likewise.
3695 (remote_target::follow_fork): Likewise.
3696 * target-delegates.c: Re-generate.
3697 * target.c (default_follow_fork): Likewise.
3698 (target_follow_fork): Likewise.
3699 * target.h (struct target_ops) <follow_fork>: Likewise.
3700 (target_follow_fork): Likewise.
3701
3702 2020-03-24 Tom de Vries <tdevries@suse.de>
3703
3704 * psymtab.c (maintenance_info_psymtabs): Print user field.
3705
3706 2020-03-20 Tom Tromey <tromey@adacore.com>
3707
3708 * dwarf2/loc.h (dwarf2_evaluate_property): Make "addr_stack"
3709 const.
3710 * dwarf2/loc.c (dwarf2_evaluate_property): Make "addr_stack"
3711 const.
3712
3713 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
3714
3715 * ptrace.m4: Don't check for ptrace declaration.
3716 * config.in: Re-generate.
3717 * configure: Re-generate.
3718 * nat/gdb_ptrace.h: Don't declare ptrace if HAVE_DECL_PTRACE is
3719 not defined.
3720
3721 2020-03-20 Kamil Rytarowski <n54@gmx.com>
3722
3723 * amd64-bsd-nat.c (gdb_ptrace): Change return type from `int' to
3724 `PTRACE_TYPE_RET'.
3725 * i386-bsd-nat.c (gdb_ptrace): Likewise.
3726 * sparc-nat.c (gdb_ptrace): Likewise.
3727 * x86-bsd-nat.c (gdb_ptrace): Likewise.
3728
3729 2020-03-20 Tom Tromey <tromey@adacore.com>
3730
3731 * c-exp.y (lex_one_token): Fix assert.
3732
3733 2020-03-20 Tom Tromey <tromey@adacore.com>
3734
3735 * ada-tasks.c (read_atcb): Use smaller length in strncpy call.
3736 * linux-tdep.c (linux_fill_prpsinfo): Use smaller length in
3737 strncpy call.
3738
3739 2020-03-20 Tom Tromey <tromey@adacore.com>
3740
3741 * symmisc.c (maintenance_print_one_line_table): Use ui_out.
3742
3743 2020-03-20 Tom Tromey <tromey@adacore.com>
3744
3745 * ada-valprint.c (print_variant_part): Remove parameters; switch
3746 to value-based API.
3747 (print_field_values): Likewise.
3748 (ada_val_print_struct_union): Likewise.
3749 (ada_value_print_1): Update.
3750
3751 2020-03-20 Kamil Rytarowski <n54@gmx.com>
3752
3753 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): Inherit from
3754 nbsd_nat_target instead of inf_ptrace_target.
3755 * ppc-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
3756 nbsd_nat_target.
3757
3758 2020-03-20 Kamil Rytarowski <n54@gmx.com>
3759
3760 * hppa-nbsd-nat.c (fetch_registers): New variable lwp and pass
3761 it to the ptrace call.
3762 * (store_registers): Likewise.
3763
3764 2020-03-20 Kamil Rytarowski <n54@gmx.com>
3765
3766 * ppc-nbsd-nat.c (fetch_registers): New variable lwp and pass
3767 it to the ptrace call.
3768 * (store_registers): Likewise.
3769
3770 2020-03-19 Luis Machado <luis.machado@linaro.org>
3771
3772 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_set_vq): If vg is not
3773 valid, fetch vg value from ptrace.
3774
3775 2020-03-19 Kamil Rytarowski <n54@gmx.com>
3776 * inf-ptrace.h: Disable get_ptrace_pid on NetBSD.
3777 * inf-ptrace.c: Likewise.
3778 * (gdb_ptrace): Add.
3779 * (inf_ptrace_target::resume): Update.
3780 * (inf_ptrace_target::xfer_partial): Likewise.
3781 * (inf_ptrace_peek_poke): Change argument `pid' to `ptid'.
3782 * (inf_ptrace_peek_poke): Update.
3783
3784 2020-03-19 Kamil Rytarowski <n54@gmx.com>
3785
3786 * x86-bsd-nat.c (gdb_ptrace): New.
3787 * (x86bsd_dr_set): Add new argument `ptid'.
3788 * (x86bsd_dr_get, x86bsd_dr_set, x86bsd_dr_set_control,
3789 x86bsd_dr_set_addr): Update.
3790
3791 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
3792
3793 * remote.c (remote_target::process_stop_reply): Handle events for
3794 all threads differently.
3795
3796 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
3797
3798 * completer.c (completion_tracker::remove_completion): Define new
3799 function.
3800 * completer.h (completion_tracker::remove_completion): Declare new
3801 function.
3802 * symtab.c (completion_list_add_symbol): Remove aliasing msymbols
3803 when adding a C++ function symbol.
3804
3805 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
3806
3807 * completer.c (completion_tracker::completion_hash_entry): Define
3808 new class.
3809 (advance_to_filename_complete_word_point): Call
3810 recompute_lowest_common_denominator.
3811 (completion_tracker::completion_tracker): Call discard_completions
3812 to setup the hash table.
3813 (completion_tracker::discard_completions): Allow for being called
3814 from the constructor, pass new equal function, and element deleter
3815 when constructing the hash table. Initialise new class member
3816 variables.
3817 (completion_tracker::maybe_add_completion): Remove use of
3818 m_entries_vec, and store more information into m_entries_hash.
3819 (completion_tracker::recompute_lcd_visitor): New function, most
3820 content taken from...
3821 (completion_tracker::recompute_lowest_common_denominator):
3822 ...here, this now just visits each item in the hash calling the
3823 above visitor.
3824 (completion_tracker::build_completion_result): Remove use of
3825 m_entries_vec, call recompute_lowest_common_denominator.
3826 * completer.h (completion_tracker::have_completions): Remove use
3827 of m_entries_vec.
3828 (completion_tracker::completion_hash_entry): Declare new class.
3829 (completion_tracker::recompute_lowest_common_denominator): Change
3830 function signature.
3831 (completion_tracker::recompute_lcd_visitor): Declare new function.
3832 (completion_tracker::m_entries_vec): Delete.
3833 (completion_tracker::m_entries_hash): Initialize to NULL.
3834 (completion_tracker::m_lowest_common_denominator_valid): New
3835 member variable.
3836 (completion_tracker::m_lowest_common_denominator_max_length): New
3837 member variable.
3838
3839 2020-03-17 Kamil Rytarowski <n54@gmx.com>
3840
3841 * regformats/regdef.h: Put reg in gdb namespace.
3842
3843 2020-03-17 Kamil Rytarowski <n54@gmx.com>
3844
3845 * i386-bsd-nat.c (gdb_ptrace): New.
3846 * (i386bsd_fetch_inferior_registers,
3847 i386bsd_store_inferior_registers) Switch from pid_t to ptid_t.
3848 * (i386bsd_fetch_inferior_registers,
3849 i386bsd_store_inferior_registers) Use gdb_ptrace.
3850
3851 2020-03-17 Kamil Rytarowski <n54@gmx.com>
3852
3853 * amd64-bsd-nat.c (gdb_ptrace): New.
3854 * (amd64bsd_fetch_inferior_registers,
3855 amd64bsd_store_inferior_registers) Switch from pid_t to ptid_t.
3856 * (amd64bsd_fetch_inferior_registers,
3857 amd64bsd_store_inferior_registers) Use gdb_ptrace.
3858
3859 2020-03-17 Kamil Rytarowski <n54@gmx.com>
3860
3861 * user-regs.c (user_reg::read): Rename to...
3862 (user_reg::xread): ...this.
3863 * (append_user_reg): Rename argument `read' to `xread'.
3864 * (user_reg_add_builtin): Likewise.
3865 * (user_reg_add): Likewise.
3866 * (value_of_user_reg): Likewise.
3867
3868 2020-03-17 Kamil Rytarowski <n54@gmx.com>
3869
3870 * sparc-nat.c (gdb_ptrace): New.
3871 * sparc-nat.c (sparc_fetch_inferior_registers)
3872 (sparc_store_inferior_registers) Remove obsolete comment.
3873 * sparc-nat.c (sparc_fetch_inferior_registers)
3874 (sparc_store_inferior_registers) Switch from pid_t to ptid_t.
3875 * sparc-nat.c (sparc_fetch_inferior_registers)
3876 (sparc_store_inferior_registers) Use gdb_ptrace.
3877
3878 2020-03-17 Kamil Rytarowski <n54@gmx.com>
3879
3880 * sh-nbsd-nat.c (fetch_registers): New variable lwp and pass
3881 it to the ptrace call.
3882 * sh-nbsd-nat.c (store_registers): Likewise.
3883
3884 2020-03-17 Kamil Rytarowski <n54@gmx.com>
3885
3886 * sh-nbsd-nat.c (sh_nbsd_nat_target): Inherit from
3887 nbsd_nat_target instead of inf_ptrace_target.
3888 * sh-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
3889 nbsd_nat_target.
3890
3891 2020-03-17 Kamil Rytarowski <n54@gmx.com>
3892
3893 * amd64-bsd-nat.c: Include amd64-bsd-nat.h".
3894
3895 2020-03-17 Kamil Rytarowski <n54@gmx.com>
3896
3897 * nbsd-nat.c: Include <sys/types.h>, <sys/ptrace.h> and
3898 <sys/sysctl.h>.
3899 * nbsd-nat.c (nbsd_nat_target::pid_to_exec_file): Rewrite.
3900
3901 2020-03-17 Tom de Vries <tdevries@suse.de>
3902
3903 PR gdb/23710
3904 * dwarf2/read.h (struct dwarf2_per_cu_data): Add unit_type and lang
3905 fields.
3906 * dwarf2/read.c (process_psymtab_comp_unit): Initialize unit_type and lang
3907 fields.
3908 (process_imported_unit_die): Skip import of c++ CUs.
3909
3910 2020-03-16 Tom Tromey <tom@tromey.com>
3911
3912 * p-valprint.c (pascal_object_print_value): Initialize
3913 base_value.
3914
3915 2020-03-16 Anton Kolesov <anton.kolesov@synopsys.com>
3916 Shahab Vahedi <shahab@synopsys.com>
3917
3918 * Makefile.in: Add arch/arc.o
3919 * configure.tgt: Likewise.
3920 * arc-tdep.c (arc_tdesc_init): Use arc_read_description.
3921 (_initialize_arc_tdep): Don't initialize old target descriptions.
3922 (arc_read_description): New function to cache target descriptions.
3923 * arc-tdep.h (arc_read_description): Add proto type.
3924 * arch/arc.c: New file.
3925 * arch/arc.h: Likewise.
3926 * features/Makefile: Replace old target descriptions with new.
3927 * features/arc-arcompact.c: Remove.
3928 * features/arc-arcompact.xml: Likewise.
3929 * features/arc-v2.c: Likewise
3930 * features/arc-v2.xml: Likewise
3931 * features/arc/aux-arcompact.xml: New file.
3932 * features/arc/aux-v2.xml: Likewise.
3933 * features/arc/core-arcompact.xml: Likewise.
3934 * features/arc/core-v2.xml: Likewise.
3935 * features/arc/aux-arcompact.c: Generate.
3936 * features/arc/aux-v2.c: Likewise.
3937 * features/arc/core-arcompact.c: Likewise.
3938 * features/arc/core-v2.c: Likewise.
3939 * target-descriptions (maint_print_c_tdesc_cmd): Support ARC features.
3940
3941 2020-03-16 Tom Tromey <tromey@adacore.com>
3942
3943 PR gdb/25663:
3944 * dwarf2/read.c (dwarf2_name): Strip leading namespaces after
3945 putting value into bcache.
3946
3947 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
3948
3949 PR gdb/21500
3950 * amd64-windows-tdep.c (amd64_windows_init_abi): Rename
3951 to...
3952 (amd64_windows_init_abi_common): ... this. Don't set size of
3953 long type.
3954 (amd64_windows_init_abi): New function.
3955 (amd64_cygwin_init_abi): New function.
3956 (_initialize_amd64_windows_tdep): Use amd64_cygwin_init_abi for
3957 the Cygwin OS ABI.
3958 * i386-windows-tdep.c (_initialize_i386_windows_tdep): Clarify
3959 comment.
3960
3961 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
3962
3963 * windows-tdep.h (is_linked_with_cygwin_dll): New declaration.
3964 * windows-tdep.c (CYGWIN_DLL_NAME): New.
3965 (pe_import_directory_entry): New struct type.
3966 (is_linked_with_cygwin_dll): New function.
3967 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Select
3968 GDB_OSABI_CYGWIN if the BFD is linked with the Cygwin DLL.
3969 * i386-windows-tdep.c (i386_windows_osabi_sniffer): Likewise.
3970
3971 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
3972
3973 * i386-windows-tdep.c: Mass-rename "cygwin" to "windows", except
3974 i386_cygwin_core_osabi_sniffer.
3975
3976 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
3977
3978 * i386-cygwin-tdep.c: Rename to...
3979 * i386-windows-tdep.c: ... this.
3980 * Makefile.in (ALL_TARGET_OBS): Rename i386-cygwin-tdep.c to
3981 i386-windows-tdep.c.
3982 * configure.tgt: Likewise.
3983
3984 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
3985
3986 * osabi.h (enum gdb_osabi): Add GDB_OSABI_WINDOWS.
3987 * osabi.c (gdb_osabi_names): Add "Windows".
3988 * i386-cygwin-tdep.c (i386_cygwin_osabi_sniffer): Return
3989 GDB_OSABI_WINDOWS when the binary's target is "pei-i386".
3990 (i386_cygwin_core_osabi_sniffer): New function, extracted from
3991 i386_cygwin_osabi_sniffer.
3992 (_initialize_i386_cygwin_tdep): Register OS ABI
3993 GDB_OSABI_WINDOWS for i386.
3994 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Return
3995 GDB_OSABI_WINDOWS when the binary's target is "pei-x86-64".
3996 (_initialize_amd64_windows_tdep): Register OS ABI GDB_OSABI_WINDOWS
3997 for x86-64.
3998 * configure.tgt: Use GDB_OSABI_WINDOWS as the default OS ABI
3999 when the target matches '*-*-mingw*'.
4000
4001 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
4002
4003 * defs.h (enum gdb_osabi): Move to...
4004 * osabi.h (enum gdb_osabi): ... here.
4005 * gdbarch.sh: Include osabi.h in gdbarch.h.
4006 * gdbarch.h: Re-generate.
4007
4008 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
4009
4010 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): New
4011 function.
4012 (_initialize_amd64_windows_tdep): Register osabi sniffer.
4013
4014 2020-03-14 Tom Tromey <tom@tromey.com>
4015
4016 * c-typeprint.c (cp_type_print_method_args): Print "__restrict__"
4017 for C++.
4018 (c_type_print_modifier): Likewise. Add "language" parameter.
4019 (c_type_print_varspec_prefix, c_type_print_base_struct_union)
4020 (c_type_print_base_1): Update.
4021 * type-stack.h (enum type_pieces) <tp_atomic, tp_restrict>: New
4022 constants.
4023 * type-stack.c (type_stack::insert): Handle tp_atomic and
4024 tp_restrict.
4025 (type_stack::follow_type_instance_flags): Likewise.
4026 (type_stack::follow_types): Likewise. Merge type-following code.
4027 * c-exp.y (RESTRICT, ATOMIC): New tokens.
4028 (space_identifier, cv_with_space_id)
4029 (const_or_volatile_or_space_identifier_noopt)
4030 (const_or_volatile_or_space_identifier): Remove.
4031 (single_qualifier, qualifier_seq_noopt, qualifier_seq): New
4032 rules.
4033 (ptr_operator, typebase): Update.
4034 (enum token_flag) <FLAG_C>: New constant.
4035 (ident_tokens): Add "restrict", "__restrict__", "__restrict", and
4036 "_Atomic".
4037 (lex_one_token): Handle FLAG_C.
4038
4039 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4040
4041 * m68k-bsd-nat.c (fetch_registers): New variable lwp and pass
4042 it to the ptrace call.
4043 * m68k-bsd-nat.c (store_registers): Likewise.
4044
4045 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4046
4047 * m68k-bsd-nat.c (m68kbsd_supply_gregset): Change type of regs to
4048 gdb_byte *.
4049 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
4050 * m68k-bsd-nat.c (m68kbsd_collect_gregset): Likewise.
4051 * m68k-bsd-nat.c (m68kbsd_supply_pcb): Cast &tmp to gdb_byte *.
4052
4053 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4054
4055 * m68k-bsd-nat.c (m68k_bsd_nat_target): Inherit from
4056 nbsd_nat_target instead of inf_ptrace_target.
4057 * m68k-bsd-nat.c: Include "nbsd-nat.h", as we are now using
4058 nbsd_nat_target.
4059
4060 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4061
4062 * m68k-bsd-nat.c: Define _KERNTYPES to get the declaration of
4063 register_t.
4064
4065 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4066
4067 * alpha-bsd-nat.c (fetch_registers): New variable lwp and pass
4068 it to the ptrace call.
4069 * alpha-bsd-nat.c (store_registers): Likewise.
4070
4071 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4072
4073 * alpha-bsd-nat.c: Remove <sys/procfs.h> and "gregset.h" from
4074 includes.
4075 * alpha-bsd-nat.c (gregset_t, fpregset_t): Remove.
4076 * alpha-bsd-nat.c (supply_gregset, fill_gregset, supply_fpregset,
4077 fill_fpregset): Likewise.
4078
4079 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4080
4081 * alpha-bsd-nat.c (alpha_netbsd_nat_target): Inherit from
4082 nbsd_nat_target instead of inf_ptrace_target.
4083 * alpha-bsd-nat.c: Include "nbsd-nat.h", as we are now using
4084 nbsd_nat_target.
4085
4086 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4087
4088 * alpha-bsd-nat.c: Define _KERNTYPES to get the declaration of
4089 register_t.
4090
4091 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4092
4093 * arm-nbsd-nat.c (fetch_register): New variable lwp and pass
4094 it to the ptrace call.
4095 * arm-nbsd-nat.c (fetch_fp_register): Likewise.
4096 * arm-nbsd-nat.c (fetch_fp_regs): Likewise.
4097 * arm-nbsd-nat.c (store_register): Likewise.
4098 * arm-nbsd-nat.c (store_regs): Likewise.
4099 * arm-nbsd-nat.c (store_fp_register): Likewise.
4100 * arm-nbsd-nat.c (store_fp_regs): Likewise.
4101
4102 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4103
4104 * arm-nbsd-nat.c (arm_netbsd_nat_target): Inherit from
4105 nbsd_nat_target instead of inf_ptrace_target.
4106 * arm-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
4107 nbsd_nat_target.
4108
4109 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4110
4111 * x86-bsd-nat.c (x86bsd_dr_get): New variable lwp and pass
4112 it to the ptrace call.
4113 * x86-bsd-nat.c (x86bsd_dr_set): Likewise.
4114
4115 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4116
4117 * vax-bsd-nat.c (vaxbsd_supply_gregset): New variable lwp and pass
4118 it to the ptrace call.
4119 * vax-bsd-nat.c (vaxbsd_collect_gregset): Likewise.
4120
4121 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4122
4123 * vax-bsd-nat.c (vaxbsd_supply_gregset): Cast gregs to const
4124 gdb_byte *.
4125 * vax-bsd-nat.c (vaxbsd_collect_gregset): Cast gregs to void *.
4126
4127 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4128
4129 * vax-bsd-nat.c (vax_bsd_nat_target): Inherit from nbsd_nat_target
4130 instead of inf_ptrace_target.
4131 * vax-bsd-nat.c: Include "nbsd-nat.h", as we are now using
4132 nbsd_nat_target.
4133
4134 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4135
4136 * mips-nbsd-nat.c: Define _KERNTYPES to get the declaration of
4137 register_t.
4138
4139 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4140
4141 * ppc-nbsd-nat.c: Define _KERNTYPES to get the declaration of
4142 register_t.
4143
4144 2020-03-14 Kamil Rytarowski <n54@gmx.com>
4145
4146 * vax-bsd-nat.c: Define _KERNTYPES to get the declaration of
4147 register_t.
4148
4149 2020-03-13 Tom Tromey <tom@tromey.com>
4150
4151 * value.h (val_print): Don't declare.
4152 * valprint.h (val_print_array_elements)
4153 (val_print_scalar_formatted, generic_val_print): Don't declare.
4154 * valprint.c (generic_val_print_array): Take a struct value.
4155 (generic_val_print_ptr, generic_val_print_memberptr)
4156 (generic_val_print_bool, generic_val_print_int)
4157 (generic_val_print_char, generic_val_print_complex)
4158 (generic_val_print): Remove.
4159 (generic_value_print): Update.
4160 (do_val_print): Remove unused parameters. Don't call
4161 la_val_print.
4162 (val_print): Remove.
4163 (common_val_print): Update. Don't call value_check_printable.
4164 (val_print_scalar_formatted, val_print_array_elements): Remove.
4165 * rust-lang.c (rust_val_print): Remove.
4166 (rust_language_defn): Update.
4167 * p-valprint.c (pascal_val_print): Remove.
4168 (pascal_value_print_inner): Update.
4169 (pascal_object_print_val_fields, pascal_object_print_val):
4170 Remove.
4171 (pascal_object_print_static_field): Update.
4172 * p-lang.h (pascal_val_print): Don't declare.
4173 * p-lang.c (pascal_language_defn): Update.
4174 * opencl-lang.c (opencl_language_defn): Update.
4175 * objc-lang.c (objc_language_defn): Update.
4176 * m2-valprint.c (m2_print_unbounded_array, m2_val_print): Remove.
4177 * m2-lang.h (m2_val_print): Don't declare.
4178 * m2-lang.c (m2_language_defn): Update.
4179 * language.h (struct language_defn) <la_val_print>: Remove.
4180 * language.c (unk_lang_value_print_inner): Rename. Change
4181 argument types.
4182 (unknown_language_defn, auto_language_defn): Update.
4183 * go-valprint.c (go_val_print): Remove.
4184 * go-lang.h (go_val_print): Don't declare.
4185 * go-lang.c (go_language_defn): Update.
4186 * f-valprint.c (f_val_print): Remove.
4187 * f-lang.h (f_value_print): Don't declare.
4188 * f-lang.c (f_language_defn): Update.
4189 * d-valprint.c (d_val_print): Remove.
4190 * d-lang.h (d_value_print): Don't declare.
4191 * d-lang.c (d_language_defn): Update.
4192 * cp-valprint.c (cp_print_value_fields)
4193 (cp_print_value_fields_rtti, cp_print_value): Remove.
4194 (cp_print_static_field): Update.
4195 * c-valprint.c (c_val_print_array, c_val_print_ptr)
4196 (c_val_print_struct, c_val_print_union, c_val_print_int)
4197 (c_val_print_memberptr, c_val_print): Remove.
4198 * c-lang.h (c_val_print_array, cp_print_value_fields)
4199 (cp_print_value_fields_rtti): Don't declare.
4200 * c-lang.c (c_language_defn, cplus_language_defn)
4201 (asm_language_defn, minimal_language_defn): Update.
4202 * ada-valprint.c (ada_val_print_ptr, ada_val_print_num): Remove.
4203 (ada_val_print_enum): Take a struct value.
4204 (ada_val_print_flt, ada_val_print_array, ada_val_print_1)
4205 (ada_val_print): Remove.
4206 (ada_value_print_1): Update.
4207 (printable_val_type): Remove.
4208 * ada-lang.h (ada_val_print): Don't declare.
4209 * ada-lang.c (ada_language_defn): Update.
4210
4211 2020-03-13 Tom Tromey <tom@tromey.com>
4212
4213 * valprint.c (do_val_print): Update.
4214 * python/python-internal.h (gdbpy_apply_val_pretty_printer): Take
4215 a struct value.
4216 (value_to_value_object_no_release): Declare.
4217 * python/py-value.c (value_to_value_object_no_release): New
4218 function.
4219 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Take a
4220 struct value.
4221 * guile/scm-value.c (vlscm_scm_from_value_no_release): New
4222 function.
4223 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer): Take
4224 a struct value.
4225 * guile/guile-internal.h (vlscm_scm_from_value_no_release):
4226 Declare.
4227 (gdbscm_apply_val_pretty_printer): Take a struct value.
4228 * extension.h (apply_ext_lang_val_pretty_printer): Take a struct
4229 value.
4230 * extension.c (apply_ext_lang_val_pretty_printer): Take a struct
4231 value.
4232 * extension-priv.h (struct extension_language_ops)
4233 <apply_val_pretty_printer>: Take a struct value.
4234 * cp-valprint.c (cp_print_value): Create a struct value.
4235 (cp_print_value): Update.
4236
4237 2020-03-13 Tom Tromey <tom@tromey.com>
4238
4239 * ada-valprint.c (print_field_values): Call common_val_print.
4240
4241 2020-03-13 Tom Tromey <tom@tromey.com>
4242
4243 * ada-valprint.c (val_print_packed_array_elements): Remove
4244 bitoffset and val parameters. Call common_val_print.
4245 (ada_val_print_string): Remove offset, address, and original_value
4246 parameters.
4247 (ada_val_print_array): Update.
4248 (ada_value_print_array): New function.
4249 (ada_value_print_1): Call it.
4250
4251 2020-03-13 Tom Tromey <tom@tromey.com>
4252
4253 * ada-valprint.c (ada_value_print): Use common_val_print.
4254
4255 2020-03-13 Tom Tromey <tom@tromey.com>
4256
4257 * ada-valprint.c (ada_val_print_ref): Use common_val_print.
4258
4259 2020-03-13 Tom Tromey <tom@tromey.com>
4260
4261 * ada-valprint.c (ada_value_print_num): New function.
4262 (ada_value_print_1): Use it.
4263
4264 2020-03-13 Tom Tromey <tom@tromey.com>
4265
4266 * ada-valprint.c (ada_value_print_1) <TYPE_CODE_FLT>: Rewrite.
4267
4268 2020-03-13 Tom Tromey <tom@tromey.com>
4269
4270 * ada-valprint.c (ada_value_print_ptr): New function.
4271 (ada_value_print_1): Use it.
4272
4273 2020-03-13 Tom Tromey <tom@tromey.com>
4274
4275 * ada-valprint.c (ada_val_print_gnat_array): Take a struct value;
4276 call common_val_print.
4277 (ada_val_print_1): Update.
4278 (ada_value_print_1): New function.
4279 (ada_value_print_inner): Rewrite.
4280
4281 2020-03-13 Tom Tromey <tom@tromey.com>
4282
4283 * cp-valprint.c (cp_print_value_fields): Update.
4284 (cp_print_value): New function.
4285
4286 2020-03-13 Tom Tromey <tom@tromey.com>
4287
4288 * m2-valprint.c (m2_value_print_inner): Use
4289 cp_print_value_fields.
4290 * cp-valprint.c (cp_print_value_fields): New function.
4291 * c-valprint.c (c_value_print_struct): New function.
4292 (c_value_print_inner): Use c_value_print_struct.
4293 * c-lang.h (cp_print_value_fields): Declare.
4294
4295 2020-03-13 Tom Tromey <tom@tromey.com>
4296
4297 * c-valprint.c (c_value_print_array): New function.
4298 (c_value_print_inner): Use it.
4299
4300 2020-03-13 Tom Tromey <tom@tromey.com>
4301
4302 * c-valprint.c (c_value_print_memberptr): New function.
4303 (c_value_print_inner): Use it.
4304
4305 2020-03-13 Tom Tromey <tom@tromey.com>
4306
4307 * c-valprint.c (c_value_print_int): New function.
4308 (c_value_print_inner): Use it.
4309
4310 2020-03-13 Tom Tromey <tom@tromey.com>
4311
4312 * c-valprint.c (c_value_print_ptr): New function.
4313 (c_value_print_inner): Use it.
4314
4315 2020-03-13 Tom Tromey <tom@tromey.com>
4316
4317 * c-valprint.c (c_value_print_inner): Rewrite.
4318
4319 2020-03-13 Tom Tromey <tom@tromey.com>
4320
4321 * valprint.c (generic_value_print_complex): New function.
4322 (generic_value_print): Use it.
4323
4324 2020-03-13 Tom Tromey <tom@tromey.com>
4325
4326 * valprint.c (generic_val_print_float): Don't call
4327 val_print_scalar_formatted.
4328 (generic_val_print, generic_value_print): Update.
4329
4330 2020-03-13 Tom Tromey <tom@tromey.com>
4331
4332 * valprint.c (generic_value_print_char): New function
4333 (generic_value_print): Use it.
4334
4335 2020-03-13 Tom Tromey <tom@tromey.com>
4336
4337 * valprint.c (generic_value_print_int): New function.
4338 (generic_value_print): Use it.
4339
4340 2020-03-13 Tom Tromey <tom@tromey.com>
4341
4342 * valprint.c (generic_value_print_bool): New function.
4343 (generic_value_print): Use it.
4344
4345 2020-03-13 Tom Tromey <tom@tromey.com>
4346
4347 * valprint.c (generic_val_print_func): Simplify.
4348 (generic_val_print, generic_value_print): Update.
4349
4350 2020-03-13 Tom Tromey <tom@tromey.com>
4351
4352 * valprint.c (generic_val_print_flags): Remove.
4353 (generic_val_print, generic_value_print): Update.
4354 (val_print_type_code_flags): Add original_value parameter.
4355
4356 2020-03-13 Tom Tromey <tom@tromey.com>
4357
4358 * valprint.c (generic_val_print): Update.
4359 (generic_value_print): Update.
4360 * valprint.c (generic_val_print_enum): Don't call
4361 val_print_scalar_formatted.
4362
4363 2020-03-13 Tom Tromey <tom@tromey.com>
4364
4365 * valprint.c (generic_value_print): Call generic_value_print_ptr.
4366 * valprint.c (generic_value_print_ptr): New function.
4367
4368 2020-03-13 Tom Tromey <tom@tromey.com>
4369
4370 * valprint.c (generic_value_print): Rewrite.
4371
4372 2020-03-13 Tom Tromey <tom@tromey.com>
4373
4374 * p-valprint.c (pascal_object_print_value_fields)
4375 (pascal_object_print_value): New functions.
4376
4377 2020-03-13 Tom Tromey <tom@tromey.com>
4378
4379 * p-valprint.c (pascal_value_print_inner): Rewrite.
4380
4381 2020-03-13 Tom Tromey <tom@tromey.com>
4382
4383 * f-valprint.c (f_value_print_innner): Rewrite.
4384
4385 2020-03-13 Tom Tromey <tom@tromey.com>
4386
4387 * m2-valprint.c (m2_print_unbounded_array): New overload.
4388 (m2_print_unbounded_array): Update.
4389 (m2_print_array_contents): Take a struct value.
4390 (m2_value_print_inner): Rewrite.
4391
4392 2020-03-13 Tom Tromey <tom@tromey.com>
4393
4394 * d-valprint.c (dynamic_array_type): Call d_value_print_inner.
4395 (d_value_print_inner): New function.
4396 * d-lang.h (d_value_print_inner): Declare.
4397 * d-lang.c (d_language_defn): Use d_value_print_inner.
4398
4399 2020-03-13 Tom Tromey <tom@tromey.com>
4400
4401 * go-valprint.c (go_value_print_inner): New function.
4402 * go-lang.h (go_value_print_inner): Declare.
4403 * go-lang.c (go_language_defn): Use go_value_print_inner.
4404
4405 2020-03-13 Tom Tromey <tom@tromey.com>
4406
4407 * rust-lang.c (val_print_struct, rust_print_enum): Use the value
4408 API.
4409 (rust_val_print): Rewrite.
4410 (rust_value_print_inner): New function, from rust_val_print.
4411 (rust_language_defn): Use rust_value_print_inner.
4412
4413 2020-03-13 Tom Tromey <tom@tromey.com>
4414
4415 * ada-valprint.c (ada_value_print_inner): New function.
4416 * ada-lang.h (ada_value_print_inner): Declare.
4417 * ada-lang.c (ada_language_defn): Use ada_value_print_inner.
4418
4419 2020-03-13 Tom Tromey <tom@tromey.com>
4420
4421 * f-valprint.c (f_value_print_innner): New function.
4422 * f-lang.h (f_value_print_innner): Declare.
4423 * f-lang.c (f_language_defn): Use f_value_print_innner.
4424
4425 2020-03-13 Tom Tromey <tom@tromey.com>
4426
4427 * p-valprint.c (pascal_value_print_inner): New function.
4428 * p-lang.h (pascal_value_print_inner): Declare.
4429 * p-lang.c (pascal_language_defn): Use pascal_value_print_inner.
4430
4431 2020-03-13 Tom Tromey <tom@tromey.com>
4432
4433 * m2-valprint.c (m2_value_print_inner): New function.
4434 * m2-lang.h (m2_value_print_inner): Declare.
4435 * m2-lang.c (m2_language_defn): Use m2_value_print_inner.
4436
4437 2020-03-13 Tom Tromey <tom@tromey.com>
4438
4439 * opencl-lang.c (opencl_language_defn): Use c_value_print_inner.
4440 * objc-lang.c (objc_language_defn): Use c_value_print_inner.
4441 * c-valprint.c (c_value_print_inner): New function.
4442 * c-lang.h (c_value_print_inner): Declare.
4443 * c-lang.c (c_language_defn, cplus_language_defn)
4444 (asm_language_defn, minimal_language_defn): Use
4445 c_value_print_inner.
4446
4447 2020-03-13 Tom Tromey <tom@tromey.com>
4448
4449 * p-valprint.c (pascal_object_print_value_fields): Now static.
4450 * p-lang.h (pascal_object_print_value_fields): Don't declare.
4451
4452 2020-03-13 Tom Tromey <tom@tromey.com>
4453
4454 * c-valprint.c (c_val_print_array): Simplify.
4455
4456 2020-03-13 Tom Tromey <tom@tromey.com>
4457
4458 * valprint.c (value_print_array_elements): New function.
4459 * valprint.h (value_print_array_elements): Declare.
4460
4461 2020-03-13 Tom Tromey <tom@tromey.com>
4462
4463 * printcmd.c (print_formatted): Use value_print_scalar_formatted.
4464 * mips-tdep.c (mips_print_register): Use
4465 value_print_scalar_formatted.
4466
4467 2020-03-13 Tom Tromey <tom@tromey.com>
4468
4469 * valprint.h (value_print_scalar_formatted): Declare.
4470 * valprint.c (value_print_scalar_formatted): New function.
4471
4472 2020-03-13 Tom Tromey <tom@tromey.com>
4473
4474 * valprint.h (generic_value_print): Declare.
4475 * valprint.c (generic_value_print): New function.
4476
4477 2020-03-13 Tom Tromey <tom@tromey.com>
4478
4479 * valprint.c (do_val_print): Call la_value_print_inner, if
4480 available.
4481 * rust-lang.c (rust_language_defn): Update.
4482 * p-lang.c (pascal_language_defn): Update.
4483 * opencl-lang.c (opencl_language_defn): Update.
4484 * objc-lang.c (objc_language_defn): Update.
4485 * m2-lang.c (m2_language_defn): Update.
4486 * language.h (struct language_defn) <la_value_print_inner>: New
4487 member.
4488 * language.c (unknown_language_defn, auto_language_defn): Update.
4489 * go-lang.c (go_language_defn): Update.
4490 * f-lang.c (f_language_defn): Update.
4491 * d-lang.c (d_language_defn): Update.
4492 * c-lang.c (c_language_defn, cplus_language_defn)
4493 (asm_language_defn, minimal_language_defn): Update.
4494 * ada-lang.c (ada_language_defn): Update.
4495
4496 2020-03-13 Tom Tromey <tom@tromey.com>
4497
4498 * c-valprint.c (c_value_print): Use common_val_print.
4499
4500 2020-03-13 Tom Tromey <tom@tromey.com>
4501
4502 * cp-valprint.c (cp_print_static_field): Use common_val_print.
4503
4504 2020-03-13 Tom Tromey <tom@tromey.com>
4505
4506 * f-valprint.c (f77_print_array_1, f_val_print): Use
4507 common_val_print.
4508
4509 2020-03-13 Tom Tromey <tom@tromey.com>
4510
4511 * riscv-tdep.c (riscv_print_one_register_info): Use
4512 common_val_print.
4513
4514 2020-03-13 Tom Tromey <tom@tromey.com>
4515
4516 * mi/mi-main.c (output_register): Use common_val_print.
4517
4518 2020-03-13 Tom Tromey <tom@tromey.com>
4519
4520 * infcmd.c (default_print_one_register_info): Use
4521 common_val_print.
4522
4523 2020-03-13 Tom Tromey <tom@tromey.com>
4524
4525 * valprint.h (common_val_print_checked): Declare.
4526 * valprint.c (common_val_print_checked): New function.
4527 * stack.c (print_frame_arg): Use common_val_print_checked.
4528
4529 2020-03-13 Tom Tromey <tom@tromey.com>
4530
4531 * valprint.c (do_val_print): New function, from val_print.
4532 (val_print): Use do_val_print.
4533 (common_val_print): Use do_val_print.
4534
4535 2020-03-13 Tom Tromey <tom@tromey.com>
4536
4537 * valprint.c (value_print): Use scoped_value_mark.
4538
4539 2020-03-13 Tom de Vries <tdevries@suse.de>
4540
4541 PR symtab/25646
4542 * psymtab.c (partial_symtab::partial_symtab): Don't set
4543 globals_offset and statics_offset. Push element onto
4544 current_global_psymbols and current_static_psymbols stacks.
4545 (concat): New function.
4546 (end_psymtab_common): Set globals_offset and statics_offset. Pop
4547 element from current_global_psymbols and current_static_psymbols
4548 stacks. Concat popped elements to global_psymbols and
4549 static_symbols.
4550 (add_psymbol_to_list): Use current_global_psymbols and
4551 current_static_psymbols stacks.
4552 * psymtab.h (class psymtab_storage): Add current_global_psymbols and
4553 current_static_psymbols fields.
4554
4555 2020-03-12 Christian Biesinger <cbiesinger@google.com>
4556
4557 * corelow.c (sniff_core_bfd): Remove.
4558 (class core_target) <m_core_vec>: Remove.
4559 (core_target::core_target): Update.
4560 (core_file_fns): Remove.
4561 (deprecated_add_core_fns): Remove.
4562 (default_core_sniffer): Remove.
4563 (sniff_core_bfd): Remove.
4564 (default_check_format): Remove.
4565 (gdb_check_format): Remove.
4566 (core_target_open): Update.
4567 (core_target::get_core_register_section): Update.
4568 (get_core_registers_cb): Update.
4569 (core_target::fetch_registers): Update.
4570 * gdbcore.h (struct core_fns): Remove.
4571 (deprecated_add_core_fns): Remove.
4572 (default_core_sniffer): Remove.
4573 (default_check_format): Remove.
4574
4575 2020-03-12 Tom Tromey <tom@tromey.com>
4576
4577 * arm-tdep.c (struct arm_mapping_symbol) <value>: Now a
4578 CORE_ADDR.
4579 (struct arm_exidx_entry) <addr>: Now a CORE_ADDR.
4580
4581 2020-03-12 Tom Tromey <tom@tromey.com>
4582
4583 * remote.c (remote_target::download_tracepoint)
4584 (remote_target::enable_tracepoint)
4585 (remote_target::disable_tracepoint): Use phex, not sprintf_vma.
4586 * breakpoint.c (print_recreate_masked_watchpoint): Use phex, not
4587 sprintf_vma.
4588
4589 2020-03-12 Tom Tromey <tom@tromey.com>
4590
4591 * symfile-mem.c: Update CORE_ADDR size assert.
4592
4593 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
4594
4595 * selftest.m4: Move to gdbsupport/.
4596 * acinclude.m4: Update path to selftest.m4.
4597
4598 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
4599
4600 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Rename to...
4601 (SELFTESTS_SRCS): ... this. Add disasm-selftests.c,
4602 gdbarch-selfselftests.c and selftest-arch.c.
4603 (SUBDIR_UNITTESTS_OBS): Rename to...
4604 (SELFTESTS_OBS): ... this.
4605 (COMMON_SFILES): Remove disasm-selftests.c and
4606 gdbarch-selftests.c.
4607 * configure.ac: Don't add selftest-arch.{c,o} to
4608 CONFIG_{SRCS,OBS}.
4609 * disasm-selftests.c, gdbarch-selftests.c: Remove GDB_SELF_TEST
4610 preprocessor conditions.
4611
4612 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
4613
4614 * configure.ac: Don't source bfd/development.sh.
4615 * selftest.m4: Modify comment.
4616 * configure: Re-generate.
4617
4618 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
4619
4620 * selftest.m4 (GDB_AC_SELFTEST): Error out if $development is
4621 not "true" or "false".
4622 * configure: Re-generate.
4623
4624 2020-03-12 Christian Biesinger <cbiesinger@google.com>
4625
4626 * Makefile.in (HFILES_NO_SRCDIR): Add new arm-nbsd-tdep.h file.
4627 * arm-nbsd-nat.c (arm_supply_gregset): Moved to arm-nbsd-tdep and
4628 renamed to arm_nbsd_supply_gregset.
4629 (fetch_register): Update to call arm_nbsd_supply_gregset.
4630 (fetch_regs): Remove in favor of fetch_register with a -1 regno.
4631 (arm_netbsd_nat_target::fetch_registers): Update.
4632 (fetch_elfcore_registers): Removed.
4633 (_initialize_arm_netbsd_nat): Removed call to deprecated_add_core_fns.
4634 * arm-nbsd-tdep.c (struct arm_nbsd_reg): New struct.
4635 (arm_nbsd_supply_gregset): Moved from arm-nbsd-nat.c and updated to
4636 not require NetBSD system headers.
4637 (arm_nbsd_regset): New struct.
4638 (arm_nbsd_iterate_over_regset_sections): New function.
4639 (arm_netbsd_init_abi_common): Updated to call
4640 set_gdbarch_iterate_over_regset_sections.
4641 * arm-nbsd-tdep.h: New file.
4642
4643 2020-03-11 Kevin Buettner <kevinb@redhat.com>
4644
4645 * symtab.c (find_pc_sect_line): Add check which prevents infinite
4646 recursion.
4647
4648 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
4649
4650 * configure: Re-generate.
4651
4652 2020-03-11 Tom Tromey <tromey@adacore.com>
4653
4654 * ada-typeprint.c (print_choices): Fix comment.
4655
4656 2020-03-11 Andrew Burgess <andrew.burgess@embecosm.com>
4657
4658 * buildsyms.c (buildsym_compunit::record_line): Avoid accessing
4659 previous item in the list, when the list has no items.
4660
4661 2020-03-11 Tom de Vries <tdevries@suse.de>
4662
4663 * dwarf2/loc.c (dwarf2_evaluate_property): Handle NULL frame in
4664 PROP_LOCLIST handling code.
4665
4666 2020-03-10 Andrew Burgess <andrew.burgess@embecosm.com>
4667
4668 * buildsym-legacy.c (record_line): Pass extra parameter to
4669 record_line.
4670 * buildsym.c (buildsym_compunit::record_line): Take an extra
4671 parameter, reduce duplication in the line table, and record the
4672 is_stmt flag in the line table.
4673 * buildsym.h (buildsym_compunit::record_line): Add extra
4674 parameter.
4675 * disasm.c (do_mixed_source_and_assembly_deprecated): Ignore
4676 non-statement lines.
4677 * dwarf2/read.c (dwarf_record_line_1): Add extra parameter, pass
4678 this to the symtab builder.
4679 (dwarf_finish_line): Pass extra parameter to dwarf_record_line_1.
4680 (lnp_state_machine::record_line): Pass a suitable is_stmt flag
4681 through to dwarf_record_line_1.
4682 * infrun.c (process_event_stop_test): When stepping, don't stop at
4683 a non-statement instruction, and only refresh the step info when
4684 we land in the middle of a line's range. Also add an extra
4685 comment.
4686 * jit.c (jit_symtab_line_mapping_add_impl): Initialise is_stmt
4687 field.
4688 * record-btrace.c (btrace_find_line_range): Only record lines
4689 marked as is-statement.
4690 * stack.c (frame_show_address): Show the frame address if we are
4691 in a non-statement sal.
4692 * symmisc.c (dump_symtab_1): Print the is_stmt flag.
4693 (maintenance_print_one_line_table): Print a header for the is_stmt
4694 column, and include is_stmt information in the output.
4695 * symtab.c (find_pc_sect_line): Find lines marked as statements in
4696 preference to non-statements.
4697 (find_pcs_for_symtab_line): Prefer is-statement entries.
4698 (find_line_common): Likewise.
4699 * symtab.h (struct linetable_entry): Add is_stmt field.
4700 (struct symtab_and_line): Likewise.
4701 * xcoffread.c (arrange_linetable): Initialise is_stmt field when
4702 arranging the line table.
4703
4704 2020-03-07 Tom de Vries <tdevries@suse.de>
4705
4706 * dwarf2/read.c (read_typedef): Treat anonymous typedef as forwarder
4707 DIE.
4708
4709 2020-03-07 Tom Tromey <tom@tromey.com>
4710
4711 * valops.c (value_literal_complex): Remove obsolete comment.
4712 * gdbtypes.h (enum type_code) <TYPE_CODE_FLT>: Remove obsolete
4713 comment.
4714
4715 2020-03-06 Simon Marchi <simon.marchi@polymtl.ca>
4716
4717 * infrun.h: Forward-declare thread_info.
4718 (set_step_info): Add thread_info parameter, add doc.
4719 * infrun.c (set_step_info): Add thread_info parameter, move doc
4720 to header.
4721 * infrun.c (process_event_stop_test): Pass thread to
4722 set_step_info call.
4723 * infcmd.c (set_step_frame): Add thread_info pointer, pass it to
4724 set_step_info.
4725 (prepare_one_step): Add thread_info parameter, pass it to
4726 set_step_frame and prepare_one_step (recursive) call.
4727 (step_1): Pass thread to prepare_one_step call.
4728 (step_command_fsm::should_stop): Pass thread to
4729 prepare_one_step.
4730 (until_next_fsm): Pass thread to set_step_frame call.
4731 (finish_command): Pass thread to set_step_info call.
4732
4733 2020-03-06 Hannes Domani <ssbssa@yahoo.de>
4734
4735 * windows-tdep.c (windows_solib_create_inferior_hook):
4736 Check if inferior is running.
4737
4738 2020-03-06 Tom de Vries <tdevries@suse.de>
4739
4740 * NEWS: Fix "the the".
4741 * ctfread.c: Same.
4742
4743 2020-03-06 Tom de Vries <tdevries@suse.de>
4744
4745 * psymtab.c (psymtab_to_symtab): Don't print "done.".
4746
4747 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
4748
4749 * .dir-locals.el: Add a comment referencing the other copies of
4750 this file.
4751
4752 2020-03-05 John Baldwin <jhb@FreeBSD.org>
4753
4754 * fbsd-tdep.c (fbsd_make_corefile_notes): Use std::string for
4755 psargs.
4756
4757 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4758
4759 * .gitattributes: New file.
4760
4761 2020-03-04 Tom Tromey <tom@tromey.com>
4762
4763 * symmisc.c (print_symbol_bcache_statistics)
4764 (print_objfile_statistics): Update.
4765 * symfile.c (allocate_symtab): Use intern.
4766 * psymtab.c (partial_symtab::partial_symtab): Use intern.
4767 * objfiles.h (struct objfile_per_bfd_storage) <filename_cache,
4768 macro_cache>: Remove.
4769 <string_cache>: New member.
4770 (struct objfile) <intern>: New methods.
4771 * elfread.c (elf_symtab_read): Use intern.
4772 * dwarf2/read.c (fixup_go_packaging): Intern package name.
4773 (dwarf2_compute_name, dwarf2_physname)
4774 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2): Intern
4775 names.
4776 (guess_partial_die_structure_name): Update.
4777 (partial_die_info::fixup): Intern name.
4778 (dwarf2_canonicalize_name): Change parameter to objfile. Intern
4779 name.
4780 (dwarf2_name): Intern name. Update.
4781 * buildsym.c (buildsym_compunit::get_macro_table): Use
4782 string_cache.
4783
4784 2020-03-04 Tom Tromey <tom@tromey.com>
4785
4786 * jit.c (bfd_open_from_target_memory): Make "target" const.
4787 * corefile.c (gnutarget): Now const.
4788 * gdbcore.h (gnutarget): Now const.
4789
4790 2020-03-04 Hannes Domani <ssbssa@yahoo.de>
4791
4792 * NEWS: Mention support for WOW64 processes.
4793 * amd64-windows-nat.c (amd64_mappings): Rename and remove static.
4794 (amd64_windows_segment_register_p): Remove static.
4795 (_initialize_amd64_windows_nat): Update.
4796 * configure.nat <windows> (NATDEPFILES): Add i386-windows-nat.o.
4797 * i386-windows-nat.c (context_offset): Update.
4798 (i386_mappings): Rename and remove static.
4799 (i386_windows_segment_register_p): Remove static.
4800 (_initialize_i386_windows_nat): Update.
4801 * windows-nat.c (STATUS_WX86_BREAKPOINT): New macro.
4802 (STATUS_WX86_SINGLE_STEP): New macro.
4803 (EnumProcessModulesEx): New macro.
4804 (Wow64SuspendThread): New macro.
4805 (Wow64GetThreadContext): New macro.
4806 (Wow64SetThreadContext): New macro.
4807 (Wow64GetThreadSelectorEntry): New macro.
4808 (windows_set_context_register_offsets): Add static.
4809 (windows_set_segment_register_p): Likewise.
4810 (windows_add_thread): Adapt for WOW64 processes.
4811 (windows_fetch_one_register): Likewise.
4812 (windows_nat_target::fetch_registers): Likewise.
4813 (windows_store_one_register): Likewise.
4814 (display_selector): Likewise.
4815 (display_selectors): Likewise.
4816 (handle_exception): Likewise.
4817 (windows_continue): Likewise.
4818 (windows_nat_target::resume): Likewise.
4819 (windows_add_all_dlls): Likewise.
4820 (do_initial_windows_stuff): Likewise.
4821 (windows_nat_target::attach): Likewise.
4822 (windows_get_exec_module_filename): Likewise.
4823 (windows_nat_target::create_inferior): Likewise.
4824 (windows_xfer_siginfo): Likewise.
4825 (_initialize_loadable): Initialize Wow64SuspendThread,
4826 Wow64GetThreadContext, Wow64SetThreadContext,
4827 Wow64GetThreadSelectorEntry and EnumProcessModulesEx.
4828 * windows-nat.h (windows_set_context_register_offsets):
4829 Remove declaration.
4830 (windows_set_segment_register_p): Likewise.
4831 (i386_windows_segment_register_p): Add declaration.
4832 (amd64_windows_segment_register_p): Likewise.
4833
4834 2020-03-04 Luis Machado <luis.machado@linaro.org>
4835
4836 Revert aa66aac47b4dd38f9524ddb5546c08cc09930d37 due to regressions
4837 in "info registers" for AArch64/ARM.
4838
4839 The change caused "info registers" to not print GPR's.
4840
4841 gdb/ChangeLog:
4842
4843 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
4844
4845 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
4846 when reg->group is empty and reggroup is not.
4847
4848 2020-03-03 Tom Tromey <tromey@adacore.com>
4849
4850 * dwarf2/frame.c (struct dwarf2_frame_cache)
4851 <checked_tailcall_bottom, entry_cfa_sp_offset,
4852 entry_cfa_sp_offset_p>: Remove members.
4853 (dwarf2_frame_cache): Call dwarf2_tailcall_sniffer_first.
4854 (dwarf2_frame_prev_register): Don't call
4855 dwarf2_tailcall_sniffer_first.
4856 (dwarf2_append_unwinders): Don't append tailcall unwinder.
4857 * frame-unwind.c (add_unwinder): New fuction.
4858 (frame_unwind_init): Use it. Add tailcall unwinder.
4859
4860 2020-03-03 Andrew Burgess <andrew.burgess@embecosm.com>
4861 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
4862
4863 * f-valprint.c (f_val_print): Handle TYPE_CODE_BOOL, any non-zero
4864 value should be printed as true.
4865
4866 2020-03-03 Hannes Domani <ssbssa@yahoo.de>
4867
4868 * windows-tdep.c (windows_solib_create_inferior_hook): New function.
4869 (windows_init_abi): Set and use windows_so_ops.
4870
4871 2020-03-03 Sergio Durigan Junior <sergiodj@redhat.com>
4872
4873 * printcmd.c (print_c_string): Check also for TYPE_CODE_PTR
4874 when verifying if dealing with a convenience variable.
4875
4876 2020-03-03 Luis Machado <luis.machado@linaro.org>
4877
4878 * auxv.c (default_print_auxv_entry): Add new AUXV entries.
4879
4880 2020-03-02 Simon Marchi <simon.marchi@polymtl.ca>
4881
4882 * infrun.c (gdbarch_supports_displaced_stepping): New.
4883 (use_displaced_stepping): Break up conditions in smaller pieces.
4884 Use gdbarch_supports_displaced_stepping.
4885 (displaced_step_prepare_throw): Use
4886 gdbarch_supports_displaced_stepping.
4887
4888 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
4889
4890 * NEWS: Mention new behaviour of the history filename.
4891 * top.c (write_history_p): Add comment.
4892 (show_write_history_p): Add header comment, give a different
4893 message when history writing is on, but the history filename is
4894 empty.
4895 (history_filename): Add comment.
4896 (history_filename_empty): New function.
4897 (show_history_filename): Add header comment, give a different
4898 message when the filename is empty.
4899 (init_history): Compare history_filename against nullptr, and only
4900 read history if the filename is not empty.
4901 (set_history_filename): Add header comment, and only make
4902 non-empty filenames absolute.
4903 (init_main): Make the filename argument to 'set history filename'
4904 optional.
4905
4906 2020-03-02 Christian Biesinger <cbiesinger@google.com>
4907
4908 * arm-nbsd-nat.c (arm_supply_fparegset): Rename to...
4909 (arm_supply_vfpregset): ...this, and update to use VFP registers.
4910 (fetch_fp_register): Update.
4911 (fetch_fp_regs): Update.
4912 (store_fp_register): Update.
4913 (store_fp_regs): Update.
4914 (arm_netbsd_nat_target::read_description): New function.
4915 (fetch_elfcore_registers): Update.
4916
4917 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
4918
4919 * remote.c (remote_target::remote_parse_stop_reply): Don't use the
4920 general_thread if the stop reply is missing a thread-id.
4921 (remote_target::process_stop_reply): Use the first non-exited
4922 thread if the target didn't pass a thread-id.
4923 * infrun.c (do_target_wait): Move call to
4924 switch_to_inferior_no_thread to ....
4925 (do_target_wait_1): ... here.
4926
4927 2020-02-29 Jon Turney <jon.turney@dronecode.org.uk>
4928
4929 * debuginfod-support.c: Include defs.h first.
4930
4931 2020-02-28 Tom de Vries <tdevries@suse.de>
4932
4933 * symfile.c (set_initial_language): Use default language for lookup.
4934
4935 2020-02-28 Simon Marchi <simon.marchi@efficios.com>
4936
4937 * dwarf2/read.c (cutu_reader::init_tu_and_read_dwo_dies): Remove
4938 reader variable, pass `this` to read_cutu_die_from_dwo.
4939
4940 2020-02-27 Aaron Merey <amerey@redhat.com>
4941
4942 * source.c (open_source_file): Check for nullptr when computing
4943 srcpath.
4944
4945 2020-02-27 Tom Tromey <tromey@adacore.com>
4946
4947 * dwarf2/read.c (struct field_info) <nfields>: Now a method, not a
4948 member.
4949 (dwarf2_add_field): Don't update nfields.
4950 (dwarf2_attach_fields_to_type, process_structure_scope): Update.
4951
4952 2020-02-27 Andrew Burgess <andrew.burgess@embecosm.com>
4953
4954 * gdbtypes.c (create_array_type_with_stride): Use std::abs not
4955 abs.
4956
4957 2020-02-26 Tom Tromey <tom@tromey.com>
4958
4959 * dwarf2/read.c (struct dwarf2_include_psymtab): New.
4960 (dwarf2_create_include_psymtab): Use dwarf2_include_psymtab.
4961 (dwarf2_psymtab::expand_psymtab, dwarf2_psymtab::readin_p)
4962 (dwarf2_psymtab::get_compunit_symtab): Remove null checks for
4963 per_cu_data.
4964
4965 2020-02-26 Tom Tromey <tom@tromey.com>
4966
4967 * dwarf2/index-write.c (psym_index_map): Change type.
4968 (add_address_entry_worker, write_one_signatured_type)
4969 (recursively_count_psymbols, recursively_write_psymbols)
4970 (class debug_names, psyms_seen_size, write_gdbindex)
4971 (write_debug_names): Use partial_symtab, not dwarf2_psymtab.
4972
4973 2020-02-26 Aaron Merey <amerey@redhat.com>
4974
4975 * Makefile.in: Handle optional debuginfod support.
4976 * NEWS: Update.
4977 * README: Add --with-debuginfod summary.
4978 * config.in: Regenerate.
4979 * configure: Regenerate.
4980 * configure.ac: Handle optional debuginfod support.
4981 * debuginfod-support.c: debuginfod helper functions.
4982 * debuginfod-support.h: Ditto.
4983 * doc/gdb.texinfo: Add --with-debuginfod to configure options
4984 summary.
4985 * dwarf2/read.c (dwarf2_get_dwz_file): Query debuginfod servers
4986 when a dwz file cannot be found.
4987 * elfread.c (elf_symfile_read): Query debuginfod servers when a
4988 debuginfo file cannot be found.
4989 * source.c (open_source_file): Query debuginfod servers when a
4990 source file cannot be found.
4991 * top.c (print_gdb_configuration): Include
4992 --{with,without}-debuginfod in the output.
4993
4994 2020-02-26 Jérémie Galarneau <jeremie.galarneau@efficios.com>
4995
4996 * thread.c (thr_try_catch_cmd): Print thread name.
4997
4998 2020-02-26 Simon Marchi <simon.marchi@efficios.com>
4999
5000 * dwarf2/loc.h (dwarf2_fetch_die_loc_sect_off,
5001 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
5002 dwarf2_fetch_die_type_sect_off): Move to...
5003 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
5004 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
5005 dwarf2_fetch_die_type_sect_off): ... here.
5006 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
5007 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
5008 dwarf2_fetch_die_type_sect_off): Move doc to header file.
5009
5010 2020-02-26 Tom de Vries <tdevries@suse.de>
5011
5012 PR gdb/25603
5013 * symfile.c (set_initial_language): Exit-early if
5014 language_mode == language_mode_manual.
5015
5016 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
5017
5018 * dwarf2/loc.h (dwarf2_read_addr_index): Move...
5019 * dwarf2/read.h (dwarf2_read_addr_index): ... here.
5020 * dwarf2/read.c (dwarf2_read_addr_index): Move doc to header.
5021
5022 2020-02-25 Andrew Burgess <andrew.burgess@embecosm.com>
5023
5024 * gdbtypes.c (create_array_type_with_stride): Handle negative
5025 array strides.
5026 * valarith.c (value_subscripted_rvalue): Likewise.
5027
5028 2020-02-25 Luis Machado <luis.machado@linaro.org>
5029
5030 * aarch64-tdep.c (aarch64_vnv_type): Fix comment typo.
5031
5032 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
5033
5034 * loc.h (dwarf2_get_die_type): Move to...
5035 * read.h (dwarf2_get_die_type): ... here.
5036 * read.c (dwarf2_get_die_type): Move doc to header.
5037
5038 2020-02-25 Joel Brobecker <brobecker@adacore.com>
5039
5040 * copypright.py (EXCLUDE_LIST): Add 'gnulib/config.in' and
5041 'gnulib/Makefile.in' to the list.
5042
5043 2020-02-24 Tom Tromey <tom@tromey.com>
5044
5045 * dwarf2/read.h (struct type_unit_unshareable) <num_symtabs>:
5046 Remove.
5047 * dwarf2/read.c (dwarf2_cu::setup_type_unit_groups): Use
5048 XOBNEWVEC.
5049
5050 2020-02-24 Tom Tromey <tom@tromey.com>
5051
5052 * dwarf2/read.h (struct dwarf2_per_cu_data) <type_unit_group_p>:
5053 New method.
5054 * dwarf2/read.c (IS_TYPE_UNIT_GROUP): Remove.
5055 (dw2_do_instantiate_symtab, dw2_get_file_names)
5056 (build_type_psymtab_dependencies, load_full_type_unit): Update.
5057
5058 2020-02-24 Tom Tromey <tom@tromey.com>
5059
5060 * dwarf2read.c (dwarf2_build_psymtabs_hard): Use
5061 make_scoped_restore.
5062 (dwarf2_psymtab::read_symtab): Don't clear
5063 reading_partial_symbols.
5064
5065 2020-02-24 Tom de Vries <tdevries@suse.de>
5066
5067 PR gdb/25592
5068 * stack.c (iterate_over_block_locals): Handle LOC_CONST.
5069
5070 2020-02-24 Tom de Vries <tdevries@suse.de>
5071
5072 * tui/tui-layout.c (_initialize_tui_layout): Fix help messages for
5073 commands layout next/prev/regs.
5074
5075 2020-02-22 Tom Tromey <tom@tromey.com>
5076
5077 * dwarf2/loc.h (dwarf2_compile_expr_to_ax): Don't declare.
5078 * dwarf2/loc.c (dwarf2_compile_expr_to_ax): Now static.
5079
5080 2020-02-22 Tom Tromey <tom@tromey.com>
5081
5082 * tui/tui-data.h (TUI_DISASM_WIN): Cast to tui_disasm_window.
5083
5084 2020-02-22 Tom Tromey <tom@tromey.com>
5085
5086 * tui/tui-win.c (_initialize_tui_win): Add usage text.
5087 * tui/tui-stack.c (_initialize_tui_stack): Add usage text.
5088 * tui/tui-regs.c (_initialize_tui_regs): Add usage text.
5089 * tui/tui.c (_initialize_tui): Add usage text.
5090
5091 2020-02-22 Tom Tromey <tom@tromey.com>
5092
5093 * tui/tui-win.c (tui_set_focus_command)
5094 (tui_set_win_height_command): Use error_no_arg.
5095 (_initialize_tui_win): Update help text.
5096 (FOCUS_USAGE, WIN_HEIGHT_USAGE): Don't define.
5097
5098 2020-02-22 Tom Tromey <tom@tromey.com>
5099
5100 * tui/tui-layout.c (extract_display_start_addr): Rewrite.
5101 * tui/tui-disasm.h (struct tui_disasm_window)
5102 <display_start_addr>: Declare.
5103 * tui/tui-source.h (struct tui_source_window)
5104 <display_start_addr>: Declare.
5105 * tui/tui-winsource.h (struct tui_source_window_base)
5106 <show_source_line, display_start_addr>: New methods.
5107 <m_horizontal_offset, m_start_line_or_addr, m_gdbarch, m_content>:
5108 Rename and move to protected section.
5109 * tui/tui-winsource.c (tui_source_window_base::update_source_window)
5110 (tui_source_window_base::do_erase_source_content): Update.
5111 (tui_source_window_base::show_source_line): Now a method.
5112 (tui_source_window_base::show_source_content)
5113 (tui_source_window_base::tui_source_window_base)
5114 (tui_source_window_base::rerender)
5115 (tui_source_window_base::refill)
5116 (tui_source_window_base::do_scroll_horizontal)
5117 (tui_source_window_base::set_is_exec_point_at)
5118 (tui_source_window_base::update_breakpoint_info)
5119 (tui_source_window_base::update_exec_info): Update.
5120 * tui/tui-source.c (tui_source_window::set_contents)
5121 (tui_source_window::showing_source_p)
5122 (tui_source_window::do_scroll_vertical)
5123 (tui_source_window::location_matches_p)
5124 (tui_source_window::line_is_displayed): Update.
5125 (tui_source_window::display_start_addr): New method.
5126 * tui/tui-disasm.c (tui_disasm_window::set_contents)
5127 (tui_disasm_window::do_scroll_vertical)
5128 (tui_disasm_window::location_matches_p): Update.
5129 (tui_disasm_window::display_start_addr): New method.
5130
5131 2020-02-22 Tom Tromey <tom@tromey.com>
5132
5133 * NEWS: Add entry for gdb.register_window_type.
5134 * tui/tui-layout.h (window_factory): New typedef.
5135 (tui_register_window): Declare.
5136 * tui/tui-layout.c (saved_tui_windows): New global.
5137 (tui_apply_current_layout): Use it.
5138 (tui_register_window): New function.
5139 * python/python.c (do_start_initialization): Call
5140 gdbpy_initialize_tui.
5141 (python_GdbMethods): Add "register_window_type" function.
5142 * python/python-internal.h (gdbpy_register_tui_window)
5143 (gdbpy_initialize_tui): Declare.
5144 * python/py-tui.c: New file.
5145 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-tui.c.
5146
5147 2020-02-22 Tom Tromey <tom@tromey.com>
5148
5149 * tui/tui-io.c (do_tui_putc): Don't omit annotations.
5150
5151 2020-02-22 Tom Tromey <tom@tromey.com>
5152
5153 * tui/tui-win.c (tui_set_win_focus_to): Move to tui-data.c.
5154 * tui/tui-data.h (tui_set_win_with_focus): Don't declare.
5155 * tui/tui-data.c (tui_set_win_with_focus): Remove.
5156 (tui_set_win_focus_to): Move from tui-win.c.
5157
5158 2020-02-22 Tom Tromey <tom@tromey.com>
5159
5160 * tui/tui-layout.c (make_standard_window, get_locator_window): New
5161 functions.
5162 (known_window_types): New global.
5163 (tui_get_window_by_name): Reimplement.
5164 (initialize_known_windows): New function.
5165 (validate_window_name): Rewrite.
5166 (_initialize_tui_layout): Call initialize_known_windows.
5167
5168 2020-02-22 Tom Tromey <tom@tromey.com>
5169
5170 * tui/tui.h (enum tui_win_type) <LOCATOR_WIN, DATA_ITEM_WIN>:
5171 Remove constants.
5172 * tui/tui-winsource.h (struct tui_source_window_base)
5173 <tui_source_window_base>: Remove parameter.
5174 * tui/tui-winsource.c
5175 (tui_source_window_base::tui_source_window_base): Remove
5176 parameter.
5177 (tui_source_window_base::refill): Update.
5178 * tui/tui-stack.h (struct tui_locator_window)
5179 <tui_locator_window>: Update.
5180 * tui/tui-source.h (struct tui_source_window) <tui_source_window>:
5181 Default the constructor.
5182 * tui/tui-regs.h (struct tui_data_item_window)
5183 <tui_data_item_window>: Default the constructor.
5184 (struct tui_data_window) <tui_data_window>: Likewise.
5185 * tui/tui-disasm.h (struct tui_disasm_window) <tui_disasm_window>:
5186 Default the constructor.
5187 * tui/tui-data.h (struct tui_gen_win_info) <tui_gen_win_info>:
5188 Default the constructor.
5189 <type>: Remove.
5190 (struct tui_win_info) <tui_win_info>: Default the constructor.
5191 * tui/tui-data.c (tui_win_info::tui_win_info): Remove.
5192 * tui/tui-command.h (struct tui_cmd_window) <tui_cmd_window>:
5193 Default the constructor.
5194
5195 2020-02-22 Tom Tromey <tom@tromey.com>
5196
5197 * tui/tui-wingeneral.h (tui_make_all_invisible): Don't declare.
5198 * tui/tui-wingeneral.c (tui_make_all_invisible): Remove.
5199 * tui/tui-win.c (tui_resize_all): Don't call
5200 tui_delete_invisible_windows.
5201 * tui/tui-layout.c (tui_apply_current_layout): Delete windows when
5202 done.
5203 (tui_set_layout): Update.
5204 (tui_add_win_to_layout): Don't call tui_delete_invisible_windows.
5205 * tui/tui-data.h (tui_delete_invisible_windows): Don't declare.
5206 * tui/tui-data.c (tui_delete_invisible_windows): Remove.
5207
5208 2020-02-22 Tom Tromey <tom@tromey.com>
5209
5210 * tui/tui-win.c (tui_partial_win_by_name): Handle ambiguity
5211 correctly.
5212
5213 2020-02-22 Tom Tromey <tom@tromey.com>
5214
5215 * tui/tui-data.c (tui_next_win, tui_prev_win): Reimplement.
5216
5217 2020-02-22 Tom Tromey <tom@tromey.com>
5218
5219 * tui/tui-winsource.h (struct tui_source_window_iterator)
5220 <inner_iterator>: New etytypedef.
5221 <tui_source_window_iterator>: Take "end" parameter.
5222 <tui_source_window_iterator>: Take iterator.
5223 <operator*, advance>: Update.
5224 <m_iter>: Change type.
5225 <m_end>: New field.
5226 (struct tui_source_windows) <begin, end>: Update.
5227 * tui/tui-layout.c (tui_windows): New global.
5228 (tui_apply_current_layout): Clear tui_windows.
5229 (tui_layout_window::apply): Update tui_windows.
5230 * tui/tui-data.h (tui_windows): Declare.
5231 (all_tui_windows): Now inline function.
5232 (class tui_window_iterator, struct all_tui_windows): Remove.
5233
5234 2020-02-22 Tom Tromey <tom@tromey.com>
5235
5236 PR tui/17850:
5237 * tui/tui-win.c (tui_gen_win_info::max_width): New method.
5238 * tui/tui-layout.h (class tui_layout_base) <get_sizes>: Add
5239 "height" argument.
5240 (class tui_layout_window) <get_sizes>: Likewise.
5241 (class tui_layout_split) <tui_layout_split>: Add "vertical"
5242 argument.
5243 <get_sizes>: Add "height" argument.
5244 <m_vertical>: New field.
5245 * tui/tui-layout.c (tui_layout_split::clone): Update.
5246 (tui_layout_split::get_sizes): Add "height" argument.
5247 (tui_layout_split::adjust_size, tui_layout_split::apply): Update.
5248 (tui_new_layout_command): Parse "-horizontal".
5249 (_initialize_tui_layout): Update help string.
5250 (tui_layout_split::specification): Add "-horizontal" when needed.
5251 * tui/tui-layout.c (tui_layout_window::get_sizes): Add "height"
5252 argument.
5253 * tui/tui-data.h (struct tui_gen_win_info) <max_width, min_width>:
5254 New methods.
5255
5256 2020-02-22 Tom Tromey <tom@tromey.com>
5257
5258 * tui/tui-layout.h (enum tui_adjust_result): New.
5259 (class tui_layout_base) <adjust_size>: Return tui_adjust_result.
5260 (class tui_layout_window) <adjust_size>: Return
5261 tui_adjust_result. Rewrite.
5262 (class tui_layout_split) <adjust_size>: Return tui_adjust_result.
5263 * tui/tui-layout.c (tui_layout_split::adjust_size): Update.
5264
5265 2020-02-22 Tom Tromey <tom@tromey.com>
5266
5267 * tui/tui-layout.h (class tui_layout_split) <add_split>: Change
5268 parameter and return types.
5269 (class tui_layout_base) <specification>: Add "depth".
5270 (class tui_layout_window) <specification>: Add "depth".
5271 (class tui_layout_split) <specification>: Add "depth".
5272 * tui/tui-layout.c (tui_layout_split::add_split): Change parameter
5273 and return types.
5274 (tui_new_layout_command): Parse sub-layouts.
5275 (_initialize_tui_layout): Update help string.
5276 (tui_layout_window::specification): Add "depth".
5277 (add_layout_command): Update.
5278
5279 2020-02-22 Tom Tromey <tom@tromey.com>
5280
5281 * NEWS: Add "tui new-layout" item.
5282 * tui/tui-layout.c (add_layout_command): Return cmd_list_element.
5283 Add new-layout command to help text.
5284 (validate_window_name): New function.
5285 (tui_new_layout_command): New function.
5286 (_initialize_tui_layout): Register "new-layout".
5287 (tui_layout_window::specification): New method.
5288 (tui_layout_window::specification): New method.
5289 * tui/tui-layout.h (class tui_layout_base) <specification>: New
5290 method.
5291 (class tui_layout_window) <specification>: New method.
5292 (class tui_layout_split) <specification>: New method.
5293
5294 2020-02-22 Tom Tromey <tom@tromey.com>
5295
5296 * tui/tui.c (tui_enable): Call tui_set_initial_layout.
5297 * tui/tui-win.c (window_name_completer): Update comment.
5298 * tui/tui-layout.h (class tui_layout_base) <replace_window>:
5299 Declare method.
5300 (class tui_layout_window) <replace_window>: Likewise.
5301 (class tui_layout_split) <replace_window>: Likewise.
5302 (tui_set_layout): Don't declare.
5303 (tui_set_initial_layout): Declare function.
5304 * tui/tui-layout.c (layouts, applied_skeleton, src_regs_layout)
5305 (asm_regs_layout): New globals.
5306 (tui_current_layout, show_layout): Remove.
5307 (tui_set_layout, tui_add_win_to_layout): Rewrite.
5308 (find_layout, tui_apply_layout): New function.
5309 (layout_completer): Remove.
5310 (tui_next_layout): Reimplement.
5311 (tui_next_layout_command): New function.
5312 (tui_set_initial_layout, tui_prev_layout_command): New functions.
5313 (tui_regs_layout): Reimplement.
5314 (tui_regs_layout_command): New function.
5315 (extract_display_start_addr): Rewrite.
5316 (next_layout, prev_layout): Remove.
5317 (tui_layout_window::replace_window): New method.
5318 (tui_layout_split::replace_window): New method.
5319 (destroy_layout): New function.
5320 (layout_list): New global.
5321 (add_layout_command): New function.
5322 (initialize_layouts): Update.
5323 (tui_layout_command): New function.
5324 (_initialize_tui_layout): Install "layout" commands.
5325 * tui/tui-data.h (enum tui_layout_type): Remove.
5326 (tui_current_layout): Don't declare.
5327
5328 2020-02-22 Tom Tromey <tom@tromey.com>
5329
5330 * tui/tui-regs.c (tui_reg_layout): Remove.
5331 (tui_reg_command): Use tui_regs_layout.
5332 * tui/tui-layout.h (tui_reg_command): Declare.
5333 * tui/tui-layout.c (tui_reg_command): New function.
5334
5335 2020-02-22 Tom Tromey <tom@tromey.com>
5336
5337 * tui/tui.c (tui_rl_delete_other_windows): Call
5338 tui_remove_some_windows.
5339 * tui/tui-layout.h (class tui_layout_base) <remove_windows>:
5340 Declare method.
5341 (class tui_layout_window) <remove_windows>: New method.
5342 (class tui_layout_split) <remove_windows>: Declare.
5343 (tui_remove_some_windows): Declare.
5344 * tui/tui-layout.c (tui_remove_some_windows): New function.
5345 (tui_layout_split::remove_windows): New method.
5346
5347 2020-02-22 Tom Tromey <tom@tromey.com>
5348
5349 * tui/tui.c (tui_rl_change_windows): Call tui_next_layout.
5350 * tui/tui-layout.h (tui_next_layout): Declare.
5351 * tui/tui-layout.c (tui_next_layout): New function.
5352
5353 2020-02-22 Tom Tromey <tom@tromey.com>
5354
5355 * tui/tui-regs.c (tui_data_window::display_registers_from): Use
5356 correct coordinates.
5357
5358 2020-02-22 Tom Tromey <tom@tromey.com>
5359
5360 * tui/tui-layout.h (tui_add_win_to_layout): Add comment.
5361 * tui/tui-layout.c (tui_add_win_to_layout): Add assert. Remove
5362 DATA_WIN case.
5363
5364 2020-02-22 Tom Tromey <tom@tromey.com>
5365
5366 * tui/tui-disasm.c (tui_get_low_disassembly_address): Use
5367 TUI_DISASM_WIN, not tui_win_list.
5368
5369 2020-02-22 Tom Tromey <tom@tromey.com>
5370
5371 * valprint.c (generic_val_print_enum_1)
5372 (val_print_type_code_flags): Style member names.
5373 * rust-lang.c (val_print_struct, rust_print_enum)
5374 (rust_print_struct_def, rust_internal_print_type): Style member
5375 names.
5376 * p-valprint.c (pascal_object_print_value_fields): Style member
5377 names. Only call fprintf_symbol_filtered for static members.
5378 * m2-typeprint.c (m2_record_fields, m2_enum): Style member names.
5379 * f-valprint.c (f_val_print): Style member names.
5380 * f-typeprint.c (f_type_print_base): Style member names.
5381 * cp-valprint.c (cp_print_value_fields): Style member names. Only
5382 call fprintf_symbol_filtered for static members.
5383 (cp_print_class_member): Style member names.
5384 * c-typeprint.c (c_print_type_1, c_type_print_base_1): Style
5385 member names.
5386 * ada-valprint.c (ada_print_scalar): Style enum names.
5387 (ada_val_print_enum): Likewise.
5388 * ada-typeprint.c (print_enum_type): Style enum names.
5389
5390 2020-02-21 Tom Tromey <tom@tromey.com>
5391
5392 * psympriv.h (struct partial_symtab): Update comment.
5393
5394 2020-02-21 Tom Tromey <tromey@adacore.com>
5395
5396 * mips-tdep.h (mips_pc_is_mips16, mips_pc_is_micromips): Parameter
5397 type is CORE_ADDR.
5398
5399 2020-02-21 Tom de Vries <tdevries@suse.de>
5400
5401 PR gdb/25534
5402 * psymtab.c (partial_symtab::read_dependencies): Don't read dependency
5403 if dependencies[i]->user != NULL.
5404
5405 2020-02-21 Ali Tamur <tamur@google.com>
5406
5407 * dwarf2/read.c (dwarf2_name): Add null check.
5408
5409 2020-02-20 Tom Tromey <tom@tromey.com>
5410
5411 * dwarf2/read.c (dwarf2_find_containing_comp_unit): Use ">", not
5412 ">=", in binary search.
5413 (dwarf2_find_containing_comp_unit): New overload.
5414 (run_test): New self-test.
5415 (_initialize_dwarf2_read): Register new test.
5416
5417 2020-02-20 Nelson Chu <nelson.chu@sifive.com>
5418
5419 * riscv-tdep.c: Updated since the DECLARE_CSR is changed.
5420 * riscv-tdep.h: Likewise.
5421 * features/riscv/rebuild-csr-xml.sh: Generate the 64bit-csr.xml without
5422 rv32-only CSR.
5423 * features/riscv/64bit-csr.xml: Regenerated.
5424
5425 2020-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
5426 Tom Tromey <tom@tromey.com>
5427
5428 * utils.c (fputs_maybe_filtered): Call 'stream->puts' instead
5429 of 'fputc_unfiltered'.
5430 (putchar_unfiltered): Call 'fputc_unfiltered'.
5431 (fputc_unfiltered): Call 'fputs_unfiltered'.
5432
5433 2020-02-20 Andrew Burgess <andrew.burgess@embecosm.com>
5434
5435 * config.in: Regenerate.
5436 * configure: Regenerate.
5437 * configure.ac: Add --with-python-libdir option.
5438 * main.c: Use WITH_PYTHON_LIBDIR.
5439
5440 2020-02-19 Tom Tromey <tom@tromey.com>
5441
5442 * symtab.c (general_symbol_info::compute_and_set_names): Use
5443 obstack_strndup. Simplify call to symbol_set_demangled_name.
5444
5445 2020-02-19 Simon Marchi <simon.marchi@efficios.com>
5446
5447 * dwarf2/read.c (allocate_signatured_type_table,
5448 allocate_dwo_unit_table, allocate_type_unit_groups_table,
5449 allocate_dwo_file_hash_table, allocate_dwp_loaded_cutus_table):
5450 Remove objfile parameter, update all callers.
5451
5452 2020-02-19 Doug Evans <dje@google.com>
5453
5454 PR rust/25535
5455 * rust-lang.c (rust_print_enum): Apply embedded_offset to
5456 rust_enum_variant calculation.
5457
5458 2020-02-19 Tom Tromey <tromey@adacore.com>
5459
5460 * mips-tdep.h (mips_pc_is_mips): Parameter type is CORE_ADDR.
5461
5462 2020-02-19 Tom Tromey <tromey@adacore.com>
5463
5464 * ada-lang.c (cache_symbol): Use obstack_strdup.
5465
5466 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
5467
5468 * configure: Regenerate.
5469
5470 2020-02-19 Tom Tromey <tromey@adacore.com>
5471
5472 * python/python.c (do_start_initialization): Use XNEWVEC. Remove
5473 NULL check.
5474
5475 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
5476
5477 * NEWS: Mention RISC-V GNU/Linux GDBserver support.
5478
5479 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
5480
5481 * arch/riscv.c (struct riscv_gdbarch_features_hasher): Only define
5482 if GDBSERVER is not defined.
5483 (riscv_tdesc_cache): Likewise, also store const target_desc.
5484 (STATIC_IN_GDB): Define.
5485 (riscv_create_target_description): Update declaration with
5486 STATIC_IN_GDB.
5487 (riscv_lookup_target_description): New function, only define if
5488 GDBSERVER is not defined.
5489 * arch/riscv.h (riscv_create_target_description): Declare only
5490 when GDBSERVER is defined.
5491 (riscv_lookup_target_description): New declaration when GDBSERVER
5492 is not defined.
5493 * nat/riscv-linux-tdesc.c (riscv_linux_read_description): Rename to...
5494 (riscv_linux_read_features): ...this, and return
5495 riscv_gdbarch_features instead of target_desc.
5496 * nat/riscv-linux-tdesc.h: Include 'arch/riscv.h'.
5497 (riscv_linux_read_description): Rename to...
5498 (riscv_linux_read_features): ...this.
5499 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
5500 Update to use riscv_gdbarch_features and
5501 riscv_lookup_target_description.
5502 * riscv-tdep.c (riscv_find_default_target_description): Use
5503 riscv_lookup_target_description instead of
5504 riscv_create_target_description.
5505
5506 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
5507
5508 * valprint.c (generic_val_print_enum_1): When printing a flag
5509 enum with value 0 and there is no enumerator with value 0, print
5510 just "0" instead of "(unknown: 0x0)".
5511
5512 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
5513
5514 * valprint.c (generic_val_print_enum_1): Print unknown part of
5515 flag enum in hex.
5516
5517 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
5518
5519 * dwarf2/read.c (update_enumeration_type_from_children): Allow
5520 flag enums to contain duplicate enumerators.
5521 * valprint.c (generic_val_print_enum_1): Update comment.
5522
5523 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
5524
5525 * dwarf2/read.c: Include "count-one-bits.h".
5526 (update_enumeration_type_from_children): If an enumerator has
5527 multiple bits set, don't treat the enumeration as a "flag enum".
5528 * valprint.c (generic_val_print_enum_1): Assert that enumerators
5529 of flag enums have 0 or 1 bit set.
5530
5531 2020-02-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
5532
5533 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use an explicit
5534 conversion.
5535 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
5536 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
5537 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
5538 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
5539 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
5540
5541 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
5542
5543 * MAINTAINERS: Change palmer@sifive.com to palmer@dabbelt.com.
5544
5545 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
5546
5547 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use
5548 displaced_step_closure_up.
5549 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
5550 (struct displaced_step_closure_up):
5551 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
5552 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
5553 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn):
5554 Likewise.
5555 * gdbarch.sh (displaced_step_copy_insn): Likewise.
5556 * gdbarch.c, gdbarch.h: Re-generate.
5557 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Use
5558 displaced_step_closure_up.
5559 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
5560 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
5561 * infrun.h (displaced_step_closure_up): New type alias.
5562 (struct displaced_step_inferior_state) <step_closure>: Change
5563 type to displaced_step_closure_up.
5564 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Use
5565 displaced_step_closure_up.
5566 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
5567
5568 2020-02-14 Tom Tromey <tom@tromey.com>
5569
5570 * minidebug.c (gnu_debug_key): New global.
5571 (find_separate_debug_file_in_section): Use it.
5572
5573 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
5574
5575 * gdbarch.sh (displaced_step_copy_insn): Change return type to an
5576 std::unique_ptr.
5577 * gdbarch.c: Re-generate.
5578 * gdbarch.h: Re-generate.
5579 * infrun.c (displaced_step_prepare_throw): Adjust to std::unique_ptr
5580 change.
5581 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Change return
5582 type to std::unique_ptr.
5583 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
5584 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
5585 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
5586 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
5587 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Likewise.
5588 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
5589 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
5590 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
5591 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
5592
5593 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
5594
5595 * infrun.c (get_displaced_step_closure_by_addr): Adjust to
5596 std::unique_ptr.
5597 (displaced_step_clear): Rename to...
5598 (displaced_step_reset): ... this. Just call displaced->reset ().
5599 (displaced_step_clear_cleanup): Rename to...
5600 (displaced_step_reset_cleanup): ... this.
5601 (displaced_step_prepare_throw): Adjust to std::unique_ptr.
5602 (displaced_step_fixup): Likewise.
5603 (resume_1): Likewise.
5604 (handle_inferior_event): Restore child's memory before calling
5605 displaced_step_fixup on the parent.
5606 * infrun.h (displaced_step_inferior_state) <reset>: Adjust
5607 to std::unique_ptr.
5608 <step_closure>: Change type to std::unique_ptr.
5609
5610 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
5611
5612 * arm-tdep.c: Include count-one-bits.h.
5613 (cleanup_block_store_pc): Use count_one_bits.
5614 (cleanup_block_load_pc): Use count_one_bits.
5615 (arm_copy_block_xfer): Use count_one_bits.
5616 (thumb2_copy_block_xfer): Use count_one_bits.
5617 (thumb_copy_pop_pc_16bit): Use count_one_bits.
5618 * arch/arm-get-next-pcs.c: Include count-one-bits.h.
5619 (thumb_get_next_pcs_raw): Use count_one_bits.
5620 (arm_get_next_pcs_raw): Use count_one_bits_l.
5621 * arch/arm.c (bitcount): Remove.
5622 * arch/arm.h (bitcount): Remove.
5623
5624 2020-02-14 Tom Tromey <tromey@adacore.com>
5625
5626 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first):
5627 Update.
5628 * dwarf2/loc.h (call_site_find_chain): Return unique_xmalloc_ptr.
5629 * dwarf2/loc.c (call_site_find_chain_1): Return
5630 unique_xmalloc_ptr.
5631 (call_site_find_chain): Likewise.
5632
5633 2020-02-14 Richard Biener <rguenther@suse.de>
5634
5635 * dwarf2/read.c (lnp_state_machine::handle_special_opcode): Apply CSE
5636 on expression with division operators.
5637
5638 2020-02-13 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
5639
5640 * MAINTAINERS (Write After Approval): Adding myself.
5641
5642 2020-02-12 Tom Tromey <tom@tromey.com>
5643
5644 * event-loop.c (event_data, gdb_event, event_handler_func):
5645 Remove.
5646
5647 2020-02-12 Tom Tromey <tom@tromey.com>
5648
5649 * dwarf2/frame.c (dwarf2_frame_bfd_data): New global.
5650 (dwarf2_frame_objfile_data): Add comment.
5651 (find_comp_unit, set_comp_unit): New functions.
5652 (dwarf2_frame_find_fde): Use find_comp_unit.
5653 (dwarf2_build_frame_info): Use set_comp_unit.
5654
5655 2020-02-12 Tom Tromey <tom@tromey.com>
5656
5657 * dwarf2/frame.c (struct comp_unit) <objfile>: Remove.
5658 (comp_unit): Don't initialize objfile.
5659 (execute_cfa_program): Add text_offset parameter.
5660 (execute_cfa_program_test, dwarf2_fetch_cfa_info)
5661 (dwarf2_frame_cache): Update.
5662 (dwarf2_build_frame_info): Don't set "objfile" member.
5663
5664 2020-02-12 Tom Tromey <tom@tromey.com>
5665
5666 * dwarf2/frame.c (decode_frame_entry_1): Add gdbarch parameter.
5667 (decode_frame_entry): Likewise.
5668 (dwarf2_build_frame_info): Update.
5669
5670 2020-02-12 Tom Tromey <tom@tromey.com>
5671
5672 * dwarf2/frame.c (struct comp_unit) <obstack>: New member.
5673 (decode_frame_entry_1): Use the comp_unit obstack.
5674
5675 2020-02-12 Tom Tromey <tom@tromey.com>
5676
5677 * dwarf2/frame.c (struct comp_unit): Add initializers and
5678 constructor.
5679 (dwarf2_frame_objfile_data): Store a comp_unit.
5680 (dwarf2_frame_find_fde): Update.
5681 (dwarf2_build_frame_info): Use "new".
5682
5683 2020-02-12 Tom Tromey <tom@tromey.com>
5684
5685 * dwarf2/frame.c (struct dwarf2_fde_table): Remove.
5686 (dwarf2_fde_table): Typedef for std::vector.
5687 (dwarf2_frame_objfile_data): Remove the deleter. Now static.
5688 (dwarf2_frame_find_fde, add_fde, decode_frame_entry_1)
5689 (decode_frame_entry): Update.
5690 (dwarf2_build_frame_info): Use "new".
5691
5692 2020-02-12 Christian Biesinger <cbiesinger@google.com>
5693
5694 * arm-tdep.c (arm_gdbarch_init): Update.
5695 * arm-tdep.h (struct gdbarch_tdep) <have_fpa_registers,
5696 have_wmmx_registers, have_vfp_pseudos, have_neon_pseudos,
5697 have_neon, is_m>: Change to bool.
5698
5699 2020-02-12 Christian Biesinger <cbiesinger@google.com>
5700
5701 * arm-tdep.c (arm_dump_tdep): Print more fields of tdep.
5702
5703 2020-02-12 Tom Tromey <tom@tromey.com>
5704
5705 * dwarf2/loc.c (struct dwarf_expr_baton): Remove.
5706
5707 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
5708
5709 * windows-tdep.c (struct windows_gdbarch_data): Add tib_ptr_type.
5710 (windows_get_tlb_type): Use windows_gdbarch_data->tib_ptr_type.
5711
5712 2020-02-11 Tom Tromey <tom@tromey.com>
5713
5714 * psymtab.h: Update comment.
5715
5716 2020-02-11 Tom Tromey <tom@tromey.com>
5717
5718 * gdb_obstack.h (struct auto_obstack): Use
5719 DISABLE_COPY_AND_ASSIGN.
5720
5721 2020-02-11 Tom Tromey <tom@tromey.com>
5722
5723 * dwarf2/frame.h (struct objfile): Don't forward declare.
5724
5725 2020-02-11 Christian Biesinger <cbiesinger@google.com>
5726
5727 * cris-tdep.c (cris_supply_gregset): Change signature to match
5728 what struct regset expects.
5729 (cris_regset): New struct.
5730 (fetch_core_registers): Remove.
5731 (cris_iterate_over_regset_sections): New function.
5732 (_initialize_cris_tdep): Don't call deprecated_add_core_fns.
5733 (cris_gdbarch_init): Call set_gdbarch_iterate_over_regset_sections.
5734
5735 2020-02-11 Christian Biesinger <cbiesinger@google.com>
5736
5737 * arch/arm.h (enum gdb_regnum): Add comment for the FP0..7
5738 registers.
5739
5740 2020-02-11 Christian Biesinger <cbiesinger@google.com>
5741
5742 * arm-tdep.c (arm_dump_tdep): Add \n in fprintf.
5743
5744 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
5745
5746 * configure: Re-generate.
5747
5748 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
5749
5750 * configure: Re-generate.
5751
5752 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
5753
5754 * acinclude: Update warning.m4 path.
5755 * warning.m4: Move to gdbsupport.
5756
5757 2020-02-11 Tom Tromey <tromey@adacore.com>
5758
5759 * remote.c (remote_console_output): Update.
5760 * printcmd.c (printf_command): Update.
5761 * event-loop.c (gdb_wait_for_event): Update.
5762 * linux-nat.c (sigchld_handler): Update.
5763 * remote-sim.c (gdb_os_write_stdout): Update.
5764 (gdb_os_flush_stdout): Update.
5765 (gdb_os_flush_stderr): Update.
5766 (gdb_os_write_stderr): Update.
5767 * exceptions.c (print_exception): Update.
5768 * remote-fileio.c (remote_fileio_func_read): Update.
5769 (remote_fileio_func_write): Update.
5770 * tui/tui.c (tui_enable): Update.
5771 * tui/tui-interp.c (tui_interp::init): Update.
5772 * utils.c (init_page_info): Update.
5773 (putchar_unfiltered, fputc_unfiltered): Update.
5774 (gdb_flush): Update.
5775 (emit_style_escape): Update.
5776 (flush_wrap_buffer, fputs_maybe_filtered): Update.
5777 * ui-file.c (ui_file_isatty, ui_file_read, ui_file_write)
5778 (ui_file_write_async_safe, ui_file_flush, ui_file_puts): Remove.
5779 (stderr_file::write): Update.
5780 (stderr_file::puts): Update.
5781 * ui-file.h (ui_file_isatty, ui_file_write)
5782 (ui_file_write_async_safe, ui_file_read, ui_file_flush)
5783 (ui_file_puts): Don't declare.
5784
5785 2020-02-10 Tom de Vries <tdevries@suse.de>
5786
5787 * dwarf2/read.c (process_psymtab_comp_unit_reader): Cast concat NULL
5788 sentinel to char *.
5789
5790 2020-02-09 Tom de Vries <tdevries@suse.de>
5791
5792 * dwarf2read.c (process_psymtab_comp_unit_reader): Append CU offset to
5793 filename if it matches "<artificial>".
5794
5795 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
5796
5797 * windows-tdep.c (struct enum_value_name): New struct.
5798 (create_enum): New function.
5799 (windows_get_siginfo_type): Create and use enum types.
5800
5801 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
5802
5803 * NEWS: Mention $_siginfo support for Windows.
5804 * windows-nat.c (handle_exception): Set siginfo_er.
5805 (windows_nat_target::mourn_inferior): Reset siginfo_er.
5806 (windows_xfer_siginfo): New function.
5807 (windows_nat_target::xfer_partial): Call windows_xfer_siginfo.
5808 * windows-tdep.c (struct windows_gdbarch_data): New struct.
5809 (init_windows_gdbarch_data): New function.
5810 (get_windows_gdbarch_data): New function.
5811 (windows_get_siginfo_type): New function.
5812 (windows_init_abi): Register windows_get_siginfo_type.
5813 (_initialize_windows_tdep): Register init_windows_gdbarch_data.
5814
5815 2020-02-08 Tom Tromey <tom@tromey.com>
5816
5817 * dwarf2/read.c (class cutu_reader) <cutu_reader,
5818 init_tu_and_read_dwo_dies>: Remove "keep" parameter.
5819 <keep>: Declare method.
5820 <m_keep>: Remove member.
5821 <~cutu_reader>: Remove.
5822 (cutu_reader::init_tu_and_read_dwo_dies): Update.
5823 (cutu_reader::cutu_reader): Update.
5824 (cutu_reader::keep): Rename from ~cutu_reader.
5825 (process_psymtab_comp_unit, build_type_psymtabs_1)
5826 (process_skeletonless_type_unit, load_partial_comp_unit)
5827 (load_full_comp_unit, dwarf2_read_addr_index)
5828 (read_signatured_type): Update.
5829
5830 2020-02-08 Tom Tromey <tom@tromey.com>
5831
5832 * dwarf2/read.c (process_psymtab_comp_unit_reader): Remove
5833 "want_partial_unit" parameter.
5834 (process_psymtab_comp_unit): Change want_partial_unit to bool.
5835 Inline check for DW_TAG_partial_unit.
5836 (dwarf2_build_psymtabs_hard, scan_partial_symbols): Update.
5837
5838 2020-02-08 Tom Tromey <tom@tromey.com>
5839
5840 * dwarf2/read.c (read_n_bytes, read_direct_string): Move to
5841 read.c.
5842 * dwarf2/leb.h (read_n_bytes, read_direct_string): Move from
5843 read.c.
5844
5845 2020-02-08 Tom Tromey <tom@tromey.com>
5846
5847 * dwarf2/read.c (read_address): Move to comp-unit.c.
5848 (dwarf2_rnglists_process, dwarf2_ranges_process)
5849 (read_attribute_value, dwarf_decode_lines_1)
5850 (var_decode_location, decode_locdesc): Update.
5851 * dwarf2/comp-unit.c (comp_unit_head::read_address): Move from
5852 read.c. Remove "cu" parameter.
5853 * dwarf2/comp-unit.h (struct comp_unit_head) <read_address>: New
5854 method.
5855
5856 2020-02-08 Tom Tromey <tom@tromey.com>
5857
5858 * dwarf2/read.c (read_attribute_value, read_indirect_string)
5859 (read_indirect_line_string): Update.
5860 * dwarf2/comp-unit.c (read_offset): Remove.
5861 (read_comp_unit_head): Update.
5862 * dwarf2/comp-unit.h (struct comp_unit_head) <read_offset>: New
5863 method.
5864 (read_offset): Don't declare.
5865
5866 2020-02-08 Tom Tromey <tom@tromey.com>
5867
5868 * Makefile.in (COMMON_SFILES): Add dwarf2/comp-unit.c.
5869 * dwarf2/read.c (struct comp_unit_head): Move to
5870 dwarf2/comp-unit.h.
5871 (enum class rcuh_kind): Move to comp-unit.h.
5872 (get_cu_length, offset_in_cu_p): Now methods on comp_unit_head.
5873 (read_comp_unit_head, error_check_comp_unit_head)
5874 (read_and_check_comp_unit_head): Move to comp-unit.c.
5875 (read_offset, dwarf_unit_type_name): Likewise.
5876 (create_debug_type_hash_table, read_cutu_die_from_dwo)
5877 (cutu_reader::cutu_reader, read_call_site_scope)
5878 (find_partial_die, follow_die_offset): Update.
5879 * dwarf2/comp-unit.h: New file, from dwarf2read.c.
5880
5881 2020-02-08 Tom Tromey <tom@tromey.com>
5882
5883 * dwarf2/read.c (read_offset_1): Move to leb.c.
5884 (read_abbrev_offset, read_offset, dwarf_decode_line_header)
5885 (dwarf_decode_macro_bytes): Update.
5886 * dwarf2/leb.c (read_offset): Rename; move from read.c.
5887 * dwarf2/leb.h (read_offset): Declare.
5888
5889 2020-02-08 Tom Tromey <tom@tromey.com>
5890
5891 * dwarf2/read.c (dwarf2_section_size): Remove.
5892 (error_check_comp_unit_head, dwarf2_symbol_mark_computed):
5893 Update.
5894 * dwarf2/section.h (struct dwarf2_section_info) <get_size>: New method.
5895
5896 2020-02-08 Tom Tromey <tom@tromey.com>
5897
5898 * dwarf2/read.c (read_initial_length): Move to leb.c.
5899 * dwarf2/leb.h (read_initial_length): Declare.
5900 * dwarf2/leb.c (read_initial_length): Move from read.c. Add
5901 handle_nonstd parameter.
5902 * dwarf2/frame.c (read_initial_length): Remove.
5903 (decode_frame_entry_1): Update.
5904
5905 2020-02-08 Tom Tromey <tom@tromey.com>
5906
5907 * dwarf2/loc.c (dwarf2_find_location_expression)
5908 (dwarf_evaluate_loc_desc::get_tls_address)
5909 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
5910 (rw_pieced_value, dwarf2_evaluate_loc_desc_full)
5911 (dwarf2_locexpr_baton_eval, dwarf2_evaluate_property)
5912 (dwarf2_compile_property_to_c)
5913 (dwarf2_loc_desc_get_symbol_read_needs)
5914 (dwarf2_compile_expr_to_ax, locexpr_describe_location)
5915 (locexpr_tracepoint_var_ref, locexpr_generate_c_location)
5916 (loclist_describe_location, loclist_tracepoint_var_ref)
5917 (loclist_generate_c_location): Update.
5918 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Update.
5919 * dwarf2/loc.h (dwarf2_per_cu_objfile, dwarf2_per_cu_addr_size)
5920 (dwarf2_per_cu_ref_addr_size, dwarf2_per_cu_offset_size)
5921 (dwarf2_per_cu_text_offset, dwarf2_version): Don't declare.
5922 * dwarf2/read.c (dwarf2_per_cu_data::objfile)
5923 (dwarf2_per_cu_data::addr_size)
5924 (dwarf2_per_cu_data::ref_addr_size)
5925 (dwarf2_per_cu_data::text_offset)
5926 (dwarf2_per_cu_data::addr_type): Now methods.
5927 (per_cu_header_read_in): Make per_cu "const".
5928 (dwarf2_version): Remove.
5929 (dwarf2_per_cu_data::int_type): Now a method.
5930 (dwarf2_per_cu_data::_addr_sized_int_type): Likewise.
5931 (set_die_type, read_array_type, read_subrange_index_type)
5932 (read_tag_string_type, read_subrange_type): Update.
5933 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_size,
5934 offset_size, ref_addr_size, text_offset, addr_type, version,
5935 objfile, int_type, addr_sized_int_type>: Declare methods.
5936
5937 2020-02-08 Tom Tromey <tom@tromey.com>
5938
5939 * dwarf2/read.h (struct dwarf2_per_cu_data) <imported_symtabs>:
5940 Move earlier.
5941
5942 2020-02-08 Tom Tromey <tom@tromey.com>
5943
5944 * dwarf2/read.h (dwarf_line_debug): Declare.
5945 * Makefile.in (COMMON_SFILES): Add dwarf2/line-header.c.
5946 * dwarf2/read.c: Move line_header code to new files.
5947 (dwarf_line_debug): No longer static.
5948 * dwarf2/line-header.c: New file.
5949 * dwarf2/line-header.h: New file.
5950
5951 2020-02-08 Tom Tromey <tom@tromey.com>
5952
5953 * dwarf2/read.c (struct line_header) <file_full_name,
5954 file_file_name>: Return unique_xmalloc_ptr.
5955 (line_header::file_file_name): Update.
5956 (line_header::file_full_name): Update.
5957 (dw2_get_file_names_reader): Update.
5958 (macro_start_file): Update.
5959
5960 2020-02-08 Tom Tromey <tom@tromey.com>
5961
5962 * dwarf2/read.c (struct line_header) <file_full_name,
5963 file_file_name>: Declare methods.
5964 (dw2_get_file_names_reader): Update.
5965 (file_file_name): Now a method.
5966 (file_full_name): Likewise.
5967 (macro_start_file): Update.
5968
5969 2020-02-08 Tom Tromey <tom@tromey.com>
5970
5971 * dwarf2/read.c (dwarf_always_disassemble)
5972 (show_dwarf_always_disassemble): Move to loc.c.
5973 (_initialize_dwarf2_read): Move "always-disassemble" registration
5974 to loc.c.
5975 * dwarf2/read.h (dwarf_always_disassemble): Don't declare.
5976 * dwarf2/loc.c (dwarf_always_disassemble): Move from read.c. Now
5977 static.
5978 (show_dwarf_always_disassemble): Move from read.c.
5979 (_initialize_dwarf2loc): Move always-disassemble from read.c.
5980
5981 2020-02-08 Tom Tromey <tom@tromey.com>
5982
5983 * dwarf2/read.c (~dwarf2_per_objfile): Update.
5984 (create_quick_file_names_table): Return htab_up.
5985 (dw2_get_file_names_reader, dw2_forget_cached_source_info):
5986 Update.
5987 * dwarf2/read.h (struct dwarf2_per_objfile)
5988 <quick_file_names_table>: Now htab_up.
5989
5990 2020-02-08 Tom Tromey <tom@tromey.com>
5991
5992 * dwarf2/abbrev.c (abbrev_table::read): Simplify.
5993
5994 2020-02-08 Tom Tromey <tom@tromey.com>
5995
5996 * dwarf2/abbrev.c (abbrev_table): Move constructor from header.
5997 Rewrite.
5998 (abbrev_table::add_abbrev, abbrev_table::lookup_abbrev): Rewrite.
5999 * dwarf2/abbrev.h (struct abbrev_info) <next>: Remove.
6000 (abbrev_table::abbrev_table): No longer inline.
6001 (ABBREV_HASH_SIZE): Remove.
6002 (abbrev_table::m_abbrevs): Now an htab_up.
6003
6004 2020-02-08 Tom Tromey <tom@tromey.com>
6005
6006 * dwarf2/read.c (read_cutu_die_from_dwo): Update.
6007 (cutu_reader): Update.
6008 (build_type_psymtabs_1): Update.
6009 * dwarf2/abbrev.c (abbrev_table::read): Rename.
6010 (abbrev_table::alloc_abbrev): Update.
6011 * dwarf2/abbrev.h (abbrev_table_up): Move earlier.
6012 (abbrev_table::read): New static method, renamed from
6013 abbrev_table_read_table.
6014 (abbrev_table::alloc_abbrev)
6015 (abbrev_table::add_abbrev): Now private.
6016 (abbrev_table::abbrev_table): Now private.
6017 (abbrev_table::m_abbrev_obstack): Now private. Rename.
6018
6019 2020-02-08 Tom Tromey <tom@tromey.com>
6020
6021 * dwarf2/read.c (set_die_type, get_die_type_at_offset): Update.
6022 * dwarf2/read.h (struct dwarf2_per_objfile) <die_type_hash>: Now
6023 htab_up.
6024
6025 2020-02-08 Tom Tromey <tom@tromey.com>
6026
6027 * dwarf2/read.c (struct dwp_file) <loaded_cus, loaded_tus>: Now
6028 htab_up.
6029 (lookup_dwo_unit_in_dwp): Update.
6030 (allocate_dwp_loaded_cutus_table): Return htab_up. Don't allocate
6031 on obstack.
6032
6033 2020-02-08 Tom Tromey <tom@tromey.com>
6034
6035 * dwarf2/read.c (allocate_dwo_file_hash_table): Don't allocate on
6036 obstack.
6037
6038 2020-02-08 Tom Tromey <tom@tromey.com>
6039
6040 * dwarf2/read.c (~dwarf2_per_objfile): Don't delete
6041 line_header_hash.
6042 (handle_DW_AT_stmt_list): Update. Don't allocate on obstack.
6043 * dwarf2/read.h (struct dwarf2_per_objfile) <line_header_hash>:
6044 Change type to htab_up.
6045
6046 2020-02-08 Tom Tromey <tom@tromey.com>
6047
6048 * dwarf2/read.c (allocate_type_unit_groups_table): Return
6049 htab_up. Don't allocate on obstack.
6050 (get_type_unit_group, dwarf2_build_psymtabs_hard): Update.
6051 * dwarf2/read.h (struct dwarf2_per_objfile) <type_unit_groups>:
6052 Change type to htab_up.
6053
6054 2020-02-08 Tom Tromey <tom@tromey.com>
6055
6056 * dwarf2/read.h (struct dwarf2_per_objfile) <signatured_types>:
6057 Change type to htab_up.
6058 * dwarf2/read.c (create_signatured_type_table_from_index)
6059 (create_signatured_type_table_from_debug_names)
6060 (create_all_type_units, add_type_unit)
6061 (lookup_dwo_signatured_type, lookup_signatured_type)
6062 (process_skeletonless_type_unit): Update.
6063 (create_debug_type_hash_table, create_debug_types_hash_table):
6064 Change type of types_htab.
6065 (allocate_signatured_type_table, allocate_dwo_unit_table): Return
6066 htab_up. Don't allocate on obstack.
6067 (create_cus_hash_table): Change type of cus_htab parameter.
6068 (struct dwo_file) <cus, tus>: Now htab_up.
6069 (lookup_dwo_signatured_type, lookup_dwo_cutu)
6070 (process_dwo_file_for_skeletonless_type_units, lookup_dwo_cutu)
6071 (queue_and_load_all_dwo_tus): Update.
6072 * dwarf2/index-write.c (write_gdbindex): Update.
6073 (write_debug_names): Update.
6074
6075 2020-02-08 Tom Tromey <tom@tromey.com>
6076
6077 * dwarf2/read.h (struct dwarf2_queue_item): Move from
6078 dwarf2/read.c. Remove "next" member. Add constructor ntad
6079 destructor.
6080 (struct dwarf2_per_objfile) <queue>: New member.
6081 * dwarf2/read.c (struct dwarf2_queue_item): Move to
6082 dwarf2/read.h.
6083 (dwarf2_queue, dwarf2_queue_tail): Remove.
6084 (class dwarf2_queue_guard): Add parameter to constructor. Use
6085 DISABLE_COPY_AND_ASSIGN.
6086 <m_per_objfile>: New member.
6087 <~dwarf2_queue_guard>: Rewrite.
6088 (dw2_do_instantiate_symtab, queue_comp_unit, process_queue):
6089 Update.
6090 (~dwarf2_queue_item): New.
6091
6092 2020-02-08 Tom Tromey <tom@tromey.com>
6093
6094 * dwarf2/read.c (struct die_info) <has_children>: New member.
6095 (dw2_get_file_names_reader): Remove has_children.
6096 (dw2_get_file_names): Update.
6097 (read_cutu_die_from_dwo): Remove has_children.
6098 (cutu_reader::init_tu_and_read_dwo_dies)
6099 (cutu_reader::cutu_reader): Update.
6100 (process_psymtab_comp_unit_reader, build_type_psymtabs_reader):
6101 Remove has_children.
6102 (build_type_psymtabs_1, process_skeletonless_type_unit)
6103 (load_partial_comp_unit, load_full_comp_unit): Update.
6104 (create_dwo_cu_reader): Remove has_children.
6105 (create_cus_hash_table, read_die_and_children): Update.
6106 (read_full_die_1,read_full_die): Remove has_children.
6107 (read_signatured_type): Update.
6108 (class cutu_reader) <has_children>: Remove.
6109
6110 2020-02-08 Tom Tromey <tom@tromey.com>
6111
6112 * dwarf2/expr.c: Rename from dwarf2expr.c.
6113 * dwarf2/expr.h: Rename from dwarf2expr.h.
6114 * dwarf2/frame-tailcall.c: Rename from dwarf2-frame-tailcall.c.
6115 * dwarf2/frame-tailcall.h: Rename from dwarf2-frame-tailcall.h.
6116 * dwarf2/frame.c: Rename from dwarf2-frame.c.
6117 * dwarf2/frame.h: Rename from dwarf2-frame.h.
6118 * dwarf2/index-cache.c: Rename from dwarf-index-cache.c.
6119 * dwarf2/index-cache.h: Rename from dwarf-index-cache.h.
6120 * dwarf2/index-common.c: Rename from dwarf-index-common.c.
6121 * dwarf2/index-common.h: Rename from dwarf-index-common.h.
6122 * dwarf2/index-write.c: Rename from dwarf-index-write.c.
6123 * dwarf2/index-write.h: Rename from dwarf-index-write.h.
6124 * dwarf2/loc.c: Rename from dwarf2loc.c.
6125 * dwarf2/loc.h: Rename from dwarf2loc.h.
6126 * dwarf2/read.c: Rename from dwarf2read.c.
6127 * dwarf2/read.h: Rename from dwarf2read.h.
6128 * dwarf2/abbrev.c, aarch64-tdep.c, alpha-tdep.c,
6129 amd64-darwin-tdep.c, arc-tdep.c, arm-tdep.c, bfin-tdep.c,
6130 compile/compile-c-symbols.c, compile/compile-cplus-symbols.c,
6131 compile/compile-loc2c.c, cris-tdep.c, csky-tdep.c, findvar.c,
6132 gdbtypes.c, guile/scm-type.c, h8300-tdep.c, hppa-bsd-tdep.c,
6133 hppa-linux-tdep.c, i386-darwin-tdep.c, i386-linux-tdep.c,
6134 i386-tdep.c, iq2000-tdep.c, m32c-tdep.c, m68hc11-tdep.c,
6135 m68k-tdep.c, microblaze-tdep.c, mips-tdep.c, mn10300-tdep.c,
6136 msp430-tdep.c, nds32-tdep.c, nios2-tdep.c, or1k-tdep.c,
6137 riscv-tdep.c, rl78-tdep.c, rs6000-tdep.c, rx-tdep.c, s12z-tdep.c,
6138 s390-tdep.c, score-tdep.c, sh-tdep.c, sparc-linux-tdep.c,
6139 sparc-tdep.c, sparc64-linux-tdep.c, sparc64-tdep.c, tic6x-tdep.c,
6140 tilegx-tdep.c, v850-tdep.c, xstormy16-tdep.c, xtensa-tdep.c:
6141 Update.
6142 * Makefile.in (COMMON_SFILES): Update.
6143 (HFILES_NO_SRCDIR): Update.
6144
6145 2020-02-08 Tom Tromey <tom@tromey.com>
6146
6147 * dwarf2read.c (struct die_reader_specs) <comp_dir>: Remove.
6148 (init_cu_die_reader, read_cutu_die_from_dwo): Update.
6149
6150 2020-02-08 Tom Tromey <tom@tromey.com>
6151
6152 * dwarf2read.h (struct die_info): Don't declare.
6153
6154 2020-02-08 Tom Tromey <tom@tromey.com>
6155
6156 * dwarf2read.h (die_info_ptr): Remove typedef.
6157
6158 2020-02-08 Tom Tromey <tom@tromey.com>
6159
6160 * dwarf2read.c (read_call_site_scope)
6161 (handle_data_member_location, dwarf2_add_member_fn)
6162 (mark_common_block_symbol_computed, read_common_block)
6163 (attr_to_dynamic_prop, partial_die_info::read)
6164 (var_decode_location, dwarf2_fetch_die_loc_sect_off)
6165 (dwarf2_symbol_mark_computed, set_die_type): Update.
6166 * dwarf2/attribute.h (struct attribute) <form_is_block>: Declare
6167 method.
6168 (attr_form_is_block): Don't declare.
6169 * dwarf2/attribute.c (attribute::form_is_block): Now a method.
6170
6171 2020-02-08 Tom Tromey <tom@tromey.com>
6172
6173 * dwarf2read.c (dwarf2_find_base_address, )
6174 (read_call_site_scope, rust_containing_type)
6175 (dwarf2_get_pc_bounds, dwarf2_record_block_ranges)
6176 (handle_data_member_location, dwarf2_add_member_fn)
6177 (get_alignment, read_structure_type, process_structure_scope)
6178 (mark_common_block_symbol_computed, read_common_block)
6179 (read_tag_string_type, attr_to_dynamic_prop, read_subrange_type)
6180 (partial_die_info::read, read_attribute_value, new_symbol)
6181 (lookup_die_type, dwarf2_get_ref_die_offset)
6182 (dwarf2_get_attr_constant_value, follow_die_ref_or_sig)
6183 (dwarf2_fetch_die_loc_sect_off, get_DW_AT_signature_type)
6184 (dwarf2_symbol_mark_computed): Update.
6185 * dwarf2/attribute.h (struct attribute) <value_as_address,
6186 form_is_section_offset, form_is_constant, form_is_ref>: Declare
6187 methods.
6188 (value_as_address, attr_form_is_section_offset)
6189 (attr_form_is_constant, attr_form_is_ref): Don't declare.
6190 * dwarf2/attribute.c (attribute::value_as_address)
6191 (attribute::form_is_section_offset, attribute::form_is_constant)
6192 (attribute::form_is_ref): Now methods.
6193
6194 2020-02-08 Tom Tromey <tom@tromey.com>
6195
6196 * dwarf2read.c (struct attribute, DW_STRING)
6197 (DW_STRING_IS_CANONICAL, DW_UNSND, DW_BLOCK, DW_SND, DW_ADDR)
6198 (DW_SIGNATURE, struct dwarf_block, attr_value_as_address)
6199 (attr_form_is_block, attr_form_is_section_offset)
6200 (attr_form_is_constant, attr_form_is_ref): Move.
6201 * dwarf2/attribute.h: New file.
6202 * dwarf2/attribute.c: New file, from dwarf2read.c.
6203 * Makefile.in (COMMON_SFILES): Add dwarf2/attribute.c.
6204
6205 2020-02-08 Tom Tromey <tom@tromey.com>
6206
6207 * dwarf2read.c (abbrev_table_up, struct abbrev_info)
6208 (struct attr_abbrev, ABBREV_HASH_SIZE, struct abbrev_table):
6209 Move.
6210 (read_cutu_die_from_dwo, build_type_psymtabs_1): Update.
6211 (abbrev_table::alloc_abbrev, abbrev_table::add_abbrev)
6212 (abbrev_table::lookup_abbrev, abbrev_table_read_table): Move to
6213 abbrev.c.
6214 * dwarf2/abbrev.h: New file.
6215 * dwarf2/abbrev.c: New file, from dwarf2read.c.
6216 * Makefile.in (COMMON_SFILES): Add dwarf2/abbrev.c.
6217
6218 2020-02-08 Tom Tromey <tom@tromey.com>
6219
6220 * dwarf2read.c (dwarf2_section_buffer_overflow_complaint)
6221 (dwarf2_section_size, dwarf2_get_section_info)
6222 (create_signatured_type_table_from_debug_names)
6223 (create_addrmap_from_aranges, read_debug_names_from_section)
6224 (get_gdb_index_contents_from_section, read_comp_unit_head)
6225 (error_check_comp_unit_head, read_abbrev_offset)
6226 (create_debug_type_hash_table, init_cu_die_reader)
6227 (read_cutu_die_from_dwo, dwarf2_build_psymtabs_hard)
6228 (read_comp_units_from_section, create_cus_hash_table)
6229 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
6230 (create_dwp_v2_section, dwarf2_rnglists_process)
6231 (dwarf2_ranges_process, read_die_and_siblings, read_full_die)
6232 (abbrev_table_read_table, read_indirect_string_at_offset_from)
6233 (read_indirect_string_from_dwz, read_addr_index_1)
6234 (read_str_index, dwarf_decode_line_header, skip_form_bytes)
6235 (dwarf_decode_macro_bytes, dwarf_decode_macros)
6236 (fill_in_loclist_baton): Update.
6237 * dwarf2/section.h (struct dwarf2_section_info) <get_name,
6238 get_containing_section, get_bfd_owner, get_bfd_section,
6239 get_file_name, get_id, get_flags, empty, read>: Declare methods.
6240 (dwarf2_read_section, get_section_name, get_section_file_name)
6241 (get_containing_section, get_section_bfd_owner)
6242 (get_section_bfd_section, get_section_name, get_section_file_name)
6243 (get_section_id, get_section_flags, dwarf2_section_empty_p): Don't
6244 declare.
6245 * dwarf2/section.c (dwarf2_section_info::get_containing_section)
6246 (dwarf2_section_info::get_bfd_owner)
6247 (dwarf2_section_info::get_bfd_section)
6248 (dwarf2_section_info::get_name)
6249 (dwarf2_section_info::get_file_name, dwarf2_section_info::get_id)
6250 (dwarf2_section_info::get_flags, dwarf2_section_info::empty)
6251 (dwarf2_section_info::read): Now methods.
6252 * dwarf-index-write.c (class debug_names): Update.
6253
6254 2020-02-08 Tom Tromey <tom@tromey.com>
6255
6256 * dwarf2read.h (struct dwarf2_section_info, dwarf2_read_section):
6257 Move to dwarf2/section.h.
6258 * dwarf2read.c (get_containing_section, get_section_bfd_owner)
6259 (get_section_bfd_section, get_section_name)
6260 (get_section_file_name, get_section_id, get_section_flags)
6261 (dwarf2_section_empty_p, dwarf2_read_section): Moe to
6262 dwarf2/section.c.
6263 * dwarf2/section.h: New file.
6264 * dwarf2/section.c: New file, from dwarf2read.c.
6265 * Makefile.in (COMMON_SFILES): Add dwarf2/section.c.
6266
6267 2020-02-08 Tom Tromey <tom@tromey.com>
6268
6269 * dwarf2read.h (read_unsigned_leb128): Don't declare.
6270 * dwarf2read.c (read_1_byte, read_1_signed_byte, read_2_bytes)
6271 (read_2_signed_bytes, read_3_bytes, read_4_bytes)
6272 (read_4_signed_bytes, read_8_bytes): Move to dwarf2/leb.h.
6273 (read_unsigned_leb128, read_signed_leb128): Move to dwarf2/leb.c.
6274 * dwarf2/leb.h: New file, from dwarf2read.c.
6275 * dwarf2/leb.c: New file, from dwarf2read.c.
6276 * dwarf2-frame.c (read_1_byte, read_4_bytes, read_8_bytes):
6277 Remove.
6278 * Makefile.in (CONFIG_SRC_SUBDIR): Add dwarf2.
6279 (COMMON_SFILES): Add dwarf2/leb.c.
6280
6281 2020-02-08 Joel Brobecker <brobecker@adacore.com>
6282
6283 GDB 9.1 released.
6284
6285 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
6286
6287 PR gdb/25190:
6288 * gdb/remote-sim.c (gdb_os_write_stderr): Update.
6289 * gdb/remote.c (remote_console_output): Update.
6290 * gdb/ui-file.c (fputs_unfiltered): Rename to...
6291 (ui_file_puts): ...this.
6292 * gdb/ui-file.h (ui_file_puts): Add declaration.
6293 * gdb/utils.c (emit_style_escape): Update.
6294 (flush_wrap_buffer): Update.
6295 (fputs_maybe_filtered): Update.
6296 (fputs_unfiltered): Add function.
6297
6298 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
6299
6300 * gdb/event-loop.c (gdb_wait_for_event): Update.
6301 * gdb/printcmd.c (printf_command): Update.
6302 * gdb/remote-fileio.c (remote_fileio_func_write): Update.
6303 * gdb/remote-sim.c (gdb_os_flush_stdout): Update.
6304 (gdb_os_flush_stderr): Update.
6305 * gdb/remote.c (remote_console_output): Update.
6306 * gdb/ui-file.c (gdb_flush): Rename to...
6307 (ui_file_flush): ...this.
6308 (stderr_file::write): Update.
6309 (stderr_file::puts): Update.
6310 * gdb/ui-file.h (gdb_flush): Rename to...
6311 (ui_file_flush): ...this.
6312 * gdb/utils.c (gdb_flush): Add function.
6313 * gdb/utils.h (gdb_flush): Add declaration.
6314
6315 2020-02-07 Tom Tromey <tromey@adacore.com>
6316
6317 PR breakpoints/24915:
6318 * source.c (find_and_open_source): Do not check basenames_may_differ.
6319
6320 2020-02-07 Tom Tromey <tom@tromey.com>
6321
6322 * README: Update gdbserver documentation.
6323 * gdbserver: Move to top level.
6324 * configure.tgt (build_gdbserver): Remove.
6325 * configure.ac: Remove --enable-gdbserver.
6326 * configure: Rebuild.
6327 * Makefile.in (distclean): Don't mention gdbserver.
6328
6329 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
6330
6331 * source-cache.c (source_cache::ensure): Surround
6332 get_plain_source_lines with a try/catch.
6333 (source_cache::get_line_charpos): Get rid of try/catch
6334 and only check for the return value of "ensure".
6335 * tui/tui-source.c (tui_source_window::set_contents):
6336 Simplify "nlines" calculation.
6337
6338 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
6339
6340 * MAINTAINERS (Write After Approval): Add myself.
6341
6342 2020-02-05 Christian Biesinger <cbiesinger@google.com>
6343
6344 * sparc-nat.h (struct sparc_target) <xfer_partial>: Fix base class
6345 function call.
6346
6347 2020-02-05 Christian Biesinger <cbiesinger@google.com>
6348
6349 * ppc-nbsd-tdep.h: Fix macro name in #endif comment.
6350
6351 2020-02-05 Maciej W. Rozycki <macro@wdc.com>
6352
6353 * nat/riscv-linux-tdesc.h: New file.
6354 * nat/riscv-linux-tdesc.c: New file, taking code from...
6355 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
6356 ... here.
6357 * configure.nat <linux> <riscv*>: Add nat/riscv-linux-tdesc.o to
6358 NATDEPFILES.
6359
6360 2020-02-04 Andrew Burgess <andrew.burgess@embecosm.com>
6361
6362 * remote-sim.c (sim_inferior_data::sim_inferior_data): Assert that
6363 we don't set the fake simulator ptid to the null_ptid.
6364
6365 2020-02-03 Simon Marchi <simon.marchi@efficios.com>
6366
6367 * fork-child.c (gdb_startup_inferior): Use bool instead of int.
6368 * gdbthread.h (class thread_info) <resumed>: Likewise.
6369 * infrun.c (resume_1): Likewise.
6370 (proceed): Likewise.
6371 (infrun_thread_stop_requested): Likewise.
6372 (stop_all_threads): Likewise.
6373 (handle_inferior_event): Likewise.
6374 (restart_threads): Likewise.
6375 (finish_step_over): Likewise.
6376 (keep_going_stepped_thread): Likewise.
6377 * linux-nat.c (attach_proc_task_lwp_callback): Likewise.
6378 (linux_handle_extended_wait): Likewise.
6379 * record-btrace.c (get_thread_current_frame_id): Likewise.
6380 * record-full.c (record_full_wait_1): Likewise.
6381 * remote.c (remote_target::process_initial_stop_replies): Likewise.
6382 * target.c (target_resume): Likewise.
6383 * thread.c (set_running_thread): Likewise.
6384
6385 2020-02-03 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
6386
6387 * f-valprint.c (f77_print_array_1): Changed datatype of index
6388 variable to LONGEST from int to enable it to contain bound
6389 values correctly.
6390
6391 2020-02-03 Maciej W. Rozycki <macro@wdc.com>
6392
6393 * riscv-linux-nat.c [!NFPREG] (NFPREG): New macro.
6394 (supply_fpregset_regnum, fill_fpregset): Handle regset buffer
6395 offsets according to FLEN determined.
6396 (riscv_linux_nat_target::read_description): Determine FLEN
6397 dynamically.
6398 (riscv_linux_nat_target::fetch_registers): Size regset buffer
6399 according to FLEN determined.
6400 (riscv_linux_nat_target::store_registers): Likewise.
6401
6402 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
6403
6404 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
6405 when reg->group is empty and reggroup is not.
6406
6407 2020-01-31 Tom Tromey <tromey@adacore.com>
6408
6409 * ravenscar-thread.c (ravenscar_thread_target::mourn_inferior):
6410 Call beneath target's mourn_inferior after unpushing.
6411
6412 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
6413
6414 PR tui/9765
6415 * tui/tui-disasm.c (tui_find_disassembly_address): If we don't
6416 have enough lines to fill the screen, still return the lowest
6417 address we found.
6418
6419 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
6420
6421 * tui/tui-win.c (_initialize_tui_win): Update help text for '+',
6422 '-', '<', and '>' commands.
6423
6424 2020-01-29 Pedro Alves <palves@redhat.com>
6425 Sergio Durigan Junior <sergiodj@redhat.com>
6426
6427 * infcmd.c (construct_inferior_arguments): Assert that
6428 'argc' is greater than 0.
6429
6430 2020-01-29 Luis Machado <luis.machado@linaro.org>
6431
6432 * aarch64-tdep.c (BRK_INSN_MASK): Define to 0xffe0001f.
6433 (BRK_INSN_MASK): Define to 0xd4200000.
6434 (aarch64_program_breakpoint_here_p): New function.
6435 (aarch64_gdbarch_init): Set gdbarch_program_breakpoint_here_p hook.
6436 * arch-utils.c (default_program_breakpoint_here_p): Moved from
6437 breakpoint.c.
6438 * arch-utils.h (default_program_breakpoint_here_p): Moved from
6439 breakpoint.h
6440 * breakpoint.c (bp_loc_is_permanent): Changed return type to bool and
6441 call gdbarch_program_breakpoint_here_p.
6442 (program_breakpoint_here): Moved to arch-utils.c, renamed to
6443 default_program_breakpoint_here_p, changed return type to bool and
6444 simplified.
6445 * breakpoint.h (program_breakpoint_here): Moved prototype to
6446 arch-utils.h, renamed to default_program_breakpoint_here_p and changed
6447 return type to bool.
6448 * gdbarch.c: Regenerate.
6449 * gdbarch.h: Regenerate.
6450 * gdbarch.sh (program_breakpoint_here_p): New method.
6451 * infrun.c (handle_signal_stop): Call
6452 gdbarch_program_breakpoint_here_p.
6453
6454 2020-01-26 Tom Tromey <tom@tromey.com>
6455
6456 * ctfread.c (struct ctf_fp_info): Reindent.
6457 (_initialize_ctfread): Remove.
6458
6459 2020-01-26 Tom Tromey <tom@tromey.com>
6460
6461 * psymtab.c (partial_map_expand_apply)
6462 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
6463 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
6464 (psym_print_stats, psym_expand_symtabs_for_function)
6465 (psym_map_symbol_filenames, psym_map_matching_symbols)
6466 (psym_expand_symtabs_matching)
6467 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
6468 (maintenance_check_psymtabs): Use new methods.
6469 * psympriv.h (struct partial_symtab) <readin_p,
6470 get_compunit_symtab>: New methods.
6471 <readin, compunit_symtab>: Remove members.
6472 (struct standard_psymtab): New.
6473 (struct legacy_psymtab): Derive from standard_psymtab.
6474 * dwarf2read.h (struct dwarf2_psymtab): Derive from
6475 standard_psymtab.
6476 * ctfread.c (struct ctf_psymtab): Derive from standard_psymtab.
6477
6478 2020-01-26 Tom Tromey <tom@tromey.com>
6479
6480 * xcoffread.c (xcoff_psymtab_to_symtab_1): Call
6481 read_dependencies. Add assert.
6482 * psymtab.c (partial_symtab::read_dependencies): New method.
6483 * psympriv.h (struct partial_symtab) <read_dependencies>: New
6484 method.
6485 * mdebugread.c (psymtab_to_symtab_1): Call read_dependencies.
6486 * dwarf2read.c (dwarf2_psymtab::expand_psymtab): Call
6487 read_dependencies.
6488 * dbxread.c (dbx_psymtab_to_symtab_1): Call read_dependencies.
6489 Add assert.
6490
6491 2020-01-26 Tom Tromey <tom@tromey.com>
6492
6493 * xcoffread.c (xcoff_psymtab_to_symtab_1): Change argument order.
6494 Call expand_psymtab.
6495 (xcoff_read_symtab): Call expand_psymtab.
6496 (xcoff_start_psymtab, xcoff_end_psymtab): Set
6497 legacy_expand_psymtab.
6498 * psympriv.h (struct partial_symtab) <expand_psymtab>: New
6499 method.
6500 (struct legacy_psymtab) <expand_psymtab>: Implement.
6501 <legacy_expand_psymtab>: New member.
6502 * mdebugread.c (mdebug_read_symtab): Call expand_psymtab.
6503 (parse_partial_symbols): Set legacy_expand_psymtab.
6504 (psymtab_to_symtab_1): Change argument order. Call
6505 expand_psymtab.
6506 (new_psymtab): Set legacy_expand_psymtab.
6507 * dwarf2read.h (struct dwarf2_psymtab) <expand_psymtab>: Declare.
6508 * dwarf2read.c (dwarf2_psymtab::read_symtab): Call
6509 expand_psymtab.
6510 (dwarf2_psymtab::expand_psymtab): Rename from
6511 psymtab_to_symtab_1. Call expand_psymtab.
6512 * dbxread.c (start_psymtab): Set legacy_expand_psymtab.
6513 (dbx_end_psymtab): Likewise.
6514 (dbx_psymtab_to_symtab_1): Change argument order. Call
6515 expand_psymtab.
6516 (dbx_read_symtab): Call expand_psymtab.
6517 * ctfread.c (struct ctf_psymtab) <expand_psymtab>: Declare.
6518 (ctf_psymtab::expand_psymtab): Rename from psymtab_to_symtab.
6519 (ctf_psymtab::read_symtab): Call expand_psymtab.
6520
6521 2020-01-26 Tom Tromey <tom@tromey.com>
6522
6523 * xcoffread.c (xcoff_read_symtab): Remove prints. Add assert.
6524 * psymtab.c (psymtab_to_symtab): Print verbose "Reading"
6525 messages.
6526 * mdebugread.c (mdebug_read_symtab): Remove prints.
6527 * dwarf2read.c (dwarf2_psymtab::read_symtab): Remove prints. Add
6528 assert.
6529 * dbxread.c (dbx_read_symtab): Remove prints. Add assert.
6530
6531 2020-01-26 Tom Tromey <tom@tromey.com>
6532
6533 * xcoffread.c (this_symtab_psymtab, read_xcoff_symtab)
6534 (xcoff_psymtab_to_symtab_1, xcoff_read_symtab)
6535 (xcoff_start_psymtab, xcoff_end_psymtab, scan_xcoff_symtab): Use
6536 legacy_symtab.
6537 * stabsread.h (dbx_end_psymtab): Use legacy_symtab.
6538 * psymtab.c (psymtab_to_symtab): Call method.
6539 (dump_psymtab): Update.
6540 * psympriv.h (struct partial_symtab): Add virtual destructor.
6541 <read_symtab>: New method.
6542 (struct legacy_symtab): New.
6543 * mdebugread.c (mdebug_read_symtab): Use legacy_psymtab.
6544 (struct pst_map) <pst>: Now a legacy_psymtab.
6545 (parse_procedure, parse_partial_symbols, psymtab_to_symtab_1)
6546 (new_psymtab): Use legacy_psymtab.
6547 * dwarf2read.h (struct dwarf2_psymtab): New.
6548 (struct dwarf2_per_cu_data) <psymtab>: Use it.
6549 * dwarf2read.c (dwarf2_create_include_psymtab)
6550 (dwarf2_build_include_psymtabs, create_type_unit_group)
6551 (create_partial_symtab, process_psymtab_comp_unit_reader)
6552 (build_type_psymtabs_reader, build_type_psymtab_dependencies)
6553 (set_partial_user): Use dwarf2_psymtab.
6554 (dwarf2_psymtab::read_symtab): Rename from dwarf2_read_symtab.
6555 (psymtab_to_symtab_1, process_full_comp_unit)
6556 (process_full_type_unit, dwarf2_ranges_read)
6557 (dwarf2_get_pc_bounds, psymtab_include_file_name)
6558 (dwarf_decode_lines): Use dwarf2_psymtab.
6559 * dwarf-index-write.c (psym_index_map): Use dwarf2_psymtab.
6560 (add_address_entry_worker, write_one_signatured_type)
6561 (recursively_count_psymbols, recursively_write_psymbols)
6562 (write_one_signatured_type, psyms_seen_size, write_gdbindex)
6563 (write_debug_names): Likewise.
6564 * dbxread.c (struct header_file_location): Take a legacy_psymtab.
6565 <pst>: Now a legacy_psymtab.
6566 (find_corresponding_bincl_psymtab): Return a legacy_psymtab.
6567 (read_dbx_symtab, start_psymtab, dbx_end_psymtab)
6568 (dbx_psymtab_to_symtab_1, read_ofile_symtab): Use legacy_psymtab.
6569 * ctfread.c (struct ctf_psymtab): New.
6570 (ctf_start_symtab, ctf_end_symtab, psymtab_to_symtab): Take a
6571 ctf_psymtab.
6572 (ctf_psymtab::read_symtab): Rename from ctf_read_symtab.
6573 (create_partial_symtab): Return a ctf_psymtab.
6574 (scan_partial_symbols): Update.
6575
6576 2020-01-26 Tom Tromey <tom@tromey.com>
6577
6578 * xcoffread.c (xcoff_start_psymtab): Use new.
6579 * psymtab.c (partial_symtab::partial_symtab): New constructor,
6580 renamed from start_psymtab_common.
6581 * psympriv.h (struct partial_symtab): Add new constructor.
6582 (start_psymtab_common): Don't declare.
6583 * mdebugread.c (parse_partial_symbols): Use new.
6584 * dwarf2read.c (create_partial_symtab): Use new.
6585 * dbxread.c (start_psymtab): Use new.
6586 * ctfread.c (create_partial_symtab): Use new.
6587
6588 2020-01-26 Tom Tromey <tom@tromey.com>
6589
6590 * xcoffread.c (xcoff_end_psymtab): Use new.
6591 * psymtab.c (start_psymtab_common): Use new.
6592 (partial_symtab::partial_symtab): Rename from allocate_psymtab.
6593 Update.
6594 * psympriv.h (struct partial_symtab): Add parameters to
6595 constructor. Don't inline.
6596 (allocate_psymtab): Don't declare.
6597 * mdebugread.c (new_psymtab): Use new.
6598 * dwarf2read.c (dwarf2_create_include_psymtab): Use new.
6599 * dbxread.c (dbx_end_psymtab): Use new.
6600
6601 2020-01-26 Tom Tromey <tom@tromey.com>
6602
6603 * psymtab.h (class psymtab_storage) <install_psymtab>: Rename from
6604 allocate_psymtab. Update documentation.
6605 * psymtab.c (psymtab_storage::install_psymtab): Rename from
6606 allocate_psymtab. Do not use new.
6607 (allocate_psymtab): Use new. Update.
6608
6609 2020-01-26 Tom Tromey <tom@tromey.com>
6610
6611 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
6612 * psymtab.c (psym_print_stats): Update.
6613 * psympriv.h (struct partial_symtab) <readin,
6614 psymtabs_addrmap_supported, anonymous>: Now bool.
6615 * mdebugread.c (psymtab_to_symtab_1): Update.
6616 * dwarf2read.c (create_type_unit_group, create_partial_symtab)
6617 (build_type_psymtabs_reader, psymtab_to_symtab_1)
6618 (process_full_comp_unit, process_full_type_unit): Update.
6619 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
6620 * ctfread.c (psymtab_to_symtab): Update.
6621
6622 2020-01-26 Tom Tromey <tom@tromey.com>
6623
6624 * mdebugread.c (parse_partial_symbols): Use discard_psymtab.
6625 * psymtab.h (class psymtab_storage) <free_psymtabs>: Remove.
6626 * psymtab.c (psymtab_storage): Delete psymtabs.
6627 (psymtab_storage::allocate_psymtab): Use new.
6628 (psymtab_storage::discard_psymtab): Use delete.
6629 * psympriv.h (struct partial_symtab): Add constructor and
6630 initializers.
6631
6632 2020-01-26 Tom Tromey <tom@tromey.com>
6633
6634 * machoread.c: Do not include psympriv.h.
6635
6636 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6637
6638 * NEWS: Mention the new option and the set/show commands.
6639
6640 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6641
6642 * exec.c (exec_file_mismatch_names, exec_file_mismatch_mode)
6643 (show_exec_file_mismatch_command, set_exec_file_mismatch_command)
6644 (validate_exec_file): New variables, enums, functions.
6645 (exec_file_locate_attach, print_section_info): Style the filenames.
6646 (_initialize_exec): Install show_exec_file_mismatch_command and
6647 set_exec_file_mismatch_command.
6648 * gdbcore.h (validate_exec_file): Declare.
6649 * infcmd.c (attach_command): Call validate_exec_file.
6650 * remote.c ( remote_target::remote_add_inferior): Likewise.
6651
6652 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
6653
6654 * frame.c (find_frame_sal): Move call to get_next_frame into more
6655 inner scope.
6656 * inline-frame.c (inilne_state) <inline_state>: Update argument
6657 types.
6658 (inilne_state) <skipped_symbol>: Rename to...
6659 (inilne_state) <skipped_symbols>: ...this, and change to a vector.
6660 (skip_inline_frames): Build vector of skipped symbols and use this
6661 to reate the inline_state.
6662 (inline_skipped_symbol): Add a comment and some assertions, fetch
6663 skipped symbol from the list.
6664
6665 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
6666
6667 * buildsym.c (lte_is_less_than): Delete.
6668 (buildsym_compunit::end_symtab_with_blockvector): Create local
6669 lambda function to sort line table entries, and use
6670 std::stable_sort instead of std::sort.
6671 * symtab.c (find_pc_sect_line): Skip backward over end of sequence
6672 markers when looking for a previous line.
6673
6674 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
6675
6676 * dwarf2read.c (lnp_state_machine::record_line): Include
6677 end_sequence parameter in debug print out. Record the line if we
6678 are at an end_sequence marker even if it's not the start of a
6679 statement.
6680 * symmisc.c (maintenance_print_one_line_table): Print end of
6681 sequence markers with 'END' not '0'.
6682
6683 2020-01-24 Pedro Alves <palves@redhat.com>
6684
6685 PR gdb/25410
6686 * thread.c (scoped_restore_current_thread::restore): Use
6687 switch_to_inferior_no_thread.
6688 * exec.c: Include "progspace-and-thread.h".
6689 (add_target_sections, remove_target_sections):
6690 scoped_restore_current_pspace_and_thread instead of
6691 scoped_restore_current_thread.
6692 * infrun.c (handle_vfork_child_exec_or_exit): Assign the pspace
6693 and aspace to the inferior before calling clone_program_space.
6694 Remove stale comment.
6695
6696 2020-01-24 Christian Biesinger <cbiesinger@google.com>
6697
6698 * arm-nbsd-nat.c (arm_nbsd_nat_target::fetch_registers): Rename to...
6699 (arm_netbsd_nat_target::fetch_registers): ...this.
6700 (arm_nbsd_nat_target::store_registers): Rename to...
6701 (arm_netbsd_nat_target::store_registers): ...this.
6702
6703 2020-01-24 Christian Biesinger <cbiesinger@google.com>
6704
6705 * arm-nbsd-nat.c: Define _KERNTYPES to get the declaration of
6706 register_t.
6707
6708 2020-01-24 Christian Biesinger <cbiesinger@google.com>
6709
6710 * aarch64-fbsd-tdep.c (aarch64_fbsd_iterate_over_regset_sections):
6711 Update comment.
6712 * aarch64-linux-tdep.c (aarch64_linux_iterate_over_regset_sections):
6713 Likewise.
6714 * arm-fbsd-tdep.c (arm_fbsd_iterate_over_regset_sections): Likewise.
6715 * gdbcore.h (deprecated_add_core_fns): Update comment to point to
6716 the correct replacement (iterate_over_regset_sections).
6717 * riscv-fbsd-tdep.c (riscv_fbsd_iterate_over_regset_sections):
6718 Update comment.
6719
6720 2020-01-24 Graham Markall <graham.markall@embecosm.com>
6721
6722 PR gdb/23718
6723 * gdb/python/python.c (execute_gdb_command): Call
6724 async_enable_stdin in catch block.
6725
6726 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
6727
6728 * event-loop.c (start_event_loop): Wrap async_enable_stdin with
6729 SWITCH_THRU_ALL_UIS.
6730
6731 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
6732
6733 PR tui/9765
6734 * minsyms.c (lookup_minimal_symbol_by_pc_section): Update header
6735 comment, add extra parameter, and update to store previous symbol
6736 when appropriate.
6737 * minsyms.h (lookup_minimal_symbol_by_pc_section): Update comment,
6738 add extra parameter.
6739 * tui/tui-disasm.c (tui_disassemble): Update header comment,
6740 remove unneeded parameter, add try/catch around gdb_print_insn,
6741 rewrite to add items to asm_lines vector.
6742 (tui_find_backward_disassembly_start_address): New function.
6743 (tui_find_disassembly_address): Updated throughout.
6744 (tui_disasm_window::set_contents): Update for changes to
6745 tui_disassemble.
6746 (tui_disasm_window::do_scroll_vertical): No need to adjust the
6747 number of lines to scroll.
6748
6749 2020-01-23 Simon Marchi <simon.marchi@polymtl.ca>
6750
6751 * objfiles.h (ALL_OBJFILE_OSECTIONS): Move up.
6752 (SECT_OFF_DATA): Likewise.
6753 (SECT_OFF_RODATA): Likewise.
6754 (SECT_OFF_TEXT): Likewise.
6755 (SECT_OFF_BSS): Likewise.
6756 (struct objfile) <text_section_offset, data_section_offset>: New
6757 methods.
6758 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Use
6759 objfile::text_section_offset.
6760 * coff-pe-read.c (add_pe_forwarded_sym): Likewise.
6761 * coffread.c (coff_symtab_read): Likewise.
6762 (enter_linenos): Likewise.
6763 (process_coff_symbol): Likewise.
6764 * ctfread.c (get_objfile_text_range): Likewise.
6765 * dtrace-probe.c (dtrace_probe::get_relocated_address):
6766 Use objfile::data_section_offset.
6767 * dwarf2-frame.c (execute_cfa_program): Use
6768 objfile::text_section_offset.
6769 (dwarf2_frame_find_fde): Likewise.
6770 * dwarf2read.c (create_addrmap_from_index): Likewise.
6771 (create_addrmap_from_aranges): Likewise.
6772 (dw2_find_pc_sect_compunit_symtab): Likewise.
6773 (process_psymtab_comp_unit_reader): Likewise.
6774 (add_partial_symbol): Likewise.
6775 (add_partial_subprogram): Likewise.
6776 (process_full_comp_unit): Likewise.
6777 (read_file_scope): Likewise.
6778 (read_func_scope): Likewise.
6779 (read_lexical_block_scope): Likewise.
6780 (read_call_site_scope): Likewise.
6781 (dwarf2_rnglists_process): Likewise.
6782 (dwarf2_ranges_process): Likewise.
6783 (dwarf2_ranges_read): Likewise.
6784 (dwarf_decode_lines_1): Likewise.
6785 (new_symbol): Likewise.
6786 (dwarf2_fetch_die_loc_sect_off): Likewise.
6787 (dwarf2_per_cu_text_offset): Likewise.
6788 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Likewise.
6789 * hppa-tdep.c (read_unwind_info): Likewise.
6790 * ia64-tdep.c (ia64_find_unwind_table): Likewise.
6791 * psympriv.h (struct partial_symtab): Likewise.
6792 * psymtab.c (find_pc_sect_psymtab): Likewise.
6793 * solib-svr4.c (enable_break): Likewise.
6794 * stap-probe.c (relocate_address): Use
6795 objfile::data_section_offset.
6796 * xcoffread.c (enter_line_range): Use
6797 objfile::text_section_offset.
6798 (read_xcoff_symtab): Likewise.
6799
6800 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
6801
6802 * darwin-nat.c (darwin_nat_target::wait_1): Move `inf`
6803 declaration to narrower scopes.
6804
6805 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
6806
6807 * darwin-nat.h (struct darwin_exception_msg, enum
6808 darwin_msg_state, struct darwin_thread_info, darwin_thread_t):
6809 Move up.
6810 (class darwin_nat_target) <wait_1, check_new_threads,
6811 decode_exception_message, decode_message, stop_inferior,
6812 init_thread_list, ptrace_him, cancel_breakpoint>: Declare.
6813 * darwin-nat.c (darwin_check_new_threads): Rename to...
6814 (darwin_nat_target::check_new_threads): ... this.
6815 (darwin_suspend_inferior_it): Remove.
6816 (darwin_decode_exception_message): Rename to...
6817 (darwin_nat_target::decode_exception_message): ... this.
6818 (darwin_nat_target::resume): Pass target to find_inferior_ptid.
6819 (darwin_decode_message): Rename to...
6820 (darwin_nat_target::decode_message): ... this.
6821 (cancel_breakpoint): Rename to...
6822 (darwin_nat_target::cancel_breakpoint): ... this.
6823 (darwin_wait): Rename to...
6824 (darwin_nat_target::wait_1): ... this. Use range-based for loop
6825 instead of iterate_over_inferiors.
6826 (darwin_nat_target::wait): Call wait_1 instead of darwin_wait.
6827 (darwin_stop_inferior): Rename to...
6828 (darwin_nat_target::stop_inferior): ... this.
6829 (darwin_nat_target::kill): Call wait_1 instead of darwin_wait.
6830 (darwin_init_thread_list): Rename to...
6831 (darwin_nat_target::init_thread_list): ... this.
6832 (darwin_ptrace_him): Rename to...
6833 (darwin_nat_target::ptrace_him): ... this.
6834 (darwin_nat_target::create_inferior): Pass lambda function to
6835 fork_inferior.
6836 (darwin_nat_target::detach): Call stop_inferior instead of
6837 darwin_stop_inferior.
6838 * fork-inferior.h (fork_inferior): Change init_trace_fun
6839 parameter to gdb::function_view.
6840 * fork-inferior.c (fork_inferior): Likewise.
6841
6842 2020-01-23 Hannes Domani <ssbssa@yahoo.de>
6843
6844 * i386-cygwin-tdep.c (core_process_module_section): Update.
6845 * windows-nat.c (struct lm_info_windows): Add text_offset.
6846 (windows_xfer_shared_libraries): Update.
6847 * windows-tdep.c (windows_xfer_shared_library):
6848 Add text_offset_cached argument.
6849 * windows-tdep.h (windows_xfer_shared_library): Update.
6850
6851 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
6852
6853 * gdbarch.sh: Add declaration for _initialize_gdbarch.
6854
6855 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
6856
6857 * remote-sim.c (check_for_duplicate_sim_descriptor): Remove.
6858 (get_sim_inferior_data): Remove use of iterate_over_inferiors,
6859 replace with range-based for.
6860 (gdbsim_interrupt_inferior): Remove.
6861 (gdbsim_target::interrupt): Replace iterate_over_inferiors use
6862 with a range-based for. Inline code from
6863 gdbsim_interrupt_inferior.
6864
6865 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
6866
6867 * infrun.c (proceed): Fix indentation.
6868
6869 2020-01-21 Tom Tromey <tromey@adacore.com>
6870
6871 * source-cache.c (source_cache::ensure): Call ext_lang_colorize.
6872 * python/python.c (python_extension_ops): Update.
6873 (gdbpy_colorize): New function.
6874 * python/lib/gdb/__init__.py (colorize): New function.
6875 * extension.h (ext_lang_colorize): Declare.
6876 * extension.c (ext_lang_colorize): New function.
6877 * extension-priv.h (struct extension_language_ops) <colorize>: New
6878 member.
6879 * cli/cli-style.c (_initialize_cli_style): Update help text.
6880
6881 2020-01-21 Luis Machado <luis.machado@linaro.org>
6882
6883 * aarch64-tdep.c (struct aarch64_displaced_step_closure)
6884 <cond>: Change type to bool.
6885 (aarch64_displaced_step_b_cond): Update cond to use bool type.
6886 (aarch64_displaced_step_cb): Likewise.
6887 (aarch64_displaced_step_tb): Likewise.
6888
6889 2020-01-21 Luis Machado <luis.machado@linaro.org>
6890
6891 * aarch64-tdep.c (aarch64_displaced_step_fixup): Add more debugging
6892 output.
6893
6894 2020-01-21 Luis Machado <luis.machado@linaro.org>
6895
6896 * aarch64-tdep.c (struct aarch64_displaced_step_closure )
6897 <pc_adjust>: Adjust the documentation.
6898 (aarch64_displaced_step_fixup): Check if PC really moved before
6899 adjusting it.
6900
6901 2020-01-19 Tom Tromey <tom@tromey.com>
6902
6903 * disasm.c (~gdb_disassembler): New destructor.
6904 (gdb_buffered_insn_length): Call disassemble_free_target.
6905 * disasm.h (class gdb_disassembler): Declare destructor. Use
6906 DISABLE_COPY_AND_ASSIGN.
6907
6908 2020-01-19 Tom Tromey <tom@tromey.com>
6909
6910 * dwarf2read.c (abbrev_table_up): Move typedef earlier.
6911 (die_reader_func_ftype): Remove.
6912 (cutu_reader): New class.
6913 (dw2_get_file_names_reader): Remove "data" parameter.
6914 (dw2_get_file_names): Use cutu_reader.
6915 (create_debug_type_hash_table): Update.
6916 (read_cutu_die_from_dwo): Update comment.
6917 (lookup_dwo_unit): Add dwo_name parameter.
6918 (cutu_reader::init_tu_and_read_dwo_dies): Now a method. Remove
6919 die_reader_func_ftype and data parameters.
6920 (cutu_reader::cutu_reader): Rename from init_cutu_and_read_dies.
6921 Remove die_reader_func_ftype and data parameters.
6922 (~cutu_reader): New; from init_cutu_and_read_dies.
6923 (cutu_reader::cutu_reader): Rename from
6924 init_cutu_and_read_dies_no_follow. Remove die_reader_func_ftype
6925 and data parameters.
6926 (init_cutu_and_read_dies_simple): Remove.
6927 (struct process_psymtab_comp_unit_data): Remove.
6928 (process_psymtab_comp_unit_reader): Remove data parameter; add
6929 want_partial_unit and pretend_language parameters.
6930 (process_psymtab_comp_unit): Use cutu_reader.
6931 (build_type_psymtabs_reader): Remove data parameter.
6932 (build_type_psymtabs_1): Use cutu_reader.
6933 (process_skeletonless_type_unit): Likewise.
6934 (load_partial_comp_unit_reader): Remove.
6935 (load_partial_comp_unit): Use cutu_reader.
6936 (load_full_comp_unit_reader): Remove.
6937 (load_full_comp_unit): Use cutu_reader.
6938 (struct create_dwo_cu_data): Remove.
6939 (create_dwo_cu_reader): Remove datap parameter; add dwo_file and
6940 dwo_unit parameters.
6941 (create_cus_hash_table): Use cutu_reader.
6942 (struct dwarf2_read_addr_index_data): Remove.
6943 (dwarf2_read_addr_index_reader): Remove.
6944 (dwarf2_read_addr_index): Use cutu_reader.
6945 (read_signatured_type_reader): Remove.
6946 (read_signatured_type): Use cutu_reader.
6947
6948 2020-01-19 Tom Tromey <tom@tromey.com>
6949
6950 * tui/tui.c (tui_show_assembly): Use tui_suppress_output.
6951 * tui/tui-wingeneral.h (class tui_suppress_output): New.
6952 (tui_wrefresh): Declare.
6953 * tui/tui-wingeneral.c (suppress_output): New global.
6954 (tui_suppress_output, ~tui_suppress_output): New constructor and
6955 destructor.
6956 (tui_wrefresh): New function.
6957 (tui_gen_win_info::refresh_window): Use tui_wrefresh.
6958 (tui_gen_win_info::make_window): Call wnoutrefresh when needed.
6959 * tui/tui-regs.h (struct tui_data_window) <no_refresh>: Declare
6960 method.
6961 * tui/tui-regs.c (tui_data_window::erase_data_content): Call
6962 tui_wrefresh.
6963 (tui_data_window::no_refresh): New method.
6964 (tui_data_item_window::refresh_window): Call tui_wrefresh.
6965 (tui_reg_command): Use tui_suppress_output
6966 * tui/tui-layout.c (tui_set_layout): Use tui_suppress_output.
6967 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: New
6968 method.
6969 * tui/tui-command.c (tui_refresh_cmd_win): Call tui_wrefresh.
6970
6971 2020-01-19 Tom Tromey <tom@tromey.com>
6972
6973 * tui/tui-winsource.c (tui_update_source_windows_with_line):
6974 Handle case where symtab is null.
6975
6976 2020-01-19 Simon Marchi <simon.marchi@polymtl.ca>
6977
6978 * linux-fork.c (one_fork_p): Simplify.
6979
6980 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
6981
6982 * top.c (struct qt_args): Remove.
6983 (kill_or_detach): Change return type to void, replace `void *`
6984 parameter with a proper one.
6985 (print_inferior_quit_action): Likewise.
6986 (quit_confirm): Use range-based for loop to iterate over inferiors.
6987 (quit_force): Likewise.
6988
6989 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
6990
6991 * mi/mi-main.c (run_one_inferior): Change return type to void, replace
6992 `void *` parameter with proper parameters.
6993 (mi_cmd_exec_run): Use range-based loop to iterate over inferiors.
6994 (print_one_inferior): Change return type to void, replace `void *`
6995 parameter with proper parameters.
6996 (mi_cmd_list_thread_groups): Use range-based loop to iterate over
6997 inferiors.
6998 (get_other_inferior): Remove.
6999 (mi_cmd_remove_inferior): Use range-based loop to iterate over
7000 inferiors.
7001
7002 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
7003
7004 * mi/mi-interp.c (report_initial_inferior): Remove.
7005 (mi_interp::init): Use range-based for to iterate over inferiors.
7006
7007 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
7008
7009 * python/py-inferior.c (build_inferior_list): Remove.
7010 (gdbpy_ref): Use range-based for loop to iterate over inferiors.
7011
7012 2020-01-16 Christian Biesinger <cbiesinger@google.com>
7013
7014 * btrace.c (btrace_compute_ftrace_1): Fix spelling error (Unkown).
7015 (btrace_stitch_trace): Likewise.
7016 * charset.c (intermediate_encoding): Likewise (vaild).
7017 * nat/linux-btrace.c (linux_read_pt): Likewise (Unkown).
7018 * python/py-record-btrace.c (struct PyMethodDef): Likewise (occurences).
7019 * record-btrace.c (record_btrace_print_conf): Likewise (unkown).
7020
7021 2020-01-16 Hannes Domani <ssbssa@yahoo.de>
7022
7023 * windows-tdep.c (windows_get_tlb_type):
7024 Add rtl_user_process_parameters type.
7025
7026 2020-01-16 Pedro Alves <palves@redhat.com>
7027 Norbert Lange <nolange79@gmail.com>
7028
7029 PR build/24805
7030 * gdbsupport/gdb_proc_service.h (PS_EXPORT): New.
7031 (ps_get_thread_area, ps_getpid, ps_lcontinue, ps_lgetfpregs)
7032 (ps_lgetregs, ps_lsetfpregs, ps_lsetregs, ps_lstop, ps_pcontinue)
7033 (ps_pdread, ps_pdwrite, ps_pglobal_lookup, ps_pstop, ps_ptread)
7034 (ps_ptwrite, ps_lgetxregs, ps_lgetxregsize, ps_lsetxregs)
7035 (ps_plog): Redeclare exported functions with default visibility.
7036
7037 2020-01-16 Nitika Achra <Nitika.Achra@amd.com>
7038
7039 * dwarf2loc.c (decode_debug_loclists_addresses): Handle
7040 DW_LLE_base_addressx, DW_LLE_startx_length, DW_LLE_start_length.
7041
7042 2020-01-15 Simon Marchi <simon.marchi@efficios.com>
7043
7044 * infcmd.c (post_create_inferior): Use get_thread_regcache
7045 instead of get_current_regcache.
7046
7047 2020-01-14 Tom Tromey <tom@tromey.com>
7048
7049 PR symtab/12535:
7050 * python/python.c (gdbpy_decode_line): Treat empty string the same
7051 as no argument.
7052
7053 2020-01-14 Tom Tromey <tom@tromey.com>
7054
7055 * Makefile.in (CLIBS): Remove second use of $(LIBIBERTY).
7056
7057 2020-01-14 Tom Tromey <tom@tromey.com>
7058
7059 * nat/linux-btrace.c: Don't include <config.h>.
7060 * nat/linux-ptrace.c: Don't include <config.h>.
7061 * nat/x86-linux-dregs.c: Don't include <config.h>.
7062
7063 2020-01-14 Tom Tromey <tom@tromey.com>
7064
7065 * configure: Rebuild.
7066 * configure.ac: Move many checks to ../gdbsupport/common.m4.
7067
7068 2020-01-14 Tom Tromey <tom@tromey.com>
7069
7070 * nat/x86-linux-dregs.c: Include configh.h.
7071 * nat/linux-ptrace.c: Include configh.h.
7072 * nat/linux-btrace.c: Include configh.h.
7073 * defs.h: Include config.h, bfd.h.
7074 * configure.ac: Don't source common.host.
7075 (CONFIG_OBS, CONFIG_SRCS): Remove gdbsupport files.
7076 * configure: Rebuild.
7077 * acinclude.m4: Update path.
7078 * Makefile.in (SUPPORT, LIBSUPPORT, INCSUPPORT): New variables.
7079 (CONFIG_SRC_SUBDIR): Remove gdbsupport.
7080 (INTERNAL_CFLAGS_BASE): Add INCSUPPORT.
7081 (CLIBS): Add LIBSUPPORT.
7082 (CDEPS): Likewise.
7083 (COMMON_SFILES): Remove gdbsupport files.
7084 (HFILES_NO_SRCDIR): Likewise.
7085 (stamp-version): Update path to create-version.sh.
7086 (ALLDEPFILES): Remove gdbsupport files.
7087
7088 2020-01-14 Tom Tromey <tom@tromey.com>
7089
7090 * gdbsupport/common.m4 (GDB_AC_COMMON): Define WIN32APILIBS and
7091 USE_WIN32API when needed.
7092 * configure.ac (USE_WIN32API): Don't define.
7093 (WIN32LIBS): Use WIN32APILIBS.
7094 * configure: Rebuild.
7095
7096 2020-01-14 Tom Tromey <tom@tromey.com>
7097
7098 * configure: Rebuild.
7099 * gdbsupport/common.m4 (GDB_AC_COMMON): Fix indentation.
7100
7101 2020-01-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
7102
7103 * skip.c (skip_function_command): Make skip w/o arguments use the
7104 name of the inlined function if pc is inside any inlined function.
7105
7106 2020-01-14 Luis Machado <luis.machado@linaro.org>
7107
7108 * inf-ptrace.c (inf_ptrace_target::resume): Update comments.
7109 * infrun.c (resume_1): Likewise.
7110 (handle_inferior_event): Remove stale comment.
7111 * linux-nat.c (linux_nat_target::resume): Update comments.
7112 (save_stop_reason): Likewise.
7113 (linux_nat_filter_event): Likewise.
7114 * linux-nat.h (struct lwp_info) <stop_pc>, <stop_reason>: Likewise.
7115
7116 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
7117
7118 * elfread.c (record_minimal_symbol): Set section index to 0 for
7119 non-allocatable sections.
7120
7121
7122 2020-01-13 Ali Tamur <tamur@google.com>
7123
7124 * dwarf2read.c (dwarf2_debug_sections): Add debug_str_offsets sections.
7125 (dwarf2_cu): Add str_offsets_base field. Change the type of addr_base
7126 to gdb::optional. Update comments.
7127 (dwo_file): Update comments.
7128 (read_attribute): Update API to take an additional out parameter,
7129 need_reprocess. This is used to mark attributes that need other
7130 attributes (e.g. str_offsets_base) for correct computation which may not
7131 have been read yet.
7132 (read_attribute_reprocess): New function declaration.
7133 (read_addr_index): Likewise.
7134 (read_dwo_str_index): Likewise.
7135 (read_stub_str_index): Likewise.
7136 (dwarf2_per_objfile::locate_sections): Handle debug_str_offsets section.
7137 (lookup_addr_base): New function definition.
7138 (lookup_ranges_base): Likewise.
7139 (read_cutu_die_from_dwo): Use the new functions: lookup_addr_base,
7140 lookup_ranges_base.
7141 (init_cutu_and_read_dies): Update comments.
7142 (init_cutu_and_read_dies_no_follow): Change API to take parent compile
7143 unit. This is used to inherit parent's str_offsets_base and addr_base.
7144 Update comments.
7145 (init_cutu_and_read_dies_simple): Reflect API changes.
7146 (skip_one_die): Reflect API changes. Handle DW_FORM_rnglistx.
7147 (create_cus_hash_table): Change API to take parent compile unit.
7148 Reflect API changes.
7149 (open_and_init_dwo_file): Reflect API changes.
7150 (dwarf2_get_pc_bounds): Update comments.
7151 (dwarf2_record_block_ranges): Likewise.
7152 (read_full_die_1): Change implementation to reprocess attributes that
7153 need str_offsets_base and addr_base.
7154 (partial_die_info::read): Likewise.
7155 (read_attribute_reprocess): New function definition.
7156 (read_attribute_value): Change API to take an additional out parameter,
7157 need_reprocess. Handle DW_FORM_rnglistx. No longer trigger an error
7158 when a non-dwo compile unit has index based attributes.
7159 (read_attribute): Reflect API changes.
7160 (read_addr_index_1): Reflect API changes. Update comments.
7161 (dwarf2_read_addr_index_data): Reflect API changes.
7162 (dwarf2_read_addr_index): Likewise.
7163 (read_str_index): Change API and implementation. This becomes a helper
7164 to be used by the new string index related methods. Update error
7165 message and comments.
7166 (read_dwo_str_index): New function definition.
7167 (read_stub_str_index): Likewise.
7168 * dwarf2read.h (dwarf2_per_objfile): Add str_offsets field.
7169 * symfile.h (dwarf2_debug_sections): Likewise.
7170 * xcoffread.c (dwarf2_debug_sections): Likewise.
7171
7172 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
7173
7174 * gdbcore.h (struct core_fns) <core_read_registers>: Change
7175 core_reg_sect type to gdb_byte *.
7176 * arm-nbsd-nat.c (fetch_elfcore_registers): Likewise.
7177 * cris-tdep.c (fetch_core_registers): Likewise.
7178 * corelow.c (core_target::get_core_register_section): Change
7179 type of `contents` to gdb::byte_vector.
7180
7181 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
7182
7183 * tui/tui-wingeneral.c (box_win): Position the title in the center
7184 of the border.
7185
7186 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
7187
7188 * corelow.c (core_target::get_core_register_section): Use
7189 std::vector instead of alloca.
7190
7191 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
7192
7193 * warning.m4: Add -Wmissing-declarations to build_warnings.
7194 * configure: Re-generate.
7195
7196 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
7197
7198 * python/python.c (init__gdb_module): Add declaration.
7199
7200 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
7201
7202 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Add declaration.
7203 * aarch64-fbsd-tdep.c (_initialize_aarch64_fbsd_tdep): Add declaration.
7204 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Add declaration.
7205 * aarch64-linux-tdep.c (_initialize_aarch64_linux_tdep): Add declaration.
7206 * aarch64-newlib-tdep.c (_initialize_aarch64_newlib_tdep): Add declaration.
7207 * aarch64-tdep.c (_initialize_aarch64_tdep): Add declaration.
7208 * ada-exp.y (_initialize_ada_exp): Add declaration.
7209 * ada-lang.c (_initialize_ada_language): Add declaration.
7210 * ada-tasks.c (_initialize_tasks): Add declaration.
7211 * agent.c (_initialize_agent): Add declaration.
7212 * aix-thread.c (_initialize_aix_thread): Add declaration.
7213 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Add declaration.
7214 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Add declaration.
7215 * alpha-linux-tdep.c (_initialize_alpha_linux_tdep): Add declaration.
7216 * alpha-nbsd-tdep.c (_initialize_alphanbsd_tdep): Add declaration.
7217 * alpha-obsd-tdep.c (_initialize_alphaobsd_tdep): Add declaration.
7218 * alpha-tdep.c (_initialize_alpha_tdep): Add declaration.
7219 * amd64-darwin-tdep.c (_initialize_amd64_darwin_tdep): Add declaration.
7220 * amd64-dicos-tdep.c (_initialize_amd64_dicos_tdep): Add declaration.
7221 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Add declaration.
7222 * amd64-fbsd-tdep.c (_initialize_amd64fbsd_tdep): Add declaration.
7223 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Add declaration.
7224 * amd64-linux-tdep.c (_initialize_amd64_linux_tdep): Add declaration.
7225 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Add declaration.
7226 * amd64-nbsd-tdep.c (_initialize_amd64nbsd_tdep): Add declaration.
7227 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Add declaration.
7228 * amd64-obsd-tdep.c (_initialize_amd64obsd_tdep): Add declaration.
7229 * amd64-sol2-tdep.c (_initialize_amd64_sol2_tdep): Add declaration.
7230 * amd64-tdep.c (_initialize_amd64_tdep): Add declaration.
7231 * amd64-windows-nat.c (_initialize_amd64_windows_nat): Add declaration.
7232 * amd64-windows-tdep.c (_initialize_amd64_windows_tdep): Add declaration.
7233 * annotate.c (_initialize_annotate): Add declaration.
7234 * arc-newlib-tdep.c (_initialize_arc_newlib_tdep): Add declaration.
7235 * arc-tdep.c (_initialize_arc_tdep): Add declaration.
7236 * arch-utils.c (_initialize_gdbarch_utils): Add declaration.
7237 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Add declaration.
7238 * arm-fbsd-tdep.c (_initialize_arm_fbsd_tdep): Add declaration.
7239 * arm-linux-nat.c (_initialize_arm_linux_nat): Add declaration.
7240 * arm-linux-tdep.c (_initialize_arm_linux_tdep): Add declaration.
7241 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Add declaration.
7242 * arm-nbsd-tdep.c (_initialize_arm_netbsd_tdep): Add declaration.
7243 * arm-obsd-tdep.c (_initialize_armobsd_tdep): Add declaration.
7244 * arm-pikeos-tdep.c (_initialize_arm_pikeos_tdep): Add declaration.
7245 * arm-symbian-tdep.c (_initialize_arm_symbian_tdep): Add declaration.
7246 * arm-tdep.c (_initialize_arm_tdep): Add declaration.
7247 * arm-wince-tdep.c (_initialize_arm_wince_tdep): Add declaration.
7248 * auto-load.c (_initialize_auto_load): Add declaration.
7249 * auxv.c (_initialize_auxv): Add declaration.
7250 * avr-tdep.c (_initialize_avr_tdep): Add declaration.
7251 * ax-gdb.c (_initialize_ax_gdb): Add declaration.
7252 * bfin-linux-tdep.c (_initialize_bfin_linux_tdep): Add declaration.
7253 * bfin-tdep.c (_initialize_bfin_tdep): Add declaration.
7254 * break-catch-sig.c (_initialize_break_catch_sig): Add declaration.
7255 * break-catch-syscall.c (_initialize_break_catch_syscall): Add declaration.
7256 * break-catch-throw.c (_initialize_break_catch_throw): Add declaration.
7257 * breakpoint.c (_initialize_breakpoint): Add declaration.
7258 * bsd-uthread.c (_initialize_bsd_uthread): Add declaration.
7259 * btrace.c (_initialize_btrace): Add declaration.
7260 * charset.c (_initialize_charset): Add declaration.
7261 * cli/cli-cmds.c (_initialize_cli_cmds): Add declaration.
7262 * cli/cli-dump.c (_initialize_cli_dump): Add declaration.
7263 * cli/cli-interp.c (_initialize_cli_interp): Add declaration.
7264 * cli/cli-logging.c (_initialize_cli_logging): Add declaration.
7265 * cli/cli-script.c (_initialize_cli_script): Add declaration.
7266 * cli/cli-style.c (_initialize_cli_style): Add declaration.
7267 * coff-pe-read.c (_initialize_coff_pe_read): Add declaration.
7268 * coffread.c (_initialize_coffread): Add declaration.
7269 * compile/compile-cplus-types.c (_initialize_compile_cplus_types): Add declaration.
7270 * compile/compile.c (_initialize_compile): Add declaration.
7271 * complaints.c (_initialize_complaints): Add declaration.
7272 * completer.c (_initialize_completer): Add declaration.
7273 * copying.c (_initialize_copying): Add declaration.
7274 * corefile.c (_initialize_core): Add declaration.
7275 * corelow.c (_initialize_corelow): Add declaration.
7276 * cp-abi.c (_initialize_cp_abi): Add declaration.
7277 * cp-namespace.c (_initialize_cp_namespace): Add declaration.
7278 * cp-support.c (_initialize_cp_support): Add declaration.
7279 * cp-valprint.c (_initialize_cp_valprint): Add declaration.
7280 * cris-linux-tdep.c (_initialize_cris_linux_tdep): Add declaration.
7281 * cris-tdep.c (_initialize_cris_tdep): Add declaration.
7282 * csky-linux-tdep.c (_initialize_csky_linux_tdep): Add declaration.
7283 * csky-tdep.c (_initialize_csky_tdep): Add declaration.
7284 * ctfread.c (_initialize_ctfread): Add declaration.
7285 * d-lang.c (_initialize_d_language): Add declaration.
7286 * darwin-nat-info.c (_initialize_darwin_info_commands): Add declaration.
7287 * darwin-nat.c (_initialize_darwin_nat): Add declaration.
7288 * dbxread.c (_initialize_dbxread): Add declaration.
7289 * dcache.c (_initialize_dcache): Add declaration.
7290 * disasm-selftests.c (_initialize_disasm_selftests): Add declaration.
7291 * disasm.c (_initialize_disasm): Add declaration.
7292 * dtrace-probe.c (_initialize_dtrace_probe): Add declaration.
7293 * dummy-frame.c (_initialize_dummy_frame): Add declaration.
7294 * dwarf-index-cache.c (_initialize_index_cache): Add declaration.
7295 * dwarf-index-write.c (_initialize_dwarf_index_write): Add declaration.
7296 * dwarf2-frame-tailcall.c (_initialize_tailcall_frame): Add declaration.
7297 * dwarf2-frame.c (_initialize_dwarf2_frame): Add declaration.
7298 * dwarf2expr.c (_initialize_dwarf2expr): Add declaration.
7299 * dwarf2loc.c (_initialize_dwarf2loc): Add declaration.
7300 * dwarf2read.c (_initialize_dwarf2_read): Add declaration.
7301 * elfread.c (_initialize_elfread): Add declaration.
7302 * exec.c (_initialize_exec): Add declaration.
7303 * extension.c (_initialize_extension): Add declaration.
7304 * f-lang.c (_initialize_f_language): Add declaration.
7305 * f-valprint.c (_initialize_f_valprint): Add declaration.
7306 * fbsd-nat.c (_initialize_fbsd_nat): Add declaration.
7307 * fbsd-tdep.c (_initialize_fbsd_tdep): Add declaration.
7308 * filesystem.c (_initialize_filesystem): Add declaration.
7309 * findcmd.c (_initialize_mem_search): Add declaration.
7310 * findvar.c (_initialize_findvar): Add declaration.
7311 * fork-child.c (_initialize_fork_child): Add declaration.
7312 * frame-base.c (_initialize_frame_base): Add declaration.
7313 * frame-unwind.c (_initialize_frame_unwind): Add declaration.
7314 * frame.c (_initialize_frame): Add declaration.
7315 * frv-linux-tdep.c (_initialize_frv_linux_tdep): Add declaration.
7316 * frv-tdep.c (_initialize_frv_tdep): Add declaration.
7317 * ft32-tdep.c (_initialize_ft32_tdep): Add declaration.
7318 * gcore.c (_initialize_gcore): Add declaration.
7319 * gdb-demangle.c (_initialize_gdb_demangle): Add declaration.
7320 * gdb_bfd.c (_initialize_gdb_bfd): Add declaration.
7321 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Add declaration.
7322 * gdbarch.c (_initialize_gdbarch): Add declaration.
7323 * gdbtypes.c (_initialize_gdbtypes): Add declaration.
7324 * gnu-nat.c (_initialize_gnu_nat): Add declaration.
7325 * gnu-v2-abi.c (_initialize_gnu_v2_abi): Add declaration.
7326 * gnu-v3-abi.c (_initialize_gnu_v3_abi): Add declaration.
7327 * go-lang.c (_initialize_go_language): Add declaration.
7328 * go32-nat.c (_initialize_go32_nat): Add declaration.
7329 * guile/guile.c (_initialize_guile): Add declaration.
7330 * h8300-tdep.c (_initialize_h8300_tdep): Add declaration.
7331 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Add declaration.
7332 * hppa-linux-tdep.c (_initialize_hppa_linux_tdep): Add declaration.
7333 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Add declaration.
7334 * hppa-nbsd-tdep.c (_initialize_hppanbsd_tdep): Add declaration.
7335 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Add declaration.
7336 * hppa-obsd-tdep.c (_initialize_hppabsd_tdep): Add declaration.
7337 * hppa-tdep.c (_initialize_hppa_tdep): Add declaration.
7338 * i386-bsd-nat.c (_initialize_i386bsd_nat): Add declaration.
7339 * i386-cygwin-tdep.c (_initialize_i386_cygwin_tdep): Add declaration.
7340 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Add declaration.
7341 * i386-darwin-tdep.c (_initialize_i386_darwin_tdep): Add declaration.
7342 * i386-dicos-tdep.c (_initialize_i386_dicos_tdep): Add declaration.
7343 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Add declaration.
7344 * i386-fbsd-tdep.c (_initialize_i386fbsd_tdep): Add declaration.
7345 * i386-gnu-nat.c (_initialize_i386gnu_nat): Add declaration.
7346 * i386-gnu-tdep.c (_initialize_i386gnu_tdep): Add declaration.
7347 * i386-go32-tdep.c (_initialize_i386_go32_tdep): Add declaration.
7348 * i386-linux-nat.c (_initialize_i386_linux_nat): Add declaration.
7349 * i386-linux-tdep.c (_initialize_i386_linux_tdep): Add declaration.
7350 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Add declaration.
7351 * i386-nbsd-tdep.c (_initialize_i386nbsd_tdep): Add declaration.
7352 * i386-nto-tdep.c (_initialize_i386nto_tdep): Add declaration.
7353 * i386-obsd-nat.c (_initialize_i386obsd_nat): Add declaration.
7354 * i386-obsd-tdep.c (_initialize_i386obsd_tdep): Add declaration.
7355 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Add declaration.
7356 * i386-sol2-tdep.c (_initialize_i386_sol2_tdep): Add declaration.
7357 * i386-tdep.c (_initialize_i386_tdep): Add declaration.
7358 * i386-windows-nat.c (_initialize_i386_windows_nat): Add declaration.
7359 * ia64-libunwind-tdep.c (_initialize_libunwind_frame): Add declaration.
7360 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Add declaration.
7361 * ia64-linux-tdep.c (_initialize_ia64_linux_tdep): Add declaration.
7362 * ia64-tdep.c (_initialize_ia64_tdep): Add declaration.
7363 * ia64-vms-tdep.c (_initialize_ia64_vms_tdep): Add declaration.
7364 * infcall.c (_initialize_infcall): Add declaration.
7365 * infcmd.c (_initialize_infcmd): Add declaration.
7366 * inflow.c (_initialize_inflow): Add declaration.
7367 * infrun.c (_initialize_infrun): Add declaration.
7368 * interps.c (_initialize_interpreter): Add declaration.
7369 * iq2000-tdep.c (_initialize_iq2000_tdep): Add declaration.
7370 * jit.c (_initialize_jit): Add declaration.
7371 * language.c (_initialize_language): Add declaration.
7372 * linux-fork.c (_initialize_linux_fork): Add declaration.
7373 * linux-nat.c (_initialize_linux_nat): Add declaration.
7374 * linux-tdep.c (_initialize_linux_tdep): Add declaration.
7375 * linux-thread-db.c (_initialize_thread_db): Add declaration.
7376 * lm32-tdep.c (_initialize_lm32_tdep): Add declaration.
7377 * m2-lang.c (_initialize_m2_language): Add declaration.
7378 * m32c-tdep.c (_initialize_m32c_tdep): Add declaration.
7379 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Add declaration.
7380 * m32r-linux-tdep.c (_initialize_m32r_linux_tdep): Add declaration.
7381 * m32r-tdep.c (_initialize_m32r_tdep): Add declaration.
7382 * m68hc11-tdep.c (_initialize_m68hc11_tdep): Add declaration.
7383 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Add declaration.
7384 * m68k-bsd-tdep.c (_initialize_m68kbsd_tdep): Add declaration.
7385 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Add declaration.
7386 * m68k-linux-tdep.c (_initialize_m68k_linux_tdep): Add declaration.
7387 * m68k-tdep.c (_initialize_m68k_tdep): Add declaration.
7388 * machoread.c (_initialize_machoread): Add declaration.
7389 * macrocmd.c (_initialize_macrocmd): Add declaration.
7390 * macroscope.c (_initialize_macroscope): Add declaration.
7391 * maint-test-options.c (_initialize_maint_test_options): Add declaration.
7392 * maint-test-settings.c (_initialize_maint_test_settings): Add declaration.
7393 * maint.c (_initialize_maint_cmds): Add declaration.
7394 * mdebugread.c (_initialize_mdebugread): Add declaration.
7395 * memattr.c (_initialize_mem): Add declaration.
7396 * mep-tdep.c (_initialize_mep_tdep): Add declaration.
7397 * mi/mi-cmd-env.c (_initialize_mi_cmd_env): Add declaration.
7398 * mi/mi-cmds.c (_initialize_mi_cmds): Add declaration.
7399 * mi/mi-interp.c (_initialize_mi_interp): Add declaration.
7400 * mi/mi-main.c (_initialize_mi_main): Add declaration.
7401 * microblaze-linux-tdep.c (_initialize_microblaze_linux_tdep): Add declaration.
7402 * microblaze-tdep.c (_initialize_microblaze_tdep): Add declaration.
7403 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Add declaration.
7404 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Add declaration.
7405 * mips-linux-nat.c (_initialize_mips_linux_nat): Add declaration.
7406 * mips-linux-tdep.c (_initialize_mips_linux_tdep): Add declaration.
7407 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Add declaration.
7408 * mips-nbsd-tdep.c (_initialize_mipsnbsd_tdep): Add declaration.
7409 * mips-sde-tdep.c (_initialize_mips_sde_tdep): Add declaration.
7410 * mips-tdep.c (_initialize_mips_tdep): Add declaration.
7411 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Add declaration.
7412 * mips64-obsd-tdep.c (_initialize_mips64obsd_tdep): Add declaration.
7413 * mipsread.c (_initialize_mipsread): Add declaration.
7414 * mn10300-linux-tdep.c (_initialize_mn10300_linux_tdep): Add declaration.
7415 * mn10300-tdep.c (_initialize_mn10300_tdep): Add declaration.
7416 * moxie-tdep.c (_initialize_moxie_tdep): Add declaration.
7417 * msp430-tdep.c (_initialize_msp430_tdep): Add declaration.
7418 * nds32-tdep.c (_initialize_nds32_tdep): Add declaration.
7419 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Add declaration.
7420 * nios2-tdep.c (_initialize_nios2_tdep): Add declaration.
7421 * nto-procfs.c (_initialize_procfs): Add declaration.
7422 * objc-lang.c (_initialize_objc_language): Add declaration.
7423 * observable.c (_initialize_observer): Add declaration.
7424 * opencl-lang.c (_initialize_opencl_language): Add declaration.
7425 * or1k-linux-tdep.c (_initialize_or1k_linux_tdep): Add declaration.
7426 * or1k-tdep.c (_initialize_or1k_tdep): Add declaration.
7427 * osabi.c (_initialize_gdb_osabi): Add declaration.
7428 * osdata.c (_initialize_osdata): Add declaration.
7429 * p-valprint.c (_initialize_pascal_valprint): Add declaration.
7430 * parse.c (_initialize_parse): Add declaration.
7431 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Add declaration.
7432 * ppc-fbsd-tdep.c (_initialize_ppcfbsd_tdep): Add declaration.
7433 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Add declaration.
7434 * ppc-linux-tdep.c (_initialize_ppc_linux_tdep): Add declaration.
7435 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Add declaration.
7436 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Add declaration.
7437 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Add declaration.
7438 * ppc-obsd-tdep.c (_initialize_ppcobsd_tdep): Add declaration.
7439 * printcmd.c (_initialize_printcmd): Add declaration.
7440 * probe.c (_initialize_probe): Add declaration.
7441 * proc-api.c (_initialize_proc_api): Add declaration.
7442 * proc-events.c (_initialize_proc_events): Add declaration.
7443 * proc-service.c (_initialize_proc_service): Add declaration.
7444 * procfs.c (_initialize_procfs): Add declaration.
7445 * producer.c (_initialize_producer): Add declaration.
7446 * psymtab.c (_initialize_psymtab): Add declaration.
7447 * python/python.c (_initialize_python): Add declaration.
7448 * ravenscar-thread.c (_initialize_ravenscar): Add declaration.
7449 * record-btrace.c (_initialize_record_btrace): Add declaration.
7450 * record-full.c (_initialize_record_full): Add declaration.
7451 * record.c (_initialize_record): Add declaration.
7452 * regcache-dump.c (_initialize_regcache_dump): Add declaration.
7453 * regcache.c (_initialize_regcache): Add declaration.
7454 * reggroups.c (_initialize_reggroup): Add declaration.
7455 * remote-notif.c (_initialize_notif): Add declaration.
7456 * remote-sim.c (_initialize_remote_sim): Add declaration.
7457 * remote.c (_initialize_remote): Add declaration.
7458 * reverse.c (_initialize_reverse): Add declaration.
7459 * riscv-fbsd-nat.c (_initialize_riscv_fbsd_nat): Add declaration.
7460 * riscv-fbsd-tdep.c (_initialize_riscv_fbsd_tdep): Add declaration.
7461 * riscv-linux-nat.c (_initialize_riscv_linux_nat): Add declaration.
7462 * riscv-linux-tdep.c (_initialize_riscv_linux_tdep): Add declaration.
7463 * riscv-tdep.c (_initialize_riscv_tdep): Add declaration.
7464 * rl78-tdep.c (_initialize_rl78_tdep): Add declaration.
7465 * rs6000-aix-tdep.c (_initialize_rs6000_aix_tdep): Add declaration.
7466 * rs6000-lynx178-tdep.c (_initialize_rs6000_lynx178_tdep):
7467 Add declaration.
7468 * rs6000-nat.c (_initialize_rs6000_nat): Add declaration.
7469 * rs6000-tdep.c (_initialize_rs6000_tdep): Add declaration.
7470 * run-on-main-thread.c (_initialize_run_on_main_thread): Add declaration.
7471 * rust-exp.y (_initialize_rust_exp): Add declaration.
7472 * rx-tdep.c (_initialize_rx_tdep): Add declaration.
7473 * s12z-tdep.c (_initialize_s12z_tdep): Add declaration.
7474 * s390-linux-nat.c (_initialize_s390_nat): Add declaration.
7475 * s390-linux-tdep.c (_initialize_s390_linux_tdep): Add declaration.
7476 * s390-tdep.c (_initialize_s390_tdep): Add declaration.
7477 * score-tdep.c (_initialize_score_tdep): Add declaration.
7478 * ser-go32.c (_initialize_ser_dos): Add declaration.
7479 * ser-mingw.c (_initialize_ser_windows): Add declaration.
7480 * ser-pipe.c (_initialize_ser_pipe): Add declaration.
7481 * ser-tcp.c (_initialize_ser_tcp): Add declaration.
7482 * ser-uds.c (_initialize_ser_socket): Add declaration.
7483 * ser-unix.c (_initialize_ser_hardwire): Add declaration.
7484 * serial.c (_initialize_serial): Add declaration.
7485 * sh-linux-tdep.c (_initialize_sh_linux_tdep): Add declaration.
7486 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Add declaration.
7487 * sh-nbsd-tdep.c (_initialize_shnbsd_tdep): Add declaration.
7488 * sh-tdep.c (_initialize_sh_tdep): Add declaration.
7489 * skip.c (_initialize_step_skip): Add declaration.
7490 * sol-thread.c (_initialize_sol_thread): Add declaration.
7491 * solib-aix.c (_initialize_solib_aix): Add declaration.
7492 * solib-darwin.c (_initialize_darwin_solib): Add declaration.
7493 * solib-dsbt.c (_initialize_dsbt_solib): Add declaration.
7494 * solib-frv.c (_initialize_frv_solib): Add declaration.
7495 * solib-svr4.c (_initialize_svr4_solib): Add declaration.
7496 * solib-target.c (_initialize_solib_target): Add declaration.
7497 * solib.c (_initialize_solib): Add declaration.
7498 * source-cache.c (_initialize_source_cache): Add declaration.
7499 * source.c (_initialize_source): Add declaration.
7500 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Add declaration.
7501 * sparc-linux-tdep.c (_initialize_sparc_linux_tdep): Add declaration.
7502 * sparc-nat.c (_initialize_sparc_nat): Add declaration.
7503 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Add declaration.
7504 * sparc-nbsd-tdep.c (_initialize_sparcnbsd_tdep): Add declaration.
7505 * sparc-obsd-tdep.c (_initialize_sparc32obsd_tdep): Add declaration.
7506 * sparc-sol2-tdep.c (_initialize_sparc_sol2_tdep): Add declaration.
7507 * sparc-tdep.c (_initialize_sparc_tdep): Add declaration.
7508 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Add declaration.
7509 * sparc64-fbsd-tdep.c (_initialize_sparc64fbsd_tdep): Add declaration.
7510 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Add declaration.
7511 * sparc64-linux-tdep.c (_initialize_sparc64_linux_tdep): Add declaration.
7512 * sparc64-nat.c (_initialize_sparc64_nat): Add declaration.
7513 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Add declaration.
7514 * sparc64-nbsd-tdep.c (_initialize_sparc64nbsd_tdep): Add declaration.
7515 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Add declaration.
7516 * sparc64-obsd-tdep.c (_initialize_sparc64obsd_tdep): Add declaration.
7517 * sparc64-sol2-tdep.c (_initialize_sparc64_sol2_tdep): Add declaration.
7518 * sparc64-tdep.c (_initialize_sparc64_adi_tdep): Add declaration.
7519 * stabsread.c (_initialize_stabsread): Add declaration.
7520 * stack.c (_initialize_stack): Add declaration.
7521 * stap-probe.c (_initialize_stap_probe): Add declaration.
7522 * std-regs.c (_initialize_frame_reg): Add declaration.
7523 * symfile-debug.c (_initialize_symfile_debug): Add declaration.
7524 * symfile-mem.c (_initialize_symfile_mem): Add declaration.
7525 * symfile.c (_initialize_symfile): Add declaration.
7526 * symmisc.c (_initialize_symmisc): Add declaration.
7527 * symtab.c (_initialize_symtab): Add declaration.
7528 * target.c (_initialize_target): Add declaration.
7529 * target-connection.c (_initialize_target_connection): Add
7530 declaration.
7531 * target-dcache.c (_initialize_target_dcache): Add declaration.
7532 * target-descriptions.c (_initialize_target_descriptions): Add declaration.
7533 * thread.c (_initialize_thread): Add declaration.
7534 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Add declaration.
7535 * tic6x-tdep.c (_initialize_tic6x_tdep): Add declaration.
7536 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Add declaration.
7537 * tilegx-linux-tdep.c (_initialize_tilegx_linux_tdep): Add declaration.
7538 * tilegx-tdep.c (_initialize_tilegx_tdep): Add declaration.
7539 * tracectf.c (_initialize_ctf): Add declaration.
7540 * tracefile-tfile.c (_initialize_tracefile_tfile): Add declaration.
7541 * tracefile.c (_initialize_tracefile): Add declaration.
7542 * tracepoint.c (_initialize_tracepoint): Add declaration.
7543 * tui/tui-hooks.c (_initialize_tui_hooks): Add declaration.
7544 * tui/tui-interp.c (_initialize_tui_interp): Add declaration.
7545 * tui/tui-layout.c (_initialize_tui_layout): Add declaration.
7546 * tui/tui-regs.c (_initialize_tui_regs): Add declaration.
7547 * tui/tui-stack.c (_initialize_tui_stack): Add declaration.
7548 * tui/tui-win.c (_initialize_tui_win): Add declaration.
7549 * tui/tui.c (_initialize_tui): Add declaration.
7550 * typeprint.c (_initialize_typeprint): Add declaration.
7551 * ui-style.c (_initialize_ui_style): Add declaration.
7552 * unittests/array-view-selftests.c (_initialize_array_view_selftests): Add declaration.
7553 * unittests/child-path-selftests.c (_initialize_child_path_selftests): Add declaration.
7554 * unittests/cli-utils-selftests.c (_initialize_cli_utils_selftests): Add declaration.
7555 * unittests/common-utils-selftests.c (_initialize_common_utils_selftests): Add declaration.
7556 * unittests/copy_bitwise-selftests.c (_initialize_copy_bitwise_utils_selftests): Add declaration.
7557 * unittests/environ-selftests.c (_initialize_environ_selftests): Add declaration.
7558 * unittests/filtered_iterator-selftests.c
7559 (_initialize_filtered_iterator_selftests): Add declaration.
7560 * unittests/format_pieces-selftests.c (_initialize_format_pieces_selftests): Add declaration.
7561 * unittests/function-view-selftests.c (_initialize_function_view_selftests): Add declaration.
7562 * unittests/help-doc-selftests.c (_initialize_help_doc_selftests): Add declaration.
7563 * unittests/lookup_name_info-selftests.c (_initialize_lookup_name_info_selftests): Add declaration.
7564 * unittests/main-thread-selftests.c
7565 (_initialize_main_thread_selftests): Add declaration.
7566 * unittests/memory-map-selftests.c (_initialize_memory_map_selftests): Add declaration.
7567 * unittests/memrange-selftests.c (_initialize_memrange_selftests): Add declaration.
7568 * unittests/mkdir-recursive-selftests.c (_initialize_mkdir_recursive_selftests): Add declaration.
7569 * unittests/observable-selftests.c (_initialize_observer_selftest): Add declaration.
7570 * unittests/offset-type-selftests.c (_initialize_offset_type_selftests): Add declaration.
7571 * unittests/optional-selftests.c (_initialize_optional_selftests): Add declaration.
7572 * unittests/parse-connection-spec-selftests.c (_initialize_parse_connection_spec_selftests): Add declaration.
7573 * unittests/rsp-low-selftests.c (_initialize_rsp_low_selftests): Add declaration.
7574 * unittests/scoped_fd-selftests.c (_initialize_scoped_fd_selftests): Add declaration.
7575 * unittests/scoped_mmap-selftests.c (_initialize_scoped_mmap_selftests): Add declaration.
7576 * unittests/scoped_restore-selftests.c (_initialize_scoped_restore_selftests): Add declaration.
7577 * unittests/string_view-selftests.c (_initialize_string_view_selftests): Add declaration.
7578 * unittests/style-selftests.c (_initialize_style_selftest): Add declaration.
7579 * unittests/tracepoint-selftests.c (_initialize_tracepoint_selftests): Add declaration.
7580 * unittests/tui-selftests.c (_initialize_tui_selftest): Add
7581 declaration.
7582 * unittests/unpack-selftests.c (_initialize_unpack_selftests): Add declaration.
7583 * unittests/utils-selftests.c (_initialize_utils_selftests): Add declaration.
7584 * unittests/vec-utils-selftests.c (_initialize_vec_utils_selftests): Add declaration.
7585 * unittests/xml-utils-selftests.c (_initialize_xml_utils): Add declaration.
7586 * user-regs.c (_initialize_user_regs): Add declaration.
7587 * utils.c (_initialize_utils): Add declaration.
7588 * v850-tdep.c (_initialize_v850_tdep): Add declaration.
7589 * valops.c (_initialize_valops): Add declaration.
7590 * valprint.c (_initialize_valprint): Add declaration.
7591 * value.c (_initialize_values): Add declaration.
7592 * varobj.c (_initialize_varobj): Add declaration.
7593 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Add declaration.
7594 * vax-nbsd-tdep.c (_initialize_vaxnbsd_tdep): Add declaration.
7595 * vax-tdep.c (_initialize_vax_tdep): Add declaration.
7596 * windows-nat.c (_initialize_windows_nat): Add declaration.
7597 (_initialize_check_for_gdb_ini): Add declaration.
7598 (_initialize_loadable): Add declaration.
7599 * windows-tdep.c (_initialize_windows_tdep): Add declaration.
7600 * x86-bsd-nat.c (_initialize_x86_bsd_nat): Add declaration.
7601 * x86-linux-nat.c (_initialize_x86_linux_nat): Add declaration.
7602 * xcoffread.c (_initialize_xcoffread): Add declaration.
7603 * xml-support.c (_initialize_xml_support): Add declaration.
7604 * xstormy16-tdep.c (_initialize_xstormy16_tdep): Add declaration.
7605 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Add declaration.
7606 * xtensa-linux-tdep.c (_initialize_xtensa_linux_tdep): Add declaration.
7607 * xtensa-tdep.c (_initialize_xtensa_tdep): Add declaration.
7608
7609 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
7610
7611 * regformats/regdat.sh: Generate declaration for init function.
7612
7613 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
7614
7615 * remote-sim.c (next_pid, INITIAL_PID, sim_inferior_data): Move
7616 up.
7617 (gdbsim_target) <get_inferior_data_by_ptid, resume_one_inferior,
7618 close_one_inferior>: New methods.
7619 (get_sim_inferior_data_by_ptid): Move to gdbsim_target,
7620 pass down target to find_inferior_pid.
7621 (gdbsim_target::fetch_registers, gdbsim_target::store_registers):
7622 Pass down target to find_inferior_ptid.
7623 (gdbsim_target::create_inferior): Pass down target to
7624 add_thread_silent.
7625 (gdbsim_close_inferior): Move to gdbsim_close_inferior, pass
7626 target down to find_inferior_ptid and switch_to_thread.
7627 (gdbsim_target::close): Update to call close_one_inferior.
7628 (struct resume_data): Remove.
7629 (gdbsim_resume_inferior): Move to gdbsim_target. Take arguments
7630 directly, rather than through a void pointer.
7631 (gdbsim_target::resume): Update to call resume_one_inferior.
7632
7633 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
7634
7635 * gdbsupport/gdb_wait.c: Include gdb_wait.h.
7636
7637 2020-01-12 Pedro Alves <palves@redhat.com>
7638
7639 * bsd-kvm.c (bsd_kvm_target::close): Call exit_inferior_silent
7640 directly for the current inferior instead of
7641 discard_all_inferiors.
7642 (discard_all_inferiors): Delete.
7643
7644 2020-01-11 Tom Tromey <tom@tromey.com>
7645
7646 * tui/tui-wingeneral.c (box_win): Check cli_styling.
7647 * tui/tui-winsource.c (tui_source_window_base::refill): Use
7648 deprecated_safe_get_selected_frame.
7649
7650 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
7651
7652 * inferior.c (print_inferior): Switch inferior before printing it.
7653
7654 2020-01-10 Aleksandar Paunovic <aleksandar.paunovic@intel.com>
7655 Pedro Alves <palves@redhat.com>
7656
7657 * progspace-and-thread.c (switch_to_program_space_and_thread):
7658 Assert there's an inferior for PSPACE. Use
7659 switch_to_inferior_no_thread to switch the inferior too.
7660 * progspace.c (program_space::~program_space): Call
7661 clear_symtab_users here, with SYMFILE_DEFER_BP_RESET.
7662 (program_space::free_all_objfiles): Don't call clear_symtab_users
7663 here.
7664 * symfile.c (symbol_file_clear): Call clear_symtab_users here.
7665
7666 2020-01-10 Pedro Alves <palves@redhat.com>
7667
7668 * NEWS: Mention multi-target debugging, "info connections", and
7669 "add-inferior -no-connection".
7670
7671 2020-01-10 Pedro Alves <palves@redhat.com>
7672
7673 * infrun.c: Include "target-connection.h".
7674 (check_multi_target_resumption): New.
7675 (proceed): Call it.
7676 * target-connection.c (make_target_connection_string): Make
7677 extern.
7678 * target-connection.h (make_target_connection_string): Declare.
7679
7680 2020-01-10 Pedro Alves <palves@redhat.com>
7681
7682 * Makefile.in (COMMON_SFILES): Add target-connection.c.
7683 * inferior.c (uiout_field_connection): New function.
7684 (print_inferior): Add new "connection-id" column.
7685 (add_inferior_command): Show connection number/string of added
7686 inferior.
7687 * process-stratum-target.h
7688 (process_stratum_target::connection_string): New virtual method.
7689 (process_stratum_target::connection_number): New field.
7690 * remote.c (remote_target::connection_string): New override.
7691 * target-connection.c: New file.
7692 * target-connection.h: New file.
7693 * target.c (decref_target): Remove process_stratum targets from
7694 the connection list.
7695 (target_stack::push): Add process_stratum targets to the
7696 connection list.
7697
7698 2020-01-10 Pedro Alves <palves@redhat.com>
7699
7700 Revert:
7701 2016-04-12 Pedro Alves <palves@redhat.com>
7702 * serial.c (serial_open, serial_fdopen_ops, do_serial_close):
7703 Remove references to name.
7704 * serial.h (struct serial) <name>: Delete.
7705
7706 2020-01-10 Pedro Alves <palves@redhat.com>
7707
7708 * gdbarch-selftests.c (register_to_value_test): Remove "target
7709 already pushed" check.
7710
7711 2020-01-10 Pedro Alves <palves@redhat.com>
7712 John Baldwin <jhb@FreeBSD.org>
7713
7714 * aarch64-linux-nat.c
7715 (aarch64_linux_nat_target::thread_architecture): Adjust.
7716 * ada-tasks.c (print_ada_task_info): Adjust find_thread_ptid call.
7717 (task_command_1): Likewise.
7718 * aix-thread.c (sync_threadlists, aix_thread_target::resume)
7719 (aix_thread_target::wait, aix_thread_target::fetch_registers)
7720 (aix_thread_target::store_registers)
7721 (aix_thread_target::thread_alive): Adjust.
7722 * amd64-fbsd-tdep.c: Include "inferior.h".
7723 (amd64fbsd_get_thread_local_address): Pass down target.
7724 * amd64-linux-nat.c (ps_get_thread_area): Use ps_prochandle
7725 thread's gdbarch instead of target_gdbarch.
7726 * break-catch-sig.c (signal_catchpoint_print_it): Adjust call to
7727 get_last_target_status.
7728 * break-catch-syscall.c (print_it_catch_syscall): Likewise.
7729 * breakpoint.c (breakpoints_should_be_inserted_now): Consider all
7730 inferiors.
7731 (update_inserted_breakpoint_locations): Skip if inferiors with no
7732 execution.
7733 (update_global_location_list): When handling moribund locations,
7734 find representative inferior for location's pspace, and use thread
7735 count of its process_stratum target.
7736 * bsd-kvm.c (bsd_kvm_target_open): Pass target down.
7737 * bsd-uthread.c (bsd_uthread_target::wait): Use
7738 as_process_stratum_target and adjust thread_change_ptid and
7739 add_thread calls.
7740 (bsd_uthread_target::update_thread_list): Use
7741 as_process_stratum_target and adjust find_thread_ptid,
7742 thread_change_ptid and add_thread calls.
7743 * btrace.c (maint_btrace_packet_history_cmd): Adjust
7744 find_thread_ptid call.
7745 * corelow.c (add_to_thread_list): Adjust add_thread call.
7746 (core_target_open): Adjust add_thread_silent and thread_count
7747 calls.
7748 (core_target::pid_to_str): Adjust find_inferior_ptid call.
7749 * ctf.c (ctf_target_open): Adjust add_thread_silent call.
7750 * event-top.c (async_disconnect): Pop targets from all inferiors.
7751 * exec.c (add_target_sections): Push exec target on all inferiors
7752 sharing the program space.
7753 (remove_target_sections): Remove the exec target from all
7754 inferiors sharing the program space.
7755 (exec_on_vfork): New.
7756 * exec.h (exec_on_vfork): Declare.
7757 * fbsd-nat.c (fbsd_add_threads): Add fbsd_nat_target parameter.
7758 Pass it down.
7759 (fbsd_nat_target::update_thread_list): Adjust.
7760 (fbsd_nat_target::resume): Adjust.
7761 (fbsd_handle_debug_trap): Add fbsd_nat_target parameter. Pass it
7762 down.
7763 (fbsd_nat_target::wait, fbsd_nat_target::post_attach): Adjust.
7764 * fbsd-tdep.c (fbsd_corefile_thread): Adjust
7765 get_thread_arch_regcache call.
7766 * fork-child.c (gdb_startup_inferior): Pass target down to
7767 startup_inferior and set_executing.
7768 * gdbthread.h (struct process_stratum_target): Forward declare.
7769 (add_thread, add_thread_silent, add_thread_with_info)
7770 (in_thread_list): Add process_stratum_target parameter.
7771 (find_thread_ptid(inferior*, ptid_t)): New overload.
7772 (find_thread_ptid, thread_change_ptid): Add process_stratum_target
7773 parameter.
7774 (all_threads()): Delete overload.
7775 (all_threads, all_non_exited_threads): Add process_stratum_target
7776 parameter.
7777 (all_threads_safe): Use brace initialization.
7778 (thread_count): Add process_stratum_target parameter.
7779 (set_resumed, set_running, set_stop_requested, set_executing)
7780 (threads_are_executing, finish_thread_state): Add
7781 process_stratum_target parameter.
7782 (switch_to_thread): Use is_current_thread.
7783 * i386-fbsd-tdep.c: Include "inferior.h".
7784 (i386fbsd_get_thread_local_address): Pass down target.
7785 * i386-linux-nat.c (i386_linux_nat_target::low_resume): Adjust.
7786 * inf-child.c (inf_child_target::maybe_unpush_target): Remove
7787 have_inferiors check.
7788 * inf-ptrace.c (inf_ptrace_target::create_inferior)
7789 (inf_ptrace_target::attach): Adjust.
7790 * infcall.c (run_inferior_call): Adjust.
7791 * infcmd.c (run_command_1): Pass target to
7792 scoped_finish_thread_state.
7793 (proceed_thread_callback): Skip inferiors with no execution.
7794 (continue_command): Rename 'all_threads' local to avoid hiding
7795 'all_threads' function. Adjust get_last_target_status call.
7796 (prepare_one_step): Adjust set_running call.
7797 (signal_command): Use user_visible_resume_target. Compare thread
7798 pointers instead of inferior_ptid.
7799 (info_program_command): Adjust to pass down target.
7800 (attach_command): Mark target's 'thread_executing' flag.
7801 (stop_current_target_threads_ns): New, factored out from ...
7802 (interrupt_target_1): ... this. Switch inferior before making
7803 target calls.
7804 * inferior-iter.h
7805 (struct all_inferiors_iterator, struct all_inferiors_range)
7806 (struct all_inferiors_safe_range)
7807 (struct all_non_exited_inferiors_range): Filter on
7808 process_stratum_target too. Remove explicit.
7809 * inferior.c (inferior::inferior): Push dummy target on target
7810 stack.
7811 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors):
7812 Add process_stratum_target parameter, and pass it down.
7813 (have_live_inferiors): Adjust.
7814 (switch_to_inferior_and_push_target): New.
7815 (add_inferior_command, clone_inferior_command): Handle
7816 "-no-connection" parameter. Use
7817 switch_to_inferior_and_push_target.
7818 (_initialize_inferior): Mention "-no-connection" option in
7819 the help of "add-inferior" and "clone-inferior" commands.
7820 * inferior.h: Include "process-stratum-target.h".
7821 (interrupt_target_1): Use bool.
7822 (struct inferior) <push_target, unpush_target, target_is_pushed,
7823 find_target_beneath, top_target, process_target, target_at,
7824 m_stack>: New.
7825 (discard_all_inferiors): Delete.
7826 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors)
7827 (all_inferiors, all_non_exited_inferiors): Add
7828 process_stratum_target parameter.
7829 * infrun.c: Include "gdb_select.h" and <unordered_map>.
7830 (target_last_proc_target): New global.
7831 (follow_fork_inferior): Push target on new inferior. Pass target
7832 to add_thread_silent. Call exec_on_vfork. Handle target's
7833 reference count.
7834 (follow_fork): Adjust get_last_target_status call. Also consider
7835 target.
7836 (follow_exec): Push target on new inferior.
7837 (struct execution_control_state) <target>: New field.
7838 (user_visible_resume_target): New.
7839 (do_target_resume): Call target_async.
7840 (resume_1): Set target's threads_executing flag. Consider resume
7841 target.
7842 (commit_resume_all_targets): New.
7843 (proceed): Also consider resume target. Skip threads of inferiors
7844 with no execution. Commit resumtion in all targets.
7845 (start_remote): Pass current inferior to wait_for_inferior.
7846 (infrun_thread_stop_requested): Consider target as well. Pass
7847 thread_info pointer to clear_inline_frame_state instead of ptid.
7848 (infrun_thread_thread_exit): Consider target as well.
7849 (random_pending_event_thread): New inferior parameter. Use it.
7850 (do_target_wait): Rename to ...
7851 (do_target_wait_1): ... this. Add inferior parameter, and pass it
7852 down.
7853 (threads_are_resumed_pending_p, do_target_wait): New.
7854 (prepare_for_detach): Adjust calls.
7855 (wait_for_inferior): New inferior parameter. Handle it. Use
7856 do_target_wait_1 instead of do_target_wait.
7857 (fetch_inferior_event): Adjust. Switch to representative
7858 inferior. Pass target down.
7859 (set_last_target_status): Add process_stratum_target parameter.
7860 Save target in global.
7861 (get_last_target_status): Add process_stratum_target parameter and
7862 handle it.
7863 (nullify_last_target_wait_ptid): Clear 'target_last_proc_target'.
7864 (context_switch): Check inferior_ptid == null_ptid before calling
7865 inferior_thread().
7866 (get_inferior_stop_soon): Pass down target.
7867 (wait_one): Rename to ...
7868 (poll_one_curr_target): ... this.
7869 (struct wait_one_event): New.
7870 (wait_one): New.
7871 (stop_all_threads): Adjust.
7872 (handle_no_resumed, handle_inferior_event): Adjust to consider the
7873 event's target.
7874 (switch_back_to_stepped_thread): Also consider target.
7875 (print_stop_event): Update.
7876 (normal_stop): Update. Also consider the resume target.
7877 * infrun.h (wait_for_inferior): Remove declaration.
7878 (user_visible_resume_target): New declaration.
7879 (get_last_target_status, set_last_target_status): New
7880 process_stratum_target parameter.
7881 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
7882 process_stratum_target parameter, and use it.
7883 (clear_inline_frame_state (thread_info*)): New.
7884 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
7885 process_stratum_target parameter.
7886 (clear_inline_frame_state (thread_info*)): Declare.
7887 * linux-fork.c (delete_checkpoint_command): Pass target down to
7888 find_thread_ptid.
7889 (checkpoint_command): Adjust.
7890 * linux-nat.c (linux_nat_target::follow_fork): Switch to thread
7891 instead of just tweaking inferior_ptid.
7892 (linux_nat_switch_fork): Pass target down to thread_change_ptid.
7893 (exit_lwp): Pass target down to find_thread_ptid.
7894 (attach_proc_task_lwp_callback): Pass target down to
7895 add_thread/set_running/set_executing.
7896 (linux_nat_target::attach): Pass target down to
7897 thread_change_ptid.
7898 (get_detach_signal): Pass target down to find_thread_ptid.
7899 Consider last target status's target.
7900 (linux_resume_one_lwp_throw, resume_lwp)
7901 (linux_handle_syscall_trap, linux_handle_extended_wait, wait_lwp)
7902 (stop_wait_callback, save_stop_reason, linux_nat_filter_event)
7903 (linux_nat_wait_1, resume_stopped_resumed_lwps): Pass target down.
7904 (linux_nat_target::async_wait_fd): New.
7905 (linux_nat_stop_lwp, linux_nat_target::thread_address_space): Pass
7906 target down.
7907 * linux-nat.h (linux_nat_target::async_wait_fd): Declare.
7908 * linux-tdep.c (get_thread_arch_regcache): Pass target down.
7909 * linux-thread-db.c (struct thread_db_info::process_target): New
7910 field.
7911 (add_thread_db_info): Save target.
7912 (get_thread_db_info): New process_stratum_target parameter. Also
7913 match target.
7914 (delete_thread_db_info): New process_stratum_target parameter.
7915 Also match target.
7916 (thread_from_lwp): Adjust to pass down target.
7917 (thread_db_notice_clone): Pass down target.
7918 (check_thread_db_callback): Pass down target.
7919 (try_thread_db_load_1): Always push the thread_db target.
7920 (try_thread_db_load, record_thread): Pass target down.
7921 (thread_db_target::detach): Pass target down. Always unpush the
7922 thread_db target.
7923 (thread_db_target::wait, thread_db_target::mourn_inferior): Pass
7924 target down. Always unpush the thread_db target.
7925 (find_new_threads_callback, thread_db_find_new_threads_2)
7926 (thread_db_target::update_thread_list): Pass target down.
7927 (thread_db_target::pid_to_str): Pass current inferior down.
7928 (thread_db_target::get_thread_local_address): Pass target down.
7929 (thread_db_target::resume, maintenance_check_libthread_db): Pass
7930 target down.
7931 * nto-procfs.c (nto_procfs_target::update_thread_list): Adjust.
7932 * procfs.c (procfs_target::procfs_init_inferior): Declare.
7933 (proc_set_current_signal, do_attach, procfs_target::wait): Adjust.
7934 (procfs_init_inferior): Rename to ...
7935 (procfs_target::procfs_init_inferior): ... this and adjust.
7936 (procfs_target::create_inferior, procfs_notice_thread)
7937 (procfs_do_thread_registers): Adjust.
7938 * ppc-fbsd-tdep.c: Include "inferior.h".
7939 (ppcfbsd_get_thread_local_address): Pass down target.
7940 * proc-service.c (ps_xfer_memory): Switch current inferior and
7941 program space as well.
7942 (get_ps_regcache): Pass target down.
7943 * process-stratum-target.c
7944 (process_stratum_target::thread_address_space)
7945 (process_stratum_target::thread_architecture): Pass target down.
7946 * process-stratum-target.h
7947 (process_stratum_target::threads_executing): New field.
7948 (as_process_stratum_target): New.
7949 * ravenscar-thread.c
7950 (ravenscar_thread_target::update_inferior_ptid): Pass target down.
7951 (ravenscar_thread_target::wait, ravenscar_add_thread): Pass target
7952 down.
7953 * record-btrace.c (record_btrace_target::info_record): Adjust.
7954 (record_btrace_target::record_method)
7955 (record_btrace_target::record_is_replaying)
7956 (record_btrace_target::fetch_registers)
7957 (get_thread_current_frame_id, record_btrace_target::resume)
7958 (record_btrace_target::wait, record_btrace_target::stop): Pass
7959 target down.
7960 * record-full.c (record_full_wait_1): Switch to event thread.
7961 Pass target down.
7962 * regcache.c (regcache::regcache)
7963 (get_thread_arch_aspace_regcache, get_thread_arch_regcache): Add
7964 process_stratum_target parameter and handle it.
7965 (current_thread_target): New global.
7966 (get_thread_regcache): Add process_stratum_target parameter and
7967 handle it. Switch inferior before calling target method.
7968 (get_thread_regcache): Pass target down.
7969 (get_thread_regcache_for_ptid): Pass target down.
7970 (registers_changed_ptid): Add process_stratum_target parameter and
7971 handle it.
7972 (registers_changed_thread, registers_changed): Pass target down.
7973 (test_get_thread_arch_aspace_regcache): New.
7974 (current_regcache_test): Define a couple local test_target_ops
7975 instances and use them for testing.
7976 (readwrite_regcache): Pass process_stratum_target parameter.
7977 (cooked_read_test, cooked_write_test): Pass mock_target down.
7978 * regcache.h (get_thread_regcache, get_thread_arch_regcache)
7979 (get_thread_arch_aspace_regcache): Add process_stratum_target
7980 parameter.
7981 (regcache::target): New method.
7982 (regcache::regcache, regcache::get_thread_arch_aspace_regcache)
7983 (regcache::registers_changed_ptid): Add process_stratum_target
7984 parameter.
7985 (regcache::m_target): New field.
7986 (registers_changed_ptid): Add process_stratum_target parameter.
7987 * remote.c (remote_state::supports_vCont_probed): New field.
7988 (remote_target::async_wait_fd): New method.
7989 (remote_unpush_and_throw): Add remote_target parameter.
7990 (get_current_remote_target): Adjust.
7991 (remote_target::remote_add_inferior): Push target.
7992 (remote_target::remote_add_thread)
7993 (remote_target::remote_notice_new_inferior)
7994 (get_remote_thread_info): Pass target down.
7995 (remote_target::update_thread_list): Skip threads of inferiors
7996 bound to other targets. (remote_target::close): Don't discard
7997 inferiors. (remote_target::add_current_inferior_and_thread)
7998 (remote_target::process_initial_stop_replies)
7999 (remote_target::start_remote)
8000 (remote_target::remote_serial_quit_handler): Pass down target.
8001 (remote_target::remote_unpush_target): New remote_target
8002 parameter. Unpush the target from all inferiors.
8003 (remote_target::remote_unpush_and_throw): New remote_target
8004 parameter. Pass it down.
8005 (remote_target::open_1): Check whether the current inferior has
8006 execution instead of checking whether any inferior is live. Pass
8007 target down.
8008 (remote_target::remote_detach_1): Pass down target. Use
8009 remote_unpush_target.
8010 (extended_remote_target::attach): Pass down target.
8011 (remote_target::remote_vcont_probe): Set supports_vCont_probed.
8012 (remote_target::append_resumption): Pass down target.
8013 (remote_target::append_pending_thread_resumptions)
8014 (remote_target::remote_resume_with_hc, remote_target::resume)
8015 (remote_target::commit_resume): Pass down target.
8016 (remote_target::remote_stop_ns): Check supports_vCont_probed.
8017 (remote_target::interrupt_query)
8018 (remote_target::remove_new_fork_children)
8019 (remote_target::check_pending_events_prevent_wildcard_vcont)
8020 (remote_target::remote_parse_stop_reply)
8021 (remote_target::process_stop_reply): Pass down target.
8022 (first_remote_resumed_thread): New remote_target parameter. Pass
8023 it down.
8024 (remote_target::wait_as): Pass down target.
8025 (unpush_and_perror): New remote_target parameter. Pass it down.
8026 (remote_target::readchar, remote_target::remote_serial_write)
8027 (remote_target::getpkt_or_notif_sane_1)
8028 (remote_target::kill_new_fork_children, remote_target::kill): Pass
8029 down target.
8030 (remote_target::mourn_inferior): Pass down target. Use
8031 remote_unpush_target.
8032 (remote_target::core_of_thread)
8033 (remote_target::remote_btrace_maybe_reopen): Pass down target.
8034 (remote_target::pid_to_exec_file)
8035 (remote_target::thread_handle_to_thread_info): Pass down target.
8036 (remote_target::async_wait_fd): New.
8037 * riscv-fbsd-tdep.c: Include "inferior.h".
8038 (riscv_fbsd_get_thread_local_address): Pass down target.
8039 * sol2-tdep.c (sol2_core_pid_to_str): Pass down target.
8040 * sol-thread.c (sol_thread_target::wait, ps_lgetregs, ps_lsetregs)
8041 (ps_lgetfpregs, ps_lsetfpregs, sol_update_thread_list_callback):
8042 Adjust.
8043 * solib-spu.c (spu_skip_standalone_loader): Pass down target.
8044 * solib-svr4.c (enable_break): Pass down target.
8045 * spu-multiarch.c (parse_spufs_run): Pass down target.
8046 * spu-tdep.c (spu2ppu_sniffer): Pass down target.
8047 * target-delegates.c: Regenerate.
8048 * target.c (g_target_stack): Delete.
8049 (current_top_target): Return the current inferior's top target.
8050 (target_has_execution_1): Refer to the passed-in inferior's top
8051 target.
8052 (target_supports_terminal_ours): Check whether the initial
8053 inferior was already created.
8054 (decref_target): New.
8055 (target_stack::push): Incref/decref the target.
8056 (push_target, push_target, unpush_target): Adjust.
8057 (target_stack::unpush): Defref target.
8058 (target_is_pushed): Return bool. Adjust to refer to the current
8059 inferior's target stack.
8060 (dispose_inferior): Delete, and inline parts ...
8061 (target_preopen): ... here. Only dispose of the current inferior.
8062 (target_detach): Hold strong target reference while detaching.
8063 Pass target down.
8064 (target_thread_name): Add assertion.
8065 (target_resume): Pass down target.
8066 (target_ops::beneath, find_target_at): Adjust to refer to the
8067 current inferior's target stack.
8068 (get_dummy_target): New.
8069 (target_pass_ctrlc): Pass the Ctrl-C to the first inferior that
8070 has a thread running.
8071 (initialize_targets): Rename to ...
8072 (_initialize_target): ... this.
8073 * target.h: Include "gdbsupport/refcounted-object.h".
8074 (struct target_ops): Inherit refcounted_object.
8075 (target_ops::shortname, target_ops::longname): Make const.
8076 (target_ops::async_wait_fd): New method.
8077 (decref_target): Declare.
8078 (struct target_ops_ref_policy): New.
8079 (target_ops_ref): New typedef.
8080 (get_dummy_target): Declare function.
8081 (target_is_pushed): Return bool.
8082 * thread-iter.c (all_matching_threads_iterator::m_inf_matches)
8083 (all_matching_threads_iterator::all_matching_threads_iterator):
8084 Handle filter target.
8085 * thread-iter.h (struct all_matching_threads_iterator, struct
8086 all_matching_threads_range, class all_non_exited_threads_range):
8087 Filter by target too. Remove explicit.
8088 * thread.c (threads_executing): Delete.
8089 (inferior_thread): Pass down current inferior.
8090 (clear_thread_inferior_resources): Pass down thread pointer
8091 instead of ptid_t.
8092 (add_thread_silent, add_thread_with_info, add_thread): Add
8093 process_stratum_target parameter. Use it for thread and inferior
8094 searches.
8095 (is_current_thread): New.
8096 (thread_info::deletable): Use it.
8097 (find_thread_ptid, thread_count, in_thread_list)
8098 (thread_change_ptid, set_resumed, set_running): New
8099 process_stratum_target parameter. Pass it down.
8100 (set_executing): New process_stratum_target parameter. Pass it
8101 down. Adjust reference to 'threads_executing'.
8102 (threads_are_executing): New process_stratum_target parameter.
8103 Adjust reference to 'threads_executing'.
8104 (set_stop_requested, finish_thread_state): New
8105 process_stratum_target parameter. Pass it down.
8106 (switch_to_thread): Also match inferior.
8107 (switch_to_thread): New process_stratum_target parameter. Pass it
8108 down.
8109 (update_threads_executing): Reimplement.
8110 * top.c (quit_force): Pop targets from all inferior.
8111 (gdb_init): Don't call initialize_targets.
8112 * windows-nat.c (windows_nat_target) <get_windows_debug_event>:
8113 Declare.
8114 (windows_add_thread, windows_delete_thread): Adjust.
8115 (get_windows_debug_event): Rename to ...
8116 (windows_nat_target::get_windows_debug_event): ... this. Adjust.
8117 * tracefile-tfile.c (tfile_target_open): Pass down target.
8118 * gdbsupport/common-gdbthread.h (struct process_stratum_target):
8119 Forward declare.
8120 (switch_to_thread): Add process_stratum_target parameter.
8121 * mi/mi-interp.c (mi_on_resume_1): Add process_stratum_target
8122 parameter. Use it.
8123 (mi_on_resume): Pass target down.
8124 * nat/fork-inferior.c (startup_inferior): Add
8125 process_stratum_target parameter. Pass it down.
8126 * nat/fork-inferior.h (startup_inferior): Add
8127 process_stratum_target parameter.
8128 * python/py-threadevent.c (py_get_event_thread): Pass target down.
8129
8130 2020-01-10 Pedro Alves <palves@redhat.com>
8131
8132 * remote.c (remote_target::start_remote): Don't set inferior_ptid
8133 directly. Instead find the first thread in the thread list and
8134 use switch_to_thread.
8135
8136 2020-01-10 Pedro Alves <palves@redhat.com>
8137
8138 * remote.c (remote_target::remote_add_inferior): Don't bind a
8139 process to the current inferior if the current inferior is already
8140 bound to a process.
8141
8142 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
8143 Pedro Alves <palves@redhat.com>
8144
8145 * remote.c (remote_target::remote_parse_stop_reply) <W/X packets>:
8146 If no process is specified, return null_ptid instead of
8147 inferior_ptid.
8148 (remote_target::wait_as): Handle TARGET_WAITKIND_EXITED /
8149 TARGET_WAITKIND_SIGNALLED with no pid.
8150
8151 2020-01-10 Pedro Alves <palves@redhat.com>
8152
8153 * remote.c (first_remote_resumed_thread): New.
8154 (remote_target::wait_as): Use it as default event_ptid instead of
8155 inferior_ptid.
8156
8157 2020-01-10 Pedro Alves <palves@redhat.com>
8158
8159 * infrun.c (handle_no_resumed): Use all_non_exited_inferiors.
8160
8161 2020-01-10 Pedro Alves <palves@redhat.com>
8162
8163 * tracefile-tfile.c (tfile_target::close): Assert that trace_fd is
8164 not -1.
8165
8166 2020-01-10 Pedro Alves <palves@redhat.com>
8167
8168 * break-catch-sig.c (signal_catchpoint_print_it): Don't pass a
8169 ptid to get_last_target_status.
8170 * break-catch-syscall.c (print_it_catch_syscall): Don't pass a
8171 ptid to get_last_target_status.
8172 * infcmd.c (continue_command): Don't pass a target_waitstatus to
8173 get_last_target_status.
8174 (info_program_command): Don't pass a target_waitstatus to
8175 get_last_target_status.
8176 * infrun.c (init_wait_for_inferior): Use
8177 nullify_last_target_wait_ptid.
8178 (get_last_target_status): Handle nullptr arguments.
8179 (nullify_last_target_wait_ptid): Clear target_last_waitstatus.
8180 (print_stop_event): Don't pass a ptid to get_last_target_status.
8181 (normal_stop): Don't pass a ptid to get_last_target_status.
8182 * infrun.h (get_last_target_status, set_last_target_status): Move
8183 comments here and update.
8184 (nullify_last_target_wait_ptid): Declare.
8185 * linux-fork.c (fork_load_infrun_state): Remove local extern
8186 declaration of nullify_last_target_wait_ptid.
8187 * linux-nat.c (get_detach_signal): Don't pass a target_waitstatus
8188 to get_last_target_status.
8189
8190 2020-01-10 Pedro Alves <palves@redhat.com>
8191
8192 * gdbthread.h (scoped_restore_current_thread)
8193 <dont_restore, restore, m_dont_restore>: Declare.
8194 * thread.c (thread_alive): Add assertion. Return bool.
8195 (switch_to_thread_if_alive): New.
8196 (prune_threads): Switch inferior/thread.
8197 (print_thread_info_1): Switch thread before calling target methods.
8198 (scoped_restore_current_thread::restore): New, factored out from
8199 ...
8200 (scoped_restore_current_thread::~scoped_restore_current_thread):
8201 ... this.
8202 (scoped_restore_current_thread::scoped_restore_current_thread):
8203 Add assertion.
8204 (thread_apply_all_command, thread_select): Use
8205 switch_to_thread_if_alive.
8206 * infrun.c (proceed, restart_threads, handle_signal_stop)
8207 (switch_back_to_stepped_thread): Switch current thread before
8208 calling target methods.
8209
8210 2020-01-10 Pedro Alves <palves@redhat.com>
8211
8212 * inferior.c (switch_to_inferior_no_thread): New function,
8213 factored out from ...
8214 (inferior_command): ... here.
8215 * inferior.h (switch_to_inferior_no_thread): Declare.
8216 * mi/mi-main.c (run_one_inferior): Use
8217 switch_to_inferior_no_thread.
8218
8219 2020-01-10 Pedro Alves <palves@redhat.com>
8220
8221 * infcmd.c (kill_command): Remove dead code.
8222
8223 2020-01-10 Pedro Alves <palves@redhat.com>
8224
8225 * remote.c (remote_target::mourn_inferior): No longer check
8226 whether the target is running.
8227
8228 2020-01-10 Pedro Alves <palves@redhat.com>
8229
8230 * corelow.c (core_target::has_execution): Change parameter type to
8231 inferior pointer.
8232 * inferior.c (number_of_live_inferiors): Use
8233 inferior::has_execution instead of target_has_execution_1.
8234 * inferior.h (inferior::has_execution): New.
8235 * linux-thread-db.c (thread_db_target::update_thread_list): Use
8236 inferior::has_execution instead of target_has_execution_1.
8237 * process-stratum-target.c
8238 (process_stratum_target::has_execution): Change parameter type to
8239 inferior pointer. Check the inferior's PID instead of
8240 inferior_ptid.
8241 * process-stratum-target.h
8242 (process_stratum_target::has_execution): Change parameter type to
8243 inferior pointer.
8244 * record-full.c (record_full_core_target::has_execution): Change
8245 parameter type to inferior pointer.
8246 * target.c (target_has_execution_1): Change parameter type to
8247 inferior pointer.
8248 (target_has_execution_current): Adjust.
8249 * target.h (target_ops::has_execution): Change parameter type to
8250 inferior pointer.
8251 (target_has_execution_1): Change parameter type to inferior
8252 pointer. Change return type to bool.
8253 * tracefile.h (tracefile_target::has_execution): Change parameter
8254 type to inferior pointer.
8255
8256 2020-01-10 Pedro Alves <palves@redhat.com>
8257
8258 * exceptions.c (print_flush): Remove current_top_target() check.
8259
8260 2020-01-10 Pedro Alves <palves@redhat.com>
8261
8262 * remote.c (show_remote_exec_file): Show the current inferior's
8263 exec-file instead of the command variable's value.
8264
8265 2020-01-10 Pedro Alves <palves@redhat.com>
8266
8267 * record-full.c (record_full_resume_ptid): New global.
8268 (record_full_target::resume): Set it.
8269 (record_full_wait_1): Use record_full_resume_ptid instead of
8270 inferior_ptid.
8271
8272 2020-01-10 Pedro Alves <palves@redhat.com>
8273
8274 * gdbthread.h (scoped_restore_current_thread)
8275 <dont_restore, restore, m_dont_restore>: Declare.
8276 * thread.c (thread_alive): Add assertion. Return bool.
8277 (switch_to_thread_if_alive): New.
8278 (prune_threads): Switch inferior/thread.
8279 (print_thread_info_1): Switch thread before calling target methods.
8280 (scoped_restore_current_thread::restore): New, factored out from
8281 ...
8282 (scoped_restore_current_thread::~scoped_restore_current_thread):
8283 ... this.
8284 (scoped_restore_current_thread::scoped_restore_current_thread):
8285 Add assertion.
8286 (thread_apply_all_command, thread_select): Use
8287 switch_to_thread_if_alive.
8288
8289 2020-01-10 George Barrett <bob@bob131.so>
8290
8291 * stap-probe.c (stap_modify_semaphore): Don't check for null
8292 semaphores.
8293 (stap_probe::set_semaphore, stap_probe::clear_semaphore): Check
8294 for null semaphores.
8295
8296 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
8297
8298 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Update
8299 all source windows, and maintain horizontal scroll status while
8300 doing so.
8301
8302 2020-01-09 Tom Tromey <tom@tromey.com>
8303
8304 PR tui/18932:
8305 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Call
8306 update_source_window, not print_source_lines.
8307
8308 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
8309
8310 * tui/tui.c (tui_enable): Register tui hooks after calling
8311 tui_display_main.
8312
8313 2020-01-09 Christian Biesinger <cbiesinger@google.com>
8314
8315 * gdbsupport/common-defs.h: Don't define _FORTIFY_SOURCE on MinGW.
8316
8317 2020-01-08 Simon Marchi <simon.marchi@efficios.com>
8318
8319 * thread.c (print_thread_info_1): Fix indentation.
8320
8321 2020-01-09 Christian Biesinger <cbiesinger@google.com>
8322
8323 * symtab.c (general_symbol_info::compute_and_set_names): Move the
8324 unique_xmalloc_ptr outside the if to always free the demangled name.
8325
8326 2020-01-08 Tom Tromey <tromey@adacore.com>
8327
8328 * xcoffread.c (enter_line_range, read_xcoff_symtab)
8329 (process_xcoff_symbol, xcoff_symfile_offsets): Update.
8330 * symtab.h (MSYMBOL_VALUE_ADDRESS): Update.
8331 (struct section_offsets, ANOFFSET, SIZEOF_N_SECTION_OFFSETS):
8332 Remove.
8333 (section_offsets): New typedef.
8334 * symtab.c (fixup_section, get_msymbol_address): Update.
8335 * symmisc.c (dump_msymbols): Update.
8336 * symfile.h (relative_addr_info_to_section_offsets)
8337 (symfile_map_offsets_to_segments): Update.
8338 * symfile.c (build_section_addr_info_from_objfile)
8339 (init_objfile_sect_indices): Update.
8340 (struct place_section_arg): Change type of "offsets".
8341 (place_section): Update.
8342 (relative_addr_info_to_section_offsets): Change type of
8343 "section_offsets". Remove "num_sections" parameter.
8344 (default_symfile_offsets, syms_from_objfile_1)
8345 (set_objfile_default_section_offset): Update.
8346 (reread_symbols): No need to preserve section offsets by hand.
8347 (symfile_map_offsets_to_segments): Change type of "offsets".
8348 * stap-probe.c (relocate_address): Update.
8349 * stabsread.h (process_one_symbol): Update.
8350 * solib-target.c (struct lm_info_target) <offsets>: Change type.
8351 (solib_target_relocate_section_addresses): Update.
8352 * solib-svr4.c (enable_break, svr4_relocate_main_executable):
8353 Update.
8354 * solib-frv.c (frv_relocate_main_executable): Update.
8355 * solib-dsbt.c (dsbt_relocate_main_executable): Update.
8356 * solib-aix.c (solib_aix_get_section_offsets): Change return
8357 type.
8358 (solib_aix_solib_create_inferior_hook): Update.
8359 * remote.c (remote_target::get_offsets): Update.
8360 * psymtab.c (find_pc_sect_psymtab): Update.
8361 * psympriv.h (struct partial_symbol) <address, text_low,
8362 text_high>: Update.
8363 * objfiles.h (obj_section_offset): Update.
8364 (struct objfile) <section_offsets>: Change type.
8365 <num_sections>: Remove.
8366 (objfile_relocate): Update.
8367 * objfiles.c (entry_point_address_query): Update
8368 (relocate_one_symbol): Change type of "section_offsets".
8369 (objfile_relocate1, objfile_relocate1): Change type of
8370 "new_offsets".
8371 (objfile_rebase1): Update.
8372 * mipsread.c (mipscoff_symfile_read): Update.
8373 (read_alphacoff_dynamic_symtab): Remove "section_offsets"
8374 parameter.
8375 * mdebugread.c (parse_symbol): Change type of "section_offsets".
8376 (parse_external, psymtab_to_symtab_1): Update.
8377 * machoread.c (macho_symfile_offsets): Update.
8378 * ia64-tdep.c (ia64_find_unwind_table): Update.
8379 * hppa-tdep.c (read_unwind_info): Update.
8380 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Update.
8381 * dwarf2read.c (create_addrmap_from_index)
8382 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
8383 (process_psymtab_comp_unit_reader, add_partial_symbol)
8384 (add_partial_subprogram, process_full_comp_unit)
8385 (read_file_scope, read_func_scope, read_lexical_block_scope)
8386 (read_call_site_scope, dwarf2_rnglists_process)
8387 (dwarf2_ranges_process, dwarf2_ranges_read)
8388 (dwarf_decode_lines_1, var_decode_location, new_symbol)
8389 (dwarf2_fetch_die_loc_sect_off, dwarf2_per_cu_text_offset):
8390 Update.
8391 * dwarf2-frame.c (execute_cfa_program, dwarf2_frame_find_fde):
8392 Update.
8393 * dtrace-probe.c (dtrace_probe::get_relocated_address): Update.
8394 * dbxread.c (read_dbx_symtab, read_ofile_symtab): Update.
8395 (process_one_symbol): Change type of "section_offsets".
8396 * ctfread.c (get_objfile_text_range): Update.
8397 * coffread.c (coff_symtab_read, enter_linenos)
8398 (process_coff_symbol): Update.
8399 * coff-pe-read.c (add_pe_forwarded_sym): Update.
8400 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Update.
8401
8402 2020-01-08 Tom Tromey <tromey@adacore.com>
8403
8404 * dwarf2read.c (parse_macro_definition): Use std::string.
8405 (parse_macro_definition): Likewise.
8406
8407 2020-01-08 Tom Tromey <tromey@adacore.com>
8408
8409 * dwarf2read.c (abbrev_table_read_table): Use std::vector.
8410 (ATTR_ALLOC_CHUNK): Remove.
8411
8412 2020-01-08 Tom Tromey <tromey@adacore.com>
8413
8414 * dwarf2read.c (fixup_go_packaging): Use unique_xmalloc_ptr.
8415
8416 2020-01-08 Tom Tromey <tromey@adacore.com>
8417
8418 * dwarf2read.c (add_partial_symbol): Use unique_xmalloc_ptr.
8419 (dwarf2_compute_name, open_dwo_file): Likewise.
8420 (process_enumeration_scope): Use std::vector.
8421 (guess_partial_die_structure_name): Use unique_xmalloc_ptr.
8422 (partial_die_info::fixup, dwarf2_start_subfile)
8423 (guess_full_die_structure_name, dwarf2_name): Likewise.
8424 (determine_prefix): Update.
8425 (guess_full_die_structure_name): Make return type const.
8426 (partial_die_full_name): Return unique_xmalloc_ptr.
8427 (DW_FIELD_ALLOC_CHUNK): Remove.
8428
8429 2020-01-07 Tom Tromey <tromey@adacore.com>
8430
8431 PR build/24937:
8432 * stap-probe.c (class stap_static_probe_ops): Add constructor.
8433
8434 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
8435
8436 * cli/cli-style.c: Set cli_styling to 'true' in the Cygwin build.
8437
8438 2020-01-06 Andrew Burgess <andrew.burgess@embecosm.com>
8439
8440 * stack.c (print_frame_info): Move disassemble_next_line code
8441 inside source_print block.
8442
8443 2020-01-06 Eli Zaretskii <eliz@gnu.org>
8444
8445 * gdbsupport/gdb_wait.c: Include <signal.h> instead of
8446 gdb/signals.h, as we are now using native signal symbols.
8447
8448 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
8449
8450 * tui/tui-disasm.c (tui_disasm_window::addr_is_displayed): Avoid
8451 overflow by an early check of content vs threshold.
8452 * tui/tui-source.c (tui_source_window::line_is_displayed):
8453 Likewise.
8454
8455 2020-01-06 Eli Zaretskii <eliz@gnu.org>
8456
8457 * NEWS: Mention the recent fix of $_exitsignal on MS-Windows.
8458
8459 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
8460
8461 * coff-pe-read.c (read_pe_exported_syms): Don't try to read the
8462 export table if no section contains it's RVA.
8463
8464 2020-01-06 Eli Zaretskii <eliz@gnu.org>
8465
8466 * windows-tdep.c: Fix a typo in WINDOWS_SIGABRT.
8467
8468 2020-01-06 Hannes Domani <ssbssa@yahoo.de>
8469
8470 * source.c (print_source_lines_base): Set last_line_listed.
8471
8472 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
8473
8474 * tui/tui-disasm.c: Remove trailing spaces.
8475
8476 2020-01-06 Eli Zaretskii <eliz@gnu.org>
8477 Pedro Alves <palves@redhat.com>
8478
8479 * Makefile.in (COMMON_SFILES): Add gdbsupport/gdb_wait.c.
8480 * windows-tdep.c: New enumeration of WINDOWS_SIG* signals.
8481 (windows_gdb_signal_to_target): New function, uses the above
8482 enumeration to convert GDB internal signal codes to equivalent
8483 Windows codes.
8484 (windows_init_abi): Call set_gdbarch_gdb_signal_to_target.
8485 * windows-nat.c: Include "gdb_wait.h".
8486 (get_windows_debug_event): Extract the fatal exception from the
8487 exit status and convert to the equivalent Posix signal number.
8488 * cli/cli-cmds.c (exit_status_set_internal_vars): Account for the
8489 possibility that WTERMSIG returns GDB_SIGNAL_UNKNOWN.
8490 * gdbsupport/gdb_wait.c: New file, implements
8491 windows_status_to_termsig.
8492 * gdbsupport/gdb_wait.h (WIFEXITED, WIFSIGNALED, WEXITSTATUS)
8493 (WTERMSIG) [__MINGW32__]: Separate definitions for MinGW.
8494
8495 2020-01-05 Andrew Burgess <andrew.burgess@embecosm.com>
8496
8497 * tui/tui-layout.c (tui_add_win_to_layout): Use tui_set_layout not
8498 show_layout.
8499
8500 2020-01-05 Luis Machado <luis.machado@linaro.org>
8501
8502 * aarch64-linux-nat.c
8503 (aarch64_linux_nat_target::thread_architecture): Use bfd_arch_aarch64
8504 and bfd_mach_aarch64.
8505
8506 2020-01-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8507
8508 * ui-file.c (stdio_file::can_emit_style_escape)
8509 (tee_file::can_emit_style_escape): Ensure style is used also on
8510 gdb_stderr when gdb_stderr is a tty supporting styling, similarly
8511 to gdb_stdout.
8512 * main.c (set_gdb_data_directory): Use file style to output the
8513 warning that the given pathname is not a directory.
8514 * top.c (show_history_filename, gdb_safe_append_history)
8515 (show_gdb_datadir): Use file style.
8516
8517 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
8518
8519 * solib-target.c (struct lm_info_target):
8520 Change offsets to be a unique_xmalloc_ptr.
8521 (solib_target_relocate_section_addresses): Update.
8522
8523 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
8524
8525 * windows-nat.c (windows_clear_solib): Free so_list linked list.
8526
8527 2020-01-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
8528
8529 * MAINTAINERS (Write After Approval): Add myself.
8530
8531 2020-01-02 Luis Machado <luis.machado@linaro.org>
8532
8533 * proc-service.c (get_ps_regcache): Remove reference to obsolete
8534 Cell BE architecture.
8535 * target.h (struct target_ops) <thread_architecture>: Likewise.
8536
8537 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
8538
8539 * Makefile.in: Use INSTALL_PROGRAM_ENV.
8540
8541 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
8542
8543 * MAINTAINERS (Write After Approval): Add myself.
8544
8545 2020-01-01 Joel Brobecker <brobecker@adacore.com>
8546
8547 * gdbarch.sh: Update copyright year range of generated files.
8548
8549 2020-01-01 Joel Brobecker <brobecker@adacore.com>
8550
8551 Update copyright year range in all GDB files.
8552
8553 2020-01-01 Joel Brobecker <brobecker@adacore.com>
8554
8555 * copyright.py: Convert to Python 3.
8556
8557 2020-01-01 Joel Brobecker <brobecker@adacore.com>
8558
8559 * copyright.py: Adapt after move of gnulib directory from gdb
8560 directory to toplevel directory.
8561
8562 2020-01-01 Joel Brobecker <brobecker@adacore.com>
8563
8564 * copyright.py (main): Exit if run from the wrong directory.
8565
8566 2020-01-01 Joel Brobecker <brobecker@adacore.com>
8567
8568 * top.c (print_gdb_version): Change copyright year to 2020.
8569
8570 2020-01-01 Joel Brobecker <brobecker@adacore.com>
8571
8572 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2019.
8573
8574 For older changes see ChangeLog-2019.
8575 \f
8576 Local Variables:
8577 mode: change-log
8578 left-margin: 8
8579 fill-column: 74
8580 version-control: never
8581 coding: utf-8
8582 End:
This page took 0.209713 seconds and 4 git commands to generate.