]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - gdb/ChangeLog
gdb: remove NULL_TYPE
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
1 2020-08-31 Simon Marchi <simon.marchi@efficios.com>
2
3 * gdbtypes.h (NULL_TYPE): Remove, change all uses to nullptr.
4
5 2020-08-29 Pedro Alves <pedro@palves.net>
6
7 * progspace.c (print_program_space): Use all_inferiors. Switch to
8 the inferior before calling target_pid_to_str.
9
10 2020-08-28 Tom Tromey <tom@tromey.com>
11
12 * xcoffread.c (xcoff_end_psymtab): Update comment.
13 * dbxread.c (dbx_end_psymtab): Update comment.
14
15 2020-08-28 Tom de Vries <tdevries@suse.de>
16
17 PR breakpoint/26544
18 * breakpoint.c (parse_breakpoint_sals): Remove const from struct
19 event_location.
20 (create_breakpoint): Same.
21 (base_breakpoint_decode_location): Same.
22 (bkpt_create_sals_from_location): Same.
23 (bkpt_decode_location): Same.
24 (bkpt_probe_create_sals_from_location): Same.
25 (bkpt_probe_decode_location): Same.
26 (tracepoint_create_sals_from_location): Same.
27 (tracepoint_decode_location): Same.
28 (tracepoint_probe_decode_location): Same.
29 (strace_marker_create_sals_from_location): Same.
30 (strace_marker_decode_location): Same.
31 (create_sals_from_location_default): Same.
32 (decode_location_default): Same.
33 * breakpoint.h (struct breakpoint_ops): Same.
34 (create_breakpoint): Same.
35 * linespec.h (decode_line_full): Same.
36 * linespec.c (decode_line_full): Same. Throw error if
37 result.size () == 0.
38
39 2020-08-27 Pedro Alves <pedro@palves.net>
40
41 PR gdb/26524
42 * breakpoint.c (until_break_fsm) <location_breakpoint,
43 caller_breakpoint>: Delete fields.
44 <breakpoints>: New field.
45 <until_break_fsm>: Adjust to save a breakpoint vector instead of
46 two individual breakpoints.
47 (until_break_fsm::should_stop): Loop over breakpoints in the
48 breakpoint vector.
49 (until_break_fsm::clean_up): Adjust to clear the breakpoints
50 vector.
51 (until_break_command): Handle location expanding into multiple
52 sals.
53
54 2020-08-27 Pedro Alves <pedro@palves.net>
55
56 PR gdb/26523
57 * inline-frame.c (stopped_by_user_bp_inline_frame): Also consider
58 bp_until breakpoints user-specified locations. Update intro
59 comment.
60
61 2020-08-27 Simon Marchi <simon.marchi@polymtl.ca>
62
63 * gdb_bfd.h (gdb_bfd_section_iterator, gdb_bfd_section_range,
64 gdb_bfd_sections): New.
65 * maint.c (print_bfd_section_info): Change param type to
66 maint_print_section_data.
67 (print_objfile_section_info): Likewise.
68 (print_bfd_section_info_maybe_relocated): Likewise.
69 (maintenance_info_sections): Use gdb_bfd_sections.
70
71 2020-08-25 Shahab Vahedi <shahab@synopsys.com>
72
73 * MAINTAINERS: Add ARC target and maintainer.
74
75 2020-08-25 Anton Kolesov <anton.kolesov@synopsys.com>
76
77 * configure.tgt: ARC support for GNU/Linux.
78 * Makefile.in (ALL_TARGET_OBJS): Likewise.
79 * arc-linux-tdep.c: New file.
80 * arc-tdep.h (ARC_STATUS32_L_MASK, ARC_STATUS32_DE_MASK): Declare.
81 * arc-tdep.c (arc_write_pc): Use it.
82
83 2020-08-25 Shahab Vahedi <shahab@synopsys.com>
84
85 * arc-tdep.c (arc_check_for_hardware_loop): New.
86 * arc-tdep.h (gdbarch_tdep): New field has_hw_loops.
87
88 2020-08-25 Shahab Vahedi <shahab@synopsys.com>
89
90 * arc-tdep.h: Include "gdbarch.h".
91
92 2020-08-25 Shahab Vahedi <shahab@synopsys.com>
93
94 * arch/arc.h
95 (arc_gdbarch_features): New class to stir the selection of target XML.
96 (arc_create_target_description): Use FEATURES to choose XML target.
97 (arc_lookup_target_description): Use arc_create_target_description
98 to create _new_ target descriptions or return the already created
99 ones if the FEATURES is the same.
100 * arch/arc.c: Implementation of prototypes described above.
101 * gdb/arc-tdep.h (arc_regnum enum): Add more registers.
102 (arc_gdbarch_features_init): Initialize the FEATURES struct.
103 * arc-tdep.c (*_feature_name): Make feature names consistent.
104 (arc_register_feature): A new struct to hold information about
105 registers of a particular target/feature.
106 (arc_check_tdesc_feature): Check if XML provides registers in
107 compliance with ARC_REGISTER_FEATURE structs.
108 (arc_update_acc_reg_names): Add aliases for r58 and r59.
109 (determine_*_reg_feature_set): Which feature name to look for.
110 (arc_gdbarch_features_init): Given MACH and ABFD, initialize FEATURES.
111 (mach_type_to_arc_isa): Convert from a set of binutils machine types
112 to expected ISA enums to be used in arc_gdbarch_features structs.
113 * features/Makefile (FEATURE_XMLFILES): Add new files.
114 * gdb/features/arc/v1-aux.c: New file.
115 * gdb/features/arc/v1-aux.xml: Likewise.
116 * gdb/features/arc/v1-core.c: Likewise.
117 * gdb/features/arc/v1-core.xml: Likewise.
118 * gdb/features/arc/v2-aux.c: Likewise.
119 * gdb/features/arc/v2-aux.xml: Likewise.
120 * gdb/features/arc/v2-core.c: Likewise.
121 * gdb/features/arc/v2-core.xml: Likewise.
122 * NEWS (Changes since GDB 9): Announce obsolence of old feature names.
123
124 2020-08-25 Gaius Mulley <gaiusmod2@gmail.com>
125 Andrew Burgess <andrew.burgess@embecosm.com>
126
127 PR m2/26372
128 * m2-exp.y (exp): Improve comment for non_empty_arglist case, add
129 an assert. Remove single element array indexing pattern as the
130 MULTI_SUBSCRIPT support will handle this case too.
131
132 2020-08-24 Simon Marchi <simon.marchi@polymtl.ca>
133
134 * value.h (valprint_check_validity): Move declaration from
135 here...
136 * valprint.h (valprint_check_validity): ... to here.
137
138 2020-08-24 Simon Marchi <simon.marchi@efficios.com>
139
140 * debug.h: New file.
141 * debug.c (debug_prefixed_vprintf): New function.
142 * infrun.c (infrun_debug_printf_1): Use debug_prefixed_vprintf.
143 * linux-nat.c (linux_nat_debug_printf_1): Likewise.
144
145 2020-08-24 Simon Marchi <simon.marchi@efficios.com>
146
147 * infrun.h (infrun_debug_printf_1): New function declaration.
148 (infrun_debug_printf): New macro.
149 * infrun.c (infrun_debug_printf_1): Use infrun_debug_printf
150 throughout.
151 (infrun_debug_printf): New function.
152 * breakpoint.c (should_be_inserted): Use infrun_debug_printf.
153 (handle_jit_event): Likewise.
154
155 2020-08-21 Mark Wielaard <mark@klomp.org>
156
157 * ada-lex.l: Extend register warnings diagnostics comment for g++.
158
159 2020-08-22 Simon Marchi <simon.marchi@efficios.com>
160
161 * frame.c (enum class frame_id_status): New.
162 (struct frame_info) <this_id::p>: Change type to frame_id_status.
163 (fprintf_frame): Update.
164 (compute_frame_id): Set frame id status to "computing" on entry.
165 Set it back to "not_computed" on failure and to "computed" on
166 success.
167 (get_frame_id): Assert the frame id is not being computed.
168 (create_sentinel_frame): Use frame_id_status::COMPUTED.
169 (create_new_frame): Likewise.
170 (frame_cleanup_after_sniffer): Update assert.
171
172 2020-08-20 Simon Marchi <simon.marchi@polymtl.ca>
173
174 * regcache.c (pid_ptid_regcache_map): New type.
175 (target_ptid_regcache_map): Remove.
176 (target_pid_ptid_regcache_map): New type.
177 (regcaches): Change type to target_pid_ptid_regcache_map.
178 (get_thread_arch_aspace_regcache): Update.
179 (regcache_thread_ptid_changed): Update, handle pid-like ptid
180 case.
181 (regcaches_size): Update.
182 (regcache_count): Update.
183 (registers_changed_ptid_target_pid_test): New.
184 (_initialize_regcache): Register new test.
185
186 2020-08-20 Simon Marchi <simon.marchi@polymtl.ca>
187
188 * regcache.c (regcache_count): New.
189 (struct regcache_test_data): New.
190 (regcache_test_data_up): New.
191 (populate_regcaches_for_test): New.
192 (regcaches_test): Remove.
193 (get_thread_arch_aspace_regcache_test): New.
194 (registers_changed_ptid_all_test): New.
195 (registers_changed_ptid_target_test): New.
196 (registers_changed_ptid_target_ptid_test): New.
197 (regcache_thread_ptid_changed): Remove regcache_count lambda.
198 (_initialize_regcache): Register new tests.
199
200 2020-08-20 Simon Marchi <simon.marchi@polymtl.ca>
201
202 * regcache.c (test_get_thread_arch_aspace_regcache): Rename to...
203 (get_thread_arch_aspace_regcache_and_check): ... this. Remove
204 gdbarch and aspace parameter. Use current inferior's aspace.
205 Validate regcache's arch value.
206 (regcaches_test): Update.
207
208 2020-08-20 Simon Marchi <simon.marchi@polymtl.ca>
209
210 * regcache.c (regcaches_test): Call registers_changed.
211
212 2020-08-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
213
214 * infrun.c (process_event_stop_test): Fix typo "breapoint".
215
216 2020-08-19 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
217
218 * amd64-tdep.c (amd64_skip_prologue): Using symbol table
219 to find the end of prologue for flang compiled binaries.
220 * arm-tdep.c (arm_skip_prologue): Likewise.
221 * i386-tdep.c (i386_skip_prologue): Likewise.
222 * producer.c (producer_is_llvm): New function.
223 (producer_parsing_tests): Added new tests for clang/flang.
224 * producer.h (producer_is_llvm): New declaration.
225
226 2020-08-18 Simon Marchi <simon.marchi@efficios.com>
227
228 * linux-nat.c (linux_nat_debug_printf): New function.
229 (linux_nat_debug_printf_1): New macro. Use throughout the file.
230
231 2020-08-18 Aaron Merey <amerey@redhat.com>
232
233 * Makefile.in (DEBUGINFOD_CFLAGS, DEBUGINFOD_LIBS): New variables.
234 (INTERNAL_CFLAGS_BASE): Add DEBUGINFOD_CFLAGS.
235 (CLIBS): Add DEBUGINFOD_LIBS.
236
237 2020-08-17 Sergei Trofimovich <siarheit@google.com>
238
239 * ia64-linux-nat.c: Include "gdbarch.h" to declare used
240 'gdbarch_num_regs'.
241
242 2020-08-17 Tom Tromey <tromey@adacore.com>
243
244 * ada-varobj.c (ada_varobj_decode_var): Handle case where
245 ada_get_decoded_value returns NULL.
246
247 2020-08-17 Tom Tromey <tromey@adacore.com>
248
249 * python/py-inferior.c (infpy_search_memory): Use
250 gdb_py_object_from_ulongest.
251 * python/py-infevents.c (create_inferior_call_event_object)
252 (create_memory_changed_event_object): Use
253 gdb_py_object_from_ulongest.
254 * python/py-linetable.c (ltpy_entry_get_pc): Use
255 gdb_py_object_from_ulongest.
256
257 2020-08-17 Simon Marchi <simon.marchi@polymtl.ca>
258
259 * loc.c (class symbol_needs_eval_context): Fix indentation.
260
261 2020-08-17 Simon Marchi <simon.marchi@polymtl.ca>
262
263 * dwarf2/loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
264 bool.
265
266 2020-08-17 Tom de Vries <tdevries@suse.de>
267
268 PR gdb/26393
269 * gdbtypes.c (dump_dynamic_prop): New function.
270 (recursive_dump_type): Use dump_dynamic_prop for TYPE_CODE_RANGE.
271
272 2020-08-15 Tom de Vries <tdevries@suse.de>
273
274 PR backtrace/26390
275 * stack.c (print_frame_args): Temporarily set the selected
276 frame to FRAME while printing the frame's arguments.
277
278 2020-08-14 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
279
280 PR breakpoints/26385
281 * ppc-linux-nat.c (ppc_linux_nat_target::low_prepare_to_resume):
282 Always clear watchpoint with PTRACE_SET_DEBUGREG.
283
284 2020-08-14 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
285
286 * ppc-linux-nat.c (ppc_linux_dreg_interface::detect)
287 (ppc_linux_nat_target::low_prepare_to_resume): Use ptrace () < 0
288 and >= to check return value instead of == -1 and != -1.
289
290 2020-08-14 Simon Marchi <simon.marchi@polymtl.ca>
291
292 * utils.h (class gdb_argv) <as_array_view>: New method.
293 * utils.c (gdb_argv_as_array_view_test): New.
294 (_initialize_utils): Register selftest.
295 * maint.c (maintenance_selftest): Use the new method.
296
297 2020-08-13 Kamil Rytarowski <n54@gmx.com>
298
299 * target.h (supports_dumpcore, dumpcore): New
300 function declarations.
301 * target.c (supports_dumpcore, dumpcore): New
302 functions.
303 * target-delegates.c: Rebuild.
304 * gcore.c (gcore_command): Use target_supports_dumpcore ()
305 and target_dumpcore ().
306
307 2020-08-13 Aaron Merey <amerey@redhat.com>
308
309 * debuginfod-support.c: Replace global variables with user_data.
310
311 2020-08-13 Simon Marchi <simon.marchi@polymtl.ca>
312
313 * maint.c (maintenance_selftest): Split args and pass array_view
314 to run_tests.
315
316 2020-08-12 Luis Machado <luis.machado@linaro.org>
317
318 * value.c (check_type_length_before_alloc): Use ULONGEST to store a
319 type's length.
320 Use %s and pulongest to print the length.
321
322 2020-08-12 Pedro Alves <palves@redhat.com>
323
324 * NEWS: Move "Multi-target debugging support" item to the
325 "Changes since GDB 9" section.
326
327 2020-08-12 Pedro Alves <palves@redhat.com>
328
329 PR gdb/26336
330 * progspace.c (program_space::remove_objfile): Invalidate the
331 frame cache.
332
333 2020-08-11 Tom de Vries <tdevries@suse.de>
334
335 * MAINTAINERS: Mark ms1 as deleted.
336
337 2020-08-10 Luis Machado <luis.machado@linaro.org>
338
339 PR gdb/26310
340
341 * aarch64-tdep.c (aarch64_analyze_prologue): Track use of SP/FP and
342 act accordingly.
343 (aarch64_analyze_prologue_test): Add more unit tests to exercise
344 movz/str/stur/stp skipping behavior.
345
346 2020-08-10 Luis Machado <luis.machado@linaro.org>
347
348 * nat/aarch64-sve-linux-sigcontext.h (SVE_PT_REGS_OFFSET): Use
349 struct user_sve_header instead of struct sve_context.
350
351 2020-08-09 Simon Marchi <simon.marchi@polymtl.ca>
352
353 * read.h (dwarf2_fetch_die_loc_sect_off,
354 dwarf2_fetch_die_loc_cu_off): Replace function pointer +
355 `void *` parameter with function_view.
356 * read.c (dwarf2_fetch_die_loc_sect_off,
357 dwarf2_fetch_die_loc_cu_off): Likewise.
358 * loc.c (get_frame_pc_for_per_cu_dwarf_call): Remove.
359 (per_cu_dwarf_call): Adjust.
360 (get_frame_address_in_block_wrapper): Remove.
361 (indirect_synthetic_pointer): Adjust.
362 (get_ax_pc): Remove.
363 (dwarf2_compile_expr_to_ax): Adjust.
364
365 2020-08-08 Tom de Vries <tdevries@suse.de>
366
367 PR build/26344
368 * arch/riscv.c (riscv_lookup_target_description): Use an explicit
369 constructor.
370 * regcache.c (get_thread_arch_aspace_regcache): Same.
371
372 2020-08-07 Tom Tromey <tromey@adacore.com>
373
374 * ravenscar-thread.c
375 (ravenscar_thread_target::set_base_thread_from_ravenscar_task):
376 New method.
377 (ravenscar_thread_target::wait): Check
378 runtime_initialized.
379 (ravenscar_thread_target::prepare_to_store)
380 (ravenscar_thread_target::stopped_by_sw_breakpoint)
381 (ravenscar_thread_target::stopped_by_hw_breakpoint)
382 (ravenscar_thread_target::stopped_by_watchpoint)
383 (ravenscar_thread_target::stopped_data_address)
384 (ravenscar_thread_target::core_of_thread): Use
385 scoped_restore_current_thread and
386 set_base_thread_from_ravenscar_task.
387
388 2020-08-07 Tom Tromey <tromey@adacore.com>
389
390 * ravenscar-thread.c (update_thread_list): Set inferior_ptid.
391
392 2020-08-07 Tom Tromey <tromey@adacore.com>
393
394 * ravenscar-thread.c (ravenscar_thread_target::wait): Call
395 update_inferior_ptid before update_thread_list.
396 (temporarily_change_regcache_ptid): New class.
397 (ravenscar_thread_target::fetch_registers)
398 (ravenscar_thread_target::store_registers)
399 (ravenscar_thread_target::prepare_to_store): Use base thread when
400 forwarding operation.
401
402 2020-08-07 Tom Tromey <tromey@adacore.com>
403
404 * ravenscar-thread.c (ravenscar_thread_target::resume): Handle
405 "is_pid" case.
406
407 2020-08-07 Tom Tromey <tromey@adacore.com>
408
409 * ravenscar-thread.c (xfer_partial, enable_btrace, add_thread):
410 New methods.
411 (ravenscar_thread_target::get_thread_base_cpu): Check m_cpu_map
412 first.
413 (ravenscar_thread_target::add_thread): Rename from
414 ravenscar_add_thread.
415 (ravenscar_thread_target::update_thread_list): Use a lambda.
416 (ravenscar_thread_target::xfer_partial): New method.
417
418 2020-08-07 Tom Tromey <tromey@adacore.com>
419
420 * ada-lang.h (ada_task_list_iterator_ftype): Now a
421 gdb::function_view.
422 (iterate_over_live_ada_tasks): Change type of argument.
423 * ada-tasks.c (iterate_over_live_ada_tasks): Change type
424 of argument.
425
426 2020-08-07 Tom Tromey <tromey@adacore.com>
427
428 * ravenscar-thread.c (ravenscar_thread_target) <extra_thread_info>:
429 Remove.
430 (ravenscar_thread_target::extra_thread_info): Remove.
431 (ravenscar_thread_target::pid_to_str): Mention Ravenscar in result;
432 defer to target beneath for non-Ravenscar threads.
433
434 2020-08-07 Tom Tromey <tromey@adacore.com>
435
436 * ravenscar-thread.c (ravenscar_thread_target) <get_base_cpu,
437 get_base_thread_from_ravenscar_task>: Now methods.
438 <m_cpu_map>: New member.
439 (ravenscar_thread_target::get_thread_base_cpu): Rename from
440 ravenscar_get_thread_base_cpu. Check m_cpu_map.
441 (ravenscar_thread_target::task_is_currently_active): Update.
442 (ravenscar_thread_target::get_base_thread_from_ravenscar_task):
443 Now a method.
444 (ravenscar_thread_target::add_active_thread): Put initial thread
445 into the m_cpu_map.
446
447 2020-08-07 Tom Tromey <tromey@adacore.com>
448
449 * ravenscar-thread.c (ravenscar_thread_target::wait): Return
450 event_ptid.
451
452 2020-08-07 Tom Tromey <tromey@adacore.com>
453
454 * ravenscar-thread.c (ravenscar_thread_target::wait): Check
455 runtime_initialized.
456
457 2020-08-07 Tom Tromey <tromey@adacore.com>
458
459 * ravenscar-thread.c (ravenscar_thread_target): Don't call
460 add_active_thread.
461 (ravenscar_thread_target::add_active_thread): Now public.
462 (ravenscar_inferior_created): Call add_active_thread after pushing
463 the target.
464
465 2020-08-07 Simon Marchi <simon.marchi@polymtl.ca>
466
467 * regcache.c (ptid_regcache_map): New type.
468 (target_ptid_regcache_map): New type.
469 (regcaches): Change type to target_ptid_regcache_map.
470 (get_thread_arch_aspace_regcache): Update to regcaches' new
471 type.
472 (regcache_thread_ptid_changed): Likewise.
473 (registers_changed_ptid): Likewise.
474 (regcaches_size): Likewise.
475 (regcaches_test): Update.
476 (regcache_thread_ptid_changed): Update.
477 * regcache.h (regcache_up): New type.
478 * gdbsupport/ptid.h (hash_ptid): New struct.
479
480 2020-08-07 Simon Marchi <simon.marchi@efficios.com>
481
482 * observable.h (thread_ptid_changed): Add parameter
483 `process_stratum_target *`.
484 * infrun.c (infrun_thread_ptid_changed): Add parameter
485 `process_stratum_target *` and use it.
486 (selftests): New namespace.
487 (infrun_thread_ptid_changed): New function.
488 (_initialize_infrun): Register selftest.
489 * regcache.c (regcache_thread_ptid_changed): Add parameter
490 `process_stratum_target *` and use it.
491 (regcache_thread_ptid_changed): New function.
492 (_initialize_regcache): Register selftest.
493 * thread.c (thread_change_ptid): Pass target to
494 thread_ptid_changed observable.
495
496 2020-08-06 Caroline Tice <cmtice@google.com>
497
498 * dwarf2/read.c (struct dwo_file): Update comment on 'sections' field.
499 (struct dwp_sections): Update field comments. Add loclists and
500 rnglists fields.
501 (struct virtual_v2_dwo_sections): Rename struct to
502 'virtual_v2_or_v5_dwo_sections'; update comments at top of struct; add
503 size & offset fields for loclists and rnglists.
504 (struct dwp_hash_table): Add a 'v5' struct field to the union section.
505 (create_debug_type_hash_table): Add 'DW_UT_split_type' to the check for
506 skipping dummy type units.
507 (create_dwp_hash_table): Update the large comment above the function to
508 discuss Version 5 DWP files as well, with references. Update all the
509 version checks in the function to check for version 5 as well. Add new
510 section at the end to create dwp hash table for version 5.
511 (create_dwp_v2_section): Rename function to
512 'create_dwp_v2_or_v5_section'. Update function comment appropriately.
513 Add V5 to error message text.
514 (create_dwo_unit_in_dwp_v2): Change calls to create_dwp_v2_section
515 into calls to create_dwp_v2_or_v5_section.
516 (create_dwo_unit_in_dwp_v5): New function.
517 (lookup_dwo_unit_in_dwp): Update conditional statement to explicitly
518 check for version2; add else clause to handle version 5.
519 (open_and_init_dwo_file): Add code to check dwarf version & only call
520 create_debug_types_hash_table (with sections.types) if version is not 5;
521 else call create_debug_type_hash_table, with sections.info.
522 (dwarf2_locate_v2_dwp_sections): Update function comment to mention
523 version 5.
524 (dwarf2_locate_v5_dwp_sections): New function.
525 (open_and_init_dwp_file): Add else-if clause for version 5 to call
526 bfd_map_over_sections with dwarf2_locate_v5_dwp_sections.
527
528 2020-08-06 Simon Marchi <simon.marchi@efficios.com>
529
530 * regcache.h (class regcache): Remove friend
531 registers_changed_ptid.
532 <regcache_thread_ptid_changed>: Remove.
533 <regcaches>: Remove.
534 * regcache.c (regcache::regcaches): Rename to...
535 (regcaches): ... this. Make static.
536 (get_thread_arch_aspace_regcache): Update.
537 (regcache::regcache_thread_ptid_changed): Rename to...
538 (regcache_thread_ptid_changed): ... this. Update.
539 (class regcache_access): Remove.
540 (regcaches_test): Update.
541 (_initialize_regcache): Update.
542 * sparc64-tdep.c, dwarf2/index-write.c, record-btrace.c: Include
543 <forward_list>.
544
545 2020-08-06 Simon Marchi <simon.marchi@efficios.com>
546
547 * regcache.h (class regcache) <current_regcache>: Rename to...
548 <regcaches>: ... this. Move doc here.
549 * regcache.c (regcache::current_regcache) Rename to...
550 (regcache::regcaches): ... this. Move doc to header.
551 (get_thread_arch_aspace_regcache): Update.
552 (regcache::regcache_thread_ptid_changed): Update.
553 (registers_changed_ptid): Update.
554 (class regcache_access) <current_regcache_size>: Rename to...
555 <regcaches_size>: ... this.
556 (current_regcache_test): Rename to...
557 (regcaches_test): ... this.
558 (_initialize_regcache): Update.
559
560 2020-08-06 Victor Collod <vcollod@nvidia.com>
561
562 * amd64-tdep.c (amd64_analyze_prologue): Fix incorrect comment.
563
564 2020-08-05 Kevin Buettner <kevinb@redhat.com>
565
566 * corelow.c (core_target::build_file_mappings): Don't output
567 null pathname in warning.
568
569 2020-08-05 Simon Marchi <simon.marchi@polymtl.ca>
570
571 * gdb.dwarf2/clztest.exp, gdb.dwarf2/dw2-common-block.exp,
572 gdb.dwarf2/dw2-dup-frame.exp, gdb.dwarf2/dw2-reg-undefined.exp,
573 gdb.dwarf2/dw2-single-line-discriminators.exp,
574 dw2-undefined-ret-addr.exp: Pass nopie to compilation options.
575
576 2020-08-05 Tom Tromey <tromey@adacore.com>
577
578 PR rust/26197:
579 * dwarf2/read.c (alloc_rust_variant): Handle univariant case.
580 (quirk_rust_enum): Call alloc_rust_variant for univariant case.
581 Fix off-by-one and type size errors in ordinary case.
582
583 2020-08-05 Tom de Vries <tdevries@suse.de>
584
585 * gdbtypes.c (type_not_allocated, type_not_associated): Use
586 "prop->const_val () == 0" instead of "prop->const_val () != 0".
587
588 2020-08-04 Simon Marchi <simon.marchi@efficios.com>
589
590 * frame.h (frame_id_p): Return bool.
591 (frame_id_artificial_p): Return bool.
592 (frame_id_eq): Return bool.
593 (has_stack_frames): Return bool.
594 (get_selected_frame): Fix typo in comment.
595 (get_frame_pc_if_available): Return bool.
596 (get_frame_address_in_block_if_available): Return bool.
597 (get_frame_func_if_available): Return bool.
598 (read_frame_register_unsigned): Return bool.
599 (get_frame_register_bytes): Return bool.
600 (safe_frame_unwind_memory): Return bool.
601 (deprecated_frame_register_read): Return bool.
602 (frame_unwinder_is): Return bool.
603 * frame.c (struct frame_info) <prev_arch::p>: Change type to
604 bool.
605 <this_id::p>: Likewise.
606 <prev_p>: Likewise.
607 (frame_stash_add): Return bool.
608 (get_frame_id): Use bool.
609 (frame_id_build_special) Use bool.
610 (frame_id_build_unavailable_stack): Use bool.
611 (frame_id_build): Use bool.
612 (frame_id_p): Return bool, use true/false instead of 1/0.
613 (frame_id_artificial_p): Likewise.
614 (frame_id_eq): Likewise.
615 (frame_id_inner): Likewise.
616 (get_frame_func_if_available): Likewise.
617 (read_frame_register_unsigned): Likewise.
618 (deprecated_frame_register_read): Likewise.
619 (get_frame_register_bytes): Likewise.
620 (has_stack_frames): Likewise.
621 (inside_main_func): Likewise.
622 (inside_entry_func): Likewise.
623 (get_frame_pc_if_available): Likewise.
624 (get_frame_address_in_block_if_available): Likewise.
625 (frame_unwinder_is): Likewise.
626 (safe_frame_unwind_memory): Likewise.
627 (frame_unwind_arch): Likewise.
628
629 2020-08-04 Simon Marchi <simon.marchi@efficios.com>
630
631 * frame.c (frame_info) <prev_func> <p>: Rename to status, change
632 type to cached_copy_status.
633 (fprintf_frame): Adjust.
634 (get_frame_func_if_available): Adjust.
635 (frame_cleanup_after_sniffer): Adjust.
636
637 2020-08-04 Mark Wielaard <mark@klomp.org>
638
639 * MAINTAINERS (Write After Approval): Update email address.
640
641 2020-08-04 Simon Marchi <simon.marchi@polymtl.ca>
642
643 * gdbtypes.h (TYPE_DYN_PROP_ADDR): Remove, replace uses with
644 dynamic_prop::const_val.
645
646 2020-08-04 Simon Marchi <simon.marchi@polymtl.ca>
647
648 * gdbtypes.h (TYPE_DYN_PROP_KIND): Remove, replace uses with
649 dynamic_prop::kind.
650
651 2020-08-04 Simon Marchi <simon.marchi@polymtl.ca>
652
653 * gdbtypes.h (TYPE_DYN_PROP_BATON): Remove.
654
655 2020-08-04 Jose E. Marchesi <jose.marchesi@oracle.com>
656
657 * configure.tgt: Set gdb_sim for bpf-*-* targets.
658
659 2020-08-04 Weimin Pan <weimin.pan@oracle.com>
660 Jose E. Marchesi <jose.marchesi@oracle.com>
661
662 * configure.tgt: Add entry for bpf-*-*.
663 * Makefile.in (ALL_TARGET_OBS): Add bpf-tdep.o
664 (ALLDEPFILES): Add bpf-tdep.c.
665 * bpf-tdep.c: New file.
666 * MAINTAINERS: Add bpf target and maintainer.
667 * NEWS: Mention the support for the new target.
668
669 2020-08-04 Tom de Vries <tdevries@suse.de>
670
671 PR symtab/23270
672 * dwarf2/read.c (find_partial_die): Change internal error into Dwarf
673 Error.
674
675 2020-08-03 John Baldwin <jhb@FreeBSD.org>
676
677 * syscalls/freebsd.xml: Regenerate.
678
679 2020-08-03 John Baldwin <jhb@FreeBSD.org>
680
681 * syscalls/update-freebsd.sh: Fix usage and year range.
682
683 2020-08-03 Tom de Vries <tdevries@suse.de>
684
685 PR symtab/26333
686 * dwarf2/read.c (dwarf_decode_lines_1): Ignore
687 DW_LNE_lo_user/DW_LNE_hi_user range.
688
689 2020-07-30 Simon Marchi <simon.marchi@polymtl.ca>
690
691 PR ada/26318
692 * ada-lang.c (ada_modulus): Return 0 if property is not of const
693 kind.
694
695 2020-07-30 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
696
697 * breakpoint.c (set_breakpoint_condition): Do minor refactoring.
698
699 2020-07-30 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
700
701 * breakpoint.c (set_breakpoint_condition): Update the condition
702 expressions after checking that the input condition string parses
703 successfully and does not contain junk at the end.
704
705 2020-07-30 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
706
707 * breakpoint.c (set_breakpoint_condition): Update the
708 condition string after parsing the new condition successfully.
709
710 2020-07-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
711
712 * proc-api.c (_STRUCTURED_PROC): Don't define.
713 * proc-events.c: Likewise.
714 * proc-flags.c: Likewise.
715 * proc-why.c: Likewise.
716 * procfs.c: Likewise.
717
718 * Makefile.in (INTERNAL_CPPFLAGS): Add LARGEFILE_CPPFLAGS.
719 * configure, config.in: Regenerate.
720
721 2020-07-30 Tom de Vries <tdevries@suse.de>
722
723 PR build/26320
724 * ui-style.h (struct ui_file_style::color): Wrap m_value and
725 m_red/m_green/m_blue in a union.
726
727 2020-07-29 Tom de Vries <tdevries@suse.de>
728
729 PR tdep/26280
730 * s390-tdep.c (s390_displaced_step_fixup): Fix Wmaybe-uninitialized.
731
732 2020-07-28 Tom Tromey <tromey@adacore.com>
733
734 PR symtab/26270:
735 * symtab.h (find_pc_partial_function_sym): Declare.
736 * cli/cli-cmds.c (disassemble_command): Use
737 find_pc_partial_function_sym. Check asm_demangle.
738 * blockframe.c (cache_pc_function_sym): New global.
739 (cache_pc_function_name): Remove.
740 (clear_pc_function_cache): Update.
741 (find_pc_partial_function_sym): New function, from
742 find_pc_partial_function.
743 (find_pc_partial_function): Rewrite using
744 find_pc_partial_function_sym.
745
746 2020-07-28 Tom Tromey <tromey@adacore.com>
747
748 * cli/cli-cmds.c (_initialize_cli_cmds): Rearrange "disassemble"
749 help. Add usage.
750
751 2020-07-28 Tom Tromey <tromey@adacore.com>
752
753 * dwarf2/expr.c (dwarf_expr_context::execute_stack_op)
754 <DW_OP_GNU_variable_value>: Cast to address type.
755
756 2020-07-28 Kamil Rytarowski <n54@gmx.com>
757
758 * nbsd-nat.h (nbsd_nat_target::xfer_partial): New declaration.
759 * nbsd-nat.c (nbsd_nat_target::xfer_partial): New function.
760 * nbsd-tdep.c (nbsd_gdbarch_data_handle, struct nbsd_gdbarch_data)
761 (init_nbsd_gdbarch_data, get_nbsd_gdbarch_data)
762 (nbsd_get_siginfo_type): New.
763 (nbsd_init_abi): Install gdbarch "get_siginfo_type" method.
764 (_initialize_nbsd_tdep): New.
765
766 2020-07-28 H.J. Lu <hongjiu.lu@intel.com>
767
768 PR binutils/26301
769 * configure: Regenerated.
770
771 2020-07-28 H.J. Lu <hongjiu.lu@intel.com>
772
773 PR binutils/26301
774 * configure: Regenerated.
775
776 2020-07-28 Andrew Burgess <andrew.burgess@embecosm.com>
777
778 * python/py-frame.c: Remove 'user-regs.h' include.
779 (frapy_read_register): Rewrite to make use of
780 gdbpy_parse_register_id.
781 * python/py-registers.c (gdbpy_parse_register_id): New function,
782 moved here from python/py-unwind.c. Updated the return type, and
783 also accepts register descriptor objects.
784 * python/py-unwind.c: Remove 'user-regs.h' include.
785 (pyuw_parse_register_id): Moved to python/py-registers.c.
786 (unwind_infopy_add_saved_register): Update to use
787 gdbpy_parse_register_id.
788 (pending_framepy_read_register): Likewise.
789 * python/python-internal.h (gdbpy_parse_register_id): Declare.
790
791 2020-07-28 Andrew Burgess <andrew.burgess@embecosm.com>
792
793 * python/py-registers.c: Add 'user-regs.h' include.
794 (register_descriptor_iter_find): New function.
795 (register_descriptor_iterator_object_methods): New static global
796 methods array.
797 (register_descriptor_iterator_object_type): Add pointer to methods
798 array.
799
800 2020-07-27 John Baldwin <jhb@FreeBSD.org>
801
802 * fbsd-nat.h: Include <osreldate.h>. Define USE_SIGTRAP_SIGINFO
803 for all architectures on FreeBSD 11.3 and later.
804
805 2020-07-27 Tom Tromey <tromey@adacore.com>
806
807 * gcore.h (load_corefile): Don't declare.
808
809 2020-07-27 Tom de Vries <tdevries@suse.de>
810
811 * configure.ac: Fix sys/sockets.h -> sys/socket.h typo.
812 * config.in: Regenerate.
813 * configure: Regenerate.
814
815 2020-07-26 Eli Zaretskii <eliz@gnu.org>
816
817 * configure.ac (AC_CHECK_HEADERS): Check for sys/socket.h and
818 ws2tcpip.h. When checking whether socklen_t type is defined, use
819 ws2tcpip.h if it is available and sys/socket.h isn't.
820 * configure: Regenerate.
821 * config.in: Regenerate.
822
823 2020-07-25 Andrew Burgess <andrew.burgess@embecosm.com>
824
825 PR fortran/23051
826 PR fortran/26139
827 * valops.c (value_ind): Pass address to
828 readjust_indirect_value_type.
829 * value.c (readjust_indirect_value_type): Make parameter
830 non-const, and add extra address parameter. Resolve original type
831 before using it.
832 * value.h (readjust_indirect_value_type): Update function
833 signature and comment.
834
835 2020-07-25 Tom de Vries <tdevries@suse.de>
836
837 PR symtab/26243
838 * dwarf2/read.c (lnp_state_machine::record_line): Ignore zero line
839 entries.
840
841 2020-07-24 Aaron Merey <amerey@redhat.com>
842
843 * Makefile.in: Replace LIBDEBUGINFOD with DEBUGINFOD_LIBS.
844 * configure: Rebuild.
845
846 2020-07-23 Kevin Buettner <kevinb@redhat.com>
847
848 PR corefiles/26294
849 * corelow.c (_initialize_corelow): Add period to help text
850 for "maintenance print core-file-backed-mappings".
851
852 2020-07-23 Pedro Alves <pedro@palves.net>
853
854 * frame-unwind.c (frame_unwind_try_unwinder): On exception, don't
855 touch THIS_CACHE/THIS_FRAME if the frame cache was cleared
856 meanwhile.
857 * frame.c (frame_cache_generation, get_frame_cache_generation):
858 New.
859 (reinit_frame_cache): Increment FRAME_CACHE_GENERATION.
860 (get_prev_frame_if_no_cycle): On exception, don't touch
861 PREV_FRAME/THIS_FRAME if the frame cache was cleared meanwhile.
862 * frame.h (get_frame_cache_generation): Declare.
863
864 2020-07-23 Tom de Vries <tdevries@suse.de>
865
866 PR tui/26282
867 * tui/tui-winsource.h (struct tui_source_windows::tui_source_windows):
868 New default constructor.
869
870 2020-07-23 Andrew Burgess <andrew.burgess@embecosm.com>
871
872 * disasm.c (do_mixed_source_and_assembly_deprecated): Don't
873 exclude non-statement entries.
874
875 2020-07-22 Kevin Buettner <kevinb@redhat.com>
876
877 * NEWS (New commands): Mention new command
878 "maintenance print core-file-backed-mappings".
879
880 2020-07-22 Kevin Buettner <kevinb@redhat.com>
881
882 * corelow.c (gdbcmd.h): Include.
883 (core_target::info_proc_mappings): New method.
884 (get_current_core_target): New function.
885 (maintenance_print_core_file_backed_mappings): New function.
886 (_initialize_corelow): Add core-file-backed-mappings to
887 "maint print" commands.
888
889 2020-07-22 Kevin Buettner <kevinb@redhat.com>
890
891 * linux-tdep.c (dump_note_entry_p): New function.
892 (linux_dump_mapping_p_ftype): New typedef.
893 (linux_find_memory_regions_full): Add new parameter,
894 should_dump_mapping_p.
895 (linux_find_memory_regions): Adjust call to
896 linux_find_memory_regions_full.
897 (linux_make_mappings_core_file_notes): Use dump_note_entry_p in
898 call to linux_find_memory_regions_full.
899
900 2020-07-22 Kevin Buettner <kevinb@redhat.com>
901
902 * corelow.c (solist.h, unordered_map): Include.
903 (class core_target): Add field m_core_file_mappings and
904 method build_file_mappings.
905 (core_target::core_target): Call build_file_mappings.
906 (core_target::~core_target): Free memory associated with
907 m_core_file_mappings.
908 (core_target::build_file_mappings): New method.
909 (core_target::xfer_partial): Use m_core_file_mappings
910 for memory transfers.
911 * linux-tdep.c (linux_read_core_file_mappings): New
912 function.
913 (linux_core_info_proc_mappings): Rewrite to use
914 linux_read_core_file_mappings.
915 (linux_init_abi): Register linux_read_core_file_mappings.
916
917 2020-07-22 Kevin Buettner <kevinb@redhat.com>
918
919 * arch-utils.c (default_read_core_file_mappings): New function.
920 * arch-utils.c (default_read_core_file_mappings): Declare.
921 * gdbarch.sh (read_core_file_mappings): New gdbarch method.
922 * gdbarch.h, gdbarch.c: Regenerate.
923
924 2020-07-22 Kevin Buettner <kevinb@redhat.com>
925
926 PR corefiles/25631
927 * corelow.c (core_target:xfer_partial): Revise
928 TARGET_OBJECT_MEMORY case to consider non-SEC_HAS_CONTENTS
929 case after first checking the stratum beneath the core
930 target.
931 (has_all_memory): Return true.
932 * target.c (raw_memory_xfer_partial): Revise comment
933 regarding use of has_all_memory.
934
935 2020-07-22 Kevin Buettner <kevinb@redhat.com>
936
937 * exec.h (section_table_xfer_memory): Revise declaration,
938 replacing section name parameter with an optional callback
939 predicate.
940 * exec.c (section_table_xfer_memory): Likewise.
941 * bfd-target.c, exec.c, target.c, corelow.c: Adjust all callers
942 of section_table_xfer_memory.
943
944 2020-07-22 Tom Tromey <tromey@adacore.com>
945
946 * mi/mi-cmd-stack.c (list_args_or_locals): Use
947 lookup_symbol_search_name.
948
949 2020-07-22 Andrew Burgess <andrew.burgess@embecosm.com>
950
951 * python/py-registers.c (gdbpy_register_object_data_init): Remove
952 redundant local variable.
953 (gdbpy_get_register_descriptor): Extract descriptor vector as a
954 reference, not pointer, update code accordingly.
955
956 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
957 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
958
959 * objfiles.h (struct objfile) <skip_jit_symbol_lookup>: New field.
960 * jit.c (jit_breakpoint_re_set_internal): Use the
961 `skip_jit_symbol_lookup` field.
962
963 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
964 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
965
966 * jit.c (jit_read_descriptor): Define the descriptor address once,
967 use twice.
968 (jit_breakpoint_deleted): Move the declaration of the loop variable
969 `iter` into the loop header.
970 (jit_breakpoint_re_set_internal): Move the declaration of the local
971 variable `objf_data` to the first point of definition.
972 (jit_event_handler): Move the declaration of local variables
973 `code_entry`, `entry_addr`, and `objf` to their first point of use.
974 Rename `objf` to `jited`.
975
976 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
977
978 * jit.h (struct jiter_objfile_data) <jiter_objfile_data, objfile>:
979 Remove.
980 * jit.c (get_jiter_objfile_data): Update.
981
982 2020-07-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
983 Simon Marchi <simon.marchi@polymtl.ca>
984
985 * jit.c (struct jit_program_space_data): Remove.
986 (jit_program_space_key): Remove.
987 (jiter_objfile_data::~jiter_objfile_data): Remove program space
988 stuff.
989 (get_jit_program_space_data): Remove.
990 (jit_breakpoint_deleted): Iterate on all of the program space's
991 objfiles.
992 (jit_inferior_init): Likewise.
993 (jit_breakpoint_re_set_internal): Likewise. Also change return
994 type to void.
995 (jit_breakpoint_re_set): Pass current_program_space to
996 jit_breakpoint_re_set_internal.
997
998 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
999
1000 * jit.h (struct jiter_objfile_data) <cached_code_address,
1001 jit_breakpoint>: Move to here from ...
1002 * jit.c (jit_program_space_data): ... here.
1003 (jiter_objfile_data::~jiter_objfile_data): Update.
1004 (jit_breakpoint_deleted): Update.
1005 (jit_breakpoint_re_set_internal): Update.
1006
1007 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1008
1009 * jit.c (jiter_objfile_data::~jiter_objfile_data): Remove some
1010 checks.
1011 (jit_read_descriptor): Remove NULL check.
1012 (jit_event_handler): Add an assertion.
1013
1014 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1015
1016 * jit.h (struct jit_objfile_data): Split into...
1017 (struct jiter_objfile_data): ... this ...
1018 (struct jited_objfile_data): ... and this.
1019 * objfiles.h (struct objfile) <jit_data>: Remove.
1020 <jiter_data, jited_data>: New fields.
1021 * jit.c (jit_objfile_data::~jit_objfile_data): Rename to ...
1022 (jiter_objfile_data::~jiter_objfile_data): ... this.
1023 (get_jit_objfile_data): Rename to ...
1024 (get_jiter_objfile_data): ... this.
1025 (add_objfile_entry): Update.
1026 (jit_read_descriptor): Use get_jiter_objfile_data.
1027 (jit_find_objf_with_entry_addr): Use objfile's jited_data field.
1028 (jit_breakpoint_re_set_internal): Use get_jiter_objfile_data.
1029 (jit_inferior_exit_hook): Use objfile's jited_data field.
1030
1031 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1032
1033 * jit.h: Forward-declare `struct minimal_symbol`.
1034 (struct jit_objfile_data): Migrate to here from jit.c; also add a
1035 constructor, destructor, and an objfile* field.
1036 * jit.c (jit_objfile_data): Remove.
1037 (struct jit_objfile_data): Migrate from here to jit.h.
1038 (jit_objfile_data::~jit_objfile_data): New destructor
1039 implementation with code moved from free_objfile_data.
1040 (free_objfile_data): Delete.
1041 (get_jit_objfile_data): Update to use the jit_data field of objfile.
1042 (jit_find_objf_with_entry_addr): Ditto.
1043 (jit_inferior_exit_hook): Ditto.
1044 (_initialize_jit): Remove the call to
1045 register_objfile_data_with_cleanup.
1046 * objfiles.h (struct objfile) <jit_data>: New field.
1047
1048 2020-07-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1049
1050 * jit.h: Forward-declare `struct objfile`.
1051 (jit_event_handler): Add a second parameter, the JITer objfile.
1052 * jit.c (jit_read_descriptor): Change the signature to take the
1053 JITer objfile as an argument instead of the jit_program_space_data.
1054 (jit_inferior_init): Update the call to jit_read_descriptor.
1055 (jit_event_handler): Use the new JITer objfile argument when calling
1056 jit_read_descriptor.
1057 * breakpoint.c (handle_jit_event): Update the call to
1058 jit_event_handler to pass the JITer objfile.
1059
1060 2020-07-21 John Baldwin <jhb@FreeBSD.org>
1061
1062 * gdbarch.c: Regenerate.
1063 * gdbarch.h: Regenerate.
1064 * gdbarch.sh (handle_segmentation_fault): Remove method.
1065 * infrun.c (handle_segmentation_fault): Remove.
1066 (print_signal_received_reason): Remove call to
1067 handle_segmentation_fault.
1068
1069 2020-07-21 John Baldwin <jhb@FreeBSD.org>
1070
1071 * sparc64-linux-tdep.c (sparc64_linux_handle_segmentation_fault):
1072 Rename to sparc64_linux_report_signal_info and add siggnal
1073 argument.
1074 (sparc64_linux_init_abi): Use sparc64_linux_report_signal_info
1075 instead of sparc64_linux_handle_segmentation_fault.
1076
1077 2020-07-21 John Baldwin <jhb@FreeBSD.org>
1078
1079 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Use
1080 i386_linux_report_signal_info instead of
1081 i386_linux_handle_segmentation_fault.
1082 * i386-linux-tdep.c (i386_linux_handle_segmentation_fault): Rename
1083 to i386_linux_report_signal_info and add siggnal argument.
1084 (i386_linux_init_abi): Use i386_linux_report_signal_info instead
1085 of i386_linux_handle_segmentation_fault.
1086 * i386-linux-tdep.h (i386_linux_handle_segmentation_fault): Rename
1087 to i386_linux_report_signal_info and add siggnal argument.
1088
1089 2020-07-21 John Baldwin <jhb@FreeBSD.org>
1090
1091 * corelow.c (core_target_open): Invoke gdbarch report_signal_info
1092 hook if present.
1093
1094 2020-07-21 John Baldwin <jhb@FreeBSD.org>
1095
1096 * gdbarch.c: Regenerate.
1097 * gdbarch.h: Regenerate.
1098 * gdbarch.sh (report_signal_info): New method.
1099 * infrun.c (print_signal_received_reason): Invoke gdbarch
1100 report_signal_info hook if present.
1101
1102 2020-07-21 Andrew Burgess <andrew.burgess@embecosm.com>
1103
1104 * python/py-registers.c : Add 'unordered_map' include.
1105 (gdbpy_new_reggroup): Renamed to...
1106 (gdbpy_get_reggroup): ...this. Update to only create register
1107 group descriptors when needed.
1108 (gdbpy_reggroup_iter_next): Update.
1109
1110 2020-07-21 Andrew Burgess <andrew.burgess@embecosm.com>
1111
1112 * python/py-registers.c (gdbpy_register_object_data): New static
1113 global.
1114 (gdbpy_register_object_data_init): New function.
1115 (gdbpy_new_register_descriptor): Renamed to...
1116 (gdbpy_get_register_descriptor): ...this, and update to reuse
1117 existing register descriptors where possible.
1118 (gdbpy_register_descriptor_iter_next): Update.
1119 (gdbpy_initialize_registers): Register new gdbarch data.
1120
1121 2020-07-21 Simon Marchi <simon.marchi@efficios.com>
1122
1123 * linux-nat.c (stopped_pids): Make static.
1124
1125 2020-07-21 Simon Marchi <simon.marchi@polymtl.ca>
1126
1127 PR ada/26235
1128 * gdbtypes.c (ada_discrete_type_low_bound,
1129 ada_discrete_type_high_bound): Handle undefined bounds.
1130
1131 2020-07-21 Kamil Rytarowski <n54@gmx.com>
1132
1133 * nbsd-nat.h (nbsd_nat_target::supports_multi_process): New
1134 declaration.
1135 * nbsd-nat.c (nbsd_nat_target::supports_multi_process): New
1136 function.
1137
1138 2020-07-20 John Baldwin <jhb@FreeBSD.org>
1139
1140 * fbsd-tdep.c (fbsd_skip_solib_resolver): New function.
1141 (fbsd_init_abi): Install gdbarch "skip_solib_resolver" method.
1142 * fbsd-tdep.h (fbsd_skip_solib_resolver): New prototype.
1143 * mips-fbsd-tdep.c (mips_fbsd_skip_solib_resolver): New function.
1144 (mips_fbsd_init_abi): Install gdbarch "skip_solib_resolver"
1145 method.
1146
1147 2020-07-20 Ludovic Courtès <ludo@gnu.org>
1148
1149 * guile/scm-math.c (vlscm_integer_fits_p): Use 'uintmax_t'
1150 and 'intmax_t' instead of 'scm_t_uintmax' and 'scm_t_intmax',
1151 which are deprecated in Guile 3.0.
1152 * configure.ac (try_guile_versions): Add "guile-3.0".
1153 * configure (try_guile_versions): Regenerate.
1154 * NEWS: Update entry.
1155
1156 2020-07-20 Ludovic Courtès <ludo@gnu.org>
1157 Doug Evans <dje@google.com>
1158
1159 PR gdb/21104
1160 * guile/scm-ports.c (USING_GUILE_BEFORE_2_2): New macro.
1161 (ioscm_memory_port)[read_buf_size, write_buf_size]: Wrap in #if
1162 USING_GUILE_BEFORE_2_2.
1163 (stdio_port_desc, memory_port_desc) [!USING_GUILE_BEFORE_2_2]:
1164 Change type to 'scm_t_port_type *'.
1165 (natural_buffer_size) [!USING_GUILE_BEFORE_2_2]: New variable.
1166 (ioscm_open_port) [USING_GUILE_BEFORE_2_2]: Add 'stream'
1167 parameter and honor it. Update callers.
1168 (ioscm_open_port) [!USING_GUILE_BEFORE_2_2]: New function.
1169 (ioscm_read_from_port, ioscm_write) [!USING_GUILE_BEFORE_2_2]: New
1170 functions.
1171 (ioscm_fill_input, ioscm_input_waiting, ioscm_flush): Wrap in #if
1172 USING_GUILE_BEFORE_2_2.
1173 (ioscm_init_gdb_stdio_port) [!USING_GUILE_BEFORE_2_2]: Use
1174 'ioscm_read_from_port'. Call 'scm_set_port_read_wait_fd'.
1175 (ioscm_init_stdio_buffers) [!USING_GUILE_BEFORE_2_2]: New function.
1176 (gdbscm_stdio_port_p) [!USING_GUILE_BEFORE_2_2]: Use 'SCM_PORTP'
1177 and 'SCM_PORT_TYPE'.
1178 (gdbscm_memory_port_end_input, gdbscm_memory_port_seek)
1179 (ioscm_reinit_memory_port): Wrap in #if USING_GUILE_BEFORE_2_2.
1180 (gdbscm_memory_port_read, gdbscm_memory_port_write)
1181 (gdbscm_memory_port_seek, gdbscm_memory_port_close)
1182 [!USING_GUILE_BEFORE_2_2]: New functions.
1183 (gdbscm_memory_port_print): Remove use of 'SCM_PTOB_NAME'.
1184 (ioscm_init_memory_port_type) [!USING_GUILE_BEFORE_2_2]: Use
1185 'gdbscm_memory_port_read'.
1186 Wrap 'scm_set_port_end_input', 'scm_set_port_flush', and
1187 'scm_set_port_free' calls in #if USING_GUILE_BEFORE_2_2.
1188 (gdbscm_get_natural_buffer_sizes) [!USING_GUILE_BEFORE_2_2]: New
1189 function.
1190 (ioscm_init_memory_port): Remove.
1191 (ioscm_init_memory_port_stream): New function
1192 (ioscm_init_memory_port_buffers) [USING_GUILE_BEFORE_2_2]: New
1193 function.
1194 (gdbscm_memory_port_read_buffer_size) [!USING_GUILE_BEFORE_2_2]:
1195 Return scm_from_uint (0).
1196 (gdbscm_set_memory_port_read_buffer_size_x)
1197 [!USING_GUILE_BEFORE_2_2]: Call 'scm_setvbuf'.
1198 (gdbscm_memory_port_write_buffer_size) [!USING_GUILE_BEFORE_2_2]:
1199 Return scm_from_uint (0).
1200 (gdbscm_set_memory_port_write_buffer_size_x)
1201 [!USING_GUILE_BEFORE_2_2]: Call 'scm_setvbuf'.
1202 * configure.ac (try_guile_versions): Add "guile-2.2".
1203 * configure: Regenerate.
1204 * NEWS: Add entry.
1205
1206 2020-07-18 Tom Tromey <tom@tromey.com>
1207
1208 * linux-nat.c (linux_multi_process): Remove.
1209 (linux_nat_target::supports_multi_process): Return true.
1210
1211 2020-07-17 Andrew Burgess <andrew.burgess@embecosm.com>
1212
1213 * arch/riscv.c (riscv_tdesc_cache): Change map type.
1214 (riscv_lookup_target_description): Return pointer out of
1215 unique_ptr.
1216 * target-descriptions.c (allocate_target_description): Add
1217 comment.
1218 (target_desc_deleter::operator()): Likewise.
1219 * target-descriptions.h (struct target_desc_deleter): Moved to
1220 gdbsupport/tdesc.h.
1221 (target_desc_up): Likewise.
1222
1223 2020-07-17 Tom Tromey <tromey@adacore.com>
1224
1225 * linux-nat.c (linux_nat_target::supports_non_stop)
1226 (linux_nat_target::always_non_stop_p): Use "true".
1227 (linux_nat_target::supports_disable_randomization): Use "true" and
1228 "false".
1229
1230 2020-07-16 Caroline Tice <cmtice@google.com>
1231
1232 * dwarf2/read.c (RNGLIST_HEADER_SIZE32) New constant definition.
1233 (RNGLIST_HEADER_SIZE64): New constant definition.
1234 (struct dwop_section_names): Add rnglists_dwo.
1235 (dwop_section_names): Add .debug_rnglists.dwo, .zdebug_rnglists.dwo.
1236 (struct loclist_header): Rename to 'loclists_rnglists_header'.
1237 (struct dwo_sections): Add rnglists field.
1238 (read_attribut_reprocess): Add tag parameter.
1239 (dwarf2_ranges_read): Add tag parameter & remove forward function decl.
1240 (cu_debug_rnglists_section): New function (decl & definition).
1241 (dwarf2_locate_dwo_sections): Add code to read rnglists_dwo section.
1242 (dwarf2_rnglists_process): Add a dwarf_tag parameter, for the kind of
1243 die whose range is being checked; get rnglist section from
1244 cu_debug_rnglists_section, to get from either objfile or dwo file as
1245 appropriate. Add cases for DW_RLE_base_addressx,
1246 DW_RLE_startx_length, DW_RLE_startx_endx. Also, update to only add
1247 the base address to DW_RLE_offset_pairs (not to all ranges), moving
1248 test inside if-condition and updating complaint message.
1249 (dwarf2_ranges_process): Add dwarf tag parameter and pass it to
1250 dwarf2_rnglists_process.
1251 (dwarf2_ranges_read): Add dwarf tag parameter and pass it to
1252 dwarf2_ranges_process.
1253 (dwarf2_get_pc_bounds): Check for DW_FORM_rnglistx when setting
1254 need_ranges_base and update comment appropriately. Also pass die tag
1255 to dwarf2_ranges_read.
1256 (dwarf2_record_block_ranges): Check for DW_FORM_rnglistx when setting
1257 need_ranges_base and update comment appropriately. Also pass die tag
1258 to dwarf2_ranges_process.
1259 (read_full_die_1): Add code to read DW_AT_rnglists_base and assign to
1260 cu->ranges_base. Also pass die tag to read_attribute_reprocess.
1261 (partial_die_info::read): Check for DW_FORM_rnglistx when setting
1262 need_ranges_base and update comment appropriately. Also pass die tag
1263 to read_attribute_reprocess and dwarf2_ranges_read.
1264 (read_loclist_header): Rename function to read_loclists_rnglists_header,
1265 and update function comment appropriately.
1266 (read_loclist_index): Call read_loclists_rnglists_header instead of
1267 read_loclist_header.
1268 (read_rnglist_index): New function.
1269 (read_attribute_reprocess): Add tag parameter. Add code for
1270 DW_FORM_rnglistx, passing tag to read_rnglist_index.
1271 (read_attribute_value): Mark DW_FORM_rnglistx with need_reprocess.
1272
1273 2020-07-15 Andrew Burgess <andrew.burgess@embecosm.com>
1274
1275 * f-typeprint.c (f_type_print_base): Allow for dynamic types not
1276 being resolved.
1277
1278 2020-07-14 Andrew Burgess <andrew.burgess@embecosm.com>
1279
1280 * arch-utils.c (show_architecture): Update formatting of messages.
1281
1282 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1283
1284 * gdbtypes.h (struct type) <bounds>: Handle array and string
1285 types.
1286 * ada-lang.c (assign_aggregate): Use type::bounds on
1287 array/string type.
1288 * c-typeprint.c (c_type_print_varspec_suffix): Likewise.
1289 * c-varobj.c (c_number_of_children): Likewise.
1290 (c_describe_child): Likewise.
1291 * eval.c (evaluate_subexp_for_sizeof): Likewise.
1292 * f-typeprint.c (f_type_print_varspec_suffix): Likewise.
1293 (f_type_print_base): Likewise.
1294 * f-valprint.c (f77_array_offset_tbl): Likewise.
1295 (f77_get_upperbound): Likewise.
1296 (f77_print_array_1): Likewise.
1297 * guile/scm-type.c (gdbscm_type_range): Likewise.
1298 * m2-typeprint.c (m2_array): Likewise.
1299 (m2_is_long_set_of_type): Likewise.
1300 * m2-valprint.c (get_long_set_bounds): Likewise.
1301 * p-typeprint.c (pascal_type_print_varspec_prefix): Likewise.
1302 * python/py-type.c (typy_range): Likewise.
1303 * rust-lang.c (rust_internal_print_type): Likewise.
1304 * type-stack.c (type_stack::follow_types): Likewise.
1305 * valarith.c (value_subscripted_rvalue): Likewise.
1306 * valops.c (value_cast): Likewise.
1307
1308 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1309
1310 * gdbtypes.c (TYPE_ARRAY_BIT_STRIDE): Remove. Update all
1311 callers to use the equivalent accessor methods.
1312
1313 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1314
1315 * gdbtypes.h (struct range_bounds) <bit_stride>: New method.
1316 (struct type) <bit_stride>: New method.
1317 (TYPE_BIT_STRIDE): Remove.
1318 * gdbtypes.c (update_static_array_size): Use type::bit_stride.
1319
1320 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1321
1322 * gdbtypes.h (TYPE_ARRAY_LOWER_BOUND_VALUE,
1323 TYPE_ARRAY_UPPER_BOUND_VALUE): Remove. Update all
1324 callers to use the equivalent accessor methods instead.
1325
1326 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1327
1328 * gdbtypes.h (TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED,
1329 TYPE_ARRAY_LOWER_BOUND_IS_UNDEFINED): Remove. Update all
1330 callers to use the equivalent accessor methods instead.
1331
1332 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1333
1334 * gdbtypes.h (TYPE_LOW_BOUND_KIND,
1335 TYPE_HIGH_BOUND_KIND): Remove. Update all callers
1336 to use dynamic_prop::kind.
1337
1338 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1339
1340 * gdbtypes.h (TYPE_LOW_BOUND_UNDEFINED,
1341 TYPE_HIGH_BOUND_UNDEFINED): Remove. Update all callers
1342 to get the bound property's kind and check against
1343 PROP_UNDEFINED.
1344
1345 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1346
1347 * gdbtypes.h (TYPE_LOW_BOUND, TYPE_HIGH_BOUND): Remove. Update
1348 all callers to use type::range_bounds followed by
1349 dynamic_prop::{low,high}.
1350
1351 2020-07-12 Simon Marchi <simon.marchi@polymtl.ca>
1352
1353 * gdbtypes.h (struct dynamic_prop) <kind, set_undefined,
1354 const_val, set_const_val, baton, set_locexpr, set_loclist,
1355 set_addr_offset, variant_parts, set_variant_parts,
1356 original_type, set_original_type>: New methods.
1357 <kind>: Rename to...
1358 <m_kind>: ... this. Update all users to use the new methods
1359 instead.
1360 <data>: Rename to...
1361 <m_data>: ... this. Update all users to use the new methods
1362 instead.
1363
1364 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1365
1366 * gdbtypes.c (get_discrete_bounds): Return failure if
1367 the range type's bounds are not both defined and constant
1368 values.
1369 (get_array_bounds): Update comment. Remove undefined bound check.
1370
1371 2020-07-12 Simon Marchi <simon.marchi@polymtl.ca>
1372
1373 * gdbtypes.h (TYPE_RANGE_DATA): Remove. Update callers to use
1374 the type::bounds method directly.
1375
1376 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1377
1378 * gdbtypes.h (struct type) <bounds, set_bounds>: New methods.
1379 (TYPE_RANGE_DATA): Use type::bounds. Change all uses that
1380 are used to set the range type's bounds to use set_bounds.
1381
1382 2020-07-11 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1383
1384 * exec.c (_initialize_exec): Update exec-file-mismatch help.
1385
1386 2020-07-10 Pedro Alves <pedro@palves.net>
1387
1388 * gdbthread.h (inferior_ref): Define.
1389 (scoped_restore_current_thread) <m_thread>: Now a thread_info_ref.
1390 (scoped_restore_current_thread) <m_inf>: Now an inferior_ref.
1391 * thread.c
1392 (scoped_restore_current_thread::restore):
1393 Adjust to gdb::ref_ptr.
1394 (scoped_restore_current_thread::~scoped_restore_current_thread):
1395 Remove manual decref handling.
1396 (scoped_restore_current_thread::scoped_restore_current_thread):
1397 Adjust to use
1398 inferior_ref::new_reference/thread_info_ref::new_reference.
1399 Incref the thread before calling get_frame_id instead of after.
1400 Let TARGET_CLOSE_ERROR propagate.
1401
1402 2020-07-10 Pedro Alves <pedro@palves.net>
1403
1404 * frame-tailcall.c (dwarf2_tailcall_sniffer_first): Only swallow
1405 NO_ENTRY_VALUE_ERROR / MEMORY_ERROR / OPTIMIZED_OUT_ERROR /
1406 NOT_AVAILABLE_ERROR.
1407 * value.c (value_optimized_out): Only swallow MEMORY_ERROR /
1408 OPTIMIZED_OUT_ERROR / NOT_AVAILABLE_ERROR.
1409
1410 2020-07-10 Simon Marchi <simon.marchi@polymtl.ca>
1411 Pedro Alves <pedro@palves.net>
1412
1413 PR gdb/26199
1414 * infrun.c (threads_are_resumed_pending_p): Delete.
1415 (do_target_wait): Remove threads_are_executing and
1416 threads_are_resumed_pending_p checks from the inferior_matches
1417 lambda. Update comments.
1418
1419 2020-07-10 Pedro Alves <pedro@palves.net>
1420
1421 PR gdb/26199
1422 * infrun.c (handle_no_resumed): Transfer terminal to inferior with
1423 executing threads.
1424
1425 2020-07-10 Pedro Alves <pedro@palves.net>
1426
1427 PR gdb/26199
1428 * infrun.c (handle_no_resumed): Handle multiple targets.
1429
1430 2020-07-10 Pedro Alves <pedro@palves.net>
1431
1432 PR gdb/26199
1433 * infrun.c (prepare_to_wait): Check target_can_async_p instead of
1434 target_is_async_p.
1435
1436 2020-07-10 Pedro Alves <pedro@palves.net>
1437
1438 PR gdb/26199
1439 * target.c (target_pass_ctrlc): Look at the inferior's non-exited
1440 threads, not all threads.
1441
1442 2020-07-10 Pedro Alves <pedro@palves.net>
1443
1444 PR gdb/26199
1445 * remote.c (remote_target::open_1): Pass remote target pointer as
1446 data to create_async_event_handler.
1447 (remote_async_inferior_event_handler): Mark async event handler
1448 before returning if the remote target still has either pending
1449 events or unacknowledged notifications.
1450
1451 2020-07-10 John Baldwin <jhb@FreeBSD.org>
1452
1453 * fbsd-nat.h (fbsd_nat_target::supports_multi_process): New
1454 declaration.
1455 * fbsd-nat.c (fbsd_nat_target::supports_multi_process): New
1456 function.
1457
1458 2020-07-09 John Baldwin <jhb@FreeBSD.org>
1459
1460 * inf-ptrace.c (inf_ptrace_target::wait): Don't compare against
1461 inferior_ptid.
1462
1463 2020-07-09 John Baldwin <jhb@FreeBSD.org>
1464
1465 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_ARGC,
1466 AT_FREEBSD_ARGV, AT_FREEBSD_ENVC, AT_FREEBSD_ENVV,
1467 AT_FREEBSD_PS_STRINGS.
1468
1469 2020-07-08 Hannes Domani <ssbssa@yahoo.de>
1470
1471 * auto-load.c (auto_load_objfile_script_1): Convert drive part
1472 of debugfile path on Windows.
1473
1474 2020-07-08 John Baldwin <jhb@FreeBSD.org>
1475
1476 * fbsd-nat.c (fbsd_nat_target::find_memory_regions): Rename 'obfd'
1477 argument to 'data'.
1478
1479 2020-07-08 Tom Tromey <tromey@adacore.com>
1480
1481 * ada-lang.c (ada_exception_message_1): Use read_memory.
1482
1483 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
1484
1485 PR python/22748
1486 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Remove
1487 special handling for inline frames.
1488 * findvar.c (value_of_register_lazy): Skip inline frames when
1489 creating lazy register values.
1490 * frame.c (frame_id_computed_p): Delete definition.
1491 * frame.h (frame_id_computed_p): Delete declaration.
1492
1493 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
1494
1495 * NEWS: Mention additions to Python API.
1496 * python/py-arch.c (archpy_register_groups): New function.
1497 (arch_object_methods): Add 'register_groups' method.
1498 * python/py-registers.c (reggroup_iterator_object): New struct.
1499 (reggroup_object): New struct.
1500 (gdbpy_new_reggroup): New function.
1501 (gdbpy_reggroup_to_string): New function.
1502 (gdbpy_reggroup_name): New function.
1503 (gdbpy_reggroup_iter): New function.
1504 (gdbpy_reggroup_iter_next): New function.
1505 (gdbpy_new_reggroup_iterator): New function
1506 (gdbpy_initialize_registers): Register new types.
1507 (reggroup_iterator_object_type): Define new Python type.
1508 (gdbpy_reggroup_getset): New static global.
1509 (reggroup_object_type): Define new Python type.
1510 * python/python-internal.h
1511
1512 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
1513
1514 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-registers.c
1515 * python/py-arch.c (archpy_registers): New function.
1516 (arch_object_methods): Add 'registers' method.
1517 * python/py-registers.c: New file.
1518 * python/python-internal.h
1519 (gdbpy_new_register_descriptor_iterator): Declare.
1520 (gdbpy_initialize_registers): Declare.
1521 * python/python.c (do_start_initialization): Call
1522 gdbpy_initialize_registers.
1523 * NEWS: Mention additions to the Python API.
1524
1525 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
1526
1527 * NEWS: Mention new Python API method.
1528 * python/py-unwind.c (pending_framepy_architecture): New function.
1529 (pending_frame_object_methods): Add architecture method.
1530
1531 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
1532
1533 * gdbarch.c: Regenerate.
1534 * gdbarch.h: Regenerate.
1535 * gdbarch.sh (deprecated_set_gdbarch_data): Delete.
1536 (gdbarch_data): Use internal_error for the case where
1537 deprecated_set_gdbarch_data was originally needed.
1538 * ia64-libunwind-tdep.c (libunwind_descr_init): Update parameters,
1539 and use passed in obstack.
1540 (libunwind_frame_set_descr): Should no longer get back NULL from
1541 gdbarch_data.
1542 (_initialize_libunwind_frame): Register as a pre-init gdbarch data
1543 type.
1544 * user-regs.c (user_regs_init): Update parameters, and use passed
1545 in obstack.
1546 (user_reg_add): Should no longer get back NULL from gdbarch_data.
1547 (_initialize_user_regs): Register as a pre-init gdbarch data type.
1548
1549 2020-07-06 Tom de Vries <tdevries@suse.de>
1550
1551 * buildsym.c (buildsym_compunit::end_symtab_with_blockvector): Handle
1552 End-Of-Sequence in lte_is_less_than.
1553 * symtab.c (find_pc_sect_line): Revert change from commit 3d92a3e313
1554 "gdb: Don't reorder line table entries too much when sorting".
1555
1556 2020-07-06 Tom de Vries <tdevries@suse.de>
1557
1558 PR tui/26205
1559 * tui/tui-win.c (tui_partial_win_by_name): Don't test for NULL name.
1560
1561 2020-07-05 Tom de Vries <tdevries@suse.de>
1562
1563 PR build/26187
1564 * inferior.h (struct infcall_suspend_state_deleter): If available, use
1565 std::uncaught_exceptions instead of deprecated
1566 std::uncaught_exception.
1567
1568 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
1569
1570 * macroexp.h (macro_stringify): Return
1571 gdb::unique_xmalloc_ptr<char>.
1572 * macroexp.c (macro_stringify): Likewise.
1573 * macrotab.c (fixup_definition): Update.
1574
1575 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
1576
1577 * c-exp.y (scan_macro_expansion): Don't free `expansion`.
1578 (lex_one_token): Update.
1579 * macroexp.c (struct macro_buffer) <release>: Return
1580 gdb::unique_xmalloc_ptr<char>.
1581 (macro_stringify): Update.
1582 (macro_expand): Update.
1583 (macro_expand_next): Return gdb::unique_xmalloc_ptr<char>.
1584 * macroexp.h (macro_expand_next): Likewise.
1585
1586 2020-07-02 Simon Marchi <simon.marchi@efficios.com>
1587
1588 * macroexp.h (macro_lookup_ftype): Remove.
1589 (macro_expand, macro_expand_once, macro_expand_next): Remove
1590 lookup function parameters, add scope parameter.
1591 * macroexp.c (scan, substitute_args, expand, maybe_expand,
1592 macro_expand, macro_expand_once, macro_expand_next): Likewise.
1593 * macroscope.h (standard_macro_lookup): Change parameter type
1594 to macro_scope.
1595 * macroscope.c (standard_macro_lookup): Likewise.
1596 * c-exp.y (lex_one_token): Update.
1597 * macrocmd.c (macro_expand_command): Likewise.
1598 (macro_expand_once_command): Likewise.
1599
1600 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
1601
1602 * inf-loop.c (inferior_event_handler): Remove client_data param.
1603 * inf-loop.h (inferior_event_handler): Likewise.
1604 * infcmd.c (step_1): Adjust.
1605 * infrun.c (proceed): Adjust.
1606 (fetch_inferior_event): Remove client_data param.
1607 (infrun_async_inferior_event_handler): Adjust.
1608 * infrun.h (fetch_inferior_event): Remove `void *` param.
1609 * linux-nat.c (handle_target_event): Adjust.
1610 * record-btrace.c (record_btrace_handle_async_inferior_event):
1611 Adjust.
1612 * record-full.c (record_full_async_inferior_event_handler):
1613 Adjust.
1614 * remote.c (remote_async_inferior_event_handler): Adjust.
1615
1616 2020-07-01 Tom Tromey <tom@tromey.com>
1617
1618 * tui/tui-data.h (struct tui_win_info) <name>: Now pure virtual.
1619 * tui/tui-stack.h (struct tui_locator_window) <name>: New method.
1620
1621 2020-07-01 Tom Tromey <tom@tromey.com>
1622
1623 * tui/tui-wingeneral.c (tui_win_info::refresh_window): Move from
1624 tui_gen_win_info.
1625 (tui_win_info::make_window): Merge with
1626 tui_gen_win_info::make_window.
1627 (tui_win_info::make_visible): Move from tui_gen_win_info.
1628 * tui/tui-win.c (tui_win_info::max_width): Move from
1629 tui_gen_win_info.
1630 * tui/tui-layout.h (class tui_layout_window) <m_window>: Change
1631 type.
1632 <window_factory>: Likewise.
1633 * tui/tui-layout.c (tui_win_info::resize): Move from
1634 tui_gen_win_info.
1635 (make_standard_window): Change return type.
1636 (get_locator_window, tui_get_window_by_name): Likewise.
1637 (tui_layout_window::apply): Remove a cast.
1638 * tui/tui-data.h (MIN_WIN_HEIGHT): Move earlier.
1639 (struct tui_win_info): Merge with tui_gen_win_info.
1640 (struct tui_gen_win_info): Remove.
1641
1642 2020-07-01 Tom Tromey <tom@tromey.com>
1643
1644 * tui/tui-stack.h (struct tui_locator_window): Derive from
1645 tui_win_info.
1646 <do_scroll_horizontal, do_scroll_vertical>: New methods.
1647 <can_box>: New method.
1648
1649 2020-07-01 Tom Tromey <tom@tromey.com>
1650
1651 * tui/tui-stack.h (struct tui_locator_window): Remove body.
1652
1653 2020-07-01 Tom Tromey <tom@tromey.com>
1654
1655 * tui/tui-regs.c (tui_data_window::display_registers_from)
1656 (tui_data_window::display_registers_from)
1657 (tui_data_window::first_data_item_displayed)
1658 (tui_data_window::delete_data_content_windows): Update.
1659 (tui_data_window::refresh_window, tui_data_window::no_refresh):
1660 Remove.
1661 (tui_data_window::check_register_values): Update.
1662 (tui_data_item_window::rerender): Add parameters. Update.
1663 (tui_data_item_window::refresh_window): Remove.
1664 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: No longer
1665 virtual.
1666 * tui/tui-regs.h (struct tui_data_item_window): Don't derive from
1667 tui_gen_win_info.
1668 <refresh_window, max_height, min_height>: Remove.
1669 <rerender>: Add parameters.
1670 <x, y, visible>: New members.
1671 (struct tui_data_window) <refresh_window, no_refresh>: Remove.
1672 <m_item_width>: New member.
1673
1674 2020-07-01 Tom Tromey <tom@tromey.com>
1675
1676 * tui/tui-regs.c (tui_data_window::show_register_group)
1677 (tui_data_window::check_register_values): Update.
1678 * tui/tui-regs.h (struct tui_data_item_window) <regno>: Rename
1679 from item_no.
1680
1681 2020-07-01 Tom Tromey <tom@tromey.com>
1682
1683 * tui/tui-regs.c (tui_data_window::show_register_group): Remove
1684 useless "if".
1685
1686 2020-07-01 Tom Tromey <tom@tromey.com>
1687
1688 * tui/tui-regs.c (tui_data_window::show_register_group): Update.
1689 * tui/tui-regs.h (struct tui_data_item_window) <name>: Remove.
1690
1691 2020-07-01 Tom Tromey <tom@tromey.com>
1692
1693 * tui/tui-stack.c (SINGLE_KEY): Move from tui-data.h
1694 * tui/tui-winsource.h (enum tui_line_or_address_kind)
1695 (struct tui_line_or_address): Move from tui-data.h.
1696 * tui/tui-win.c (DEFAULT_TAB_LEN): Move from tui-data.h.
1697 * tui/tui-data.h (DEFAULT_TAB_LEN): Move to tui-win.c.
1698 (tui_cmd_window, tui_source_window_base, tui_source_window)
1699 (tui_disasm_window): Don't declare.
1700 (enum tui_line_or_address_kind, struct tui_line_or_address): Move
1701 to tui-winsource.h.
1702 (SINGLE_KEY): Move to tui-stack.c.
1703
1704 2020-07-01 Tom Tromey <tom@tromey.com>
1705
1706 * tui/tui-regs.h (struct tui_data_item_window) <content>: Now a
1707 std::string.
1708 * tui/tui-regs.c (class tab_expansion_file): New.
1709 (tab_expansion_file::write): New method.
1710 (tui_register_format): Change return type. Use
1711 tab_expansion_file.
1712 (tui_get_register, tui_data_window::display_registers_from)
1713 (tui_data_item_window::rerender): Update.
1714 * tui/tui-io.h (tui_expand_tabs): Don't declare.
1715 * tui/tui-io.c (tui_expand_tabs): Remove.
1716
1717 2020-07-01 Tom Tromey <tom@tromey.com>
1718
1719 * tui/tui-regs.c (tui_reggroup_completer): Use complete_on_enum.
1720
1721 2020-07-01 Fangrui Song <maskray@google.com>
1722
1723 * dwarf2/read.c (lnp_state_machine::check_line_address): Test -1.
1724
1725 2020-07-01 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
1726
1727 * dwarf2/read.c (set_die_type): Removed conditions to restrict
1728 forms for DW_AT_associated and DW_AT_allocated attributes,
1729 which is already checked in function attr_to_dynamic_prop.
1730
1731 2020-06-30 Tom Tromey <tromey@adacore.com>
1732
1733 * dwarf2/read.c (quirk_rust_enum): Correctly call
1734 alloc_rust_variant for default-less enum.
1735
1736 2020-06-30 Tom Tromey <tromey@adacore.com>
1737
1738 PR build/26183:
1739 * ada-lang.c (ada_lookup_name_info::ada_lookup_name_info): Use
1740 gdb::to_string.
1741
1742 2020-06-29 Simon Marchi <simon.marchi@efficios.com>
1743
1744 * gdbarch.sh (displaced_step_copy_insn): Update doc.
1745 * gdbarch.h: Re-generate.
1746
1747 2020-06-28 Tom Tromey <tom@tromey.com>
1748
1749 * command.h (cmd_types): Remove.
1750 (cmd_type): Don't declare.
1751 * cli/cli-decode.h (enum cmd_types): Uncomment. No longer a
1752 typedef.
1753 * cli/cli-cmds.c (setting_cmd): Use cmd->type directly.
1754 * cli/cli-decode.c (cmd_type): Remove.
1755
1756 2020-06-27 Pedro Alves <palves@redhat.com>
1757
1758 * fork-child.c (prefork_hook): Adjust.
1759 * infcmd.c (set_inferior_io_terminal, get_inferior_io_terminal):
1760 Delete.
1761 (set_inferior_tty_command, show_inferior_tty_command): Adjust.
1762 * inferior.c (inferior::set_tty, inferior::tty): New methods.
1763 * inferior.h (set_inferior_io_terminal, get_inferior_io_terminal):
1764 Remove declarations.
1765 (struct inferior) <set_tty, tty>: New methods.
1766 (struct inferior) <terminal>: Rename to ...
1767 (struct inferior) <m_terminal>: ... this and make private.
1768 * main.c (captured_main_1): Adjust.
1769 * mi/mi-cmd-env.c (mi_cmd_inferior_tty_set): Adjust.
1770 (mi_cmd_inferior_tty_show): Adjust.
1771 * nto-procfs.c (nto_procfs_target::create_inferior): Adjust.
1772 * windows-nat.c (windows_nat_target::create_inferior): Adjust.
1773
1774 2020-06-26 Nick Alcock <nick.alcock@oracle.com>
1775
1776 * configure.ac: Add --enable-libctf: handle --disable-static
1777 properly.
1778 * acinclude.m4: sinclude ../config/enable.m4.
1779 * Makefile.in (aclocal_m4_deps): Adjust accordingly.
1780 (LIBCTF): Substitute in.
1781 (CTF_DEPS): New, likewise.
1782 (CLIBS): libctf needs symbols from libbfd: move earlier.
1783 (CDEPS): Use CTF_DEPS, not LIBCTF, now LIBCTF can include rpath
1784 flags.
1785 * ctfread.c: Surround in ENABLE_LIBCTF.
1786 (elfctf_build_psymtabs) [!ENABLE_LIBCTF]: New stub.
1787 * configure: Regenerate.
1788 * config.in: Likewise.
1789
1790 2020-06-25 Simon Marchi <simon.marchi@efficios.com>
1791
1792 * infcmd.c (set_inferior_io_terminal): Use make_unique_xstrdup.
1793
1794 2020-06-25 Simon Marchi <simon.marchi@efficios.com>
1795
1796 * inferior.h (struct inferior) <terminal>: Change type to
1797 gdb::unique_xmalloc_ptr<char>.
1798 * inferior.c (inferior::~inferior): Don't free inf->terminal.
1799 * infcmd.c (set_inferior_io_terminal): Don't free terminal
1800 field, adjust to unique pointer.
1801 (get_inferior_io_terminal): Adjust to unique pointer.
1802
1803 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1804
1805 * riscv-tdep.c (riscv_print_registers_info): Loop over all
1806 registers, not just the known core set of registers.
1807
1808 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1809
1810 * riscv-tdep.c (riscv_register_name): Return NULL for duplicate
1811 fflags, frm, and fcsr registers.
1812 (riscv_register_reggroup_p): Remove unknown CSRs from save and
1813 restore groups.
1814 (riscv_tdesc_unknown_reg): New function.
1815 (riscv_gdbarch_init): Pass riscv_tdesc_unknown_reg to
1816 tdesc_use_registers.
1817 * riscv-tdep.h (struct gdbarch_tdep): Add
1818 unknown_csrs_first_regnum, unknown_csrs_count,
1819 duplicate_fflags_regnum, duplicate_frm_regnum, and
1820 duplicate_fcsr_regnum fields.
1821
1822 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1823
1824 * target-descriptions.c (tdesc_use_registers): Add new parameter a
1825 callback, use the callback (when not null) to help number unknown
1826 registers.
1827 * target-descriptions.h (tdesc_unknown_register_ftype): New typedef.
1828 (tdesc_use_registers): Add extra parameter to declaration.
1829
1830 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1831
1832 * riscv-tdep.c (value_of_riscv_user_reg): Moved to here from later
1833 in the file.
1834 (class riscv_pending_register_alias): Likewise.
1835 (riscv_register_feature::register_info): Change 'required_p' field
1836 to 'required', and change its type. Add 'check' member function.
1837 (riscv_register_feature::register_info::check): Define new member
1838 function.
1839 (riscv_xreg_feature): Change initialisation of 'required' field.
1840 (riscv_freg_feature): Likewise.
1841 (riscv_virtual_feature): Likewise.
1842 (riscv_csr_feature): Likewise.
1843 (riscv_check_tdesc_feature): Take extra parameter, the csr
1844 tdesc_feature, rewrite the function to use the new
1845 riscv_register_feature::register_info::check function.
1846 (riscv_gdbarch_init): Pass the csr tdesc_feature where needed.
1847
1848 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1849
1850 * features/Makefile: Remove all references to the deleted files
1851 below.
1852 * features/riscv/32bit-csr.c: Deleted.
1853 * features/riscv/32bit-csr.xml: Deleted.
1854 * features/riscv/64bit-csr.c: Deleted.
1855 * features/riscv/64bit-csr.xml: Deleted.
1856 * features/riscv/rebuild-csr-xml.sh: Deleted.
1857
1858 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1859
1860 * riscv-tdep.c (struct riscv_register_feature::register_info): Fix
1861 whitespace error for declaration of names member variable.
1862 (struct riscv_register_feature): Add new prefer_first_name member
1863 variable, and fix whitespace error in declaration of registers.
1864 (riscv_xreg_feature): Initialize prefer_first_name field.
1865 (riscv_freg_feature): Likewise.
1866 (riscv_virtual_feature): Likewise.
1867 (riscv_csr_feature): Likewise.
1868 (riscv_register_name): Expand on comments. Remove register name
1869 modifications for CSR and virtual registers.
1870
1871 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1872
1873 * riscv-tdep.c (struct riscv_register_feature): Fix whitespace
1874 errors.
1875
1876 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1877
1878 * riscv-tdep.c (riscv_create_csr_aliases): Handle csr aliases from
1879 riscv-opc.h.
1880 (class riscv_pending_register_alias): New class.
1881 (riscv_check_tdesc_feature): Take vector of pending aliases and
1882 populate it as appropriate.
1883 (riscv_setup_register_aliases): Delete.
1884 (riscv_gdbarch_init): Create vector of pending aliases and pass it
1885 to riscv_check_tdesc_feature in all cases. Use the vector to
1886 create the register aliases.
1887
1888 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1889
1890 * sol2-tdep.c (sol2_static_transform_name): Remove.
1891 (sol2_init_abi): Don't register it.
1892 * gdbarch.sh (static_transform_name): Remove.
1893 * gdbarch.c, gdbarch.h: Regenerate.
1894
1895 * dbxread.c (read_dbx_symtab) <'S'>: Remove call to
1896 gdbarch_static_transform_name.
1897 * mdebugread.c (parse_partial_symbols) <'S'>: Likewise.
1898 * stabsread.c (define_symbol) <'X'>: Remove.
1899 (define_symbol) <'S'>: Remove gdbarch_static_transform_name
1900 handling.
1901 <'V'>: Likewise.
1902 * xcoffread.c (scan_xcoff_symtab): Remove gdbarch.
1903 <'S'>: Remove call to gdbarch_static_transform_name.
1904
1905 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1906
1907 * procfs.c (procfs_pre_trace): New function.
1908 (procfs_target::create_inferior): Pass it to fork_inferior.
1909
1910 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1911
1912 * configure.tgt <sparc-*-linux*> (gdb_target_obs): Remove
1913 sparc-sol2-tdep.o, sol2-tdep.o, sparc64-sol2-tdep.o.
1914 <sparc64-*-linux*> (gdb_target_obs): Remove sparc64-sol2-tdep.o,
1915 sol2-tdep.o, sparc-sol2-tdep.o.
1916 * sparc-sol2-tdep.c (sparc32_sol2_init_abi): Make static.
1917 * sparc-tdep.h (sparc32_sol2_init_abi): Remove.
1918 * sparc64-sol2-tdep.c (sparc64_sol2_init_abi): Make static.
1919 * sparc64-tdep.h (sparc64_sol2_init_abi): Remove.
1920
1921 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1922
1923 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Remove.
1924 (amd64_sol2_init_abi): Use sol2_sigtramp_p.
1925 Call sol2_init_abi.
1926 Remove calls to set_gdbarch_skip_solib_resolver,
1927 set_gdbarch_core_pid_to_str.
1928 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Remove.
1929 (i386_sol2_static_transform_name): Remove.
1930 (i386_sol2_init_abi): Call sol2_init_abi.
1931 Remove calls to set_gdbarch_sofun_address_maybe_missing,
1932 set_gdbarch_static_transform_name,
1933 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
1934 Use sol2_sigtramp_p.
1935 * sol2-tdep.c (sol2_pc_in_sigtramp): New function.
1936 (sol2_sigtramp_p): New function.
1937 (sol2_static_transform_name): New function.
1938 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Make static.
1939 (sol2_init_abi): New function.
1940 * sol2-tdep.h (sol2_sigtramp_p, sol2_init_abi): Declare.
1941 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Remove.
1942 * sparc-sol2-tdep.c (sparc_sol2_pc_in_sigtramp): Remove.
1943 (sparc32_sol2_sigtramp_frame_sniffer): Just call sol2_sigtramp_p.
1944 (sparc_sol2_static_transform_name): Remove.
1945 (sparc32_sol2_init_abi): Call sol2_init_abi.
1946 Remove calls to set_gdbarch_sofun_address_maybe_missing,
1947 set_gdbarch_static_transform_name,
1948 set_gdbarch_skip_solib_resolver,
1949 set_gdbarch_core_pid_to_str.
1950 * sparc-tdep.h (sparc_sol2_pc_in_sigtramp)
1951 (sparc_sol2_static_transform_name): Remove
1952 * sparc64-sol2-tdep.c (sparc64_sol2_sigtramp_frame_sniffer): Just
1953 call sol2_sigtramp_p.
1954 (sparc64_sol2_init_abi): Call sol2_init_abi.
1955 Remove calls to set_gdbarch_sofun_address_maybe_missing,
1956 set_gdbarch_static_transform_name,
1957 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
1958
1959 2020-06-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1960
1961 * symfile-add-flags.h: New flag SYMFILE_ALWAYS_CONFIRM.
1962 * exec.c (validate_exec_file): If from_tty, set both
1963 SYMFILE_VERBOSE (== from_tty) and SYMFILE_ALWAYS_CONFIRM.
1964 * symfile.c (symbol_file_add_with_addrs): if always_confirm
1965 and from_tty, unconditionally ask a confirmation.
1966
1967 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1968
1969 * target-descriptions.c (tdesc_architecture_name): Protect against
1970 NULL pointer dereference.
1971 (maint_print_xml_tdesc_cmd): New function.
1972 (_initialize_target_descriptions): Register new 'maint print
1973 xml-tdesc' command and give it the filename completer.
1974 * NEWS: Mention new 'maint print xml-tdesc' command.
1975
1976 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1977
1978 * target-descriptions.c (class tdesc_compatible_info): New class.
1979 (struct target_desc): Change type of compatible vector.
1980 (tdesc_compatible_p): Update for change in type of
1981 target_desc::compatible.
1982 (tdesc_compatible_info_list): New function.
1983 (tdesc_compatible_info_arch_name): New function.
1984 (tdesc_add_compatible): Update for change in type of
1985 target_desc::compatible.
1986 (print_c_tdesc::visit_pre): Likewise.
1987
1988 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1989
1990 * target-descriptions.c (print_c_tdesc::print_c_tdesc): Change
1991 whitespace to underscore.
1992 (maint_print_c_tdesc_cmd): Use fake filename for target
1993 descriptions that came from the target.
1994 (_initialize_target_descriptions): Add filename command completion
1995 for 'maint print c-tdesc'.
1996
1997 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
1998
1999 * dwarf2/loc.c (decode_debug_loclists_addresses): Add empty
2000 lines.
2001
2002 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
2003
2004 * dwarf2/loc.c (decode_debug_loc_dwo_addresses): Add empty
2005 lines.
2006 (dwarf2_find_location_expression): Likewise.
2007 (call_site_parameter_matches): Likewise.
2008 (dwarf2_compile_expr_to_ax): Likewise.
2009 (disassemble_dwarf_expression): Likewise.
2010 (loclist_describe_location): Likewise.
2011
2012 2020-06-23 Pedro Alves <palves@redhat.com>
2013
2014 * gdbarch-selftests.c: Don't include inferior.h, gdbthread.h or
2015 progspace-and-thread.h. Include scoped-mock-context.h instead.
2016 (register_to_value_test): Use scoped_mock_context.
2017 * regcache.c: Include "scoped-mock-context.h".
2018 (cooked_read_test): Don't error out if a target is already pushed.
2019 Use scoped_mock_context. Adjust.
2020 * scoped-mock-context.h: New file.
2021
2022 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2023
2024 * ada-lang.c (ada_language_data): Delete la_is_string_type_p
2025 initializer.
2026 (ada_language::is_string_type_p): New member function.
2027 * c-lang.c (c_language_data): Delete la_is_string_type_p
2028 initializer.
2029 (cplus_language_data): Likewise.
2030 (asm_language_data): Likewise.
2031 (minimal_language_data): Likewise.
2032 * d-lang.c (d_language_data): Likewise.
2033 * f-lang.c (f_is_string_type_p): Delete function, implementation
2034 moved to f_language::is_string_type_p.
2035 (f_language_data): Delete la_is_string_type_p initializer.
2036 (f_language::is_string_type_p): New member function,
2037 implementation from f_is_string_type_p.
2038 * go-lang.c (go_is_string_type_p): Delete function, implementation
2039 moved to go_language::is_string_type_p.
2040 (go_language_data): Delete la_is_string_type_p initializer.
2041 (go_language::is_string_type_p): New member function,
2042 implementation from go_is_string_type_p.
2043 * language.c (language_defn::is_string_type_p): Define new member
2044 function.
2045 (default_is_string_type_p): Make static, add comment copied from
2046 header file.
2047 (unknown_language_data): Delete la_is_string_type_p initializer.
2048 (unknown_language::is_string_type_p): New member function.
2049 (auto_language_data): Delete la_is_string_type_p initializer.
2050 (auto_language::is_string_type_p): New member function.
2051 * language.h (language_data): Delete la_is_string_type_p field.
2052 (language_defn::is_string_type_p): Declare new function.
2053 (default_is_string_type_p): Delete desclaration, move comment to
2054 definition.
2055 * m2-lang.c (m2_is_string_type_p): Delete function, implementation
2056 moved to m2_language::is_string_type_p.
2057 (m2_language_data): Delete la_is_string_type_p initializer.
2058 (m2_language::is_string_type_p): New member function,
2059 implementation from m2_is_string_type_p.
2060 * objc-lang.c (objc_language_data): Delete la_is_string_type_p
2061 initializer.
2062 * opencl-lang.c (opencl_language_data): Likewise.
2063 * p-lang.c (pascal_is_string_type_p): Delete function,
2064 implementation moved to pascal_language::is_string_type_p.
2065 (pascal_language_data): Delete la_is_string_type_p initializer.
2066 (pascal_language::is_string_type_p): New member function,
2067 implementation from pascal_is_string_type_p.
2068 * rust-lang.c (rust_is_string_type_p): Delete function,
2069 implementation moved to rust_language::is_string_type_p.
2070 (rust_language_data): Delete la_is_string_type_p initializer.
2071 (rust_language::is_string_type_p): New member function,
2072 implementation from rust_is_string_type_p.
2073 * valprint.c (val_print_scalar_or_string_type_p): Update call to
2074 is_string_type_p.
2075
2076 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2077
2078 * ada-lang.c (ada_language_data): Delete la_print_typedef
2079 initializer.
2080 (ada_language::print_typedef): New member function.
2081 * c-lang.c (c_language_data): Delete la_print_typedef initializer.
2082 (cplus_language_data): Likewise.
2083 (asm_language_data): Likewise.
2084 (minimal_language_data): Likewise.
2085 * d-lang.c (d_language_data): Likewise.
2086 * f-lang.c (f_language_data): Likewise.
2087 (f_language::print_typedef): New member function.
2088 * go-lang.c (go_language_data): Delete la_print_typedef
2089 initializer.
2090 * language.c (language_defn::print_typedef): Define member
2091 function.
2092 (unknown_language_data): Delete la_print_typedef initializer.
2093 (unknown_language::print_typedef): New member function.
2094 (auto_language_data): Delete la_print_typedef initializer.
2095 (auto_language::print_typedef): New member function.
2096 * language.h (language_data): Delete la_print_typedef field.
2097 (language_defn::print_typedef): Declare new member function.
2098 (LA_PRINT_TYPEDEF): Update call to print_typedef.
2099 (default_print_typedef): Delete declaration.
2100 * m2-lang.c (m2_language_data): Delete la_print_typedef
2101 initializer.
2102 (m2_language::print_typedef): New member function.
2103 * objc-lang.c (objc_language_data): Delete la_print_typedef
2104 initializer.
2105 * opencl-lang.c (opencl_language_data): Likewise.
2106 * p-lang.c (pascal_language_data): Likewise.
2107 (pascal_language::print_typedef): New member function.
2108 * rust-lang.c (rust_print_typedef): Delete function,
2109 implementation moved to rust_language::print_typedef.
2110 (rust_language): Delete la_print_typedef initializer.
2111 (rust_language::print_typedef): New member function,
2112 implementation from rust_print_typedef.
2113 * typeprint.c (default_print_typedef): Delete.
2114
2115 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2116
2117 * ada-lang.c (ada_language_data): Delete la_printstr initializer.
2118 (ada_language::printstr): New member function.
2119 * c-lang.c (c_language_data): Delete la_printstr initializer.
2120 (cplus_language_data): Likewise.
2121 (asm_language_data): Likewise.
2122 (minimal_language_data): Likewise.
2123 * d-lang.c (d_language_data): Likewise.
2124 * f-lang.c (f_printstr): Rename to f_language::printstr.
2125 (f_language_data): Delete la_printstr initializer.
2126 (f_language::printstr): New member function, implementation from
2127 f_printstr.
2128 * go-lang.c (go_language_data): Delete la_printstr initializer.
2129 * language.c (language_defn::printstr): Define new member
2130 function.
2131 (unk_lang_printstr): Delete.
2132 (unknown_language_data): Delete la_printstr initializer.
2133 (unknown_language::printstr): New member function.
2134 (auto_language_data): Delete la_printstr initializer.
2135 (auto_language::printstr): New member function.
2136 * language.h (language_data): Delete la_printstr field.
2137 (language_defn::printstr): Declare new member function.
2138 (LA_PRINT_STRING): Update call to printstr.
2139 * m2-lang.c (m2_printstr): Rename to m2_language::printstr.
2140 (m2_language_data): Delete la_printstr initializer.
2141 (m2_language::printstr): New member function, implementation from
2142 m2_printstr.
2143 * objc-lang.c (objc_language_data): Delete la_printstr
2144 initializer.
2145 * opencl-lang.c (opencl_language_data): Likewise.
2146 * p-lang.c (pascal_printstr): Rename to pascal_language::printstr.
2147 (pascal_language_data): Delete la_printstr initializer.
2148 (pascal_language::printstr): New member function, implementation
2149 from pascal_printstr.
2150 * p-lang.h (pascal_printstr): Delete declaration.
2151 * rust-lang.c (rust_printstr): Update header comment.
2152 (rust_language_data): Delete la_printstr initializer.
2153 (rust_language::printstr): New member function.
2154
2155 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2156
2157 * ada-lang.c (ada_language_data): Delete la_printchar initializer.
2158 (ada_language::printchar): New member function.
2159 * c-lang.c (c_language_data): Delete la_printchar initializer.
2160 (cplus_language_data): Likewise.
2161 (asm_language_data): Likewise.
2162 (minimal_language_data): Likewise.
2163 * d-lang.c (d_language_data): Likewise.
2164 * f-lang.c (f_printchar): Rename to f_language::printchar.
2165 (f_language_data): Delete la_printchar initializer.
2166 (f_language::printchar): New member function, implementation from
2167 f_printchar.
2168 * go-lang.c (go_language_data): Delete la_printchar initializer.
2169 * language.c (unk_lang_printchar): Delete.
2170 (language_defn::printchar): Define new member function.
2171 (unknown_language_data): Delete la_printchar initializer.
2172 (unknown_language::printchar): New member function.
2173 (auto_language_data): Delete la_printchar initializer.
2174 (auto_language::printchar): New member function.
2175 * language.h (language_data): Delete la_printchar field.
2176 (language_defn::printchar): Declare new member function.
2177 (LA_PRINT_CHAR): Update call to printchar.
2178 * m2-lang.c (m2_language_data): Delete la_printchar initializer.
2179 (m2_language::printchar): New member function.
2180 * objc-lang.c (objc_language_data): Delete la_printchar
2181 initializer.
2182 * opencl-lang.c (opencl_language_data): Likewise.
2183 * p-lang.c (pascal_language_data): Delete la_printchar
2184 initializer.
2185 (pascal_language::printchar): New member function.
2186 * rust-lang.c (rust_printchar): Rename to
2187 rust_language::printchar.
2188 (rust_language_data): Delete la_printchar initializer.
2189 (rust_language::printchar): New member function, implementation
2190 from rust_printchar.
2191
2192 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2193
2194 * ada-lang.c (emit_char): Renamed to ada_language::emitchar.
2195 (ada_language_data): Delete la_emitchar initializer.
2196 (ada_language::emitchar): New member function, implementation from
2197 emit_char.
2198 * c-lang.c (c_language_data): Delete la_emitchar initializer.
2199 (cplus_language_data): Likewise.
2200 (asm_language_data): Likewise.
2201 (minimal_language_data): Likewise.
2202 * d-lang.c (d_language_data): Likewise.
2203 * f-lang.c (f_emit_char): Rename to f_language::emitchar.
2204 (f_language_data): Delete la_emitchar initializer.
2205 (f_language::emitchar): New member function, implementation from
2206 f_emit_char.
2207 * go-lang.c (go_language_data): Delete la_emitchar initializer.
2208 * language.c (unk_lang_emit_char): Delete.
2209 (language_defn::emitchar): New member function definition.
2210 (unknown_language_data): Delete la_emitchar initializer.
2211 (unknown_language::emitchar): New member function.
2212 (auto_language_data): Delete la_emitchar initializer.
2213 (auto_language::emitchar): New member function.
2214 * language.h (language_data): Delete la_emitchar field.
2215 (language_defn::emitchar): New member field declaration.
2216 (LA_EMIT_CHAR): Update call to emitchar.
2217 * m2-lang.c (m2_emit_char): Rename to m2_language::emitchar.
2218 (m2_language_data): Delete la_emitchar initializer.
2219 (m2_language::emitchar): New member function, implementation from
2220 m2_emit_char.
2221 * objc-lang.c (objc_language_data): Delete la_emitchar
2222 initializer.
2223 * opencl-lang.c (opencl_language_data): Likewise.
2224 * p-lang.c (pascal_emit_char): Rename to pascal_language::emitchar.
2225 (pascal_language_data): Delete la_emitchar initializer.
2226 (pascal_language::emitchar): New member function, implementation
2227 from pascal_emit_char.
2228 * rust-lang.c (rust_emitchar): Rename to rust_language::emitchar.
2229 (rust_language_data): Delete la_emitchar initializer.
2230 (rust_language::emitchar): New member function, implementation
2231 from rust_emitchar.
2232
2233 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2234
2235 * ada-lang.c (resolve): Rename to ada_language::post_parser.
2236 (ada_language_data): Delete la_post_parser initializer.
2237 (ada_language::post_parser): New member function.
2238 * c-lang.c (c_language_data): Delete la_post_parser initializer.
2239 (cplus_language_data): Likewise.
2240 (asm_language_data): Likewise.
2241 (minimal_language_data): Likewise.
2242 * d-lang.c (d_language_data): Likewise.
2243 * f-lang.c (f_language_data): Likewise.
2244 * go-lang.c (go_language_data): Likewise.
2245 * language.c (unknown_language_data): Likewise.
2246 (auto_language_data): Likewise.
2247 * language.h (language_data): Delete la_post_parser field.
2248 (language_defn::post_parser): New member function.
2249 * m2-lang.c (m2_language_data): Delete la_post_parser initializer.
2250 * objc-lang.c (objc_language_data): Likewise.
2251 * opencl-lang.c (opencl_language_data): Likewise.
2252 * p-lang.c (pascal_language_data): Likewise.
2253 * parse.c (parse_exp_in_context): Update call to post_parser.
2254 (null_post_parser): Delete definition.
2255 * parser-defs.h (null_post_parser): Delete declaration.
2256 * rust-lang.c (rust_language_data): Delete la_post_parser
2257 initializer.
2258
2259 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2260
2261 * ada-lang.c (parse): Rename to ada_language::parser.
2262 (ada_language_data): Delete la_parser initializer.
2263 (ada_language::parser): New member function, implementation from
2264 parse.
2265 * c-lang.c (c_language_data): Delete la_parser initializer.
2266 (cplus_language_data): Likewise.
2267 (asm_language_data): Likewise.
2268 (minimal_language_data): Likewise.
2269 * d-lang.c (d_language_data): Likewise.
2270 (d_language::parser): New member function.
2271 * f-lang.c (f_language_data): Delete la_parser initializer.
2272 (f_language::parser): New member function.
2273 * go-lang.c (go_language_data): Delete la_parser initializer.
2274 (go_language::parser): New member function.
2275 * language.c (unk_lang_parser): Delete.
2276 (language_defn::parser): Define new member function.
2277 (unknown_language_data): Delete la_parser initializer.
2278 (unknown_language::parser): New member function.
2279 (auto_language_data): Delete la_parser initializer.
2280 (auto_language::parser): New member function.
2281 * language.h (language_data): Delete la_parser field.
2282 (language_defn::parser): Declare new member function.
2283 * m2-lang.c (m2_language_data): Delete la_parser initializer.
2284 (m2_language::parser): New member function.
2285 * objc-lang.c (objc_language_data): Delete la_parser initializer.
2286 * opencl-lang.c (opencl_language_data): Likewise.
2287 * p-lang.c (pascal_language_data): Likewise.
2288 (pascal_language::parser): New member function.
2289 * parse.c (parse_exp_in_context): Update call to parser.
2290 * rust-lang.c (rust_language_data): Delete la_parser initializer.
2291 (rust_language::parser): New member function.
2292
2293 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2294
2295 * top.c (print_gdb_configuration): Print --with-python-libdir
2296 configuration value.
2297
2298 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2299
2300 * NEWS: Mention change to the alias command.
2301
2302 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2303
2304 * cli/cli-cmds.c (lookup_cmd_for_default_args)
2305 (alias_command_completer)
2306 (make_alias_options_def_group): New functions.
2307 (alias_opts, alias_option_defs): New struct and array.
2308 (alias_usage_error): Update usage.
2309 (alias_command): Handles optional DEFAULT-ARGS... arguments.
2310 Use option framework.
2311 (_initialize_cli_cmds): Update alias command help.
2312 Update aliases command help.
2313 (show_user):
2314 Add NULL for new default_args lookup_cmd argument.
2315 (valid_command_p): Rename to validate_aliased_command.
2316 Add NULL for new default_args lookup_cmd argument. Verify that the
2317 aliased_command has no default args.
2318 * cli/cli-decode.c (help_cmd): Show aliases definitions.
2319 (lookup_cmd_1, lookup_cmd): New argument default_args.
2320 (add_alias_cmd):
2321 Add NULL for new default_args lookup_cmd argument.
2322 (print_help_for_command): Show default args under the layout
2323 alias some_alias = some_aliased_cmd some_alias_default_arg.
2324 * cli/cli-decode.h (struct cmd_list_element): New member default_args.
2325 xfree default_args in destructor.
2326 * cli/cli-script.c (process_next_line, do_define_command):
2327 Add NULL for new default_args lookup_cmd argument.
2328 * command.h: Declare new default_args argument in lookup_cmd
2329 and lookup_cmd_1.
2330 * completer.c (complete_line_internal_1):
2331 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
2332 * guile/scm-cmd.c (gdbscm_parse_command_name): Likewise.
2333 * guile/scm-param.c (add_setshow_generic, pascm_parameter_defined_p):
2334 Likewise.
2335 * infcmd.c (_initialize_infcmd): Likewise.
2336 * python/py-auto-load.c (gdbpy_initialize_auto_load): Likewise.
2337 * python/py-cmd.c (gdbpy_parse_command_name): Likewise.
2338 * python/py-param.c (add_setshow_generic): Likewise.
2339 * remote.c (_initialize_remote): Likewise.
2340 * top.c (execute_command): Prepend default_args if command has some.
2341 (set_verbose):
2342 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
2343 * tracepoint.c (validate_actionline, encode_actions_1):
2344 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
2345
2346 2020-06-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2347
2348 * jit.c (jit_read_descriptor): Use bool as the return type.
2349 (jit_breakpoint_re_set_internal): Use bool as the return type.
2350 Invert the return value logic; return true if the jit breakpoint
2351 has been successfully initialized.
2352 (jit_inferior_init): Update the call to
2353 jit_breakpoint_re_set_internal.
2354
2355 2020-06-22 Pedro Alves <palves@redhat.com>
2356
2357 PR gdb/25939
2358 * procfs.c (procfs_target::wait): Don't reference inferior_ptid.
2359 Use the current inferior instead. Don't return
2360 TARGET_WAITKIND_SPURIOUS/inferior_ptid -- instead continue and
2361 wait again.
2362 * sol-thread.c (sol_thread_target::wait): Don't reference
2363 inferior_ptid.
2364 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs)
2365 (sol_update_thread_list_callback): Use the current inferior's pid
2366 instead of inferior_ptid.
2367
2368 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2369
2370 * procfs.c: Cleanup many comments.
2371
2372 (READ_WATCHFLAG, WRITE_WATCHFLAG, EXEC_WATCHFLAG)
2373 (AFTER_WATCHFLAG): Replace by value.
2374
2375 (MAIN_PROC_NAME_FORMAT): Inline ...
2376 (create_procinfo): ... here.
2377
2378 (procfs_debug_inferior): Remove SYS_exec handling.
2379 (syscall_is_exec): Likewise.
2380 (procfs_set_exec_trap): Likewise.
2381
2382 (syscall_is_lwp_exit): Inline in callers.
2383 (syscall_is_exit): Likewise.
2384 (syscall_is_exec): Likewise.
2385 (syscall_is_lwp_create): Likewise.
2386
2387 (invalidate_cache): Remove #if 0 code.
2388
2389 (make_signal_thread_runnable): Remove.
2390 (procfs_target::resume): Remove #if 0 code.
2391
2392 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2393
2394 PR gdb/25939
2395 * procfs.c (procfs_target::procfs_init_inferior): Move push_target
2396 call ...
2397 (procfs_target::create_inferior): ... here.
2398
2399 2020-06-21 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2400
2401 * exec.c (validate_exec_file): Ensure the build-id is up to
2402 date by calling reopen_exec_file (that checks file timestamp
2403 to decide to re-read the file).
2404
2405 2020-06-18 Pedro Alves <palves@redhat.com>
2406
2407 PR gdb/25412
2408 * gdbthread.h (delete_thread, delete_thread_silent)
2409 (find_thread_ptid): Update comments.
2410 * thread.c (current_thread_): New global.
2411 (is_current_thread): Move higher, and reimplement.
2412 (inferior_thread): Reimplement.
2413 (set_thread_exited): Use bool. Add assertions.
2414 (add_thread_silent): Simplify thread-reuse handling by always
2415 calling delete_thread.
2416 (delete_thread): Remove intro comment.
2417 (find_thread_ptid): Skip exited threads.
2418 (switch_to_thread_no_regs): Write to current_thread_.
2419 (switch_to_no_thread): Check CURRENT_THREAD_ instead of
2420 INFERIOR_PTID. Clear current_thread_.
2421
2422 2020-06-18 Pedro Alves <palves@redhat.com>
2423
2424 * aix-thread.c (pd_update): Use switch_to_thread.
2425
2426 2020-06-18 Pedro Alves <palves@redhat.com>
2427
2428 * ravenscar-thread.c (ravenscar_thread_target): Update.
2429 (ravenscar_thread_target::update_inferior_ptid): Rename to ...
2430 (ravenscar_thread_target::add_active_thread): ... this. Don't
2431 set m_base_ptid here. Update to avoid referencing inferior_ptid.
2432 (ravenscar_thread_target::wait): Don't write to inferior_ptid.
2433
2434 2020-06-18 Pedro Alves <palves@redhat.com>
2435
2436 * nat/windows-nat.c (current_windows_thread): Remove.
2437 * nat/windows-nat.h (current_windows_thread): Remove.
2438 * windows-nat.c (windows_nat_target::stopped_by_sw_breakpoint):
2439 Adjust.
2440 (display_selectors): Adjust to fetch the current
2441 windows_thread_info based on inferior_ptid.
2442 (fake_create_process): No longer write to current_windows_thread.
2443 (windows_nat_target::get_windows_debug_event):
2444 Don't set inferior_ptid or current_windows_thread.
2445 (windows_nat_target::wait): Adjust to not rely on
2446 current_windows_thread.
2447 (do_initial_windows_stuff): Now a method of windows_nat_target.
2448 Switch to the last_ptid thread.
2449 (windows_nat_target::attach): Adjust.
2450 (windows_nat_target::detach): Use switch_to_no_thread instead of
2451 writing to inferior_ptid directly.
2452 (windows_nat_target::create_inferior): Adjust.
2453
2454 2020-06-18 Pedro Alves <palves@redhat.com>
2455
2456 * windows-nat.c (do_initial_windows_stuff): No longer set inferior_ptid.
2457
2458 2020-06-18 Pedro Alves <palves@redhat.com>
2459
2460 * go32-nat.c (go32_nat_target::create_inferior): Switch to thread
2461 after creating it, instead of writing to inferior_ptid. Don't
2462 write to inferior_ptid.
2463
2464 2020-06-18 Pedro Alves <palves@redhat.com>
2465
2466 * fork-child.c (postfork_hook): Don't write to inferior_ptid.
2467
2468 2020-06-18 Pedro Alves <palves@redhat.com>
2469
2470 * bsd-kvm.c (bsd_kvm_target_open): Switch to thread after adding
2471 it, instead of writing to inferior_ptid.
2472
2473 2020-06-18 Pedro Alves <palves@redhat.com>
2474
2475 * btrace.c (btrace_fetch): Use switch_to_thread instead of writing
2476 to inferior_ptid.
2477
2478 2020-06-18 Pedro Alves <palves@redhat.com>
2479
2480 * bsd-kvm.c (bsd_kvm_target::close): Use switch_to_no_thread
2481 instead of writing to inferior_ptid directly.
2482
2483 2020-06-18 Pedro Alves <palves@redhat.com>
2484
2485 * corelow.c (core_target::close): Use switch_to_no_thread instead
2486 of writing to inferior_ptid directly.
2487 (add_to_thread_list, core_target_open): Use switch_to_thread
2488 instead of writing to inferior_ptid directly.
2489
2490 2020-06-18 Pedro Alves <palves@redhat.com>
2491
2492 * darwin-nat.c (darwin_nat_target::decode_message): Don't write to
2493 inferior_ptid.
2494 (darwin_nat_target::stop_inferior, darwin_nat_target::kill): Avoid
2495 inferior_ptid.
2496 (darwin_attach_pid): Use switch_to_no_thread instead of writing to
2497 inferior_ptid directly.
2498 (darwin_nat_target::init_thread_list): Switch to thread, instead
2499 of writing to inferior_ptid.
2500 (darwin_nat_target::attach): Don't write to inferior_ptid.
2501 (darwin_nat_target::get_ada_task_ptid): Avoid inferior_ptid.
2502
2503 2020-06-18 Pedro Alves <palves@redhat.com>
2504
2505 * gnu-nat.c (gnu_nat_target::create_inferior): Switch to the added
2506 thread.
2507 (gnu_nat_target::attach): Don't write to inferior_ptid directly.
2508 Instead use switch_to_thread.
2509 (gnu_nat_target::detach): Use switch_to_no_thread
2510 instead of writing to inferior_ptid directly. Used passed-in
2511 inferior instead of looking up the inferior by pid.
2512
2513 2020-06-18 Pedro Alves <palves@redhat.com>
2514
2515 * go32-nat.c (go32_nat_target::create_inferior): Don't write to
2516 inferior_ptid.
2517
2518 2020-06-18 Pedro Alves <palves@redhat.com>
2519
2520 * nto-procfs.c (nto_procfs_target::update_thread_list): Avoid
2521 inferior_ptid.
2522 (nto_procfs_target::attach): Avoid inferior_ptid. Switch to
2523 thread.
2524 (nto_procfs_target::detach): Avoid referencing
2525 inferior_ptid. Use switch_to_no_thread instead of writing to
2526 inferior_ptid directly.
2527 (nto_procfs_target::mourn_inferior): Use switch_to_no_thread
2528 instead of writing to inferior_ptid directly.
2529 (nto_procfs_target::create_inferior): Avoid inferior_ptid. Switch
2530 to thread.
2531
2532 2020-06-18 Pedro Alves <palves@redhat.com>
2533
2534 * remote-sim.c (gdbsim_target::create_inferior): Switch to thread
2535 after creating it, instead of writing to inferior_ptid.
2536 (gdbsim_target_open): Use switch_to_no_thread instead of writing
2537 to inferior_ptid directly.
2538 (gdbsim_target::wait): Don't write to inferior_ptid.
2539
2540 2020-06-18 Pedro Alves <palves@redhat.com>
2541
2542 * remote.c (remote_target::remote_notice_new_inferior): Use
2543 switch_to_thread instead of writing to inferior_ptid directly.
2544 (remote_target::add_current_inferior_and_thread): Use
2545 switch_to_no_thread instead of writing to inferior_ptid directly.
2546 (extended_remote_target::attach): Use switch_to_inferior_no_thread
2547 and switch_to_thread instead of using set_current_inferior or
2548 writing to inferior_ptid directly.
2549
2550 2020-06-18 Pedro Alves <palves@redhat.com>
2551
2552 * tracectf.c (ctf_target_open): Switch to added thread instead of
2553 writing to inferior_ptid directly.
2554 (ctf_target::close): Use switch_to_no_thread instead of writing to
2555 inferior_ptid directly.
2556
2557 2020-06-18 Pedro Alves <palves@redhat.com>
2558
2559 * tracefile-tfile.c (tfile_target_open): Don't write to
2560 inferior_ptid directly, instead switch to added thread.
2561 (tfile_target::close): Use switch_to_no_thread instead of writing
2562 to inferior_ptid directly.
2563
2564 2020-06-18 Pedro Alves <palves@redhat.com>
2565
2566 * procfs.c (procfs_target::attach): Don't write to inferior_ptid.
2567 (procfs_target::detach): Use switch_to_no_thread
2568 instead of writing to inferior_ptid directly.
2569 (do_attach): Change return type to void. Switch to the added
2570 thread.
2571 (procfs_target::create_inferior): Switch to the added thread.
2572 (procfs_do_thread_registers): Don't write to inferior_ptid.
2573
2574 2020-06-18 Pedro Alves <palves@redhat.com>
2575
2576 * infrun.c (generic_mourn_inferior): Use switch_to_thread instead
2577 of writing to inferior_ptid.
2578 (scoped_restore_exited_inferior): Delete.
2579 (handle_vfork_child_exec_or_exit): Simplify using
2580 scoped_restore_current_pspace_and_thread. Use switch_to_thread
2581 instead of writing to inferior_ptid.
2582 (THREAD_STOPPED_BY): Delete.
2583 (thread_stopped_by_watchpoint, thread_stopped_by_sw_breakpoint)
2584 (thread_stopped_by_hw_breakpoint): Delete.
2585 (save_waitstatus): Use
2586 scoped_restore_current_thread+switch_to_thread, and call
2587 target_stopped_by_watchpoint instead of
2588 thread_stopped_by_watchpoint, target_stopped_by_sw_breakpoint
2589 instead of thread_stopped_by_sw_breakpoint, and
2590 target_stopped_by_hw_breakpoint instead of
2591 thread_stopped_by_hw_breakpoint.
2592 (handle_inferior_event)
2593 <TARGET_WAITKIND_EXITED/TARGET_WAITKIND_SIGNALLED>: Don't write to
2594 inferior_ptid directly, nor
2595 set_current_inferior/set_current_program_space. Use
2596 switch_to_thread / switch_to_inferior_no_thread instead.
2597
2598 2020-06-18 Pedro Alves <palves@redhat.com>
2599
2600 * target.c (generic_mourn_inferior): Use switch_to_no_thread
2601 instead of writing to inferior_ptid.
2602
2603 2020-06-18 Pedro Alves <palves@redhat.com>
2604
2605 * inf-ptrace.c (inf_ptrace_target::create_inferior): Switch to the
2606 added thread.
2607 (inf_ptrace_target::attach): Don't write to inferior_ptid. Switch
2608 to the added thread.
2609 (inf_ptrace_target::detach_success): Use switch_to_no_thread
2610 instead of writing to inferior_ptid.
2611
2612 2020-06-18 Pedro Alves <palves@redhat.com>
2613
2614 * gdbarch-selftests.c: Include "progspace-and-thread.h".
2615 (register_to_value_test): Mock a program_space too. Heap-allocate
2616 the address space. Don't write to inferior_ptid. Use
2617 switch_to_thread instead.
2618
2619 2020-06-18 Pedro Alves <palves@redhat.com>
2620
2621 * linux-tdep.c (find_signalled_thread(thread_info *,void *)):
2622 Delete.
2623 (find_signalled_thread()): New, factored out from
2624 linux_make_corefile_notes and adjusted to handle exited threads.
2625 (linux_make_corefile_notes): Adjust to use the new
2626 find_signalled_thread.
2627
2628 2020-06-18 Pedro Alves <palves@redhat.com>
2629
2630 * linux-tdep.c (btrace_fetch): Save/restore current thread instead
2631 of saving/restoring inferior_ptid.
2632
2633 2020-06-17 Tom Tromey <tom@tromey.com>
2634
2635 * tui/tui-win.h (tui_scroll_forward, tui_scroll_backward)
2636 (tui_scroll_left, tui_scroll_right, struct tui_win_info): Don't
2637 declare.
2638 * tui/tui-data.h (MIN_CMD_WIN_HEIGHT): Remove.
2639
2640 2020-06-15 Simon Marchi <simon.marchi@efficios.com>
2641
2642 * dwarf2/read.c (dwarf2_initialize_objfile): Check for presence
2643 of partial symtabs.
2644
2645 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
2646
2647 * regformats/reg-arm.dat: Remove.
2648 * regformats/reg-bfin.dat: Remove.
2649 * regformats/reg-cris.dat: Remove.
2650 * regformats/reg-crisv32.dat: Remove.
2651 * regformats/reg-m32r.dat: Remove.
2652 * regformats/reg-tilegx.dat: Remove.
2653 * regformats/reg-tilegx32.dat: Remove.
2654
2655 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
2656
2657 * features/Makefile (WHICH): Remove arm files.
2658 * regformats/arm/arm-with-iwmmxt.dat: Remove.
2659 * regformats/arm/arm-with-neon.dat: Remove.
2660 * regformats/arm/arm-with-vfpv2.dat: Remove.
2661 * regformats/arm/arm-with-vfpv3.dat: Remove.
2662
2663 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
2664
2665 * features/Makefile (XMLTOC): Remove rx.xml.
2666
2667 2020-06-17 Pedro Alves <palves@redhat.com>
2668
2669 * gdbthread.h (thread_control_state) <trap_expected> Update
2670 comments.
2671
2672 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2673
2674 * ada-lang.c (ada_lookup_symbol_nonlocal): Rename to
2675 ada_language::lookup_symbol_nonlocal.
2676 (ada_language_data): Delete la_lookup_symbol_nonlocal initializer.
2677 (ada_language::lookup_symbol_nonlocal): New member function,
2678 implementation from ada_lookup_symbol_nonlocal.
2679 * c-lang.c (c_language_data): Delete la_lookup_symbol_nonlocal
2680 initializer.
2681 (cplus_language_data): Delete la_lookup_symbol_nonlocal
2682 initializer.
2683 (cplus_language::lookup_symbol_nonlocal): New member function.
2684 (asm_language_data): Delete la_lookup_symbol_nonlocal initializer.
2685 (minimal_language_data) Likewise.
2686 * cp-namespace.c (cp_lookup_nested_symbol): Update comment.
2687 * d-lang.c (d_language_data): Delete la_lookup_symbol_nonlocal
2688 initializer.
2689 (d_language::lookup_symbol_nonlocal): New member function.
2690 * f-lang.c (f_language_data): Delete la_lookup_symbol_nonlocal
2691 initializer.
2692 (f_language::lookup_symbol_nonlocal): New member function.
2693 * go-lang.c (go_language_data): Delete la_lookup_symbol_nonlocal
2694 initializer.
2695 * language.c (unknown_language_data): Likewise.
2696 (auto_language_data): Likewise.
2697 * language.h (language_data): Delete la_lookup_symbol_nonlocal
2698 field.
2699 (language_defn::lookup_symbol_nonlocal): New member function.
2700 * m2-lang.c (m2_language_data): Delete la_lookup_symbol_nonlocal
2701 initializer.
2702 * objc-lang.c (objc_language_data): Likewise.
2703 * opencl-lang.c (opencl_language_data): Likewise.
2704 * p-lang.c (pascal_language_data): Likewise.
2705 * rust-lang.c (rust_lookup_symbol_nonlocal): Rename to
2706 rust_language::lookup_symbol_nonlocal.
2707 (rust_language_data): Delete la_lookup_symbol_nonlocal
2708 initializer.
2709 (rust_language::lookup_symbol_nonlocal): New member function,
2710 implementation from rust_lookup_symbol_nonlocal.
2711 * symtab.c (lookup_symbol_aux): Update call to
2712 lookup_symbol_nonlocal.
2713 (basic_lookup_symbol_nonlocal): Rename to...
2714 (language_defn::lookup_symbol_nonlocal): ...this, and update
2715 header comment. Remove language_defn parameter, and replace with
2716 uses of `this'.
2717 * symtab.h (basic_lookup_symbol_nonlocal): Delete declaration.
2718
2719 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2720
2721 * ada-lang.c (ada_language_data): Delete la_value_print_inner
2722 initializer.
2723 (ada_language::value_print_inner): New member function.
2724 * c-lang.c (c_language_data): Delete la_value_print_inner
2725 initializer.
2726 (cplus_language_data): Likewise.
2727 (asm_language_data): Likewise.
2728 (minimal_language_data): Likewise.
2729 * d-lang.c (d_language_data): Likewise.
2730 (d_language::value_print_inner): New member function.
2731 * f-lang.c (f_language_data): Delete la_value_print_inner
2732 initializer.
2733 (f_language::value_print_inner): New member function.
2734 * f-lang.h (f_value_print_innner): Rename to...
2735 (f_value_print_inner): ...this (note spelling of 'inner').
2736 * f-valprint.c (f_value_print_innner): Rename to...
2737 (f_value_print_inner): ...this (note spelling of 'inner').
2738 * go-lang.c (go_language_data): Delete la_value_print_inner
2739 initializer.
2740 (go_language::value_print_inner): New member function.
2741 * language.c (language_defn::value_print_inner): Define new member
2742 function.
2743 (unk_lang_value_print_inner): Delete.
2744 (unknown_language_data): Delete la_value_print_inner initializer.
2745 (unknown_language::value_print_inner): New member function.
2746 (auto_language_data): Delete la_value_print_inner initializer.
2747 (auto_language::value_print_inner): New member function.
2748 * language.h (language_data): Delete la_value_print_inner field.
2749 (language_defn::value_print_inner): Delcare new member function.
2750 * m2-lang.c (m2_language_data): Delete la_value_print_inner
2751 initializer.
2752 (m2_language::value_print_inner): New member function.
2753 * objc-lang.c (objc_language_data): Delete la_value_print_inner
2754 initializer.
2755 * opencl-lang.c (opencl_language_data): Likewise.
2756 * p-lang.c (pascal_language_data): Likewise.
2757 (pascal_language::value_print_inner): New member function.
2758 * rust-lang.c (rust_language_data): Delete la_value_print_inner
2759 initializer.
2760 (rust_language::value_print_inner): New member function.
2761 * valprint.c (do_val_print): Update call to value_print_inner.
2762
2763 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2764
2765 * ada-lang.c (ada_language_data): Delete la_value_print
2766 initializer.
2767 (ada_language::value_print): New member function.
2768 * c-lang.c (c_language_data): Delete la_value_print initializer.
2769 (cplus_language_data): Likewise.
2770 (asm_language_data): Likewise.
2771 (minimal_language_data): Likewise.
2772 * d-lang.c (d_language_data): Likewise.
2773 * f-lang.c (f_language_data): Likewise.
2774 * go-lang.c (go_language_data): Likewise.
2775 * language.c (unk_lang_value_print): Delete.
2776 (language_defn::value_print): Define new member function.
2777 (unknown_language_data): Delete la_value_print initializer.
2778 (unknown_language::value_print): New member function.
2779 (auto_language_data): Delete la_value_print initializer.
2780 (auto_language::value_print): New member function.
2781 * language.h (language_data): Delete la_value_print field.
2782 (language_defn::value_print): Declare new member function.
2783 (LA_VALUE_PRINT): Update call to value_print.
2784 * m2-lang.c (m2_language_data): Delete la_value_print initializer.
2785 * objc-lang.c (objc_language_data): Likewise.
2786 * opencl-lang.c (opencl_language_data): Likewise.
2787 * p-lang.c (pascal_language_data): Likewise.
2788 (pascal_language::value_print): New member function.
2789 * rust-lang.c (rust_language_data): Delete la_value_print
2790 initializer.
2791
2792 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2793
2794 * ada-lang.c (ada_watch_location_expression): Rename to
2795 ada_language::watch_location_expression.
2796 (ada_language_data): Delete la_watch_location_expression
2797 initializer.
2798 (ada_language::watch_location_expression): New member function,
2799 implementation from ada_watch_location_expression.
2800 * breakpoint.c (watch_command_1): Update call to
2801 watch_location_expression.
2802 * c-lang.c (c_watch_location_expression): Rename to
2803 language_defn::watch_location_expression.
2804 (c_language_data): Delete la_watch_location_expression
2805 initializer.
2806 (cplus_language_data): Likewise.
2807 (asm_language_data): Likewise.
2808 (minimal_language_data): Likewise.
2809 * c-lang.h (c_watch_location_expression): Delete declaration.
2810 * d-lang.c (d_language_data): Delete la_watch_location_expression
2811 initializer.
2812 * f-lang.c (f_language_data): Likewise.
2813 * go-lang.c (go_language_data): Likewise.
2814 * language.c (language_defn::watch_location_expression): Member
2815 function implementation from c_watch_location_expression.
2816 (unknown_language_data): Delete la_watch_location_expression
2817 initializer.
2818 (auto_language_data): Likewise.
2819 * language.h (language_data): Delete la_watch_location_expression
2820 field.
2821 (language_defn::watch_location_expression): Declare new member
2822 function.
2823 * m2-lang.c (m2_language_data): Delete
2824 la_watch_location_expression initializer.
2825 * objc-lang.c (objc_language_data): Likewise.
2826 * opencl-lang.c (opencl_language_data): Likewise.
2827 * p-lang.c (pascal_language_data): Likewise.
2828 * rust-lang.c (rust_watch_location_expression): Rename to
2829 rust_language::watch_location_expression.
2830 (rust_language_data): Delete la_watch_location_expression
2831 initializer.
2832 (rust_language::watch_location_expression): New member function,
2833 implementation from rust_watch_location_expression.
2834
2835 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2836
2837 * ada-lang.c (ada_collect_symbol_completion_matches): Rename to
2838 ada_language::collect_symbol_completion_matches.
2839 (ada_language_data): Delete la_collect_symbol_completion_matches
2840 initializer.
2841 (ada_language::collect_symbol_completion_matches): New member
2842 function, implementation from
2843 ada_collect_symbol_completion_matches.
2844 * c-lang.c (c_language_data): Delete
2845 la_collect_symbol_completion_matches initializer.
2846 (cplus_language_data): Likewise.
2847 (asm_language_data): Likewise.
2848 (minimal_language_data): Likewise.
2849 * d-lang.c (d_language_data): Likewise.
2850 * f-lang.c (f_collect_symbol_completion_matches): Rename to
2851 f_language::collect_symbol_completion_matches.
2852 (f_language_data): Delete la_collect_symbol_completion_matches
2853 initializer.
2854 (f_language::collect_symbol_completion_matches) New member
2855 function, implementation from f_collect_symbol_completion_matches.
2856 * go-lang.c (go_language_data): Delete
2857 la_collect_symbol_completion_matches initializer.
2858 * language.c (unknown_language_data): Likewise.
2859 (auto_language_data): Likewise.
2860 * language.h (language_data): Delete
2861 la_collect_symbol_completion_matches field.
2862 (language_defn::collect_symbol_completion_matches): New member
2863 function.
2864 * m2-lang.c (m2_language_data): Delete
2865 la_collect_symbol_completion_matches initializer.
2866 * objc-lang.c (objc_language_data): Likewise.
2867 * opencl-lang.c (opencl_language_data): Likewise.
2868 * p-lang.c (pascal_language_data): Likewise.
2869 * rust-lang.c (rust_language_data): Likewise.
2870 * symtab.c (default_collect_symbol_completion_matches): Delete.
2871 (collect_symbol_completion_matches): Update call to
2872 collect_symbol_completion_matches.
2873 (collect_symbol_completion_matches_type): Likewise.
2874 * symtab.h (default_collect_symbol_completion_matches): Delete
2875 declaration.
2876
2877 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2878
2879 * ada-lang.c (ada_get_gdb_completer_word_break_characters): Delete.
2880 (ada_language_data): Delete la_word_break_characters initializer.
2881 (ada_language::word_break_characters): New member function.
2882 * c-lang.c (c_language_data): Delete la_word_break_characters
2883 initializer.
2884 (cplus_language_data): Likewise.
2885 (asm_language_data): Likewise.
2886 (minimal_language_data): Likewise.
2887 * completer.c: Update global comment.
2888 (advance_to_expression_complete_word_point): Update call to
2889 word_break_characters.
2890 (complete_files_symbols): Likewise.
2891 (complete_line_internal_1): Likewise.
2892 (default_completer_handle_brkchars): Likewise.
2893 (skip_quoted_chars): Likewise.
2894 * d-lang.c (d_language_data): Delete la_word_break_characters
2895 initializer.
2896 * f-lang.c (f_word_break_characters): Delete.
2897 (f_language_data): Delete la_word_break_characters initializer.
2898 (f_language::word_break_characters): New member function.
2899 * go-lang.c (go_language_data): Delete la_word_break_characters
2900 initializer.
2901 * language.c (unknown_language_data): Likewise.
2902 (auto_language_data): Likewise.
2903 * language.h (default_word_break_characters): Move declaration to
2904 earlier in the file.
2905 (language_data): Delete la_word_break_characters field.
2906 (language_defn::word_break_characters): New member function.
2907 * m2-lang.c (m2_language_data): Delete la_word_break_characters
2908 initializer.
2909 * objc-lang.c (objc_language_data): Likewise.
2910 * opencl-lang.c (opencl_language_data): Likewise.
2911 * p-lang.c (pascal_language_data): Likewise.
2912 * rust-lang.c (rust_language_data): Likewise.
2913
2914 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2915
2916 * ada-lang.c (ada_get_symbol_name_matcher): Update header comment.
2917 (ada_language_data): Delete la_get_symbol_name_matcher
2918 initializer.
2919 (language_defn::get_symbol_name_matcher_inner): New member
2920 function.
2921 * c-lang.c (c_language_data): Delete la_get_symbol_name_matcher
2922 initializer.
2923 (cplus_language_data): Likewise.
2924 (cplus_language::get_symbol_name_matcher_inner): New member
2925 function.
2926 (asm_language_data): Delete la_get_symbol_name_matcher initializer.
2927 (minimal_language_data): Likewise.
2928 * cp-support.h (cp_get_symbol_name_matcher): Update header comment.
2929 * d-lang.c (d_language_data): Delete la_get_symbol_name_matcher
2930 initializer.
2931 * dictionary.c (iter_match_first_hashed): Update call to
2932 get_symbol_name_matcher.
2933 (iter_match_next_hashed): Likewise.
2934 (iter_match_next_linear): Likewise.
2935 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Likewise.
2936 * f-lang.c (f_language_data): Delete la_get_symbol_name_matcher
2937 initializer.
2938 (f_language::get_symbol_name_matcher_inner): New member function.
2939 * go-lang.c (go_language_data): Delete la_get_symbol_name_matcher
2940 initializer.
2941 * language.c (default_symbol_name_matcher): Update header comment,
2942 make static.
2943 (language_defn::get_symbol_name_matcher): New definition.
2944 (language_defn::get_symbol_name_matcher_inner): Likewise.
2945 (get_symbol_name_matcher): Delete.
2946 (unknown_language_data): Delete la_get_symbol_name_matcher
2947 initializer.
2948 (auto_language_data): Likewise.
2949 * language.h (language_data): Delete la_get_symbol_name_matcher
2950 field.
2951 (language_defn::get_symbol_name_matcher): New member function.
2952 (language_defn::get_symbol_name_matcher_inner): Likewise.
2953 (default_symbol_name_matcher): Delete declaration.
2954 * linespec.c (find_methods): Update call to
2955 get_symbol_name_matcher.
2956 * m2-lang.c (m2_language_data): Delete la_get_symbol_name_matcher
2957 initializer.
2958 * minsyms.c (lookup_minimal_symbol): Update call to
2959 get_symbol_name_matcher.
2960 (iterate_over_minimal_symbols): Likewise.
2961 * objc-lang.c (objc_language_data): Delete
2962 la_get_symbol_name_matcher initializer.
2963 * opencl-lang.c (opencl_language_data): Likewise.
2964 * p-lang.c (pascal_language_data): Likewise.
2965 * psymtab.c (psymbol_name_matches): Update call to
2966 get_symbol_name_matcher.
2967 * rust-lang.c (rust_language_data): Delete
2968 la_get_symbol_name_matcher initializer.
2969 * symtab.c (symbol_matches_search_name): Update call to
2970 get_symbol_name_matcher.
2971 (compare_symbol_name): Likewise.
2972
2973 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2974
2975 * ada-lang.c (ada_language_data): Delete la_compute_program
2976 initializer.
2977 * c-lang.c (c_language_data): Likewise.
2978 (c_language::compute_program): New member function.
2979 (cplus_language_data): Delete la_compute_program initializer.
2980 (cplus_language::compute_program): New member function.
2981 (asm_language_data): Delete la_compute_program initializer.
2982 (minimal_language_data): Likewise.
2983 * c-lang.h (c_compute_program): Update comment.
2984 (cplus_compute_program): Likewise.
2985 * compile/compile-c-support.c (c_compute_program): Likewise.
2986 (cplus_compute_program): Likewise.
2987 * compile/compile.c (compile_to_object): Update call to
2988 la_compute_program.
2989 * d-lang.c (d_language_data): Delete la_compute_program
2990 initializer.
2991 * f-lang.c (f_language_data): Likewise.
2992 * go-lang.c (go_language_data): Likewise.
2993 * language.c (unknown_language_data): Likewise.
2994 (auto_language_data): Likewise.
2995 * language.h (language_data): Delete la_compute_program field.
2996 (language_defn::compute_program): New member function.
2997 * m2-lang.c (m2_language_data): Delete la_compute_program
2998 initializer.
2999 * objc-lang.c (objc_language_data): Likewise.
3000 * opencl-lang.c (opencl_language_data): Likewise.
3001 * p-lang.c (pascal_language_data): Likewise.
3002 * rust-lang.c (rust_language_data): Likewise.
3003
3004 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
3005
3006 * ada-lang.c (ada_language_data) Delete
3007 la_class_name_from_physname initializer.
3008 * c-lang.c (c_language_data): Likewise.
3009 (cplus_language_data): Likewise.
3010 (cplus_language::class_name_from_physname): New member function.
3011 (asm_language_data): Delete la_class_name_from_physname
3012 initializer.
3013 (minimal_language_data): Likewise.
3014 * d-lang.c (d_language_data): Likewise.
3015 * dwarf2/read.c (guess_partial_die_structure_name): Update to call
3016 method on language_defn class.
3017 (guess_full_die_structure_name): Likewise.
3018 * f-lang.c (f_language_data): Delete la_class_name_from_physname
3019 initializer.
3020 * go-lang.c (go_language_data): Likewise.
3021 * language.c (language_class_name_from_physname): Delete.
3022 (unk_lang_class_name): Delete.
3023 (unknown_language_data): Delete la_class_name_from_physname
3024 initializer.
3025 (auto_language_data): Likewise.
3026 * language.h (language_data): Delete la_class_name_from_physname
3027 field.
3028 (language_defn::class_name_from_physname): New function.
3029 (language_class_name_from_physname): Delete declaration.
3030 * m2-lang.c (m2_language_data): Delete la_class_name_from_physname
3031 initializer.
3032 * objc-lang.c (objc_language_data): Likewise.
3033 * opencl-lang.c (opencl_language_data): Likewise.
3034 * p-lang.c (pascal_language_data): Likewise.
3035 * rust-lang.c (rust_language_data): Likewise.
3036
3037 2020-06-16 Tom Tromey <tom@tromey.com>
3038
3039 * tui/tui-data.h (STATUS_NAME): New macro.
3040 * tui/tui-layout.c (tui_remove_some_windows)
3041 (initialize_known_windows, tui_register_window)
3042 (tui_layout_split::remove_windows, initialize_layouts)
3043 (tui_new_layout_command): Don't use hard-coded window names.
3044
3045 2020-06-16 Tom Tromey <tom@tromey.com>
3046
3047 PR tui/25348:
3048 * tui/tui.c (tui_ensure_readline_initialized): Rename from
3049 tui_initialize_readline. Only run once. Call rl_initialize.
3050 * tui/tui.h (tui_ensure_readline_initialized): Rename from
3051 tui_initialize_readline.
3052 * tui/tui-io.c (tui_setup_io): Call
3053 tui_ensure_readline_initialized.
3054 * tui/tui-interp.c (tui_interp::init): Update.
3055
3056 2020-06-16 Tom Tromey <tom@tromey.com>
3057
3058 * tui/tui-layout.c (tui_layout_split::remove_windows): Fix logic.
3059 Also preserve the status window.
3060
3061 2020-06-16 Tom Tromey <tom@tromey.com>
3062
3063 * python/py-tui.c (tui_py_window::~tui_py_window): Handle case
3064 where m_window==nullptr.
3065
3066 2020-06-15 Tom Tromey <tromey@adacore.com>
3067
3068 * windows-nat.c (windows_nat::handle_output_debug_string):
3069 Update.
3070 (windows_nat::handle_ms_vc_exception): Update.
3071 * target.h (target_read_string): Change API.
3072 * target.c (target_read_string): Change API.
3073 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
3074 Update.
3075 * solib-frv.c (frv_current_sos): Update.
3076 * solib-dsbt.c (dsbt_current_sos): Update.
3077 * solib-darwin.c (darwin_current_sos): Update.
3078 * linux-thread-db.c (inferior_has_bug): Update.
3079 * expprint.c (print_subexp_standard): Update.
3080 * ada-lang.c (ada_main_name, ada_tag_name_from_tsd)
3081 (ada_exception_message_1): Update.
3082
3083 2020-06-15 Tom Tromey <tromey@adacore.com>
3084
3085 * linux-tdep.c (dump_mapping_p): Use target_read_memory.
3086
3087 2020-06-15 Tom Tromey <tromey@adacore.com>
3088
3089 * valprint.c (read_string): Update comment.
3090 * target.c (MIN): Remove.
3091 (target_read_string): Rewrite.
3092
3093 2020-06-15 Tom Tromey <tromey@adacore.com>
3094
3095 * corefile.c (read_memory_string): Remove.
3096 * ada-valprint.c (ada_value_print_ptr): Update.
3097 * ada-lang.h (ada_tag_name): Change return type.
3098 * ada-lang.c (type_from_tag): Update.
3099 (ada_tag_name_from_tsd): Change return type. Use
3100 target_read_string.
3101 (ada_tag_name): Likewise.
3102 * gdbcore.h (read_memory_string): Don't declare.
3103
3104 2020-06-14 Hannes Domani <ssbssa@yahoo.de>
3105
3106 * symtab.c (rbreak_command): Ignore Windows drive colon.
3107
3108 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
3109
3110 * NEWS: Mention removed GDBserver host support.
3111
3112 2020-06-12 Nelson Chu <nelson.chu@sifive.com>
3113
3114 * features/riscv/rebuild-csr-xml.sh: Updated.
3115
3116 2020-06-11 Tom Tromey <tom@tromey.com>
3117
3118 PR gdb/18318:
3119 * c-exp.y (lex_one_token): Handle 'p' like 'e'.
3120
3121 2020-06-09 Jonny Grant <jg@jguk.org>
3122 2020-06-09 Simon Marchi <simon.marchi@polymtl.ca>
3123
3124 * main.c (captured_main_1): Don't print new line after help.
3125 (print_gdb_help): add mailing list and IRC channel information
3126 to --help. Add new lines between items in the footer. Remove
3127 quotes around bug url.
3128
3129 2020-06-11 Keith Seitz <keiths@redhat.com>
3130
3131 PR gdb/21356
3132 * gdbtypes.c (resolve_dynamic_union, resolve_dynamic_struct):
3133 Resolve typedefs for type length calculations.
3134
3135 2020-06-10 Tom de Vries <tdevries@suse.de>
3136
3137 PR ada/24713
3138 * dwarf2/index-write.c (struct mapped_symtab): Add m_string_obstack.
3139 (write_psymbols): Enable .gdb_index for ada.
3140 * dwarf2/read.c: Remove comment stating .gdb_index is unsupported for
3141 ada.
3142
3143 2020-06-10 Tom de Vries <tdevries@suse.de>
3144
3145 * dwarf2/read.c (dw2_symtab_iter_init_common): Factor out of ...
3146 (dw2_symtab_iter_init): ... here. Add variant with "offset_type
3147 namei" instead of "const char *name" argument.
3148 (dw2_map_matching_symbols): Use "offset_type namei" variant of
3149 dw2_symtab_iter_init.
3150
3151 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
3152
3153 * gdbtypes.h (TYPE_FIELD_TYPE): Remove. Change all call sites
3154 to use type::field and field::type instead.
3155
3156 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
3157
3158 * gdbtypes.h (FIELD_TYPE): Remove. Change all call sites
3159 to use field::type instead.
3160
3161 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
3162
3163 * gdbtypes.h (struct field) <type, set_type>: New methods.
3164 Rename `type` field to...
3165 <m_type>: ... this. Change references throughout to use type or
3166 set_type methods.
3167 (FIELD_TYPE): Use field::type. Change call sites that modify
3168 the field's type to use field::set_type instead.
3169
3170 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
3171
3172 * gdbtypes.h (TYPE_INDEX_TYPE): Remove. Change all call sites
3173 to use type::index_type instead.
3174
3175 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
3176
3177 * gdbtypes.h (struct type) <index_type, set_index_type>: New
3178 methods.
3179 (TYPE_INDEX_TYPE): Use type::index_type.
3180 * gdbtypes.c (create_array_type_with_stride): Likewise.
3181
3182 2020-06-07 Tom Tromey <tom@tromey.com>
3183
3184 * valprint.c (generic_val_print_float): Remove "embedded_offset"
3185 parameter.
3186 (generic_value_print): Update.
3187
3188 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
3189
3190 Revert commit 982a38f60b0.
3191 * python/py-tui.c (gdbpy_tui_set_title): Restore use of get.
3192
3193 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
3194
3195 * python/py-tui.c (gdbpy_tui_set_title): Use release, not get, to
3196 avoid use after free.
3197
3198 2020-06-05 Tom de Vries <tdevries@suse.de>
3199
3200 * NEWS: Fix typos.
3201
3202 2020-06-04 Simon Marchi <simon.marchi@efficios.com>
3203
3204 * dwarf2/read.c (dwarf2_read_gdb_index): Save partial_symtabs in
3205 the per_bfd object.
3206 (dwarf2_read_debug_names): Likewise.
3207 (dwarf2_initialize_objfile): Use partial_symtabs from per_bfd
3208 object when re-using a per_bfd object with an index.
3209
3210 2020-06-03 Tom de Vries <tdevries@suse.de>
3211
3212 PR symtab/26046
3213 * dwarf2/read.c (scan_partial_symbols): Recurse into DW_TAG_subprogram
3214 children for C++.
3215 (load_partial_dies): Don't skip DW_TAG_inlined_subroutine child of
3216 DW_TAG_subprogram.
3217
3218 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3219
3220 * ada-lang.c (ada_language_data): Delete skip_trampoline
3221 initializer.
3222 * c-lang.c (c_language_data): Likewise.
3223 (cplus_language_data): Likewise.
3224 (cplus_language::skip_trampoline): New member function.
3225 (asm_language_data): Delete skip_trampoline initializer.
3226 (minimal_language_data): Likewise.
3227 * d-lang.c (d_language_data): Likewise.
3228 * f-lang.c (f_language_data): Likewise.
3229 * go-lang.c (go_language_data): Likewise.
3230 * language.c (unk_lang_trampoline): Delete function.
3231 (skip_language_trampoline): Update.
3232 (unknown_language_data): Delete skip_trampoline initializer.
3233 (auto_language_data): Likewise.
3234 * language.h (language_data): Delete skip_trampoline field.
3235 (language_defn::skip_trampoline): New function.
3236 * m2-lang.c (m2_language_data): Delete skip_trampoline
3237 initializer.
3238 * objc-lang.c (objc_skip_trampoline): Delete function, move
3239 implementation to objc_language::skip_trampoline.
3240 (objc_language_data): Delete skip_trampoline initializer.
3241 (objc_language::skip_trampoline): New member function with
3242 implementation from objc_skip_trampoline.
3243 * opencl-lang.c (opencl_language_data): Delete skip_trampoline
3244 initializer.
3245 * p-lang.c (pascal_language_data): Likewise.
3246 * rust-lang.c (rust_language_data): Likewise.
3247
3248 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3249
3250 * ada-lang.c (ada_language_data): Delete la_demangle initializer.
3251 (ada_language::demangle): New member function.
3252 * c-lang.c (c_language_data): Delete la_demangle initializer.
3253 (cplus_language_data): Delete la_demangle initializer.
3254 (cplus_language::demangle): New member function.
3255 (asm_language_data): Delete la_demangle initializer.
3256 (minimal_language_data): Delete la_demangle initializer.
3257 * d-lang.c (d_language_data): Delete la_demangle initializer.
3258 (d_language::demangle): New member function.
3259 * f-lang.c (f_language_data): Delete la_demangle initializer.
3260 (f_language::demangle): New member function.
3261 * go-lang.c (go_language_data): Delete la_demangle initializer.
3262 (go_language::demangle): New member function.
3263 * language.c (language_demangle): Update.
3264 (unk_lang_demangle): Delete.
3265 (unknown_language_data): Delete la_demangle initializer.
3266 (unknown_language::demangle): New member function.
3267 (auto_language_data): Delete la_demangle initializer.
3268 (auto_language::demangle): New member function.
3269 * language.h (language_data): Delete la_demangle field.
3270 (language_defn::demangle): New function.
3271 * m2-lang.c (m2_language_data): Delete la_demangle initializer.
3272 * objc-lang.c (objc_language_data): Delete la_demangle
3273 initializer.
3274 (objc_language::demangle): New member function.
3275 * opencl-lang.c (opencl_language_data): Delete la_demangle
3276 initializer.
3277 * p-lang.c (pascal_language_data): Likewise.
3278 * rust-lang.c (rust_language_data): Likewise.
3279 (rust_language::demangle): New member function.
3280
3281 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3282
3283 * ada-lang.c (ada_language_data): Delete la_print_type
3284 initializer.
3285 (ada_language::print_type): New member function.
3286 * c-lang.c (c_language_data): Delete la_print_type initializer.
3287 (c_language::print_type): New member function.
3288 (cplus_language_data): Delete la_print_type initializer.
3289 (cplus_language::print_type): New member function.
3290 (asm_language_data): Delete la_print_type initializer.
3291 (asm_language::print_type): New member function.
3292 (minimal_language_data): Delete la_print_type initializer.
3293 (minimal_language::print_type): New member function.
3294 * d-lang.c (d_language_data): Delete la_print_type initializer.
3295 (d_language::print_type): New member function.
3296 * f-lang.c (f_language_data): Delete la_print_type initializer.
3297 (f_language::print_type): New member function.
3298 * go-lang.c (go_language_data): Delete la_print_type initializer.
3299 (go_language::print_type): New member function.
3300 * language.c (unk_lang_print_type): Delete.
3301 (unknown_language_data): Delete la_print_type initializer.
3302 (unknown_language::print_type): New member function.
3303 (auto_language_data): Delete la_print_type initializer.
3304 (auto_language::print_type): New member function.
3305 * language.h (language_data): Delete la_print_type field.
3306 (language_defn::print_type): New function.
3307 (LA_PRINT_TYPE): Update.
3308 * m2-lang.c (m2_language_data): Delete la_print_type initializer.
3309 (m2_language::print_type): New member function.
3310 * objc-lang.c (objc_language_data): Delete la_print_type
3311 initializer.
3312 (objc_language::print_type): New member function.
3313 * opencl-lang.c (opencl_print_type): Delete, implementation moved
3314 to opencl_language::print_type.
3315 (opencl_language_data): Delete la_print_type initializer.
3316 (opencl_language::print_type): New member function, implementation
3317 from opencl_print_type.
3318 * p-lang.c (pascal_language_data): Delete la_print_type
3319 initializer.
3320 (pascal_language::print_type): New member function.
3321 * rust-lang.c (rust_print_type): Delete, implementation moved to
3322 rust_language::print_type.
3323 (rust_language_data): Delete la_print_type initializer.
3324 (rust_language::print_type): New member function, implementation
3325 from rust_print_type.
3326
3327 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3328
3329 * ada-lang.c (ada_sniff_from_mangled_name): Delete function,
3330 implementation moves to...
3331 (ada_language::sniff_from_mangled_name): ...here. Update return
3332 type.
3333 (ada_language_data): Delete la_sniff_from_mangled_name
3334 initializer.
3335 * c-lang.c (c_language_data): Likewise.
3336 (cplus_language_data): Likewise.
3337 (cplus_language::sniff_from_mangled_name): New member function,
3338 implementation taken from gdb_sniff_from_mangled_name.
3339 (asm_language_data): Delete la_sniff_from_mangled_name
3340 initializer.
3341 (minimal_language_data): Likewise.
3342 * cp-support.c (gdb_sniff_from_mangled_name): Delete,
3343 implementation moves to cplus_language::sniff_from_mangled_name.
3344 * cp-support.h (gdb_sniff_from_mangled_name): Delete declaration.
3345 * d-lang.c (d_sniff_from_mangled_name): Delete, implementation
3346 moves to...
3347 (d_language::sniff_from_mangled_name): ...here.
3348 (d_language_data): Delete la_sniff_from_mangled_name initializer.
3349 * f-lang.c (f_language_data): Likewise.
3350 * go-lang.c (go_sniff_from_mangled_name): Delete, implementation
3351 moves to...
3352 (go_language::sniff_from_mangled_name): ...here.
3353 (go_language_data): Delete la_sniff_from_mangled_name initializer.
3354 * language.c (language_sniff_from_mangled_name): Delete.
3355 (unknown_language_data): Delete la_sniff_from_mangled_name
3356 initializer.
3357 (auto_language_data): Likewise.
3358 * language.h (language_data): Delete la_sniff_from_mangled_name
3359 field.
3360 (language_defn::sniff_from_mangled_name): New function.
3361 (language_sniff_from_mangled_name): Delete declaration.
3362 * m2-lang.c (m2_language_data): Delete la_sniff_from_mangled_name
3363 field.
3364 * objc-lang.c (objc_sniff_from_mangled_name): Delete,
3365 implementation moves to...
3366 (objc_language::sniff_from_mangled_name): ...here.
3367 (objc_language_data): Delete la_sniff_from_mangled_name initializer.
3368 * opencl-lang.c (opencl_language_data): Likewise.
3369 * p-lang.c (pascal_language_data): Likewise.
3370 * rust-lang.c (rust_sniff_from_mangled_name): Delete,
3371 implementation moves to...
3372 (rust_language::sniff_from_mangled_name): ...here.
3373 (rust_language_data): Delete la_sniff_from_mangled_name
3374 initializer.
3375 * symtab.c (symbol_find_demangled_name): Call
3376 sniff_from_mangled_name member function.
3377
3378 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3379
3380 * ada-lang.c (ada_language_data): Delete la_search_name_hash
3381 initializer.
3382 * c-lang.c (c_language_data): Likewise.
3383 (cplus_language_data): Likewise.
3384 (cplus_language::search_name_hash): New member function.
3385 (asm_language_data): Delete la_search_name_hash initializer.
3386 (minimal_language_data): Likewise.
3387 * d-lang.c (d_language_data): Likewise.
3388 * dictionary.c (default_search_name_hash): Rename to...
3389 (language_defn::search_name_hash): ...this.
3390 * f-lang.c (f_language_data): Likewise.
3391 (f_language::search_name_hash): New member function.
3392 * go-lang.c (go_language_data): Delete la_search_name_hash
3393 initializer.
3394 * language.c (unknown_language_data): Likewise.
3395 (auto_language_data): Likewise.
3396 * language.h (struct language_data): Delete la_search_name_hash
3397 field.
3398 (language_defn::search_name_hash): Declare new member function.
3399 (default_search_name_hash): Delete declaration.
3400 * m2-lang.c (m2_language_data): Delete la_search_name_hash
3401 initializer.
3402 * objc-lang.c (objc_language_data): Likewise.
3403 * opencl-lang.c (opencl_language_data): Likewise.
3404 * p-lang.c (pascal_language_data): Likewise.
3405 * rust-lang.c (rust_language_data): Likewise.
3406 * symtab.c (search_name_hash): Update call.
3407
3408 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3409
3410 * ada-lang.c (ada_language_data): Delete la_get_compile_instance
3411 initializer.
3412 * c-lang.c (class compile_instance): Declare.
3413 (c_language_data): Delete la_get_compile_instance initializer.
3414 (c_language::get_compile_instance): New member function.
3415 (cplus_language_data): Delete la_get_compile_instance initializer.
3416 (cplus_language::get_compile_instance): New member function.
3417 (asm_language_data): Delete la_get_compile_instance initializer.
3418 (minimal_language_data): Likewise.
3419 * c-lang.h (c_get_compile_context): Update comment.
3420 (cplus_get_compile_context): Update comment.
3421 * compile/compile.c (compile_to_object): Update calls, don't rely
3422 on function pointer being NULL.
3423 * d-lang.c (d_language_data): Delete la_get_compile_instance
3424 initializer.
3425 * f-lang.c (f_language_data): Likewise.
3426 * go-lang.c (go_language_data): Likewise.
3427 * language.c (unknown_language_data): Likewise.
3428 (auto_language_data): Likewise.
3429 * language.h (language_data): Delete la_get_compile_instance field.
3430 (language_defn::get_compile_instance): New member function.
3431 * m2-lang.c (m2_language_data): Delete la_get_compile_instance
3432 initializer.
3433 * objc-lang.c (objc_language_data): Likewise.
3434 * opencl-lang.c (opencl_language_data): Likewise.
3435 * p-lang.c (pascal_language_data): Likewise.
3436 * rust-lang.c (rust_language_data): Likewise.
3437
3438 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3439
3440 * ada-lang.c (ada_add_all_symbols): Update comment.
3441 (ada_iterate_over_symbols): Delete, move implementation to...
3442 (ada_language::iterate_over_symbols): ...here, a new member
3443 function, rewrite to use range based for loop.
3444 (ada_language_data): Delete la_iterate_over_symbols initializer.
3445 * c-lang.c (c_language_data): Likewise.
3446 (cplus_language_data): Likewise.
3447 (asm_language_data): Likewise.
3448 (minimal_language_data): Likewise.
3449 * d-lang.c (d_language_data): Likewise.
3450 * f-lang.c (f_language_data): Likewise.
3451 * go-lang.c (go_language_data): Likewise.
3452 * language.c (unknown_language_data): Likewise.
3453 (auto_language_data): Likewise.
3454 * language.h (language_data): Delete la_iterate_over_symbols field.
3455 (language_defn::iterate_over_symbols): New member function.
3456 (LA_ITERATE_OVER_SYMBOLS): Update.
3457 * linespec.c (iterate_over_all_matching_symtabs): Update.
3458 * m2-lang.c (m2_language_data): Delete la_iterate_over_symbols
3459 initializer.
3460 * objc-lang.c (objc_language_data): Likewise.
3461 * opencl-lang.c (opencl_language_data): Likewise.
3462 * p-lang.c (pascal_language_data): Likewise.
3463 * rust-lang.c (rust_language_data): Likewise.
3464
3465 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3466
3467 * ada-lang.c (ada_language_data): Delete
3468 la_lookup_transparent_type initializer.
3469 * c-lang.c (c_language_data): Likewise.
3470 (cplus_language_data): Likewise.
3471 (cplus_language::lookup_transparent_type): New member function.
3472 (asm_language_data): Delete la_lookup_transparent_type
3473 initializer.
3474 (minimal_language_data): Likewise.
3475 * d-lang.c (d_language_data): Likewise.
3476 * f-lang.c (f_language_data): Likewise.
3477 * go-lang.c (go_language_data): Likewise.
3478 * language.c (unknown_language_data): Likewise.
3479 (auto_language_data): Likewise.
3480 * language.h (struct language_data): Delete
3481 la_lookup_transparent_type field.
3482 (language_defn::lookup_transparent_type): New member function.
3483 * m2-lang.c (m2_language_data): Delete la_lookup_transparent_type
3484 initializer.
3485 * objc-lang.c (objc_language_data): Likewise.
3486 * opencl-lang.c (opencl_language_data): Likewise.
3487 * p-lang.c (pascal_language_data): Likewise.
3488 * rust-lang.c (rust_language_data): Likewise.
3489 * symtab.c (symbol_matches_domain): Update call.
3490
3491 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3492
3493 * ada-lang.c (ada_language_arch_info): Delete function, move
3494 implementation to...
3495 (ada_language::language_arch_info): ...here, a new member
3496 function.
3497 (ada_language_data): Delete la_language_arch_info.
3498 * c-lang.c (c_language_data): Likewise.
3499 (c_language::language_arch_info): New member function.
3500 (cplus_language_arch_info): Delete function, move
3501 implementation to...
3502 (cplus_language::language_arch_info): ...here, a new member
3503 function.
3504 (cplus_language_data): Delete la_language_arch_info.
3505 (asm_language_data): Likewise.
3506 (asm_language::language_arch_info): New member function.
3507 (minimal_language_data): Delete la_language_arch_info.
3508 (minimal_language::language_arch_info): New member function.
3509 * d-lang.c (d_language_arch_info): Delete function, move
3510 implementation to...
3511 (d_language::language_arch_info): ...here, a new member
3512 function.
3513 (d_language_data): Delete la_language_arch_info.
3514 * f-lang.c (f_language_arch_info): Delete function, move
3515 implementation to...
3516 (f_language::language_arch_info): ...here, a new member
3517 function.
3518 (f_language_data): Delete la_language_arch_info.
3519 * go-lang.c (go_language_arch_info): Delete function, move
3520 implementation to...
3521 (go_language::language_arch_info): ...here, a new member
3522 function.
3523 (go_language_data): Delete la_language_arch_info.
3524 * language.c (unknown_language_data): Likewise.
3525 (unknown_language::language_arch_info): New member function.
3526 (auto_language_data): Delete la_language_arch_info.
3527 (auto_language::language_arch_info): New member function.
3528 (language_gdbarch_post_init): Update call to
3529 la_language_arch_info.
3530 * language.h (language_data): Delete la_language_arch_info
3531 function pointer.
3532 (language_defn::language_arch_info): New function.
3533 * m2-lang.c (m2_language_arch_info): Delete function, move
3534 implementation to...
3535 (m2_language::language_arch_info): ...here, a new member
3536 function.
3537 (m2_language_data): Delete la_language_arch_info.
3538 * objc-lang.c (objc_language_arch_info): Delete function, move
3539 implementation to...
3540 (objc_language::language_arch_info): ...here, a new member
3541 function.
3542 (objc_language_data): Delete la_language_arch_info.
3543 * opencl-lang.c (opencl_language_arch_info): Delete function, move
3544 implementation to...
3545 (opencl_language::language_arch_info): ...here, a new member
3546 function.
3547 (opencl_language_data): Delete la_language_arch_info.
3548 * p-lang.c (pascal_language_arch_info): Delete function, move
3549 implementation to...
3550 (pascal_language::language_arch_info): ...here, a new member
3551 function.
3552 (pascal_language_data): Delete la_language_arch_info.
3553 * rust-lang.c (rust_language_arch_info): Delete function, move
3554 implementation to...
3555 (rust_language::language_arch_info): ...here, a new member
3556 function.
3557 (rust_language_data): Delete la_language_arch_info.
3558
3559 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3560
3561 * ada-lang.c (ada_language_data): Delete la_pass_by_reference
3562 initializer.
3563 * c-lang.c (c_language_data): Likewise.
3564 (cplus_language_data): Likewise.
3565 (cplus_language::pass_by_reference_info): New method.
3566 (asm_language_data): Delete la_pass_by_reference initializer.
3567 (minimal_language_data): Likewise.
3568 * cp-abi.c (cp_pass_by_reference): Remove use of
3569 default_pass_by_reference.
3570 * d-lang.c (d_language_data): Likewise.
3571 * f-lang.c (f_language_data): Likewise.
3572 * gnu-v3-abi.c (gnuv3_pass_by_reference): Remove use of
3573 default_pass_by_reference.
3574 * go-lang.c (go_language_data): Likewise.
3575 * language.c (language_pass_by_reference): Update.
3576 (default_pass_by_reference): Delete.
3577 (unknown_language_data): Delete la_pass_by_reference
3578 initializer.
3579 (auto_language_data): Likewise.
3580 * language.h (struct language_data): Delete la_pass_by_reference
3581 field.
3582 (language_defn::pass_by_reference_info): New member function.
3583 (default_pass_by_reference): Delete declaration.
3584 * m2-lang.c (m2_language_data): Delete la_pass_by_reference
3585 initializer.
3586 * objc-lang.c (objc_language_data): Likewise.
3587 * opencl-lang.c (opencl_language_data): Likewise.
3588 * p-lang.c (pascal_language_data): Likewise.
3589 * rust-lang.c (rust_language_data): Likewise.
3590
3591 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3592
3593 * ada-lang.c (ada_read_var_value): Delete function, move
3594 implementation to...
3595 (ada_language::read_var_value): ...here.
3596 (ada_language_data): Delete la_read_var_value initializer.
3597 * c-lang.c (c_language_data): Likewise.
3598 (cplus_language_data): Likewise.
3599 (minimal_language_data): Likewise.
3600 * d-lang.c (d_language_data): Likewise.
3601 * f-lang.c (f_language_data): Likewise.
3602 * findvar.c (default_read_var_value): Rename to...
3603 (language_defn::read_var_value): ...this.
3604 * findvar.c (read_var_value): Update header comment, and change to
3605 call member function instead of function pointer.
3606 * go-lang.c (go_language_data): Likewise.
3607 * language.c (unknown_language_data): Delete la_read_var_value
3608 initializer.
3609 (auto_language_data): Likewise.
3610 * language.h (struct language_data): Delete la_read_var_value
3611 field.
3612 (language_defn::read_var_value): New member function.
3613 (default_read_var_value): Delete declaration.
3614 * m2-lang.c (m2_language_data): Delete la_read_var_value
3615 initializer.
3616 * objc-lang.c (objc_language_data): Likewise.
3617 * opencl-lang.c (opencl_language_data): Likewise.
3618 * p-lang.c (pascal_language_data): Likewise.
3619 * rust-lang.c (rust_language_data): Likewise.
3620 * value.h (default_read_var_value): Delete declaration.
3621
3622 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3623
3624 * ada-lang.c (ada_print_array_index): Delete function, move
3625 implementation to...
3626 (ada_language::print_array_index): ...here.
3627 (ada_language_data): Delete la_print_array_index initializer.
3628 * c-lang.c (c_language_data): Likewise.
3629 (cplus_language_data): Likewise.
3630 (minimal_language_data): Likewise.
3631 * d-lang.c (d_language_data): Likewise.
3632 * f-lang.c (f_language_data): Likewise.
3633 * go-lang.c (go_language_data): Likewise.
3634 * language.c (default_print_array_index): Delete function, move
3635 implementation to...
3636 (language_defn::print_array_index): ...here.
3637 (unknown_language_data): Delete la_print_array_index initializer.
3638 (auto_language_data): Likewise.
3639 * language.h (struct language_data): Delete la_print_array_index
3640 field.
3641 (language_defn::print_array_index): New member function.
3642 (LA_PRINT_ARRAY_INDEX): Update.
3643 (default_print_array_index): Delete declaration.
3644 * m2-lang.c (m2_language_data): Delete la_print_array_index
3645 initializer.
3646 * objc-lang.c (objc_language_data): Likewise.
3647 * opencl-lang.c (opencl_language_data): Likewise.
3648 * p-lang.c (pascal_language_data): Likewise.
3649 * rust-lang.c (rust_language_data): Likewise.
3650
3651 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3652
3653 * gdb/ada-lang.c (ada_language_defn): Convert to...
3654 (ada_language_data): ...this.
3655 (class ada_language): New class.
3656 (ada_language_defn): New static global.
3657 * gdb/c-lang.c (c_language_defn): Convert to...
3658 (c_language_data): ...this.
3659 (class c_language): New class.
3660 (c_language_defn): New static global.
3661 (cplus_language_defn): Convert to...
3662 (cplus_language_data): ...this.
3663 (class cplus_language): New class.
3664 (cplus_language_defn): New static global.
3665 (asm_language_defn): Convert to...
3666 (asm_language_data): ...this.
3667 (class asm_language): New class.
3668 (asm_language_defn): New static global.
3669 (minimal_language_defn): Convert to...
3670 (minimal_language_data): ...this.
3671 (class minimal_language): New class.
3672 (minimal_language_defn): New static global.
3673 * gdb/d-lang.c (d_language_defn): Convert to...
3674 (d_language_data): ...this.
3675 (class d_language): New class.
3676 (d_language_defn): New static global.
3677 * gdb/f-lang.c (f_language_defn): Convert to...
3678 (f_language_data): ...this.
3679 (class f_language): New class.
3680 (f_language_defn): New static global.
3681 * gdb/go-lang.c (go_language_defn): Convert to...
3682 (go_language_data): ...this.
3683 (class go_language): New class.
3684 (go_language_defn): New static global.
3685 * gdb/language.c (unknown_language_defn): Remove declaration.
3686 (current_language): Initialize to nullptr, real initialization is
3687 moved to _initialize_language.
3688 (languages): Delete global.
3689 (language_defn::languages): Define.
3690 (set_language_command): Use language_defn::languages.
3691 (set_language): Likewise.
3692 (range_error): Likewise.
3693 (language_enum): Likewise.
3694 (language_def): Likewise.
3695 (add_set_language_command): Use language_def::languages for the
3696 language list, and language_def to lookup language pointers.
3697 (skip_language_trampoline): Use language_defn::languages.
3698 (unknown_language_defn): Convert to...
3699 (unknown_language_data): ...this.
3700 (class unknown_language): New class.
3701 (unknown_language_defn): New static global.
3702 (auto_language_defn): Convert to...
3703 (auto_language_data): ...this.
3704 (class auto_language): New class.
3705 (auto_language_defn): New static global.
3706 (language_gdbarch_post_init): Use language_defn::languages.
3707 (_initialize_language): Initialize current_language.
3708 * gdb/language.h (struct language_defn): Rename to...
3709 (struct language_data): ...this.
3710 (struct language_defn): New.
3711 (auto_language_defn): Delete.
3712 (unknown_language_defn): Delete.
3713 (minimal_language_defn): Delete.
3714 (ada_language_defn): Delete.
3715 (asm_language_defn): Delete.
3716 (c_language_defn): Delete.
3717 (cplus_language_defn): Delete.
3718 (d_language_defn): Delete.
3719 (f_language_defn): Delete.
3720 (go_language_defn): Delete.
3721 (m2_language_defn): Delete.
3722 (objc_language_defn): Delete.
3723 (opencl_language_defn): Delete.
3724 (pascal_language_defn): Delete.
3725 (rust_language_defn): Delete.
3726 * gdb/m2-lang.c (m2_language_defn): Convert to...
3727 (m2_language_data): ...this.
3728 (class m2_language): New class.
3729 (m2_language_defn): New static global.
3730 * gdb/objc-lang.c (objc_language_defn): Convert to...
3731 (objc_language_data): ...this.
3732 (class objc_language): New class.
3733 (objc_language_defn): New static global.
3734 * gdb/opencl-lang.c (opencl_language_defn): Convert to...
3735 (opencl_language_data): ...this.
3736 (class opencl_language): New class.
3737 (opencl_language_defn): New static global.
3738 * gdb/p-lang.c (pascal_language_defn): Convert to...
3739 (pascal_language_data): ...this.
3740 (class pascal_language): New class.
3741 (pascal_language_defn): New static global.
3742 * gdb/rust-exp.y (rust_lex_tests): Use language_def to find
3743 language pointer, update comment format.
3744 * gdb/rust-lang.c (rust_language_defn): Convert to...
3745 (rust_language_data): ...this.
3746 (class rust_language): New class.
3747 (rust_language_defn): New static global.
3748
3749 2020-06-01 Andrew Burgess <andrew.burgess@embecosm.com>
3750
3751 * dwarf2/read.c (class lnp_state_machine) <m_last_address>: New
3752 member variable.
3753 <m_stmt_at_address>: New member variable.
3754 (lnp_state_machine::record_line): Don't record some lines, update
3755 tracking of is_stmt at the same address.
3756 (lnp_state_machine::lnp_state_machine): Initialise new member
3757 variables.
3758
3759 2020-06-01 Samuel Thibault <samuel.thibault@ens-lyon.org>
3760
3761 * config/i386/i386gnu.mn [%_S.o %_U.o] (COMPILE.post): Add
3762 "-include gnu-nat-mig.h".
3763 * gnu-nat-mig.h: New file.
3764 * gnu-nat.c: Include "gnu-nat-mig.h".
3765 (exc_server, msg_reply_server, notify_server,
3766 process_reply_server): Remove declarations.
3767
3768 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3769
3770 * gnu-nat.h (inf_validate_procs, inf_suspend, inf_set_traced,
3771 steal_exc_port, proc_get_state, inf_clear_wait, inf_cleanup,
3772 inf_startup, inf_update_suspends, inf_set_pid, inf_steal_exc_ports,
3773 inf_validate_procinfo, inf_validate_task_sc, inf_restore_exc_ports,
3774 inf_set_threads_resume_sc, inf_set_threads_resume_sc_for_signal_thread,
3775 inf_resume, inf_set_step_thread, inf_detach, inf_attach, inf_signal,
3776 inf_continue, make_proc, proc_abort, _proc_free, proc_update_sc,
3777 proc_get_exception_port, proc_set_exception_port, _proc_get_exc_port,
3778 proc_steal_exc_port, proc_restore_exc_port, proc_trace): Move functions
3779 to gnu_nat_target class.
3780 * gnu-nat.c: Likewise.
3781 (inf_update_procs, S_proc_wait_reply, set_task_pause_cmd,
3782 set_task_exc_port_cmd, set_signals_cmd, set_thread_pause_cmd,
3783 set_thread_exc_port_cmd): Call inf_validate_procs through gnu_target
3784 object.
3785 (gnu_nat_target::create_inferior, gnu_nat_target::detach): Pass `this'
3786 instead of `gnu_target'.
3787
3788 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3789
3790 * i386-gnu-tdep.c: Include "gdbcore.h"
3791 (gnu_sigtramp_code, i386_gnu_sc_reg_offset): New arrays.
3792 (GNU_SIGTRAMP_LEN, GNU_SIGTRAMP_TAIL,
3793 I386_GNU_SIGCONTEXT_THREAD_STATE_OFFSET): New macros
3794 (i386_gnu_sigtramp_start, i386_gnu_sigtramp_p,
3795 i386_gnu_sigcontext_addr): New functions
3796 (i386gnu_init_abi): Register i386_gnu_sigtramp_p,
3797 i386_gnu_sigcontext_addr, and i386_gnu_sc_reg_offset in the gdbarch
3798 tdep.
3799
3800 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3801
3802 * gnu-nat.c (gnu_nat_target::create_inferior): Move push_target call
3803 before fork_inferior call. Avoid calling it if target_is_pushed returns
3804 true.
3805
3806 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3807
3808 * gnu-nat.h (gnu_target): New variable declaration.
3809 * i386-gnu-nat.c (_initialize_i386gnu_nat): Initialize
3810 gnu_target.
3811 * gnu-nat.c (gnu_target): New variable.
3812 (inf_validate_procs): Pass gnu_target to thread_change_ptid,
3813 add_thread_silent, and add_thread calls.
3814 (gnu_nat_target::create_inferior): Pass gnu_target to
3815 add_thread_silent, thread_change_ptid call.
3816 (gnu_nat_target::detach): Pass gnu_target to detach_inferior
3817 call.
3818
3819 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3820
3821 * gnu-nat.c (gnu_xfer_auxv): Remove unused `res' variable.
3822 (gnu_nat_target::find_memory_regions): Remove unused
3823 `old_address' variable.
3824
3825 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3826
3827 * gnu-nat.c: Include "gdbarch.h".
3828
3829 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3830
3831 * reply_mig_hack.awk (Error return): Cast function through
3832 void *, to bypass compiler function call check.
3833
3834 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3835
3836 * config/i386/i386gnu.mn (%_reply_S.c): Add dependency on
3837 $(srcdir)/reply_mig_hack.awk.
3838
3839 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3840
3841 * gnu-nat.h (gnu_debug_flag): Set type to bool.
3842
3843 2020-05-30 Jonny Grant <jg@jguk.org>
3844
3845 * configure.ac (ACX_BUGURL): change bug URL to https.
3846
3847 2020-05-30 Pedro Alves <palves@redhat.com>
3848
3849 * cp-support.c (replace_typedefs_template): New.
3850 (replace_typedefs_qualified_name): Handle
3851 DEMANGLE_COMPONENT_TEMPLATE.
3852
3853 2020-05-29 Simon Marchi <simon.marchi@efficios.com>
3854
3855 * dwarf2/comp-unit.c, dwarf2/comp-unit.h, dwarf2/index-cache.c,
3856 dwarf2/index-cache.h, dwarf2/index-write.c,
3857 dwarf2/index-write.h, dwarf2/line-header.c,
3858 dwarf2/line-header.h, dwarf2/macro.c, dwarf2/macro.h,
3859 dwarf2/read.c, dwarf2/read.h: Rename struct dwarf2_per_objfile
3860 variables and fields from `dwarf2_per_objfile` to just
3861 `per_objfile` throughout.
3862
3863 2020-05-28 Simon Marchi <simon.marchi@polymtl.ca>
3864
3865 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
3866 <push_dwarf_reg_entry_value>: Add comment.
3867
3868 2020-05-28 Kevin Buettner <kevinb@redhat.com>
3869 Keith Seitz <keiths@redhat.com>
3870
3871 * python/python.c (do_start_initialization): Call PyEval_SaveThread
3872 instead of PyEval_ReleaseLock.
3873 (class gdbpy_gil): Move to earlier in file.
3874 (finalize_python): Set gdb_python_initialized.
3875 (gdbpy_check_quit_flag): Acquire GIL via gdbpy_gil. Return early
3876 when not initialized.
3877
3878 2020-05-28 Simon Marchi <simon.marchi@efficios.com>
3879
3880 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
3881 <push_dwarf_reg_entry_value>: Remove assert. Override
3882 per_objfile with caller_per_objfile.
3883
3884 2020-05-28 Tom de Vries <tdevries@suse.de>
3885
3886 * dwarf2/read.c (dw2_symtab_iter_next, dw2_expand_marked_cus): Limit
3887 PR gold/15646 workaround to symbol kind "type".
3888
3889 2020-05-27 Tom Tromey <tromey@adacore.com>
3890
3891 * dwarf2/read.c (load_partial_dies): Use add_partial_symbol.
3892
3893 2020-05-27 Tom Tromey <tromey@adacore.com>
3894
3895 * dwarf2/abbrev.h (struct abbrev_table) <lookup_abbrev>: Inline.
3896 Use htab_find_with_hash.
3897 <add_abbrev>: Remove "abbrev_number" parameter.
3898 * dwarf2/abbrev.c (abbrev_table::add_abbrev): Remove
3899 "abbrev_number" parameter. Use htab_find_slot_with_hash.
3900 (hash_abbrev): Add comment.
3901 (abbrev_table::lookup_abbrev): Move to header file.
3902 (abbrev_table::read): Update.
3903
3904 2020-05-27 Tom Tromey <tromey@adacore.com>
3905
3906 * dwarf2/read.c (struct partial_die_info) <name>: Declare new
3907 method.
3908 <canonical_name>: New member.
3909 <raw_name>: Rename from "name".
3910 (partial_die_info): Initialize canonical_name.
3911 (scan_partial_symbols): Check raw_name.
3912 (partial_die_parent_scope, partial_die_full_name)
3913 (add_partial_symbol, add_partial_subprogram)
3914 (add_partial_enumeration, load_partial_dies): Use "name" method.
3915 (partial_die_info::name): New method.
3916 (partial_die_info::read, guess_partial_die_structure_name)
3917 (partial_die_info::fixup): Update.
3918
3919 2020-05-27 Tom Tromey <tromey@adacore.com>
3920
3921 * dwarf2/attribute.h (struct attribute) <form_is_ref>: Inline.
3922 <get_ref_die_offset>: Inline.
3923 <get_ref_die_offset_complaint>: New method.
3924 * dwarf2/attribute.c (attribute::form_is_ref): Move to header.
3925 (attribute::get_ref_die_offset_complaint): Rename from
3926 get_ref_die_offset. Just issue complaint.
3927
3928 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
3929
3930 * cli/cli-cmds.c (shell_escape): Move exit_status_set_internal_vars.
3931
3932 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
3933
3934 * exec.c (exec_file_attach): Use errno value of first openp failure.
3935
3936 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
3937
3938 * nat/windows-nat.c (windows_thread_info::~windows_thread_info):
3939 Don't close thread handle.
3940
3941 2020-05-27 Tom Tromey <tom@tromey.com>
3942 Simon Marchi <simon.marchi@efficios.com>
3943
3944 * objfiles.h (struct objfile) <partial_symtabs>: Now a
3945 shared_ptr.
3946 * dwarf2/read.h (struct dwarf2_per_objfile) <partial_symtabs>: New
3947 member.
3948 * dwarf2/read.c (dwarf2_per_bfd_bfd_data_key,
3949 dwarf2_per_bfd_objfile_data_key>: New globals.
3950 (dwarf2_has_info): Use shared dwarf2_per_bfd if possible.
3951 (dwarf2_get_section_info): Use get_dwarf2_per_objfile.
3952 (dwarf2_initialize_objfile): Consider cases where per_bfd can be
3953 shared.
3954 (dwarf2_build_psymtabs): Set objfile::partial_symtabs and
3955 short-circuit when sharing.
3956 (dwarf2_build_psymtabs): Set dwarf2_per_objfile::partial_symtabs.
3957 (dwarf2_psymtab::expand_psymtab): Use free_cached_comp_units.
3958
3959 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3960
3961 * dwarf2/read.h (struct dwarf2_per_bfd) <line_header_hash>: Move
3962 to...
3963 (struct dwarf2_per_objfile) <line_header_hash>: ... here.
3964 * dwarf2/read.c (handle_DW_AT_stmt_list): Update.
3965
3966 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3967
3968 * dwarf2/read.c (struct mapped_index_base) <symbol_name_at,
3969 build_name_components, find_name_components_bounds>:
3970 Add per_objfile parameter.
3971 (struct mapped_index) <symbol_name_at>: Likewise.
3972 (struct mapped_debug_names): Remove constructor.
3973 <dwarf2_per_objfile>: Remove field.
3974 <namei_to_name, symbol_name_at>: Add per_objfile parameter.
3975 (mapped_index_base::find_name_components_bounds,
3976 mapped_index_base::build_name_components,
3977 dw2_expand_symtabs_matching_symbol): Likewise.
3978 (class mock_mapped_index) <symbol_name_at>: Likewise.
3979 (check_match): Likewise.
3980 (check_find_bounds_finds): Likewise.
3981 (test_mapped_index_find_name_component_bounds): Update.
3982 (CHECK_MATCH): Update.
3983 (dw2_expand_symtabs_matching): Update.
3984 (class dw2_debug_names_iterator) <dw2_debug_names_iterator>: Add
3985 per_objfile parameter.
3986 <find_vec_in_debug_names>: Likewise.
3987 <m_per_objfile>: New field.
3988 (mapped_debug_names::namei_to_name): Add dwarf2_per_objfile
3989 parameter.
3990 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
3991 (dw2_debug_names_iterator::next): Update.
3992 (dw2_debug_names_lookup_symbol): Update.
3993 (dw2_debug_names_expand_symtabs_for_function): Update.
3994 (dw2_debug_names_map_matching_symbols): Update.
3995 (dw2_debug_names_expand_symtabs_matching): Update.
3996 (dwarf2_read_debug_names): Update.
3997
3998 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3999
4000 * dwarf2/read.h (struct dwarf2_cu): Forward-declare.
4001 (struct dwarf2_per_bfd) <free_cached_comp_units>: Remove,
4002 move to dwarf2_per_objfile.
4003 <read_in_chain>: Remove.
4004 (struct dwarf2_per_objfile) <get_cu, set_cu, remove_cu,
4005 remove_all_cus, age_comp_units>: New methods.
4006 <m_dwarf2_cus>: New member.
4007 (struct dwarf2_per_cu_data) <cu>: Remove.
4008 * dwarf2/read.c (struct dwarf2_cu) <read_in_chain>: Remove.
4009 (age_cached_comp_units, free_one_cached_comp_unit): Remove,
4010 moved to methods of dwarf2_per_objfile.
4011 (dwarf2_clear_marks): Remove.
4012 (dwarf2_queue_item::~dwarf2_queue_item): Update.
4013 (dwarf2_per_bfd::~dwarf2_per_bfd): Don't free dwarf2_cus.
4014 (dwarf2_per_bfd::free_cached_comp_units): Remove.
4015 (dwarf2_per_objfile::remove_all_cus): New.
4016 (class free_cached_comp_units) <~free_cached_comp_units>:
4017 Update.
4018 (load_cu): Update.
4019 (dw2_do_instantiate_symtab): Adjust.
4020 (fill_in_sig_entry_from_dwo_entry): Adjust.
4021 (cutu_reader::init_tu_and_read_dwo_dies): Update.
4022 (cutu_reader::cutu_reader): Likewise.
4023 (cutu_reader::keep): Use dwarf2_per_objfile::set_cu.
4024 (cutu_reader::cutu_reader): Use dwarf2_per_objfile::get_cu.
4025 (process_psymtab_comp_unit): Use dwarf2_per_objfile::remove_cu
4026 and dwarf2_per_objfile::age_comp_units.
4027 (load_partial_comp_unit): Update.
4028 (maybe_queue_comp_unit): Use dwarf2_per_objfile::get_cu.
4029 (process_queue): Likewise.
4030 (find_partial_die): Use dwarf2_per_objfile::get_cu instead of cu
4031 backlink.
4032 (dwarf2_read_addr_index): Likewise.
4033 (follow_die_offset): Likewise.
4034 (dwarf2_fetch_die_loc_sect_off): Likewise.
4035 (dwarf2_fetch_constant_bytes): Likewise.
4036 (dwarf2_fetch_die_type_sect_off): Likewise.
4037 (follow_die_sig_1): Likewise.
4038 (load_full_type_unit): Likewise.
4039 (read_signatured_type): Likewise.
4040 (dwarf2_cu::dwarf2_cu): Don't set cu field.
4041 (dwarf2_cu::~dwarf2_cu): Remove.
4042 (dwarf2_per_objfile::get_cu): New.
4043 (dwarf2_per_objfile::set_cu): New.
4044 (age_cached_comp_units): Rename to...
4045 (dwarf2_per_objfile::age_comp_units): ... this. Adjust
4046 to std::unordered_map.
4047 (free_one_cached_comp_unit): Rename to...
4048 (dwarf2_per_objfile::remove_cu): ... this. Adjust
4049 to std::unordered_map.
4050 (dwarf2_per_objfile::~dwarf2_per_objfile): New.
4051 (dwarf2_mark_helper): Use dwarf2_per_objfile::get_cu, expect
4052 a dwarf2_per_objfile in data.
4053 (dwarf2_mark): Pass dwarf2_per_objfile in data to htab_traverse.
4054 (dwarf2_clear_marks): Remove.
4055
4056 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4057
4058 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Replace
4059 `int use_existing_cu` parameter with `dwarf2_cu *existing_cu`.
4060 (init_tu_and_read_dwo_dies): Likewise.
4061 (cutu_reader::init_tu_and_read_dwo_dies): Likewise.
4062 (cutu_reader::cutu_reader): Likewise.
4063 (load_partial_comp_unit): Likewise.
4064 (process_psymtab_comp_unit): Update.
4065 (build_type_psymtabs_1): Update.
4066 (process_skeletonless_type_unit): Update.
4067 (load_full_comp_unit): Update.
4068 (find_partial_die): Update.
4069 (dwarf2_read_addr_index): Update.
4070 (read_signatured_type): Update.
4071
4072 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4073
4074 * dwarf2/read.h (struct dwarf2_per_cu_data) <m_header,
4075 m_header_read_in>: New fields.
4076 <get_header>: New method.
4077 * dwarf2/read.c (per_cu_header_read_in): Remove.
4078 (dwarf2_per_cu_data::get_header): New.
4079 (dwarf2_per_cu_data::addr_size): Update.
4080 (dwarf2_per_cu_data::offset_size): Update.
4081 (dwarf2_per_cu_data::ref_addr_size): Update.
4082
4083 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4084
4085 * dwarf2/read.c (load_cu): Return dwarf2_cu.
4086 (dw2_do_instantiate_symtab): Update.
4087 (queue_and_load_all_dwo_tus): Change parameter from
4088 dwarf2_per_cu_data to dwarf2_cu.
4089 (dwarf2_fetch_die_loc_sect_off): Update.
4090 (dwarf2_fetch_constant_bytes): Update.
4091 (dwarf2_fetch_die_type_sect_off): Update.
4092
4093 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4094
4095 * dwarf2/read.c (process_full_comp_unit,
4096 process_full_type_unit): Remove per_cu, per_objfile paramters.
4097 Add dwarf2_cu parameter.
4098 (process_queue): Update.
4099
4100 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4101
4102 * dwarf2/read.c (create_cu_from_index_list): Replace
4103 dwarf2_per_objfile parameter with dwarf2_per_bfd.
4104 (create_cus_from_index_list): Likewise.
4105 (create_cus_from_index): Likewise.
4106 (create_signatured_type_table_from_index): Likewise.
4107 (create_cus_from_debug_names_list): Likewise.
4108 (create_cus_from_debug_names): Likewise.
4109 (dwarf2_read_gdb_index): Update.
4110 (dwarf2_read_debug_names): Update.
4111
4112 2020-05-27 Tom Tromey <tom@tromey.com>
4113 Simon Marchi <simon.marchi@efficios.com>
4114
4115 * dwarf2/read.h (struct dwarf2_per_objfile)
4116 <get_type_for_signatured_type, set_type_for_signatured_type>:
4117 New methods.
4118 <m_type_map>: New member.
4119 (struct signatured_type) <type>: Remove.
4120 * dwarf2/read.c
4121 (dwarf2_per_objfile::get_type_for_signatured_type,
4122 dwarf2_per_objfile::set_type_for_signatured_type): New.
4123 (get_signatured_type): Use new methods.
4124
4125 2020-05-27 Tom Tromey <tom@tromey.com>
4126 Simon Marchi <simon.marchi@efficios.com>
4127
4128 * dwarf2/read.h (struct type_unit_group_unshareable): New.
4129 (struct dwarf2_per_objfile) <type_units>: New member.
4130 <get_type_unit_group_unshareable>: New method.
4131 * dwarf2/read.c (struct type_unit_group) <compunit_symtab,
4132 num_symtabs, symtabs>: Remove; move to
4133 type_unit_group_unshareable.
4134 (dwarf2_per_objfile::get_type_unit_group_unshareable): New.
4135 (process_full_type_unit, dwarf2_cu::setup_type_unit_groups)
4136 (dwarf2_cu::setup_type_unit_groups): Use type_unit_group_unshareable.
4137
4138 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4139
4140 * dwarf2/read.h (struct dwarf2_per_cu_data):
4141 <dwarf2_per_objfile>: Remove.
4142 * dwarf2/read.c (create_cu_from_index_list): Don't assign
4143 dwarf2_per_objfile.
4144 (create_signatured_type_table_from_index): Likewise.
4145 (create_signatured_type_table_from_debug_names): Likewise.
4146 (create_debug_type_hash_table): Likewise.
4147 (fill_in_sig_entry_from_dwo_entry): Likewise.
4148 (create_type_unit_group): Likewise.
4149 (read_comp_units_from_section): Likewise.
4150 (create_cus_hash_table): Likewise.
4151
4152 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4153
4154 * dwarf2/read.c (process_psymtab_comp_unit): Remove reference to
4155 dwarf2_per_cu_data::dwarf2_per_objfile.
4156 (compute_compunit_symtab_includes): Likewise.
4157 (dwarf2_cu::start_symtab): Likewise.
4158
4159 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4160
4161 * dwarf2/read.h (dwarf2_get_die_type): Add dwarf2_per_objfile
4162 parameter.
4163 * dwarf2/read.c (get_die_type_at_offset): Likewise.
4164 (read_namespace_alias): Update.
4165 (lookup_die_type): Update.
4166 (dwarf2_get_die_type): Add dwarf2_per_objfile parameter.
4167 * dwarf2/loc.c (class dwarf_evaluate_loc_desc) <get_base_type>:
4168 Update.
4169 (disassemble_dwarf_expression): Update.
4170
4171 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4172
4173 * dwarf2/read.h (struct dwarf2_queue_item): Add
4174 dwarf2_per_objfile parameter, assign new parameter.
4175 <per_objfile>: New field.
4176 * dwarf2/read.c (free_one_cached_comp_unit): Add
4177 dwarf2_per_objfile parameter.
4178 (queue_comp_unit): Likewise.
4179 (dw2_do_instantiate_symtab): Update.
4180 (process_psymtab_comp_unit): Update.
4181 (maybe_queue_comp_unit): Add dwarf2_per_objfile parameter.
4182 (process_imported_unit_die): Update.
4183 (queue_and_load_dwo_tu): Update.
4184 (follow_die_offset): Update.
4185 (follow_die_sig_1): Update.
4186
4187 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4188
4189 * dwarf2/read.h (struct dwarf2_per_cu_data) <objfile>: Remove.
4190 * dwarf2/read.c (dwarf2_compute_name): Pass per_objfile down.
4191 (read_call_site_scope): Assign per_objfile.
4192 (dwarf2_per_cu_data::objfile): Remove.
4193 * gdbtypes.h (struct call_site) <per_objfile>: New member.
4194 * dwarf2/loc.h (dwarf2_evaluate_loc_desc): Add
4195 dwarf2_per_objfile parameter.
4196 * dwarf2/loc.c (dwarf2_evaluate_loc_desc_full): Add
4197 dwarf2_per_objfile parameter.
4198 (dwarf_expr_reg_to_entry_parameter): Add output
4199 dwarf2_per_objfile parameter.
4200 (locexpr_get_frame_base): Update.
4201 (class dwarf_evaluate_loc_desc) <get_tls_address>: Update.
4202 <push_dwarf_reg_entry_value>: Update.
4203 <call_site_to_target_addr>: Update.
4204 (dwarf_entry_parameter_to_value): Add dwarf2_per_objfile
4205 parameter.
4206 (value_of_dwarf_reg_entry): Update.
4207 (rw_pieced_value): Update.
4208 (indirect_synthetic_pointer): Update.
4209 (dwarf2_evaluate_property): Update.
4210 (dwarf2_loc_desc_get_symbol_read_needs): Add dwarf2_per_objfile
4211 parameter.
4212 (locexpr_read_variable): Update.
4213 (locexpr_get_symbol_read_needs): Update.
4214 (loclist_read_variable): Update.
4215
4216 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4217
4218 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
4219 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
4220 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
4221 parameter.
4222 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
4223 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
4224 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
4225 parameter.
4226 * dwarf2/loc.c (indirect_synthetic_pointer, per_cu_dwarf_call,
4227 sect_variable_value): Add dwarf2_per_objfile parameter.
4228 (class dwarf_evaluate_loc_desc) <dwarf_call,
4229 dwarf_variable_value>: Update.
4230 (fetch_const_value_from_synthetic_pointer): Add
4231 dwarf2_per_objfile parameter.
4232 (fetch_const_value_from_synthetic_pointer): Update.
4233 (coerced_pieced_ref): Update.
4234 (class symbol_needs_eval_context) <dwarf_call,
4235 dwarf_variable_value>: Update.
4236 (dwarf2_compile_expr_to_ax): Update.
4237
4238 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4239
4240 * dwarf2/loc.c (allocate_piece_closure): Add dwarf2_per_objfile
4241 parameter.
4242 (dwarf2_evaluate_loc_desc_full): Update.
4243
4244 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4245
4246 * dwarf2/read.h (dwarf2_read_addr_index): Add dwarf2_per_objfile
4247 parameter.
4248 * dwarf2/read.c (dwarf2_read_addr_index): Likewise.
4249 * dwarf2/loc.c (decode_debug_loclists_addresses): Add
4250 dwarf2_per_objfile parameter.
4251 (decode_debug_loc_dwo_addresses): Likewise.
4252 (dwarf2_find_location_expression): Update.
4253 (class dwarf_evaluate_loc_desc) <get_addr_index>: Update.
4254 (locexpr_describe_location_piece): Add dwarf2_per_objfile
4255 parameter.
4256 (disassemble_dwarf_expression): Add dwarf2_per_objfile
4257 parameter.
4258 (locexpr_describe_location_1): Likewise.
4259 (locexpr_describe_location): Update.
4260
4261 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4262
4263 * dwarf2/read.h (struct dwarf2_per_cu_data) <text_offset>:
4264 Remove.
4265 * dwarf2/read.c (dwarf2_per_cu_data::text_offset): Remove.
4266 * dwarf2/loc.c (dwarf2_find_location_expression): Update.
4267 (dwarf2_compile_property_to_c): Update.
4268 (dwarf2_compile_expr_to_ax): Add dwarf2_per_objfile parameter,
4269 use text offset from objfile.
4270 (locexpr_tracepoint_var_ref): Update.
4271 (locexpr_generate_c_location): Update.
4272 (loclist_describe_location): Update.
4273 (loclist_tracepoint_var_ref): Update.
4274 * dwarf2/compile.h (compile_dwarf_bounds_to_c): Add
4275 dwarf2_per_objfile parameter.
4276 * dwarf2/loc2c.c (do_compile_dwarf_expr_to_c): Likewise,
4277 use text offset from objfile.
4278 (compile_dwarf_expr_to_c): Add dwarf2_per_objfile parameter.
4279
4280 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4281
4282 * dwarf2/expr.h (struct dwarf_expr_context)
4283 <dwarf_expr_context>: Add dwarf2_per_objfile parameter.
4284 <offset>: Remove.
4285 <per_objfile>: New member.
4286 * dwarf2/expr.c (dwarf_expr_context::dwarf_expr_context): Add
4287 dwarf2_per_objfile parameter. Don't set offset, set
4288 per_objfile.
4289 (dwarf_expr_context::execute_stack_op): Use offset from objfile.
4290 * dwarf2/frame.c (dwarf2_frame_find_fde): Return (by parameter)
4291 a dwarf2_per_objfile object instead of an offset.
4292 (class dwarf_expr_executor) <dwarf_expr_executor>: Add
4293 constructor.
4294 (execute_stack_op): Add dwarf2_per_objfile parameter, pass it
4295 to dwarf2_expr_executor constructor. Don't set offset.
4296 (dwarf2_fetch_cfa_info): Update.
4297 (struct dwarf2_frame_cache) <text_offset>: Remove.
4298 <per_objfile>: New field.
4299 (dwarf2_frame_cache): Update.
4300 (dwarf2_frame_prev_register): Update.
4301 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
4302 <dwarf_evaluate_loc_desc>: Add constructor.
4303 (dwarf2_evaluate_loc_desc_full): Update.
4304 (dwarf2_locexpr_baton_eval): Update.
4305 (class symbol_needs_eval_context) <symbol_needs_eval_context>:
4306 Add constructor.
4307 (dwarf2_loc_desc_get_symbol_read_needs): Update.
4308
4309 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4310
4311 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_type,
4312 addr_sized_int_type>: Move to dwarf2_cu.
4313 <int_type>: Move to dwarf2_per_objfile.
4314 (struct dwarf2_per_objfile) <int_type>: Move here.
4315 * dwarf2/read.c (struct dwarf2_cu) <addr_type,
4316 addr_sized_int_type>: Move here.
4317 (read_func_scope): Update.
4318 (read_array_type): Update.
4319 (read_tag_string_type): Update.
4320 (attr_to_dynamic_prop): Update.
4321 (dwarf2_per_cu_data::int_type): Rename to...
4322 (dwarf2_per_objfile::int_type): ... this.
4323 (dwarf2_per_cu_data::addr_sized_int_type): Rename to...
4324 (dwarf2_cu::addr_sized_int_type): ... this.
4325 (read_subrange_type): Update.
4326 (dwarf2_per_cu_data::addr_type): Rename to...
4327 (dwarf2_cu::addr_type): ... this.
4328 (set_die_type): Update.
4329
4330 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4331
4332 * dwarf2/read.c (queue_and_load_all_dwo_tus): Access per_objfile
4333 data through per_cu->cu.
4334
4335 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4336
4337 * dwarf2/read.c (lookup_dwo_comp_unit): Change
4338 dwarf2_per_cu_data parameter fo dwarf2_cu.
4339 (lookup_dwo_type_unit): Likewise.
4340 (read_cutu_die_from_dwo): Likewise.
4341 (lookup_dwo_unit): Likewise.
4342 (open_and_init_dwo_file): Likewise.
4343 (lookup_dwo_cutu): Likewise.
4344 (lookup_dwo_comp_unit): Likewise.
4345 (lookup_dwo_type_unit): Likewise.
4346 (cutu_reader::init_tu_and_read_dwo_dies): Update.
4347 (cutu_reader::cutu_reader): Update.
4348
4349 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4350
4351 * dwarf2/read.c (process_full_comp_unit): Add dwarf2_per_objfile
4352 parameter.
4353 (process_full_type_unit): Likewise.
4354 (process_queue): Update.
4355
4356 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4357
4358 * dwarf2/read.c (recursively_compute_inclusions): Add
4359 dwarf2_per_objfile parameter.
4360 (compute_compunit_symtab_includes): Likewise.
4361 (process_cu_includes): Update.
4362
4363 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4364
4365 * dwarf2/read.c (create_partial_symtab): Add dwarf2_per_objfile
4366 parameter.
4367 (create_type_unit_group): Update.
4368 (process_psymtab_comp_unit_reader): Update.
4369 (build_type_psymtabs_reader): Update.
4370
4371 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4372
4373 * dwarf2/read.c (cutu_reader::keep): Access dwarf2_per_objfile
4374 object through m_this_cu->cu.
4375
4376 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4377
4378 * dwarf2/read.c (queue_and_load_dwo_tu): Expect a dwarf2_cu as
4379 the info parameter.
4380 (queue_and_load_all_dwo_tus): Pass per_cu->cu.
4381
4382 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4383
4384 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Add
4385 per_objfile parameter.
4386 (load_full_type_unit): Add per_objfile parameter.
4387 (read_signatured_type): Likewise.
4388 (load_full_comp_unit): Likewise.
4389 (load_cu): Likewise.
4390 (dw2_do_instantiate_symtab): Likewise.
4391 (dw2_get_file_names): Likewise.
4392 (dw2_map_symtabs_matching_filename): Update.
4393 (dw_expand_symtabs_matching_file_matcher): Update.
4394 (dw2_map_symbol_filenames): Update.
4395 (process_psymtab_comp_unit): Add per_objfile parameter.
4396 (build_type_psymtabs_1): Update.
4397 (process_skeletonless_type_unit): Update.
4398 (dwarf2_build_psymtabs_hard): Update.
4399 (load_partial_comp_unit): Add per_objfile parameter.
4400 (scan_partial_symbols): Update.
4401 (load_full_comp_unit): Add per_objfile parameter.
4402 (process_imported_unit_die): Update.
4403 (create_cus_hash_table): Update.
4404 (find_partial_die): Update.
4405 (dwarf2_read_addr_index): Update.
4406 (follow_die_offset): Update.
4407 (dwarf2_fetch_die_loc_sect_off): Update.
4408 (dwarf2_fetch_constant_bytes): Update.
4409 (dwarf2_fetch_die_type_sect_off): Update.
4410 (follow_die_sig_1): Update.
4411 (load_full_type_unit): Add per_objfile parameter.
4412 (read_signatured_type): Likewise.
4413
4414 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4415
4416 * dwarf2/read.c (lookup_dwo_unit): Use bfd_get_filename instead
4417 of objfile_name.
4418
4419 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4420
4421 * dwarf2/read.h (struct dwarf2_per_bfd) <obfd>: New member.
4422 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
4423 * dwarf2/read.c (dwarf2_per_bfd::dwarf2_per_bfd): Assign obfd
4424 field.
4425 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
4426 (create_cus_from_index): Update.
4427 (dwarf2_read_gdb_index): Update.
4428 (create_cus_from_debug_names): Update.
4429 (dwarf2_read_debug_names): Update.
4430 (get_abbrev_section_for_cu): Update.
4431 (create_all_comp_units): Update.
4432 (read_attribute_value): Update.
4433 (get_debug_line_section): Update.
4434 * dwarf2/index-cache.c (index_cache::store): Update.
4435 * dwarf2/index-write.c (save_gdb_index_command): Update.
4436 * dwarf2/macro.c (dwarf_decode_macro_bytes): Update.
4437
4438 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4439
4440 * dwarf2/read.h (struct dwarf2_per_cu_data) <per_bfd>: New
4441 member.
4442 * dwarf2/read.c (dwarf2_per_bfd::allocate_per_cu): Initialize
4443 dwarf2_per_cu_data::per_bfd.
4444 (dwarf2_per_bfd::allocate_signatured_type): Likewise.
4445 (create_type_unit_group): Likewise.
4446 (queue_comp_unit): Remove reference to
4447 per_cu->dwarf2_per_objfile.
4448 (maybe_queue_comp_unit): Likewise.
4449 (fill_in_sig_entry_from_dwo_entry): Assign new field.
4450 (create_cus_hash_table): Assign new field.
4451
4452 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4453
4454 * dwarf2/read.c: Replace
4455 dwarf2_cu->per_cu->dwarf2_per_objfile references with
4456 dwarf2_cu->per_objfile throughout.
4457
4458 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4459
4460 * dwarf2/read.c (dw2_do_instantiate_symtab): Add per_objfile
4461 parameter, don't use per_cu->dwarf2_per_objfile.
4462 (dw2_instantiate_symtab): Likewise.
4463 (dw2_find_last_source_symtab): Update.
4464 (dw2_map_expand_apply): Update.
4465 (dw2_lookup_symbol): Update.
4466 (dw2_expand_symtabs_for_function): Update.
4467 (dw2_expand_all_symtabs): Update.
4468 (dw2_expand_symtabs_with_fullname): Update.
4469 (dw2_expand_symtabs_matching_one): Add per_objfile parameter,
4470 don't use per_cu->dwarf2_per_objfile.
4471 (dw2_expand_marked_cus): Update.
4472 (dw2_find_pc_sect_compunit_symtab): Update.
4473 (dw2_debug_names_lookup_symbol): Update.
4474 (dw2_debug_names_expand_symtabs_for_function): Update.
4475 (dw2_debug_names_map_matching_symbols): Update.
4476 (dwarf2_psymtab::expand_psymtab): Update.
4477
4478 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4479
4480 * dwarf2/read.c (struct dwarf2_cu) <dwarf2_cu>: Add parameter.
4481 <per_objfile>: New member.
4482 (class cutu_reader) <init_tu_and_read_dwo_dies>: Add parameter.
4483 (cutu_reader::init_tu_and_read_dwo_dies): Add parameter, update
4484 call to dwarf2_cu.
4485 (cutu_reader::cutu_reader): Update.
4486 (dwarf2_cu::dwarf2_cu): Add parameter, initialize per_objfile.
4487
4488 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4489
4490 * dwarf2/read.h (struct dwarf2_per_bfd) <die_type_hash>: Move to
4491 struct dwarf2_per_objfile.
4492 (struct dwarf2_per_objfile) <die_type_hash>: Move from struct
4493 dwarf2_per_bfd.
4494 * dwarf2/read.c (set_die_type): Update.
4495 (get_die_type_at_offset): Update.
4496
4497 2020-05-27 Tom Tromey <tom@tromey.com>
4498 Simon Marchi <simon.marchi@efficios.com>
4499
4500 * dwarf2/read.h (struct dwarf2_per_bfd) <num_psymtabs>: New
4501 method.
4502 (struct dwarf2_per_objfile) <resize_symtabs, symtab_set_p,
4503 get_symtab, set_symtab>: New methods.
4504 <m_symtabs>: New field.
4505 (struct dwarf2_psymtab): Derive from partial_symtab.
4506 <readin_p, get_compunit_symtab>: Declare methods.
4507 * dwarf2/read.c (dwarf2_per_objfile::symtab_set_p,
4508 dwarf2_per_objfile::get_symtab, dwarf2_per_objfile::set_symtab):
4509 New methods.
4510 (struct dwarf2_per_cu_quick_data) <compunit_symtab>: Remove.
4511 (dw2_do_instantiate_symtab, dw2_instantiate_symtab)
4512 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
4513 (dw2_symtab_iter_next, dw2_print_stats)
4514 (dw2_expand_symtabs_with_fullname)
4515 (dw2_expand_symtabs_matching_one)
4516 (dw_expand_symtabs_matching_file_matcher)
4517 (dw2_find_pc_sect_compunit_symtab, dw2_map_symbol_filenames)
4518 (dw2_debug_names_iterator::next)
4519 (dw2_debug_names_map_matching_symbols)
4520 (fill_in_sig_entry_from_dwo_entry, dwarf2_psymtab::read_symtab)
4521 (process_queue, dwarf2_psymtab::expand_psymtab): Update.
4522 (dwarf2_psymtab::readin_p, dwarf2_psymtab::get_compunit_symtab):
4523 New methods.
4524 (get_compunit_symtab, process_full_comp_unit)
4525 (process_full_type_unit): Update.
4526 (dwarf2_build_psymtabs, dwarf2_initialize_objfile, add_type_unit): Call
4527
4528 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4529
4530 * dwarf2/read.h (dwarf2_per_objfile): Rename to dwarf2_per_bfd,
4531 then introduce a new dwarf2_per_objfile type.
4532 <read_line_string>: Move to the new dwarf2_per_objfile type.
4533 <objfile>: Likewise.
4534 (dwarf2_per_bfd): Rename dwarf2_per_objfile to this.
4535 * dwarf2/read.c: Replace references to dwarf2_per_objfile with
4536 dwarf2_per_objfile->per_bfd.
4537 (dwarf2_per_objfile::dwarf2_per_objfile): Rename to...
4538 (dwarf2_per_bfd::dwarf2_per_bfd): ... this.
4539 (dwarf2_per_objfile::free_cached_comp_units): Rename to...
4540 (dwarf2_per_bfd::free_cached_comp_units): ... this.
4541 (dwarf2_has_info): Allocate dwarf2_per_bfd.
4542 (dwarf2_per_objfile::locate_sections): Rename to...
4543 (dwarf2_per_bfd::locate_sections): ... this.
4544 (dwarf2_per_objfile::get_cutu): Rename to...
4545 (dwarf2_per_bfd::get_cutu): ... this.
4546 (dwarf2_per_objfile::get_cu): Rename to...
4547 (dwarf2_per_bfd::get_cu): ... this.
4548 (dwarf2_per_objfile::get_tu): Rename to...
4549 (dwarf2_per_bfd::get_tu): ... this.
4550 (dwarf2_per_objfile::allocate_per_cu): Rename to...
4551 (dwarf2_per_bfd::allocate_per_cu): ... this.
4552 (dwarf2_per_objfile::allocate_signatured_type): Rename to...
4553 (dwarf2_per_bfd::allocate_signatured_type): ... this.
4554 (get_gdb_index_contents_ftype): Change parameter from
4555 dwarf2_per_objfile to dwarf2_per_bfd.
4556 * dwarf2/macro.c, dwarf2/index-write.c: Replace references to
4557 dwarf2_per_objfile with dwarf2_per_objfile->per_bfd.
4558
4559 2020-05-27 Tom Tromey <tom@tromey.com>
4560 Simon Marchi <simon.marchi@efficios.com>
4561
4562 * dwarf2/loc.c (struct piece_closure) <per_objfile>: New member.
4563 (allocate_piece_closure): Set "per_objfile" member.
4564 (dwarf2_find_location_expression, dwarf2_locexpr_baton_eval)
4565 (locexpr_describe_location, loclist_describe_location): Use new
4566 member.
4567 * dwarf2/read.c (read_call_site_scope)
4568 (mark_common_block_symbol_computed, attr_to_dynamic_prop)
4569 (dwarf2_const_value_attr, dwarf2_fetch_die_loc_sect_off)
4570 (fill_in_loclist_baton, dwarf2_symbol_mark_computed,
4571 handle_data_member_location): Set per_objfile member.
4572 * dwarf2/loc.h (struct dwarf2_locexpr_baton) <per_objfile>: New
4573 member.
4574 (struct dwarf2_loclist_baton) <per_objfile>: New member.
4575
4576 2020-05-27 Tom Tromey <tom@tromey.com>
4577
4578 * dwarf2/read.h (struct dwarf2_per_objfile) <allocate_per_cu,
4579 allocate_signatured_type>: Declare new methods.
4580 <m_num_psymtabs>: New member.
4581 (struct dwarf2_per_cu_data) <index>: New member.
4582 * dwarf2/read.c (dwarf2_per_objfile::allocate_per_cu)
4583 (dwarf2_per_objfile::allocate_signatured_type): New methods.
4584 (create_cu_from_index_list): Use allocate_per_cu.
4585 (create_signatured_type_table_from_index)
4586 (create_signatured_type_table_from_debug_names)
4587 (create_debug_type_hash_table, add_type_unit)
4588 (read_comp_units_from_section): Use allocate_signatured_type.
4589
4590 2020-05-27 Tom Tromey <tom@tromey.com>
4591
4592 * psymtab.c (partial_map_expand_apply)
4593 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
4594 (psym_lookup_global_symbol_language)
4595 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
4596 (psym_print_stats, psym_expand_symtabs_for_function)
4597 (psym_map_symbol_filenames, psym_map_matching_symbols)
4598 (psym_expand_symtabs_matching)
4599 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
4600 (maintenance_check_psymtabs): Update.
4601 * psympriv.h (struct partial_symtab) <readin_p,
4602 get_compunit_symtab>: Add objfile parameter.
4603 (struct standard_psymtab) <readin_p, get_compunit_symtab>:
4604 Likewise.
4605 * dwarf2/read.c (struct dwarf2_include_psymtab) <readin_p,
4606 get_compunit_symtab>: Likewise.
4607 (dwarf2_psymtab::expand_psymtab): Pass objfile argument.
4608
4609 2020-05-27 Tom Tromey <tom@tromey.com>
4610
4611 * dwarf2/read.h (struct dwarf2_per_objfile) <obstack>: New
4612 member.
4613 * dwarf2/read.c (delete_file_name_entry): Fix comment.
4614 (create_cu_from_index_list)
4615 (create_signatured_type_table_from_index)
4616 (create_signatured_type_table_from_debug_names)
4617 (dw2_get_file_names_reader, dwarf2_initialize_objfile)
4618 (dwarf2_create_include_psymtab)
4619 (create_debug_type_hash_table, add_type_unit)
4620 (create_type_unit_group, read_comp_units_from_section)
4621 (dwarf2_compute_name, create_cus_hash_table)
4622 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
4623 (create_dwo_unit_in_dwp_v2, open_and_init_dwp_file): Use new
4624 obstack.
4625 (dw2_get_real_path): Likewise. Change argument to
4626 dwarf2_per_objfile.
4627
4628 2020-05-27 Luis Machado <luis.machado@linaro.org>
4629
4630 PR tdep/26000
4631 * arm-tdep.c (thumb_analyze_prologue): Fix instruction matching
4632 for ldrd (immediate).
4633
4634 2020-05-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4635
4636 * command.h: Add comment giving the name of class_tui.
4637 * cli/cli-cmds.c (_initialize_cli_cmds): If TUI defined,
4638 create the fake command for the help for class_tui.
4639
4640 2020-05-26 Tom Tromey <tromey@adacore.com>
4641
4642 * ada-lang.c (ada_print_array_index): Change type. Call val_atr.
4643 (ada_value_ptr_subscript): Don't call pos_atr on the lower bound.
4644 (val_atr): New function.
4645 (value_val_atr): Use it.
4646 * ada-valprint.c (print_optional_low_bound): Change low bound
4647 handling for enums.
4648 (val_print_packed_array_elements): Don't call discrete_position.
4649 * gdbtypes.c (get_discrete_bounds) <TYPE_CODE_RANGE>: Call
4650 discrete_position for enum types.
4651 * language.c (default_print_array_index): Change type.
4652 * language.h (struct language_defn) <la_print_array_index>: Add
4653 index_type parameter, change type of index_value.
4654 (LA_PRINT_ARRAY_INDEX): Add index_type parameter.
4655 (default_print_array_index): Update.
4656 * valprint.c (maybe_print_array_index): Don't call
4657 value_from_longest. Update.
4658 (value_print_array_elements): Don't call discrete_position.
4659
4660 2020-05-26 Tom Tromey <tromey@adacore.com>
4661
4662 * ada-lang.c (value_val_atr): Handle TYPE_CODE_RANGE.
4663 * gdbtypes.c (discrete_position): Handle TYPE_CODE_RANGE.
4664
4665 2020-05-25 Cristiano De Alti <cristiano_dealti@hotmail.com>
4666
4667 PR gdb/13519
4668 * avr-tdep.c (avr_integer_to_address): Return data or code
4669 address accordingly to the second 'type' argument of the
4670 function.
4671
4672 2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
4673
4674 * infcmd.c, inferior.h: (construct_inferior_arguments):
4675 Moved function from here to gdbsupport/common-inferior.{h,cc}
4676
4677 2020-05-23 Tom Tromey <tom@tromey.com>
4678
4679 Revert commit eca1f90c:
4680 * NEWS: Remove entry for completion styling.
4681 * completer.c (_rl_completion_prefix_display_length): Move
4682 declaration later.
4683 (gdb_fnprint): Revert.
4684 (gdb_display_match_list_1): Likewise.
4685 * cli/cli-style.c (completion_prefix_style)
4686 (completion_difference_style, completion_suffix_style): Remove.
4687 (_initialize_cli_style): Revert.
4688 * cli/cli-style.h (completion_prefix_style)
4689 (completion_difference_style, completion_suffix_style): Don't
4690 declare.
4691
4692 2020-05-24 Pedro Alves <palves@redhat.com>
4693
4694 * symtab.c (completion_list_add_name): Return boolean indication
4695 of whether the symbol matched.
4696 (completion_list_add_symbol): Don't try to remove C++ aliases if
4697 the symbol didn't match in the first place.
4698 * symtab.h (completion_list_add_name): Return bool.
4699
4700 2020-05-23 Simon Marchi <simon.marchi@polymtl.ca>
4701
4702 * gdbtypes.h (TYPE_FIELD): Remove. Replace all uses with
4703 type::field.
4704
4705 2020-05-23 Joel Brobecker <brobecker@adacore.com>
4706
4707 GDB 9.2 released.
4708
4709 2020-05-23 Tom Tromey <tom@tromey.com>
4710
4711 * NEWS: Add entry for completion styling.
4712 * completer.c (_rl_completion_prefix_display_length): Move
4713 declaration earlier.
4714 (gdb_fnprint): Use completion_style.
4715 (gdb_display_match_list_1): Likewise.
4716 * cli/cli-style.c (completion_prefix_style)
4717 (completion_difference_style, completion_suffix_style): New
4718 globals.
4719 (_initialize_cli_style): Register new globals.
4720 * cli/cli-style.h (completion_prefix_style)
4721 (completion_difference_style, completion_suffix_style): Declare.
4722
4723 2020-05-23 Pedro Alves <palves@redhat.com>
4724
4725 * utils.c: Include "gdbsupport/gdb-safe-ctype.h".
4726 (parse_escape): Use ISDIGIT instead of isdigit.
4727 (puts_debug): Use gdb_isprint instead of isprint.
4728 (fprintf_symbol_filtered): Use ISALNUM instead of isalnum.
4729 (cp_skip_operator_token, skip_ws, strncmp_iw_with_mode): Use
4730 ISSPACE instead of isspace.
4731 (strncmp_iw_with_mode): Use TOLOWER instead of tolower and ISSPACE
4732 instead of isspace.
4733 (strcmp_iw_ordered): Use ISSPACE instead of isspace.
4734 (string_to_core_addr): Use TOLOWER instead of tolower, ISXDIGIT
4735 instead of isxdigit and ISDIGIT instead of isdigit.
4736
4737 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
4738
4739 * gdbtypes.h (struct type) <field>: New method.
4740 (TYPE_FIELDS): Remove, replace all uses with either type::fields
4741 or type::field.
4742
4743 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
4744
4745 * gdbtypes.h (struct type) <fields, set_fields>: New methods.
4746 (TYPE_FIELDS): Use type::fields. Change all call sites that
4747 modify the propery to use type::set_fields instead.
4748
4749 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
4750
4751 * gdbtypes.h (TYPE_NFIELDS): Remove. Change all cal sites to use
4752 type::num_fields instead.
4753
4754 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
4755
4756 * gdbtypes.h (struct type) <num_fields, set_num_fields>: New
4757 methods.
4758 (TYPE_NFIELDS): Use type::num_fields. Change all call sites
4759 that modify the number of fields to use type::set_num_fields
4760 instead.
4761
4762 2020-05-22 Tom Tromey <tromey@adacore.com>
4763
4764 * compile/compile-object-load.h (munmap_list_free): Don't
4765 declare.
4766
4767 2020-05-22 Andrew Burgess <andrew.burgess@embecosm.com>
4768
4769 * annotate.c (annotate_source_line): Update return type, add call
4770 to update current symtab and line.
4771 * annotate.h (annotate_source_line): Update return type, and
4772 extend header comment.
4773 * source.c (info_line_command): Check annotation_level before
4774 calling annotate_source_line.
4775 * stack.c (print_frame_info): If calling annotate_source_line
4776 returns true, then don't print any other source line information.
4777
4778 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
4779
4780 * lm32-tdep.c (lm32_register_reggroup_p): Fix condition.
4781
4782 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
4783
4784 * coffread.c (patch_type): Remove NULL check before xfree.
4785 * corefile.c (set_gnutarget): Likewise.
4786 * cp-abi.c (set_cp_abi_as_auto_default): Likewise.
4787 * exec.c (build_section_table): Likewise.
4788 * remote.c (remote_target::pass_signals): Likewise.
4789 * utils.c (n_spaces): Likewise.
4790 * cli/cli-script.c (document_command): Likewise.
4791 * i386-windows-tdep.c (core_process_module_section): Likewise.
4792 * linux-fork.c (struct fork_info) <~fork_info>: Likewise.
4793
4794 2020-05-20 Simon Marchi <simon.marchi@efficios.com>
4795
4796 * symfile.c (reread_symbols): Clear objfile's section_offsets
4797 vector and section indices, re-compute them by calling
4798 sym_offsets.
4799
4800 2020-05-20 Tom Tromey <tromey@adacore.com>
4801
4802 * ada-lang.c (bound_name, MAX_ADA_DIMENS): Remove.
4803 (desc_one_bound, desc_index_type): Compute field name.
4804
4805 2020-05-20 Tom de Vries <tdevries@suse.de>
4806
4807 PR symtab/25833
4808 * dwarf2/read.c (dw2_map_matching_symbols): Handle .gdb_index.
4809
4810 2020-05-20 Alan Modra <amodra@gmail.com>
4811
4812 PR 25993
4813 * solib-darwin.c (darwin_bfd_open): Don't strdup pathname for
4814 bfd_set_filename.
4815 * solib-aix.c (solib_aix_bfd_open): Use std::string for name
4816 passed to bfd_set_filename.
4817 * symfile-mem.c (add_vsyscall_page): Likewise for string
4818 passed to symbol_file_add_from_memory.
4819 (symbol_file_add_from_memory): Make name param a const char* and
4820 don't strdup.
4821
4822 2020-05-20 Alan Modra <amodra@gmail.com>
4823
4824 * coff-pe-read.c (read_pe_exported_syms): Use bfd_get_filename
4825 rather than accessing bfd->filename directly.
4826 * dtrace-probe.c (dtrace_static_probe_ops::get_probes): Likewise,
4827 and use bfd_section_name.
4828 * dwarf2/frame.c (decode_frame_entry): Likewise.
4829 * exec.c (exec_set_section_address): Likewise.
4830 * solib-aix.c (solib_aix_bfd_open): Likewise.
4831 * stap-probe.c (get_stap_base_address): Likewise.
4832 * symfile.c (reread_symbols): Likewise.
4833
4834 2020-05-19 Tom Tromey <tromey@adacore.com>
4835
4836 * sparc64-tdep.c (adi_tag_fd): Update call to target_fileio_open.
4837
4838 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
4839
4840 * dwarf2/read.c (quirk_rust_enum): Allocate enough fields.
4841
4842 2020-05-19 Pedro Alves <palves@redhat.com>
4843
4844 * NEWS (set exec-file-mismatch): Adjust entry.
4845 * exec.c: Include "build-id.h".
4846 (validate_exec_file): Try to match build IDs instead of filenames.
4847 * gdb_bfd.c (struct gdb_bfd_open_closure): New.
4848 (gdb_bfd_iovec_fileio_open): Adjust to use gdb_bfd_open_closure
4849 and pass down 'warn_if_slow'.
4850 (gdb_bfd_open): Add 'warn_if_slow' parameter. Use
4851 gdb_bfd_open_closure to pass it down.
4852 * gdb_bfd.h (gdb_bfd_open): Add 'warn_if_slow' parameter.
4853
4854 2020-05-19 Pedro Alves <palves@redhat.com>
4855
4856 * gdb_bfd.c (gdb_bfd_iovec_fileio_open): Adjust.
4857 * target.c (target_fileio_open_1): Rename to target_fileio_open
4858 and make extern. Use bool.
4859 (target_fileio_open, target_fileio_open_warn_if_slow): Delete.
4860 (target_fileio_read_alloc_1): Adjust.
4861 * target.h (target_fileio_open): Add 'warn_if_slow' parameter.
4862 (target_fileio_open_warn_if_slow): Delete declaration.
4863
4864 2020-05-19 Pedro Alves <palves@redhat.com>
4865
4866 * gdb_bfd.h: (gdb_bfd_open): Default to 'fd' parameter to -1.
4867 Adjust all callers.
4868
4869 2020-05-19 Yoshinori Sato <ysato@users.sourceforge.jp>
4870
4871 * h8300-tdep.c (h8300_is_argument_spill): Change how we check
4872 whether disp is negative.
4873
4874 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
4875
4876 * symfile.h (struct symfile_segment_data)
4877 <~symfile_segment_data>: Remove.
4878 <segment_info>: Change to std::vector.
4879 * symfile.c (default_symfile_segments): Update.
4880 * elfread.c (elf_symfile_segments): Update.
4881
4882 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
4883
4884 * symfile.h (struct symfile_segment_data) <struct segment>: New.
4885 <segments>: New.
4886 <segment_bases, segment_sizes>: Remove.
4887 * symfile.c (default_symfile_segments): Update.
4888 * elfread.c (elf_symfile_segments): Update.
4889 * remote.c (remote_target::get_offsets): Update.
4890 * solib-target.c (solib_target_relocate_section_addresses):
4891 Update.
4892
4893 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
4894
4895 * symfile.h (struct symfile_segment_data): Initialize fields.
4896 <~symfile_segment_data>: Add.
4897 (symfile_segment_data_up): New.
4898 (struct sym_fns) <sym_segments>: Return a
4899 symfile_segment_data_up.
4900 (default_symfile_segments): Return a symfile_segment_data_up.
4901 (free_symfile_segment_data): Remove.
4902 (get_symfile_segment_data): Return a symfile_segment_data_up.
4903 * symfile.c (default_symfile_segments): Likewise.
4904 (get_symfile_segment_data): Likewise.
4905 (free_symfile_segment_data): Remove.
4906 (symfile_find_segment_sections): Update.
4907 * elfread.c (elf_symfile_segments): Return a
4908 symfile_segment_data_up.
4909 * remote.c (remote_target::get_offsets): Update.
4910 * solib-target.c (solib_target_relocate_section_addresses):
4911 Update.
4912 * symfile-debug.c (debug_sym_segments): Return a
4913 symfile_segment_data_up.
4914
4915 2020-05-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4916
4917 PR build/25981
4918 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64] (regmap):
4919 Hardcode register numbers.
4920
4921 PR build/25981
4922 * procfs.c [(__i386__ || __x86_64__) && sun] (proc_get_LDT_entry,
4923 procfs_find_LDT_entry): Remove.
4924 * procfs.h [(__i386__ || __x86_64__) && sun] (struct ssd,
4925 procfs_find_LDT_entry): Remove.
4926 * sol-thread.c [(__i386__ || __x86_64__) && sun] (ps_lgetLDT):
4927 Remove.
4928
4929 2020-05-17 Pedro Alves <palves@redhat.com>
4930 Andrew Burgess <andrew.burgess@embecosm.com>
4931 Keno Fischer <keno@juliacomputing.com>
4932
4933 PR gdb/25741
4934 * breakpoint.c (build_target_condition_list): Update comments.
4935 (build_target_command_list): Update comments and skip matching
4936 locations.
4937 (insert_bp_location): Move "set breakpoint auto-hw on" handling to
4938 a separate function. Simplify "set breakpoint auto-hw off"
4939 handling.
4940 (insert_breakpoints): Update comment.
4941 (tracepoint_locations_match): New parameter. For breakpoints,
4942 compare location types too, if the caller wants to.
4943 (handle_automatic_hardware_breakpoints): New functions.
4944 (bp_location_is_less_than): Also sort by location type and
4945 hardware breakpoint length.
4946 (update_global_location_list): Handle "set breakpoint auto-hw on"
4947 here.
4948 (update_breakpoint_locations): Ask breakpoint_locations_match to
4949 ignore location types.
4950
4951 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
4952
4953 * gdbtypes.h (TYPE_NAME): Remove. Change all cal sites to use
4954 type::name instead.
4955
4956 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
4957
4958 * gdbtypes.h (struct type) <name, set_name>: New methods.
4959 (TYPE_CODE): Use type::name. Change all call sites used to set
4960 the name to use type::set_name instead.
4961
4962 2020-05-16 Tom Tromey <tom@tromey.com>
4963
4964 * top.c (quit_force): Update.
4965 * infrun.c (handle_no_resumed): Update.
4966 * top.h (all_uis): New function.
4967 (ALL_UIS): Remove.
4968
4969 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
4970
4971 * mips-linux-tdep.c (mips_linux_in_dynsym_stub): Fix condition.
4972
4973 2020-05-16 Pedro Alves <palves@redhat.com>
4974
4975 * ia64-linux-nat.c
4976 (ia64_linux_nat_target) <enable_watchpoints_in_psr(ptid_t)>:
4977 Declare method.
4978 (enable_watchpoints_in_psr): Now a method of ia64_linux_nat_target.
4979
4980 2020-05-15 Simon Marchi <simon.marchi@efficios.com>
4981
4982 * sparc64-tdep.c (adi_stat_t): Remove typedef (leaving struct).
4983 (sparc64_adi_info): Likewise.
4984
4985 2020-05-15 Tom Tromey <tom@tromey.com>
4986
4987 * symtab.c (lookup_language_this, lookup_symbol_aux): Use
4988 block_objfile.
4989 (lookup_objfile_from_block): Remove.
4990 (lookup_symbol_in_block, lookup_symbol_in_static_block)
4991 (lookup_global_symbol): Use block_objfile.
4992 * symtab.h (lookup_objfile_from_block): Don't declare.
4993 * printcmd.c (clear_dangling_display_expressions): Use
4994 block_objfile.
4995 * parse.c (operator_check_standard): Use block_objfile.
4996
4997 2020-05-15 Tom Tromey <tom@tromey.com>
4998
4999 * language.c (language_alloc_type_symbol): Set
5000 SYMBOL_SECTION.
5001 * symtab.c (initialize_objfile_symbol): Remove.
5002 (allocate_symbol): Remove.
5003 (allocate_template_symbol): Remove.
5004 * dwarf2/read.c (fixup_go_packaging): Use "new".
5005 (new_symbol): Use "new".
5006 (read_variable): Don't call initialize_objfile_symbol. Use
5007 "new".
5008 (read_func_scope): Use "new".
5009 * xcoffread.c (process_xcoff_symbol): Don't call
5010 initialize_objfile_symbol.
5011 (SYMBOL_DUP): Remove.
5012 * coffread.c (process_coff_symbol, coff_read_enum_type): Use
5013 "new".
5014 * symtab.h (allocate_symbol, initialize_objfile_symbol)
5015 (allocate_template_symbol): Don't declare.
5016 (struct symbol): Add copy constructor. Change defaults.
5017 * jit.c (finalize_symtab): Use "new".
5018 * ctfread.c (ctf_add_enum_member_cb, new_symbol, ctf_add_var_cb):
5019 Use "new".
5020 * stabsread.c (patch_block_stabs, define_symbol, read_enum_type)
5021 (common_block_end): Use "new".
5022 * mdebugread.c (parse_symbol): Use "new".
5023 (new_symbol): Likewise.
5024
5025 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5026
5027 * NEWS: Mention changes to help and apropos.
5028
5029 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5030
5031 * command.h (enum command_class): Improve comments, document
5032 that class_alias is for user-defined aliases, give the class
5033 name for each class, remove unused class_xdb.
5034 * cli/cli-decode.c (add_com_alias): Document THECLASS intended usage.
5035 * breakpoint.c (_initialize_breakpoint): Replace class_alias
5036 by a precise class.
5037 * infcmd.c (_initialize_infcmd): Likewise.
5038 * reverse.c (_initialize_reverse): Likewise.
5039 * stack.c (_initialize_stack): Likewise.
5040 * symfile.c (_initialize_symfile): Likewise.
5041 * tracepoint.c (_initialize_tracepoint): Likewise.
5042
5043 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5044
5045 * cli/cli-decode.c (apropos_cmd): Produce output for aliases
5046 when their aliased command is traversed.
5047 (help_cmd): Add fput_command_names_styled call to
5048 output command name and aliases when command has an alias.
5049
5050 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5051
5052 * cli/cli-decode.h (help_cmd_list): Remove declaration.
5053 * cli/cli-decode.c (help_cmd_list): Declare as static,
5054 remove prefix argument, use bool for recurse arg, rework to show the aliases of
5055 a command together with the command.
5056 (fput_command_name_styled, fput_command_names_styled): New functions.
5057 (print_help_for_command): Remove prefix arg, use bool for recurse arg, use
5058 fput_command_name_styled.
5059 (help_list, help_all): Update callers to remove prefix arg and use bool recurse.
5060 * cli/cli-cmds.c (_initialize_cli_cmds): Update alias_command doc.
5061
5062 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5063
5064 * cli/cli-setshow.h (cmd_show_list): Remove prefix argument.
5065 * cli/cli-decode.c (do_show_prefix_cmd): Likewise.
5066 * command.h (cmd_show_list): Likewise.
5067 * dwarf2/index-cache.c (show_index_cache_command): Likewise.
5068 * cli/cli-setshow.c (cmd_show_list): Use the prefix to produce the output. Skip aliases.
5069
5070 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5071
5072 * unittests/command-def-selftests.c (traverse_command_structure):
5073 Verify all commands of a list have the same prefix command and
5074 that only the top cmdlist commands have a null prefix.
5075
5076 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5077
5078 * cli/cli-decode.c (lookup_cmd_for_prefix): Return the aliased command
5079 as prefix, not one of its aliases.
5080 (set_cmd_prefix): Remove.
5081 (do_add_cmd): Centralize the setting of the prefix of a command, when
5082 command is defined after its full chain of prefix commands.
5083 (add_alias_cmd): Remove call to set_cmd_prefix, as do_add_cmd does it.
5084 (add_setshow_cmd_full): Likewise.
5085 (update_prefix_field_of_prefixed_commands): New function.
5086 (add_prefix_cmd): Replace non working call to set_cmd_prefix by
5087 update_prefix_field_of_prefixed_commands.
5088 * gdb/remote-fileio.c (initialize_remote_fileio): Use the real
5089 addresses of remote_set_cmdlist and remote_show_cmdlist given
5090 as argument, not the address of an argument.
5091 * gdb/remote-fileio.h (initialize_remote_fileio): Likewise.
5092 * gdb/remote.c (_initialize_remote): Likewise.
5093
5094 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5095
5096 * cli/cli-cmds.c (alias_command): Check for an existing alias
5097 using lookup_cmd_composition, as valid_command_p is too strict
5098 and forbids aliases that are the prefix of an existing alias
5099 or command.
5100 * cli/cli-decode.c (lookup_cmd_composition): Ensure a prefix
5101 command is properly recognised as a valid command.
5102
5103 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5104
5105 * unittests/help-doc-selftests.c: Rename to
5106 unittests/command-def-selftests.c
5107 * unittests/command-def-selftests.c (help_doc_tests): Update some
5108 comments.
5109 (command_structure_tests, traverse_command_structure): New namespace
5110 and function.
5111 (command_structure_invariants_tests): New function.
5112 (_initialize_command_def_selftests) Renamed from
5113 _initialize_help_doc_selftests, register command_structure_invariants
5114 selftest.
5115
5116 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5117
5118 * cli/cli-cmds.c (_initialize_cli_cmds): Define 'info set' as
5119 an alias of 'show'.
5120
5121 2020-05-15 Joel Brobecker <brobecker@adacore.com>
5122
5123 * ada-lang.h: (ada_is_gnat_encoded_fixed_point_type): Renames
5124 ada_is_fixed_point_type. Update all callers.
5125 (gnat_encoded_fixed_point_delta): Renames ada_delta. Update
5126 all callers.
5127 * ada-lang.c (gnat_encoded_fixed_type_info): Renames fixed_type_info.
5128 Update all callers.
5129 * ada-typeprint.c (print_gnat_encoded_fixed_point_type): Renames
5130 print_fixed_point_type. Update all callers.
5131 * ada-valprint.c (ada_value_print_num): Replace call to
5132 ada_is_fixed_point_type by ada_is_gnat_encoded_fixed_point_type.
5133
5134 2020-05-14 Kevin Buettner <kevinb@redhat.com>
5135
5136 * nat/linux-btrace.c (btrace_this_cpu): Add check for AMD
5137 processors.
5138 (cpu_supports_bts): Add CV_AMD case.
5139
5140 2020-05-14 Laurent Morichetti <Laurent.Morichetti@amd.com>
5141 Simon Marchi <simon.marchi@efficios.com>
5142
5143 * infrun.c (stop_all_threads): Collect multiple wait events at
5144 each pass.
5145
5146 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
5147
5148 * gdbtypes.h (TYPE_CODE): Remove. Change all call sites to use
5149 type::code instead.
5150
5151 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
5152
5153 * gdbtypes.h (struct type) <code, set_code>: New methods.
5154 (TYPE_CODE): Use type::code. Change all call sites used to set
5155 the code to use type::set_code instead.
5156
5157 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5158 Tom de Vries <tdevries@suse.de>
5159 Pedro Alves <palves@redhat.com>
5160
5161 PR threads/25478
5162 * infrun.c (stop_all_threads): Do NOT ignore
5163 TARGET_WAITKIND_NO_RESUMED, TARGET_WAITKIND_THREAD_EXITED,
5164 TARGET_WAITKIND_EXITED, TARGET_WAITKIND_SIGNALLED wait statuses
5165 received.
5166 (handle_no_resumed): Remove code handling a live inferior with no
5167 threads.
5168 * remote.c (has_single_non_exited_thread): New.
5169 (remote_target::update_thread_list): Do not delete a thread if is
5170 the last thread of the process.
5171 * thread.c (thread_select): Call delete_exited_threads instead of
5172 prune_threads.
5173
5174 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5175
5176 * infrun.c (stop_all_threads): Enable/disable thread events of all
5177 targets. Move a debug message denoting the end of the function
5178 into the SCOPED_EXIT block.
5179
5180 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5181
5182 * process-stratum-target.h: Include <set>.
5183 (all_non_exited_process_targets, switch_to_target_no_thread): New
5184 function declarations.
5185 * process-stratum-target.c (all_non_exited_process_targets)
5186 (switch_to_target_no_thread): New function implementations.
5187
5188 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5189
5190 * infrun.c (handle_inferior_event): Extract out a piece of code
5191 into...
5192 (mark_non_executing_threads): ...this new function.
5193
5194 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5195
5196 * infrun.c (resume_1): Move a 'regcache_read_pc' call down to first
5197 use.
5198
5199 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5200
5201 * regcache.c (regcache_read_pc_protected): New function
5202 implementation that returns 0 if the PC cannot read via
5203 'regcache_read_pc'.
5204 * infrun.c (proceed): Call 'regcache_read_pc_protected'
5205 instead of 'regcache_read_pc'.
5206 (keep_going_pass_signal): Ditto.
5207
5208 2020-05-13 Tom Tromey <tromey@adacore.com>
5209
5210 * ada-lang.c (align_value): Remove.
5211 (ada_template_to_fixed_record_type_1): Use align_up.
5212
5213 2020-05-13 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5214
5215 * async-event.c: Update the copyright year.
5216 * async-event.h: Update the copyright year.
5217
5218 2020-05-12 Simon Marchi <simon.marchi@efficios.com>
5219
5220 * objfiles.h (is_addr_in_objfile,
5221 shared_objfile_contains_address_p): Return bool.
5222 * objfile.c (is_addr_in_objfile,
5223 shared_objfile_contains_address_p): Return bool.
5224
5225 2020-05-11 Tom Tromey <tromey@adacore.com>
5226
5227 * cli/cli-cmds.c (info_command): Restore.
5228 (_initialize_cli_cmds): Use add_prefix_command for "info".
5229 * gdb-gdb.gdb.in: Restore breakpoint on info_command.
5230
5231 2020-05-11 Tom Tromey <tromey@adacore.com>
5232
5233 * ada-lang.c (ada_value_primitive_field): Now public.
5234 * ada-lang.h (ada_value_primitive_field): Declare.
5235 * ada-valprint.c (print_field_values): Use
5236 ada_value_primitive_field for wrapper fields.
5237
5238 2020-05-11 Tom de Vries <tdevries@suse.de>
5239
5240 * dwarf2/index-write.c (debug_names::psymbol_tag): Handle
5241 MODULE_DOMAIN.
5242
5243 2020-05-11 Tom de Vries <tdevries@suse.de>
5244
5245 PR symtab/25941
5246 * dwarf2/read.c (create_cus_from_debug_names_list): Initialize CUs
5247 with length 0, if not gdb-produced.
5248 (cutu_reader::cutu_reader): Set CU length to actual length if 0.
5249
5250 2020-05-09 Tom de Vries <tdevries@suse.de>
5251
5252 PR gdb/25955
5253 * break-catch-throw.c (check_status_exception_catchpoint): Fix name
5254 calculation.
5255
5256 2020-05-09 Tom Tromey <tom@tromey.com>
5257
5258 * top.c (server_command): Now bool.
5259 * top.h (server_command): Now bool.
5260
5261 2020-05-08 Tom Tromey <tromey@adacore.com>
5262
5263 * dwarf2/read.c (read_lexical_block_scope): Don't process a DIE
5264 already being processed.
5265
5266 2020-05-08 Tom Tromey <tom@tromey.com>
5267
5268 * printcmd.c (struct display) <next>: Remove.
5269 <display>: New constructor.
5270 <exp_string>: Now a std::string.
5271 <enabled_p>: Now a bool.
5272 (display_number): Move definition earlier.
5273 (displays): Rename from display_chain. Now a std::vector.
5274 (ALL_DISPLAYS, ALL_DISPLAYS_SAFE): Remove.
5275 (display_command): Update.
5276 (do_one_display, disable_display)
5277 (enable_disable_display_command, do_enable_disable_display):
5278 Update.
5279 (free_display): Remove.
5280 (clear_displays): Rewrite.
5281 (delete_display): Update.
5282 (map_display_numbers): Use function_view. Remove "data"
5283 parameter. Update.
5284 (do_delete_display): Remove.
5285 (undisplay_command): Update.
5286 (do_one_display, do_displays, disable_display)
5287 (info_display_command): Update.
5288 (do_enable_disable_display): Remove.
5289 (enable_disable_display_command)
5290 (clear_dangling_display_expressions): Update.
5291
5292 2020-05-08 Tom Tromey <tom@tromey.com>
5293
5294 * symtab.c (set_symbol_cache_size)
5295 (maintenance_print_symbol_cache, maintenance_flush_symbol_cache)
5296 (maintenance_print_symbol_cache_statistics): Update.
5297 * symmisc.c (print_symbol_bcache_statistics)
5298 (print_objfile_statistics, maintenance_print_objfiles)
5299 (maintenance_info_symtabs, maintenance_check_symtabs)
5300 (maintenance_expand_symtabs, maintenance_info_line_tables):
5301 Update.
5302 * symfile-debug.c (set_debug_symfile): Update.
5303 * source.c (forget_cached_source_info): Update.
5304 * python/python.c (gdbpy_progspaces): Update.
5305 * psymtab.c (maintenance_info_psymtabs): Update.
5306 * probe.c (parse_probes): Update.
5307 * linespec.c (iterate_over_all_matching_symtabs)
5308 (collect_symtabs_from_filename, search_minsyms_for_name): Update.
5309 * guile/scm-progspace.c (gdbscm_progspaces): Update.
5310 * exec.c (exec_target::close): Update.
5311 * ada-tasks.c (ada_tasks_new_objfile_observer): Update.
5312 * breakpoint.c (print_one_breakpoint_location)
5313 (create_longjmp_master_breakpoint)
5314 (create_std_terminate_master_breakpoint): Update.
5315 * progspace.c (program_spaces): Now a std::vector.
5316 (maybe_new_address_space): Update.
5317 (add_program_space): Remove.
5318 (program_space::program_space): Update.
5319 (remove_program_space): Update.
5320 (number_of_program_spaces): Remove.
5321 (print_program_space, update_address_spaces): Update.
5322 * progspace.h (program_spaces): Change type.
5323 (ALL_PSPACES): Remove.
5324 (number_of_program_spaces): Don't declare.
5325 (struct program_space) <next>: Remove.
5326
5327 2020-05-08 Tom Tromey <tom@tromey.com>
5328
5329 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Update.
5330 * solib-svr4.c (svr4_fetch_objfile_link_map): Update.
5331 (enable_break): Update.
5332 * solib-frv.c (frv_fdpic_find_global_pointer): Update.
5333 (frv_fdpic_find_canonical_descriptor): Update.
5334 (frv_fetch_objfile_link_map): Update.
5335 * progspace.c (program_space::free_all_objfiles): Update.
5336 (program_space::solibs): New method.
5337 * progspace.h (struct program_space) <solibs>: New method.
5338 * solist.h (master_so_list): Don't declare.
5339 (ALL_SO_LIBS): Remove.
5340 * solib.h (so_list_head): Remove.
5341 (update_solib_list): Update comment.
5342 * solib.c (master_so_list): Remove.
5343 (solib_used, update_solib_list, solib_add)
5344 (info_sharedlibrary_command, clear_solib)
5345 (reload_shared_libraries_1, remove_user_added_objfile): Update.
5346
5347 2020-05-08 Tom Tromey <tom@tromey.com>
5348
5349 * extension.c (extension_languages): Now a std::array.
5350 (ALL_EXTENSION_LANGUAGES): Remove.
5351 (get_ext_lang_defn, get_ext_lang_of_file)
5352 (eval_ext_lang_from_control_command): Update.
5353 (finish_ext_lang_initialization)
5354 (auto_load_ext_lang_scripts_for_objfile)
5355 (ext_lang_type_printers::ext_lang_type_printers)
5356 (apply_ext_lang_type_printers)
5357 (ext_lang_type_printers::~ext_lang_type_printers)
5358 (apply_ext_lang_val_pretty_printer, apply_ext_lang_frame_filter)
5359 (preserve_ext_lang_values, get_breakpoint_cond_ext_lang)
5360 (breakpoint_ext_lang_cond_says_stop, check_quit_flag)
5361 (get_matching_xmethod_workers, ext_lang_colorize)
5362 (ext_lang_before_prompt): Update.
5363 (ALL_ENABLED_EXTENSION_LANGUAGES): Remove.
5364
5365 2020-05-08 Tom Tromey <tom@tromey.com>
5366
5367 * symtab.h (class demangle_result_storage) <set_malloc_ptr>: New
5368 overload.
5369 <swap_string, m_string>: Remove.
5370 * symtab.c (demangle_for_lookup, completion_list_add_symbol):
5371 Update.
5372 * stabsread.c (define_symbol, read_type): Update.
5373 * linespec.c (find_linespec_symbols): Update.
5374 * gnu-v3-abi.c (gnuv3_get_typeid): Update.
5375 * dwarf2/read.c (dwarf2_canonicalize_name): Update.
5376 * dbxread.c (read_dbx_symtab): Update.
5377 * cp-support.h (cp_canonicalize_string_full)
5378 (cp_canonicalize_string, cp_canonicalize_string_no_typedefs):
5379 Return unique_xmalloc_ptr.
5380 * cp-support.c (inspect_type): Update.
5381 (cp_canonicalize_string_full): Return unique_xmalloc_ptr.
5382 (cp_canonicalize_string_no_typedefs, cp_canonicalize_string):
5383 Likewise.
5384 * c-typeprint.c (print_name_maybe_canonical): Update.
5385 * break-catch-throw.c (check_status_exception_catchpoint):
5386 Update.
5387
5388 2020-05-08 Tom de Vries <tdevries@suse.de>
5389
5390 * infrun.c (follow_fork): Copy current_line and current_symtab to
5391 child thread.
5392
5393 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
5394
5395 * async-event.c (struct async_signal_handler, struct
5396 async_event_handler): Reformat, remove typedef.
5397
5398 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
5399
5400 * gdbtypes.h (TYPE_DYN_PROP_LIST): Remove. Update all users
5401 access thistype->main_type->dyn_prop_list directly.
5402
5403 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
5404
5405 * gdbtypes.h (struct type) <remove_dyn_prop>: New method.
5406 (remove_dyn_prop): Remove. Update all users to use
5407 type::remove_dyn_prop.
5408 * gdbtypes.c (remove_dyn_prop): Rename to...
5409 (type::remove_dyn_prop): ... this.
5410
5411 2020-05-07 Simon Marchi via Gdb-patches <gdb-patches@sourceware.org>
5412
5413 * gdbtypes.h (struct type) <add_dyn_prop>: New method.
5414 (add_dyn_prop): Remove. Update all users to use
5415 type::add_dyn_prop.
5416 * gdbtypes.c (add_dyn_prop): Rename to...
5417 (type::add_dyn_prop): ... this.
5418
5419 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
5420
5421 * gdbtypes.h (struct type) <get_dyn_prop>: New method.
5422 (get_dyn_prop): Remove. Update all users to use
5423 type::dyn_prop.
5424 * gdbtypes.c (get_dyn_prop): Rename to...
5425 (type::dyn_prop): ... this.
5426
5427 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
5428
5429 * gdbtypes.h (struct main_type) <flag_static>: Remove.
5430
5431 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
5432
5433 * amd64-tdep.c (amd64_analyze_prologue): Check for `endbr64`
5434 instruction, skip it if it's there.
5435
5436 2020-05-05 Simon Marchi <simon.marchi@efficios.com>
5437
5438 * gdbtypes.h (struct main_type) <flag_incomplete>: Remove.
5439
5440 2020-05-04 Simon Marchi <simon.marchi@efficios.com>
5441
5442 * gdbtypes.h (TYPE_INCOMPLETE): Remove.
5443 * gdbtypes.c (recursive_dump_type): Remove use of
5444 TYPE_INCOMPLETE.
5445
5446 2020-05-03 Tom Tromey <tom@tromey.com>
5447
5448 * breakpoint.c (catch_command, tcatch_command): Remove.
5449 (_initialize_breakpoint): Use add_basic_prefix_cmd,
5450 add_show_prefix_cmd.
5451 (set_breakpoint_cmd, show_breakpoint_cmd): Remove
5452 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
5453 Remove.
5454 (add_internal_problem_command): Use add_basic_prefix_cmd,
5455 add_show_prefix_cmd.
5456 * mips-tdep.c (set_mipsfpu_command): Remove.
5457 (_initialize_mips_tdep): Use add_basic_prefix_cmd.
5458 * dwarf2/index-cache.c (set_index_cache_command): Remove.
5459 (_initialize_index_cache): Use add_basic_prefix_cmd.
5460 * memattr.c (dummy_cmd): Remove.
5461 (_initialize_mem): Use add_basic_prefix_cmd, add_show_prefix_cmd.
5462 * tui/tui-win.c (set_tui_cmd, show_tui_cmd): Remove.
5463 (_initialize_tui_win): Use add_basic_prefix_cmd,
5464 add_show_prefix_cmd.
5465 * cli/cli-logging.c (set_logging_command): Remove.
5466 (_initialize_cli_logging): Use add_basic_prefix_cmd,
5467 add_show_prefix_cmd.
5468 (show_logging_command): Remove.
5469 * target.c (target_command): Remove.
5470 (add_target): Use add_basic_prefix_cmd.
5471
5472 2020-05-02 Hannes Domani <ssbssa@yahoo.de>
5473
5474 * gdbtypes.h (enum dynamic_prop_node_kind): Fix typo.
5475
5476 2020-05-01 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5477
5478 * gdb-gdb.gdb-in: Remove breakpoint on disappeared function
5479 info_command.
5480
5481 2020-04-30 Kamil Rytarowski <n54@gmx.com>
5482
5483 * nbsd-nat.c (nbsd_enable_proc_events)
5484 (nbsd_nat_target::post_startup_inferior): Add.
5485 (nbsd_nat_target::post_attach): Call `nbsd_enable_proc_events'.
5486 (nbsd_nat_target::update_thread_list): Rewrite.
5487 (nbsd_nat_target::wait): Handle "PTRACE_LWP_EXIT" and
5488 "PTRACE_LWP_CREATE".
5489 * nbsd-nat.h (nbsd_nat_target::post_startup_inferior): Add.
5490
5491 2020-04-30 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5492
5493 * stack.c (_initialize_stack): Remove duplicated creation
5494 of "frame" command and "f" alias.
5495
5496 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
5497
5498 PR gdb/18706
5499 * gdbtypes.c (check_typedef): Calculate size of array of
5500 stubbed type.
5501
5502 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
5503
5504 PR gdb/15559
5505 * i386-tdep.c (i386_push_dummy_call): Call
5506 i386_thiscall_push_dummy_call.
5507 (i386_thiscall_push_dummy_call): New function.
5508 * i386-tdep.h (i386_thiscall_push_dummy_call): Declare.
5509 * i386-windows-tdep.c (i386_windows_push_dummy_call): New function.
5510 (i386_windows_init_abi): Call set_gdbarch_push_dummy_call.
5511
5512 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
5513
5514 * gdbarch.sh (do_read): Add shellcheck disable directive for
5515 warning SC2162.
5516
5517 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
5518
5519 * gdbarch.sh: Use ${foo:-} where shellcheck would report a
5520 "referenced but not assigned" warning.
5521
5522 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
5523
5524 * gdbarch.sh: Remove code that sets fallbackdefault.
5525
5526 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
5527
5528 * gdbarch.sh: Use shell operators && and || instead of
5529 -a and -o.
5530
5531 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
5532
5533 * gdbarch.sh: Use $(...) instead of `...`.
5534
5535 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
5536
5537 * gdbarch.sh: Use double quotes around variables.
5538
5539 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
5540
5541 * gdbarch.sh: Use %s with printf, instead of variables in the
5542 format string.
5543
5544 2020-04-29 Tom Tromey <tromey@adacore.com>
5545
5546 PR ada/25875:
5547 * dwarf2/read.c (update_enumeration_type_from_children): Compute
5548 type fields here.
5549 (read_enumeration_type): Call
5550 update_enumeration_type_from_children later. Update comments.
5551 (process_enumeration_scope): Don't create type fields.
5552
5553 2020-04-29 Kamil Rytarowski <n54@gmx.com>
5554
5555 * nbsd-tdep.c: Include "xml-syscall.h".
5556 (nbsd_init_abi): Call `set_xml_syscall_file_name'.
5557
5558 2020-04-29 Kamil Rytarowski <n54@gmx.com>
5559
5560 * nbsd-nat.c: Include "sys/wait.h".
5561 (nbsd_resume, nbsd_nat_target::resume, nbsd_wait)
5562 (nbsd_nat_target::wait, nbsd_nat_target::insert_exec_catchpoint)
5563 (nbsd_nat_target::remove_exec_catchpoint)
5564 (nbsd_nat_target::set_syscall_catchpoint): Add.
5565 * nbsd-nat.h (nbsd_nat_target::resume, nbsd_nat_target::wait)
5566 (nbsd_nat_target::insert_exec_catchpoint)
5567 (nbsd_nat_target::remove_exec_catchpoint)
5568 (nbsd_nat_target::set_syscall_catchpoint): Add.
5569 * nbsd-tdep.c (nbsd_get_syscall_number): Add.
5570 (nbsd_init_abi): Call `set_gdbarch_get_syscall_number' and pass
5571 `nbsd_get_syscall_number'.
5572
5573 2020-04-29 Tom Tromey <tom@tromey.com>
5574
5575 * stack.c (print_block_frame_labels): Remove.
5576
5577 2020-04-29 Hannes Domani <ssbssa@yahoo.de>
5578
5579 PR gdb/17320
5580 * ada-valprint.c (val_print_packed_array_elements): Move array
5581 end bracket to new line.
5582 (ada_val_print_string): Remove extra spaces before first array
5583 element.
5584 * c-valprint.c (c_value_print_array): Likewise.
5585 * m2-valprint.c (m2_print_array_contents): Likewise.
5586 (m2_value_print_inner): Likewise.
5587 * p-valprint.c (pascal_value_print_inner): Likewise.
5588 * valprint.c (generic_val_print_array): Likewise.
5589 (value_print_array_elements): Move first array element and array
5590 end bracket to new line.
5591
5592 2020-04-29 Tom de Vries <tdevries@suse.de>
5593
5594 PR symtab/25889
5595 * linespec.c (find_method): Fix ix calculation.
5596
5597 2020-04-28 Kamil Rytarowski <n54@gmx.com>
5598
5599 * syscalls/update-netbsd.sh: New file.
5600 * syscalls/netbsd.xml: Regenerate.
5601 * data-directory/Makefile.in: Register `netbsd.xml' in
5602 `SYSCALLS_FILES'.
5603
5604 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
5605
5606 * syscalls/update-freebsd.sh: Add double quotes.
5607
5608 2020-04-28 Tom Tromey <tom@tromey.com>
5609
5610 * NEWS: Update.
5611 * python/py-cmd.c (gdbpy_initialize_commands): Add COMMAND_TUI.
5612 (cmdpy_init): Allow class_tui.
5613
5614 2020-04-28 Mark Williams <mark@myosotissp.com>
5615
5616 PR gdb/24480
5617 * dwarf2read.c: Add missing assingments to list_in_scope when
5618 start_symtab was already called.
5619
5620 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
5621
5622 PR gdb/25881
5623 * dwarf2/read.c (offset_map_type): Use
5624 gdb:hash_enum<sect_offset> as hash function.
5625
5626 2020-04-28 Tom de Vries <tdevries@suse.de>
5627
5628 * dwarf2/read.c (process_structure_scope): Add symbol for struct decl
5629 with DW_AT_signature.
5630
5631 2020-04-27 Simon Marchi <simon.marchi@efficios.com>
5632
5633 * configure.ac: Remove check for fs_base/gs_base in
5634 user_regs_struct.
5635 * configure: Re-generate.
5636 * config.in: Re-generate.
5637 * amd64-nat.c (amd64_native_gregset_reg_offset): Adjust.
5638 * amd64-linux-nat.c (amd64_linux_nat_target::fetch_registers,
5639 amd64_linux_nat_target::store_registers, ps_get_thread_area, ): Adjust.
5640
5641 2020-04-27 Luis Machado <luis.machado@linaro.org>
5642
5643 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Handle
5644 problematic inline frame unwinding situation.
5645 * frame.c (frame_id_computed_p): New function.
5646 * frame.h (frame_id_computed_p): New prototype.
5647
5648 2020-04-26 Tom Tromey <tom@tromey.com>
5649
5650 * command.h (enum command_class) <class_pseudo>: Remove.
5651
5652 2020-04-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5653
5654 * cli/cli-decode.c (lookup_cmd_composition): Fix comments
5655 and whitespace.
5656
5657 2020-04-25 Kamil Rytarowski <n54@gmx.com>
5658
5659 * inf-ptrace.c (inf_ptrace_target::wait): Remove
5660 `PT_GET_PROCESS_STATE' block.
5661
5662 2020-04-24 Tom Tromey <tom@tromey.com>
5663
5664 * symtab.h (symbol_get_demangled_name): Don't declare.
5665 * symtab.c (symbol_get_demangled_name): Remove.
5666 (general_symbol_info::natural_name)
5667 (general_symbol_info::demangled_name): Update.
5668
5669 2020-04-24 Tom Tromey <tom@tromey.com>
5670
5671 PR rust/25025:
5672 * dwarf2/read.c (dwarf2_physname): Do not demangle for Rust.
5673
5674 2020-04-24 Tom Tromey <tom@tromey.com>
5675
5676 PR symtab/12707:
5677 * dwarf2/read.c (add_partial_symbol): Use the linkage name if it
5678 exists.
5679 (new_symbol): Likewise.
5680 * compile/compile-object-load.c (get_out_value_type): Use
5681 symbol_matches_search_name.
5682
5683 2020-04-24 Tom Tromey <tom@tromey.com>
5684
5685 * dwarf2/read.c (add_partial_symbol): Do not call
5686 compute_and_set_names.
5687
5688 2020-04-24 Tom Tromey <tom@tromey.com>
5689
5690 * dwarf2/read.c (add_partial_symbol): Use new add_psymbol_to_list
5691 overload.
5692
5693 2020-04-24 Tom Tromey <tom@tromey.com>
5694
5695 * psymtab.c (add_psymbol_to_bcache): Simplify calling convention.
5696 (add_psymbol_to_list): New overload. Make old overload call new
5697 one.
5698 * psympriv.h (add_psymbol_to_list): New overload.
5699
5700 2020-04-24 Tom Tromey <tom@tromey.com>
5701
5702 * dwarf2/read.c (partial_die_info::read) <case
5703 DW_AT_linkage_name>: Use value_as_string.
5704 (dwarf2_string_attr): Use value_as_string.
5705 * dwarf2/attribute.h (struct attribute) <value_as_string>: Declare
5706 method.
5707 * dwarf2/attribute.c (attribute::value_as_string): New method.
5708
5709 2020-04-24 Tom Tromey <tom@tromey.com>
5710
5711 * symtab.c (general_symbol_info::natural_name)
5712 (general_symbol_info::demangled_name): Check for language_rust.
5713
5714 2020-04-24 Tom Tromey <tom@tromey.com>
5715
5716 * dwarf2/read.c (dw2_linkage_name): Move Rust "{" hack here...
5717 (dwarf2_physname): ... from here.
5718 (partial_die_info::read): Add Rust "{" hack.
5719
5720 2020-04-24 Tom Tromey <tom@tromey.com>
5721
5722 * symtab.h (struct general_symbol_info) <set_demangled_name>: New
5723 method.
5724 (symbol_set_demangled_name): Don't declare.
5725 * symtab.c (general_symbol_info::set_demangled_name): Rename from
5726 symbol_set_demangled_name.
5727 (general_symbol_info::set_language)
5728 (general_symbol_info::compute_and_set_names): Update.
5729 * minsyms.c (minimal_symbol_reader::install): Update.
5730 * dwarf2/read.c (new_symbol): Update.
5731
5732 2020-04-24 Tom Tromey <tromey@adacore.com>
5733
5734 PR python/23662:
5735 * python/py-type.c (convert_field): Handle
5736 FIELD_LOC_KIND_DWARF_BLOCK.
5737 (typy_get_sizeof): Handle TYPE_HAS_DYNAMIC_LENGTH.
5738 (typy_get_dynamic): Nw function.
5739 (type_object_getset): Add "dynamic".
5740 * NEWS: Add entry.
5741
5742 2020-04-24 Tom Tromey <tromey@adacore.com>
5743
5744 * ada-typeprint.c (print_choices, print_variant_part)
5745 (print_record_field_types_dynamic): New functions.
5746 (print_record_field_types): Use print_record_field_types_dynamic.
5747
5748 2020-04-24 Tom Tromey <tromey@adacore.com>
5749
5750 * dwarf2/read.c (handle_data_member_location): New overload.
5751 (dwarf2_add_field): Use it.
5752 (decode_locdesc): Add "computed" parameter. Update comment.
5753 * gdbtypes.c (is_dynamic_type_internal): Also look for
5754 FIELD_LOC_KIND_DWARF_BLOCK.
5755 (resolve_dynamic_struct): Handle FIELD_LOC_KIND_DWARF_BLOCK.
5756 * gdbtypes.c (is_dynamic_type_internal): Add special case for C++
5757 virtual base classes.
5758 * gnu-v3-abi.c (gnuv3_baseclass_offset): Handle
5759 FIELD_LOC_KIND_DWARF_BLOCK.
5760
5761 2020-04-24 Tom Tromey <tromey@adacore.com>
5762
5763 * dwarf2/read.c (read_structure_type): Handle dynamic length.
5764 * gdbtypes.c (is_dynamic_type_internal): Check
5765 TYPE_HAS_DYNAMIC_LENGTH.
5766 (resolve_dynamic_type_internal): Use TYPE_DYNAMIC_LENGTH.
5767 * gdbtypes.h (TYPE_HAS_DYNAMIC_LENGTH, TYPE_DYNAMIC_LENGTH):
5768 New macros.
5769 (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_SIZE>: New
5770 constant.
5771
5772 2020-04-24 Tom Tromey <tromey@adacore.com>
5773
5774 * dwarf2/read.c (struct variant_field): Rewrite.
5775 (struct variant_part_builder): New.
5776 (struct nextfield): Remove "variant" field. Add "offset".
5777 (struct field_info): Add "current_variant_part" and
5778 "variant_parts".
5779 (alloc_discriminant_info): Remove.
5780 (alloc_rust_variant): New function.
5781 (quirk_rust_enum): Update.
5782 (dwarf2_add_field): Set "offset" member. Don't handle
5783 DW_TAG_variant_part.
5784 (offset_map_type): New typedef.
5785 (convert_variant_range, create_one_variant)
5786 (create_one_variant_part, create_variant_parts)
5787 (add_variant_property): New functions.
5788 (dwarf2_attach_fields_to_type): Call add_variant_property.
5789 (read_structure_type): Don't handle DW_TAG_variant_part.
5790 (handle_variant_part, handle_variant): New functions.
5791 (handle_struct_member_die): Use them.
5792 (process_structure_scope): Don't handle variant parts.
5793 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): Remove.
5794 (struct discriminant_info): Remove.
5795 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: Remove.
5796 (struct main_type) <flag_discriminated_union>: Remove.
5797 * rust-lang.c (rust_enum_p, rust_empty_enum_p): Rewrite.
5798 (rust_enum_variant): Return int. Remove "contents". Rewrite.
5799 (rust_print_enum, rust_print_struct_def, rust_evaluate_subexp):
5800 Update.
5801 * valops.c (value_union_variant): Remove.
5802 * value.h (value_union_variant): Don't declare.
5803
5804 2020-04-24 Tom Tromey <tromey@adacore.com>
5805
5806 * ada-lang.c (ada_discrete_type_high_bound, ada_discrete_type_low)
5807 (ada_value_primitive_packed_val): Update.
5808 * ada-valprint.c (ada_value_print_1): Update.
5809 * dwarf2/loc.c (evaluate_for_locexpr_baton): New struct.
5810 (dwarf2_locexpr_baton_eval): Take a property_addr_info rather than
5811 just an address. Use evaluate_for_locexpr_baton.
5812 (dwarf2_evaluate_property): Update.
5813 * dwarf2/loc.h (struct property_addr_info) <valaddr>: Now an
5814 array_view.
5815 * findvar.c (default_read_var_value): Update.
5816 * gdbtypes.c (compute_variant_fields_inner)
5817 (resolve_dynamic_type_internal): Update.
5818 (resolve_dynamic_type): Change type of valaddr parameter.
5819 * gdbtypes.h (resolve_dynamic_type): Update.
5820 * valarith.c (value_subscripted_rvalue): Update.
5821 * value.c (value_from_contents_and_address): Update.
5822
5823 2020-04-24 Tom Tromey <tromey@adacore.com>
5824
5825 * dwarf2/loc.c (dwarf2_locexpr_baton_eval): Add
5826 "push_initial_value" parameter.
5827 (dwarf2_evaluate_property): Likewise.
5828 * dwarf2/loc.h (dwarf2_evaluate_property): Update.
5829
5830 2020-04-24 Tom Tromey <tromey@adacore.com>
5831
5832 * gdbtypes.c (is_dynamic_type_internal): Check for variant parts.
5833 (variant::matches, compute_variant_fields_recurse)
5834 (compute_variant_fields_inner, compute_variant_fields): New
5835 functions.
5836 (resolve_dynamic_struct): Check for DYN_PROP_VARIANT_PARTS.
5837 Use resolved_type after type is made.
5838 (operator==): Add new cases.
5839 * gdbtypes.h (TYPE_HAS_VARIANT_PARTS): New macro.
5840 (struct discriminant_range, struct variant, struct variant_part):
5841 New.
5842 (union dynamic_prop_data) <variant_parts, original_type>: New
5843 members.
5844 (enum dynamic_prop_node_kind) <DYN_PROP_VARIANT_PARTS>: New constant.
5845 (enum dynamic_prop_kind) <PROP_TYPE, PROP_VARIANT_PARTS>: New
5846 constants.
5847 * value.c (unpack_bits_as_long): Now public.
5848 * value.h (unpack_bits_as_long): Declare.
5849
5850 2020-04-24 Tom Tromey <tromey@adacore.com>
5851
5852 * rs6000-tdep.c (struct ppc_variant): Rename from "variant".
5853 (variants, find_variant_by_arch, rs6000_gdbarch_init): Update.
5854
5855 2020-04-24 Hannes Domani <ssbssa@yahoo.de>
5856
5857 * windows-tdep.c (exception_values): Add WOW64 exception numbers.
5858
5859 2020-04-24 Kamil Rytarowski <n54@gmx.com>
5860
5861 * inf-ptrace.h (follow_fork, insert_fork_catchpoint)
5862 (remove_fork_catchpoint, post_startup_inferior)
5863 (post_attach): Move...
5864 * obsd-nat.h (follow_fork, insert_fork_catchpoint)
5865 (remove_fork_catchpoint, post_startup_inferior)
5866 (post_attach): ...here.
5867 * inf-ptrace.c (follow_fork, insert_fork_catchpoint)
5868 (remove_fork_catchpoint, post_startup_inferior)
5869 (post_attach): Move...
5870 * obsd-nat.c (follow_fork, insert_fork_catchpoint)
5871 (remove_fork_catchpoint, post_startup_inferior)
5872 (post_attach): ...here.
5873
5874 2020-04-24 Tom Tromey <tromey@adacore.com>
5875
5876 * nat/windows-nat.h (struct windows_thread_info)
5877 <pc_adjusted>: New member.
5878 * windows-nat.c (windows_fetch_one_register): Check
5879 pc_adjusted.
5880 (windows_nat_target::get_windows_debug_event)
5881 (windows_nat_target::wait): Set pc_adjusted.
5882
5883 2020-04-24 Tom de Vries <tdevries@suse.de>
5884
5885 * contrib/cc-with-tweaks.sh: Remove <exec>.gdb-index file handling.
5886 Run gdb-add-index inside temp dir.
5887
5888 2020-04-23 Tom Tromey <tromey@adacore.com>
5889
5890 * windows-tdep.c (is_linked_with_cygwin_dll): Always update "iter"
5891 in loop.
5892
5893 2020-04-23 Luis Machado <luis.machado@linaro.org>
5894
5895 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Use
5896 get_frame_register instead of gdbarch_unwind_pc.
5897
5898 2020-04-23 Tom de Vries <tdevries@suse.de>
5899
5900 * symtab.c (lookup_global_symbol): Prefer def over decl.
5901
5902 2020-04-23 Tom de Vries <tdevries@suse.de>
5903
5904 PR symtab/25807
5905 * block.c (best_symbol, better_symbol): Promote to external.
5906 * block.h (best_symbol, better_symbol): Declare.
5907 * symtab.c (lookup_symbol_in_objfile_symtabs): Prefer def over
5908 decl.
5909
5910 2020-04-23 Tom Tromey <tromey@adacore.com>
5911
5912 PR ada/25837:
5913 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Store a
5914 "const char *", not a "const std::string &".
5915 <name_and_matcher::operator==>: Update.
5916 * unittests/lookup_name_info-selftests.c: Change type of
5917 "result".
5918
5919 2020-04-23 Tom Tromey <tom@tromey.com>
5920
5921 * inferior.h (iterate_over_inferiors): Don't declare.
5922 * inferior.c (iterate_over_inferiors): Remove.
5923 * darwin-nat.c (find_inferior_task_it, find_inferior_pid_it):
5924 Remove.
5925 (darwin_find_inferior_by_task, darwin_find_inferior_by_pid): Don't
5926 use iterate_over_inferiors.
5927 (darwin_resume_inferior_it)
5928 (struct resume_inferior_threads_param)
5929 (darwin_resume_inferior_threads_it): Remove.
5930 (darwin_nat_target::resume): Don't use iterate_over_inferiors.
5931
5932 2020-04-23 Tom de Vries <tdevries@suse.de>
5933
5934 * blockframe.c (find_pc_partial_function): Use
5935 find_pc_sect_compunit_symtab rather than
5936 objfile->sf->qf->find_pc_sect_compunit_symtab.
5937
5938 2020-04-22 Tom de Vries <tdevries@suse.de>
5939
5940 PR symtab/25764
5941 * dwarf2/read.c (scan_partial_symbols): Allow external variable decls
5942 in psymtabs.
5943
5944 2020-04-22 Tom de Vries <tdevries@suse.de>
5945
5946 PR symtab/25801
5947 * psymtab.c (psym_map_symtabs_matching_filename): Don't skip shared
5948 symtabs.
5949
5950 2020-04-22 Tom de Vries <tdevries@suse.de>
5951
5952 PR symtab/25700
5953 * dwarf2/read.c (dwarf2_build_psymtabs_hard): Don't create psymtab for
5954 CU if already created.
5955
5956 2020-04-21 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5957
5958 * infrun.c (displaced_step_fixup): Switch to the event_thread
5959 before calling displaced_step_restore, not after.
5960
5961 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
5962
5963 * record-btrace.c (record_btrace_enable_warn): Ignore thread if
5964 its inferior is not recorded by us.
5965 (record_btrace_target_open): Replace call to
5966 all_non_exited_threads () with call to current_inferior
5967 ()->non_exited_threads ().
5968 (record_btrace_target::stop_recording): Likewise.
5969 (record_btrace_target::close): Likewise.
5970 (record_btrace_target::wait): Likewise.
5971 (record_btrace_target::record_stop_replaying): Likewise.
5972
5973 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
5974
5975 * btrace.c (btrace_enable): Throw an error on double enables and
5976 when enabling recording fails.
5977 (btrace_disable): Throw an error if the thread is not recorded.
5978
5979 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
5980
5981 * record-btrace.c (record_btrace_target::fetch_registers): Forward
5982 request if we do not have a thread_info.
5983
5984 2020-04-21 Tom de Vries <tdevries@suse.de>
5985
5986 PR gdb/25471
5987 * thread.c
5988 (scoped_restore_current_thread::scoped_restore_current_thread): Catch
5989 exception in get_frame_id.
5990
5991 2020-04-20 Tom Tromey <tromey@adacore.com>
5992
5993 * python/python.c (struct gdbpy_event): Mark move constructor as
5994 noexcept.
5995 * python/py-tui.c (class gdbpy_tui_window_maker): Mark move
5996 constructor as noexcept.
5997 * completer.h (struct completion_result): Mark move constructor as
5998 noexcept.
5999 * completer.c (completion_result::completion_result): Use
6000 initialization style. Don't call reset_match_list.
6001
6002 2020-04-20 Mihails Strasuns <mihails.strasuns@intel.com>
6003
6004 * MAINTAINERS (Write After Approval): Add myself.
6005
6006 2020-04-18 Tom Tromey <tom@tromey.com>
6007
6008 * windows-tdep.c (init_w32_command_list)
6009 (w32_prefix_command_valid): Restore.
6010 (_initialize_windows_tdep): Call init_w32_command_list.
6011
6012 2020-04-18 Tom Tromey <tom@tromey.com>
6013
6014 * xcoffread.c (enter_line_range, scan_xcoff_symtab): Update.
6015 * value.c (value_fn_field): Update.
6016 * valops.c (find_function_in_inferior)
6017 (value_allocate_space_in_inferior): Update.
6018 * tui/tui-winsource.c (tui_update_source_windows_with_line):
6019 Update.
6020 * tui/tui-source.c (tui_source_window::set_contents): Update.
6021 * symtab.c (lookup_global_or_static_symbol)
6022 (find_function_start_sal_1, skip_prologue_sal)
6023 (print_msymbol_info, find_gnu_ifunc, symbol_arch): Update.
6024 * symmisc.c (dump_msymbols, dump_symtab_1)
6025 (maintenance_print_one_line_table): Update.
6026 * symfile.c (init_entry_point_info, section_is_mapped)
6027 (list_overlays_command, simple_read_overlay_table)
6028 (simple_overlay_update_1): Update.
6029 * stap-probe.c (handle_stap_probe): Update.
6030 * stabsread.c (dbx_init_float_type, define_symbol)
6031 (read_one_struct_field, read_enum_type, read_range_type): Update.
6032 * source.c (info_line_command): Update.
6033 * python/python.c (gdbpy_source_objfile_script)
6034 (gdbpy_execute_objfile_script): Update.
6035 * python/py-type.c (save_objfile_types): Update.
6036 * python/py-objfile.c (py_free_objfile): Update.
6037 * python/py-inferior.c (python_new_objfile): Update.
6038 * psymtab.c (psym_find_pc_sect_compunit_symtab, dump_psymtab)
6039 (dump_psymtab_addrmap_1, maintenance_info_psymtabs)
6040 (maintenance_check_psymtabs): Update.
6041 * printcmd.c (info_address_command): Update.
6042 * objfiles.h (struct objfile) <arch>: New method, from
6043 get_objfile_arch.
6044 (get_objfile_arch): Don't declare.
6045 * objfiles.c (get_objfile_arch): Remove.
6046 (filter_overlapping_sections): Update.
6047 * minsyms.c (msymbol_is_function): Update.
6048 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines)
6049 (output_nondebug_symbol): Update.
6050 * mdebugread.c (parse_symbol, basic_type, parse_partial_symbols)
6051 (mdebug_expand_psymtab): Update.
6052 * machoread.c (macho_add_oso_symfile): Update.
6053 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap):
6054 Update.
6055 * linux-fork.c (checkpoint_command): Update.
6056 * linespec.c (convert_linespec_to_sals): Update.
6057 * jit.c (finalize_symtab): Update.
6058 * infrun.c (insert_exception_resume_from_probe): Update.
6059 * ia64-tdep.c (ia64_find_unwind_table): Update.
6060 * hppa-tdep.c (internalize_unwinds): Update.
6061 * gdbtypes.c (get_type_arch, init_float_type, objfile_type):
6062 Update.
6063 * gcore.c (call_target_sbrk): Update.
6064 * elfread.c (record_minimal_symbol, elf_symtab_read)
6065 (elf_rel_plt_read, elf_gnu_ifunc_record_cache)
6066 (elf_gnu_ifunc_resolve_by_got): Update.
6067 * dwarf2/read.c (create_addrmap_from_index)
6068 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
6069 (read_debug_names_from_section)
6070 (process_psymtab_comp_unit_reader, add_partial_symbol)
6071 (add_partial_subprogram, process_full_comp_unit)
6072 (read_file_scope, read_func_scope, read_lexical_block_scope)
6073 (read_call_site_scope, dwarf2_ranges_read)
6074 (dwarf2_record_block_ranges, dwarf2_add_field)
6075 (mark_common_block_symbol_computed, read_tag_pointer_type)
6076 (read_tag_string_type, dwarf2_init_float_type)
6077 (dwarf2_init_complex_target_type, read_base_type)
6078 (partial_die_info::read, partial_die_info::read)
6079 (read_attribute_value, dwarf_decode_lines_1, new_symbol)
6080 (dwarf2_fetch_die_loc_sect_off): Update.
6081 * dwarf2/loc.c (dwarf2_find_location_expression)
6082 (class dwarf_evaluate_loc_desc, rw_pieced_value)
6083 (dwarf2_evaluate_loc_desc_full, dwarf2_locexpr_baton_eval)
6084 (dwarf2_loc_desc_get_symbol_read_needs)
6085 (locexpr_describe_location_piece, locexpr_describe_location_1)
6086 (loclist_describe_location): Update.
6087 * dwarf2/index-write.c (write_debug_names): Update.
6088 * dwarf2/frame.c (dwarf2_build_frame_info): Update.
6089 * dtrace-probe.c (dtrace_process_dof): Update.
6090 * dbxread.c (read_dbx_symtab, dbx_end_psymtab)
6091 (process_one_symbol): Update.
6092 * ctfread.c (ctf_init_float_type, read_base_type): Update.
6093 * coffread.c (coff_symtab_read, enter_linenos, decode_base_type)
6094 (coff_read_enum_type): Update.
6095 * cli/cli-cmds.c (edit_command, list_command): Update.
6096 * buildsym.c (buildsym_compunit::finish_block_internal): Update.
6097 * breakpoint.c (create_overlay_event_breakpoint)
6098 (create_longjmp_master_breakpoint)
6099 (create_std_terminate_master_breakpoint)
6100 (create_exception_master_breakpoint, get_sal_arch): Update.
6101 * block.c (block_gdbarch): Update.
6102 * annotate.c (annotate_source_line): Update.
6103
6104 2020-04-17 Tom Tromey <tromey@adacore.com>
6105
6106 * auto-load.c (show_auto_load_cmd): Remove.
6107 (auto_load_show_cmdlist_get): Use add_show_prefix_cmd.
6108 * arc-tdep.c (_initialize_arc_tdep): Use add_show_prefix_cmd.
6109 (maintenance_print_arc_command): Remove.
6110 * tui/tui-win.c (tui_command): Remove.
6111 (tui_get_cmd_list): Use add_basic_prefix_cmd.
6112 * tui/tui-layout.c (tui_layout_command): Remove.
6113 (_initialize_tui_layout): Use add_basic_prefix_cmd.
6114 * python/python.c (user_set_python, user_show_python): Remove.
6115 (_initialize_python): Use add_basic_prefix_cmd,
6116 add_show_prefix_cmd.
6117 * guile/guile.c (set_guile_command, show_guile_command): Remove.
6118 (install_gdb_commands): Use add_basic_prefix_cmd,
6119 add_show_prefix_cmd.
6120 (info_guile_command): Remove.
6121 * dwarf2/read.c (set_dwarf_cmd, show_dwarf_cmd): Remove.
6122 (_initialize_dwarf2_read): Use add_basic_prefix_cmd,
6123 add_show_prefix_cmd.
6124 * cli/cli-style.h (class cli_style_option) <add_setshow_commands>:
6125 Remove do_set and do_show parameters.
6126 * cli/cli-style.c (set_style, show_style): Remove.
6127 (_initialize_cli_style): Use add_basic_prefix_cmd,
6128 add_show_prefix_cmd.
6129 (cli_style_option::add_setshow_commands): Remove do_set and
6130 do_show parameters.
6131 (cli_style_option::add_setshow_commands): Use
6132 add_basic_prefix_cmd, add_show_prefix_cmd.
6133 (STYLE_ADD_SETSHOW_COMMANDS): Remove macro.
6134 (set_style_name): Remove.
6135 * cli/cli-dump.c (dump_command, append_command): Remove.
6136 (srec_dump_command, ihex_dump_command, verilog_dump_command)
6137 (tekhex_dump_command, binary_dump_command)
6138 (binary_append_command): Remove.
6139 (_initialize_cli_dump): Use add_basic_prefix_cmd.
6140 * windows-tdep.c (w32_prefix_command_valid): Remove global.
6141 (init_w32_command_list): Remove; move into ...
6142 (_initialize_windows_tdep): ... here. Use add_basic_prefix_cmd.
6143 * valprint.c (set_print, show_print, set_print_raw)
6144 (show_print_raw): Remove.
6145 (_initialize_valprint): Use add_basic_prefix_cmd,
6146 add_show_prefix_cmd.
6147 * typeprint.c (set_print_type, show_print_type): Remove.
6148 (_initialize_typeprint): Use add_basic_prefix_cmd,
6149 add_show_prefix_cmd.
6150 * record.c (set_record_command, show_record_command): Remove.
6151 (_initialize_record): Use add_basic_prefix_cmd,
6152 add_show_prefix_cmd.
6153 * cli/cli-cmds.c (_initialize_cli_cmds): Use add_basic_prefix_cmd,
6154 add_show_prefix_cmd.
6155 (info_command, show_command, set_debug, show_debug): Remove.
6156 * top.h (set_history, show_history): Don't declare.
6157 * top.c (set_history, show_history): Remove.
6158 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
6159 (unset_tdesc_cmd): Remove.
6160 (_initialize_target_descriptions): Use add_basic_prefix_cmd,
6161 add_show_prefix_cmd.
6162 * symtab.c (info_module_command): Remove.
6163 (_initialize_symtab): Use add_basic_prefix_cmd.
6164 * symfile.c (overlay_command): Remove.
6165 (_initialize_symfile): Use add_basic_prefix_cmd.
6166 * sparc64-tdep.c (info_adi_command): Remove.
6167 (_initialize_sparc64_adi_tdep): Use add_basic_prefix_cmd.
6168 * sh-tdep.c (show_sh_command, set_sh_command): Remove.
6169 (_initialize_sh_tdep): Use add_basic_prefix_cmd,
6170 add_show_prefix_cmd.
6171 * serial.c (serial_set_cmd, serial_show_cmd): Remove.
6172 (_initialize_serial): Use add_basic_prefix_cmd,
6173 add_show_prefix_cmd.
6174 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Remove.
6175 (_initialize_ser_tcp): Use add_basic_prefix_cmd,
6176 add_show_prefix_cmd.
6177 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command)
6178 (_initialize_rs6000_tdep): Use add_basic_prefix_cmd,
6179 add_show_prefix_cmd.
6180 * riscv-tdep.c (show_riscv_command, set_riscv_command)
6181 (show_debug_riscv_command, set_debug_riscv_command): Remove.
6182 (_initialize_riscv_tdep): Use add_basic_prefix_cmd,
6183 add_show_prefix_cmd.
6184 * remote.c (remote_command, set_remote_cmd): Remove.
6185 (_initialize_remote): Use add_basic_prefix_cmd.
6186 * record-full.c (set_record_full_command)
6187 (show_record_full_command): Remove.
6188 (_initialize_record_full): Use add_basic_prefix_cmd,
6189 add_show_prefix_cmd.
6190 * record-btrace.c (cmd_set_record_btrace)
6191 (cmd_show_record_btrace, cmd_set_record_btrace_bts)
6192 (cmd_show_record_btrace_bts, cmd_set_record_btrace_pt)
6193 (cmd_show_record_btrace_pt): Remove.
6194 (_initialize_record_btrace): Use add_basic_prefix_cmd,
6195 add_show_prefix_cmd.
6196 * ravenscar-thread.c (set_ravenscar_command)
6197 (show_ravenscar_command): Remove.
6198 (_initialize_ravenscar): Use add_basic_prefix_cmd,
6199 add_show_prefix_cmd.
6200 * mips-tdep.c (show_mips_command, set_mips_command)
6201 (_initialize_mips_tdep): Use add_basic_prefix_cmd,
6202 add_show_prefix_cmd.
6203 * maint.c (maintenance_command, maintenance_info_command)
6204 (maintenance_check_command, maintenance_print_command)
6205 (maintenance_set_cmd, maintenance_show_cmd): Remove.
6206 (_initialize_maint_cmds): Use add_basic_prefix_cmd,
6207 add_show_prefix_cmd.
6208 (show_per_command_cmd): Remove.
6209 * maint-test-settings.c (maintenance_set_test_settings_cmd):
6210 Remove.
6211 (maintenance_show_test_settings_cmd): Remove.
6212 (_initialize_maint_test_settings): Use add_basic_prefix_cmd,
6213 add_show_prefix_cmd.
6214 * maint-test-options.c (maintenance_test_options_command):
6215 Remove.
6216 (_initialize_maint_test_options): Use add_basic_prefix_cmd.
6217 * macrocmd.c (macro_command): Remove
6218 (_initialize_macrocmd): Use add_basic_prefix_cmd.
6219 * language.c (set_check, show_check): Remove.
6220 (_initialize_language): Use add_basic_prefix_cmd,
6221 add_show_prefix_cmd.
6222 * infcmd.c (unset_command): Remove.
6223 (_initialize_infcmd): Use add_basic_prefix_cmd.
6224 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Remove.
6225 (_initialize_i386_tdep): Use add_basic_prefix_cmd,
6226 add_show_prefix_cmd.
6227 * go32-nat.c (go32_info_dos_command): Remove.
6228 (_initialize_go32_nat): Use add_basic_prefix_cmd.
6229 * cli/cli-decode.c (do_prefix_cmd, add_basic_prefix_cmd)
6230 (do_show_prefix_cmd, add_show_prefix_cmd): New functions.
6231 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Remove.
6232 (_initialize_frame): Use add_basic_prefix_cmd,
6233 add_show_prefix_cmd.
6234 * dcache.c (set_dcache_command, show_dcache_command): Remove.
6235 (_initialize_dcache): Use add_basic_prefix_cmd,
6236 add_show_prefix_cmd.
6237 * cp-support.c (maint_cplus_command): Remove.
6238 (_initialize_cp_support): Use add_basic_prefix_cmd.
6239 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
6240 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
6241 (maint_btrace_pt_show_cmd, _initialize_btrace): Use
6242 add_basic_prefix_cmd, add_show_prefix_cmd.
6243 * breakpoint.c (save_command): Remove.
6244 (_initialize_breakpoint): Use add_basic_prefix_cmd.
6245 * arm-tdep.c (set_arm_command, show_arm_command): Remove.
6246 (_initialize_arm_tdep): Use add_basic_prefix_cmd,
6247 add_show_prefix_cmd.
6248 * ada-lang.c (maint_set_ada_cmd, maint_show_ada_cmd)
6249 (set_ada_command, show_ada_command): Remove.
6250 (_initialize_ada_language): Use add_basic_prefix_cmd,
6251 add_show_prefix_cmd.
6252 * command.h (add_basic_prefix_cmd, add_show_prefix_cmd): Declare.
6253
6254 2020-04-16 Kamil Rytarowski <n54@gmx.com>
6255
6256 * nbsd-nat.c (inf_ptrace_target::auxv_parse): Remove.
6257 * nbsd-nat.h (inf_ptrace_target::auxv_parse): Likewise.
6258
6259 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
6260
6261 * windows-tdep.c (is_linked_with_cygwin_dll): Add filename to
6262 warning messages.
6263
6264 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
6265
6266 * windows-tdep.c (is_linked_with_cygwin_dll): Consider case where
6267 import table is not at beginning of .idata section.
6268
6269 2020-04-16 Pedro Alves <palves@redhat.com>
6270
6271 * inferior.c (delete_inferior): Use delete operator directly
6272 instead of delete_program_space.
6273 * progspace.c (add_program_space): New, factored out from
6274 program_space::program_space.
6275 (remove_program_space): New, factored out from
6276 delete_program_space.
6277 (program_space::program_space): Remove intro comment. Rewrite.
6278 (program_space::~program_space): Remove intro comment. Call
6279 remove_program_space.
6280 (delete_program_space): Delete.
6281 * progspace.h (program_space::program_space): Make explicit. Move
6282 intro comment here, adjusted.
6283 (program_space::~program_space): Move intro comment here,
6284 adjusted.
6285 (delete_program_space): Remove.
6286
6287 2020-04-16 Tom Tromey <tromey@adacore.com>
6288
6289 * windows-nat.c (windows_nat::handle_access_violation): New
6290 function.
6291 * nat/windows-nat.h (handle_access_violation): Declare.
6292 * nat/windows-nat.c (handle_exception): Move Cygwin code to
6293 windows-nat.c. Call handle_access_violation.
6294
6295 2020-04-16 Tom de Vries <tdevries@suse.de>
6296
6297 PR symtab/25791
6298 * dwarf2/index-write.c (write_gdbindex): Generate CU table entries for
6299 CUs without psymtab.
6300
6301 2020-04-16 Kevin Buettner <kevinb@redhat.com>
6302
6303 * python/python.c (do_start_initialization): Don't call
6304 PyEval_InitThreads for Python 3.9 and beyond.
6305
6306 2020-04-15 Kamil Rytarowski <n54@gmx.com>
6307
6308 * obsd-nat.c (obsd_nat_target::update_thread_list): Pass "this" to
6309 thread functions.
6310 (obsd_nat_target::wait): Likewise.
6311
6312 2020-04-15 Tom Tromey <tromey@adacore.com>
6313
6314 * windows-nat.c (DEBUG_EXEC, DEBUG_EVENTS, DEBUG_MEM)
6315 (DEBUG_EXCEPT): Use debug_printf.
6316
6317 2020-04-15 Andrew Burgess <andrew.burgess@embecosm.com>
6318
6319 * completer.c (class completion_tracker::completion_hash_entry)
6320 <hash_name>: New member function.
6321 (completion_tracker::discard_completions): New callback to hash a
6322 completion_hash_entry, pass this to htab_create_alloc.
6323
6324 2016-01-20 Jon Turney <jon.turney@dronecode.org.uk>
6325
6326 * windows-nat.c (windows_make_so): Warn rather than stopping with
6327 an error if realpath() fails.
6328
6329 2020-04-14 Kamil Rytarowski <n54@gmx.com>
6330
6331 * nbsd-nat.c (nbsd_pid_to_kinfo_proc2): New.
6332 (nbsd_nat_target::info_proc): Add do_status.
6333
6334 2020-04-14 Simon Marchi <simon.marchi@polymtl.ca>
6335 Tom de Vries <tdevries@suse.de>
6336
6337 PR symtab/25718
6338 * psympriv.h (struct partial_symtab::read_symtab)
6339 (struct partial_symtab::expand_psymtab)
6340 (struct partial_symtab::read_dependencies): Update comments.
6341 * dwarf2/read.c (struct dwarf2_include_psymtab::read_symtab): Call
6342 read_symtab for includer.
6343 (struct dwarf2_include_psymtab::expand_psymtab): Assert false.
6344 (struct dwarf2_include_psymtab::readin_p): Call readin_p () for includer.
6345 (struct dwarf2_include_psymtab::m_readin): Remove.
6346 (struct dwarf2_include_psymtab::includer): New member function.
6347 (dwarf2_psymtab::expand_psymtab): Assert !readin.
6348
6349 2020-04-14 Tom de Vries <tdevries@suse.de>
6350
6351 PR symtab/25720
6352 * symmisc.c (maintenance_expand_symtabs): Call expand_symtabs_matching
6353 with NULL symbol_matcher and lookup_name.
6354 * psymtab.c (psym_expand_symtabs_matching): Handle NULL symbol_matcher
6355 and lookup_name.
6356 * dwarf2/read.c (dw2_expand_symtabs_matching)
6357 (dw2_debug_names_expand_symtabs_matching): Same.
6358 * symfile.h (struct quick_symbol_functions::expand_symtabs_matching):
6359 Make lookup_name a pointer. Update comment.
6360 * symtab.c (global_symbol_searcher::expand_symtabs): Handle
6361 lookup_name being a pointer.
6362 * symfile.c (expand_symtabs_matching): Same.
6363 * symfile-debug.c (debug_qf_expand_symtabs_matching): Same.
6364 * linespec.c (iterate_over_all_matching_symtabs): Same.
6365
6366 2020-04-13 Tom Tromey <tom@tromey.com>
6367
6368 * run-on-main-thread.c: Update include.
6369 * unittests/main-thread-selftests.c: Update include.
6370 * tui/tui-win.c: Update include.
6371 * tui/tui-io.c: Update include.
6372 * tui/tui-interp.c: Update include.
6373 * tui/tui-hooks.c: Update include.
6374 * top.h: Update include.
6375 * top.c: Update include.
6376 * ser-base.c: Update include.
6377 * remote.c: Update include.
6378 * remote-notif.c: Update include.
6379 * remote-fileio.c: Update include.
6380 * record-full.c: Update include.
6381 * record-btrace.c: Update include.
6382 * python/python.c: Update include.
6383 * posix-hdep.c: Update include.
6384 * mingw-hdep.c: Update include.
6385 * mi/mi-main.c: Update include.
6386 * mi/mi-interp.c: Update include.
6387 * main.c: Update include.
6388 * linux-nat.c: Update include.
6389 * interps.c: Update include.
6390 * infrun.c: Update include.
6391 * inf-loop.c: Update include.
6392 * event-top.c: Update include.
6393 * event-loop.c: Move to ../gdbsupport/.
6394 * event-loop.h: Move to ../gdbsupport/.
6395 * async-event.h: Update include.
6396 * Makefile.in (COMMON_SFILES, HFILES_NO_SRCDIR): Update.
6397
6398 2020-04-13 Tom Tromey <tom@tromey.com>
6399
6400 * tui/tui-win.c: Include async-event.h.
6401 * remote.c: Include async-event.h.
6402 * remote-notif.c: Include async-event.h.
6403 * record-full.c: Include async-event.h.
6404 * record-btrace.c: Include async-event.h.
6405 * infrun.c: Include async-event.h.
6406 * event-top.c: Include async-event.h.
6407 * event-loop.h: Move some declarations to async-event.h.
6408 * event-loop.c: Don't include ser-event.h or top.h. Move some
6409 code to async-event.c.
6410 * async-event.h: New file.
6411 * async-event.c: New file.
6412 * Makefile.in (COMMON_SFILES): Add async-event.c.
6413 (HFILES_NO_SRCDIR): Add async-event.h.
6414
6415 2020-04-13 Tom Tromey <tom@tromey.com>
6416
6417 * utils.c (flush_streams): New function.
6418 * event-loop.c (gdb_wait_for_event): Call flush_streams.
6419
6420 2020-04-13 Tom Tromey <tom@tromey.com>
6421
6422 * event-loop.c (handle_file_event): Use warning, not
6423 printf_unfiltered.
6424
6425 2020-04-13 Tom Tromey <tom@tromey.com>
6426
6427 * event-loop.c: Include <chrono>.
6428
6429 2020-04-13 Tom Tromey <tom@tromey.com>
6430
6431 * gdb_select.h: Move to ../gdbsupport/.
6432 * event-loop.c: Update include path.
6433 * top.c: Update include path.
6434 * ser-base.c: Update include path.
6435 * ui-file.c: Update include path.
6436 * ser-tcp.c: Update include path.
6437 * guile/scm-ports.c: Update include path.
6438 * posix-hdep.c: Update include path.
6439 * ser-unix.c: Update include path.
6440 * gdb_usleep.c: Update include path.
6441 * mingw-hdep.c: Update include path.
6442 * inflow.c: Update include path.
6443 * infrun.c: Update include path.
6444 * event-top.c: Update include path.
6445
6446 2020-04-13 Tom Tromey <tom@tromey.com>
6447
6448 * configure: Rebuild.
6449 * configure.ac: Remove checks that are now in GDB_AC_COMMON.
6450
6451 2020-04-13 Tom Tromey <tom@tromey.com>
6452
6453 * event-loop.h (start_event_loop): Don't declare.
6454 * event-loop.c (start_event_loop): Move...
6455 * main.c (start_event_loop): ...here. Now static.
6456
6457 2020-04-13 Sergio Durigan Junior <sergiodj@sergiodj.net>
6458
6459 * MAINTAINERS: Update my email address.
6460
6461 2020-04-12 Kamil Rytarowski <n54@gmx.com>
6462
6463 * nbsd-nat.c (nbsd_nat_target::info_proc): Add IP_MINIMAL and
6464 IP_ALL.
6465
6466 2020-04-12 Kamil Rytarowski <n54@gmx.com>
6467
6468 * nbsd-nat.c (nbsd_pid_to_cmdline): Add.
6469 (nbsd_nat_target::info_proc): Add do_cmdline.
6470
6471 2020-04-12 Kamil Rytarowski <n54@gmx.com>
6472
6473 * nbsd-nat.c (nbsd_pid_to_cwd): Add.
6474 (nbsd_nat_target::info_proc): Add do_cwd.
6475
6476 2020-04-12 Kamil Rytarowski <n54@gmx.com>
6477
6478 * nbsd-nat.c (nbsd_nat_target::info_proc): Add do_exe.
6479
6480 2020-04-11 Kamil Rytarowski <n54@gmx.com>
6481
6482 * nbsd-nat.c; Include "nbsd-tdep.h" and "gdbarch.h".
6483 * nbsd-nat.c (nbsd_nat_target::find_memory_regions)
6484 (nbsd_nat_target::info_proc): New functions.
6485 * nbsd-nat.c (kinfo_get_vmmap): New function.
6486 * nbsd-nat.c (nbsd_nat_target::info_proc) Use
6487 nbsd_info_proc_mappings_header and nbsd_info_proc_mappings_entry.
6488 * nbsd-tdep.c (nbsd_info_proc_mappings_header)
6489 (nbsd_info_proc_mappings_entry, nbsd_vm_map_entry_flags): New
6490 functions.
6491 * nbsd-tdep.c (KINFO_VME_PROT_READ, KINFO_VME_PROT_WRITE)
6492 (KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
6493 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
6494 (KINFO_VME_FLAG_PAGEABLE, KINFO_VME_FLAG_GROWS_UP)
6495 (KINFO_VME_FLAG_GROWS_DOWN): New.
6496
6497 2020-04-10 Artur Shepilko <nomadbyte@gmail.com>
6498
6499 * utils.c (copy_bitwise): Use unsigned 0 constant as operand of
6500 bit shift.
6501
6502 2020-04-10 Tom Tromey <tromey@adacore.com>
6503
6504 * symfile.c (symbol_file_add_separate): Preserve OBJF_MAINLINE.
6505
6506 2020-04-10 Tom Tromey <tromey@adacore.com>
6507
6508 * symtab.c (get_symbol_address, get_msymbol_address): Skip
6509 separate debug files.
6510
6511 2020-04-10 Hannes Domani <ssbssa@yahoo.de>
6512
6513 * nat/windows-nat.c (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
6514 Move to...
6515 * nat/windows-nat.h (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
6516 ... here.
6517 * windows-nat.c (windows_nat_target::get_windows_debug_event):
6518 Check for STATUS_WX86_BREAKPOINT.
6519 (windows_nat_target::wait): Same.
6520
6521 2020-04-10 Tom de Vries <tdevries@suse.de>
6522
6523 PR cli/25808
6524 * python/lib/gdb/__init__.py: Initialize lexer with stripnl=False.
6525
6526 2020-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6527
6528 * MAINTAINERS (Global Maintainers): Add Tom de Vries.
6529 (Write After Approval): Remove Tom de Vries.
6530
6531 2020-04-09 Bernd Edlinger <bernd.edlinger@hotmail.de>
6532
6533 revert partially:
6534 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
6535
6536 * buildsym.c (record_line): Fix undefined behavior and preserve
6537 lines at eof.
6538
6539 2020-04-09 Kamil Rytarowski <n54@gmx.com>
6540
6541 * auxv.h (svr4_auxv_parse): New.
6542 * auxv.c (default_auxv_parse): Split into default_auxv_parse
6543 and generic_auxv_parse.
6544 (svr4_auxv_parse): Add.
6545 * obsd-tdep.c: Include "auxv.h".
6546 (obsd_auxv_parse): Remove.
6547 (obsd_init_abi): Remove comment.
6548 (obsd_init_abi): Change set_gdbarch_auxv_parse passed argument
6549 from `obsd_auxv_parse' to `svr4_auxv_parse'.
6550 * nbsd-tdep.c: Include "auxv.h".
6551 (nbsd_init_abi): Call set_gdbarch_auxv_parse.
6552
6553 2020-04-08 Tom Tromey <tromey@adacore.com>
6554
6555 * nat/windows-nat.h (last_wait_event): Don't declare.
6556 (wait_for_debug_event): Update comment.
6557 * nat/windows-nat.c (last_wait_event): Now static.
6558
6559 2020-04-08 Tom Tromey <tromey@adacore.com>
6560
6561 * windows-nat.c (wait_for_debug_event): Move to
6562 nat/windows-nat.c.
6563 * nat/windows-nat.h (wait_for_debug_event): Declare.
6564 * nat/windows-nat.c (wait_for_debug_event): Move from
6565 windows-nat.c. No longer static.
6566
6567 2020-04-08 Tom Tromey <tromey@adacore.com>
6568
6569 * windows-nat.c (get_windows_debug_event): Use
6570 fetch_pending_stop.
6571 * nat/windows-nat.h (fetch_pending_stop): Declare.
6572 * nat/windows-nat.c (fetch_pending_stop): New function.
6573
6574 2020-04-08 Tom Tromey <tromey@adacore.com>
6575
6576 * windows-nat.c (windows_continue): Use matching_pending_stop and
6577 continue_last_debug_event.
6578 * nat/windows-nat.h (matching_pending_stop)
6579 (continue_last_debug_event): Declare.
6580 * nat/windows-nat.c (DEBUG_EVENTS): New define.
6581 (matching_pending_stop, continue_last_debug_event): New
6582 functions.
6583
6584 2020-04-08 Tom Tromey <tromey@adacore.com>
6585
6586 * windows-nat.c (MS_VC_EXCEPTION): Move to nat/windows-nat.c.
6587 (handle_exception_result): Move to nat/windows-nat.h.
6588 (DEBUG_EXCEPTION_SIMPLE): Remove.
6589 (windows_nat::handle_ms_vc_exception): New function.
6590 (handle_exception): Move to nat/windows-nat.c.
6591 (get_windows_debug_event): Update.
6592 (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP): Move to
6593 nat/windows-nat.c.
6594 * nat/windows-nat.h (handle_ms_vc_exception): Declare.
6595 (handle_exception_result): Move from windows-nat.c.
6596 (handle_exception): Declare.
6597 * nat/windows-nat.c (MS_VC_EXCEPTION, handle_exception)
6598 (STATUS_WX86_SINGLE_STEP, STATUS_WX86_BREAKPOINT): Move from
6599 windows-nat.c.
6600
6601 2020-04-08 Tom Tromey <tromey@adacore.com>
6602
6603 * windows-nat.c (exception_count, event_count): Remove.
6604 (handle_exception, get_windows_debug_event)
6605 (do_initial_windows_stuff): Update.
6606
6607 2020-04-08 Tom Tromey <tromey@adacore.com>
6608
6609 * windows-nat.c (windows_nat::handle_load_dll)
6610 (windows_nat::handle_unload_dll): Rename. No longer static.
6611 * nat/windows-nat.h (handle_load_dll, handle_unload_dll):
6612 Declare.
6613
6614 2020-04-08 Tom Tromey <tromey@adacore.com>
6615
6616 * complaints.h (stop_whining): Declare at top-level.
6617 (complaint): Don't declare stop_whining.
6618
6619 2020-04-08 Tom Tromey <tromey@adacore.com>
6620
6621 * windows-nat.c (windows_nat::handle_output_debug_string):
6622 Rename. No longer static.
6623 * nat/windows-nat.h (handle_output_debug_string): Declare.
6624
6625 2020-04-08 Tom Tromey <tromey@adacore.com>
6626
6627 * windows-nat.c (current_process_handle, current_process_id)
6628 (main_thread_id, last_sig, current_event, last_wait_event)
6629 (current_windows_thread, desired_stop_thread_id, pending_stops)
6630 (struct pending_stop, siginfo_er): Move to nat/windows-nat.c.
6631 (display_selectors, fake_create_process)
6632 (get_windows_debug_event): Update.
6633 * nat/windows-nat.h (current_process_handle, current_process_id)
6634 (main_thread_id, last_sig, current_event, last_wait_event)
6635 (current_windows_thread, desired_stop_thread_id, pending_stops)
6636 (struct pending_stop, siginfo_er): Move from windows-nat.c.
6637 * nat/windows-nat.c (current_process_handle, current_process_id)
6638 (main_thread_id, last_sig, current_event, last_wait_event)
6639 (current_windows_thread, desired_stop_thread_id, pending_stops)
6640 (siginfo_er): New globals. Move from windows-nat.c.
6641
6642 2020-04-08 Tom Tromey <tromey@adacore.com>
6643
6644 * windows-nat.c (get_image_name): Move to nat/windows-nat.c.
6645 (handle_load_dll): Update.
6646 * nat/windows-nat.c (get_image_name): Move from windows-nat.c.
6647
6648 2020-04-08 Tom Tromey <tromey@adacore.com>
6649
6650 * windows-nat.c (enum thread_disposition_type): Move to
6651 nat/windows-nat.h.
6652 (windows_nat::thread_rec): Rename from thread_rec. No longer
6653 static.
6654 (windows_add_thread, windows_nat_target::fetch_registers)
6655 (windows_nat_target::store_registers, handle_exception)
6656 (windows_nat_target::resume, get_windows_debug_event)
6657 (windows_nat_target::get_tib_address)
6658 (windows_nat_target::thread_name)
6659 (windows_nat_target::thread_alive): Update.
6660 * nat/windows-nat.h (enum thread_disposition_type): Move from
6661 windows-nat.c.
6662 (thread_rec): Declare.
6663
6664 2020-04-08 Tom Tromey <tromey@adacore.com>
6665
6666 * windows-nat.c: Add "using namespace".
6667 * nat/windows-nat.h: Wrap contents in windows_nat namespace.
6668 * nat/windows-nat.c: Wrap contents in windows_nat namespace.
6669
6670 2020-04-08 Tom Tromey <tromey@adacore.com>
6671
6672 * nat/windows-nat.h (struct windows_thread_info): Declare
6673 destructor.
6674 * nat/windows-nat.c (~windows_thread_info): New.
6675
6676 2020-04-08 Tom Tromey <tromey@adacore.com>
6677
6678 PR gdb/22992
6679 * windows-nat.c (current_event): Update comment.
6680 (last_wait_event, desired_stop_thread_id): New globals.
6681 (struct pending_stop): New.
6682 (pending_stops): New global.
6683 (windows_nat_target) <stopped_by_sw_breakpoint>
6684 <supports_stopped_by_sw_breakpoint>: New methods.
6685 (windows_fetch_one_register): Add assertions. Adjust PC.
6686 (windows_continue): Handle pending stops. Suspend other threads
6687 when stepping. Use last_wait_event
6688 (wait_for_debug_event): New function.
6689 (get_windows_debug_event): Use wait_for_debug_event. Handle
6690 pending stops. Queue spurious stops.
6691 (windows_nat_target::wait): Set stopped_at_software_breakpoint.
6692 (windows_nat_target::kill): Use wait_for_debug_event.
6693 * nat/windows-nat.h (struct windows_thread_info)
6694 <stopped_at_software_breakpoint>: New field.
6695 * nat/windows-nat.c (windows_thread_info::resume): Clear
6696 stopped_at_software_breakpoint.
6697
6698 2020-04-08 Tom Tromey <tromey@adacore.com>
6699
6700 * windows-nat.c (enum thread_disposition_type): New.
6701 (thread_rec): Replace "get_context" parameter with "disposition";
6702 change type.
6703 (windows_add_thread, windows_nat_target::fetch_registers)
6704 (windows_nat_target::store_registers, handle_exception)
6705 (windows_nat_target::resume, get_windows_debug_event)
6706 (windows_nat_target::get_tib_address)
6707 (windows_nat_target::thread_name)
6708 (windows_nat_target::thread_alive): Update.
6709
6710 2020-04-08 Tom Tromey <tromey@adacore.com>
6711
6712 * windows-nat.c (thread_rec): Use windows_thread_info::suspend.
6713 (windows_continue): Use windows_continue::resume.
6714 * nat/windows-nat.h (struct windows_thread_info) <suspend,
6715 resume>: Declare new methods.
6716 * nat/windows-nat.c: New file.
6717 * configure.nat (NATDEPFILES): Add nat/windows-nat.o when needed.
6718
6719 2020-04-08 Tom Tromey <tromey@adacore.com>
6720
6721 * windows-nat.c (windows_add_thread, windows_delete_thread)
6722 (windows_nat_target::fetch_registers)
6723 (windows_nat_target::store_registers, fake_create_process)
6724 (windows_nat_target::resume, windows_nat_target::resume)
6725 (get_windows_debug_event, windows_nat_target::wait)
6726 (windows_nat_target::pid_to_str)
6727 (windows_nat_target::get_tib_address)
6728 (windows_nat_target::get_ada_task_ptid)
6729 (windows_nat_target::thread_name)
6730 (windows_nat_target::thread_alive): Use lwp, not tid.
6731
6732 2020-04-08 Tom Tromey <tromey@adacore.com>
6733
6734 * windows-nat.c (handle_exception)
6735 (windows_nat_target::thread_name): Update.
6736 * nat/windows-nat.h (windows_thread_info): Remove destructor.
6737 <name>: Now unique_xmalloc_ptr.
6738
6739 2020-04-08 Tom Tromey <tromey@adacore.com>
6740
6741 * windows-nat.c (thread_rec)
6742 (windows_nat_target::fetch_registers): Update.
6743 * nat/windows-nat.h (struct windows_thread_info) <suspended>:
6744 Update comment.
6745 <debug_registers_changed, reload_context>: Now bool.
6746
6747 2020-04-08 Tom Tromey <tromey@adacore.com>
6748
6749 * windows-nat.c (windows_add_thread): Use new.
6750 (windows_init_thread_list, windows_delete_thread): Use delete.
6751 (get_windows_debug_event): Update.
6752 * nat/windows-nat.h (struct windows_thread_info): Add constructor,
6753 destructor, and initializers.
6754
6755 2020-04-08 Tom Tromey <tromey@adacore.com>
6756
6757 * windows-nat.c (struct windows_thread_info): Remove.
6758 * nat/windows-nat.h: New file.
6759
6760 2020-04-08 Tom Tromey <tromey@adacore.com>
6761
6762 * windows-nat.c (struct windows_thread_info) <tid>: Rename from "id".
6763 (thread_rec, windows_add_thread, windows_delete_thread)
6764 (windows_continue): Update.
6765
6766 2020-04-08 Tom Tromey <tromey@adacore.com>
6767
6768 * windows-nat.c (struct windows_thread_info): Remove typedef.
6769 (thread_head): Remove.
6770 (thread_list): New global.
6771 (thread_rec, windows_add_thread, windows_init_thread_list)
6772 (windows_delete_thread, windows_continue): Update.
6773
6774 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
6775
6776 * windows-tdep.h (windows_init_abi): Add comment.
6777 (cygwin_init_abi): New declaration.
6778 * windows-tdep.c: Split signal enumeration in two, one for
6779 Windows and one for Cygwin.
6780 (windows_gdb_signal_to_target): Only deal with signal of the
6781 Windows OS ABI.
6782 (cygwin_gdb_signal_to_target): New function.
6783 (windows_init_abi): Rename to windows_init_abi_common, don't set
6784 gdb_signal_to_target gdbarch method. Add new new function with
6785 this name.
6786 (cygwin_init_abi): New function.
6787 * amd64-windows-tdep.c (amd64_windows_init_abi_common): Add
6788 comment. Don't call windows_init_abi.
6789 (amd64_windows_init_abi): Add comment, call windows_init_abi.
6790 (amd64_cygwin_init_abi): Add comment, call cygwin_init_abi.
6791 * i386-windows-tdep.c (i386_windows_init_abi): Rename to
6792 i386_windows_init_abi_common, don't call windows_init_abi. Add
6793 a new function of this name.
6794 (i386_cygwin_init_abi): New function.
6795 (_initialize_i386_windows_tdep): Bind i386_cygwin_init_abi to
6796 OS ABI Cygwin.
6797
6798 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
6799
6800 * dwarf2/read.c (read_gdb_index_from_buffer): Remove objfile
6801 parameter.c.
6802 (dwarf2_read_gdb_index): Update.
6803
6804 2020-04-07 Kamil Rytarowski <n54@gmx.com>
6805
6806 * nbsd-tdep.c: Include "objfiles.h".
6807 (nbsd_skip_solib_resolver): New.
6808 (nbsd_init_abi): Call set_gdbarch_skip_solib_resolver().
6809
6810 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
6811
6812 * dwarf2/loc.c (loclist_describe_location): Call the function decode_debug_loclists_
6813 addresses if DWARF version is 5 or more because DW_LLE_start* or DW_LLE_offset_pair
6814 with DW_LLE_base_addressx are being emitted in DWARFv5.
6815 Add the newly added kind DW_LOC_OFFSET_PAIR also.
6816 The length of location description is an unsigned ULEB integer in DWARFv5 instead of
6817 unsigned integer.
6818
6819 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
6820
6821 * dwarf2/loc.c (enum debug_loc_kind): Add a new kind DEBUG_LOC_OFFSET_PAIR.
6822 (dwarf2_find_location_expression): Call the function decode_debug_loclists_
6823 addresses if DWARF version is 5 or more. DW_LLE_start* or DW_LLE_offset_pair
6824 with DW_LLE_base_addressx are being emitted in DWARFv5 instead of DW_LLE_GNU*.
6825 Add applicable base address if the entry is DW_LLE_offset_pair from DWO.
6826 (decode_debug_loclists_addresses): Return DEBUG_LOC_OFFSET_PAIR instead of
6827 DEBUG_LOC_START_END in case of DW_LLE_offset_pair.
6828
6829
6830 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
6831
6832 * dwarf2/read.c (cu_debug_loc_section): Added the declaration for the function.
6833 (read_loclist_index): New function definition.
6834 (lookup_loclist_base): New function definition.
6835 (read_loclist_header): New function definition.
6836 (dwarf2_cu): Add loclist_base and loclist_header field.
6837 (dwarf2_locate_dwo_sections): Handle .debug_loclists.dwo section.
6838 (read_full_die_1): Read the value of DW_AT_loclists_base.
6839 (read_attribute_reprocess): Handle DW_FORM_loclistx.
6840 (read_attribute_value): Handle DW_FORM_loclistx.
6841 (skip_one_die): Handle DW_FORM_loclistx.
6842 (loclist_header): New structure declaration.
6843 * dwarf2/attribute.c (form_is_section_offset): Handle DW_FORM_loclistx.
6844
6845 2020-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6846
6847 * dwarf2/read.h (struct dwarf2_psymtab): Remove two-parameters
6848 constructor. Remove `addr` parameter from other constructor and
6849 add `per_cu` parameter.
6850 * dwarf2/read.c (create_partial_symtab): Update.
6851
6852 2020-04-07 Tom de Vries <tdevries@suse.de>
6853
6854 PR symtab/25796
6855 * dwarf2/read.c (can_have_DW_AT_const_value_p): New function.
6856 (partial_die_info::fixup): Inherit has_const_value.
6857
6858 2020-04-07 Tom de Vries <tdevries@suse.de>
6859
6860 * psymtab.c (maintenance_check_psymtabs): Skip static LOC_BLOCK
6861 symbols without address.
6862
6863 2020-04-06 Kamil Rytarowski <n54@gmx.com>
6864
6865 * nbsd-nat.h (struct thread_info): Add forward declaration.
6866 (nbsd_nat_target::thread_alive): Add.
6867 (nbsd_nat_target::thread_name): Likewise.
6868 (nbsd_nat_target::update_thread_list): Likewise.
6869 (update_thread_list::post_attach): Likewise.
6870 (post_attach::pid_to_str): Likewise.
6871 * nbsd-nat.c: Include "gdbthread.h" and "inferior.h".
6872 (nbsd_thread_lister): Add.
6873 (nbsd_nat_target::thread_alive): Likewise.
6874 (nbsd_nat_target::thread_name): Likewise.
6875 (nbsd_add_threads): Likewise.
6876 (update_thread_list::post_attach): Likewise.
6877 (nbsd_nat_target::update_thread_list): Likewise.
6878 (post_attach::pid_to_str): Likewise.
6879
6880 2020-04-06 Tom Tromey <tromey@adacore.com>
6881
6882 * ada-valprint.c (print_variant_part): Extract the variant field.
6883 (print_field_values): Use the field as the outer value when
6884 recursing.
6885
6886 2020-04-06 Tom Tromey <tromey@adacore.com>
6887
6888 * sh-nbsd-tdep.c: Include nbsd-tdep.h.
6889 * ppc-nbsd-tdep.c: Include nbsd-tdep.h.
6890 * mips-nbsd-tdep.c (mipsnbsd_init_abi): Add missing ";".
6891 * arm-nbsd-tdep.c: Include nbsd-tdep.h.
6892 * hppa-nbsd-tdep.c: Include nbsd-tdep.h.
6893
6894 2020-04-06 Tom Tromey <tromey@adacore.com>
6895
6896 * dwarf2/read.c (read_base_type) <DW_ATE_complex_float>: Handle
6897 TYPE_CODE_ERROR.
6898
6899 2020-04-06 Kamil Rytarowski <n54@gmx.com>
6900
6901 * nbsd-tdep.c: Include "gdbarch.h".
6902 Define enum with NetBSD signal numbers.
6903 (nbsd_gdb_signal_from_target, nbsd_gdb_signal_to_target): New.
6904 * alpha-nbsd-tdep.c (alphanbsd_init_abi): Call nbsd_init_abi().
6905 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
6906 * arm-nbsd-tdep.c (arm_netbsd_elf_init_abi): Likewise.
6907 * hppa-nbsd-tdep.c (hppanbsd_init_abi): Likewise.
6908 * i386-nbsd-tdep.c (i386nbsd_init_abi): Likewise.
6909 * mips-nbsd-tdep.c (nbsd_init_abi): Likewise.
6910 * ppc-nbsd-tdep.c (ppcnbsd_init_abi): Likewise.
6911 * sh-nbsd-tdep.c (shnbsd_init_abi): Likewise.
6912 * sparc-nbsd-tdep.c (sparc32nbsd_init_abi): Likewise.
6913 * sparc64-nbsd-tdep.c (sparc64nbsd_init_abi): Likewise.
6914 * vax-nbsd-tdep.c (vaxnbsd_elf_init_abi): Likewise.
6915
6916 2020-04-03 Hannes Domani <ssbssa@yahoo.de>
6917
6918 PR gdb/25325
6919 * dwarf2/read.c (read_enumeration_type): Fix typed enum attributes.
6920
6921 2020-04-03 Tom Tromey <tromey@adacore.com>
6922
6923 * dwarf2/loc.c (disassemble_dwarf_expression) <DW_OP_const_type>:
6924 Read constant block.
6925
6926 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
6927
6928 * gdb_bfd.h: Include gdbsupport/byte-vector.h.
6929 (gdb_bfd_get_full_section_contents): New declaration.
6930 * gdb_bfd.c (gdb_bfd_get_full_section_contents): New function.
6931 * windows-tdep.c (is_linked_with_cygwin_dll): Use
6932 gdb_bfd_get_full_section_contents.
6933
6934 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
6935
6936 * exec.c (build_section_table): Replace internal_error with
6937 gdb_assert.
6938 (section_table_xfer_memory_partial): Likewise.
6939 * mdebugread.c (parse_partial_symbols): Likewise.
6940 * psymtab.c (lookup_partial_symbol): Likewise.
6941 * utils.c (wrap_here): Likewise.
6942
6943 2020-04-02 Tom Tromey <tromey@adacore.com>
6944
6945 * f-lang.c (build_fortran_types): Use arch_type to initialize
6946 builtin_complex_s32 in the TYPE_CODE_ERROR case.
6947
6948 2020-04-02 Tom Tromey <tromey@adacore.com>
6949
6950 * dwarf2/read.c (partial_die_info::read): Do not create a vector
6951 of attributes.
6952
6953 2020-04-02 Andrew Burgess <andrew.burgess@embecosm.com>
6954 Bernd Edlinger <bernd.edlinger@hotmail.de>
6955 Tom Tromey <tromey@adacore.com>
6956
6957 * buildsym.c (buildsym_compunit::record_line): Remove
6958 deduplication code.
6959
6960 2020-04-02 Tom de Vries <tdevries@suse.de>
6961
6962 PR ada/24671
6963 * dwarf2/read.c (dw2_map_matching_symbols): Handle -readnow.
6964
6965 2020-04-02 Tom de Vries <tdevries@suse.de>
6966
6967 * dwarf2/read.c (dwarf2_gdb_index_functions,
6968 dwarf2_debug_names_functions): Init lookup_global_symbol_language with
6969 NULL.
6970 * psymtab.c (psym_lookup_global_symbol_language): New function.
6971 (psym_functions): Init psym_lookup_global_symbol_language with
6972 psym_lookup_global_symbol_language.
6973 * symfile-debug.c (debug_sym_quick_functions): Init
6974 lookup_global_symbol_language with NULL.
6975 * symfile.c (set_initial_language): Remove fixme comment.
6976 * symfile.h (struct quick_symbol_functions): Add
6977 lookup_global_symbol_language.
6978 * symtab.c (find_quick_global_symbol_language): New function.
6979 (find_main_name): Use find_quick_global_symbol_language.
6980
6981 2020-04-01 Simon Marchi <simon.marchi@polymtl.ca>
6982
6983 * windows-tdep.c (is_linked_with_cygwin_dll): Fix style.
6984
6985 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
6986
6987 * buildsym.c (record_line): Fix undefined behavior and preserve
6988 lines at eof.
6989
6990 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
6991
6992 * buildsym.c (record_line): Fix the resizing condition.
6993
6994 2020-04-01 Tom Tromey <tom@tromey.com>
6995
6996 * value.h (value_literal_complex): Add comment.
6997 * valops.c (value_literal_complex): Refer to value.h.
6998
6999 2020-04-01 Tom Tromey <tom@tromey.com>
7000
7001 * c-exp.y (FLOAT_KEYWORD, COMPLEX): New tokens.
7002 (scalar_type): New rule, from typebase.
7003 (typebase): Use scalar_type. Recognize complex types.
7004 (field_name): Handle FLOAT_KEYWORD.
7005 (ident_tokens): Add _Complex and __complex__.
7006
7007 2020-04-01 Tom Tromey <tom@tromey.com>
7008
7009 PR exp/25299:
7010 * valarith.c (promotion_type, complex_binop): New functions.
7011 (scalar_binop): Handle complex numbers. Use promotion_type.
7012 (value_pos, value_neg, value_complement): Handle complex numbers.
7013
7014 2020-04-01 Tom Tromey <tom@tromey.com>
7015
7016 * c-exp.y (COMPLEX_INT, COMPLEX_FLOAT): New tokens.
7017 (exp) <COMPLEX_INT, COMPLEX_FLOAT>: New rules.
7018 (parse_number): Handle complex numbers.
7019
7020 2020-04-01 Tom Tromey <tom@tromey.com>
7021
7022 * c-valprint.c (c_decorations): Change complex suffix to "i".
7023
7024 2020-04-01 Tom Tromey <tom@tromey.com>
7025
7026 * valprint.c (generic_value_print_complex): Use accessors.
7027 * value.h (value_real_part, value_imaginary_part): Declare.
7028 * valops.c (value_real_part, value_imaginary_part): New
7029 functions.
7030 * value.c (creal_internal_fn, cimag_internal_fn): Use accessors.
7031
7032 2020-04-01 Tom Tromey <tom@tromey.com>
7033
7034 * stabsread.c (rs6000_builtin_type, read_sun_floating_type)
7035 (read_range_type): Update.
7036 * mdebugread.c (basic_type): Update.
7037 * go-lang.c (build_go_types): Use init_complex_type.
7038 * gdbtypes.h (struct main_type) <complex_type>: New member.
7039 (init_complex_type): Update.
7040 (arch_complex_type): Don't declare.
7041 * gdbtypes.c (init_complex_type): Remove "objfile" parameter.
7042 Make name if none given. Use alloc_type_copy. Look for cached
7043 complex type.
7044 (arch_complex_type): Remove.
7045 (gdbtypes_post_init): Use init_complex_type.
7046 * f-lang.c (build_fortran_types): Use init_complex_type.
7047 * dwarf2/read.c (read_base_type): Update.
7048 * d-lang.c (build_d_types): Use init_complex_type.
7049 * ctfread.c (read_base_type): Update.
7050
7051 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
7052
7053 * infrun.c (stop_all_threads): Update assertion, plus when
7054 stopping threads, take into account that we might be trying
7055 to stop an all-stop target.
7056 (stop_waiting): Call 'stop_all_threads' if there exists a
7057 non-stop target.
7058
7059 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
7060
7061 * target.h (exists_non_stop_target): New function declaration.
7062 * target.c (exists_non_stop_target): New function.
7063
7064 2020-04-01 Hannes Domani <ssbssa@yahoo.de>
7065
7066 PR gdb/24789
7067 * eval.c (is_integral_or_integral_reference): New function.
7068 (evaluate_subexp_standard): Allow integer references in
7069 pointer arithmetic.
7070
7071 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
7072
7073 * remote.c (remote_target::remote_parse_stop_reply): Remove the
7074 check for no ptid in the stop reply when the target is non-stop.
7075
7076 2020-04-01 Tom Tromey <tromey@adacore.com>
7077
7078 * symtab.h (class lookup_name_info) <lookup_name_info>: Change
7079 "name" parameter to rvalue reference. Initialize m_name_holder.
7080 <lookup_name_info>: New overloads.
7081 <name>: Return gdb::string_view.
7082 <c_str>: New method.
7083 <make_ignore_params>: Update.
7084 <search_name_hash>: Update.
7085 <language_lookup_name>: Return const char *.
7086 <m_name>: Change type.
7087 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info)
7088 (demangle_for_lookup_info::demangle_for_lookup_info): Update.
7089 (lookup_name_info::match_any): Update.
7090 * psymtab.c (match_partial_symbol, lookup_partial_symbol):
7091 Update.
7092 * minsyms.c (linkage_name_str): Update.
7093 * language.c (default_symbol_name_matcher): Update.
7094 * dwarf2/read.c (mapped_index_base::find_name_components_bounds):
7095 Update.
7096 * ada-lang.c (ada_fold_name): Change parameter to string_view.
7097 (ada_lookup_name_info::ada_lookup_name_info): Update.
7098 (literal_symbol_name_matcher): Update.
7099
7100 2020-04-01 Tom Tromey <tromey@adacore.com>
7101
7102 * psymtab.c (psymtab_search_name): Remove function.
7103 (psym_lookup_symbol): Create search name and lookup name here.
7104 (lookup_partial_symbol): Remove "name" parameter; add
7105 lookup_name.
7106 (psym_expand_symtabs_for_function): Update.
7107
7108 2020-03-31 Joel Jones <joelkevinjones@gmail.com>
7109
7110 PR tui/25597:
7111 * python/py-tui.c: Include gdb_curses.h inside of #ifdef TUI.
7112
7113 2020-03-31 Tom Tromey <tromey@adacore.com>
7114
7115 * dwarf2/abbrev.c (abbrev_table::read): Conditionally call
7116 memcpy.
7117
7118 2020-03-30 Nelson Chu <nelson.chu@sifive.com>
7119
7120 * features/riscv/32bit-csr.xml: Regenerated.
7121 * features/riscv/64bit-csr.xml: Regenerated.
7122
7123 2020-03-30 Tom Tromey <tromey@adacore.com>
7124
7125 * ada-valprint.c (print_variant_part): Update.
7126 * ada-lang.h (ada_which_variant_applies): Update.
7127 * ada-lang.c (ada_which_variant_applies): Remove outer_type and
7128 outer_valaddr parameters; replace with "outer" value parameter.
7129 (to_fixed_variant_branch_type): Update.
7130
7131 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
7132
7133 * ppc-linux-nat.c: Include <algorithm>, <unordered_map>, and
7134 <list>. Remove inclusion of observable.h.
7135 (PPC_DEBUG_CURRENT_VERSION): Move up define.
7136 (struct arch_lwp_info): New struct.
7137 (class ppc_linux_dreg_interface): New class.
7138 (struct ppc_linux_process_info): New struct.
7139 (struct ppc_linux_nat_target) <low_delete_thread, low_new_fork>
7140 <low_new_clone, low_forget_process, low_prepare_to_resume>
7141 <copy_thread_dreg_state, mark_thread_stale>
7142 <mark_debug_registers_changed, register_hw_breakpoint>
7143 <clear_hw_breakpoint, register_wp, clear_wp>
7144 <can_use_watchpoint_cond_accel, calculate_dvc, check_condition>
7145 <num_memory_accesses, get_trigger_type>
7146 <create_watchpoint_request, hwdebug_point_cmp>
7147 <init_arch_lwp_info, get_arch_lwp_info>
7148 <low_stopped_by_watchpoint, low_stopped_data_address>: Declare as
7149 methods.
7150 <struct ptid_hash>: New inner struct.
7151 <m_dreg_interface, m_process_info, m_installed_hw_bps>: Declare
7152 members.
7153 (saved_dabr_value, hwdebug_info, max_slots_number)
7154 (struct hw_break_tuple, struct thread_points, ppc_threads)
7155 (have_ptrace_hwdebug_interface)
7156 (hwdebug_find_thread_points_by_tid)
7157 (hwdebug_insert_point, hwdebug_remove_point): Remove.
7158 (ppc_linux_nat_target::can_use_hw_breakpoint): Use
7159 m_dreg_interface, remove call to PTRACE_SET_DEBUGREG.
7160 (ppc_linux_nat_target::region_ok_for_hw_watchpoint): Add comment,
7161 use m_dreg_interface.
7162 (hwdebug_point_cmp): Change to...
7163 (ppc_linux_nat_target::hwdebug_point_cmp): ...this method. Use
7164 reference arguments instead of pointers.
7165 (ppc_linux_nat_target::ranged_break_num_registers): Use
7166 m_dreg_interface.
7167 (ppc_linux_nat_target::insert_hw_breakpoint): Add comment, use
7168 m_dreg_interface. Call register_hw_breakpoint.
7169 (ppc_linux_nat_target::remove_hw_breakpoint): Add comment, use
7170 m_dreg_interface. Call clear_hw_breakpoint.
7171 (get_trigger_type): Change to...
7172 (ppc_linux_nat_target::get_trigger_type): ...this method. Add
7173 comment.
7174 (ppc_linux_nat_target::insert_mask_watchpoint): Update comment,
7175 use m_dreg_interface. Call register_hw_breakpoint.
7176 (ppc_linux_nat_target::remove_mask_watchpoint): Update comment,
7177 use m_dreg_interface. Call clear_hw_breakpoint.
7178 (can_use_watchpoint_cond_accel): Change to...
7179 (ppc_linux_nat_target::can_use_watchpoint_cond_accel): ...this
7180 method. Update comment, use m_dreg_interface and
7181 m_process_info.
7182 (calculate_dvc): Change to...
7183 (ppc_linux_nat_target::calculate_dvc): ...this method. Use
7184 m_dreg_interface.
7185 (num_memory_accesses): Change to...
7186 (ppc_linux_nat_target::num_memory_accesses): ...this method.
7187 (check_condition): Change to...
7188 (ppc_linux_nat_target::check_condition): ...this method.
7189 (ppc_linux_nat_target::can_accel_watchpoint_condition): Update
7190 comment, use m_dreg_interface.
7191 (create_watchpoint_request): Change to...
7192 (ppc_linux_nat_target::create_watchpoint_request): ...this
7193 method. Use m_dreg_interface.
7194 (ppc_linux_nat_target::insert_watchpoint): Add comment, use
7195 m_dreg_interface. Call register_hw_breakpoint or register_wp.
7196 (ppc_linux_nat_target::remove_watchpoint): Add comment, use
7197 m_dreg_interface. Call clear_hw_breakpoint or clear_wp.
7198 (ppc_linux_nat_target::low_forget_process)
7199 (ppc_linux_nat_target::low_new_fork)
7200 (ppc_linux_nat_target::low_new_clone)
7201 (ppc_linux_nat_target::low_delete_thread)
7202 (ppc_linux_nat_target::low_prepare_to_resume): New methods.
7203 (ppc_linux_nat_target::low_new_thread): Remove previous logic,
7204 only call mark_thread_stale.
7205 (ppc_linux_thread_exit): Remove.
7206 (ppc_linux_nat_target::stopped_data_address): Change to...
7207 (ppc_linux_nat_target::low_stopped_data_address): This. Add
7208 comment, use m_dreg_interface and m_thread_hw_breakpoints.
7209 (ppc_linux_nat_target::stopped_by_watchpoint): Change to...
7210 (ppc_linux_nat_target::stopped_by_watchpoint): This. Add
7211 comment. Call low_stopped_data_address.
7212 (ppc_linux_nat_target::watchpoint_addr_within_range): Use
7213 m_dreg_interface.
7214 (ppc_linux_nat_target::masked_watch_num_registers): Use
7215 m_dreg_interface.
7216 (ppc_linux_nat_target::copy_thread_dreg_state)
7217 (ppc_linux_nat_target::mark_thread_stale)
7218 (ppc_linux_nat_target::mark_debug_registers_changed)
7219 (ppc_linux_nat_target::register_hw_breakpoint)
7220 (ppc_linux_nat_target::clear_hw_breakpoint)
7221 (ppc_linux_nat_target::register_wp)
7222 (ppc_linux_nat_target::clear_wp)
7223 (ppc_linux_nat_target::init_arch_lwp_info)
7224 (ppc_linux_nat_target::get_arch_lwp_info): New methods.
7225 (_initialize_ppc_linux_nat): Remove observer callback.
7226
7227 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
7228
7229 * ppc-linux-nat.c (ppc_linux_nat_target::store_registers)
7230 (ppc_linux_nat_target::auxv_parse)
7231 (ppc_linux_nat_target::read_description)
7232 (supply_gregset, fill_gregset, supply_fpregset, fill_fpregset):
7233 Move up.
7234
7235 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
7236
7237 * linux-nat.h (low_new_clone): New method.
7238 * linux-nat.c (linux_handle_extended_wait): Call low_new_clone.
7239
7240 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
7241
7242 * dbxread.c (dbx_psymtab_to_symtab_1): Rename to...
7243 (dbx_expand_psymtab): ... this.
7244 (start_psymtab): Update.
7245 * mdebugread.c (psymtab_to_symtab_1): Rename to...
7246 (mdebug_expand_psymtab): ... this.
7247 (parse_partial_symbols): Update.
7248 (new_psymtab): Update.
7249 * xcoffread.c (xcoff_psymtab_to_symtab_1): Rename to...
7250 (xcoff_expand_psymtab): ... this.
7251 (xcoff_start_psymtab): Update.
7252
7253 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
7254
7255 * psympriv.h (partial_symtab) <read_dependencies>: Rename to...
7256 <expand_dependencies>: ... this.
7257 * psymtab.c (partial_symtab::read_dependencies): Rename to...
7258 (partial_symtab::expand_dependencies): ... this.
7259 * dwarf2/read.c (dwarf2_include_psymtab) <expand_psymtab>:
7260 Update.
7261 (dwarf2_psymtab::expand_psymtab): Update.
7262 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
7263 * mdebugread.c (psymtab_to_symtab_1): Update.
7264 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
7265
7266 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
7267
7268 * psympriv.h (discard_psymtab): Remove.
7269 * dbxread.c (dbx_end_psymtab): Update.
7270 * xcoffread.c (xcoff_end_psymtab): Update.
7271
7272 2020-03-28 Tom Tromey <tom@tromey.com>
7273
7274 * dwarf2/attribute.h (struct attribute) <form_is_constant>: Update
7275 comment.
7276
7277 2020-03-28 Tom Tromey <tom@tromey.com>
7278
7279 * dwarf2/read.c (read_attribute_reprocess): Fix formatting.
7280
7281 2020-03-27 Hannes Domani <ssbssa@yahoo.de>
7282
7283 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
7284
7285 2020-03-26 John Baldwin <jhb@FreeBSD.org>
7286
7287 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_BSDFLAGS.
7288
7289 2020-03-26 Tom Tromey <tom@tromey.com>
7290
7291 * dwarf2/read.c (handle_data_member_location, dwarf2_add_field)
7292 (mark_common_block_symbol_computed, read_tag_string_type)
7293 (attr_to_dynamic_prop, read_subrange_type): Update.
7294 (dwarf2_get_ref_die_offset, dwarf2_get_attr_constant_value): Move
7295 to be methods on struct attribute.
7296 (skip_one_die, process_imported_unit_die, read_namespace_alias)
7297 (read_call_site_scope, partial_die_info::read)
7298 (partial_die_info::read, lookup_die_type, follow_die_ref):
7299 Update.
7300 * dwarf2/attribute.c (attribute::get_ref_die_offset): New method,
7301 from dwarf2_get_ref_die_offset.
7302 (attribute::constant_value): New method, from
7303 dwarf2_get_attr_constant_value.
7304 * dwarf2/attribute.h (struct attribute) <get_ref_die_offset>:
7305 Declare method.
7306 <constant_value>: New method.
7307
7308 2020-03-26 Tom Tromey <tom@tromey.com>
7309
7310 * dwarf2/read.c (dwarf_unit_type_name, dwarf_tag_name)
7311 (dwarf_attr_name, dwarf_form_name, dwarf_bool_name)
7312 (dwarf_type_encoding_name): Move to stringify.c.
7313 * Makefile.in (COMMON_SFILES): Add dwarf2/stringify.c.
7314 * dwarf2/stringify.c: New file.
7315 * dwarf2/stringify.h: New file.
7316
7317 2020-03-26 Tom Tromey <tom@tromey.com>
7318
7319 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>:
7320 Rewrite.
7321
7322 2020-03-26 Tom Tromey <tom@tromey.com>
7323
7324 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>: New
7325 methods.
7326 * dwarf2/read.c (lookup_addr_base): Move to die.h.
7327 (lookup_ranges_base): Likewise.
7328 (read_cutu_die_from_dwo, read_full_die_1): Update.
7329
7330 2020-03-26 Tom Tromey <tom@tromey.com>
7331
7332 * dwarf2/read.c (read_import_statement, read_file_scope)
7333 (read_type_unit_scope, inherit_abstract_dies, read_func_scope)
7334 (read_lexical_block_scope, read_call_site_scope)
7335 (dwarf2_get_subprogram_pc_bounds, get_scope_pc_bounds)
7336 (handle_struct_member_die, process_structure_scope)
7337 (update_enumeration_type_from_children)
7338 (process_enumeration_scope, read_array_type, read_common_block)
7339 (read_namespace, read_module, read_subroutine_type): Update.
7340 (sibling_die): Remove.
7341
7342 2020-03-26 Tom Tromey <tom@tromey.com>
7343
7344 * dwarf2/read.c (lookup_addr_base, lookup_ranges_base)
7345 (build_type_psymtabs_reader, read_structure_type)
7346 (read_enumeration_type, read_full_die_1): Update.
7347 (dwarf2_attr_no_follow): Move to die.h.
7348 * dwarf2/die.h (struct die_info) <attr>: New method.
7349
7350 2020-03-26 Tom Tromey <tom@tromey.com>
7351
7352 * dwarf2/read.c (struct dwarf2_cu) <base_known>: Remove.
7353 <base_address>: Now an optional.
7354 (dwarf2_find_base_address, dwarf2_rnglists_process)
7355 (dwarf2_ranges_process, fill_in_loclist_baton)
7356 (dwarf2_symbol_mark_computed): Update.
7357
7358 2020-03-26 Tom Tromey <tom@tromey.com>
7359
7360 * dwarf2/read.c (struct die_info): Move to die.h.
7361 * dwarf2/die.h: New file.
7362
7363 2020-03-26 Tom Tromey <tom@tromey.com>
7364
7365 * dwarf2/line-header.h (dwarf_decode_line_header): Declare.
7366 * dwarf2/read.c
7367 (dwarf2_statement_list_fits_in_line_number_section_complaint):
7368 Move to line-header.c.
7369 (read_checked_initial_length_and_offset, read_formatted_entries):
7370 Likewise.
7371 (dwarf_decode_line_header): Split into two.
7372 * dwarf2/line-header.c
7373 (dwarf2_statement_list_fits_in_line_number_section_complaint):
7374 Move from read.c.
7375 (read_checked_initial_length_and_offset, read_formatted_entries):
7376 Likewise.
7377 (dwarf_decode_line_header): New function, split from read.c.
7378
7379 2020-03-26 Tom Tromey <tom@tromey.com>
7380
7381 * dwarf2/read.h (struct dwarf2_per_objfile) <read_line_string>:
7382 Declare method.
7383 * dwarf2/read.c (read_attribute_value): Update.
7384 (dwarf2_per_objfile::read_line_string): Rename from
7385 read_indirect_line_string.
7386 (read_formatted_entries): Update.
7387
7388 2020-03-26 Tom Tromey <tom@tromey.com>
7389
7390 * dwarf2/macro.c (dwarf_decode_macro_bytes): Use objfile local
7391 variable.
7392
7393 2020-03-26 Tom Tromey <tom@tromey.com>
7394
7395 * dwarf2/macro.h (dwarf_decode_macros): Make section parameter
7396 const.
7397 * dwarf2/macro.c (skip_form_bytes, skip_unknown_opcode)
7398 (dwarf_decode_macro_bytes, dwarf_decode_macros): Make section
7399 parameter const.
7400
7401 2020-03-26 Tom Tromey <tom@tromey.com>
7402
7403 * dwarf2/read.c (dwarf_decode_macros): Make "lh" const.
7404 * dwarf2/macro.h (dwarf_decode_macros): Constify "lh" parameter.
7405 * dwarf2/macro.c (macro_start_file): Constify "lh" parameter.
7406 (dwarf_decode_macro_bytes, dwarf_decode_macros): Likewise.
7407
7408 2020-03-26 Tom Tromey <tom@tromey.com>
7409
7410 * dwarf2/line-header.h (struct line_header) <is_valid_file_index,
7411 file_names_size, file_full_name, file_file_name>: Use const.
7412 <file_name_at, file_names>: Add const overload.
7413 * dwarf2/line-header.c (line_header::file_file_name)
7414 (line_header::file_full_name): Update.
7415
7416 2020-03-26 Tom Tromey <tom@tromey.com>
7417
7418 * dwarf2/read.c (dwarf2_macro_malformed_definition_complaint)
7419 (macro_start_file, consume_improper_spaces)
7420 (parse_macro_definition, skip_form_bytes, skip_unknown_opcode)
7421 (dwarf_parse_macro_header, dwarf_decode_macro_bytes)
7422 (dwarf_decode_macros): Move to macro.c.
7423 * dwarf2/macro.c: New file.
7424 * dwarf2/macro.h: New file.
7425 * Makefile.in (COMMON_SFILES): Add dwarf2/macro.c.
7426
7427 2020-03-26 Tom Tromey <tom@tromey.com>
7428
7429 * dwarf2/section.h (struct dwarf2_section_info) <read_string>: New
7430 method.
7431 * dwarf2/section.c: New method. From
7432 read_indirect_string_at_offset_from.
7433 * dwarf2/read.c (mapped_debug_names::namei_to_name): Update.
7434 (read_indirect_string_at_offset_from): Move to section.c.
7435 (read_indirect_string_at_offset): Rewrite.
7436 (read_indirect_line_string_at_offset): Remove.
7437 (read_indirect_string, read_indirect_line_string)
7438 (dwarf_decode_macro_bytes): Update.
7439
7440 2020-03-26 Tom Tromey <tom@tromey.com>
7441
7442 * dwarf2/section.h (struct dwarf2_section_info)
7443 <overload_complaint>: Declare.
7444 (dwarf2_section_buffer_overflow_complaint): Don't declare.
7445 * dwarf2/section.c (dwarf2_section_info::overflow_complaint):
7446 Rename from dwarf2_section_buffer_overflow_complaint.
7447 * dwarf2/read.c (skip_one_die, partial_die_info::read)
7448 (skip_form_bytes, dwarf_decode_macro_bytes): Update.
7449
7450 2020-03-26 Tom Tromey <tom@tromey.com>
7451
7452 * dwarf2/section.h (dwarf2_section_buffer_overflow_complaint):
7453 Declare.
7454 * dwarf2/section.c (dwarf2_section_buffer_overflow_complaint):
7455 Move from read.c.
7456 * dwarf2/read.c (dwarf2_section_buffer_overflow_complaint): Move
7457 to section.c.
7458
7459 2020-03-26 Tom Tromey <tom@tromey.com>
7460
7461 * dwarf2/read.c (dwarf_decode_macros): Split into two overloads.
7462
7463 2020-03-26 Tom Tromey <tom@tromey.com>
7464
7465 * dwarf2/read.c (macro_start_file): Change "cu" parameter to
7466 "builder".
7467 (dwarf_decode_macro_bytes): Likewise. Add dwarf2_per_objfile
7468 parameter.
7469 (dwarf_decode_macros): Update.
7470
7471 2020-03-26 Tom Tromey <tom@tromey.com>
7472
7473 * dwarf2/read.c (read_attribute_value): Update.
7474 (read_indirect_string_from_dwz): Move to dwz.c; change into
7475 method.
7476 (dwarf_decode_macro_bytes): Update.
7477 * dwarf2/dwz.h (struct dwz_file) <read_string>: Declare method.
7478 * dwarf2/dwz.c: New file.
7479 * Makefile.in (COMMON_SFILES): Add dwz.c.
7480
7481 2020-03-26 Tom Tromey <tom@tromey.com>
7482
7483 * dwarf2/read.h (struct dwz_file): Move to dwz.h.
7484 * dwarf2/read.c: Add include.
7485 * dwarf2/index-write.c: Add include.
7486 * dwarf2/index-cache.c: Add include.
7487 * dwarf2/dwz.h: New file.
7488
7489 2020-03-25 Tom Tromey <tom@tromey.com>
7490
7491 * compile/compile-object-load.c (get_out_value_type): Mention
7492 correct symbol name in error message.
7493
7494 2020-03-25 Hannes Domani <ssbssa@yahoo.de>
7495
7496 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
7497
7498 2020-03-25 Tom de Vries <tdevries@suse.de>
7499
7500 * symtab.h (is_main_symtab_of_compunit_symtab): New function.
7501 * symmisc.c (dump_symtab_1): Print user and includes fields.
7502 (maintenance_info_symtabs): Same.
7503
7504 2020-03-25 Andrew Burgess <andrew.burgess@embecosm.com>
7505
7506 PR gdb/25534
7507 * riscv-tdep.c (riscv_arg_info::c_offset): Update comment.
7508 (riscv_regcache_cooked_write): New function.
7509 (riscv_push_dummy_call): Use new function.
7510 (riscv_return_value): Likewise.
7511
7512 2020-03-24 Simon Marchi <simon.marchi@polymtl.ca>
7513
7514 * fbsd-nat.c (fbsd_nat_target::follow_fork): Change bool to int.
7515 * fbsd-nat.h (class fbsd_nat_target) <follow_fork>: Likewise.
7516 * inf-ptrace.c (inf_ptrace_target::follow_fork): Likewise.
7517 * inf-ptrace.h (struct inf_ptrace_target) <follow_fork>: Likewise.
7518 * infrun.c (follow_fork): Likewise.
7519 (follow_fork_inferior): Likewise.
7520 * linux-nat.c (linux_nat_target::follow_fork): Likewise.
7521 * linux-nat.h (class linux_nat_target): Likewise.
7522 * remote.c (class remote_target) <follow_fork>: Likewise.
7523 (remote_target::follow_fork): Likewise.
7524 * target-delegates.c: Re-generate.
7525 * target.c (default_follow_fork): Likewise.
7526 (target_follow_fork): Likewise.
7527 * target.h (struct target_ops) <follow_fork>: Likewise.
7528 (target_follow_fork): Likewise.
7529
7530 2020-03-24 Tom de Vries <tdevries@suse.de>
7531
7532 * psymtab.c (maintenance_info_psymtabs): Print user field.
7533
7534 2020-03-20 Tom Tromey <tromey@adacore.com>
7535
7536 * dwarf2/loc.h (dwarf2_evaluate_property): Make "addr_stack"
7537 const.
7538 * dwarf2/loc.c (dwarf2_evaluate_property): Make "addr_stack"
7539 const.
7540
7541 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
7542
7543 * ptrace.m4: Don't check for ptrace declaration.
7544 * config.in: Re-generate.
7545 * configure: Re-generate.
7546 * nat/gdb_ptrace.h: Don't declare ptrace if HAVE_DECL_PTRACE is
7547 not defined.
7548
7549 2020-03-20 Kamil Rytarowski <n54@gmx.com>
7550
7551 * amd64-bsd-nat.c (gdb_ptrace): Change return type from `int' to
7552 `PTRACE_TYPE_RET'.
7553 * i386-bsd-nat.c (gdb_ptrace): Likewise.
7554 * sparc-nat.c (gdb_ptrace): Likewise.
7555 * x86-bsd-nat.c (gdb_ptrace): Likewise.
7556
7557 2020-03-20 Tom Tromey <tromey@adacore.com>
7558
7559 * c-exp.y (lex_one_token): Fix assert.
7560
7561 2020-03-20 Tom Tromey <tromey@adacore.com>
7562
7563 * ada-tasks.c (read_atcb): Use smaller length in strncpy call.
7564 * linux-tdep.c (linux_fill_prpsinfo): Use smaller length in
7565 strncpy call.
7566
7567 2020-03-20 Tom Tromey <tromey@adacore.com>
7568
7569 * symmisc.c (maintenance_print_one_line_table): Use ui_out.
7570
7571 2020-03-20 Tom Tromey <tromey@adacore.com>
7572
7573 * ada-valprint.c (print_variant_part): Remove parameters; switch
7574 to value-based API.
7575 (print_field_values): Likewise.
7576 (ada_val_print_struct_union): Likewise.
7577 (ada_value_print_1): Update.
7578
7579 2020-03-20 Kamil Rytarowski <n54@gmx.com>
7580
7581 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): Inherit from
7582 nbsd_nat_target instead of inf_ptrace_target.
7583 * ppc-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
7584 nbsd_nat_target.
7585
7586 2020-03-20 Kamil Rytarowski <n54@gmx.com>
7587
7588 * hppa-nbsd-nat.c (fetch_registers): New variable lwp and pass
7589 it to the ptrace call.
7590 * (store_registers): Likewise.
7591
7592 2020-03-20 Kamil Rytarowski <n54@gmx.com>
7593
7594 * ppc-nbsd-nat.c (fetch_registers): New variable lwp and pass
7595 it to the ptrace call.
7596 * (store_registers): Likewise.
7597
7598 2020-03-19 Luis Machado <luis.machado@linaro.org>
7599
7600 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_set_vq): If vg is not
7601 valid, fetch vg value from ptrace.
7602
7603 2020-03-19 Kamil Rytarowski <n54@gmx.com>
7604 * inf-ptrace.h: Disable get_ptrace_pid on NetBSD.
7605 * inf-ptrace.c: Likewise.
7606 * (gdb_ptrace): Add.
7607 * (inf_ptrace_target::resume): Update.
7608 * (inf_ptrace_target::xfer_partial): Likewise.
7609 * (inf_ptrace_peek_poke): Change argument `pid' to `ptid'.
7610 * (inf_ptrace_peek_poke): Update.
7611
7612 2020-03-19 Kamil Rytarowski <n54@gmx.com>
7613
7614 * x86-bsd-nat.c (gdb_ptrace): New.
7615 * (x86bsd_dr_set): Add new argument `ptid'.
7616 * (x86bsd_dr_get, x86bsd_dr_set, x86bsd_dr_set_control,
7617 x86bsd_dr_set_addr): Update.
7618
7619 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
7620
7621 * remote.c (remote_target::process_stop_reply): Handle events for
7622 all threads differently.
7623
7624 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
7625
7626 * completer.c (completion_tracker::remove_completion): Define new
7627 function.
7628 * completer.h (completion_tracker::remove_completion): Declare new
7629 function.
7630 * symtab.c (completion_list_add_symbol): Remove aliasing msymbols
7631 when adding a C++ function symbol.
7632
7633 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
7634
7635 * completer.c (completion_tracker::completion_hash_entry): Define
7636 new class.
7637 (advance_to_filename_complete_word_point): Call
7638 recompute_lowest_common_denominator.
7639 (completion_tracker::completion_tracker): Call discard_completions
7640 to setup the hash table.
7641 (completion_tracker::discard_completions): Allow for being called
7642 from the constructor, pass new equal function, and element deleter
7643 when constructing the hash table. Initialise new class member
7644 variables.
7645 (completion_tracker::maybe_add_completion): Remove use of
7646 m_entries_vec, and store more information into m_entries_hash.
7647 (completion_tracker::recompute_lcd_visitor): New function, most
7648 content taken from...
7649 (completion_tracker::recompute_lowest_common_denominator):
7650 ...here, this now just visits each item in the hash calling the
7651 above visitor.
7652 (completion_tracker::build_completion_result): Remove use of
7653 m_entries_vec, call recompute_lowest_common_denominator.
7654 * completer.h (completion_tracker::have_completions): Remove use
7655 of m_entries_vec.
7656 (completion_tracker::completion_hash_entry): Declare new class.
7657 (completion_tracker::recompute_lowest_common_denominator): Change
7658 function signature.
7659 (completion_tracker::recompute_lcd_visitor): Declare new function.
7660 (completion_tracker::m_entries_vec): Delete.
7661 (completion_tracker::m_entries_hash): Initialize to NULL.
7662 (completion_tracker::m_lowest_common_denominator_valid): New
7663 member variable.
7664 (completion_tracker::m_lowest_common_denominator_max_length): New
7665 member variable.
7666
7667 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7668
7669 * regformats/regdef.h: Put reg in gdb namespace.
7670
7671 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7672
7673 * i386-bsd-nat.c (gdb_ptrace): New.
7674 * (i386bsd_fetch_inferior_registers,
7675 i386bsd_store_inferior_registers) Switch from pid_t to ptid_t.
7676 * (i386bsd_fetch_inferior_registers,
7677 i386bsd_store_inferior_registers) Use gdb_ptrace.
7678
7679 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7680
7681 * amd64-bsd-nat.c (gdb_ptrace): New.
7682 * (amd64bsd_fetch_inferior_registers,
7683 amd64bsd_store_inferior_registers) Switch from pid_t to ptid_t.
7684 * (amd64bsd_fetch_inferior_registers,
7685 amd64bsd_store_inferior_registers) Use gdb_ptrace.
7686
7687 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7688
7689 * user-regs.c (user_reg::read): Rename to...
7690 (user_reg::xread): ...this.
7691 * (append_user_reg): Rename argument `read' to `xread'.
7692 * (user_reg_add_builtin): Likewise.
7693 * (user_reg_add): Likewise.
7694 * (value_of_user_reg): Likewise.
7695
7696 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7697
7698 * sparc-nat.c (gdb_ptrace): New.
7699 * sparc-nat.c (sparc_fetch_inferior_registers)
7700 (sparc_store_inferior_registers) Remove obsolete comment.
7701 * sparc-nat.c (sparc_fetch_inferior_registers)
7702 (sparc_store_inferior_registers) Switch from pid_t to ptid_t.
7703 * sparc-nat.c (sparc_fetch_inferior_registers)
7704 (sparc_store_inferior_registers) Use gdb_ptrace.
7705
7706 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7707
7708 * sh-nbsd-nat.c (fetch_registers): New variable lwp and pass
7709 it to the ptrace call.
7710 * sh-nbsd-nat.c (store_registers): Likewise.
7711
7712 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7713
7714 * sh-nbsd-nat.c (sh_nbsd_nat_target): Inherit from
7715 nbsd_nat_target instead of inf_ptrace_target.
7716 * sh-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
7717 nbsd_nat_target.
7718
7719 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7720
7721 * amd64-bsd-nat.c: Include amd64-bsd-nat.h".
7722
7723 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7724
7725 * nbsd-nat.c: Include <sys/types.h>, <sys/ptrace.h> and
7726 <sys/sysctl.h>.
7727 * nbsd-nat.c (nbsd_nat_target::pid_to_exec_file): Rewrite.
7728
7729 2020-03-17 Tom de Vries <tdevries@suse.de>
7730
7731 PR gdb/23710
7732 * dwarf2/read.h (struct dwarf2_per_cu_data): Add unit_type and lang
7733 fields.
7734 * dwarf2/read.c (process_psymtab_comp_unit): Initialize unit_type and lang
7735 fields.
7736 (process_imported_unit_die): Skip import of c++ CUs.
7737
7738 2020-03-16 Tom Tromey <tom@tromey.com>
7739
7740 * p-valprint.c (pascal_object_print_value): Initialize
7741 base_value.
7742
7743 2020-03-16 Anton Kolesov <anton.kolesov@synopsys.com>
7744 Shahab Vahedi <shahab@synopsys.com>
7745
7746 * Makefile.in: Add arch/arc.o
7747 * configure.tgt: Likewise.
7748 * arc-tdep.c (arc_tdesc_init): Use arc_read_description.
7749 (_initialize_arc_tdep): Don't initialize old target descriptions.
7750 (arc_read_description): New function to cache target descriptions.
7751 * arc-tdep.h (arc_read_description): Add proto type.
7752 * arch/arc.c: New file.
7753 * arch/arc.h: Likewise.
7754 * features/Makefile: Replace old target descriptions with new.
7755 * features/arc-arcompact.c: Remove.
7756 * features/arc-arcompact.xml: Likewise.
7757 * features/arc-v2.c: Likewise
7758 * features/arc-v2.xml: Likewise
7759 * features/arc/aux-arcompact.xml: New file.
7760 * features/arc/aux-v2.xml: Likewise.
7761 * features/arc/core-arcompact.xml: Likewise.
7762 * features/arc/core-v2.xml: Likewise.
7763 * features/arc/aux-arcompact.c: Generate.
7764 * features/arc/aux-v2.c: Likewise.
7765 * features/arc/core-arcompact.c: Likewise.
7766 * features/arc/core-v2.c: Likewise.
7767 * target-descriptions (maint_print_c_tdesc_cmd): Support ARC features.
7768
7769 2020-03-16 Tom Tromey <tromey@adacore.com>
7770
7771 PR gdb/25663:
7772 * dwarf2/read.c (dwarf2_name): Strip leading namespaces after
7773 putting value into bcache.
7774
7775 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7776
7777 PR gdb/21500
7778 * amd64-windows-tdep.c (amd64_windows_init_abi): Rename
7779 to...
7780 (amd64_windows_init_abi_common): ... this. Don't set size of
7781 long type.
7782 (amd64_windows_init_abi): New function.
7783 (amd64_cygwin_init_abi): New function.
7784 (_initialize_amd64_windows_tdep): Use amd64_cygwin_init_abi for
7785 the Cygwin OS ABI.
7786 * i386-windows-tdep.c (_initialize_i386_windows_tdep): Clarify
7787 comment.
7788
7789 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7790
7791 * windows-tdep.h (is_linked_with_cygwin_dll): New declaration.
7792 * windows-tdep.c (CYGWIN_DLL_NAME): New.
7793 (pe_import_directory_entry): New struct type.
7794 (is_linked_with_cygwin_dll): New function.
7795 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Select
7796 GDB_OSABI_CYGWIN if the BFD is linked with the Cygwin DLL.
7797 * i386-windows-tdep.c (i386_windows_osabi_sniffer): Likewise.
7798
7799 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7800
7801 * i386-windows-tdep.c: Mass-rename "cygwin" to "windows", except
7802 i386_cygwin_core_osabi_sniffer.
7803
7804 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7805
7806 * i386-cygwin-tdep.c: Rename to...
7807 * i386-windows-tdep.c: ... this.
7808 * Makefile.in (ALL_TARGET_OBS): Rename i386-cygwin-tdep.c to
7809 i386-windows-tdep.c.
7810 * configure.tgt: Likewise.
7811
7812 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7813
7814 * osabi.h (enum gdb_osabi): Add GDB_OSABI_WINDOWS.
7815 * osabi.c (gdb_osabi_names): Add "Windows".
7816 * i386-cygwin-tdep.c (i386_cygwin_osabi_sniffer): Return
7817 GDB_OSABI_WINDOWS when the binary's target is "pei-i386".
7818 (i386_cygwin_core_osabi_sniffer): New function, extracted from
7819 i386_cygwin_osabi_sniffer.
7820 (_initialize_i386_cygwin_tdep): Register OS ABI
7821 GDB_OSABI_WINDOWS for i386.
7822 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Return
7823 GDB_OSABI_WINDOWS when the binary's target is "pei-x86-64".
7824 (_initialize_amd64_windows_tdep): Register OS ABI GDB_OSABI_WINDOWS
7825 for x86-64.
7826 * configure.tgt: Use GDB_OSABI_WINDOWS as the default OS ABI
7827 when the target matches '*-*-mingw*'.
7828
7829 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7830
7831 * defs.h (enum gdb_osabi): Move to...
7832 * osabi.h (enum gdb_osabi): ... here.
7833 * gdbarch.sh: Include osabi.h in gdbarch.h.
7834 * gdbarch.h: Re-generate.
7835
7836 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7837
7838 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): New
7839 function.
7840 (_initialize_amd64_windows_tdep): Register osabi sniffer.
7841
7842 2020-03-14 Tom Tromey <tom@tromey.com>
7843
7844 * c-typeprint.c (cp_type_print_method_args): Print "__restrict__"
7845 for C++.
7846 (c_type_print_modifier): Likewise. Add "language" parameter.
7847 (c_type_print_varspec_prefix, c_type_print_base_struct_union)
7848 (c_type_print_base_1): Update.
7849 * type-stack.h (enum type_pieces) <tp_atomic, tp_restrict>: New
7850 constants.
7851 * type-stack.c (type_stack::insert): Handle tp_atomic and
7852 tp_restrict.
7853 (type_stack::follow_type_instance_flags): Likewise.
7854 (type_stack::follow_types): Likewise. Merge type-following code.
7855 * c-exp.y (RESTRICT, ATOMIC): New tokens.
7856 (space_identifier, cv_with_space_id)
7857 (const_or_volatile_or_space_identifier_noopt)
7858 (const_or_volatile_or_space_identifier): Remove.
7859 (single_qualifier, qualifier_seq_noopt, qualifier_seq): New
7860 rules.
7861 (ptr_operator, typebase): Update.
7862 (enum token_flag) <FLAG_C>: New constant.
7863 (ident_tokens): Add "restrict", "__restrict__", "__restrict", and
7864 "_Atomic".
7865 (lex_one_token): Handle FLAG_C.
7866
7867 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7868
7869 * m68k-bsd-nat.c (fetch_registers): New variable lwp and pass
7870 it to the ptrace call.
7871 * m68k-bsd-nat.c (store_registers): Likewise.
7872
7873 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7874
7875 * m68k-bsd-nat.c (m68kbsd_supply_gregset): Change type of regs to
7876 gdb_byte *.
7877 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
7878 * m68k-bsd-nat.c (m68kbsd_collect_gregset): Likewise.
7879 * m68k-bsd-nat.c (m68kbsd_supply_pcb): Cast &tmp to gdb_byte *.
7880
7881 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7882
7883 * m68k-bsd-nat.c (m68k_bsd_nat_target): Inherit from
7884 nbsd_nat_target instead of inf_ptrace_target.
7885 * m68k-bsd-nat.c: Include "nbsd-nat.h", as we are now using
7886 nbsd_nat_target.
7887
7888 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7889
7890 * m68k-bsd-nat.c: Define _KERNTYPES to get the declaration of
7891 register_t.
7892
7893 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7894
7895 * alpha-bsd-nat.c (fetch_registers): New variable lwp and pass
7896 it to the ptrace call.
7897 * alpha-bsd-nat.c (store_registers): Likewise.
7898
7899 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7900
7901 * alpha-bsd-nat.c: Remove <sys/procfs.h> and "gregset.h" from
7902 includes.
7903 * alpha-bsd-nat.c (gregset_t, fpregset_t): Remove.
7904 * alpha-bsd-nat.c (supply_gregset, fill_gregset, supply_fpregset,
7905 fill_fpregset): Likewise.
7906
7907 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7908
7909 * alpha-bsd-nat.c (alpha_netbsd_nat_target): Inherit from
7910 nbsd_nat_target instead of inf_ptrace_target.
7911 * alpha-bsd-nat.c: Include "nbsd-nat.h", as we are now using
7912 nbsd_nat_target.
7913
7914 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7915
7916 * alpha-bsd-nat.c: Define _KERNTYPES to get the declaration of
7917 register_t.
7918
7919 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7920
7921 * arm-nbsd-nat.c (fetch_register): New variable lwp and pass
7922 it to the ptrace call.
7923 * arm-nbsd-nat.c (fetch_fp_register): Likewise.
7924 * arm-nbsd-nat.c (fetch_fp_regs): Likewise.
7925 * arm-nbsd-nat.c (store_register): Likewise.
7926 * arm-nbsd-nat.c (store_regs): Likewise.
7927 * arm-nbsd-nat.c (store_fp_register): Likewise.
7928 * arm-nbsd-nat.c (store_fp_regs): Likewise.
7929
7930 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7931
7932 * arm-nbsd-nat.c (arm_netbsd_nat_target): Inherit from
7933 nbsd_nat_target instead of inf_ptrace_target.
7934 * arm-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
7935 nbsd_nat_target.
7936
7937 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7938
7939 * x86-bsd-nat.c (x86bsd_dr_get): New variable lwp and pass
7940 it to the ptrace call.
7941 * x86-bsd-nat.c (x86bsd_dr_set): Likewise.
7942
7943 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7944
7945 * vax-bsd-nat.c (vaxbsd_supply_gregset): New variable lwp and pass
7946 it to the ptrace call.
7947 * vax-bsd-nat.c (vaxbsd_collect_gregset): Likewise.
7948
7949 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7950
7951 * vax-bsd-nat.c (vaxbsd_supply_gregset): Cast gregs to const
7952 gdb_byte *.
7953 * vax-bsd-nat.c (vaxbsd_collect_gregset): Cast gregs to void *.
7954
7955 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7956
7957 * vax-bsd-nat.c (vax_bsd_nat_target): Inherit from nbsd_nat_target
7958 instead of inf_ptrace_target.
7959 * vax-bsd-nat.c: Include "nbsd-nat.h", as we are now using
7960 nbsd_nat_target.
7961
7962 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7963
7964 * mips-nbsd-nat.c: Define _KERNTYPES to get the declaration of
7965 register_t.
7966
7967 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7968
7969 * ppc-nbsd-nat.c: Define _KERNTYPES to get the declaration of
7970 register_t.
7971
7972 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7973
7974 * vax-bsd-nat.c: Define _KERNTYPES to get the declaration of
7975 register_t.
7976
7977 2020-03-13 Tom Tromey <tom@tromey.com>
7978
7979 * value.h (val_print): Don't declare.
7980 * valprint.h (val_print_array_elements)
7981 (val_print_scalar_formatted, generic_val_print): Don't declare.
7982 * valprint.c (generic_val_print_array): Take a struct value.
7983 (generic_val_print_ptr, generic_val_print_memberptr)
7984 (generic_val_print_bool, generic_val_print_int)
7985 (generic_val_print_char, generic_val_print_complex)
7986 (generic_val_print): Remove.
7987 (generic_value_print): Update.
7988 (do_val_print): Remove unused parameters. Don't call
7989 la_val_print.
7990 (val_print): Remove.
7991 (common_val_print): Update. Don't call value_check_printable.
7992 (val_print_scalar_formatted, val_print_array_elements): Remove.
7993 * rust-lang.c (rust_val_print): Remove.
7994 (rust_language_defn): Update.
7995 * p-valprint.c (pascal_val_print): Remove.
7996 (pascal_value_print_inner): Update.
7997 (pascal_object_print_val_fields, pascal_object_print_val):
7998 Remove.
7999 (pascal_object_print_static_field): Update.
8000 * p-lang.h (pascal_val_print): Don't declare.
8001 * p-lang.c (pascal_language_defn): Update.
8002 * opencl-lang.c (opencl_language_defn): Update.
8003 * objc-lang.c (objc_language_defn): Update.
8004 * m2-valprint.c (m2_print_unbounded_array, m2_val_print): Remove.
8005 * m2-lang.h (m2_val_print): Don't declare.
8006 * m2-lang.c (m2_language_defn): Update.
8007 * language.h (struct language_defn) <la_val_print>: Remove.
8008 * language.c (unk_lang_value_print_inner): Rename. Change
8009 argument types.
8010 (unknown_language_defn, auto_language_defn): Update.
8011 * go-valprint.c (go_val_print): Remove.
8012 * go-lang.h (go_val_print): Don't declare.
8013 * go-lang.c (go_language_defn): Update.
8014 * f-valprint.c (f_val_print): Remove.
8015 * f-lang.h (f_value_print): Don't declare.
8016 * f-lang.c (f_language_defn): Update.
8017 * d-valprint.c (d_val_print): Remove.
8018 * d-lang.h (d_value_print): Don't declare.
8019 * d-lang.c (d_language_defn): Update.
8020 * cp-valprint.c (cp_print_value_fields)
8021 (cp_print_value_fields_rtti, cp_print_value): Remove.
8022 (cp_print_static_field): Update.
8023 * c-valprint.c (c_val_print_array, c_val_print_ptr)
8024 (c_val_print_struct, c_val_print_union, c_val_print_int)
8025 (c_val_print_memberptr, c_val_print): Remove.
8026 * c-lang.h (c_val_print_array, cp_print_value_fields)
8027 (cp_print_value_fields_rtti): Don't declare.
8028 * c-lang.c (c_language_defn, cplus_language_defn)
8029 (asm_language_defn, minimal_language_defn): Update.
8030 * ada-valprint.c (ada_val_print_ptr, ada_val_print_num): Remove.
8031 (ada_val_print_enum): Take a struct value.
8032 (ada_val_print_flt, ada_val_print_array, ada_val_print_1)
8033 (ada_val_print): Remove.
8034 (ada_value_print_1): Update.
8035 (printable_val_type): Remove.
8036 * ada-lang.h (ada_val_print): Don't declare.
8037 * ada-lang.c (ada_language_defn): Update.
8038
8039 2020-03-13 Tom Tromey <tom@tromey.com>
8040
8041 * valprint.c (do_val_print): Update.
8042 * python/python-internal.h (gdbpy_apply_val_pretty_printer): Take
8043 a struct value.
8044 (value_to_value_object_no_release): Declare.
8045 * python/py-value.c (value_to_value_object_no_release): New
8046 function.
8047 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Take a
8048 struct value.
8049 * guile/scm-value.c (vlscm_scm_from_value_no_release): New
8050 function.
8051 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer): Take
8052 a struct value.
8053 * guile/guile-internal.h (vlscm_scm_from_value_no_release):
8054 Declare.
8055 (gdbscm_apply_val_pretty_printer): Take a struct value.
8056 * extension.h (apply_ext_lang_val_pretty_printer): Take a struct
8057 value.
8058 * extension.c (apply_ext_lang_val_pretty_printer): Take a struct
8059 value.
8060 * extension-priv.h (struct extension_language_ops)
8061 <apply_val_pretty_printer>: Take a struct value.
8062 * cp-valprint.c (cp_print_value): Create a struct value.
8063 (cp_print_value): Update.
8064
8065 2020-03-13 Tom Tromey <tom@tromey.com>
8066
8067 * ada-valprint.c (print_field_values): Call common_val_print.
8068
8069 2020-03-13 Tom Tromey <tom@tromey.com>
8070
8071 * ada-valprint.c (val_print_packed_array_elements): Remove
8072 bitoffset and val parameters. Call common_val_print.
8073 (ada_val_print_string): Remove offset, address, and original_value
8074 parameters.
8075 (ada_val_print_array): Update.
8076 (ada_value_print_array): New function.
8077 (ada_value_print_1): Call it.
8078
8079 2020-03-13 Tom Tromey <tom@tromey.com>
8080
8081 * ada-valprint.c (ada_value_print): Use common_val_print.
8082
8083 2020-03-13 Tom Tromey <tom@tromey.com>
8084
8085 * ada-valprint.c (ada_val_print_ref): Use common_val_print.
8086
8087 2020-03-13 Tom Tromey <tom@tromey.com>
8088
8089 * ada-valprint.c (ada_value_print_num): New function.
8090 (ada_value_print_1): Use it.
8091
8092 2020-03-13 Tom Tromey <tom@tromey.com>
8093
8094 * ada-valprint.c (ada_value_print_1) <TYPE_CODE_FLT>: Rewrite.
8095
8096 2020-03-13 Tom Tromey <tom@tromey.com>
8097
8098 * ada-valprint.c (ada_value_print_ptr): New function.
8099 (ada_value_print_1): Use it.
8100
8101 2020-03-13 Tom Tromey <tom@tromey.com>
8102
8103 * ada-valprint.c (ada_val_print_gnat_array): Take a struct value;
8104 call common_val_print.
8105 (ada_val_print_1): Update.
8106 (ada_value_print_1): New function.
8107 (ada_value_print_inner): Rewrite.
8108
8109 2020-03-13 Tom Tromey <tom@tromey.com>
8110
8111 * cp-valprint.c (cp_print_value_fields): Update.
8112 (cp_print_value): New function.
8113
8114 2020-03-13 Tom Tromey <tom@tromey.com>
8115
8116 * m2-valprint.c (m2_value_print_inner): Use
8117 cp_print_value_fields.
8118 * cp-valprint.c (cp_print_value_fields): New function.
8119 * c-valprint.c (c_value_print_struct): New function.
8120 (c_value_print_inner): Use c_value_print_struct.
8121 * c-lang.h (cp_print_value_fields): Declare.
8122
8123 2020-03-13 Tom Tromey <tom@tromey.com>
8124
8125 * c-valprint.c (c_value_print_array): New function.
8126 (c_value_print_inner): Use it.
8127
8128 2020-03-13 Tom Tromey <tom@tromey.com>
8129
8130 * c-valprint.c (c_value_print_memberptr): New function.
8131 (c_value_print_inner): Use it.
8132
8133 2020-03-13 Tom Tromey <tom@tromey.com>
8134
8135 * c-valprint.c (c_value_print_int): New function.
8136 (c_value_print_inner): Use it.
8137
8138 2020-03-13 Tom Tromey <tom@tromey.com>
8139
8140 * c-valprint.c (c_value_print_ptr): New function.
8141 (c_value_print_inner): Use it.
8142
8143 2020-03-13 Tom Tromey <tom@tromey.com>
8144
8145 * c-valprint.c (c_value_print_inner): Rewrite.
8146
8147 2020-03-13 Tom Tromey <tom@tromey.com>
8148
8149 * valprint.c (generic_value_print_complex): New function.
8150 (generic_value_print): Use it.
8151
8152 2020-03-13 Tom Tromey <tom@tromey.com>
8153
8154 * valprint.c (generic_val_print_float): Don't call
8155 val_print_scalar_formatted.
8156 (generic_val_print, generic_value_print): Update.
8157
8158 2020-03-13 Tom Tromey <tom@tromey.com>
8159
8160 * valprint.c (generic_value_print_char): New function
8161 (generic_value_print): Use it.
8162
8163 2020-03-13 Tom Tromey <tom@tromey.com>
8164
8165 * valprint.c (generic_value_print_int): New function.
8166 (generic_value_print): Use it.
8167
8168 2020-03-13 Tom Tromey <tom@tromey.com>
8169
8170 * valprint.c (generic_value_print_bool): New function.
8171 (generic_value_print): Use it.
8172
8173 2020-03-13 Tom Tromey <tom@tromey.com>
8174
8175 * valprint.c (generic_val_print_func): Simplify.
8176 (generic_val_print, generic_value_print): Update.
8177
8178 2020-03-13 Tom Tromey <tom@tromey.com>
8179
8180 * valprint.c (generic_val_print_flags): Remove.
8181 (generic_val_print, generic_value_print): Update.
8182 (val_print_type_code_flags): Add original_value parameter.
8183
8184 2020-03-13 Tom Tromey <tom@tromey.com>
8185
8186 * valprint.c (generic_val_print): Update.
8187 (generic_value_print): Update.
8188 * valprint.c (generic_val_print_enum): Don't call
8189 val_print_scalar_formatted.
8190
8191 2020-03-13 Tom Tromey <tom@tromey.com>
8192
8193 * valprint.c (generic_value_print): Call generic_value_print_ptr.
8194 * valprint.c (generic_value_print_ptr): New function.
8195
8196 2020-03-13 Tom Tromey <tom@tromey.com>
8197
8198 * valprint.c (generic_value_print): Rewrite.
8199
8200 2020-03-13 Tom Tromey <tom@tromey.com>
8201
8202 * p-valprint.c (pascal_object_print_value_fields)
8203 (pascal_object_print_value): New functions.
8204
8205 2020-03-13 Tom Tromey <tom@tromey.com>
8206
8207 * p-valprint.c (pascal_value_print_inner): Rewrite.
8208
8209 2020-03-13 Tom Tromey <tom@tromey.com>
8210
8211 * f-valprint.c (f_value_print_innner): Rewrite.
8212
8213 2020-03-13 Tom Tromey <tom@tromey.com>
8214
8215 * m2-valprint.c (m2_print_unbounded_array): New overload.
8216 (m2_print_unbounded_array): Update.
8217 (m2_print_array_contents): Take a struct value.
8218 (m2_value_print_inner): Rewrite.
8219
8220 2020-03-13 Tom Tromey <tom@tromey.com>
8221
8222 * d-valprint.c (dynamic_array_type): Call d_value_print_inner.
8223 (d_value_print_inner): New function.
8224 * d-lang.h (d_value_print_inner): Declare.
8225 * d-lang.c (d_language_defn): Use d_value_print_inner.
8226
8227 2020-03-13 Tom Tromey <tom@tromey.com>
8228
8229 * go-valprint.c (go_value_print_inner): New function.
8230 * go-lang.h (go_value_print_inner): Declare.
8231 * go-lang.c (go_language_defn): Use go_value_print_inner.
8232
8233 2020-03-13 Tom Tromey <tom@tromey.com>
8234
8235 * rust-lang.c (val_print_struct, rust_print_enum): Use the value
8236 API.
8237 (rust_val_print): Rewrite.
8238 (rust_value_print_inner): New function, from rust_val_print.
8239 (rust_language_defn): Use rust_value_print_inner.
8240
8241 2020-03-13 Tom Tromey <tom@tromey.com>
8242
8243 * ada-valprint.c (ada_value_print_inner): New function.
8244 * ada-lang.h (ada_value_print_inner): Declare.
8245 * ada-lang.c (ada_language_defn): Use ada_value_print_inner.
8246
8247 2020-03-13 Tom Tromey <tom@tromey.com>
8248
8249 * f-valprint.c (f_value_print_innner): New function.
8250 * f-lang.h (f_value_print_innner): Declare.
8251 * f-lang.c (f_language_defn): Use f_value_print_innner.
8252
8253 2020-03-13 Tom Tromey <tom@tromey.com>
8254
8255 * p-valprint.c (pascal_value_print_inner): New function.
8256 * p-lang.h (pascal_value_print_inner): Declare.
8257 * p-lang.c (pascal_language_defn): Use pascal_value_print_inner.
8258
8259 2020-03-13 Tom Tromey <tom@tromey.com>
8260
8261 * m2-valprint.c (m2_value_print_inner): New function.
8262 * m2-lang.h (m2_value_print_inner): Declare.
8263 * m2-lang.c (m2_language_defn): Use m2_value_print_inner.
8264
8265 2020-03-13 Tom Tromey <tom@tromey.com>
8266
8267 * opencl-lang.c (opencl_language_defn): Use c_value_print_inner.
8268 * objc-lang.c (objc_language_defn): Use c_value_print_inner.
8269 * c-valprint.c (c_value_print_inner): New function.
8270 * c-lang.h (c_value_print_inner): Declare.
8271 * c-lang.c (c_language_defn, cplus_language_defn)
8272 (asm_language_defn, minimal_language_defn): Use
8273 c_value_print_inner.
8274
8275 2020-03-13 Tom Tromey <tom@tromey.com>
8276
8277 * p-valprint.c (pascal_object_print_value_fields): Now static.
8278 * p-lang.h (pascal_object_print_value_fields): Don't declare.
8279
8280 2020-03-13 Tom Tromey <tom@tromey.com>
8281
8282 * c-valprint.c (c_val_print_array): Simplify.
8283
8284 2020-03-13 Tom Tromey <tom@tromey.com>
8285
8286 * valprint.c (value_print_array_elements): New function.
8287 * valprint.h (value_print_array_elements): Declare.
8288
8289 2020-03-13 Tom Tromey <tom@tromey.com>
8290
8291 * printcmd.c (print_formatted): Use value_print_scalar_formatted.
8292 * mips-tdep.c (mips_print_register): Use
8293 value_print_scalar_formatted.
8294
8295 2020-03-13 Tom Tromey <tom@tromey.com>
8296
8297 * valprint.h (value_print_scalar_formatted): Declare.
8298 * valprint.c (value_print_scalar_formatted): New function.
8299
8300 2020-03-13 Tom Tromey <tom@tromey.com>
8301
8302 * valprint.h (generic_value_print): Declare.
8303 * valprint.c (generic_value_print): New function.
8304
8305 2020-03-13 Tom Tromey <tom@tromey.com>
8306
8307 * valprint.c (do_val_print): Call la_value_print_inner, if
8308 available.
8309 * rust-lang.c (rust_language_defn): Update.
8310 * p-lang.c (pascal_language_defn): Update.
8311 * opencl-lang.c (opencl_language_defn): Update.
8312 * objc-lang.c (objc_language_defn): Update.
8313 * m2-lang.c (m2_language_defn): Update.
8314 * language.h (struct language_defn) <la_value_print_inner>: New
8315 member.
8316 * language.c (unknown_language_defn, auto_language_defn): Update.
8317 * go-lang.c (go_language_defn): Update.
8318 * f-lang.c (f_language_defn): Update.
8319 * d-lang.c (d_language_defn): Update.
8320 * c-lang.c (c_language_defn, cplus_language_defn)
8321 (asm_language_defn, minimal_language_defn): Update.
8322 * ada-lang.c (ada_language_defn): Update.
8323
8324 2020-03-13 Tom Tromey <tom@tromey.com>
8325
8326 * c-valprint.c (c_value_print): Use common_val_print.
8327
8328 2020-03-13 Tom Tromey <tom@tromey.com>
8329
8330 * cp-valprint.c (cp_print_static_field): Use common_val_print.
8331
8332 2020-03-13 Tom Tromey <tom@tromey.com>
8333
8334 * f-valprint.c (f77_print_array_1, f_val_print): Use
8335 common_val_print.
8336
8337 2020-03-13 Tom Tromey <tom@tromey.com>
8338
8339 * riscv-tdep.c (riscv_print_one_register_info): Use
8340 common_val_print.
8341
8342 2020-03-13 Tom Tromey <tom@tromey.com>
8343
8344 * mi/mi-main.c (output_register): Use common_val_print.
8345
8346 2020-03-13 Tom Tromey <tom@tromey.com>
8347
8348 * infcmd.c (default_print_one_register_info): Use
8349 common_val_print.
8350
8351 2020-03-13 Tom Tromey <tom@tromey.com>
8352
8353 * valprint.h (common_val_print_checked): Declare.
8354 * valprint.c (common_val_print_checked): New function.
8355 * stack.c (print_frame_arg): Use common_val_print_checked.
8356
8357 2020-03-13 Tom Tromey <tom@tromey.com>
8358
8359 * valprint.c (do_val_print): New function, from val_print.
8360 (val_print): Use do_val_print.
8361 (common_val_print): Use do_val_print.
8362
8363 2020-03-13 Tom Tromey <tom@tromey.com>
8364
8365 * valprint.c (value_print): Use scoped_value_mark.
8366
8367 2020-03-13 Tom de Vries <tdevries@suse.de>
8368
8369 PR symtab/25646
8370 * psymtab.c (partial_symtab::partial_symtab): Don't set
8371 globals_offset and statics_offset. Push element onto
8372 current_global_psymbols and current_static_psymbols stacks.
8373 (concat): New function.
8374 (end_psymtab_common): Set globals_offset and statics_offset. Pop
8375 element from current_global_psymbols and current_static_psymbols
8376 stacks. Concat popped elements to global_psymbols and
8377 static_symbols.
8378 (add_psymbol_to_list): Use current_global_psymbols and
8379 current_static_psymbols stacks.
8380 * psymtab.h (class psymtab_storage): Add current_global_psymbols and
8381 current_static_psymbols fields.
8382
8383 2020-03-12 Christian Biesinger <cbiesinger@google.com>
8384
8385 * corelow.c (sniff_core_bfd): Remove.
8386 (class core_target) <m_core_vec>: Remove.
8387 (core_target::core_target): Update.
8388 (core_file_fns): Remove.
8389 (deprecated_add_core_fns): Remove.
8390 (default_core_sniffer): Remove.
8391 (sniff_core_bfd): Remove.
8392 (default_check_format): Remove.
8393 (gdb_check_format): Remove.
8394 (core_target_open): Update.
8395 (core_target::get_core_register_section): Update.
8396 (get_core_registers_cb): Update.
8397 (core_target::fetch_registers): Update.
8398 * gdbcore.h (struct core_fns): Remove.
8399 (deprecated_add_core_fns): Remove.
8400 (default_core_sniffer): Remove.
8401 (default_check_format): Remove.
8402
8403 2020-03-12 Tom Tromey <tom@tromey.com>
8404
8405 * arm-tdep.c (struct arm_mapping_symbol) <value>: Now a
8406 CORE_ADDR.
8407 (struct arm_exidx_entry) <addr>: Now a CORE_ADDR.
8408
8409 2020-03-12 Tom Tromey <tom@tromey.com>
8410
8411 * remote.c (remote_target::download_tracepoint)
8412 (remote_target::enable_tracepoint)
8413 (remote_target::disable_tracepoint): Use phex, not sprintf_vma.
8414 * breakpoint.c (print_recreate_masked_watchpoint): Use phex, not
8415 sprintf_vma.
8416
8417 2020-03-12 Tom Tromey <tom@tromey.com>
8418
8419 * symfile-mem.c: Update CORE_ADDR size assert.
8420
8421 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
8422
8423 * selftest.m4: Move to gdbsupport/.
8424 * acinclude.m4: Update path to selftest.m4.
8425
8426 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
8427
8428 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Rename to...
8429 (SELFTESTS_SRCS): ... this. Add disasm-selftests.c,
8430 gdbarch-selfselftests.c and selftest-arch.c.
8431 (SUBDIR_UNITTESTS_OBS): Rename to...
8432 (SELFTESTS_OBS): ... this.
8433 (COMMON_SFILES): Remove disasm-selftests.c and
8434 gdbarch-selftests.c.
8435 * configure.ac: Don't add selftest-arch.{c,o} to
8436 CONFIG_{SRCS,OBS}.
8437 * disasm-selftests.c, gdbarch-selftests.c: Remove GDB_SELF_TEST
8438 preprocessor conditions.
8439
8440 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
8441
8442 * configure.ac: Don't source bfd/development.sh.
8443 * selftest.m4: Modify comment.
8444 * configure: Re-generate.
8445
8446 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
8447
8448 * selftest.m4 (GDB_AC_SELFTEST): Error out if $development is
8449 not "true" or "false".
8450 * configure: Re-generate.
8451
8452 2020-03-12 Christian Biesinger <cbiesinger@google.com>
8453
8454 * Makefile.in (HFILES_NO_SRCDIR): Add new arm-nbsd-tdep.h file.
8455 * arm-nbsd-nat.c (arm_supply_gregset): Moved to arm-nbsd-tdep and
8456 renamed to arm_nbsd_supply_gregset.
8457 (fetch_register): Update to call arm_nbsd_supply_gregset.
8458 (fetch_regs): Remove in favor of fetch_register with a -1 regno.
8459 (arm_netbsd_nat_target::fetch_registers): Update.
8460 (fetch_elfcore_registers): Removed.
8461 (_initialize_arm_netbsd_nat): Removed call to deprecated_add_core_fns.
8462 * arm-nbsd-tdep.c (struct arm_nbsd_reg): New struct.
8463 (arm_nbsd_supply_gregset): Moved from arm-nbsd-nat.c and updated to
8464 not require NetBSD system headers.
8465 (arm_nbsd_regset): New struct.
8466 (arm_nbsd_iterate_over_regset_sections): New function.
8467 (arm_netbsd_init_abi_common): Updated to call
8468 set_gdbarch_iterate_over_regset_sections.
8469 * arm-nbsd-tdep.h: New file.
8470
8471 2020-03-11 Kevin Buettner <kevinb@redhat.com>
8472
8473 * symtab.c (find_pc_sect_line): Add check which prevents infinite
8474 recursion.
8475
8476 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
8477
8478 * configure: Re-generate.
8479
8480 2020-03-11 Tom Tromey <tromey@adacore.com>
8481
8482 * ada-typeprint.c (print_choices): Fix comment.
8483
8484 2020-03-11 Andrew Burgess <andrew.burgess@embecosm.com>
8485
8486 * buildsyms.c (buildsym_compunit::record_line): Avoid accessing
8487 previous item in the list, when the list has no items.
8488
8489 2020-03-11 Tom de Vries <tdevries@suse.de>
8490
8491 * dwarf2/loc.c (dwarf2_evaluate_property): Handle NULL frame in
8492 PROP_LOCLIST handling code.
8493
8494 2020-03-10 Andrew Burgess <andrew.burgess@embecosm.com>
8495
8496 * buildsym-legacy.c (record_line): Pass extra parameter to
8497 record_line.
8498 * buildsym.c (buildsym_compunit::record_line): Take an extra
8499 parameter, reduce duplication in the line table, and record the
8500 is_stmt flag in the line table.
8501 * buildsym.h (buildsym_compunit::record_line): Add extra
8502 parameter.
8503 * disasm.c (do_mixed_source_and_assembly_deprecated): Ignore
8504 non-statement lines.
8505 * dwarf2/read.c (dwarf_record_line_1): Add extra parameter, pass
8506 this to the symtab builder.
8507 (dwarf_finish_line): Pass extra parameter to dwarf_record_line_1.
8508 (lnp_state_machine::record_line): Pass a suitable is_stmt flag
8509 through to dwarf_record_line_1.
8510 * infrun.c (process_event_stop_test): When stepping, don't stop at
8511 a non-statement instruction, and only refresh the step info when
8512 we land in the middle of a line's range. Also add an extra
8513 comment.
8514 * jit.c (jit_symtab_line_mapping_add_impl): Initialise is_stmt
8515 field.
8516 * record-btrace.c (btrace_find_line_range): Only record lines
8517 marked as is-statement.
8518 * stack.c (frame_show_address): Show the frame address if we are
8519 in a non-statement sal.
8520 * symmisc.c (dump_symtab_1): Print the is_stmt flag.
8521 (maintenance_print_one_line_table): Print a header for the is_stmt
8522 column, and include is_stmt information in the output.
8523 * symtab.c (find_pc_sect_line): Find lines marked as statements in
8524 preference to non-statements.
8525 (find_pcs_for_symtab_line): Prefer is-statement entries.
8526 (find_line_common): Likewise.
8527 * symtab.h (struct linetable_entry): Add is_stmt field.
8528 (struct symtab_and_line): Likewise.
8529 * xcoffread.c (arrange_linetable): Initialise is_stmt field when
8530 arranging the line table.
8531
8532 2020-03-07 Tom de Vries <tdevries@suse.de>
8533
8534 * dwarf2/read.c (read_typedef): Treat anonymous typedef as forwarder
8535 DIE.
8536
8537 2020-03-07 Tom Tromey <tom@tromey.com>
8538
8539 * valops.c (value_literal_complex): Remove obsolete comment.
8540 * gdbtypes.h (enum type_code) <TYPE_CODE_FLT>: Remove obsolete
8541 comment.
8542
8543 2020-03-06 Simon Marchi <simon.marchi@polymtl.ca>
8544
8545 * infrun.h: Forward-declare thread_info.
8546 (set_step_info): Add thread_info parameter, add doc.
8547 * infrun.c (set_step_info): Add thread_info parameter, move doc
8548 to header.
8549 * infrun.c (process_event_stop_test): Pass thread to
8550 set_step_info call.
8551 * infcmd.c (set_step_frame): Add thread_info pointer, pass it to
8552 set_step_info.
8553 (prepare_one_step): Add thread_info parameter, pass it to
8554 set_step_frame and prepare_one_step (recursive) call.
8555 (step_1): Pass thread to prepare_one_step call.
8556 (step_command_fsm::should_stop): Pass thread to
8557 prepare_one_step.
8558 (until_next_fsm): Pass thread to set_step_frame call.
8559 (finish_command): Pass thread to set_step_info call.
8560
8561 2020-03-06 Hannes Domani <ssbssa@yahoo.de>
8562
8563 * windows-tdep.c (windows_solib_create_inferior_hook):
8564 Check if inferior is running.
8565
8566 2020-03-06 Tom de Vries <tdevries@suse.de>
8567
8568 * NEWS: Fix "the the".
8569 * ctfread.c: Same.
8570
8571 2020-03-06 Tom de Vries <tdevries@suse.de>
8572
8573 * psymtab.c (psymtab_to_symtab): Don't print "done.".
8574
8575 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8576
8577 * .dir-locals.el: Add a comment referencing the other copies of
8578 this file.
8579
8580 2020-03-05 John Baldwin <jhb@FreeBSD.org>
8581
8582 * fbsd-tdep.c (fbsd_make_corefile_notes): Use std::string for
8583 psargs.
8584
8585 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
8586
8587 * .gitattributes: New file.
8588
8589 2020-03-04 Tom Tromey <tom@tromey.com>
8590
8591 * symmisc.c (print_symbol_bcache_statistics)
8592 (print_objfile_statistics): Update.
8593 * symfile.c (allocate_symtab): Use intern.
8594 * psymtab.c (partial_symtab::partial_symtab): Use intern.
8595 * objfiles.h (struct objfile_per_bfd_storage) <filename_cache,
8596 macro_cache>: Remove.
8597 <string_cache>: New member.
8598 (struct objfile) <intern>: New methods.
8599 * elfread.c (elf_symtab_read): Use intern.
8600 * dwarf2/read.c (fixup_go_packaging): Intern package name.
8601 (dwarf2_compute_name, dwarf2_physname)
8602 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2): Intern
8603 names.
8604 (guess_partial_die_structure_name): Update.
8605 (partial_die_info::fixup): Intern name.
8606 (dwarf2_canonicalize_name): Change parameter to objfile. Intern
8607 name.
8608 (dwarf2_name): Intern name. Update.
8609 * buildsym.c (buildsym_compunit::get_macro_table): Use
8610 string_cache.
8611
8612 2020-03-04 Tom Tromey <tom@tromey.com>
8613
8614 * jit.c (bfd_open_from_target_memory): Make "target" const.
8615 * corefile.c (gnutarget): Now const.
8616 * gdbcore.h (gnutarget): Now const.
8617
8618 2020-03-04 Hannes Domani <ssbssa@yahoo.de>
8619
8620 * NEWS: Mention support for WOW64 processes.
8621 * amd64-windows-nat.c (amd64_mappings): Rename and remove static.
8622 (amd64_windows_segment_register_p): Remove static.
8623 (_initialize_amd64_windows_nat): Update.
8624 * configure.nat <windows> (NATDEPFILES): Add i386-windows-nat.o.
8625 * i386-windows-nat.c (context_offset): Update.
8626 (i386_mappings): Rename and remove static.
8627 (i386_windows_segment_register_p): Remove static.
8628 (_initialize_i386_windows_nat): Update.
8629 * windows-nat.c (STATUS_WX86_BREAKPOINT): New macro.
8630 (STATUS_WX86_SINGLE_STEP): New macro.
8631 (EnumProcessModulesEx): New macro.
8632 (Wow64SuspendThread): New macro.
8633 (Wow64GetThreadContext): New macro.
8634 (Wow64SetThreadContext): New macro.
8635 (Wow64GetThreadSelectorEntry): New macro.
8636 (windows_set_context_register_offsets): Add static.
8637 (windows_set_segment_register_p): Likewise.
8638 (windows_add_thread): Adapt for WOW64 processes.
8639 (windows_fetch_one_register): Likewise.
8640 (windows_nat_target::fetch_registers): Likewise.
8641 (windows_store_one_register): Likewise.
8642 (display_selector): Likewise.
8643 (display_selectors): Likewise.
8644 (handle_exception): Likewise.
8645 (windows_continue): Likewise.
8646 (windows_nat_target::resume): Likewise.
8647 (windows_add_all_dlls): Likewise.
8648 (do_initial_windows_stuff): Likewise.
8649 (windows_nat_target::attach): Likewise.
8650 (windows_get_exec_module_filename): Likewise.
8651 (windows_nat_target::create_inferior): Likewise.
8652 (windows_xfer_siginfo): Likewise.
8653 (_initialize_loadable): Initialize Wow64SuspendThread,
8654 Wow64GetThreadContext, Wow64SetThreadContext,
8655 Wow64GetThreadSelectorEntry and EnumProcessModulesEx.
8656 * windows-nat.h (windows_set_context_register_offsets):
8657 Remove declaration.
8658 (windows_set_segment_register_p): Likewise.
8659 (i386_windows_segment_register_p): Add declaration.
8660 (amd64_windows_segment_register_p): Likewise.
8661
8662 2020-03-04 Luis Machado <luis.machado@linaro.org>
8663
8664 Revert aa66aac47b4dd38f9524ddb5546c08cc09930d37 due to regressions
8665 in "info registers" for AArch64/ARM.
8666
8667 The change caused "info registers" to not print GPR's.
8668
8669 gdb/ChangeLog:
8670
8671 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
8672
8673 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
8674 when reg->group is empty and reggroup is not.
8675
8676 2020-03-03 Tom Tromey <tromey@adacore.com>
8677
8678 * dwarf2/frame.c (struct dwarf2_frame_cache)
8679 <checked_tailcall_bottom, entry_cfa_sp_offset,
8680 entry_cfa_sp_offset_p>: Remove members.
8681 (dwarf2_frame_cache): Call dwarf2_tailcall_sniffer_first.
8682 (dwarf2_frame_prev_register): Don't call
8683 dwarf2_tailcall_sniffer_first.
8684 (dwarf2_append_unwinders): Don't append tailcall unwinder.
8685 * frame-unwind.c (add_unwinder): New fuction.
8686 (frame_unwind_init): Use it. Add tailcall unwinder.
8687
8688 2020-03-03 Andrew Burgess <andrew.burgess@embecosm.com>
8689 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
8690
8691 * f-valprint.c (f_val_print): Handle TYPE_CODE_BOOL, any non-zero
8692 value should be printed as true.
8693
8694 2020-03-03 Hannes Domani <ssbssa@yahoo.de>
8695
8696 * windows-tdep.c (windows_solib_create_inferior_hook): New function.
8697 (windows_init_abi): Set and use windows_so_ops.
8698
8699 2020-03-03 Sergio Durigan Junior <sergiodj@redhat.com>
8700
8701 * printcmd.c (print_c_string): Check also for TYPE_CODE_PTR
8702 when verifying if dealing with a convenience variable.
8703
8704 2020-03-03 Luis Machado <luis.machado@linaro.org>
8705
8706 * auxv.c (default_print_auxv_entry): Add new AUXV entries.
8707
8708 2020-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8709
8710 * infrun.c (gdbarch_supports_displaced_stepping): New.
8711 (use_displaced_stepping): Break up conditions in smaller pieces.
8712 Use gdbarch_supports_displaced_stepping.
8713 (displaced_step_prepare_throw): Use
8714 gdbarch_supports_displaced_stepping.
8715
8716 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
8717
8718 * NEWS: Mention new behaviour of the history filename.
8719 * top.c (write_history_p): Add comment.
8720 (show_write_history_p): Add header comment, give a different
8721 message when history writing is on, but the history filename is
8722 empty.
8723 (history_filename): Add comment.
8724 (history_filename_empty): New function.
8725 (show_history_filename): Add header comment, give a different
8726 message when the filename is empty.
8727 (init_history): Compare history_filename against nullptr, and only
8728 read history if the filename is not empty.
8729 (set_history_filename): Add header comment, and only make
8730 non-empty filenames absolute.
8731 (init_main): Make the filename argument to 'set history filename'
8732 optional.
8733
8734 2020-03-02 Christian Biesinger <cbiesinger@google.com>
8735
8736 * arm-nbsd-nat.c (arm_supply_fparegset): Rename to...
8737 (arm_supply_vfpregset): ...this, and update to use VFP registers.
8738 (fetch_fp_register): Update.
8739 (fetch_fp_regs): Update.
8740 (store_fp_register): Update.
8741 (store_fp_regs): Update.
8742 (arm_netbsd_nat_target::read_description): New function.
8743 (fetch_elfcore_registers): Update.
8744
8745 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
8746
8747 * remote.c (remote_target::remote_parse_stop_reply): Don't use the
8748 general_thread if the stop reply is missing a thread-id.
8749 (remote_target::process_stop_reply): Use the first non-exited
8750 thread if the target didn't pass a thread-id.
8751 * infrun.c (do_target_wait): Move call to
8752 switch_to_inferior_no_thread to ....
8753 (do_target_wait_1): ... here.
8754
8755 2020-02-29 Jon Turney <jon.turney@dronecode.org.uk>
8756
8757 * debuginfod-support.c: Include defs.h first.
8758
8759 2020-02-28 Tom de Vries <tdevries@suse.de>
8760
8761 * symfile.c (set_initial_language): Use default language for lookup.
8762
8763 2020-02-28 Simon Marchi <simon.marchi@efficios.com>
8764
8765 * dwarf2/read.c (cutu_reader::init_tu_and_read_dwo_dies): Remove
8766 reader variable, pass `this` to read_cutu_die_from_dwo.
8767
8768 2020-02-27 Aaron Merey <amerey@redhat.com>
8769
8770 * source.c (open_source_file): Check for nullptr when computing
8771 srcpath.
8772
8773 2020-02-27 Tom Tromey <tromey@adacore.com>
8774
8775 * dwarf2/read.c (struct field_info) <nfields>: Now a method, not a
8776 member.
8777 (dwarf2_add_field): Don't update nfields.
8778 (dwarf2_attach_fields_to_type, process_structure_scope): Update.
8779
8780 2020-02-27 Andrew Burgess <andrew.burgess@embecosm.com>
8781
8782 * gdbtypes.c (create_array_type_with_stride): Use std::abs not
8783 abs.
8784
8785 2020-02-26 Tom Tromey <tom@tromey.com>
8786
8787 * dwarf2/read.c (struct dwarf2_include_psymtab): New.
8788 (dwarf2_create_include_psymtab): Use dwarf2_include_psymtab.
8789 (dwarf2_psymtab::expand_psymtab, dwarf2_psymtab::readin_p)
8790 (dwarf2_psymtab::get_compunit_symtab): Remove null checks for
8791 per_cu_data.
8792
8793 2020-02-26 Tom Tromey <tom@tromey.com>
8794
8795 * dwarf2/index-write.c (psym_index_map): Change type.
8796 (add_address_entry_worker, write_one_signatured_type)
8797 (recursively_count_psymbols, recursively_write_psymbols)
8798 (class debug_names, psyms_seen_size, write_gdbindex)
8799 (write_debug_names): Use partial_symtab, not dwarf2_psymtab.
8800
8801 2020-02-26 Aaron Merey <amerey@redhat.com>
8802
8803 * Makefile.in: Handle optional debuginfod support.
8804 * NEWS: Update.
8805 * README: Add --with-debuginfod summary.
8806 * config.in: Regenerate.
8807 * configure: Regenerate.
8808 * configure.ac: Handle optional debuginfod support.
8809 * debuginfod-support.c: debuginfod helper functions.
8810 * debuginfod-support.h: Ditto.
8811 * doc/gdb.texinfo: Add --with-debuginfod to configure options
8812 summary.
8813 * dwarf2/read.c (dwarf2_get_dwz_file): Query debuginfod servers
8814 when a dwz file cannot be found.
8815 * elfread.c (elf_symfile_read): Query debuginfod servers when a
8816 debuginfo file cannot be found.
8817 * source.c (open_source_file): Query debuginfod servers when a
8818 source file cannot be found.
8819 * top.c (print_gdb_configuration): Include
8820 --{with,without}-debuginfod in the output.
8821
8822 2020-02-26 Jérémie Galarneau <jeremie.galarneau@efficios.com>
8823
8824 * thread.c (thr_try_catch_cmd): Print thread name.
8825
8826 2020-02-26 Simon Marchi <simon.marchi@efficios.com>
8827
8828 * dwarf2/loc.h (dwarf2_fetch_die_loc_sect_off,
8829 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
8830 dwarf2_fetch_die_type_sect_off): Move to...
8831 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
8832 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
8833 dwarf2_fetch_die_type_sect_off): ... here.
8834 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
8835 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
8836 dwarf2_fetch_die_type_sect_off): Move doc to header file.
8837
8838 2020-02-26 Tom de Vries <tdevries@suse.de>
8839
8840 PR gdb/25603
8841 * symfile.c (set_initial_language): Exit-early if
8842 language_mode == language_mode_manual.
8843
8844 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
8845
8846 * dwarf2/loc.h (dwarf2_read_addr_index): Move...
8847 * dwarf2/read.h (dwarf2_read_addr_index): ... here.
8848 * dwarf2/read.c (dwarf2_read_addr_index): Move doc to header.
8849
8850 2020-02-25 Andrew Burgess <andrew.burgess@embecosm.com>
8851
8852 * gdbtypes.c (create_array_type_with_stride): Handle negative
8853 array strides.
8854 * valarith.c (value_subscripted_rvalue): Likewise.
8855
8856 2020-02-25 Luis Machado <luis.machado@linaro.org>
8857
8858 * aarch64-tdep.c (aarch64_vnv_type): Fix comment typo.
8859
8860 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
8861
8862 * loc.h (dwarf2_get_die_type): Move to...
8863 * read.h (dwarf2_get_die_type): ... here.
8864 * read.c (dwarf2_get_die_type): Move doc to header.
8865
8866 2020-02-25 Joel Brobecker <brobecker@adacore.com>
8867
8868 * copypright.py (EXCLUDE_LIST): Add 'gnulib/config.in' and
8869 'gnulib/Makefile.in' to the list.
8870
8871 2020-02-24 Tom Tromey <tom@tromey.com>
8872
8873 * dwarf2/read.h (struct type_unit_unshareable) <num_symtabs>:
8874 Remove.
8875 * dwarf2/read.c (dwarf2_cu::setup_type_unit_groups): Use
8876 XOBNEWVEC.
8877
8878 2020-02-24 Tom Tromey <tom@tromey.com>
8879
8880 * dwarf2/read.h (struct dwarf2_per_cu_data) <type_unit_group_p>:
8881 New method.
8882 * dwarf2/read.c (IS_TYPE_UNIT_GROUP): Remove.
8883 (dw2_do_instantiate_symtab, dw2_get_file_names)
8884 (build_type_psymtab_dependencies, load_full_type_unit): Update.
8885
8886 2020-02-24 Tom Tromey <tom@tromey.com>
8887
8888 * dwarf2read.c (dwarf2_build_psymtabs_hard): Use
8889 make_scoped_restore.
8890 (dwarf2_psymtab::read_symtab): Don't clear
8891 reading_partial_symbols.
8892
8893 2020-02-24 Tom de Vries <tdevries@suse.de>
8894
8895 PR gdb/25592
8896 * stack.c (iterate_over_block_locals): Handle LOC_CONST.
8897
8898 2020-02-24 Tom de Vries <tdevries@suse.de>
8899
8900 * tui/tui-layout.c (_initialize_tui_layout): Fix help messages for
8901 commands layout next/prev/regs.
8902
8903 2020-02-22 Tom Tromey <tom@tromey.com>
8904
8905 * dwarf2/loc.h (dwarf2_compile_expr_to_ax): Don't declare.
8906 * dwarf2/loc.c (dwarf2_compile_expr_to_ax): Now static.
8907
8908 2020-02-22 Tom Tromey <tom@tromey.com>
8909
8910 * tui/tui-data.h (TUI_DISASM_WIN): Cast to tui_disasm_window.
8911
8912 2020-02-22 Tom Tromey <tom@tromey.com>
8913
8914 * tui/tui-win.c (_initialize_tui_win): Add usage text.
8915 * tui/tui-stack.c (_initialize_tui_stack): Add usage text.
8916 * tui/tui-regs.c (_initialize_tui_regs): Add usage text.
8917 * tui/tui.c (_initialize_tui): Add usage text.
8918
8919 2020-02-22 Tom Tromey <tom@tromey.com>
8920
8921 * tui/tui-win.c (tui_set_focus_command)
8922 (tui_set_win_height_command): Use error_no_arg.
8923 (_initialize_tui_win): Update help text.
8924 (FOCUS_USAGE, WIN_HEIGHT_USAGE): Don't define.
8925
8926 2020-02-22 Tom Tromey <tom@tromey.com>
8927
8928 * tui/tui-layout.c (extract_display_start_addr): Rewrite.
8929 * tui/tui-disasm.h (struct tui_disasm_window)
8930 <display_start_addr>: Declare.
8931 * tui/tui-source.h (struct tui_source_window)
8932 <display_start_addr>: Declare.
8933 * tui/tui-winsource.h (struct tui_source_window_base)
8934 <show_source_line, display_start_addr>: New methods.
8935 <m_horizontal_offset, m_start_line_or_addr, m_gdbarch, m_content>:
8936 Rename and move to protected section.
8937 * tui/tui-winsource.c (tui_source_window_base::update_source_window)
8938 (tui_source_window_base::do_erase_source_content): Update.
8939 (tui_source_window_base::show_source_line): Now a method.
8940 (tui_source_window_base::show_source_content)
8941 (tui_source_window_base::tui_source_window_base)
8942 (tui_source_window_base::rerender)
8943 (tui_source_window_base::refill)
8944 (tui_source_window_base::do_scroll_horizontal)
8945 (tui_source_window_base::set_is_exec_point_at)
8946 (tui_source_window_base::update_breakpoint_info)
8947 (tui_source_window_base::update_exec_info): Update.
8948 * tui/tui-source.c (tui_source_window::set_contents)
8949 (tui_source_window::showing_source_p)
8950 (tui_source_window::do_scroll_vertical)
8951 (tui_source_window::location_matches_p)
8952 (tui_source_window::line_is_displayed): Update.
8953 (tui_source_window::display_start_addr): New method.
8954 * tui/tui-disasm.c (tui_disasm_window::set_contents)
8955 (tui_disasm_window::do_scroll_vertical)
8956 (tui_disasm_window::location_matches_p): Update.
8957 (tui_disasm_window::display_start_addr): New method.
8958
8959 2020-02-22 Tom Tromey <tom@tromey.com>
8960
8961 * NEWS: Add entry for gdb.register_window_type.
8962 * tui/tui-layout.h (window_factory): New typedef.
8963 (tui_register_window): Declare.
8964 * tui/tui-layout.c (saved_tui_windows): New global.
8965 (tui_apply_current_layout): Use it.
8966 (tui_register_window): New function.
8967 * python/python.c (do_start_initialization): Call
8968 gdbpy_initialize_tui.
8969 (python_GdbMethods): Add "register_window_type" function.
8970 * python/python-internal.h (gdbpy_register_tui_window)
8971 (gdbpy_initialize_tui): Declare.
8972 * python/py-tui.c: New file.
8973 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-tui.c.
8974
8975 2020-02-22 Tom Tromey <tom@tromey.com>
8976
8977 * tui/tui-io.c (do_tui_putc): Don't omit annotations.
8978
8979 2020-02-22 Tom Tromey <tom@tromey.com>
8980
8981 * tui/tui-win.c (tui_set_win_focus_to): Move to tui-data.c.
8982 * tui/tui-data.h (tui_set_win_with_focus): Don't declare.
8983 * tui/tui-data.c (tui_set_win_with_focus): Remove.
8984 (tui_set_win_focus_to): Move from tui-win.c.
8985
8986 2020-02-22 Tom Tromey <tom@tromey.com>
8987
8988 * tui/tui-layout.c (make_standard_window, get_locator_window): New
8989 functions.
8990 (known_window_types): New global.
8991 (tui_get_window_by_name): Reimplement.
8992 (initialize_known_windows): New function.
8993 (validate_window_name): Rewrite.
8994 (_initialize_tui_layout): Call initialize_known_windows.
8995
8996 2020-02-22 Tom Tromey <tom@tromey.com>
8997
8998 * tui/tui.h (enum tui_win_type) <LOCATOR_WIN, DATA_ITEM_WIN>:
8999 Remove constants.
9000 * tui/tui-winsource.h (struct tui_source_window_base)
9001 <tui_source_window_base>: Remove parameter.
9002 * tui/tui-winsource.c
9003 (tui_source_window_base::tui_source_window_base): Remove
9004 parameter.
9005 (tui_source_window_base::refill): Update.
9006 * tui/tui-stack.h (struct tui_locator_window)
9007 <tui_locator_window>: Update.
9008 * tui/tui-source.h (struct tui_source_window) <tui_source_window>:
9009 Default the constructor.
9010 * tui/tui-regs.h (struct tui_data_item_window)
9011 <tui_data_item_window>: Default the constructor.
9012 (struct tui_data_window) <tui_data_window>: Likewise.
9013 * tui/tui-disasm.h (struct tui_disasm_window) <tui_disasm_window>:
9014 Default the constructor.
9015 * tui/tui-data.h (struct tui_gen_win_info) <tui_gen_win_info>:
9016 Default the constructor.
9017 <type>: Remove.
9018 (struct tui_win_info) <tui_win_info>: Default the constructor.
9019 * tui/tui-data.c (tui_win_info::tui_win_info): Remove.
9020 * tui/tui-command.h (struct tui_cmd_window) <tui_cmd_window>:
9021 Default the constructor.
9022
9023 2020-02-22 Tom Tromey <tom@tromey.com>
9024
9025 * tui/tui-wingeneral.h (tui_make_all_invisible): Don't declare.
9026 * tui/tui-wingeneral.c (tui_make_all_invisible): Remove.
9027 * tui/tui-win.c (tui_resize_all): Don't call
9028 tui_delete_invisible_windows.
9029 * tui/tui-layout.c (tui_apply_current_layout): Delete windows when
9030 done.
9031 (tui_set_layout): Update.
9032 (tui_add_win_to_layout): Don't call tui_delete_invisible_windows.
9033 * tui/tui-data.h (tui_delete_invisible_windows): Don't declare.
9034 * tui/tui-data.c (tui_delete_invisible_windows): Remove.
9035
9036 2020-02-22 Tom Tromey <tom@tromey.com>
9037
9038 * tui/tui-win.c (tui_partial_win_by_name): Handle ambiguity
9039 correctly.
9040
9041 2020-02-22 Tom Tromey <tom@tromey.com>
9042
9043 * tui/tui-data.c (tui_next_win, tui_prev_win): Reimplement.
9044
9045 2020-02-22 Tom Tromey <tom@tromey.com>
9046
9047 * tui/tui-winsource.h (struct tui_source_window_iterator)
9048 <inner_iterator>: New etytypedef.
9049 <tui_source_window_iterator>: Take "end" parameter.
9050 <tui_source_window_iterator>: Take iterator.
9051 <operator*, advance>: Update.
9052 <m_iter>: Change type.
9053 <m_end>: New field.
9054 (struct tui_source_windows) <begin, end>: Update.
9055 * tui/tui-layout.c (tui_windows): New global.
9056 (tui_apply_current_layout): Clear tui_windows.
9057 (tui_layout_window::apply): Update tui_windows.
9058 * tui/tui-data.h (tui_windows): Declare.
9059 (all_tui_windows): Now inline function.
9060 (class tui_window_iterator, struct all_tui_windows): Remove.
9061
9062 2020-02-22 Tom Tromey <tom@tromey.com>
9063
9064 PR tui/17850:
9065 * tui/tui-win.c (tui_gen_win_info::max_width): New method.
9066 * tui/tui-layout.h (class tui_layout_base) <get_sizes>: Add
9067 "height" argument.
9068 (class tui_layout_window) <get_sizes>: Likewise.
9069 (class tui_layout_split) <tui_layout_split>: Add "vertical"
9070 argument.
9071 <get_sizes>: Add "height" argument.
9072 <m_vertical>: New field.
9073 * tui/tui-layout.c (tui_layout_split::clone): Update.
9074 (tui_layout_split::get_sizes): Add "height" argument.
9075 (tui_layout_split::adjust_size, tui_layout_split::apply): Update.
9076 (tui_new_layout_command): Parse "-horizontal".
9077 (_initialize_tui_layout): Update help string.
9078 (tui_layout_split::specification): Add "-horizontal" when needed.
9079 * tui/tui-layout.c (tui_layout_window::get_sizes): Add "height"
9080 argument.
9081 * tui/tui-data.h (struct tui_gen_win_info) <max_width, min_width>:
9082 New methods.
9083
9084 2020-02-22 Tom Tromey <tom@tromey.com>
9085
9086 * tui/tui-layout.h (enum tui_adjust_result): New.
9087 (class tui_layout_base) <adjust_size>: Return tui_adjust_result.
9088 (class tui_layout_window) <adjust_size>: Return
9089 tui_adjust_result. Rewrite.
9090 (class tui_layout_split) <adjust_size>: Return tui_adjust_result.
9091 * tui/tui-layout.c (tui_layout_split::adjust_size): Update.
9092
9093 2020-02-22 Tom Tromey <tom@tromey.com>
9094
9095 * tui/tui-layout.h (class tui_layout_split) <add_split>: Change
9096 parameter and return types.
9097 (class tui_layout_base) <specification>: Add "depth".
9098 (class tui_layout_window) <specification>: Add "depth".
9099 (class tui_layout_split) <specification>: Add "depth".
9100 * tui/tui-layout.c (tui_layout_split::add_split): Change parameter
9101 and return types.
9102 (tui_new_layout_command): Parse sub-layouts.
9103 (_initialize_tui_layout): Update help string.
9104 (tui_layout_window::specification): Add "depth".
9105 (add_layout_command): Update.
9106
9107 2020-02-22 Tom Tromey <tom@tromey.com>
9108
9109 * NEWS: Add "tui new-layout" item.
9110 * tui/tui-layout.c (add_layout_command): Return cmd_list_element.
9111 Add new-layout command to help text.
9112 (validate_window_name): New function.
9113 (tui_new_layout_command): New function.
9114 (_initialize_tui_layout): Register "new-layout".
9115 (tui_layout_window::specification): New method.
9116 (tui_layout_window::specification): New method.
9117 * tui/tui-layout.h (class tui_layout_base) <specification>: New
9118 method.
9119 (class tui_layout_window) <specification>: New method.
9120 (class tui_layout_split) <specification>: New method.
9121
9122 2020-02-22 Tom Tromey <tom@tromey.com>
9123
9124 * tui/tui.c (tui_enable): Call tui_set_initial_layout.
9125 * tui/tui-win.c (window_name_completer): Update comment.
9126 * tui/tui-layout.h (class tui_layout_base) <replace_window>:
9127 Declare method.
9128 (class tui_layout_window) <replace_window>: Likewise.
9129 (class tui_layout_split) <replace_window>: Likewise.
9130 (tui_set_layout): Don't declare.
9131 (tui_set_initial_layout): Declare function.
9132 * tui/tui-layout.c (layouts, applied_skeleton, src_regs_layout)
9133 (asm_regs_layout): New globals.
9134 (tui_current_layout, show_layout): Remove.
9135 (tui_set_layout, tui_add_win_to_layout): Rewrite.
9136 (find_layout, tui_apply_layout): New function.
9137 (layout_completer): Remove.
9138 (tui_next_layout): Reimplement.
9139 (tui_next_layout_command): New function.
9140 (tui_set_initial_layout, tui_prev_layout_command): New functions.
9141 (tui_regs_layout): Reimplement.
9142 (tui_regs_layout_command): New function.
9143 (extract_display_start_addr): Rewrite.
9144 (next_layout, prev_layout): Remove.
9145 (tui_layout_window::replace_window): New method.
9146 (tui_layout_split::replace_window): New method.
9147 (destroy_layout): New function.
9148 (layout_list): New global.
9149 (add_layout_command): New function.
9150 (initialize_layouts): Update.
9151 (tui_layout_command): New function.
9152 (_initialize_tui_layout): Install "layout" commands.
9153 * tui/tui-data.h (enum tui_layout_type): Remove.
9154 (tui_current_layout): Don't declare.
9155
9156 2020-02-22 Tom Tromey <tom@tromey.com>
9157
9158 * tui/tui-regs.c (tui_reg_layout): Remove.
9159 (tui_reg_command): Use tui_regs_layout.
9160 * tui/tui-layout.h (tui_reg_command): Declare.
9161 * tui/tui-layout.c (tui_reg_command): New function.
9162
9163 2020-02-22 Tom Tromey <tom@tromey.com>
9164
9165 * tui/tui.c (tui_rl_delete_other_windows): Call
9166 tui_remove_some_windows.
9167 * tui/tui-layout.h (class tui_layout_base) <remove_windows>:
9168 Declare method.
9169 (class tui_layout_window) <remove_windows>: New method.
9170 (class tui_layout_split) <remove_windows>: Declare.
9171 (tui_remove_some_windows): Declare.
9172 * tui/tui-layout.c (tui_remove_some_windows): New function.
9173 (tui_layout_split::remove_windows): New method.
9174
9175 2020-02-22 Tom Tromey <tom@tromey.com>
9176
9177 * tui/tui.c (tui_rl_change_windows): Call tui_next_layout.
9178 * tui/tui-layout.h (tui_next_layout): Declare.
9179 * tui/tui-layout.c (tui_next_layout): New function.
9180
9181 2020-02-22 Tom Tromey <tom@tromey.com>
9182
9183 * tui/tui-regs.c (tui_data_window::display_registers_from): Use
9184 correct coordinates.
9185
9186 2020-02-22 Tom Tromey <tom@tromey.com>
9187
9188 * tui/tui-layout.h (tui_add_win_to_layout): Add comment.
9189 * tui/tui-layout.c (tui_add_win_to_layout): Add assert. Remove
9190 DATA_WIN case.
9191
9192 2020-02-22 Tom Tromey <tom@tromey.com>
9193
9194 * tui/tui-disasm.c (tui_get_low_disassembly_address): Use
9195 TUI_DISASM_WIN, not tui_win_list.
9196
9197 2020-02-22 Tom Tromey <tom@tromey.com>
9198
9199 * valprint.c (generic_val_print_enum_1)
9200 (val_print_type_code_flags): Style member names.
9201 * rust-lang.c (val_print_struct, rust_print_enum)
9202 (rust_print_struct_def, rust_internal_print_type): Style member
9203 names.
9204 * p-valprint.c (pascal_object_print_value_fields): Style member
9205 names. Only call fprintf_symbol_filtered for static members.
9206 * m2-typeprint.c (m2_record_fields, m2_enum): Style member names.
9207 * f-valprint.c (f_val_print): Style member names.
9208 * f-typeprint.c (f_type_print_base): Style member names.
9209 * cp-valprint.c (cp_print_value_fields): Style member names. Only
9210 call fprintf_symbol_filtered for static members.
9211 (cp_print_class_member): Style member names.
9212 * c-typeprint.c (c_print_type_1, c_type_print_base_1): Style
9213 member names.
9214 * ada-valprint.c (ada_print_scalar): Style enum names.
9215 (ada_val_print_enum): Likewise.
9216 * ada-typeprint.c (print_enum_type): Style enum names.
9217
9218 2020-02-21 Tom Tromey <tom@tromey.com>
9219
9220 * psympriv.h (struct partial_symtab): Update comment.
9221
9222 2020-02-21 Tom Tromey <tromey@adacore.com>
9223
9224 * mips-tdep.h (mips_pc_is_mips16, mips_pc_is_micromips): Parameter
9225 type is CORE_ADDR.
9226
9227 2020-02-21 Tom de Vries <tdevries@suse.de>
9228
9229 PR gdb/25534
9230 * psymtab.c (partial_symtab::read_dependencies): Don't read dependency
9231 if dependencies[i]->user != NULL.
9232
9233 2020-02-21 Ali Tamur <tamur@google.com>
9234
9235 * dwarf2/read.c (dwarf2_name): Add null check.
9236
9237 2020-02-20 Tom Tromey <tom@tromey.com>
9238
9239 * dwarf2/read.c (dwarf2_find_containing_comp_unit): Use ">", not
9240 ">=", in binary search.
9241 (dwarf2_find_containing_comp_unit): New overload.
9242 (run_test): New self-test.
9243 (_initialize_dwarf2_read): Register new test.
9244
9245 2020-02-20 Nelson Chu <nelson.chu@sifive.com>
9246
9247 * riscv-tdep.c: Updated since the DECLARE_CSR is changed.
9248 * riscv-tdep.h: Likewise.
9249 * features/riscv/rebuild-csr-xml.sh: Generate the 64bit-csr.xml without
9250 rv32-only CSR.
9251 * features/riscv/64bit-csr.xml: Regenerated.
9252
9253 2020-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
9254 Tom Tromey <tom@tromey.com>
9255
9256 * utils.c (fputs_maybe_filtered): Call 'stream->puts' instead
9257 of 'fputc_unfiltered'.
9258 (putchar_unfiltered): Call 'fputc_unfiltered'.
9259 (fputc_unfiltered): Call 'fputs_unfiltered'.
9260
9261 2020-02-20 Andrew Burgess <andrew.burgess@embecosm.com>
9262
9263 * config.in: Regenerate.
9264 * configure: Regenerate.
9265 * configure.ac: Add --with-python-libdir option.
9266 * main.c: Use WITH_PYTHON_LIBDIR.
9267
9268 2020-02-19 Tom Tromey <tom@tromey.com>
9269
9270 * symtab.c (general_symbol_info::compute_and_set_names): Use
9271 obstack_strndup. Simplify call to symbol_set_demangled_name.
9272
9273 2020-02-19 Simon Marchi <simon.marchi@efficios.com>
9274
9275 * dwarf2/read.c (allocate_signatured_type_table,
9276 allocate_dwo_unit_table, allocate_type_unit_groups_table,
9277 allocate_dwo_file_hash_table, allocate_dwp_loaded_cutus_table):
9278 Remove objfile parameter, update all callers.
9279
9280 2020-02-19 Doug Evans <dje@google.com>
9281
9282 PR rust/25535
9283 * rust-lang.c (rust_print_enum): Apply embedded_offset to
9284 rust_enum_variant calculation.
9285
9286 2020-02-19 Tom Tromey <tromey@adacore.com>
9287
9288 * mips-tdep.h (mips_pc_is_mips): Parameter type is CORE_ADDR.
9289
9290 2020-02-19 Tom Tromey <tromey@adacore.com>
9291
9292 * ada-lang.c (cache_symbol): Use obstack_strdup.
9293
9294 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
9295
9296 * configure: Regenerate.
9297
9298 2020-02-19 Tom Tromey <tromey@adacore.com>
9299
9300 * python/python.c (do_start_initialization): Use XNEWVEC. Remove
9301 NULL check.
9302
9303 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
9304
9305 * NEWS: Mention RISC-V GNU/Linux GDBserver support.
9306
9307 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
9308
9309 * arch/riscv.c (struct riscv_gdbarch_features_hasher): Only define
9310 if GDBSERVER is not defined.
9311 (riscv_tdesc_cache): Likewise, also store const target_desc.
9312 (STATIC_IN_GDB): Define.
9313 (riscv_create_target_description): Update declaration with
9314 STATIC_IN_GDB.
9315 (riscv_lookup_target_description): New function, only define if
9316 GDBSERVER is not defined.
9317 * arch/riscv.h (riscv_create_target_description): Declare only
9318 when GDBSERVER is defined.
9319 (riscv_lookup_target_description): New declaration when GDBSERVER
9320 is not defined.
9321 * nat/riscv-linux-tdesc.c (riscv_linux_read_description): Rename to...
9322 (riscv_linux_read_features): ...this, and return
9323 riscv_gdbarch_features instead of target_desc.
9324 * nat/riscv-linux-tdesc.h: Include 'arch/riscv.h'.
9325 (riscv_linux_read_description): Rename to...
9326 (riscv_linux_read_features): ...this.
9327 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
9328 Update to use riscv_gdbarch_features and
9329 riscv_lookup_target_description.
9330 * riscv-tdep.c (riscv_find_default_target_description): Use
9331 riscv_lookup_target_description instead of
9332 riscv_create_target_description.
9333
9334 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
9335
9336 * valprint.c (generic_val_print_enum_1): When printing a flag
9337 enum with value 0 and there is no enumerator with value 0, print
9338 just "0" instead of "(unknown: 0x0)".
9339
9340 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
9341
9342 * valprint.c (generic_val_print_enum_1): Print unknown part of
9343 flag enum in hex.
9344
9345 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
9346
9347 * dwarf2/read.c (update_enumeration_type_from_children): Allow
9348 flag enums to contain duplicate enumerators.
9349 * valprint.c (generic_val_print_enum_1): Update comment.
9350
9351 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
9352
9353 * dwarf2/read.c: Include "count-one-bits.h".
9354 (update_enumeration_type_from_children): If an enumerator has
9355 multiple bits set, don't treat the enumeration as a "flag enum".
9356 * valprint.c (generic_val_print_enum_1): Assert that enumerators
9357 of flag enums have 0 or 1 bit set.
9358
9359 2020-02-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
9360
9361 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use an explicit
9362 conversion.
9363 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
9364 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
9365 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
9366 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
9367 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
9368
9369 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
9370
9371 * MAINTAINERS: Change palmer@sifive.com to palmer@dabbelt.com.
9372
9373 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
9374
9375 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use
9376 displaced_step_closure_up.
9377 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
9378 (struct displaced_step_closure_up):
9379 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
9380 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
9381 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn):
9382 Likewise.
9383 * gdbarch.sh (displaced_step_copy_insn): Likewise.
9384 * gdbarch.c, gdbarch.h: Re-generate.
9385 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Use
9386 displaced_step_closure_up.
9387 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
9388 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
9389 * infrun.h (displaced_step_closure_up): New type alias.
9390 (struct displaced_step_inferior_state) <step_closure>: Change
9391 type to displaced_step_closure_up.
9392 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Use
9393 displaced_step_closure_up.
9394 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
9395
9396 2020-02-14 Tom Tromey <tom@tromey.com>
9397
9398 * minidebug.c (gnu_debug_key): New global.
9399 (find_separate_debug_file_in_section): Use it.
9400
9401 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
9402
9403 * gdbarch.sh (displaced_step_copy_insn): Change return type to an
9404 std::unique_ptr.
9405 * gdbarch.c: Re-generate.
9406 * gdbarch.h: Re-generate.
9407 * infrun.c (displaced_step_prepare_throw): Adjust to std::unique_ptr
9408 change.
9409 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Change return
9410 type to std::unique_ptr.
9411 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
9412 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
9413 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
9414 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
9415 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Likewise.
9416 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
9417 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
9418 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
9419 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
9420
9421 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
9422
9423 * infrun.c (get_displaced_step_closure_by_addr): Adjust to
9424 std::unique_ptr.
9425 (displaced_step_clear): Rename to...
9426 (displaced_step_reset): ... this. Just call displaced->reset ().
9427 (displaced_step_clear_cleanup): Rename to...
9428 (displaced_step_reset_cleanup): ... this.
9429 (displaced_step_prepare_throw): Adjust to std::unique_ptr.
9430 (displaced_step_fixup): Likewise.
9431 (resume_1): Likewise.
9432 (handle_inferior_event): Restore child's memory before calling
9433 displaced_step_fixup on the parent.
9434 * infrun.h (displaced_step_inferior_state) <reset>: Adjust
9435 to std::unique_ptr.
9436 <step_closure>: Change type to std::unique_ptr.
9437
9438 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
9439
9440 * arm-tdep.c: Include count-one-bits.h.
9441 (cleanup_block_store_pc): Use count_one_bits.
9442 (cleanup_block_load_pc): Use count_one_bits.
9443 (arm_copy_block_xfer): Use count_one_bits.
9444 (thumb2_copy_block_xfer): Use count_one_bits.
9445 (thumb_copy_pop_pc_16bit): Use count_one_bits.
9446 * arch/arm-get-next-pcs.c: Include count-one-bits.h.
9447 (thumb_get_next_pcs_raw): Use count_one_bits.
9448 (arm_get_next_pcs_raw): Use count_one_bits_l.
9449 * arch/arm.c (bitcount): Remove.
9450 * arch/arm.h (bitcount): Remove.
9451
9452 2020-02-14 Tom Tromey <tromey@adacore.com>
9453
9454 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first):
9455 Update.
9456 * dwarf2/loc.h (call_site_find_chain): Return unique_xmalloc_ptr.
9457 * dwarf2/loc.c (call_site_find_chain_1): Return
9458 unique_xmalloc_ptr.
9459 (call_site_find_chain): Likewise.
9460
9461 2020-02-14 Richard Biener <rguenther@suse.de>
9462
9463 * dwarf2/read.c (lnp_state_machine::handle_special_opcode): Apply CSE
9464 on expression with division operators.
9465
9466 2020-02-13 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
9467
9468 * MAINTAINERS (Write After Approval): Adding myself.
9469
9470 2020-02-12 Tom Tromey <tom@tromey.com>
9471
9472 * event-loop.c (event_data, gdb_event, event_handler_func):
9473 Remove.
9474
9475 2020-02-12 Tom Tromey <tom@tromey.com>
9476
9477 * dwarf2/frame.c (dwarf2_frame_bfd_data): New global.
9478 (dwarf2_frame_objfile_data): Add comment.
9479 (find_comp_unit, set_comp_unit): New functions.
9480 (dwarf2_frame_find_fde): Use find_comp_unit.
9481 (dwarf2_build_frame_info): Use set_comp_unit.
9482
9483 2020-02-12 Tom Tromey <tom@tromey.com>
9484
9485 * dwarf2/frame.c (struct comp_unit) <objfile>: Remove.
9486 (comp_unit): Don't initialize objfile.
9487 (execute_cfa_program): Add text_offset parameter.
9488 (execute_cfa_program_test, dwarf2_fetch_cfa_info)
9489 (dwarf2_frame_cache): Update.
9490 (dwarf2_build_frame_info): Don't set "objfile" member.
9491
9492 2020-02-12 Tom Tromey <tom@tromey.com>
9493
9494 * dwarf2/frame.c (decode_frame_entry_1): Add gdbarch parameter.
9495 (decode_frame_entry): Likewise.
9496 (dwarf2_build_frame_info): Update.
9497
9498 2020-02-12 Tom Tromey <tom@tromey.com>
9499
9500 * dwarf2/frame.c (struct comp_unit) <obstack>: New member.
9501 (decode_frame_entry_1): Use the comp_unit obstack.
9502
9503 2020-02-12 Tom Tromey <tom@tromey.com>
9504
9505 * dwarf2/frame.c (struct comp_unit): Add initializers and
9506 constructor.
9507 (dwarf2_frame_objfile_data): Store a comp_unit.
9508 (dwarf2_frame_find_fde): Update.
9509 (dwarf2_build_frame_info): Use "new".
9510
9511 2020-02-12 Tom Tromey <tom@tromey.com>
9512
9513 * dwarf2/frame.c (struct dwarf2_fde_table): Remove.
9514 (dwarf2_fde_table): Typedef for std::vector.
9515 (dwarf2_frame_objfile_data): Remove the deleter. Now static.
9516 (dwarf2_frame_find_fde, add_fde, decode_frame_entry_1)
9517 (decode_frame_entry): Update.
9518 (dwarf2_build_frame_info): Use "new".
9519
9520 2020-02-12 Christian Biesinger <cbiesinger@google.com>
9521
9522 * arm-tdep.c (arm_gdbarch_init): Update.
9523 * arm-tdep.h (struct gdbarch_tdep) <have_fpa_registers,
9524 have_wmmx_registers, have_vfp_pseudos, have_neon_pseudos,
9525 have_neon, is_m>: Change to bool.
9526
9527 2020-02-12 Christian Biesinger <cbiesinger@google.com>
9528
9529 * arm-tdep.c (arm_dump_tdep): Print more fields of tdep.
9530
9531 2020-02-12 Tom Tromey <tom@tromey.com>
9532
9533 * dwarf2/loc.c (struct dwarf_expr_baton): Remove.
9534
9535 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
9536
9537 * windows-tdep.c (struct windows_gdbarch_data): Add tib_ptr_type.
9538 (windows_get_tlb_type): Use windows_gdbarch_data->tib_ptr_type.
9539
9540 2020-02-11 Tom Tromey <tom@tromey.com>
9541
9542 * psymtab.h: Update comment.
9543
9544 2020-02-11 Tom Tromey <tom@tromey.com>
9545
9546 * gdb_obstack.h (struct auto_obstack): Use
9547 DISABLE_COPY_AND_ASSIGN.
9548
9549 2020-02-11 Tom Tromey <tom@tromey.com>
9550
9551 * dwarf2/frame.h (struct objfile): Don't forward declare.
9552
9553 2020-02-11 Christian Biesinger <cbiesinger@google.com>
9554
9555 * cris-tdep.c (cris_supply_gregset): Change signature to match
9556 what struct regset expects.
9557 (cris_regset): New struct.
9558 (fetch_core_registers): Remove.
9559 (cris_iterate_over_regset_sections): New function.
9560 (_initialize_cris_tdep): Don't call deprecated_add_core_fns.
9561 (cris_gdbarch_init): Call set_gdbarch_iterate_over_regset_sections.
9562
9563 2020-02-11 Christian Biesinger <cbiesinger@google.com>
9564
9565 * arch/arm.h (enum gdb_regnum): Add comment for the FP0..7
9566 registers.
9567
9568 2020-02-11 Christian Biesinger <cbiesinger@google.com>
9569
9570 * arm-tdep.c (arm_dump_tdep): Add \n in fprintf.
9571
9572 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
9573
9574 * configure: Re-generate.
9575
9576 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
9577
9578 * configure: Re-generate.
9579
9580 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
9581
9582 * acinclude: Update warning.m4 path.
9583 * warning.m4: Move to gdbsupport.
9584
9585 2020-02-11 Tom Tromey <tromey@adacore.com>
9586
9587 * remote.c (remote_console_output): Update.
9588 * printcmd.c (printf_command): Update.
9589 * event-loop.c (gdb_wait_for_event): Update.
9590 * linux-nat.c (sigchld_handler): Update.
9591 * remote-sim.c (gdb_os_write_stdout): Update.
9592 (gdb_os_flush_stdout): Update.
9593 (gdb_os_flush_stderr): Update.
9594 (gdb_os_write_stderr): Update.
9595 * exceptions.c (print_exception): Update.
9596 * remote-fileio.c (remote_fileio_func_read): Update.
9597 (remote_fileio_func_write): Update.
9598 * tui/tui.c (tui_enable): Update.
9599 * tui/tui-interp.c (tui_interp::init): Update.
9600 * utils.c (init_page_info): Update.
9601 (putchar_unfiltered, fputc_unfiltered): Update.
9602 (gdb_flush): Update.
9603 (emit_style_escape): Update.
9604 (flush_wrap_buffer, fputs_maybe_filtered): Update.
9605 * ui-file.c (ui_file_isatty, ui_file_read, ui_file_write)
9606 (ui_file_write_async_safe, ui_file_flush, ui_file_puts): Remove.
9607 (stderr_file::write): Update.
9608 (stderr_file::puts): Update.
9609 * ui-file.h (ui_file_isatty, ui_file_write)
9610 (ui_file_write_async_safe, ui_file_read, ui_file_flush)
9611 (ui_file_puts): Don't declare.
9612
9613 2020-02-10 Tom de Vries <tdevries@suse.de>
9614
9615 * dwarf2/read.c (process_psymtab_comp_unit_reader): Cast concat NULL
9616 sentinel to char *.
9617
9618 2020-02-09 Tom de Vries <tdevries@suse.de>
9619
9620 * dwarf2read.c (process_psymtab_comp_unit_reader): Append CU offset to
9621 filename if it matches "<artificial>".
9622
9623 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
9624
9625 * windows-tdep.c (struct enum_value_name): New struct.
9626 (create_enum): New function.
9627 (windows_get_siginfo_type): Create and use enum types.
9628
9629 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
9630
9631 * NEWS: Mention $_siginfo support for Windows.
9632 * windows-nat.c (handle_exception): Set siginfo_er.
9633 (windows_nat_target::mourn_inferior): Reset siginfo_er.
9634 (windows_xfer_siginfo): New function.
9635 (windows_nat_target::xfer_partial): Call windows_xfer_siginfo.
9636 * windows-tdep.c (struct windows_gdbarch_data): New struct.
9637 (init_windows_gdbarch_data): New function.
9638 (get_windows_gdbarch_data): New function.
9639 (windows_get_siginfo_type): New function.
9640 (windows_init_abi): Register windows_get_siginfo_type.
9641 (_initialize_windows_tdep): Register init_windows_gdbarch_data.
9642
9643 2020-02-08 Tom Tromey <tom@tromey.com>
9644
9645 * dwarf2/read.c (class cutu_reader) <cutu_reader,
9646 init_tu_and_read_dwo_dies>: Remove "keep" parameter.
9647 <keep>: Declare method.
9648 <m_keep>: Remove member.
9649 <~cutu_reader>: Remove.
9650 (cutu_reader::init_tu_and_read_dwo_dies): Update.
9651 (cutu_reader::cutu_reader): Update.
9652 (cutu_reader::keep): Rename from ~cutu_reader.
9653 (process_psymtab_comp_unit, build_type_psymtabs_1)
9654 (process_skeletonless_type_unit, load_partial_comp_unit)
9655 (load_full_comp_unit, dwarf2_read_addr_index)
9656 (read_signatured_type): Update.
9657
9658 2020-02-08 Tom Tromey <tom@tromey.com>
9659
9660 * dwarf2/read.c (process_psymtab_comp_unit_reader): Remove
9661 "want_partial_unit" parameter.
9662 (process_psymtab_comp_unit): Change want_partial_unit to bool.
9663 Inline check for DW_TAG_partial_unit.
9664 (dwarf2_build_psymtabs_hard, scan_partial_symbols): Update.
9665
9666 2020-02-08 Tom Tromey <tom@tromey.com>
9667
9668 * dwarf2/read.c (read_n_bytes, read_direct_string): Move to
9669 read.c.
9670 * dwarf2/leb.h (read_n_bytes, read_direct_string): Move from
9671 read.c.
9672
9673 2020-02-08 Tom Tromey <tom@tromey.com>
9674
9675 * dwarf2/read.c (read_address): Move to comp-unit.c.
9676 (dwarf2_rnglists_process, dwarf2_ranges_process)
9677 (read_attribute_value, dwarf_decode_lines_1)
9678 (var_decode_location, decode_locdesc): Update.
9679 * dwarf2/comp-unit.c (comp_unit_head::read_address): Move from
9680 read.c. Remove "cu" parameter.
9681 * dwarf2/comp-unit.h (struct comp_unit_head) <read_address>: New
9682 method.
9683
9684 2020-02-08 Tom Tromey <tom@tromey.com>
9685
9686 * dwarf2/read.c (read_attribute_value, read_indirect_string)
9687 (read_indirect_line_string): Update.
9688 * dwarf2/comp-unit.c (read_offset): Remove.
9689 (read_comp_unit_head): Update.
9690 * dwarf2/comp-unit.h (struct comp_unit_head) <read_offset>: New
9691 method.
9692 (read_offset): Don't declare.
9693
9694 2020-02-08 Tom Tromey <tom@tromey.com>
9695
9696 * Makefile.in (COMMON_SFILES): Add dwarf2/comp-unit.c.
9697 * dwarf2/read.c (struct comp_unit_head): Move to
9698 dwarf2/comp-unit.h.
9699 (enum class rcuh_kind): Move to comp-unit.h.
9700 (get_cu_length, offset_in_cu_p): Now methods on comp_unit_head.
9701 (read_comp_unit_head, error_check_comp_unit_head)
9702 (read_and_check_comp_unit_head): Move to comp-unit.c.
9703 (read_offset, dwarf_unit_type_name): Likewise.
9704 (create_debug_type_hash_table, read_cutu_die_from_dwo)
9705 (cutu_reader::cutu_reader, read_call_site_scope)
9706 (find_partial_die, follow_die_offset): Update.
9707 * dwarf2/comp-unit.h: New file, from dwarf2read.c.
9708
9709 2020-02-08 Tom Tromey <tom@tromey.com>
9710
9711 * dwarf2/read.c (read_offset_1): Move to leb.c.
9712 (read_abbrev_offset, read_offset, dwarf_decode_line_header)
9713 (dwarf_decode_macro_bytes): Update.
9714 * dwarf2/leb.c (read_offset): Rename; move from read.c.
9715 * dwarf2/leb.h (read_offset): Declare.
9716
9717 2020-02-08 Tom Tromey <tom@tromey.com>
9718
9719 * dwarf2/read.c (dwarf2_section_size): Remove.
9720 (error_check_comp_unit_head, dwarf2_symbol_mark_computed):
9721 Update.
9722 * dwarf2/section.h (struct dwarf2_section_info) <get_size>: New method.
9723
9724 2020-02-08 Tom Tromey <tom@tromey.com>
9725
9726 * dwarf2/read.c (read_initial_length): Move to leb.c.
9727 * dwarf2/leb.h (read_initial_length): Declare.
9728 * dwarf2/leb.c (read_initial_length): Move from read.c. Add
9729 handle_nonstd parameter.
9730 * dwarf2/frame.c (read_initial_length): Remove.
9731 (decode_frame_entry_1): Update.
9732
9733 2020-02-08 Tom Tromey <tom@tromey.com>
9734
9735 * dwarf2/loc.c (dwarf2_find_location_expression)
9736 (dwarf_evaluate_loc_desc::get_tls_address)
9737 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
9738 (rw_pieced_value, dwarf2_evaluate_loc_desc_full)
9739 (dwarf2_locexpr_baton_eval, dwarf2_evaluate_property)
9740 (dwarf2_compile_property_to_c)
9741 (dwarf2_loc_desc_get_symbol_read_needs)
9742 (dwarf2_compile_expr_to_ax, locexpr_describe_location)
9743 (locexpr_tracepoint_var_ref, locexpr_generate_c_location)
9744 (loclist_describe_location, loclist_tracepoint_var_ref)
9745 (loclist_generate_c_location): Update.
9746 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Update.
9747 * dwarf2/loc.h (dwarf2_per_cu_objfile, dwarf2_per_cu_addr_size)
9748 (dwarf2_per_cu_ref_addr_size, dwarf2_per_cu_offset_size)
9749 (dwarf2_per_cu_text_offset, dwarf2_version): Don't declare.
9750 * dwarf2/read.c (dwarf2_per_cu_data::objfile)
9751 (dwarf2_per_cu_data::addr_size)
9752 (dwarf2_per_cu_data::ref_addr_size)
9753 (dwarf2_per_cu_data::text_offset)
9754 (dwarf2_per_cu_data::addr_type): Now methods.
9755 (per_cu_header_read_in): Make per_cu "const".
9756 (dwarf2_version): Remove.
9757 (dwarf2_per_cu_data::int_type): Now a method.
9758 (dwarf2_per_cu_data::_addr_sized_int_type): Likewise.
9759 (set_die_type, read_array_type, read_subrange_index_type)
9760 (read_tag_string_type, read_subrange_type): Update.
9761 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_size,
9762 offset_size, ref_addr_size, text_offset, addr_type, version,
9763 objfile, int_type, addr_sized_int_type>: Declare methods.
9764
9765 2020-02-08 Tom Tromey <tom@tromey.com>
9766
9767 * dwarf2/read.h (struct dwarf2_per_cu_data) <imported_symtabs>:
9768 Move earlier.
9769
9770 2020-02-08 Tom Tromey <tom@tromey.com>
9771
9772 * dwarf2/read.h (dwarf_line_debug): Declare.
9773 * Makefile.in (COMMON_SFILES): Add dwarf2/line-header.c.
9774 * dwarf2/read.c: Move line_header code to new files.
9775 (dwarf_line_debug): No longer static.
9776 * dwarf2/line-header.c: New file.
9777 * dwarf2/line-header.h: New file.
9778
9779 2020-02-08 Tom Tromey <tom@tromey.com>
9780
9781 * dwarf2/read.c (struct line_header) <file_full_name,
9782 file_file_name>: Return unique_xmalloc_ptr.
9783 (line_header::file_file_name): Update.
9784 (line_header::file_full_name): Update.
9785 (dw2_get_file_names_reader): Update.
9786 (macro_start_file): Update.
9787
9788 2020-02-08 Tom Tromey <tom@tromey.com>
9789
9790 * dwarf2/read.c (struct line_header) <file_full_name,
9791 file_file_name>: Declare methods.
9792 (dw2_get_file_names_reader): Update.
9793 (file_file_name): Now a method.
9794 (file_full_name): Likewise.
9795 (macro_start_file): Update.
9796
9797 2020-02-08 Tom Tromey <tom@tromey.com>
9798
9799 * dwarf2/read.c (dwarf_always_disassemble)
9800 (show_dwarf_always_disassemble): Move to loc.c.
9801 (_initialize_dwarf2_read): Move "always-disassemble" registration
9802 to loc.c.
9803 * dwarf2/read.h (dwarf_always_disassemble): Don't declare.
9804 * dwarf2/loc.c (dwarf_always_disassemble): Move from read.c. Now
9805 static.
9806 (show_dwarf_always_disassemble): Move from read.c.
9807 (_initialize_dwarf2loc): Move always-disassemble from read.c.
9808
9809 2020-02-08 Tom Tromey <tom@tromey.com>
9810
9811 * dwarf2/read.c (~dwarf2_per_objfile): Update.
9812 (create_quick_file_names_table): Return htab_up.
9813 (dw2_get_file_names_reader, dw2_forget_cached_source_info):
9814 Update.
9815 * dwarf2/read.h (struct dwarf2_per_objfile)
9816 <quick_file_names_table>: Now htab_up.
9817
9818 2020-02-08 Tom Tromey <tom@tromey.com>
9819
9820 * dwarf2/abbrev.c (abbrev_table::read): Simplify.
9821
9822 2020-02-08 Tom Tromey <tom@tromey.com>
9823
9824 * dwarf2/abbrev.c (abbrev_table): Move constructor from header.
9825 Rewrite.
9826 (abbrev_table::add_abbrev, abbrev_table::lookup_abbrev): Rewrite.
9827 * dwarf2/abbrev.h (struct abbrev_info) <next>: Remove.
9828 (abbrev_table::abbrev_table): No longer inline.
9829 (ABBREV_HASH_SIZE): Remove.
9830 (abbrev_table::m_abbrevs): Now an htab_up.
9831
9832 2020-02-08 Tom Tromey <tom@tromey.com>
9833
9834 * dwarf2/read.c (read_cutu_die_from_dwo): Update.
9835 (cutu_reader): Update.
9836 (build_type_psymtabs_1): Update.
9837 * dwarf2/abbrev.c (abbrev_table::read): Rename.
9838 (abbrev_table::alloc_abbrev): Update.
9839 * dwarf2/abbrev.h (abbrev_table_up): Move earlier.
9840 (abbrev_table::read): New static method, renamed from
9841 abbrev_table_read_table.
9842 (abbrev_table::alloc_abbrev)
9843 (abbrev_table::add_abbrev): Now private.
9844 (abbrev_table::abbrev_table): Now private.
9845 (abbrev_table::m_abbrev_obstack): Now private. Rename.
9846
9847 2020-02-08 Tom Tromey <tom@tromey.com>
9848
9849 * dwarf2/read.c (set_die_type, get_die_type_at_offset): Update.
9850 * dwarf2/read.h (struct dwarf2_per_objfile) <die_type_hash>: Now
9851 htab_up.
9852
9853 2020-02-08 Tom Tromey <tom@tromey.com>
9854
9855 * dwarf2/read.c (struct dwp_file) <loaded_cus, loaded_tus>: Now
9856 htab_up.
9857 (lookup_dwo_unit_in_dwp): Update.
9858 (allocate_dwp_loaded_cutus_table): Return htab_up. Don't allocate
9859 on obstack.
9860
9861 2020-02-08 Tom Tromey <tom@tromey.com>
9862
9863 * dwarf2/read.c (allocate_dwo_file_hash_table): Don't allocate on
9864 obstack.
9865
9866 2020-02-08 Tom Tromey <tom@tromey.com>
9867
9868 * dwarf2/read.c (~dwarf2_per_objfile): Don't delete
9869 line_header_hash.
9870 (handle_DW_AT_stmt_list): Update. Don't allocate on obstack.
9871 * dwarf2/read.h (struct dwarf2_per_objfile) <line_header_hash>:
9872 Change type to htab_up.
9873
9874 2020-02-08 Tom Tromey <tom@tromey.com>
9875
9876 * dwarf2/read.c (allocate_type_unit_groups_table): Return
9877 htab_up. Don't allocate on obstack.
9878 (get_type_unit_group, dwarf2_build_psymtabs_hard): Update.
9879 * dwarf2/read.h (struct dwarf2_per_objfile) <type_unit_groups>:
9880 Change type to htab_up.
9881
9882 2020-02-08 Tom Tromey <tom@tromey.com>
9883
9884 * dwarf2/read.h (struct dwarf2_per_objfile) <signatured_types>:
9885 Change type to htab_up.
9886 * dwarf2/read.c (create_signatured_type_table_from_index)
9887 (create_signatured_type_table_from_debug_names)
9888 (create_all_type_units, add_type_unit)
9889 (lookup_dwo_signatured_type, lookup_signatured_type)
9890 (process_skeletonless_type_unit): Update.
9891 (create_debug_type_hash_table, create_debug_types_hash_table):
9892 Change type of types_htab.
9893 (allocate_signatured_type_table, allocate_dwo_unit_table): Return
9894 htab_up. Don't allocate on obstack.
9895 (create_cus_hash_table): Change type of cus_htab parameter.
9896 (struct dwo_file) <cus, tus>: Now htab_up.
9897 (lookup_dwo_signatured_type, lookup_dwo_cutu)
9898 (process_dwo_file_for_skeletonless_type_units, lookup_dwo_cutu)
9899 (queue_and_load_all_dwo_tus): Update.
9900 * dwarf2/index-write.c (write_gdbindex): Update.
9901 (write_debug_names): Update.
9902
9903 2020-02-08 Tom Tromey <tom@tromey.com>
9904
9905 * dwarf2/read.h (struct dwarf2_queue_item): Move from
9906 dwarf2/read.c. Remove "next" member. Add constructor ntad
9907 destructor.
9908 (struct dwarf2_per_objfile) <queue>: New member.
9909 * dwarf2/read.c (struct dwarf2_queue_item): Move to
9910 dwarf2/read.h.
9911 (dwarf2_queue, dwarf2_queue_tail): Remove.
9912 (class dwarf2_queue_guard): Add parameter to constructor. Use
9913 DISABLE_COPY_AND_ASSIGN.
9914 <m_per_objfile>: New member.
9915 <~dwarf2_queue_guard>: Rewrite.
9916 (dw2_do_instantiate_symtab, queue_comp_unit, process_queue):
9917 Update.
9918 (~dwarf2_queue_item): New.
9919
9920 2020-02-08 Tom Tromey <tom@tromey.com>
9921
9922 * dwarf2/read.c (struct die_info) <has_children>: New member.
9923 (dw2_get_file_names_reader): Remove has_children.
9924 (dw2_get_file_names): Update.
9925 (read_cutu_die_from_dwo): Remove has_children.
9926 (cutu_reader::init_tu_and_read_dwo_dies)
9927 (cutu_reader::cutu_reader): Update.
9928 (process_psymtab_comp_unit_reader, build_type_psymtabs_reader):
9929 Remove has_children.
9930 (build_type_psymtabs_1, process_skeletonless_type_unit)
9931 (load_partial_comp_unit, load_full_comp_unit): Update.
9932 (create_dwo_cu_reader): Remove has_children.
9933 (create_cus_hash_table, read_die_and_children): Update.
9934 (read_full_die_1,read_full_die): Remove has_children.
9935 (read_signatured_type): Update.
9936 (class cutu_reader) <has_children>: Remove.
9937
9938 2020-02-08 Tom Tromey <tom@tromey.com>
9939
9940 * dwarf2/expr.c: Rename from dwarf2expr.c.
9941 * dwarf2/expr.h: Rename from dwarf2expr.h.
9942 * dwarf2/frame-tailcall.c: Rename from dwarf2-frame-tailcall.c.
9943 * dwarf2/frame-tailcall.h: Rename from dwarf2-frame-tailcall.h.
9944 * dwarf2/frame.c: Rename from dwarf2-frame.c.
9945 * dwarf2/frame.h: Rename from dwarf2-frame.h.
9946 * dwarf2/index-cache.c: Rename from dwarf-index-cache.c.
9947 * dwarf2/index-cache.h: Rename from dwarf-index-cache.h.
9948 * dwarf2/index-common.c: Rename from dwarf-index-common.c.
9949 * dwarf2/index-common.h: Rename from dwarf-index-common.h.
9950 * dwarf2/index-write.c: Rename from dwarf-index-write.c.
9951 * dwarf2/index-write.h: Rename from dwarf-index-write.h.
9952 * dwarf2/loc.c: Rename from dwarf2loc.c.
9953 * dwarf2/loc.h: Rename from dwarf2loc.h.
9954 * dwarf2/read.c: Rename from dwarf2read.c.
9955 * dwarf2/read.h: Rename from dwarf2read.h.
9956 * dwarf2/abbrev.c, aarch64-tdep.c, alpha-tdep.c,
9957 amd64-darwin-tdep.c, arc-tdep.c, arm-tdep.c, bfin-tdep.c,
9958 compile/compile-c-symbols.c, compile/compile-cplus-symbols.c,
9959 compile/compile-loc2c.c, cris-tdep.c, csky-tdep.c, findvar.c,
9960 gdbtypes.c, guile/scm-type.c, h8300-tdep.c, hppa-bsd-tdep.c,
9961 hppa-linux-tdep.c, i386-darwin-tdep.c, i386-linux-tdep.c,
9962 i386-tdep.c, iq2000-tdep.c, m32c-tdep.c, m68hc11-tdep.c,
9963 m68k-tdep.c, microblaze-tdep.c, mips-tdep.c, mn10300-tdep.c,
9964 msp430-tdep.c, nds32-tdep.c, nios2-tdep.c, or1k-tdep.c,
9965 riscv-tdep.c, rl78-tdep.c, rs6000-tdep.c, rx-tdep.c, s12z-tdep.c,
9966 s390-tdep.c, score-tdep.c, sh-tdep.c, sparc-linux-tdep.c,
9967 sparc-tdep.c, sparc64-linux-tdep.c, sparc64-tdep.c, tic6x-tdep.c,
9968 tilegx-tdep.c, v850-tdep.c, xstormy16-tdep.c, xtensa-tdep.c:
9969 Update.
9970 * Makefile.in (COMMON_SFILES): Update.
9971 (HFILES_NO_SRCDIR): Update.
9972
9973 2020-02-08 Tom Tromey <tom@tromey.com>
9974
9975 * dwarf2read.c (struct die_reader_specs) <comp_dir>: Remove.
9976 (init_cu_die_reader, read_cutu_die_from_dwo): Update.
9977
9978 2020-02-08 Tom Tromey <tom@tromey.com>
9979
9980 * dwarf2read.h (struct die_info): Don't declare.
9981
9982 2020-02-08 Tom Tromey <tom@tromey.com>
9983
9984 * dwarf2read.h (die_info_ptr): Remove typedef.
9985
9986 2020-02-08 Tom Tromey <tom@tromey.com>
9987
9988 * dwarf2read.c (read_call_site_scope)
9989 (handle_data_member_location, dwarf2_add_member_fn)
9990 (mark_common_block_symbol_computed, read_common_block)
9991 (attr_to_dynamic_prop, partial_die_info::read)
9992 (var_decode_location, dwarf2_fetch_die_loc_sect_off)
9993 (dwarf2_symbol_mark_computed, set_die_type): Update.
9994 * dwarf2/attribute.h (struct attribute) <form_is_block>: Declare
9995 method.
9996 (attr_form_is_block): Don't declare.
9997 * dwarf2/attribute.c (attribute::form_is_block): Now a method.
9998
9999 2020-02-08 Tom Tromey <tom@tromey.com>
10000
10001 * dwarf2read.c (dwarf2_find_base_address, )
10002 (read_call_site_scope, rust_containing_type)
10003 (dwarf2_get_pc_bounds, dwarf2_record_block_ranges)
10004 (handle_data_member_location, dwarf2_add_member_fn)
10005 (get_alignment, read_structure_type, process_structure_scope)
10006 (mark_common_block_symbol_computed, read_common_block)
10007 (read_tag_string_type, attr_to_dynamic_prop, read_subrange_type)
10008 (partial_die_info::read, read_attribute_value, new_symbol)
10009 (lookup_die_type, dwarf2_get_ref_die_offset)
10010 (dwarf2_get_attr_constant_value, follow_die_ref_or_sig)
10011 (dwarf2_fetch_die_loc_sect_off, get_DW_AT_signature_type)
10012 (dwarf2_symbol_mark_computed): Update.
10013 * dwarf2/attribute.h (struct attribute) <value_as_address,
10014 form_is_section_offset, form_is_constant, form_is_ref>: Declare
10015 methods.
10016 (value_as_address, attr_form_is_section_offset)
10017 (attr_form_is_constant, attr_form_is_ref): Don't declare.
10018 * dwarf2/attribute.c (attribute::value_as_address)
10019 (attribute::form_is_section_offset, attribute::form_is_constant)
10020 (attribute::form_is_ref): Now methods.
10021
10022 2020-02-08 Tom Tromey <tom@tromey.com>
10023
10024 * dwarf2read.c (struct attribute, DW_STRING)
10025 (DW_STRING_IS_CANONICAL, DW_UNSND, DW_BLOCK, DW_SND, DW_ADDR)
10026 (DW_SIGNATURE, struct dwarf_block, attr_value_as_address)
10027 (attr_form_is_block, attr_form_is_section_offset)
10028 (attr_form_is_constant, attr_form_is_ref): Move.
10029 * dwarf2/attribute.h: New file.
10030 * dwarf2/attribute.c: New file, from dwarf2read.c.
10031 * Makefile.in (COMMON_SFILES): Add dwarf2/attribute.c.
10032
10033 2020-02-08 Tom Tromey <tom@tromey.com>
10034
10035 * dwarf2read.c (abbrev_table_up, struct abbrev_info)
10036 (struct attr_abbrev, ABBREV_HASH_SIZE, struct abbrev_table):
10037 Move.
10038 (read_cutu_die_from_dwo, build_type_psymtabs_1): Update.
10039 (abbrev_table::alloc_abbrev, abbrev_table::add_abbrev)
10040 (abbrev_table::lookup_abbrev, abbrev_table_read_table): Move to
10041 abbrev.c.
10042 * dwarf2/abbrev.h: New file.
10043 * dwarf2/abbrev.c: New file, from dwarf2read.c.
10044 * Makefile.in (COMMON_SFILES): Add dwarf2/abbrev.c.
10045
10046 2020-02-08 Tom Tromey <tom@tromey.com>
10047
10048 * dwarf2read.c (dwarf2_section_buffer_overflow_complaint)
10049 (dwarf2_section_size, dwarf2_get_section_info)
10050 (create_signatured_type_table_from_debug_names)
10051 (create_addrmap_from_aranges, read_debug_names_from_section)
10052 (get_gdb_index_contents_from_section, read_comp_unit_head)
10053 (error_check_comp_unit_head, read_abbrev_offset)
10054 (create_debug_type_hash_table, init_cu_die_reader)
10055 (read_cutu_die_from_dwo, dwarf2_build_psymtabs_hard)
10056 (read_comp_units_from_section, create_cus_hash_table)
10057 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
10058 (create_dwp_v2_section, dwarf2_rnglists_process)
10059 (dwarf2_ranges_process, read_die_and_siblings, read_full_die)
10060 (abbrev_table_read_table, read_indirect_string_at_offset_from)
10061 (read_indirect_string_from_dwz, read_addr_index_1)
10062 (read_str_index, dwarf_decode_line_header, skip_form_bytes)
10063 (dwarf_decode_macro_bytes, dwarf_decode_macros)
10064 (fill_in_loclist_baton): Update.
10065 * dwarf2/section.h (struct dwarf2_section_info) <get_name,
10066 get_containing_section, get_bfd_owner, get_bfd_section,
10067 get_file_name, get_id, get_flags, empty, read>: Declare methods.
10068 (dwarf2_read_section, get_section_name, get_section_file_name)
10069 (get_containing_section, get_section_bfd_owner)
10070 (get_section_bfd_section, get_section_name, get_section_file_name)
10071 (get_section_id, get_section_flags, dwarf2_section_empty_p): Don't
10072 declare.
10073 * dwarf2/section.c (dwarf2_section_info::get_containing_section)
10074 (dwarf2_section_info::get_bfd_owner)
10075 (dwarf2_section_info::get_bfd_section)
10076 (dwarf2_section_info::get_name)
10077 (dwarf2_section_info::get_file_name, dwarf2_section_info::get_id)
10078 (dwarf2_section_info::get_flags, dwarf2_section_info::empty)
10079 (dwarf2_section_info::read): Now methods.
10080 * dwarf-index-write.c (class debug_names): Update.
10081
10082 2020-02-08 Tom Tromey <tom@tromey.com>
10083
10084 * dwarf2read.h (struct dwarf2_section_info, dwarf2_read_section):
10085 Move to dwarf2/section.h.
10086 * dwarf2read.c (get_containing_section, get_section_bfd_owner)
10087 (get_section_bfd_section, get_section_name)
10088 (get_section_file_name, get_section_id, get_section_flags)
10089 (dwarf2_section_empty_p, dwarf2_read_section): Moe to
10090 dwarf2/section.c.
10091 * dwarf2/section.h: New file.
10092 * dwarf2/section.c: New file, from dwarf2read.c.
10093 * Makefile.in (COMMON_SFILES): Add dwarf2/section.c.
10094
10095 2020-02-08 Tom Tromey <tom@tromey.com>
10096
10097 * dwarf2read.h (read_unsigned_leb128): Don't declare.
10098 * dwarf2read.c (read_1_byte, read_1_signed_byte, read_2_bytes)
10099 (read_2_signed_bytes, read_3_bytes, read_4_bytes)
10100 (read_4_signed_bytes, read_8_bytes): Move to dwarf2/leb.h.
10101 (read_unsigned_leb128, read_signed_leb128): Move to dwarf2/leb.c.
10102 * dwarf2/leb.h: New file, from dwarf2read.c.
10103 * dwarf2/leb.c: New file, from dwarf2read.c.
10104 * dwarf2-frame.c (read_1_byte, read_4_bytes, read_8_bytes):
10105 Remove.
10106 * Makefile.in (CONFIG_SRC_SUBDIR): Add dwarf2.
10107 (COMMON_SFILES): Add dwarf2/leb.c.
10108
10109 2020-02-08 Joel Brobecker <brobecker@adacore.com>
10110
10111 GDB 9.1 released.
10112
10113 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
10114
10115 PR gdb/25190:
10116 * gdb/remote-sim.c (gdb_os_write_stderr): Update.
10117 * gdb/remote.c (remote_console_output): Update.
10118 * gdb/ui-file.c (fputs_unfiltered): Rename to...
10119 (ui_file_puts): ...this.
10120 * gdb/ui-file.h (ui_file_puts): Add declaration.
10121 * gdb/utils.c (emit_style_escape): Update.
10122 (flush_wrap_buffer): Update.
10123 (fputs_maybe_filtered): Update.
10124 (fputs_unfiltered): Add function.
10125
10126 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
10127
10128 * gdb/event-loop.c (gdb_wait_for_event): Update.
10129 * gdb/printcmd.c (printf_command): Update.
10130 * gdb/remote-fileio.c (remote_fileio_func_write): Update.
10131 * gdb/remote-sim.c (gdb_os_flush_stdout): Update.
10132 (gdb_os_flush_stderr): Update.
10133 * gdb/remote.c (remote_console_output): Update.
10134 * gdb/ui-file.c (gdb_flush): Rename to...
10135 (ui_file_flush): ...this.
10136 (stderr_file::write): Update.
10137 (stderr_file::puts): Update.
10138 * gdb/ui-file.h (gdb_flush): Rename to...
10139 (ui_file_flush): ...this.
10140 * gdb/utils.c (gdb_flush): Add function.
10141 * gdb/utils.h (gdb_flush): Add declaration.
10142
10143 2020-02-07 Tom Tromey <tromey@adacore.com>
10144
10145 PR breakpoints/24915:
10146 * source.c (find_and_open_source): Do not check basenames_may_differ.
10147
10148 2020-02-07 Tom Tromey <tom@tromey.com>
10149
10150 * README: Update gdbserver documentation.
10151 * gdbserver: Move to top level.
10152 * configure.tgt (build_gdbserver): Remove.
10153 * configure.ac: Remove --enable-gdbserver.
10154 * configure: Rebuild.
10155 * Makefile.in (distclean): Don't mention gdbserver.
10156
10157 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
10158
10159 * source-cache.c (source_cache::ensure): Surround
10160 get_plain_source_lines with a try/catch.
10161 (source_cache::get_line_charpos): Get rid of try/catch
10162 and only check for the return value of "ensure".
10163 * tui/tui-source.c (tui_source_window::set_contents):
10164 Simplify "nlines" calculation.
10165
10166 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
10167
10168 * MAINTAINERS (Write After Approval): Add myself.
10169
10170 2020-02-05 Christian Biesinger <cbiesinger@google.com>
10171
10172 * sparc-nat.h (struct sparc_target) <xfer_partial>: Fix base class
10173 function call.
10174
10175 2020-02-05 Christian Biesinger <cbiesinger@google.com>
10176
10177 * ppc-nbsd-tdep.h: Fix macro name in #endif comment.
10178
10179 2020-02-05 Maciej W. Rozycki <macro@wdc.com>
10180
10181 * nat/riscv-linux-tdesc.h: New file.
10182 * nat/riscv-linux-tdesc.c: New file, taking code from...
10183 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
10184 ... here.
10185 * configure.nat <linux> <riscv*>: Add nat/riscv-linux-tdesc.o to
10186 NATDEPFILES.
10187
10188 2020-02-04 Andrew Burgess <andrew.burgess@embecosm.com>
10189
10190 * remote-sim.c (sim_inferior_data::sim_inferior_data): Assert that
10191 we don't set the fake simulator ptid to the null_ptid.
10192
10193 2020-02-03 Simon Marchi <simon.marchi@efficios.com>
10194
10195 * fork-child.c (gdb_startup_inferior): Use bool instead of int.
10196 * gdbthread.h (class thread_info) <resumed>: Likewise.
10197 * infrun.c (resume_1): Likewise.
10198 (proceed): Likewise.
10199 (infrun_thread_stop_requested): Likewise.
10200 (stop_all_threads): Likewise.
10201 (handle_inferior_event): Likewise.
10202 (restart_threads): Likewise.
10203 (finish_step_over): Likewise.
10204 (keep_going_stepped_thread): Likewise.
10205 * linux-nat.c (attach_proc_task_lwp_callback): Likewise.
10206 (linux_handle_extended_wait): Likewise.
10207 * record-btrace.c (get_thread_current_frame_id): Likewise.
10208 * record-full.c (record_full_wait_1): Likewise.
10209 * remote.c (remote_target::process_initial_stop_replies): Likewise.
10210 * target.c (target_resume): Likewise.
10211 * thread.c (set_running_thread): Likewise.
10212
10213 2020-02-03 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
10214
10215 * f-valprint.c (f77_print_array_1): Changed datatype of index
10216 variable to LONGEST from int to enable it to contain bound
10217 values correctly.
10218
10219 2020-02-03 Maciej W. Rozycki <macro@wdc.com>
10220
10221 * riscv-linux-nat.c [!NFPREG] (NFPREG): New macro.
10222 (supply_fpregset_regnum, fill_fpregset): Handle regset buffer
10223 offsets according to FLEN determined.
10224 (riscv_linux_nat_target::read_description): Determine FLEN
10225 dynamically.
10226 (riscv_linux_nat_target::fetch_registers): Size regset buffer
10227 according to FLEN determined.
10228 (riscv_linux_nat_target::store_registers): Likewise.
10229
10230 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
10231
10232 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
10233 when reg->group is empty and reggroup is not.
10234
10235 2020-01-31 Tom Tromey <tromey@adacore.com>
10236
10237 * ravenscar-thread.c (ravenscar_thread_target::mourn_inferior):
10238 Call beneath target's mourn_inferior after unpushing.
10239
10240 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
10241
10242 PR tui/9765
10243 * tui/tui-disasm.c (tui_find_disassembly_address): If we don't
10244 have enough lines to fill the screen, still return the lowest
10245 address we found.
10246
10247 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
10248
10249 * tui/tui-win.c (_initialize_tui_win): Update help text for '+',
10250 '-', '<', and '>' commands.
10251
10252 2020-01-29 Pedro Alves <palves@redhat.com>
10253 Sergio Durigan Junior <sergiodj@redhat.com>
10254
10255 * infcmd.c (construct_inferior_arguments): Assert that
10256 'argc' is greater than 0.
10257
10258 2020-01-29 Luis Machado <luis.machado@linaro.org>
10259
10260 * aarch64-tdep.c (BRK_INSN_MASK): Define to 0xffe0001f.
10261 (BRK_INSN_MASK): Define to 0xd4200000.
10262 (aarch64_program_breakpoint_here_p): New function.
10263 (aarch64_gdbarch_init): Set gdbarch_program_breakpoint_here_p hook.
10264 * arch-utils.c (default_program_breakpoint_here_p): Moved from
10265 breakpoint.c.
10266 * arch-utils.h (default_program_breakpoint_here_p): Moved from
10267 breakpoint.h
10268 * breakpoint.c (bp_loc_is_permanent): Changed return type to bool and
10269 call gdbarch_program_breakpoint_here_p.
10270 (program_breakpoint_here): Moved to arch-utils.c, renamed to
10271 default_program_breakpoint_here_p, changed return type to bool and
10272 simplified.
10273 * breakpoint.h (program_breakpoint_here): Moved prototype to
10274 arch-utils.h, renamed to default_program_breakpoint_here_p and changed
10275 return type to bool.
10276 * gdbarch.c: Regenerate.
10277 * gdbarch.h: Regenerate.
10278 * gdbarch.sh (program_breakpoint_here_p): New method.
10279 * infrun.c (handle_signal_stop): Call
10280 gdbarch_program_breakpoint_here_p.
10281
10282 2020-01-26 Tom Tromey <tom@tromey.com>
10283
10284 * ctfread.c (struct ctf_fp_info): Reindent.
10285 (_initialize_ctfread): Remove.
10286
10287 2020-01-26 Tom Tromey <tom@tromey.com>
10288
10289 * psymtab.c (partial_map_expand_apply)
10290 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
10291 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
10292 (psym_print_stats, psym_expand_symtabs_for_function)
10293 (psym_map_symbol_filenames, psym_map_matching_symbols)
10294 (psym_expand_symtabs_matching)
10295 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
10296 (maintenance_check_psymtabs): Use new methods.
10297 * psympriv.h (struct partial_symtab) <readin_p,
10298 get_compunit_symtab>: New methods.
10299 <readin, compunit_symtab>: Remove members.
10300 (struct standard_psymtab): New.
10301 (struct legacy_psymtab): Derive from standard_psymtab.
10302 * dwarf2read.h (struct dwarf2_psymtab): Derive from
10303 standard_psymtab.
10304 * ctfread.c (struct ctf_psymtab): Derive from standard_psymtab.
10305
10306 2020-01-26 Tom Tromey <tom@tromey.com>
10307
10308 * xcoffread.c (xcoff_psymtab_to_symtab_1): Call
10309 read_dependencies. Add assert.
10310 * psymtab.c (partial_symtab::read_dependencies): New method.
10311 * psympriv.h (struct partial_symtab) <read_dependencies>: New
10312 method.
10313 * mdebugread.c (psymtab_to_symtab_1): Call read_dependencies.
10314 * dwarf2read.c (dwarf2_psymtab::expand_psymtab): Call
10315 read_dependencies.
10316 * dbxread.c (dbx_psymtab_to_symtab_1): Call read_dependencies.
10317 Add assert.
10318
10319 2020-01-26 Tom Tromey <tom@tromey.com>
10320
10321 * xcoffread.c (xcoff_psymtab_to_symtab_1): Change argument order.
10322 Call expand_psymtab.
10323 (xcoff_read_symtab): Call expand_psymtab.
10324 (xcoff_start_psymtab, xcoff_end_psymtab): Set
10325 legacy_expand_psymtab.
10326 * psympriv.h (struct partial_symtab) <expand_psymtab>: New
10327 method.
10328 (struct legacy_psymtab) <expand_psymtab>: Implement.
10329 <legacy_expand_psymtab>: New member.
10330 * mdebugread.c (mdebug_read_symtab): Call expand_psymtab.
10331 (parse_partial_symbols): Set legacy_expand_psymtab.
10332 (psymtab_to_symtab_1): Change argument order. Call
10333 expand_psymtab.
10334 (new_psymtab): Set legacy_expand_psymtab.
10335 * dwarf2read.h (struct dwarf2_psymtab) <expand_psymtab>: Declare.
10336 * dwarf2read.c (dwarf2_psymtab::read_symtab): Call
10337 expand_psymtab.
10338 (dwarf2_psymtab::expand_psymtab): Rename from
10339 psymtab_to_symtab_1. Call expand_psymtab.
10340 * dbxread.c (start_psymtab): Set legacy_expand_psymtab.
10341 (dbx_end_psymtab): Likewise.
10342 (dbx_psymtab_to_symtab_1): Change argument order. Call
10343 expand_psymtab.
10344 (dbx_read_symtab): Call expand_psymtab.
10345 * ctfread.c (struct ctf_psymtab) <expand_psymtab>: Declare.
10346 (ctf_psymtab::expand_psymtab): Rename from psymtab_to_symtab.
10347 (ctf_psymtab::read_symtab): Call expand_psymtab.
10348
10349 2020-01-26 Tom Tromey <tom@tromey.com>
10350
10351 * xcoffread.c (xcoff_read_symtab): Remove prints. Add assert.
10352 * psymtab.c (psymtab_to_symtab): Print verbose "Reading"
10353 messages.
10354 * mdebugread.c (mdebug_read_symtab): Remove prints.
10355 * dwarf2read.c (dwarf2_psymtab::read_symtab): Remove prints. Add
10356 assert.
10357 * dbxread.c (dbx_read_symtab): Remove prints. Add assert.
10358
10359 2020-01-26 Tom Tromey <tom@tromey.com>
10360
10361 * xcoffread.c (this_symtab_psymtab, read_xcoff_symtab)
10362 (xcoff_psymtab_to_symtab_1, xcoff_read_symtab)
10363 (xcoff_start_psymtab, xcoff_end_psymtab, scan_xcoff_symtab): Use
10364 legacy_symtab.
10365 * stabsread.h (dbx_end_psymtab): Use legacy_symtab.
10366 * psymtab.c (psymtab_to_symtab): Call method.
10367 (dump_psymtab): Update.
10368 * psympriv.h (struct partial_symtab): Add virtual destructor.
10369 <read_symtab>: New method.
10370 (struct legacy_symtab): New.
10371 * mdebugread.c (mdebug_read_symtab): Use legacy_psymtab.
10372 (struct pst_map) <pst>: Now a legacy_psymtab.
10373 (parse_procedure, parse_partial_symbols, psymtab_to_symtab_1)
10374 (new_psymtab): Use legacy_psymtab.
10375 * dwarf2read.h (struct dwarf2_psymtab): New.
10376 (struct dwarf2_per_cu_data) <psymtab>: Use it.
10377 * dwarf2read.c (dwarf2_create_include_psymtab)
10378 (dwarf2_build_include_psymtabs, create_type_unit_group)
10379 (create_partial_symtab, process_psymtab_comp_unit_reader)
10380 (build_type_psymtabs_reader, build_type_psymtab_dependencies)
10381 (set_partial_user): Use dwarf2_psymtab.
10382 (dwarf2_psymtab::read_symtab): Rename from dwarf2_read_symtab.
10383 (psymtab_to_symtab_1, process_full_comp_unit)
10384 (process_full_type_unit, dwarf2_ranges_read)
10385 (dwarf2_get_pc_bounds, psymtab_include_file_name)
10386 (dwarf_decode_lines): Use dwarf2_psymtab.
10387 * dwarf-index-write.c (psym_index_map): Use dwarf2_psymtab.
10388 (add_address_entry_worker, write_one_signatured_type)
10389 (recursively_count_psymbols, recursively_write_psymbols)
10390 (write_one_signatured_type, psyms_seen_size, write_gdbindex)
10391 (write_debug_names): Likewise.
10392 * dbxread.c (struct header_file_location): Take a legacy_psymtab.
10393 <pst>: Now a legacy_psymtab.
10394 (find_corresponding_bincl_psymtab): Return a legacy_psymtab.
10395 (read_dbx_symtab, start_psymtab, dbx_end_psymtab)
10396 (dbx_psymtab_to_symtab_1, read_ofile_symtab): Use legacy_psymtab.
10397 * ctfread.c (struct ctf_psymtab): New.
10398 (ctf_start_symtab, ctf_end_symtab, psymtab_to_symtab): Take a
10399 ctf_psymtab.
10400 (ctf_psymtab::read_symtab): Rename from ctf_read_symtab.
10401 (create_partial_symtab): Return a ctf_psymtab.
10402 (scan_partial_symbols): Update.
10403
10404 2020-01-26 Tom Tromey <tom@tromey.com>
10405
10406 * xcoffread.c (xcoff_start_psymtab): Use new.
10407 * psymtab.c (partial_symtab::partial_symtab): New constructor,
10408 renamed from start_psymtab_common.
10409 * psympriv.h (struct partial_symtab): Add new constructor.
10410 (start_psymtab_common): Don't declare.
10411 * mdebugread.c (parse_partial_symbols): Use new.
10412 * dwarf2read.c (create_partial_symtab): Use new.
10413 * dbxread.c (start_psymtab): Use new.
10414 * ctfread.c (create_partial_symtab): Use new.
10415
10416 2020-01-26 Tom Tromey <tom@tromey.com>
10417
10418 * xcoffread.c (xcoff_end_psymtab): Use new.
10419 * psymtab.c (start_psymtab_common): Use new.
10420 (partial_symtab::partial_symtab): Rename from allocate_psymtab.
10421 Update.
10422 * psympriv.h (struct partial_symtab): Add parameters to
10423 constructor. Don't inline.
10424 (allocate_psymtab): Don't declare.
10425 * mdebugread.c (new_psymtab): Use new.
10426 * dwarf2read.c (dwarf2_create_include_psymtab): Use new.
10427 * dbxread.c (dbx_end_psymtab): Use new.
10428
10429 2020-01-26 Tom Tromey <tom@tromey.com>
10430
10431 * psymtab.h (class psymtab_storage) <install_psymtab>: Rename from
10432 allocate_psymtab. Update documentation.
10433 * psymtab.c (psymtab_storage::install_psymtab): Rename from
10434 allocate_psymtab. Do not use new.
10435 (allocate_psymtab): Use new. Update.
10436
10437 2020-01-26 Tom Tromey <tom@tromey.com>
10438
10439 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
10440 * psymtab.c (psym_print_stats): Update.
10441 * psympriv.h (struct partial_symtab) <readin,
10442 psymtabs_addrmap_supported, anonymous>: Now bool.
10443 * mdebugread.c (psymtab_to_symtab_1): Update.
10444 * dwarf2read.c (create_type_unit_group, create_partial_symtab)
10445 (build_type_psymtabs_reader, psymtab_to_symtab_1)
10446 (process_full_comp_unit, process_full_type_unit): Update.
10447 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
10448 * ctfread.c (psymtab_to_symtab): Update.
10449
10450 2020-01-26 Tom Tromey <tom@tromey.com>
10451
10452 * mdebugread.c (parse_partial_symbols): Use discard_psymtab.
10453 * psymtab.h (class psymtab_storage) <free_psymtabs>: Remove.
10454 * psymtab.c (psymtab_storage): Delete psymtabs.
10455 (psymtab_storage::allocate_psymtab): Use new.
10456 (psymtab_storage::discard_psymtab): Use delete.
10457 * psympriv.h (struct partial_symtab): Add constructor and
10458 initializers.
10459
10460 2020-01-26 Tom Tromey <tom@tromey.com>
10461
10462 * machoread.c: Do not include psympriv.h.
10463
10464 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10465
10466 * NEWS: Mention the new option and the set/show commands.
10467
10468 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10469
10470 * exec.c (exec_file_mismatch_names, exec_file_mismatch_mode)
10471 (show_exec_file_mismatch_command, set_exec_file_mismatch_command)
10472 (validate_exec_file): New variables, enums, functions.
10473 (exec_file_locate_attach, print_section_info): Style the filenames.
10474 (_initialize_exec): Install show_exec_file_mismatch_command and
10475 set_exec_file_mismatch_command.
10476 * gdbcore.h (validate_exec_file): Declare.
10477 * infcmd.c (attach_command): Call validate_exec_file.
10478 * remote.c ( remote_target::remote_add_inferior): Likewise.
10479
10480 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
10481
10482 * frame.c (find_frame_sal): Move call to get_next_frame into more
10483 inner scope.
10484 * inline-frame.c (inilne_state) <inline_state>: Update argument
10485 types.
10486 (inilne_state) <skipped_symbol>: Rename to...
10487 (inilne_state) <skipped_symbols>: ...this, and change to a vector.
10488 (skip_inline_frames): Build vector of skipped symbols and use this
10489 to reate the inline_state.
10490 (inline_skipped_symbol): Add a comment and some assertions, fetch
10491 skipped symbol from the list.
10492
10493 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
10494
10495 * buildsym.c (lte_is_less_than): Delete.
10496 (buildsym_compunit::end_symtab_with_blockvector): Create local
10497 lambda function to sort line table entries, and use
10498 std::stable_sort instead of std::sort.
10499 * symtab.c (find_pc_sect_line): Skip backward over end of sequence
10500 markers when looking for a previous line.
10501
10502 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
10503
10504 * dwarf2read.c (lnp_state_machine::record_line): Include
10505 end_sequence parameter in debug print out. Record the line if we
10506 are at an end_sequence marker even if it's not the start of a
10507 statement.
10508 * symmisc.c (maintenance_print_one_line_table): Print end of
10509 sequence markers with 'END' not '0'.
10510
10511 2020-01-24 Pedro Alves <palves@redhat.com>
10512
10513 PR gdb/25410
10514 * thread.c (scoped_restore_current_thread::restore): Use
10515 switch_to_inferior_no_thread.
10516 * exec.c: Include "progspace-and-thread.h".
10517 (add_target_sections, remove_target_sections):
10518 scoped_restore_current_pspace_and_thread instead of
10519 scoped_restore_current_thread.
10520 * infrun.c (handle_vfork_child_exec_or_exit): Assign the pspace
10521 and aspace to the inferior before calling clone_program_space.
10522 Remove stale comment.
10523
10524 2020-01-24 Christian Biesinger <cbiesinger@google.com>
10525
10526 * arm-nbsd-nat.c (arm_nbsd_nat_target::fetch_registers): Rename to...
10527 (arm_netbsd_nat_target::fetch_registers): ...this.
10528 (arm_nbsd_nat_target::store_registers): Rename to...
10529 (arm_netbsd_nat_target::store_registers): ...this.
10530
10531 2020-01-24 Christian Biesinger <cbiesinger@google.com>
10532
10533 * arm-nbsd-nat.c: Define _KERNTYPES to get the declaration of
10534 register_t.
10535
10536 2020-01-24 Christian Biesinger <cbiesinger@google.com>
10537
10538 * aarch64-fbsd-tdep.c (aarch64_fbsd_iterate_over_regset_sections):
10539 Update comment.
10540 * aarch64-linux-tdep.c (aarch64_linux_iterate_over_regset_sections):
10541 Likewise.
10542 * arm-fbsd-tdep.c (arm_fbsd_iterate_over_regset_sections): Likewise.
10543 * gdbcore.h (deprecated_add_core_fns): Update comment to point to
10544 the correct replacement (iterate_over_regset_sections).
10545 * riscv-fbsd-tdep.c (riscv_fbsd_iterate_over_regset_sections):
10546 Update comment.
10547
10548 2020-01-24 Graham Markall <graham.markall@embecosm.com>
10549
10550 PR gdb/23718
10551 * gdb/python/python.c (execute_gdb_command): Call
10552 async_enable_stdin in catch block.
10553
10554 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
10555
10556 * event-loop.c (start_event_loop): Wrap async_enable_stdin with
10557 SWITCH_THRU_ALL_UIS.
10558
10559 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
10560
10561 PR tui/9765
10562 * minsyms.c (lookup_minimal_symbol_by_pc_section): Update header
10563 comment, add extra parameter, and update to store previous symbol
10564 when appropriate.
10565 * minsyms.h (lookup_minimal_symbol_by_pc_section): Update comment,
10566 add extra parameter.
10567 * tui/tui-disasm.c (tui_disassemble): Update header comment,
10568 remove unneeded parameter, add try/catch around gdb_print_insn,
10569 rewrite to add items to asm_lines vector.
10570 (tui_find_backward_disassembly_start_address): New function.
10571 (tui_find_disassembly_address): Updated throughout.
10572 (tui_disasm_window::set_contents): Update for changes to
10573 tui_disassemble.
10574 (tui_disasm_window::do_scroll_vertical): No need to adjust the
10575 number of lines to scroll.
10576
10577 2020-01-23 Simon Marchi <simon.marchi@polymtl.ca>
10578
10579 * objfiles.h (ALL_OBJFILE_OSECTIONS): Move up.
10580 (SECT_OFF_DATA): Likewise.
10581 (SECT_OFF_RODATA): Likewise.
10582 (SECT_OFF_TEXT): Likewise.
10583 (SECT_OFF_BSS): Likewise.
10584 (struct objfile) <text_section_offset, data_section_offset>: New
10585 methods.
10586 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Use
10587 objfile::text_section_offset.
10588 * coff-pe-read.c (add_pe_forwarded_sym): Likewise.
10589 * coffread.c (coff_symtab_read): Likewise.
10590 (enter_linenos): Likewise.
10591 (process_coff_symbol): Likewise.
10592 * ctfread.c (get_objfile_text_range): Likewise.
10593 * dtrace-probe.c (dtrace_probe::get_relocated_address):
10594 Use objfile::data_section_offset.
10595 * dwarf2-frame.c (execute_cfa_program): Use
10596 objfile::text_section_offset.
10597 (dwarf2_frame_find_fde): Likewise.
10598 * dwarf2read.c (create_addrmap_from_index): Likewise.
10599 (create_addrmap_from_aranges): Likewise.
10600 (dw2_find_pc_sect_compunit_symtab): Likewise.
10601 (process_psymtab_comp_unit_reader): Likewise.
10602 (add_partial_symbol): Likewise.
10603 (add_partial_subprogram): Likewise.
10604 (process_full_comp_unit): Likewise.
10605 (read_file_scope): Likewise.
10606 (read_func_scope): Likewise.
10607 (read_lexical_block_scope): Likewise.
10608 (read_call_site_scope): Likewise.
10609 (dwarf2_rnglists_process): Likewise.
10610 (dwarf2_ranges_process): Likewise.
10611 (dwarf2_ranges_read): Likewise.
10612 (dwarf_decode_lines_1): Likewise.
10613 (new_symbol): Likewise.
10614 (dwarf2_fetch_die_loc_sect_off): Likewise.
10615 (dwarf2_per_cu_text_offset): Likewise.
10616 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Likewise.
10617 * hppa-tdep.c (read_unwind_info): Likewise.
10618 * ia64-tdep.c (ia64_find_unwind_table): Likewise.
10619 * psympriv.h (struct partial_symtab): Likewise.
10620 * psymtab.c (find_pc_sect_psymtab): Likewise.
10621 * solib-svr4.c (enable_break): Likewise.
10622 * stap-probe.c (relocate_address): Use
10623 objfile::data_section_offset.
10624 * xcoffread.c (enter_line_range): Use
10625 objfile::text_section_offset.
10626 (read_xcoff_symtab): Likewise.
10627
10628 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
10629
10630 * darwin-nat.c (darwin_nat_target::wait_1): Move `inf`
10631 declaration to narrower scopes.
10632
10633 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
10634
10635 * darwin-nat.h (struct darwin_exception_msg, enum
10636 darwin_msg_state, struct darwin_thread_info, darwin_thread_t):
10637 Move up.
10638 (class darwin_nat_target) <wait_1, check_new_threads,
10639 decode_exception_message, decode_message, stop_inferior,
10640 init_thread_list, ptrace_him, cancel_breakpoint>: Declare.
10641 * darwin-nat.c (darwin_check_new_threads): Rename to...
10642 (darwin_nat_target::check_new_threads): ... this.
10643 (darwin_suspend_inferior_it): Remove.
10644 (darwin_decode_exception_message): Rename to...
10645 (darwin_nat_target::decode_exception_message): ... this.
10646 (darwin_nat_target::resume): Pass target to find_inferior_ptid.
10647 (darwin_decode_message): Rename to...
10648 (darwin_nat_target::decode_message): ... this.
10649 (cancel_breakpoint): Rename to...
10650 (darwin_nat_target::cancel_breakpoint): ... this.
10651 (darwin_wait): Rename to...
10652 (darwin_nat_target::wait_1): ... this. Use range-based for loop
10653 instead of iterate_over_inferiors.
10654 (darwin_nat_target::wait): Call wait_1 instead of darwin_wait.
10655 (darwin_stop_inferior): Rename to...
10656 (darwin_nat_target::stop_inferior): ... this.
10657 (darwin_nat_target::kill): Call wait_1 instead of darwin_wait.
10658 (darwin_init_thread_list): Rename to...
10659 (darwin_nat_target::init_thread_list): ... this.
10660 (darwin_ptrace_him): Rename to...
10661 (darwin_nat_target::ptrace_him): ... this.
10662 (darwin_nat_target::create_inferior): Pass lambda function to
10663 fork_inferior.
10664 (darwin_nat_target::detach): Call stop_inferior instead of
10665 darwin_stop_inferior.
10666 * fork-inferior.h (fork_inferior): Change init_trace_fun
10667 parameter to gdb::function_view.
10668 * fork-inferior.c (fork_inferior): Likewise.
10669
10670 2020-01-23 Hannes Domani <ssbssa@yahoo.de>
10671
10672 * i386-cygwin-tdep.c (core_process_module_section): Update.
10673 * windows-nat.c (struct lm_info_windows): Add text_offset.
10674 (windows_xfer_shared_libraries): Update.
10675 * windows-tdep.c (windows_xfer_shared_library):
10676 Add text_offset_cached argument.
10677 * windows-tdep.h (windows_xfer_shared_library): Update.
10678
10679 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
10680
10681 * gdbarch.sh: Add declaration for _initialize_gdbarch.
10682
10683 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
10684
10685 * remote-sim.c (check_for_duplicate_sim_descriptor): Remove.
10686 (get_sim_inferior_data): Remove use of iterate_over_inferiors,
10687 replace with range-based for.
10688 (gdbsim_interrupt_inferior): Remove.
10689 (gdbsim_target::interrupt): Replace iterate_over_inferiors use
10690 with a range-based for. Inline code from
10691 gdbsim_interrupt_inferior.
10692
10693 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
10694
10695 * infrun.c (proceed): Fix indentation.
10696
10697 2020-01-21 Tom Tromey <tromey@adacore.com>
10698
10699 * source-cache.c (source_cache::ensure): Call ext_lang_colorize.
10700 * python/python.c (python_extension_ops): Update.
10701 (gdbpy_colorize): New function.
10702 * python/lib/gdb/__init__.py (colorize): New function.
10703 * extension.h (ext_lang_colorize): Declare.
10704 * extension.c (ext_lang_colorize): New function.
10705 * extension-priv.h (struct extension_language_ops) <colorize>: New
10706 member.
10707 * cli/cli-style.c (_initialize_cli_style): Update help text.
10708
10709 2020-01-21 Luis Machado <luis.machado@linaro.org>
10710
10711 * aarch64-tdep.c (struct aarch64_displaced_step_closure)
10712 <cond>: Change type to bool.
10713 (aarch64_displaced_step_b_cond): Update cond to use bool type.
10714 (aarch64_displaced_step_cb): Likewise.
10715 (aarch64_displaced_step_tb): Likewise.
10716
10717 2020-01-21 Luis Machado <luis.machado@linaro.org>
10718
10719 * aarch64-tdep.c (aarch64_displaced_step_fixup): Add more debugging
10720 output.
10721
10722 2020-01-21 Luis Machado <luis.machado@linaro.org>
10723
10724 * aarch64-tdep.c (struct aarch64_displaced_step_closure )
10725 <pc_adjust>: Adjust the documentation.
10726 (aarch64_displaced_step_fixup): Check if PC really moved before
10727 adjusting it.
10728
10729 2020-01-19 Tom Tromey <tom@tromey.com>
10730
10731 * disasm.c (~gdb_disassembler): New destructor.
10732 (gdb_buffered_insn_length): Call disassemble_free_target.
10733 * disasm.h (class gdb_disassembler): Declare destructor. Use
10734 DISABLE_COPY_AND_ASSIGN.
10735
10736 2020-01-19 Tom Tromey <tom@tromey.com>
10737
10738 * dwarf2read.c (abbrev_table_up): Move typedef earlier.
10739 (die_reader_func_ftype): Remove.
10740 (cutu_reader): New class.
10741 (dw2_get_file_names_reader): Remove "data" parameter.
10742 (dw2_get_file_names): Use cutu_reader.
10743 (create_debug_type_hash_table): Update.
10744 (read_cutu_die_from_dwo): Update comment.
10745 (lookup_dwo_unit): Add dwo_name parameter.
10746 (cutu_reader::init_tu_and_read_dwo_dies): Now a method. Remove
10747 die_reader_func_ftype and data parameters.
10748 (cutu_reader::cutu_reader): Rename from init_cutu_and_read_dies.
10749 Remove die_reader_func_ftype and data parameters.
10750 (~cutu_reader): New; from init_cutu_and_read_dies.
10751 (cutu_reader::cutu_reader): Rename from
10752 init_cutu_and_read_dies_no_follow. Remove die_reader_func_ftype
10753 and data parameters.
10754 (init_cutu_and_read_dies_simple): Remove.
10755 (struct process_psymtab_comp_unit_data): Remove.
10756 (process_psymtab_comp_unit_reader): Remove data parameter; add
10757 want_partial_unit and pretend_language parameters.
10758 (process_psymtab_comp_unit): Use cutu_reader.
10759 (build_type_psymtabs_reader): Remove data parameter.
10760 (build_type_psymtabs_1): Use cutu_reader.
10761 (process_skeletonless_type_unit): Likewise.
10762 (load_partial_comp_unit_reader): Remove.
10763 (load_partial_comp_unit): Use cutu_reader.
10764 (load_full_comp_unit_reader): Remove.
10765 (load_full_comp_unit): Use cutu_reader.
10766 (struct create_dwo_cu_data): Remove.
10767 (create_dwo_cu_reader): Remove datap parameter; add dwo_file and
10768 dwo_unit parameters.
10769 (create_cus_hash_table): Use cutu_reader.
10770 (struct dwarf2_read_addr_index_data): Remove.
10771 (dwarf2_read_addr_index_reader): Remove.
10772 (dwarf2_read_addr_index): Use cutu_reader.
10773 (read_signatured_type_reader): Remove.
10774 (read_signatured_type): Use cutu_reader.
10775
10776 2020-01-19 Tom Tromey <tom@tromey.com>
10777
10778 * tui/tui.c (tui_show_assembly): Use tui_suppress_output.
10779 * tui/tui-wingeneral.h (class tui_suppress_output): New.
10780 (tui_wrefresh): Declare.
10781 * tui/tui-wingeneral.c (suppress_output): New global.
10782 (tui_suppress_output, ~tui_suppress_output): New constructor and
10783 destructor.
10784 (tui_wrefresh): New function.
10785 (tui_gen_win_info::refresh_window): Use tui_wrefresh.
10786 (tui_gen_win_info::make_window): Call wnoutrefresh when needed.
10787 * tui/tui-regs.h (struct tui_data_window) <no_refresh>: Declare
10788 method.
10789 * tui/tui-regs.c (tui_data_window::erase_data_content): Call
10790 tui_wrefresh.
10791 (tui_data_window::no_refresh): New method.
10792 (tui_data_item_window::refresh_window): Call tui_wrefresh.
10793 (tui_reg_command): Use tui_suppress_output
10794 * tui/tui-layout.c (tui_set_layout): Use tui_suppress_output.
10795 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: New
10796 method.
10797 * tui/tui-command.c (tui_refresh_cmd_win): Call tui_wrefresh.
10798
10799 2020-01-19 Tom Tromey <tom@tromey.com>
10800
10801 * tui/tui-winsource.c (tui_update_source_windows_with_line):
10802 Handle case where symtab is null.
10803
10804 2020-01-19 Simon Marchi <simon.marchi@polymtl.ca>
10805
10806 * linux-fork.c (one_fork_p): Simplify.
10807
10808 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
10809
10810 * top.c (struct qt_args): Remove.
10811 (kill_or_detach): Change return type to void, replace `void *`
10812 parameter with a proper one.
10813 (print_inferior_quit_action): Likewise.
10814 (quit_confirm): Use range-based for loop to iterate over inferiors.
10815 (quit_force): Likewise.
10816
10817 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
10818
10819 * mi/mi-main.c (run_one_inferior): Change return type to void, replace
10820 `void *` parameter with proper parameters.
10821 (mi_cmd_exec_run): Use range-based loop to iterate over inferiors.
10822 (print_one_inferior): Change return type to void, replace `void *`
10823 parameter with proper parameters.
10824 (mi_cmd_list_thread_groups): Use range-based loop to iterate over
10825 inferiors.
10826 (get_other_inferior): Remove.
10827 (mi_cmd_remove_inferior): Use range-based loop to iterate over
10828 inferiors.
10829
10830 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
10831
10832 * mi/mi-interp.c (report_initial_inferior): Remove.
10833 (mi_interp::init): Use range-based for to iterate over inferiors.
10834
10835 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
10836
10837 * python/py-inferior.c (build_inferior_list): Remove.
10838 (gdbpy_ref): Use range-based for loop to iterate over inferiors.
10839
10840 2020-01-16 Christian Biesinger <cbiesinger@google.com>
10841
10842 * btrace.c (btrace_compute_ftrace_1): Fix spelling error (Unkown).
10843 (btrace_stitch_trace): Likewise.
10844 * charset.c (intermediate_encoding): Likewise (vaild).
10845 * nat/linux-btrace.c (linux_read_pt): Likewise (Unkown).
10846 * python/py-record-btrace.c (struct PyMethodDef): Likewise (occurences).
10847 * record-btrace.c (record_btrace_print_conf): Likewise (unkown).
10848
10849 2020-01-16 Hannes Domani <ssbssa@yahoo.de>
10850
10851 * windows-tdep.c (windows_get_tlb_type):
10852 Add rtl_user_process_parameters type.
10853
10854 2020-01-16 Pedro Alves <palves@redhat.com>
10855 Norbert Lange <nolange79@gmail.com>
10856
10857 PR build/24805
10858 * gdbsupport/gdb_proc_service.h (PS_EXPORT): New.
10859 (ps_get_thread_area, ps_getpid, ps_lcontinue, ps_lgetfpregs)
10860 (ps_lgetregs, ps_lsetfpregs, ps_lsetregs, ps_lstop, ps_pcontinue)
10861 (ps_pdread, ps_pdwrite, ps_pglobal_lookup, ps_pstop, ps_ptread)
10862 (ps_ptwrite, ps_lgetxregs, ps_lgetxregsize, ps_lsetxregs)
10863 (ps_plog): Redeclare exported functions with default visibility.
10864
10865 2020-01-16 Nitika Achra <Nitika.Achra@amd.com>
10866
10867 * dwarf2loc.c (decode_debug_loclists_addresses): Handle
10868 DW_LLE_base_addressx, DW_LLE_startx_length, DW_LLE_start_length.
10869
10870 2020-01-15 Simon Marchi <simon.marchi@efficios.com>
10871
10872 * infcmd.c (post_create_inferior): Use get_thread_regcache
10873 instead of get_current_regcache.
10874
10875 2020-01-14 Tom Tromey <tom@tromey.com>
10876
10877 PR symtab/12535:
10878 * python/python.c (gdbpy_decode_line): Treat empty string the same
10879 as no argument.
10880
10881 2020-01-14 Tom Tromey <tom@tromey.com>
10882
10883 * Makefile.in (CLIBS): Remove second use of $(LIBIBERTY).
10884
10885 2020-01-14 Tom Tromey <tom@tromey.com>
10886
10887 * nat/linux-btrace.c: Don't include <config.h>.
10888 * nat/linux-ptrace.c: Don't include <config.h>.
10889 * nat/x86-linux-dregs.c: Don't include <config.h>.
10890
10891 2020-01-14 Tom Tromey <tom@tromey.com>
10892
10893 * configure: Rebuild.
10894 * configure.ac: Move many checks to ../gdbsupport/common.m4.
10895
10896 2020-01-14 Tom Tromey <tom@tromey.com>
10897
10898 * nat/x86-linux-dregs.c: Include configh.h.
10899 * nat/linux-ptrace.c: Include configh.h.
10900 * nat/linux-btrace.c: Include configh.h.
10901 * defs.h: Include config.h, bfd.h.
10902 * configure.ac: Don't source common.host.
10903 (CONFIG_OBS, CONFIG_SRCS): Remove gdbsupport files.
10904 * configure: Rebuild.
10905 * acinclude.m4: Update path.
10906 * Makefile.in (SUPPORT, LIBSUPPORT, INCSUPPORT): New variables.
10907 (CONFIG_SRC_SUBDIR): Remove gdbsupport.
10908 (INTERNAL_CFLAGS_BASE): Add INCSUPPORT.
10909 (CLIBS): Add LIBSUPPORT.
10910 (CDEPS): Likewise.
10911 (COMMON_SFILES): Remove gdbsupport files.
10912 (HFILES_NO_SRCDIR): Likewise.
10913 (stamp-version): Update path to create-version.sh.
10914 (ALLDEPFILES): Remove gdbsupport files.
10915
10916 2020-01-14 Tom Tromey <tom@tromey.com>
10917
10918 * gdbsupport/common.m4 (GDB_AC_COMMON): Define WIN32APILIBS and
10919 USE_WIN32API when needed.
10920 * configure.ac (USE_WIN32API): Don't define.
10921 (WIN32LIBS): Use WIN32APILIBS.
10922 * configure: Rebuild.
10923
10924 2020-01-14 Tom Tromey <tom@tromey.com>
10925
10926 * configure: Rebuild.
10927 * gdbsupport/common.m4 (GDB_AC_COMMON): Fix indentation.
10928
10929 2020-01-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
10930
10931 * skip.c (skip_function_command): Make skip w/o arguments use the
10932 name of the inlined function if pc is inside any inlined function.
10933
10934 2020-01-14 Luis Machado <luis.machado@linaro.org>
10935
10936 * inf-ptrace.c (inf_ptrace_target::resume): Update comments.
10937 * infrun.c (resume_1): Likewise.
10938 (handle_inferior_event): Remove stale comment.
10939 * linux-nat.c (linux_nat_target::resume): Update comments.
10940 (save_stop_reason): Likewise.
10941 (linux_nat_filter_event): Likewise.
10942 * linux-nat.h (struct lwp_info) <stop_pc>, <stop_reason>: Likewise.
10943
10944 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
10945
10946 * elfread.c (record_minimal_symbol): Set section index to 0 for
10947 non-allocatable sections.
10948
10949
10950 2020-01-13 Ali Tamur <tamur@google.com>
10951
10952 * dwarf2read.c (dwarf2_debug_sections): Add debug_str_offsets sections.
10953 (dwarf2_cu): Add str_offsets_base field. Change the type of addr_base
10954 to gdb::optional. Update comments.
10955 (dwo_file): Update comments.
10956 (read_attribute): Update API to take an additional out parameter,
10957 need_reprocess. This is used to mark attributes that need other
10958 attributes (e.g. str_offsets_base) for correct computation which may not
10959 have been read yet.
10960 (read_attribute_reprocess): New function declaration.
10961 (read_addr_index): Likewise.
10962 (read_dwo_str_index): Likewise.
10963 (read_stub_str_index): Likewise.
10964 (dwarf2_per_objfile::locate_sections): Handle debug_str_offsets section.
10965 (lookup_addr_base): New function definition.
10966 (lookup_ranges_base): Likewise.
10967 (read_cutu_die_from_dwo): Use the new functions: lookup_addr_base,
10968 lookup_ranges_base.
10969 (init_cutu_and_read_dies): Update comments.
10970 (init_cutu_and_read_dies_no_follow): Change API to take parent compile
10971 unit. This is used to inherit parent's str_offsets_base and addr_base.
10972 Update comments.
10973 (init_cutu_and_read_dies_simple): Reflect API changes.
10974 (skip_one_die): Reflect API changes. Handle DW_FORM_rnglistx.
10975 (create_cus_hash_table): Change API to take parent compile unit.
10976 Reflect API changes.
10977 (open_and_init_dwo_file): Reflect API changes.
10978 (dwarf2_get_pc_bounds): Update comments.
10979 (dwarf2_record_block_ranges): Likewise.
10980 (read_full_die_1): Change implementation to reprocess attributes that
10981 need str_offsets_base and addr_base.
10982 (partial_die_info::read): Likewise.
10983 (read_attribute_reprocess): New function definition.
10984 (read_attribute_value): Change API to take an additional out parameter,
10985 need_reprocess. Handle DW_FORM_rnglistx. No longer trigger an error
10986 when a non-dwo compile unit has index based attributes.
10987 (read_attribute): Reflect API changes.
10988 (read_addr_index_1): Reflect API changes. Update comments.
10989 (dwarf2_read_addr_index_data): Reflect API changes.
10990 (dwarf2_read_addr_index): Likewise.
10991 (read_str_index): Change API and implementation. This becomes a helper
10992 to be used by the new string index related methods. Update error
10993 message and comments.
10994 (read_dwo_str_index): New function definition.
10995 (read_stub_str_index): Likewise.
10996 * dwarf2read.h (dwarf2_per_objfile): Add str_offsets field.
10997 * symfile.h (dwarf2_debug_sections): Likewise.
10998 * xcoffread.c (dwarf2_debug_sections): Likewise.
10999
11000 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
11001
11002 * gdbcore.h (struct core_fns) <core_read_registers>: Change
11003 core_reg_sect type to gdb_byte *.
11004 * arm-nbsd-nat.c (fetch_elfcore_registers): Likewise.
11005 * cris-tdep.c (fetch_core_registers): Likewise.
11006 * corelow.c (core_target::get_core_register_section): Change
11007 type of `contents` to gdb::byte_vector.
11008
11009 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
11010
11011 * tui/tui-wingeneral.c (box_win): Position the title in the center
11012 of the border.
11013
11014 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
11015
11016 * corelow.c (core_target::get_core_register_section): Use
11017 std::vector instead of alloca.
11018
11019 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
11020
11021 * warning.m4: Add -Wmissing-declarations to build_warnings.
11022 * configure: Re-generate.
11023
11024 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
11025
11026 * python/python.c (init__gdb_module): Add declaration.
11027
11028 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
11029
11030 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Add declaration.
11031 * aarch64-fbsd-tdep.c (_initialize_aarch64_fbsd_tdep): Add declaration.
11032 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Add declaration.
11033 * aarch64-linux-tdep.c (_initialize_aarch64_linux_tdep): Add declaration.
11034 * aarch64-newlib-tdep.c (_initialize_aarch64_newlib_tdep): Add declaration.
11035 * aarch64-tdep.c (_initialize_aarch64_tdep): Add declaration.
11036 * ada-exp.y (_initialize_ada_exp): Add declaration.
11037 * ada-lang.c (_initialize_ada_language): Add declaration.
11038 * ada-tasks.c (_initialize_tasks): Add declaration.
11039 * agent.c (_initialize_agent): Add declaration.
11040 * aix-thread.c (_initialize_aix_thread): Add declaration.
11041 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Add declaration.
11042 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Add declaration.
11043 * alpha-linux-tdep.c (_initialize_alpha_linux_tdep): Add declaration.
11044 * alpha-nbsd-tdep.c (_initialize_alphanbsd_tdep): Add declaration.
11045 * alpha-obsd-tdep.c (_initialize_alphaobsd_tdep): Add declaration.
11046 * alpha-tdep.c (_initialize_alpha_tdep): Add declaration.
11047 * amd64-darwin-tdep.c (_initialize_amd64_darwin_tdep): Add declaration.
11048 * amd64-dicos-tdep.c (_initialize_amd64_dicos_tdep): Add declaration.
11049 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Add declaration.
11050 * amd64-fbsd-tdep.c (_initialize_amd64fbsd_tdep): Add declaration.
11051 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Add declaration.
11052 * amd64-linux-tdep.c (_initialize_amd64_linux_tdep): Add declaration.
11053 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Add declaration.
11054 * amd64-nbsd-tdep.c (_initialize_amd64nbsd_tdep): Add declaration.
11055 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Add declaration.
11056 * amd64-obsd-tdep.c (_initialize_amd64obsd_tdep): Add declaration.
11057 * amd64-sol2-tdep.c (_initialize_amd64_sol2_tdep): Add declaration.
11058 * amd64-tdep.c (_initialize_amd64_tdep): Add declaration.
11059 * amd64-windows-nat.c (_initialize_amd64_windows_nat): Add declaration.
11060 * amd64-windows-tdep.c (_initialize_amd64_windows_tdep): Add declaration.
11061 * annotate.c (_initialize_annotate): Add declaration.
11062 * arc-newlib-tdep.c (_initialize_arc_newlib_tdep): Add declaration.
11063 * arc-tdep.c (_initialize_arc_tdep): Add declaration.
11064 * arch-utils.c (_initialize_gdbarch_utils): Add declaration.
11065 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Add declaration.
11066 * arm-fbsd-tdep.c (_initialize_arm_fbsd_tdep): Add declaration.
11067 * arm-linux-nat.c (_initialize_arm_linux_nat): Add declaration.
11068 * arm-linux-tdep.c (_initialize_arm_linux_tdep): Add declaration.
11069 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Add declaration.
11070 * arm-nbsd-tdep.c (_initialize_arm_netbsd_tdep): Add declaration.
11071 * arm-obsd-tdep.c (_initialize_armobsd_tdep): Add declaration.
11072 * arm-pikeos-tdep.c (_initialize_arm_pikeos_tdep): Add declaration.
11073 * arm-symbian-tdep.c (_initialize_arm_symbian_tdep): Add declaration.
11074 * arm-tdep.c (_initialize_arm_tdep): Add declaration.
11075 * arm-wince-tdep.c (_initialize_arm_wince_tdep): Add declaration.
11076 * auto-load.c (_initialize_auto_load): Add declaration.
11077 * auxv.c (_initialize_auxv): Add declaration.
11078 * avr-tdep.c (_initialize_avr_tdep): Add declaration.
11079 * ax-gdb.c (_initialize_ax_gdb): Add declaration.
11080 * bfin-linux-tdep.c (_initialize_bfin_linux_tdep): Add declaration.
11081 * bfin-tdep.c (_initialize_bfin_tdep): Add declaration.
11082 * break-catch-sig.c (_initialize_break_catch_sig): Add declaration.
11083 * break-catch-syscall.c (_initialize_break_catch_syscall): Add declaration.
11084 * break-catch-throw.c (_initialize_break_catch_throw): Add declaration.
11085 * breakpoint.c (_initialize_breakpoint): Add declaration.
11086 * bsd-uthread.c (_initialize_bsd_uthread): Add declaration.
11087 * btrace.c (_initialize_btrace): Add declaration.
11088 * charset.c (_initialize_charset): Add declaration.
11089 * cli/cli-cmds.c (_initialize_cli_cmds): Add declaration.
11090 * cli/cli-dump.c (_initialize_cli_dump): Add declaration.
11091 * cli/cli-interp.c (_initialize_cli_interp): Add declaration.
11092 * cli/cli-logging.c (_initialize_cli_logging): Add declaration.
11093 * cli/cli-script.c (_initialize_cli_script): Add declaration.
11094 * cli/cli-style.c (_initialize_cli_style): Add declaration.
11095 * coff-pe-read.c (_initialize_coff_pe_read): Add declaration.
11096 * coffread.c (_initialize_coffread): Add declaration.
11097 * compile/compile-cplus-types.c (_initialize_compile_cplus_types): Add declaration.
11098 * compile/compile.c (_initialize_compile): Add declaration.
11099 * complaints.c (_initialize_complaints): Add declaration.
11100 * completer.c (_initialize_completer): Add declaration.
11101 * copying.c (_initialize_copying): Add declaration.
11102 * corefile.c (_initialize_core): Add declaration.
11103 * corelow.c (_initialize_corelow): Add declaration.
11104 * cp-abi.c (_initialize_cp_abi): Add declaration.
11105 * cp-namespace.c (_initialize_cp_namespace): Add declaration.
11106 * cp-support.c (_initialize_cp_support): Add declaration.
11107 * cp-valprint.c (_initialize_cp_valprint): Add declaration.
11108 * cris-linux-tdep.c (_initialize_cris_linux_tdep): Add declaration.
11109 * cris-tdep.c (_initialize_cris_tdep): Add declaration.
11110 * csky-linux-tdep.c (_initialize_csky_linux_tdep): Add declaration.
11111 * csky-tdep.c (_initialize_csky_tdep): Add declaration.
11112 * ctfread.c (_initialize_ctfread): Add declaration.
11113 * d-lang.c (_initialize_d_language): Add declaration.
11114 * darwin-nat-info.c (_initialize_darwin_info_commands): Add declaration.
11115 * darwin-nat.c (_initialize_darwin_nat): Add declaration.
11116 * dbxread.c (_initialize_dbxread): Add declaration.
11117 * dcache.c (_initialize_dcache): Add declaration.
11118 * disasm-selftests.c (_initialize_disasm_selftests): Add declaration.
11119 * disasm.c (_initialize_disasm): Add declaration.
11120 * dtrace-probe.c (_initialize_dtrace_probe): Add declaration.
11121 * dummy-frame.c (_initialize_dummy_frame): Add declaration.
11122 * dwarf-index-cache.c (_initialize_index_cache): Add declaration.
11123 * dwarf-index-write.c (_initialize_dwarf_index_write): Add declaration.
11124 * dwarf2-frame-tailcall.c (_initialize_tailcall_frame): Add declaration.
11125 * dwarf2-frame.c (_initialize_dwarf2_frame): Add declaration.
11126 * dwarf2expr.c (_initialize_dwarf2expr): Add declaration.
11127 * dwarf2loc.c (_initialize_dwarf2loc): Add declaration.
11128 * dwarf2read.c (_initialize_dwarf2_read): Add declaration.
11129 * elfread.c (_initialize_elfread): Add declaration.
11130 * exec.c (_initialize_exec): Add declaration.
11131 * extension.c (_initialize_extension): Add declaration.
11132 * f-lang.c (_initialize_f_language): Add declaration.
11133 * f-valprint.c (_initialize_f_valprint): Add declaration.
11134 * fbsd-nat.c (_initialize_fbsd_nat): Add declaration.
11135 * fbsd-tdep.c (_initialize_fbsd_tdep): Add declaration.
11136 * filesystem.c (_initialize_filesystem): Add declaration.
11137 * findcmd.c (_initialize_mem_search): Add declaration.
11138 * findvar.c (_initialize_findvar): Add declaration.
11139 * fork-child.c (_initialize_fork_child): Add declaration.
11140 * frame-base.c (_initialize_frame_base): Add declaration.
11141 * frame-unwind.c (_initialize_frame_unwind): Add declaration.
11142 * frame.c (_initialize_frame): Add declaration.
11143 * frv-linux-tdep.c (_initialize_frv_linux_tdep): Add declaration.
11144 * frv-tdep.c (_initialize_frv_tdep): Add declaration.
11145 * ft32-tdep.c (_initialize_ft32_tdep): Add declaration.
11146 * gcore.c (_initialize_gcore): Add declaration.
11147 * gdb-demangle.c (_initialize_gdb_demangle): Add declaration.
11148 * gdb_bfd.c (_initialize_gdb_bfd): Add declaration.
11149 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Add declaration.
11150 * gdbarch.c (_initialize_gdbarch): Add declaration.
11151 * gdbtypes.c (_initialize_gdbtypes): Add declaration.
11152 * gnu-nat.c (_initialize_gnu_nat): Add declaration.
11153 * gnu-v2-abi.c (_initialize_gnu_v2_abi): Add declaration.
11154 * gnu-v3-abi.c (_initialize_gnu_v3_abi): Add declaration.
11155 * go-lang.c (_initialize_go_language): Add declaration.
11156 * go32-nat.c (_initialize_go32_nat): Add declaration.
11157 * guile/guile.c (_initialize_guile): Add declaration.
11158 * h8300-tdep.c (_initialize_h8300_tdep): Add declaration.
11159 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Add declaration.
11160 * hppa-linux-tdep.c (_initialize_hppa_linux_tdep): Add declaration.
11161 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Add declaration.
11162 * hppa-nbsd-tdep.c (_initialize_hppanbsd_tdep): Add declaration.
11163 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Add declaration.
11164 * hppa-obsd-tdep.c (_initialize_hppabsd_tdep): Add declaration.
11165 * hppa-tdep.c (_initialize_hppa_tdep): Add declaration.
11166 * i386-bsd-nat.c (_initialize_i386bsd_nat): Add declaration.
11167 * i386-cygwin-tdep.c (_initialize_i386_cygwin_tdep): Add declaration.
11168 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Add declaration.
11169 * i386-darwin-tdep.c (_initialize_i386_darwin_tdep): Add declaration.
11170 * i386-dicos-tdep.c (_initialize_i386_dicos_tdep): Add declaration.
11171 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Add declaration.
11172 * i386-fbsd-tdep.c (_initialize_i386fbsd_tdep): Add declaration.
11173 * i386-gnu-nat.c (_initialize_i386gnu_nat): Add declaration.
11174 * i386-gnu-tdep.c (_initialize_i386gnu_tdep): Add declaration.
11175 * i386-go32-tdep.c (_initialize_i386_go32_tdep): Add declaration.
11176 * i386-linux-nat.c (_initialize_i386_linux_nat): Add declaration.
11177 * i386-linux-tdep.c (_initialize_i386_linux_tdep): Add declaration.
11178 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Add declaration.
11179 * i386-nbsd-tdep.c (_initialize_i386nbsd_tdep): Add declaration.
11180 * i386-nto-tdep.c (_initialize_i386nto_tdep): Add declaration.
11181 * i386-obsd-nat.c (_initialize_i386obsd_nat): Add declaration.
11182 * i386-obsd-tdep.c (_initialize_i386obsd_tdep): Add declaration.
11183 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Add declaration.
11184 * i386-sol2-tdep.c (_initialize_i386_sol2_tdep): Add declaration.
11185 * i386-tdep.c (_initialize_i386_tdep): Add declaration.
11186 * i386-windows-nat.c (_initialize_i386_windows_nat): Add declaration.
11187 * ia64-libunwind-tdep.c (_initialize_libunwind_frame): Add declaration.
11188 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Add declaration.
11189 * ia64-linux-tdep.c (_initialize_ia64_linux_tdep): Add declaration.
11190 * ia64-tdep.c (_initialize_ia64_tdep): Add declaration.
11191 * ia64-vms-tdep.c (_initialize_ia64_vms_tdep): Add declaration.
11192 * infcall.c (_initialize_infcall): Add declaration.
11193 * infcmd.c (_initialize_infcmd): Add declaration.
11194 * inflow.c (_initialize_inflow): Add declaration.
11195 * infrun.c (_initialize_infrun): Add declaration.
11196 * interps.c (_initialize_interpreter): Add declaration.
11197 * iq2000-tdep.c (_initialize_iq2000_tdep): Add declaration.
11198 * jit.c (_initialize_jit): Add declaration.
11199 * language.c (_initialize_language): Add declaration.
11200 * linux-fork.c (_initialize_linux_fork): Add declaration.
11201 * linux-nat.c (_initialize_linux_nat): Add declaration.
11202 * linux-tdep.c (_initialize_linux_tdep): Add declaration.
11203 * linux-thread-db.c (_initialize_thread_db): Add declaration.
11204 * lm32-tdep.c (_initialize_lm32_tdep): Add declaration.
11205 * m2-lang.c (_initialize_m2_language): Add declaration.
11206 * m32c-tdep.c (_initialize_m32c_tdep): Add declaration.
11207 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Add declaration.
11208 * m32r-linux-tdep.c (_initialize_m32r_linux_tdep): Add declaration.
11209 * m32r-tdep.c (_initialize_m32r_tdep): Add declaration.
11210 * m68hc11-tdep.c (_initialize_m68hc11_tdep): Add declaration.
11211 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Add declaration.
11212 * m68k-bsd-tdep.c (_initialize_m68kbsd_tdep): Add declaration.
11213 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Add declaration.
11214 * m68k-linux-tdep.c (_initialize_m68k_linux_tdep): Add declaration.
11215 * m68k-tdep.c (_initialize_m68k_tdep): Add declaration.
11216 * machoread.c (_initialize_machoread): Add declaration.
11217 * macrocmd.c (_initialize_macrocmd): Add declaration.
11218 * macroscope.c (_initialize_macroscope): Add declaration.
11219 * maint-test-options.c (_initialize_maint_test_options): Add declaration.
11220 * maint-test-settings.c (_initialize_maint_test_settings): Add declaration.
11221 * maint.c (_initialize_maint_cmds): Add declaration.
11222 * mdebugread.c (_initialize_mdebugread): Add declaration.
11223 * memattr.c (_initialize_mem): Add declaration.
11224 * mep-tdep.c (_initialize_mep_tdep): Add declaration.
11225 * mi/mi-cmd-env.c (_initialize_mi_cmd_env): Add declaration.
11226 * mi/mi-cmds.c (_initialize_mi_cmds): Add declaration.
11227 * mi/mi-interp.c (_initialize_mi_interp): Add declaration.
11228 * mi/mi-main.c (_initialize_mi_main): Add declaration.
11229 * microblaze-linux-tdep.c (_initialize_microblaze_linux_tdep): Add declaration.
11230 * microblaze-tdep.c (_initialize_microblaze_tdep): Add declaration.
11231 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Add declaration.
11232 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Add declaration.
11233 * mips-linux-nat.c (_initialize_mips_linux_nat): Add declaration.
11234 * mips-linux-tdep.c (_initialize_mips_linux_tdep): Add declaration.
11235 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Add declaration.
11236 * mips-nbsd-tdep.c (_initialize_mipsnbsd_tdep): Add declaration.
11237 * mips-sde-tdep.c (_initialize_mips_sde_tdep): Add declaration.
11238 * mips-tdep.c (_initialize_mips_tdep): Add declaration.
11239 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Add declaration.
11240 * mips64-obsd-tdep.c (_initialize_mips64obsd_tdep): Add declaration.
11241 * mipsread.c (_initialize_mipsread): Add declaration.
11242 * mn10300-linux-tdep.c (_initialize_mn10300_linux_tdep): Add declaration.
11243 * mn10300-tdep.c (_initialize_mn10300_tdep): Add declaration.
11244 * moxie-tdep.c (_initialize_moxie_tdep): Add declaration.
11245 * msp430-tdep.c (_initialize_msp430_tdep): Add declaration.
11246 * nds32-tdep.c (_initialize_nds32_tdep): Add declaration.
11247 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Add declaration.
11248 * nios2-tdep.c (_initialize_nios2_tdep): Add declaration.
11249 * nto-procfs.c (_initialize_procfs): Add declaration.
11250 * objc-lang.c (_initialize_objc_language): Add declaration.
11251 * observable.c (_initialize_observer): Add declaration.
11252 * opencl-lang.c (_initialize_opencl_language): Add declaration.
11253 * or1k-linux-tdep.c (_initialize_or1k_linux_tdep): Add declaration.
11254 * or1k-tdep.c (_initialize_or1k_tdep): Add declaration.
11255 * osabi.c (_initialize_gdb_osabi): Add declaration.
11256 * osdata.c (_initialize_osdata): Add declaration.
11257 * p-valprint.c (_initialize_pascal_valprint): Add declaration.
11258 * parse.c (_initialize_parse): Add declaration.
11259 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Add declaration.
11260 * ppc-fbsd-tdep.c (_initialize_ppcfbsd_tdep): Add declaration.
11261 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Add declaration.
11262 * ppc-linux-tdep.c (_initialize_ppc_linux_tdep): Add declaration.
11263 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Add declaration.
11264 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Add declaration.
11265 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Add declaration.
11266 * ppc-obsd-tdep.c (_initialize_ppcobsd_tdep): Add declaration.
11267 * printcmd.c (_initialize_printcmd): Add declaration.
11268 * probe.c (_initialize_probe): Add declaration.
11269 * proc-api.c (_initialize_proc_api): Add declaration.
11270 * proc-events.c (_initialize_proc_events): Add declaration.
11271 * proc-service.c (_initialize_proc_service): Add declaration.
11272 * procfs.c (_initialize_procfs): Add declaration.
11273 * producer.c (_initialize_producer): Add declaration.
11274 * psymtab.c (_initialize_psymtab): Add declaration.
11275 * python/python.c (_initialize_python): Add declaration.
11276 * ravenscar-thread.c (_initialize_ravenscar): Add declaration.
11277 * record-btrace.c (_initialize_record_btrace): Add declaration.
11278 * record-full.c (_initialize_record_full): Add declaration.
11279 * record.c (_initialize_record): Add declaration.
11280 * regcache-dump.c (_initialize_regcache_dump): Add declaration.
11281 * regcache.c (_initialize_regcache): Add declaration.
11282 * reggroups.c (_initialize_reggroup): Add declaration.
11283 * remote-notif.c (_initialize_notif): Add declaration.
11284 * remote-sim.c (_initialize_remote_sim): Add declaration.
11285 * remote.c (_initialize_remote): Add declaration.
11286 * reverse.c (_initialize_reverse): Add declaration.
11287 * riscv-fbsd-nat.c (_initialize_riscv_fbsd_nat): Add declaration.
11288 * riscv-fbsd-tdep.c (_initialize_riscv_fbsd_tdep): Add declaration.
11289 * riscv-linux-nat.c (_initialize_riscv_linux_nat): Add declaration.
11290 * riscv-linux-tdep.c (_initialize_riscv_linux_tdep): Add declaration.
11291 * riscv-tdep.c (_initialize_riscv_tdep): Add declaration.
11292 * rl78-tdep.c (_initialize_rl78_tdep): Add declaration.
11293 * rs6000-aix-tdep.c (_initialize_rs6000_aix_tdep): Add declaration.
11294 * rs6000-lynx178-tdep.c (_initialize_rs6000_lynx178_tdep):
11295 Add declaration.
11296 * rs6000-nat.c (_initialize_rs6000_nat): Add declaration.
11297 * rs6000-tdep.c (_initialize_rs6000_tdep): Add declaration.
11298 * run-on-main-thread.c (_initialize_run_on_main_thread): Add declaration.
11299 * rust-exp.y (_initialize_rust_exp): Add declaration.
11300 * rx-tdep.c (_initialize_rx_tdep): Add declaration.
11301 * s12z-tdep.c (_initialize_s12z_tdep): Add declaration.
11302 * s390-linux-nat.c (_initialize_s390_nat): Add declaration.
11303 * s390-linux-tdep.c (_initialize_s390_linux_tdep): Add declaration.
11304 * s390-tdep.c (_initialize_s390_tdep): Add declaration.
11305 * score-tdep.c (_initialize_score_tdep): Add declaration.
11306 * ser-go32.c (_initialize_ser_dos): Add declaration.
11307 * ser-mingw.c (_initialize_ser_windows): Add declaration.
11308 * ser-pipe.c (_initialize_ser_pipe): Add declaration.
11309 * ser-tcp.c (_initialize_ser_tcp): Add declaration.
11310 * ser-uds.c (_initialize_ser_socket): Add declaration.
11311 * ser-unix.c (_initialize_ser_hardwire): Add declaration.
11312 * serial.c (_initialize_serial): Add declaration.
11313 * sh-linux-tdep.c (_initialize_sh_linux_tdep): Add declaration.
11314 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Add declaration.
11315 * sh-nbsd-tdep.c (_initialize_shnbsd_tdep): Add declaration.
11316 * sh-tdep.c (_initialize_sh_tdep): Add declaration.
11317 * skip.c (_initialize_step_skip): Add declaration.
11318 * sol-thread.c (_initialize_sol_thread): Add declaration.
11319 * solib-aix.c (_initialize_solib_aix): Add declaration.
11320 * solib-darwin.c (_initialize_darwin_solib): Add declaration.
11321 * solib-dsbt.c (_initialize_dsbt_solib): Add declaration.
11322 * solib-frv.c (_initialize_frv_solib): Add declaration.
11323 * solib-svr4.c (_initialize_svr4_solib): Add declaration.
11324 * solib-target.c (_initialize_solib_target): Add declaration.
11325 * solib.c (_initialize_solib): Add declaration.
11326 * source-cache.c (_initialize_source_cache): Add declaration.
11327 * source.c (_initialize_source): Add declaration.
11328 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Add declaration.
11329 * sparc-linux-tdep.c (_initialize_sparc_linux_tdep): Add declaration.
11330 * sparc-nat.c (_initialize_sparc_nat): Add declaration.
11331 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Add declaration.
11332 * sparc-nbsd-tdep.c (_initialize_sparcnbsd_tdep): Add declaration.
11333 * sparc-obsd-tdep.c (_initialize_sparc32obsd_tdep): Add declaration.
11334 * sparc-sol2-tdep.c (_initialize_sparc_sol2_tdep): Add declaration.
11335 * sparc-tdep.c (_initialize_sparc_tdep): Add declaration.
11336 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Add declaration.
11337 * sparc64-fbsd-tdep.c (_initialize_sparc64fbsd_tdep): Add declaration.
11338 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Add declaration.
11339 * sparc64-linux-tdep.c (_initialize_sparc64_linux_tdep): Add declaration.
11340 * sparc64-nat.c (_initialize_sparc64_nat): Add declaration.
11341 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Add declaration.
11342 * sparc64-nbsd-tdep.c (_initialize_sparc64nbsd_tdep): Add declaration.
11343 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Add declaration.
11344 * sparc64-obsd-tdep.c (_initialize_sparc64obsd_tdep): Add declaration.
11345 * sparc64-sol2-tdep.c (_initialize_sparc64_sol2_tdep): Add declaration.
11346 * sparc64-tdep.c (_initialize_sparc64_adi_tdep): Add declaration.
11347 * stabsread.c (_initialize_stabsread): Add declaration.
11348 * stack.c (_initialize_stack): Add declaration.
11349 * stap-probe.c (_initialize_stap_probe): Add declaration.
11350 * std-regs.c (_initialize_frame_reg): Add declaration.
11351 * symfile-debug.c (_initialize_symfile_debug): Add declaration.
11352 * symfile-mem.c (_initialize_symfile_mem): Add declaration.
11353 * symfile.c (_initialize_symfile): Add declaration.
11354 * symmisc.c (_initialize_symmisc): Add declaration.
11355 * symtab.c (_initialize_symtab): Add declaration.
11356 * target.c (_initialize_target): Add declaration.
11357 * target-connection.c (_initialize_target_connection): Add
11358 declaration.
11359 * target-dcache.c (_initialize_target_dcache): Add declaration.
11360 * target-descriptions.c (_initialize_target_descriptions): Add declaration.
11361 * thread.c (_initialize_thread): Add declaration.
11362 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Add declaration.
11363 * tic6x-tdep.c (_initialize_tic6x_tdep): Add declaration.
11364 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Add declaration.
11365 * tilegx-linux-tdep.c (_initialize_tilegx_linux_tdep): Add declaration.
11366 * tilegx-tdep.c (_initialize_tilegx_tdep): Add declaration.
11367 * tracectf.c (_initialize_ctf): Add declaration.
11368 * tracefile-tfile.c (_initialize_tracefile_tfile): Add declaration.
11369 * tracefile.c (_initialize_tracefile): Add declaration.
11370 * tracepoint.c (_initialize_tracepoint): Add declaration.
11371 * tui/tui-hooks.c (_initialize_tui_hooks): Add declaration.
11372 * tui/tui-interp.c (_initialize_tui_interp): Add declaration.
11373 * tui/tui-layout.c (_initialize_tui_layout): Add declaration.
11374 * tui/tui-regs.c (_initialize_tui_regs): Add declaration.
11375 * tui/tui-stack.c (_initialize_tui_stack): Add declaration.
11376 * tui/tui-win.c (_initialize_tui_win): Add declaration.
11377 * tui/tui.c (_initialize_tui): Add declaration.
11378 * typeprint.c (_initialize_typeprint): Add declaration.
11379 * ui-style.c (_initialize_ui_style): Add declaration.
11380 * unittests/array-view-selftests.c (_initialize_array_view_selftests): Add declaration.
11381 * unittests/child-path-selftests.c (_initialize_child_path_selftests): Add declaration.
11382 * unittests/cli-utils-selftests.c (_initialize_cli_utils_selftests): Add declaration.
11383 * unittests/common-utils-selftests.c (_initialize_common_utils_selftests): Add declaration.
11384 * unittests/copy_bitwise-selftests.c (_initialize_copy_bitwise_utils_selftests): Add declaration.
11385 * unittests/environ-selftests.c (_initialize_environ_selftests): Add declaration.
11386 * unittests/filtered_iterator-selftests.c
11387 (_initialize_filtered_iterator_selftests): Add declaration.
11388 * unittests/format_pieces-selftests.c (_initialize_format_pieces_selftests): Add declaration.
11389 * unittests/function-view-selftests.c (_initialize_function_view_selftests): Add declaration.
11390 * unittests/help-doc-selftests.c (_initialize_help_doc_selftests): Add declaration.
11391 * unittests/lookup_name_info-selftests.c (_initialize_lookup_name_info_selftests): Add declaration.
11392 * unittests/main-thread-selftests.c
11393 (_initialize_main_thread_selftests): Add declaration.
11394 * unittests/memory-map-selftests.c (_initialize_memory_map_selftests): Add declaration.
11395 * unittests/memrange-selftests.c (_initialize_memrange_selftests): Add declaration.
11396 * unittests/mkdir-recursive-selftests.c (_initialize_mkdir_recursive_selftests): Add declaration.
11397 * unittests/observable-selftests.c (_initialize_observer_selftest): Add declaration.
11398 * unittests/offset-type-selftests.c (_initialize_offset_type_selftests): Add declaration.
11399 * unittests/optional-selftests.c (_initialize_optional_selftests): Add declaration.
11400 * unittests/parse-connection-spec-selftests.c (_initialize_parse_connection_spec_selftests): Add declaration.
11401 * unittests/rsp-low-selftests.c (_initialize_rsp_low_selftests): Add declaration.
11402 * unittests/scoped_fd-selftests.c (_initialize_scoped_fd_selftests): Add declaration.
11403 * unittests/scoped_mmap-selftests.c (_initialize_scoped_mmap_selftests): Add declaration.
11404 * unittests/scoped_restore-selftests.c (_initialize_scoped_restore_selftests): Add declaration.
11405 * unittests/string_view-selftests.c (_initialize_string_view_selftests): Add declaration.
11406 * unittests/style-selftests.c (_initialize_style_selftest): Add declaration.
11407 * unittests/tracepoint-selftests.c (_initialize_tracepoint_selftests): Add declaration.
11408 * unittests/tui-selftests.c (_initialize_tui_selftest): Add
11409 declaration.
11410 * unittests/unpack-selftests.c (_initialize_unpack_selftests): Add declaration.
11411 * unittests/utils-selftests.c (_initialize_utils_selftests): Add declaration.
11412 * unittests/vec-utils-selftests.c (_initialize_vec_utils_selftests): Add declaration.
11413 * unittests/xml-utils-selftests.c (_initialize_xml_utils): Add declaration.
11414 * user-regs.c (_initialize_user_regs): Add declaration.
11415 * utils.c (_initialize_utils): Add declaration.
11416 * v850-tdep.c (_initialize_v850_tdep): Add declaration.
11417 * valops.c (_initialize_valops): Add declaration.
11418 * valprint.c (_initialize_valprint): Add declaration.
11419 * value.c (_initialize_values): Add declaration.
11420 * varobj.c (_initialize_varobj): Add declaration.
11421 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Add declaration.
11422 * vax-nbsd-tdep.c (_initialize_vaxnbsd_tdep): Add declaration.
11423 * vax-tdep.c (_initialize_vax_tdep): Add declaration.
11424 * windows-nat.c (_initialize_windows_nat): Add declaration.
11425 (_initialize_check_for_gdb_ini): Add declaration.
11426 (_initialize_loadable): Add declaration.
11427 * windows-tdep.c (_initialize_windows_tdep): Add declaration.
11428 * x86-bsd-nat.c (_initialize_x86_bsd_nat): Add declaration.
11429 * x86-linux-nat.c (_initialize_x86_linux_nat): Add declaration.
11430 * xcoffread.c (_initialize_xcoffread): Add declaration.
11431 * xml-support.c (_initialize_xml_support): Add declaration.
11432 * xstormy16-tdep.c (_initialize_xstormy16_tdep): Add declaration.
11433 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Add declaration.
11434 * xtensa-linux-tdep.c (_initialize_xtensa_linux_tdep): Add declaration.
11435 * xtensa-tdep.c (_initialize_xtensa_tdep): Add declaration.
11436
11437 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
11438
11439 * regformats/regdat.sh: Generate declaration for init function.
11440
11441 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
11442
11443 * remote-sim.c (next_pid, INITIAL_PID, sim_inferior_data): Move
11444 up.
11445 (gdbsim_target) <get_inferior_data_by_ptid, resume_one_inferior,
11446 close_one_inferior>: New methods.
11447 (get_sim_inferior_data_by_ptid): Move to gdbsim_target,
11448 pass down target to find_inferior_pid.
11449 (gdbsim_target::fetch_registers, gdbsim_target::store_registers):
11450 Pass down target to find_inferior_ptid.
11451 (gdbsim_target::create_inferior): Pass down target to
11452 add_thread_silent.
11453 (gdbsim_close_inferior): Move to gdbsim_close_inferior, pass
11454 target down to find_inferior_ptid and switch_to_thread.
11455 (gdbsim_target::close): Update to call close_one_inferior.
11456 (struct resume_data): Remove.
11457 (gdbsim_resume_inferior): Move to gdbsim_target. Take arguments
11458 directly, rather than through a void pointer.
11459 (gdbsim_target::resume): Update to call resume_one_inferior.
11460
11461 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
11462
11463 * gdbsupport/gdb_wait.c: Include gdb_wait.h.
11464
11465 2020-01-12 Pedro Alves <palves@redhat.com>
11466
11467 * bsd-kvm.c (bsd_kvm_target::close): Call exit_inferior_silent
11468 directly for the current inferior instead of
11469 discard_all_inferiors.
11470 (discard_all_inferiors): Delete.
11471
11472 2020-01-11 Tom Tromey <tom@tromey.com>
11473
11474 * tui/tui-wingeneral.c (box_win): Check cli_styling.
11475 * tui/tui-winsource.c (tui_source_window_base::refill): Use
11476 deprecated_safe_get_selected_frame.
11477
11478 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
11479
11480 * inferior.c (print_inferior): Switch inferior before printing it.
11481
11482 2020-01-10 Aleksandar Paunovic <aleksandar.paunovic@intel.com>
11483 Pedro Alves <palves@redhat.com>
11484
11485 * progspace-and-thread.c (switch_to_program_space_and_thread):
11486 Assert there's an inferior for PSPACE. Use
11487 switch_to_inferior_no_thread to switch the inferior too.
11488 * progspace.c (program_space::~program_space): Call
11489 clear_symtab_users here, with SYMFILE_DEFER_BP_RESET.
11490 (program_space::free_all_objfiles): Don't call clear_symtab_users
11491 here.
11492 * symfile.c (symbol_file_clear): Call clear_symtab_users here.
11493
11494 2020-01-10 Pedro Alves <palves@redhat.com>
11495
11496 * NEWS: Mention multi-target debugging, "info connections", and
11497 "add-inferior -no-connection".
11498
11499 2020-01-10 Pedro Alves <palves@redhat.com>
11500
11501 * infrun.c: Include "target-connection.h".
11502 (check_multi_target_resumption): New.
11503 (proceed): Call it.
11504 * target-connection.c (make_target_connection_string): Make
11505 extern.
11506 * target-connection.h (make_target_connection_string): Declare.
11507
11508 2020-01-10 Pedro Alves <palves@redhat.com>
11509
11510 * Makefile.in (COMMON_SFILES): Add target-connection.c.
11511 * inferior.c (uiout_field_connection): New function.
11512 (print_inferior): Add new "connection-id" column.
11513 (add_inferior_command): Show connection number/string of added
11514 inferior.
11515 * process-stratum-target.h
11516 (process_stratum_target::connection_string): New virtual method.
11517 (process_stratum_target::connection_number): New field.
11518 * remote.c (remote_target::connection_string): New override.
11519 * target-connection.c: New file.
11520 * target-connection.h: New file.
11521 * target.c (decref_target): Remove process_stratum targets from
11522 the connection list.
11523 (target_stack::push): Add process_stratum targets to the
11524 connection list.
11525
11526 2020-01-10 Pedro Alves <palves@redhat.com>
11527
11528 Revert:
11529 2016-04-12 Pedro Alves <palves@redhat.com>
11530 * serial.c (serial_open, serial_fdopen_ops, do_serial_close):
11531 Remove references to name.
11532 * serial.h (struct serial) <name>: Delete.
11533
11534 2020-01-10 Pedro Alves <palves@redhat.com>
11535
11536 * gdbarch-selftests.c (register_to_value_test): Remove "target
11537 already pushed" check.
11538
11539 2020-01-10 Pedro Alves <palves@redhat.com>
11540 John Baldwin <jhb@FreeBSD.org>
11541
11542 * aarch64-linux-nat.c
11543 (aarch64_linux_nat_target::thread_architecture): Adjust.
11544 * ada-tasks.c (print_ada_task_info): Adjust find_thread_ptid call.
11545 (task_command_1): Likewise.
11546 * aix-thread.c (sync_threadlists, aix_thread_target::resume)
11547 (aix_thread_target::wait, aix_thread_target::fetch_registers)
11548 (aix_thread_target::store_registers)
11549 (aix_thread_target::thread_alive): Adjust.
11550 * amd64-fbsd-tdep.c: Include "inferior.h".
11551 (amd64fbsd_get_thread_local_address): Pass down target.
11552 * amd64-linux-nat.c (ps_get_thread_area): Use ps_prochandle
11553 thread's gdbarch instead of target_gdbarch.
11554 * break-catch-sig.c (signal_catchpoint_print_it): Adjust call to
11555 get_last_target_status.
11556 * break-catch-syscall.c (print_it_catch_syscall): Likewise.
11557 * breakpoint.c (breakpoints_should_be_inserted_now): Consider all
11558 inferiors.
11559 (update_inserted_breakpoint_locations): Skip if inferiors with no
11560 execution.
11561 (update_global_location_list): When handling moribund locations,
11562 find representative inferior for location's pspace, and use thread
11563 count of its process_stratum target.
11564 * bsd-kvm.c (bsd_kvm_target_open): Pass target down.
11565 * bsd-uthread.c (bsd_uthread_target::wait): Use
11566 as_process_stratum_target and adjust thread_change_ptid and
11567 add_thread calls.
11568 (bsd_uthread_target::update_thread_list): Use
11569 as_process_stratum_target and adjust find_thread_ptid,
11570 thread_change_ptid and add_thread calls.
11571 * btrace.c (maint_btrace_packet_history_cmd): Adjust
11572 find_thread_ptid call.
11573 * corelow.c (add_to_thread_list): Adjust add_thread call.
11574 (core_target_open): Adjust add_thread_silent and thread_count
11575 calls.
11576 (core_target::pid_to_str): Adjust find_inferior_ptid call.
11577 * ctf.c (ctf_target_open): Adjust add_thread_silent call.
11578 * event-top.c (async_disconnect): Pop targets from all inferiors.
11579 * exec.c (add_target_sections): Push exec target on all inferiors
11580 sharing the program space.
11581 (remove_target_sections): Remove the exec target from all
11582 inferiors sharing the program space.
11583 (exec_on_vfork): New.
11584 * exec.h (exec_on_vfork): Declare.
11585 * fbsd-nat.c (fbsd_add_threads): Add fbsd_nat_target parameter.
11586 Pass it down.
11587 (fbsd_nat_target::update_thread_list): Adjust.
11588 (fbsd_nat_target::resume): Adjust.
11589 (fbsd_handle_debug_trap): Add fbsd_nat_target parameter. Pass it
11590 down.
11591 (fbsd_nat_target::wait, fbsd_nat_target::post_attach): Adjust.
11592 * fbsd-tdep.c (fbsd_corefile_thread): Adjust
11593 get_thread_arch_regcache call.
11594 * fork-child.c (gdb_startup_inferior): Pass target down to
11595 startup_inferior and set_executing.
11596 * gdbthread.h (struct process_stratum_target): Forward declare.
11597 (add_thread, add_thread_silent, add_thread_with_info)
11598 (in_thread_list): Add process_stratum_target parameter.
11599 (find_thread_ptid(inferior*, ptid_t)): New overload.
11600 (find_thread_ptid, thread_change_ptid): Add process_stratum_target
11601 parameter.
11602 (all_threads()): Delete overload.
11603 (all_threads, all_non_exited_threads): Add process_stratum_target
11604 parameter.
11605 (all_threads_safe): Use brace initialization.
11606 (thread_count): Add process_stratum_target parameter.
11607 (set_resumed, set_running, set_stop_requested, set_executing)
11608 (threads_are_executing, finish_thread_state): Add
11609 process_stratum_target parameter.
11610 (switch_to_thread): Use is_current_thread.
11611 * i386-fbsd-tdep.c: Include "inferior.h".
11612 (i386fbsd_get_thread_local_address): Pass down target.
11613 * i386-linux-nat.c (i386_linux_nat_target::low_resume): Adjust.
11614 * inf-child.c (inf_child_target::maybe_unpush_target): Remove
11615 have_inferiors check.
11616 * inf-ptrace.c (inf_ptrace_target::create_inferior)
11617 (inf_ptrace_target::attach): Adjust.
11618 * infcall.c (run_inferior_call): Adjust.
11619 * infcmd.c (run_command_1): Pass target to
11620 scoped_finish_thread_state.
11621 (proceed_thread_callback): Skip inferiors with no execution.
11622 (continue_command): Rename 'all_threads' local to avoid hiding
11623 'all_threads' function. Adjust get_last_target_status call.
11624 (prepare_one_step): Adjust set_running call.
11625 (signal_command): Use user_visible_resume_target. Compare thread
11626 pointers instead of inferior_ptid.
11627 (info_program_command): Adjust to pass down target.
11628 (attach_command): Mark target's 'thread_executing' flag.
11629 (stop_current_target_threads_ns): New, factored out from ...
11630 (interrupt_target_1): ... this. Switch inferior before making
11631 target calls.
11632 * inferior-iter.h
11633 (struct all_inferiors_iterator, struct all_inferiors_range)
11634 (struct all_inferiors_safe_range)
11635 (struct all_non_exited_inferiors_range): Filter on
11636 process_stratum_target too. Remove explicit.
11637 * inferior.c (inferior::inferior): Push dummy target on target
11638 stack.
11639 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors):
11640 Add process_stratum_target parameter, and pass it down.
11641 (have_live_inferiors): Adjust.
11642 (switch_to_inferior_and_push_target): New.
11643 (add_inferior_command, clone_inferior_command): Handle
11644 "-no-connection" parameter. Use
11645 switch_to_inferior_and_push_target.
11646 (_initialize_inferior): Mention "-no-connection" option in
11647 the help of "add-inferior" and "clone-inferior" commands.
11648 * inferior.h: Include "process-stratum-target.h".
11649 (interrupt_target_1): Use bool.
11650 (struct inferior) <push_target, unpush_target, target_is_pushed,
11651 find_target_beneath, top_target, process_target, target_at,
11652 m_stack>: New.
11653 (discard_all_inferiors): Delete.
11654 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors)
11655 (all_inferiors, all_non_exited_inferiors): Add
11656 process_stratum_target parameter.
11657 * infrun.c: Include "gdb_select.h" and <unordered_map>.
11658 (target_last_proc_target): New global.
11659 (follow_fork_inferior): Push target on new inferior. Pass target
11660 to add_thread_silent. Call exec_on_vfork. Handle target's
11661 reference count.
11662 (follow_fork): Adjust get_last_target_status call. Also consider
11663 target.
11664 (follow_exec): Push target on new inferior.
11665 (struct execution_control_state) <target>: New field.
11666 (user_visible_resume_target): New.
11667 (do_target_resume): Call target_async.
11668 (resume_1): Set target's threads_executing flag. Consider resume
11669 target.
11670 (commit_resume_all_targets): New.
11671 (proceed): Also consider resume target. Skip threads of inferiors
11672 with no execution. Commit resumtion in all targets.
11673 (start_remote): Pass current inferior to wait_for_inferior.
11674 (infrun_thread_stop_requested): Consider target as well. Pass
11675 thread_info pointer to clear_inline_frame_state instead of ptid.
11676 (infrun_thread_thread_exit): Consider target as well.
11677 (random_pending_event_thread): New inferior parameter. Use it.
11678 (do_target_wait): Rename to ...
11679 (do_target_wait_1): ... this. Add inferior parameter, and pass it
11680 down.
11681 (threads_are_resumed_pending_p, do_target_wait): New.
11682 (prepare_for_detach): Adjust calls.
11683 (wait_for_inferior): New inferior parameter. Handle it. Use
11684 do_target_wait_1 instead of do_target_wait.
11685 (fetch_inferior_event): Adjust. Switch to representative
11686 inferior. Pass target down.
11687 (set_last_target_status): Add process_stratum_target parameter.
11688 Save target in global.
11689 (get_last_target_status): Add process_stratum_target parameter and
11690 handle it.
11691 (nullify_last_target_wait_ptid): Clear 'target_last_proc_target'.
11692 (context_switch): Check inferior_ptid == null_ptid before calling
11693 inferior_thread().
11694 (get_inferior_stop_soon): Pass down target.
11695 (wait_one): Rename to ...
11696 (poll_one_curr_target): ... this.
11697 (struct wait_one_event): New.
11698 (wait_one): New.
11699 (stop_all_threads): Adjust.
11700 (handle_no_resumed, handle_inferior_event): Adjust to consider the
11701 event's target.
11702 (switch_back_to_stepped_thread): Also consider target.
11703 (print_stop_event): Update.
11704 (normal_stop): Update. Also consider the resume target.
11705 * infrun.h (wait_for_inferior): Remove declaration.
11706 (user_visible_resume_target): New declaration.
11707 (get_last_target_status, set_last_target_status): New
11708 process_stratum_target parameter.
11709 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
11710 process_stratum_target parameter, and use it.
11711 (clear_inline_frame_state (thread_info*)): New.
11712 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
11713 process_stratum_target parameter.
11714 (clear_inline_frame_state (thread_info*)): Declare.
11715 * linux-fork.c (delete_checkpoint_command): Pass target down to
11716 find_thread_ptid.
11717 (checkpoint_command): Adjust.
11718 * linux-nat.c (linux_nat_target::follow_fork): Switch to thread
11719 instead of just tweaking inferior_ptid.
11720 (linux_nat_switch_fork): Pass target down to thread_change_ptid.
11721 (exit_lwp): Pass target down to find_thread_ptid.
11722 (attach_proc_task_lwp_callback): Pass target down to
11723 add_thread/set_running/set_executing.
11724 (linux_nat_target::attach): Pass target down to
11725 thread_change_ptid.
11726 (get_detach_signal): Pass target down to find_thread_ptid.
11727 Consider last target status's target.
11728 (linux_resume_one_lwp_throw, resume_lwp)
11729 (linux_handle_syscall_trap, linux_handle_extended_wait, wait_lwp)
11730 (stop_wait_callback, save_stop_reason, linux_nat_filter_event)
11731 (linux_nat_wait_1, resume_stopped_resumed_lwps): Pass target down.
11732 (linux_nat_target::async_wait_fd): New.
11733 (linux_nat_stop_lwp, linux_nat_target::thread_address_space): Pass
11734 target down.
11735 * linux-nat.h (linux_nat_target::async_wait_fd): Declare.
11736 * linux-tdep.c (get_thread_arch_regcache): Pass target down.
11737 * linux-thread-db.c (struct thread_db_info::process_target): New
11738 field.
11739 (add_thread_db_info): Save target.
11740 (get_thread_db_info): New process_stratum_target parameter. Also
11741 match target.
11742 (delete_thread_db_info): New process_stratum_target parameter.
11743 Also match target.
11744 (thread_from_lwp): Adjust to pass down target.
11745 (thread_db_notice_clone): Pass down target.
11746 (check_thread_db_callback): Pass down target.
11747 (try_thread_db_load_1): Always push the thread_db target.
11748 (try_thread_db_load, record_thread): Pass target down.
11749 (thread_db_target::detach): Pass target down. Always unpush the
11750 thread_db target.
11751 (thread_db_target::wait, thread_db_target::mourn_inferior): Pass
11752 target down. Always unpush the thread_db target.
11753 (find_new_threads_callback, thread_db_find_new_threads_2)
11754 (thread_db_target::update_thread_list): Pass target down.
11755 (thread_db_target::pid_to_str): Pass current inferior down.
11756 (thread_db_target::get_thread_local_address): Pass target down.
11757 (thread_db_target::resume, maintenance_check_libthread_db): Pass
11758 target down.
11759 * nto-procfs.c (nto_procfs_target::update_thread_list): Adjust.
11760 * procfs.c (procfs_target::procfs_init_inferior): Declare.
11761 (proc_set_current_signal, do_attach, procfs_target::wait): Adjust.
11762 (procfs_init_inferior): Rename to ...
11763 (procfs_target::procfs_init_inferior): ... this and adjust.
11764 (procfs_target::create_inferior, procfs_notice_thread)
11765 (procfs_do_thread_registers): Adjust.
11766 * ppc-fbsd-tdep.c: Include "inferior.h".
11767 (ppcfbsd_get_thread_local_address): Pass down target.
11768 * proc-service.c (ps_xfer_memory): Switch current inferior and
11769 program space as well.
11770 (get_ps_regcache): Pass target down.
11771 * process-stratum-target.c
11772 (process_stratum_target::thread_address_space)
11773 (process_stratum_target::thread_architecture): Pass target down.
11774 * process-stratum-target.h
11775 (process_stratum_target::threads_executing): New field.
11776 (as_process_stratum_target): New.
11777 * ravenscar-thread.c
11778 (ravenscar_thread_target::update_inferior_ptid): Pass target down.
11779 (ravenscar_thread_target::wait, ravenscar_add_thread): Pass target
11780 down.
11781 * record-btrace.c (record_btrace_target::info_record): Adjust.
11782 (record_btrace_target::record_method)
11783 (record_btrace_target::record_is_replaying)
11784 (record_btrace_target::fetch_registers)
11785 (get_thread_current_frame_id, record_btrace_target::resume)
11786 (record_btrace_target::wait, record_btrace_target::stop): Pass
11787 target down.
11788 * record-full.c (record_full_wait_1): Switch to event thread.
11789 Pass target down.
11790 * regcache.c (regcache::regcache)
11791 (get_thread_arch_aspace_regcache, get_thread_arch_regcache): Add
11792 process_stratum_target parameter and handle it.
11793 (current_thread_target): New global.
11794 (get_thread_regcache): Add process_stratum_target parameter and
11795 handle it. Switch inferior before calling target method.
11796 (get_thread_regcache): Pass target down.
11797 (get_thread_regcache_for_ptid): Pass target down.
11798 (registers_changed_ptid): Add process_stratum_target parameter and
11799 handle it.
11800 (registers_changed_thread, registers_changed): Pass target down.
11801 (test_get_thread_arch_aspace_regcache): New.
11802 (current_regcache_test): Define a couple local test_target_ops
11803 instances and use them for testing.
11804 (readwrite_regcache): Pass process_stratum_target parameter.
11805 (cooked_read_test, cooked_write_test): Pass mock_target down.
11806 * regcache.h (get_thread_regcache, get_thread_arch_regcache)
11807 (get_thread_arch_aspace_regcache): Add process_stratum_target
11808 parameter.
11809 (regcache::target): New method.
11810 (regcache::regcache, regcache::get_thread_arch_aspace_regcache)
11811 (regcache::registers_changed_ptid): Add process_stratum_target
11812 parameter.
11813 (regcache::m_target): New field.
11814 (registers_changed_ptid): Add process_stratum_target parameter.
11815 * remote.c (remote_state::supports_vCont_probed): New field.
11816 (remote_target::async_wait_fd): New method.
11817 (remote_unpush_and_throw): Add remote_target parameter.
11818 (get_current_remote_target): Adjust.
11819 (remote_target::remote_add_inferior): Push target.
11820 (remote_target::remote_add_thread)
11821 (remote_target::remote_notice_new_inferior)
11822 (get_remote_thread_info): Pass target down.
11823 (remote_target::update_thread_list): Skip threads of inferiors
11824 bound to other targets. (remote_target::close): Don't discard
11825 inferiors. (remote_target::add_current_inferior_and_thread)
11826 (remote_target::process_initial_stop_replies)
11827 (remote_target::start_remote)
11828 (remote_target::remote_serial_quit_handler): Pass down target.
11829 (remote_target::remote_unpush_target): New remote_target
11830 parameter. Unpush the target from all inferiors.
11831 (remote_target::remote_unpush_and_throw): New remote_target
11832 parameter. Pass it down.
11833 (remote_target::open_1): Check whether the current inferior has
11834 execution instead of checking whether any inferior is live. Pass
11835 target down.
11836 (remote_target::remote_detach_1): Pass down target. Use
11837 remote_unpush_target.
11838 (extended_remote_target::attach): Pass down target.
11839 (remote_target::remote_vcont_probe): Set supports_vCont_probed.
11840 (remote_target::append_resumption): Pass down target.
11841 (remote_target::append_pending_thread_resumptions)
11842 (remote_target::remote_resume_with_hc, remote_target::resume)
11843 (remote_target::commit_resume): Pass down target.
11844 (remote_target::remote_stop_ns): Check supports_vCont_probed.
11845 (remote_target::interrupt_query)
11846 (remote_target::remove_new_fork_children)
11847 (remote_target::check_pending_events_prevent_wildcard_vcont)
11848 (remote_target::remote_parse_stop_reply)
11849 (remote_target::process_stop_reply): Pass down target.
11850 (first_remote_resumed_thread): New remote_target parameter. Pass
11851 it down.
11852 (remote_target::wait_as): Pass down target.
11853 (unpush_and_perror): New remote_target parameter. Pass it down.
11854 (remote_target::readchar, remote_target::remote_serial_write)
11855 (remote_target::getpkt_or_notif_sane_1)
11856 (remote_target::kill_new_fork_children, remote_target::kill): Pass
11857 down target.
11858 (remote_target::mourn_inferior): Pass down target. Use
11859 remote_unpush_target.
11860 (remote_target::core_of_thread)
11861 (remote_target::remote_btrace_maybe_reopen): Pass down target.
11862 (remote_target::pid_to_exec_file)
11863 (remote_target::thread_handle_to_thread_info): Pass down target.
11864 (remote_target::async_wait_fd): New.
11865 * riscv-fbsd-tdep.c: Include "inferior.h".
11866 (riscv_fbsd_get_thread_local_address): Pass down target.
11867 * sol2-tdep.c (sol2_core_pid_to_str): Pass down target.
11868 * sol-thread.c (sol_thread_target::wait, ps_lgetregs, ps_lsetregs)
11869 (ps_lgetfpregs, ps_lsetfpregs, sol_update_thread_list_callback):
11870 Adjust.
11871 * solib-spu.c (spu_skip_standalone_loader): Pass down target.
11872 * solib-svr4.c (enable_break): Pass down target.
11873 * spu-multiarch.c (parse_spufs_run): Pass down target.
11874 * spu-tdep.c (spu2ppu_sniffer): Pass down target.
11875 * target-delegates.c: Regenerate.
11876 * target.c (g_target_stack): Delete.
11877 (current_top_target): Return the current inferior's top target.
11878 (target_has_execution_1): Refer to the passed-in inferior's top
11879 target.
11880 (target_supports_terminal_ours): Check whether the initial
11881 inferior was already created.
11882 (decref_target): New.
11883 (target_stack::push): Incref/decref the target.
11884 (push_target, push_target, unpush_target): Adjust.
11885 (target_stack::unpush): Defref target.
11886 (target_is_pushed): Return bool. Adjust to refer to the current
11887 inferior's target stack.
11888 (dispose_inferior): Delete, and inline parts ...
11889 (target_preopen): ... here. Only dispose of the current inferior.
11890 (target_detach): Hold strong target reference while detaching.
11891 Pass target down.
11892 (target_thread_name): Add assertion.
11893 (target_resume): Pass down target.
11894 (target_ops::beneath, find_target_at): Adjust to refer to the
11895 current inferior's target stack.
11896 (get_dummy_target): New.
11897 (target_pass_ctrlc): Pass the Ctrl-C to the first inferior that
11898 has a thread running.
11899 (initialize_targets): Rename to ...
11900 (_initialize_target): ... this.
11901 * target.h: Include "gdbsupport/refcounted-object.h".
11902 (struct target_ops): Inherit refcounted_object.
11903 (target_ops::shortname, target_ops::longname): Make const.
11904 (target_ops::async_wait_fd): New method.
11905 (decref_target): Declare.
11906 (struct target_ops_ref_policy): New.
11907 (target_ops_ref): New typedef.
11908 (get_dummy_target): Declare function.
11909 (target_is_pushed): Return bool.
11910 * thread-iter.c (all_matching_threads_iterator::m_inf_matches)
11911 (all_matching_threads_iterator::all_matching_threads_iterator):
11912 Handle filter target.
11913 * thread-iter.h (struct all_matching_threads_iterator, struct
11914 all_matching_threads_range, class all_non_exited_threads_range):
11915 Filter by target too. Remove explicit.
11916 * thread.c (threads_executing): Delete.
11917 (inferior_thread): Pass down current inferior.
11918 (clear_thread_inferior_resources): Pass down thread pointer
11919 instead of ptid_t.
11920 (add_thread_silent, add_thread_with_info, add_thread): Add
11921 process_stratum_target parameter. Use it for thread and inferior
11922 searches.
11923 (is_current_thread): New.
11924 (thread_info::deletable): Use it.
11925 (find_thread_ptid, thread_count, in_thread_list)
11926 (thread_change_ptid, set_resumed, set_running): New
11927 process_stratum_target parameter. Pass it down.
11928 (set_executing): New process_stratum_target parameter. Pass it
11929 down. Adjust reference to 'threads_executing'.
11930 (threads_are_executing): New process_stratum_target parameter.
11931 Adjust reference to 'threads_executing'.
11932 (set_stop_requested, finish_thread_state): New
11933 process_stratum_target parameter. Pass it down.
11934 (switch_to_thread): Also match inferior.
11935 (switch_to_thread): New process_stratum_target parameter. Pass it
11936 down.
11937 (update_threads_executing): Reimplement.
11938 * top.c (quit_force): Pop targets from all inferior.
11939 (gdb_init): Don't call initialize_targets.
11940 * windows-nat.c (windows_nat_target) <get_windows_debug_event>:
11941 Declare.
11942 (windows_add_thread, windows_delete_thread): Adjust.
11943 (get_windows_debug_event): Rename to ...
11944 (windows_nat_target::get_windows_debug_event): ... this. Adjust.
11945 * tracefile-tfile.c (tfile_target_open): Pass down target.
11946 * gdbsupport/common-gdbthread.h (struct process_stratum_target):
11947 Forward declare.
11948 (switch_to_thread): Add process_stratum_target parameter.
11949 * mi/mi-interp.c (mi_on_resume_1): Add process_stratum_target
11950 parameter. Use it.
11951 (mi_on_resume): Pass target down.
11952 * nat/fork-inferior.c (startup_inferior): Add
11953 process_stratum_target parameter. Pass it down.
11954 * nat/fork-inferior.h (startup_inferior): Add
11955 process_stratum_target parameter.
11956 * python/py-threadevent.c (py_get_event_thread): Pass target down.
11957
11958 2020-01-10 Pedro Alves <palves@redhat.com>
11959
11960 * remote.c (remote_target::start_remote): Don't set inferior_ptid
11961 directly. Instead find the first thread in the thread list and
11962 use switch_to_thread.
11963
11964 2020-01-10 Pedro Alves <palves@redhat.com>
11965
11966 * remote.c (remote_target::remote_add_inferior): Don't bind a
11967 process to the current inferior if the current inferior is already
11968 bound to a process.
11969
11970 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
11971 Pedro Alves <palves@redhat.com>
11972
11973 * remote.c (remote_target::remote_parse_stop_reply) <W/X packets>:
11974 If no process is specified, return null_ptid instead of
11975 inferior_ptid.
11976 (remote_target::wait_as): Handle TARGET_WAITKIND_EXITED /
11977 TARGET_WAITKIND_SIGNALLED with no pid.
11978
11979 2020-01-10 Pedro Alves <palves@redhat.com>
11980
11981 * remote.c (first_remote_resumed_thread): New.
11982 (remote_target::wait_as): Use it as default event_ptid instead of
11983 inferior_ptid.
11984
11985 2020-01-10 Pedro Alves <palves@redhat.com>
11986
11987 * infrun.c (handle_no_resumed): Use all_non_exited_inferiors.
11988
11989 2020-01-10 Pedro Alves <palves@redhat.com>
11990
11991 * tracefile-tfile.c (tfile_target::close): Assert that trace_fd is
11992 not -1.
11993
11994 2020-01-10 Pedro Alves <palves@redhat.com>
11995
11996 * break-catch-sig.c (signal_catchpoint_print_it): Don't pass a
11997 ptid to get_last_target_status.
11998 * break-catch-syscall.c (print_it_catch_syscall): Don't pass a
11999 ptid to get_last_target_status.
12000 * infcmd.c (continue_command): Don't pass a target_waitstatus to
12001 get_last_target_status.
12002 (info_program_command): Don't pass a target_waitstatus to
12003 get_last_target_status.
12004 * infrun.c (init_wait_for_inferior): Use
12005 nullify_last_target_wait_ptid.
12006 (get_last_target_status): Handle nullptr arguments.
12007 (nullify_last_target_wait_ptid): Clear target_last_waitstatus.
12008 (print_stop_event): Don't pass a ptid to get_last_target_status.
12009 (normal_stop): Don't pass a ptid to get_last_target_status.
12010 * infrun.h (get_last_target_status, set_last_target_status): Move
12011 comments here and update.
12012 (nullify_last_target_wait_ptid): Declare.
12013 * linux-fork.c (fork_load_infrun_state): Remove local extern
12014 declaration of nullify_last_target_wait_ptid.
12015 * linux-nat.c (get_detach_signal): Don't pass a target_waitstatus
12016 to get_last_target_status.
12017
12018 2020-01-10 Pedro Alves <palves@redhat.com>
12019
12020 * gdbthread.h (scoped_restore_current_thread)
12021 <dont_restore, restore, m_dont_restore>: Declare.
12022 * thread.c (thread_alive): Add assertion. Return bool.
12023 (switch_to_thread_if_alive): New.
12024 (prune_threads): Switch inferior/thread.
12025 (print_thread_info_1): Switch thread before calling target methods.
12026 (scoped_restore_current_thread::restore): New, factored out from
12027 ...
12028 (scoped_restore_current_thread::~scoped_restore_current_thread):
12029 ... this.
12030 (scoped_restore_current_thread::scoped_restore_current_thread):
12031 Add assertion.
12032 (thread_apply_all_command, thread_select): Use
12033 switch_to_thread_if_alive.
12034 * infrun.c (proceed, restart_threads, handle_signal_stop)
12035 (switch_back_to_stepped_thread): Switch current thread before
12036 calling target methods.
12037
12038 2020-01-10 Pedro Alves <palves@redhat.com>
12039
12040 * inferior.c (switch_to_inferior_no_thread): New function,
12041 factored out from ...
12042 (inferior_command): ... here.
12043 * inferior.h (switch_to_inferior_no_thread): Declare.
12044 * mi/mi-main.c (run_one_inferior): Use
12045 switch_to_inferior_no_thread.
12046
12047 2020-01-10 Pedro Alves <palves@redhat.com>
12048
12049 * infcmd.c (kill_command): Remove dead code.
12050
12051 2020-01-10 Pedro Alves <palves@redhat.com>
12052
12053 * remote.c (remote_target::mourn_inferior): No longer check
12054 whether the target is running.
12055
12056 2020-01-10 Pedro Alves <palves@redhat.com>
12057
12058 * corelow.c (core_target::has_execution): Change parameter type to
12059 inferior pointer.
12060 * inferior.c (number_of_live_inferiors): Use
12061 inferior::has_execution instead of target_has_execution_1.
12062 * inferior.h (inferior::has_execution): New.
12063 * linux-thread-db.c (thread_db_target::update_thread_list): Use
12064 inferior::has_execution instead of target_has_execution_1.
12065 * process-stratum-target.c
12066 (process_stratum_target::has_execution): Change parameter type to
12067 inferior pointer. Check the inferior's PID instead of
12068 inferior_ptid.
12069 * process-stratum-target.h
12070 (process_stratum_target::has_execution): Change parameter type to
12071 inferior pointer.
12072 * record-full.c (record_full_core_target::has_execution): Change
12073 parameter type to inferior pointer.
12074 * target.c (target_has_execution_1): Change parameter type to
12075 inferior pointer.
12076 (target_has_execution_current): Adjust.
12077 * target.h (target_ops::has_execution): Change parameter type to
12078 inferior pointer.
12079 (target_has_execution_1): Change parameter type to inferior
12080 pointer. Change return type to bool.
12081 * tracefile.h (tracefile_target::has_execution): Change parameter
12082 type to inferior pointer.
12083
12084 2020-01-10 Pedro Alves <palves@redhat.com>
12085
12086 * exceptions.c (print_flush): Remove current_top_target() check.
12087
12088 2020-01-10 Pedro Alves <palves@redhat.com>
12089
12090 * remote.c (show_remote_exec_file): Show the current inferior's
12091 exec-file instead of the command variable's value.
12092
12093 2020-01-10 Pedro Alves <palves@redhat.com>
12094
12095 * record-full.c (record_full_resume_ptid): New global.
12096 (record_full_target::resume): Set it.
12097 (record_full_wait_1): Use record_full_resume_ptid instead of
12098 inferior_ptid.
12099
12100 2020-01-10 Pedro Alves <palves@redhat.com>
12101
12102 * gdbthread.h (scoped_restore_current_thread)
12103 <dont_restore, restore, m_dont_restore>: Declare.
12104 * thread.c (thread_alive): Add assertion. Return bool.
12105 (switch_to_thread_if_alive): New.
12106 (prune_threads): Switch inferior/thread.
12107 (print_thread_info_1): Switch thread before calling target methods.
12108 (scoped_restore_current_thread::restore): New, factored out from
12109 ...
12110 (scoped_restore_current_thread::~scoped_restore_current_thread):
12111 ... this.
12112 (scoped_restore_current_thread::scoped_restore_current_thread):
12113 Add assertion.
12114 (thread_apply_all_command, thread_select): Use
12115 switch_to_thread_if_alive.
12116
12117 2020-01-10 George Barrett <bob@bob131.so>
12118
12119 * stap-probe.c (stap_modify_semaphore): Don't check for null
12120 semaphores.
12121 (stap_probe::set_semaphore, stap_probe::clear_semaphore): Check
12122 for null semaphores.
12123
12124 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
12125
12126 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Update
12127 all source windows, and maintain horizontal scroll status while
12128 doing so.
12129
12130 2020-01-09 Tom Tromey <tom@tromey.com>
12131
12132 PR tui/18932:
12133 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Call
12134 update_source_window, not print_source_lines.
12135
12136 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
12137
12138 * tui/tui.c (tui_enable): Register tui hooks after calling
12139 tui_display_main.
12140
12141 2020-01-09 Christian Biesinger <cbiesinger@google.com>
12142
12143 * gdbsupport/common-defs.h: Don't define _FORTIFY_SOURCE on MinGW.
12144
12145 2020-01-08 Simon Marchi <simon.marchi@efficios.com>
12146
12147 * thread.c (print_thread_info_1): Fix indentation.
12148
12149 2020-01-09 Christian Biesinger <cbiesinger@google.com>
12150
12151 * symtab.c (general_symbol_info::compute_and_set_names): Move the
12152 unique_xmalloc_ptr outside the if to always free the demangled name.
12153
12154 2020-01-08 Tom Tromey <tromey@adacore.com>
12155
12156 * xcoffread.c (enter_line_range, read_xcoff_symtab)
12157 (process_xcoff_symbol, xcoff_symfile_offsets): Update.
12158 * symtab.h (MSYMBOL_VALUE_ADDRESS): Update.
12159 (struct section_offsets, ANOFFSET, SIZEOF_N_SECTION_OFFSETS):
12160 Remove.
12161 (section_offsets): New typedef.
12162 * symtab.c (fixup_section, get_msymbol_address): Update.
12163 * symmisc.c (dump_msymbols): Update.
12164 * symfile.h (relative_addr_info_to_section_offsets)
12165 (symfile_map_offsets_to_segments): Update.
12166 * symfile.c (build_section_addr_info_from_objfile)
12167 (init_objfile_sect_indices): Update.
12168 (struct place_section_arg): Change type of "offsets".
12169 (place_section): Update.
12170 (relative_addr_info_to_section_offsets): Change type of
12171 "section_offsets". Remove "num_sections" parameter.
12172 (default_symfile_offsets, syms_from_objfile_1)
12173 (set_objfile_default_section_offset): Update.
12174 (reread_symbols): No need to preserve section offsets by hand.
12175 (symfile_map_offsets_to_segments): Change type of "offsets".
12176 * stap-probe.c (relocate_address): Update.
12177 * stabsread.h (process_one_symbol): Update.
12178 * solib-target.c (struct lm_info_target) <offsets>: Change type.
12179 (solib_target_relocate_section_addresses): Update.
12180 * solib-svr4.c (enable_break, svr4_relocate_main_executable):
12181 Update.
12182 * solib-frv.c (frv_relocate_main_executable): Update.
12183 * solib-dsbt.c (dsbt_relocate_main_executable): Update.
12184 * solib-aix.c (solib_aix_get_section_offsets): Change return
12185 type.
12186 (solib_aix_solib_create_inferior_hook): Update.
12187 * remote.c (remote_target::get_offsets): Update.
12188 * psymtab.c (find_pc_sect_psymtab): Update.
12189 * psympriv.h (struct partial_symbol) <address, text_low,
12190 text_high>: Update.
12191 * objfiles.h (obj_section_offset): Update.
12192 (struct objfile) <section_offsets>: Change type.
12193 <num_sections>: Remove.
12194 (objfile_relocate): Update.
12195 * objfiles.c (entry_point_address_query): Update
12196 (relocate_one_symbol): Change type of "section_offsets".
12197 (objfile_relocate1, objfile_relocate1): Change type of
12198 "new_offsets".
12199 (objfile_rebase1): Update.
12200 * mipsread.c (mipscoff_symfile_read): Update.
12201 (read_alphacoff_dynamic_symtab): Remove "section_offsets"
12202 parameter.
12203 * mdebugread.c (parse_symbol): Change type of "section_offsets".
12204 (parse_external, psymtab_to_symtab_1): Update.
12205 * machoread.c (macho_symfile_offsets): Update.
12206 * ia64-tdep.c (ia64_find_unwind_table): Update.
12207 * hppa-tdep.c (read_unwind_info): Update.
12208 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Update.
12209 * dwarf2read.c (create_addrmap_from_index)
12210 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
12211 (process_psymtab_comp_unit_reader, add_partial_symbol)
12212 (add_partial_subprogram, process_full_comp_unit)
12213 (read_file_scope, read_func_scope, read_lexical_block_scope)
12214 (read_call_site_scope, dwarf2_rnglists_process)
12215 (dwarf2_ranges_process, dwarf2_ranges_read)
12216 (dwarf_decode_lines_1, var_decode_location, new_symbol)
12217 (dwarf2_fetch_die_loc_sect_off, dwarf2_per_cu_text_offset):
12218 Update.
12219 * dwarf2-frame.c (execute_cfa_program, dwarf2_frame_find_fde):
12220 Update.
12221 * dtrace-probe.c (dtrace_probe::get_relocated_address): Update.
12222 * dbxread.c (read_dbx_symtab, read_ofile_symtab): Update.
12223 (process_one_symbol): Change type of "section_offsets".
12224 * ctfread.c (get_objfile_text_range): Update.
12225 * coffread.c (coff_symtab_read, enter_linenos)
12226 (process_coff_symbol): Update.
12227 * coff-pe-read.c (add_pe_forwarded_sym): Update.
12228 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Update.
12229
12230 2020-01-08 Tom Tromey <tromey@adacore.com>
12231
12232 * dwarf2read.c (parse_macro_definition): Use std::string.
12233 (parse_macro_definition): Likewise.
12234
12235 2020-01-08 Tom Tromey <tromey@adacore.com>
12236
12237 * dwarf2read.c (abbrev_table_read_table): Use std::vector.
12238 (ATTR_ALLOC_CHUNK): Remove.
12239
12240 2020-01-08 Tom Tromey <tromey@adacore.com>
12241
12242 * dwarf2read.c (fixup_go_packaging): Use unique_xmalloc_ptr.
12243
12244 2020-01-08 Tom Tromey <tromey@adacore.com>
12245
12246 * dwarf2read.c (add_partial_symbol): Use unique_xmalloc_ptr.
12247 (dwarf2_compute_name, open_dwo_file): Likewise.
12248 (process_enumeration_scope): Use std::vector.
12249 (guess_partial_die_structure_name): Use unique_xmalloc_ptr.
12250 (partial_die_info::fixup, dwarf2_start_subfile)
12251 (guess_full_die_structure_name, dwarf2_name): Likewise.
12252 (determine_prefix): Update.
12253 (guess_full_die_structure_name): Make return type const.
12254 (partial_die_full_name): Return unique_xmalloc_ptr.
12255 (DW_FIELD_ALLOC_CHUNK): Remove.
12256
12257 2020-01-07 Tom Tromey <tromey@adacore.com>
12258
12259 PR build/24937:
12260 * stap-probe.c (class stap_static_probe_ops): Add constructor.
12261
12262 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
12263
12264 * cli/cli-style.c: Set cli_styling to 'true' in the Cygwin build.
12265
12266 2020-01-06 Andrew Burgess <andrew.burgess@embecosm.com>
12267
12268 * stack.c (print_frame_info): Move disassemble_next_line code
12269 inside source_print block.
12270
12271 2020-01-06 Eli Zaretskii <eliz@gnu.org>
12272
12273 * gdbsupport/gdb_wait.c: Include <signal.h> instead of
12274 gdb/signals.h, as we are now using native signal symbols.
12275
12276 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
12277
12278 * tui/tui-disasm.c (tui_disasm_window::addr_is_displayed): Avoid
12279 overflow by an early check of content vs threshold.
12280 * tui/tui-source.c (tui_source_window::line_is_displayed):
12281 Likewise.
12282
12283 2020-01-06 Eli Zaretskii <eliz@gnu.org>
12284
12285 * NEWS: Mention the recent fix of $_exitsignal on MS-Windows.
12286
12287 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
12288
12289 * coff-pe-read.c (read_pe_exported_syms): Don't try to read the
12290 export table if no section contains it's RVA.
12291
12292 2020-01-06 Eli Zaretskii <eliz@gnu.org>
12293
12294 * windows-tdep.c: Fix a typo in WINDOWS_SIGABRT.
12295
12296 2020-01-06 Hannes Domani <ssbssa@yahoo.de>
12297
12298 * source.c (print_source_lines_base): Set last_line_listed.
12299
12300 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
12301
12302 * tui/tui-disasm.c: Remove trailing spaces.
12303
12304 2020-01-06 Eli Zaretskii <eliz@gnu.org>
12305 Pedro Alves <palves@redhat.com>
12306
12307 * Makefile.in (COMMON_SFILES): Add gdbsupport/gdb_wait.c.
12308 * windows-tdep.c: New enumeration of WINDOWS_SIG* signals.
12309 (windows_gdb_signal_to_target): New function, uses the above
12310 enumeration to convert GDB internal signal codes to equivalent
12311 Windows codes.
12312 (windows_init_abi): Call set_gdbarch_gdb_signal_to_target.
12313 * windows-nat.c: Include "gdb_wait.h".
12314 (get_windows_debug_event): Extract the fatal exception from the
12315 exit status and convert to the equivalent Posix signal number.
12316 * cli/cli-cmds.c (exit_status_set_internal_vars): Account for the
12317 possibility that WTERMSIG returns GDB_SIGNAL_UNKNOWN.
12318 * gdbsupport/gdb_wait.c: New file, implements
12319 windows_status_to_termsig.
12320 * gdbsupport/gdb_wait.h (WIFEXITED, WIFSIGNALED, WEXITSTATUS)
12321 (WTERMSIG) [__MINGW32__]: Separate definitions for MinGW.
12322
12323 2020-01-05 Andrew Burgess <andrew.burgess@embecosm.com>
12324
12325 * tui/tui-layout.c (tui_add_win_to_layout): Use tui_set_layout not
12326 show_layout.
12327
12328 2020-01-05 Luis Machado <luis.machado@linaro.org>
12329
12330 * aarch64-linux-nat.c
12331 (aarch64_linux_nat_target::thread_architecture): Use bfd_arch_aarch64
12332 and bfd_mach_aarch64.
12333
12334 2020-01-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
12335
12336 * ui-file.c (stdio_file::can_emit_style_escape)
12337 (tee_file::can_emit_style_escape): Ensure style is used also on
12338 gdb_stderr when gdb_stderr is a tty supporting styling, similarly
12339 to gdb_stdout.
12340 * main.c (set_gdb_data_directory): Use file style to output the
12341 warning that the given pathname is not a directory.
12342 * top.c (show_history_filename, gdb_safe_append_history)
12343 (show_gdb_datadir): Use file style.
12344
12345 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
12346
12347 * solib-target.c (struct lm_info_target):
12348 Change offsets to be a unique_xmalloc_ptr.
12349 (solib_target_relocate_section_addresses): Update.
12350
12351 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
12352
12353 * windows-nat.c (windows_clear_solib): Free so_list linked list.
12354
12355 2020-01-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
12356
12357 * MAINTAINERS (Write After Approval): Add myself.
12358
12359 2020-01-02 Luis Machado <luis.machado@linaro.org>
12360
12361 * proc-service.c (get_ps_regcache): Remove reference to obsolete
12362 Cell BE architecture.
12363 * target.h (struct target_ops) <thread_architecture>: Likewise.
12364
12365 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
12366
12367 * Makefile.in: Use INSTALL_PROGRAM_ENV.
12368
12369 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
12370
12371 * MAINTAINERS (Write After Approval): Add myself.
12372
12373 2020-01-01 Joel Brobecker <brobecker@adacore.com>
12374
12375 * gdbarch.sh: Update copyright year range of generated files.
12376
12377 2020-01-01 Joel Brobecker <brobecker@adacore.com>
12378
12379 Update copyright year range in all GDB files.
12380
12381 2020-01-01 Joel Brobecker <brobecker@adacore.com>
12382
12383 * copyright.py: Convert to Python 3.
12384
12385 2020-01-01 Joel Brobecker <brobecker@adacore.com>
12386
12387 * copyright.py: Adapt after move of gnulib directory from gdb
12388 directory to toplevel directory.
12389
12390 2020-01-01 Joel Brobecker <brobecker@adacore.com>
12391
12392 * copyright.py (main): Exit if run from the wrong directory.
12393
12394 2020-01-01 Joel Brobecker <brobecker@adacore.com>
12395
12396 * top.c (print_gdb_version): Change copyright year to 2020.
12397
12398 2020-01-01 Joel Brobecker <brobecker@adacore.com>
12399
12400 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2019.
12401
12402 For older changes see ChangeLog-2019.
12403 \f
12404 Local Variables:
12405 mode: change-log
12406 left-margin: 8
12407 fill-column: 74
12408 version-control: never
12409 coding: utf-8
12410 End: