]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdb/ChangeLog
Automatic date update in version.in
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
56bcdbea
TT
12018-05-04 Tom Tromey <tom@tromey.com>
2
3 PR python/22730:
4 * NEWS: Mention gdb.execute change.
5 * gdbcmd.h (execute_control_command): Don't declare.
6 * python/python.c (execute_gdb_command): Use read_command_lines_1,
7 execute_control_commands, execute_control_commands_to_string.
8 * cli/cli-script.h (execute_control_commands)
9 (execute_control_commands_to_string): Declare.
10 (execute_control_command): Add from_tty parameter.
11 * cli/cli-script.c (execute_control_commands)
12 (execute_control_commands_to_string): New functions.
13 (execute_user_command): Use execute_control_commands.
14 (execute_control_command_1): Add "from_tty" parameter. Update.
15 (execute_control_command): Likewise.
16
a913fffb
TT
172018-05-04 Tom Tromey <tom@tromey.com>
18
19 PR python/22731:
20 * NEWS: Mention that breakpoint commands are writable.
21 * python/py-breakpoint.c (bppy_set_commands): New function.
22 (breakpoint_object_getset) <"commands">: Use it.
23
60b3cef2
TT
242018-05-04 Tom Tromey <tom@tromey.com>
25
26 * tracepoint.c (actions_command): Update.
27 * mi/mi-cmd-break.c (mi_command_line_array)
28 (mi_command_line_array_cnt, mi_command_line_array_ptr)
29 (mi_read_next_line): Remove.
30 (mi_cmd_break_commands): Update.
31 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
32 function_view.
33 * cli/cli-script.c (get_command_line): Update.
34 (process_next_line): Use function_view. Constify.
35 (recurse_read_control_structure, read_command_lines)
36 (read_command_lines_1): Change argument types to function_view.
37 (do_define_command, document_command): Update.
38 * breakpoint.h (check_tracepoint_command): Don't declare.
39 * breakpoint.c (check_tracepoint_command): Remove.
40 (commands_command_1, create_tracepoint_from_upload): Update.
41
7a2c85f2
TT
422018-05-04 Tom Tromey <tom@tromey.com>
43
44 PR gdb/11750:
45 * cli/cli-script.h (enum command_control_type) <define_control>:
46 New constant.
47 * cli/cli-script.c (multi_line_command_p): Handle define_control.
48 (build_command_line, execute_control_command_1)
49 (process_next_line): Likewise.
50 (do_define_command): New function, extracted from define_command.
51 (define_command): Use it.
52
295dc222
TT
532018-05-04 Tom Tromey <tom@tromey.com>
54
55 * tracepoint.c (actions_command): Update.
56 * cli/cli-script.h (read_command_lines): Update.
57 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
58 (MAX_TMPBUF): Remove define.
59 (define_command): Use string_printf.
60 (document_command): Likewise.
61 * breakpoint.c (commands_command_1): Update.
62
1263a9d5
TT
632018-05-04 Tom Tromey <tom@tromey.com>
64
65 * top.c (execute_command): Update.
66 * cli/cli-script.h (print_command_lines): Now varargs.
67 * cli/cli-script.c (print_command_lines): Now varargs.
68 (execute_control_command_1) <case while_control, case if_control>:
69 Update.
70
12973681
TT
712018-05-04 Tom Tromey <tom@tromey.com>
72
73 * tracepoint.c (all_tracepoint_actions): Rename from
74 all_tracepoint_actions_and_cleanup. Change return type.
75 (actions_command, encode_actions_1, encode_actions)
76 (trace_dump_actions, tdump_command): Update.
77 * remote.c (remote_download_command_source): Update.
78 * python/python.c (gdbpy_eval_from_control_command)
79 (python_command, python_interactive_command): Update.
80 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
81 * guile/guile.c (guile_command)
82 (gdbscm_eval_from_control_command, guile_command): Update.
83 * compile/compile.c (compile_code_command)
84 (compile_print_command, compile_to_object): Update.
85 * cli/cli-script.h (struct command_lines_deleter): New.
86 (counted_command_line): New typedef.
87 (struct command_line): Add constructor, destructor.
88 <body_list>: Remove.
89 <body_list_0, body_list_1>: New members.
90 (command_line_up): Remove typedef.
91 (read_command_lines, read_command_lines_1, get_command_line):
92 Update.
93 (copy_command_lines): Don't declare.
94 * cli/cli-script.c (build_command_line): Use "new".
95 (get_command_line): Return counted_command_line.
96 (print_command_lines, execute_user_command)
97 (execute_control_command_1, while_command, if_command): Update.
98 (realloc_body_list): Remove.
99 (process_next_line, recurse_read_control_structure): Update.
100 (read_command_lines, read_command_lines_1): Return counted_command_line.
101 (free_command_lines): Use "delete".
102 (copy_command_lines): Remove.
103 (define_command, document_command, show_user_1): Update.
104 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
105 a counted_command_line.
106 * breakpoint.h (counted_command_line): Remove typedef.
107 (breakpoint_set_commands): Update.
108 * breakpoint.c (check_no_tracepoint_commands)
109 (validate_commands_for_breakpoint): Update.
110 (breakpoint_set_commands): Change commands to be a
111 counted_command_line.
112 (commands_command_1, update_dprintf_command_list)
113 (create_tracepoint_from_upload): Update.
114
e2fc72e2
TT
1152018-05-04 Tom Tromey <tom@tromey.com>
116
117 * cli/cli-decode.h (cmd_list_element): New constructor.
118 (~cmd_list_element): New destructor.
119 (struct cmd_list_element): Add initializers.
120 * cli/cli-decode.c (do_add_cmd): Use "new".
121 (delete_cmd): Use "delete".
122
a3b60e45
JK
1232018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
124 Pedro Alves <palves@redhat.com>
125
126 PR breakpoints/19806 and support for PR external/20207.
127 * NEWS: Mention Aarch64 watchpoint improvements.
128 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
129 watchpoints and PR external/20207 watchpoints.
130 * nat/aarch64-linux-hw-point.c
131 (kernel_supports_any_contiguous_range): New.
132 (aarch64_watchpoint_offset): New.
133 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
134 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
135 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
136 (aarch64_align_watchpoint): New parameters aligned_offset_p and
137 next_addr_orig_p. Support PR external/20207 watchpoints.
138 (aarch64_downgrade_regs): New.
139 (aarch64_dr_state_insert_one_point): New parameters offset and
140 addr_orig.
141 (aarch64_dr_state_remove_one_point): Likewise.
142 (aarch64_handle_breakpoint): Update caller.
143 (aarch64_handle_aligned_watchpoint): Likewise.
144 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
145 aligned_offset.
146 (aarch64_linux_set_debug_regs): Remove const from state. Call
147 aarch64_downgrade_regs.
148 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
149 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
150 (DR_CONTROL_MASK): ... this.
151 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
152 (unsigned int aarch64_watchpoint_offset): New prototype.
153 (aarch64_linux_set_debug_regs): Remove const from state.
154 * utils.c (align_up, align_down): Move to ...
155 * common/common-utils.c (align_up, align_down): ... here.
156 * utils.h (align_up, align_down): Move to ...
157 * common/common-utils.h (align_up, align_down): ... here.
158
05bc7456
JB
1592018-05-04 Joel Brobecker <brobecker@adacore.com>
160
161 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
162 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
163 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
164 Re-implement to match the ABI as summarized in GCC's
165 gcc/config/sparc/sparc.c. All callers updated.
166 (sparc32_store_arguments): Remove assertion.
167
2f433492
TT
1682018-05-04 Tom Tromey <tom@tromey.com>
169
170 * printcmd.c: Don't include tui.h.
171 (decode_format): Use skip_spaces.
172
9be2ae8f
TT
1732018-05-04 Tom Tromey <tom@tromey.com>
174
175 PR gdb/22619:
176 * printcmd.c (last_count): New global.
177 (x_command): Use saved count when repeating.
178
f0b3976b
TT
1792018-05-04 Tom Tromey <tom@tromey.com>
180
181 * nto-procfs.c (do_closedir_cleanup): Remove.
182 (procfs_pidlist): Use gdb_dir_up.
183 * procfs.c (do_closedir_cleanup): Remove.
184 (proc_update_threads): Use gdb_dir_up.
185 * common/filestuff.h (struct gdb_dir_deleter): New.
186 (gdb_dir_up): New typedef.
187
862d101a
TT
1882018-05-04 Tom Tromey <tom@tromey.com>
189
190 * ada-lang.c (print_mention_exception): Use std::string.
191
cb7de75e
TT
1922018-05-04 Tom Tromey <tom@tromey.com>
193
194 * ada-lang.c (create_excep_cond_exprs): Update.
195 (ada_exception_catchpoint_cond_string): Use std::string.
196
49d83361
TT
1972018-05-04 Tom Tromey <tom@tromey.com>
198
199 * ada-lang.c (xget_renaming_scope): Return std::string.
200 (old_renaming_is_invisible): Update.
201
ade72a34
TT
2022018-05-04 Tom Tromey <tom@tromey.com>
203
204 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
205 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
206
2be4d7f0
UW
2072018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
208
209 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
210
69b6ecb0
TT
2112018-05-04 Tom Tromey <tom@tromey.com>
212
213 * remote.c (remote_query_supported_append): Change type.
214 (remote_check_symbols): Update.
215
bf27f0e2
PP
2162018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
217
218 PR gdb/11420
219 * configure.ac: Prepend libpython.
220 * python/python-config.py: Likewise.
221 * configure: Regenerate.
222
4ea17de8
SM
2232018-05-03 Simon Marchi <simon.marchi@ericsson.com>
224
225 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
226
bd732259
PA
2272018-05-03 Pedro Alves <palves@redhat.com>
228
229 * s390-linux-nat.c
230 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
231 override. Write 'true' instead of '1'.
232 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
233 declaration.
234
d9f719f1
PA
2352018-05-02 Pedro Alves <palves@redhat.com>
236
237 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
238 add_inf_child_target.
239 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
240 add_inf_child_target.
241 * aix-thread.c (aix_thread_target_info): New.
242 (aix_thread_target) <shortname, longname, doc>: Delete.
243 <info>: New.
244 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
245 add_inf_child_target.
246 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
247 add_inf_child_target.
248 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
249 add_inf_child_target.
250 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
251 add_inf_child_target.
252 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
253 add_inf_child_target.
254 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
255 add_inf_child_target.
256 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
257 add_inf_child_target.
258 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
259 add_inf_child_target.
260 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
261 add_inf_child_target.
262 * bfd-target.c (target_bfd_target_info): New.
263 (target_bfd) <shortname, longname, doc>: Delete.
264 <info>: New.
265 * bsd-kvm.c (bsd_kvm_target_info): New.
266 (bsd_kvm_target) <shortname, longname, doc>: Delete.
267 <info>: New.
268 (bsd_kvm_target::open): Rename to ...
269 (bsd_kvm_target_open): ... this. Adjust.
270 * bsd-uthread.c (bsd_uthread_target_info): New.
271 (bsd_uthread_target) <shortname, longname, doc>: Delete.
272 <info>: New.
273 * corefile.c (core_file_command): Adjust.
274 * corelow.c (core_target_info): New.
275 (core_target) <shortname, longname, doc>: Delete.
276 <info>: New.
277 (core_target::open): Rename to ...
278 (core_target_open): ... this. Adjust.
279 * ctf.c (ctf_target_info): New.
280 (ctf_target) <shortname, longname, doc>: Delete.
281 <info>: New.
282 (ctf_target::open): Rename to ...
283 (ctf_target_open): ... this.
284 (_initialize_ctf): Adjust.
285 * exec.c (exec_target_info): New.
286 (exec_target) <shortname, longname, doc>: Delete.
287 <info>: New.
288 (exec_target::open): Rename to ...
289 (exec_target_open): ... this.
290 * gdbcore.h (core_target_open): Declare.
291 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
292 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
293 add_inf_child_target.
294 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
295 add_inf_child_target.
296 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
297 add_inf_child_target.
298 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
299 add_inf_child_target.
300 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
301 add_inf_child_target.
302 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
303 add_inf_child_target.
304 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
305 add_inf_child_target.
306 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
307 add_inf_child_target.
308 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
309 add_inf_child_target.
310 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
311 add_inf_child_target.
312 * inf-child.c (inf_child_target_info): New.
313 (inf_child_target::info): New.
314 (inf_child_open_target): Remove 'target' parameter. Use
315 get_native_target instead.
316 (inf_child_target::open): Delete.
317 (add_inf_child_target): New.
318 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
319 Delete.
320 <info>: New.
321 (add_inf_child_target): Declare.
322 (inf_child_open_target): Declare.
323 * linux-thread-db.c (thread_db_target_info): New.
324 (thread_db_target) <shortname, longname, doc>: Delete.
325 <info>: New.
326 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
327 add_inf_child_target.
328 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
329 add_inf_child_target.
330 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
331 add_inf_child_target.
332 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
333 add_inf_child_target.
334 * make-target-delegates (print_class): Adjust.
335 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
336 add_inf_child_target.
337 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
338 add_inf_child_target.
339 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
340 add_inf_child_target.
341 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
342 add_inf_child_target.
343 * nto-procfs.c (nto_native_target_info): New.
344 (nto_procfs_target_native) <shortname, longname, doc>:
345 Delete.
346 <info>: New.
347 (nto_procfs_target_info): New.
348 (nto_procfs_target_procfs) <shortname, longname, doc>:
349 Delete.
350 <info>: New.
351 (init_procfs_targets): Adjust.
352 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
353 add_inf_child_target.
354 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
355 add_inf_child_target.
356 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
357 add_inf_child_target.
358 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
359 add_inf_child_target.
360 * ravenscar-thread.c (ravenscar_target_info): New.
361 (ravenscar_thread_target) <shortname, longname, doc>:
362 Delete.
363 <info>: New.
364 * record-btrace.c (record_btrace_target_info):
365 (record_btrace_target) <shortname, longname, doc>: Delete.
366 <info>: New.
367 (record_btrace_target::open): Rename to ...
368 (record_btrace_target_open): ... this. Adjust.
369 * record-full.c (record_longname, record_doc): New.
370 (record_full_base_target) <shortname, longname, doc>: Delete.
371 <info>: New.
372 (record_full_target_info): New.
373 (record_full_target): <shortname>: Delete.
374 <info>: New.
375 (record_full_core_open_1, record_full_open_1): Update comments.
376 (record_full_base_target::open): Rename to ...
377 (record_full_open): ... this.
378 (cmd_record_full_restore): Update.
379 (_initialize_record_full): Update.
380 * remote-sim.c (remote_sim_target_info): New.
381 (gdbsim_target) <shortname, longname, doc>: Delete.
382 <info>: New.
383 (gdbsim_target::open): Rename to ...
384 (gdbsim_target_open): ... this.
385 (_initialize_remote_sim): Adjust.
386 * remote.c (remote_doc): New.
387 (remote_target_info): New.
388 (remote_target) <shortname, longname, doc>: Delete.
389 <info>: New.
390 (extended_remote_target_info): New.
391 (extended_remote_target) <shortname, longname, doc>: Delete.
392 <info>: New.
393 (remote_target::open_1): Make static. Adjust.
394 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
395 * s390-linux-nat.c (_initialize_s390_nat): Use
396 add_inf_child_target.
397 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
398 add_inf_child_target.
399 * sol-thread.c (thread_db_target_info): New.
400 (sol_thread_target) <shortname, longname, doc>: Delete.
401 <info>: New.
402 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
403 add_inf_child_target.
404 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
405 add_inf_child_target.
406 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
407 add_inf_child_target.
408 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
409 add_inf_child_target.
410 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
411 add_inf_child_target.
412 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
413 add_inf_child_target.
414 * spu-linux-nat.c (_initialize_spu_nat): Use
415 add_inf_child_target.
416 * spu-multiarch.c (spu_multiarch_target_info): New.
417 (spu_multiarch_target) <shortname, longname, doc>: Delete.
418 <info>: New.
419 * target-delegates.c: Regenerate.
420 * target.c: Include <unordered_map>.
421 (target_ops_p): Delete.
422 (DEF_VEC_P(target_ops_p)): Delete.
423 (target_factories): New.
424 (test_target_info): New.
425 (test_target_ops::info): New.
426 (open_target): Adjust to use target_factories.
427 (add_target_with_completer): Rename to ...
428 (add_target): ... this. Change prototype. Register target_info
429 and open callback in target_factories. Register target_info in
430 command context instead of target_ops.
431 (add_target): Delete old implementation.
432 (add_deprecated_target_alias): Change prototype. Adjust.
433 (the_native_target): New.
434 (set_native_target, get_native_target): New.
435 (find_default_run_target): Use the_native_target.
436 (find_attach_target, find_run_target): Simplify.
437 (target_ops::open): Delete.
438 (dummy_target_info): New.
439 (dummy_target::shortname, dummy_target::longname)
440 (dummy_target::doc): Delete.
441 (dummy_target::info): New.
442 (debug_target::shortname, debug_target::longname)
443 (debug_target::doc): Delete.
444 (debug_target::info): New.
445 * target.h (struct target_info): New.
446 (target_ops::~target_ops): Add comment.
447 (target_ops::info): New.
448 (target_ops::shortname, target_ops::longname, target_ops::doc): No
449 longer virtual. Implement in terms of target_info.
450 (set_native_target, get_native_target): Declare.
451 (target_open_ftype): New.
452 (add_target, add_target_with_completer)
453 (add_deprecated_target_alias): Change prototype.
454 (test_target) <shortname, longname, doc>: Delete.
455 <info>: New.
456 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
457 add_inf_child_target.
458 * tracefile-tfile.c (tfile_target_info): New.
459 (tfile_target) <shortname, longname, doc>: Delete.
460 <info>: New.
461 (tfile_target::open): Rename to ...
462 (tfile_target_open): ... this.
463 (_initialize_tracefile_tfile): Adjust.
464 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
465 add_inf_child_target.
466 * windows-nat.c (_initialize_windows_nat): Use
467 add_inf_child_target.
468 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
469 add_inf_child_target.
470
135340af
PA
4712018-05-02 Pedro Alves <palves@redhat.com>
472
473 * linux-nat.h (linux_nat_target) <low_new_thread,
474 low_delete_thread, low_new_fork, low_forget_process,
475 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
476 New virtual methods.
477 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
478 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
479 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
480 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
481 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
482 Delete.
483 * linux-fork.c (delete_fork): Adjust to call low method.
484 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
485 (linux_nat_new_fork, linux_nat_forget_process_hook)
486 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
487 (linux_nat_status_is_event):
488 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
489 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
490 to call low method.
491 (sigtrap_is_event): Rename to ...
492 (linux_nat_target::low_status_is_event): ... this.
493 (linux_nat_set_status_is_event): Delete.
494 (save_stop_reason, linux_nat_wait_1)
495 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
496 low methods.
497 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
498 (linux_nat_set_new_fork, linux_nat_set_forget_process)
499 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
500 (linux_nat_set_prepare_to_resume): Delete.
501 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
502 low virtual methods.
503 * amd64-linux-nat.c: Likewise.
504 * arm-linux-nat.c: Likewise.
505 * i386-linux-nat.c: Likewise.
506 * ia64-linux-nat.c: Likewise.
507 * mips-linux-nat.c: Likewise.
508 * ppc-linux-nat.c: Likewise.
509 * s390-linux-nat.c: Likewise.
510 * sparc64-linux-nat.c: Likewise.
511 * x86-linux-nat.c: Likewise.
512 * x86-linux-nat.h: Include "nat/x86-linux.h".
513 (x86_linux_nat_target) <low_new_fork, low_forget_process,
514 low_prepare_to_resume, low_new_thread, low_delete_thread>:
515 Override methods.
516
57810aa7
PA
5172018-05-02 Pedro Alves <palves@redhat.com>
518
519 * target.h (target_ops)
520 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
521 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
522 stopped_by_watchpoint, have_continuable_watchpoint,
523 stopped_data_address, watchpoint_addr_within_range,
524 can_accel_watchpoint_condition, can_run, thread_alive,
525 has_all_memory, has_memory, has_stack, has_registers,
526 has_execution, can_async_p, is_async_p, supports_non_stop,
527 always_non_stop_p, can_execute_reverse, supports_multi_process,
528 supports_enable_disable_tracepoint,
529 supports_disable_randomization, supports_string_tracing,
530 supports_evaluation_of_breakpoint_conditions,
531 can_run_breakpoint_commands, filesystem_is_local,
532 can_download_tracepoint, get_trace_state_variable_value,
533 set_trace_notes, get_tib_address, use_agent, can_use_agent,
534 record_is_replaying, record_will_replay,
535 augmented_libraries_svr4_read>: Adjust to return bool.
536 * aarch64-linux-nat.c: All implementations adjusted.
537 * aix-thread.c: All implementations adjusted.
538 * arm-linux-nat.c: All implementations adjusted.
539 * breakpoint.c: All implementations adjusted.
540 * bsd-kvm.c: All implementations adjusted.
541 * bsd-uthread.c: All implementations adjusted.
542 * corelow.c: All implementations adjusted.
543 * ctf.c: All implementations adjusted.
544 * darwin-nat.c: All implementations adjusted.
545 * darwin-nat.h: All implementations adjusted.
546 * exec.c: All implementations adjusted.
547 * fbsd-nat.c: All implementations adjusted.
548 * fbsd-nat.h: All implementations adjusted.
549 * gnu-nat.c: All implementations adjusted.
550 * gnu-nat.h: All implementations adjusted.
551 * go32-nat.c: All implementations adjusted.
552 * ia64-linux-nat.c: All implementations adjusted.
553 * inf-child.c: All implementations adjusted.
554 * inf-child.h: All implementations adjusted.
555 * inf-ptrace.c: All implementations adjusted.
556 * inf-ptrace.h: All implementations adjusted.
557 * linux-nat.c: All implementations adjusted.
558 * linux-nat.h: All implementations adjusted.
559 * mips-linux-nat.c: All implementations adjusted.
560 * nto-procfs.c: All implementations adjusted.
561 * ppc-linux-nat.c: All implementations adjusted.
562 * procfs.c: All implementations adjusted.
563 * ravenscar-thread.c: All implementations adjusted.
564 * record-btrace.c: All implementations adjusted.
565 * record-full.c: All implementations adjusted.
566 * remote-sim.c: All implementations adjusted.
567 * remote.c: All implementations adjusted.
568 * s390-linux-nat.c: All implementations adjusted.
569 * sol-thread.c: All implementations adjusted.
570 * spu-multiarch.c: All implementations adjusted.
571 * target-delegates.c: All implementations adjusted.
572 * target.c: All implementations adjusted.
573 * target.h: All implementations adjusted.
574 * tracefile-tfile.c: All implementations adjusted.
575 * tracefile.c: All implementations adjusted.
576 * tracefile.h: All implementations adjusted.
577 * windows-nat.c: All implementations adjusted.
578 * x86-linux-nat.h: All implementations adjusted.
579 * x86-nat.h: All implementations adjusted.
580
ad6a4e2d
PA
5812018-05-02 Pedro Alves <palves@redhat.com>
582
583 * make-target-delegates (scan_target_h): Don't trim lines here.
584 Replace sequences of tabs and/or whitespace with a single
585 whitespace.
586 (top level, parsing methods): Trim each line before processing it
587 here.
588
f6ac5f3d
PA
5892018-05-02 Pedro Alves <palves@redhat.com>
590 John Baldwin <jhb@freebsd.org>
591
592 * target.h (enum strata) <debug_stratum>: New.
593 (struct target_ops) <all delegation methods>: Replace by C++
594 virtual methods, and drop "to_" prefix. All references updated
595 throughout.
596 <to_shortname, to_longname, to_doc, to_data,
597 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
598 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
599 virtual methods. All references updated throughout.
600 <can_attach, supports_terminal_ours, can_create_inferior,
601 get_thread_control_capabilities, attach_no_wait>: New
602 virtual methods.
603 <insert_breakpoint, remove_breakpoint>: Now
604 TARGET_DEFAULT_NORETURN methods.
605 <info_proc>: Now returns bool.
606 <to_magic>: Delete.
607 (OPS_MAGIC): Delete.
608 (current_target): Delete. All references replaced by references
609 to ...
610 (target_stack): ... this. New.
611 (target_shortname, target_longname): Adjust.
612 (target_can_run): Now a function declaration.
613 (default_child_has_all_memory, default_child_has_memory)
614 (default_child_has_stack, default_child_has_registers)
615 (default_child_has_execution): Remove target_ops parameter.
616 (complete_target_initialization): Delete.
617 (memory_breakpoint_target): New template class.
618 (test_target_ops): Refactor as a C++ class with virtual methods.
619 * make-target-delegates (NAME_PART): Tighten.
620 (POINTER_PART, CP_SYMBOL): New.
621 (SIMPLE_RETURN_PART): Reimplement.
622 (VEC_RETURN_PART): Expect less.
623 (RETURN_PART, VIRTUAL_PART): New.
624 (METHOD): Adjust to C++ virtual methods.
625 (scan_target_h): Remove reference to C99.
626 (dname): Output "target_ops::" prefix.
627 (write_function_header): Adjust to output a C++ class method.
628 (write_declaration): New.
629 (write_delegator): Adjust to output a C++ class method.
630 (tdname): Output "dummy_target::" prefix.
631 (write_tdefault, write_debugmethod): Adjust to output a C++ class
632 method.
633 (tdefault_names, debug_names): Delete.
634 (return_types, tdefaults, styles, argtypes_array): New.
635 (top level): All methods are delegators.
636 (print_class): New.
637 (top level): Print dummy_target and debug_target classes.
638 * target-delegates.c: Regenerate.
639 * target-debug.h (target_debug_print_enum_info_proc_what)
640 (target_debug_print_thread_control_capabilities)
641 (target_debug_print_thread_info_p): New.
642 * target.c (dummy_target): Delete.
643 (the_dummy_target, the_debug_target): New.
644 (target_stack): Now extern.
645 (set_targetdebug): Push/unpush debug target.
646 (default_child_has_all_memory, default_child_has_memory)
647 (default_child_has_stack, default_child_has_registers)
648 (default_child_has_execution): Remove target_ops parameter.
649 (complete_target_initialization): Delete.
650 (add_target_with_completer): No longer call
651 complete_target_initialization.
652 (target_supports_terminal_ours): Use regular delegation.
653 (update_current_target): Delete.
654 (push_target): No longer check magic number. Don't call
655 update_current_target.
656 (unpush_target): Don't call update_current_target.
657 (target_is_pushed): No longer check magic number.
658 (target_require_runnable): Skip for all stratums over
659 process_stratum.
660 (target_ops::info_proc): New.
661 (target_info_proc): Use find_target_at and
662 find_default_run_target.
663 (target_supports_disable_randomization): Use regular delegation.
664 (target_get_osdata): Use find_target_at.
665 (target_ops::open, target_ops::close, target_ops::can_attach)
666 (target_ops::attach, target_ops::can_create_inferior)
667 (target_ops::create_inferior, target_ops::can_run)
668 (target_can_run): New.
669 (default_fileio_target): Use regular delegation.
670 (target_ops::fileio_open, target_ops::fileio_pwrite)
671 (target_ops::fileio_pread, target_ops::fileio_fstat)
672 (target_ops::fileio_close, target_ops::fileio_unlink)
673 (target_ops::fileio_readlink): New.
674 (target_fileio_open_1, target_fileio_unlink)
675 (target_fileio_readlink): Always call the target method. Handle
676 FILEIO_ENOSYS.
677 (return_zero, return_zero_has_execution): Delete.
678 (init_dummy_target): Delete.
679 (dummy_target::dummy_target, dummy_target::shortname)
680 (dummy_target::longname, dummy_target::doc)
681 (debug_target::debug_target, debug_target::shortname)
682 (debug_target::longname, debug_target::doc): New.
683 (target_supports_delete_record): Use regular delegation.
684 (setup_target_debug): Delete.
685 (maintenance_print_target_stack): Skip debug_stratum.
686 (initialize_targets): Instantiate the_dummy_target and
687 the_debug_target.
688 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
689 use target_stack.
690 (target_auxv_search, fprint_target_auxv): Adjust.
691 (info_auxv_command): Adjust to use target_stack.
692 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
693 * exceptions.c (print_flush): Handle a NULL target_stack.
694 * regcache.c (target_ops_no_register): Refactor as class with
695 virtual methods.
696
697 * exec.c (exec_target): New class.
698 (exec_ops): Now an exec_target.
699 (exec_open, exec_close_1, exec_get_section_table)
700 (exec_xfer_partial, exec_files_info, exec_has_memory)
701 (exec_make_note_section): Refactor as exec_target methods.
702 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
703 Delete.
704 (exec_target::find_memory_regions): New.
705 (_initialize_exec): Don't call init_exec_ops.
706 * gdbcore.h (exec_file_clear): Delete.
707
708 * corefile.c (core_target): Delete.
709 (core_file_command): Adjust.
710 * corelow.c (core_target): New class.
711 (the_core_target): New.
712 (core_close): Remove target_ops parameter.
713 (core_close_cleanup): Adjust.
714 (core_target::close): New.
715 (core_open, core_detach, get_core_registers, core_files_info)
716 (core_xfer_partial, core_thread_alive, core_read_description)
717 (core_pid_to_str, core_thread_name, core_has_memory)
718 (core_has_stack, core_has_registers, core_info_proc): Rework as
719 core_target methods.
720 (ignore, core_remove_breakpoint, init_core_ops): Delete.
721 (_initialize_corelow): Initialize the_core_target.
722 * gdbcore.h (core_target): Delete.
723 (the_core_target): New.
724
725 * ctf.c: (ctf_target): New class.
726 (ctf_ops): Now a ctf_target.
727 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
728 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
729 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
730 methods.
731 (init_ctf_ops): Delete.
732 (_initialize_ctf): Don't call it.
733 * tracefile-tfile.c (tfile_target): New class.
734 (tfile_ops): Now a tfile_target.
735 (tfile_open, tfile_close, tfile_files_info)
736 (tfile_get_tracepoint_status, tfile_trace_find)
737 (tfile_fetch_registers, tfile_xfer_partial)
738 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
739 Refactor as tfile_target methods.
740 (tfile_xfer_partial_features): Remove target_ops parameter.
741 (init_tfile_ops): Delete.
742 (_initialize_tracefile_tfile): Don't call it.
743 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
744 (tracefile_has_stack, tracefile_has_registers)
745 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
746 tracefile_target methods.
747 (init_tracefile_ops): Delete.
748 (tracefile_target::tracefile_target): New.
749 * tracefile.h: Include "target.h".
750 (tracefile_target): New class.
751 (init_tracefile_ops): Delete.
752
753 * spu-multiarch.c (spu_multiarch_target): New class.
754 (spu_ops): Now a spu_multiarch_target.
755 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
756 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
757 (spu_search_memory, spu_mourn_inferior): Refactor as
758 spu_multiarch_target methods.
759 (init_spu_ops): Delete.
760 (_initialize_spu_multiarch): Remove references to init_spu_ops,
761 complete_target_initialization.
762
763 * ravenscar-thread.c (ravenscar_thread_target): New class.
764 (ravenscar_ops): Now a ravenscar_thread_target.
765 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
766 (ravenscar_thread_alive, ravenscar_pid_to_str)
767 (ravenscar_fetch_registers, ravenscar_store_registers)
768 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
769 (ravenscar_stopped_by_hw_breakpoint)
770 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
771 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
772 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
773 methods.
774 (init_ravenscar_thread_ops): Delete.
775 (_initialize_ravenscar): Remove references to
776 init_ravenscar_thread_ops and complete_target_initialization.
777
778 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
779 (bsd_uthread_target): New class.
780 (bsd_uthread_ops): Now a bsd_uthread_target.
781 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
782 (bsd_uthread_close, bsd_uthread_mourn_inferior)
783 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
784 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
785 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
786 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
787 (bsd_uthread_target): Delete function.
788 (_initialize_bsd_uthread): Remove reference to
789 complete_target_initialization.
790
791 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
792 (target_bfd): ... this new class.
793 (target_bfd_xfer_partial, target_bfd_get_section_table)
794 (target_bfd_close): Refactor as target_bfd methods.
795 (target_bfd::~target_bfd): New.
796 (target_bfd_reopen): Adjust.
797 (target_bfd::close): New.
798
799 * record-btrace.c (record_btrace_target): New class.
800 (record_btrace_ops): Now a record_btrace_target.
801 (record_btrace_open, record_btrace_stop_recording)
802 (record_btrace_disconnect, record_btrace_close)
803 (record_btrace_async, record_btrace_info)
804 (record_btrace_insn_history, record_btrace_insn_history_range)
805 (record_btrace_insn_history_from, record_btrace_call_history)
806 (record_btrace_call_history_range)
807 (record_btrace_call_history_from, record_btrace_record_method)
808 (record_btrace_is_replaying, record_btrace_will_replay)
809 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
810 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
811 (record_btrace_store_registers, record_btrace_prepare_to_store)
812 (record_btrace_to_get_unwinder)
813 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
814 (record_btrace_commit_resume, record_btrace_wait)
815 (record_btrace_stop, record_btrace_can_execute_reverse)
816 (record_btrace_stopped_by_sw_breakpoint)
817 (record_btrace_supports_stopped_by_sw_breakpoint)
818 (record_btrace_stopped_by_hw_breakpoint)
819 (record_btrace_supports_stopped_by_hw_breakpoint)
820 (record_btrace_update_thread_list, record_btrace_thread_alive)
821 (record_btrace_goto_begin, record_btrace_goto_end)
822 (record_btrace_goto, record_btrace_stop_replaying_all)
823 (record_btrace_execution_direction)
824 (record_btrace_prepare_to_generate_core)
825 (record_btrace_done_generating_core): Refactor as
826 record_btrace_target methods.
827 (init_record_btrace_ops): Delete.
828 (_initialize_record_btrace): Remove reference to
829 init_record_btrace_ops.
830 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
831 the execution_direction global.
832 (record_full_base_target, record_full_target)
833 (record_full_core_target): New classes.
834 (record_full_ops): Now a record_full_target.
835 (record_full_core_ops): Now a record_full_core_target.
836 (record_full_target::detach, record_full_target::disconnect)
837 (record_full_core_target::disconnect)
838 (record_full_target::mourn_inferior, record_full_target::kill):
839 New.
840 (record_full_open, record_full_close, record_full_async): Refactor
841 as methods of the record_full_base_target class.
842 (record_full_resume, record_full_commit_resume): Refactor
843 as methods of the record_full_target class.
844 (record_full_wait, record_full_stopped_by_watchpoint)
845 (record_full_stopped_data_address)
846 (record_full_stopped_by_sw_breakpoint)
847 (record_full_supports_stopped_by_sw_breakpoint)
848 (record_full_stopped_by_hw_breakpoint)
849 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
850 methods of the record_full_base_target class.
851 (record_full_store_registers, record_full_xfer_partial)
852 (record_full_insert_breakpoint, record_full_remove_breakpoint):
853 Refactor as methods of the record_full_target class.
854 (record_full_can_execute_reverse, record_full_get_bookmark)
855 (record_full_goto_bookmark, record_full_execution_direction)
856 (record_full_record_method, record_full_info, record_full_delete)
857 (record_full_is_replaying, record_full_will_replay)
858 (record_full_goto_begin, record_full_goto_end, record_full_goto)
859 (record_full_stop_replaying): Refactor as methods of the
860 record_full_base_target class.
861 (record_full_core_resume, record_full_core_kill)
862 (record_full_core_fetch_registers)
863 (record_full_core_prepare_to_store)
864 (record_full_core_store_registers, record_full_core_xfer_partial)
865 (record_full_core_insert_breakpoint)
866 (record_full_core_remove_breakpoint)
867 (record_full_core_has_execution): Refactor
868 as methods of the record_full_core_target class.
869 (record_full_base_target::supports_delete_record): New.
870 (init_record_full_ops): Delete.
871 (init_record_full_core_ops): Delete.
872 (record_full_save): Refactor as method of the
873 record_full_base_target class.
874 (_initialize_record_full): Remove references to
875 init_record_full_ops and init_record_full_core_ops.
876
877 * remote.c (remote_target, extended_remote_target): New classes.
878 (remote_ops): Now a remote_target.
879 (extended_remote_ops): Now an extended_remote_target.
880 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
881 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
882 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
883 (remote_pass_signals, remote_set_syscall_catchpoint)
884 (remote_program_signals, )
885 (remote_thread_always_alive): Remove target_ops parameter.
886 (remote_thread_alive, remote_thread_name)
887 (remote_update_thread_list, remote_threads_extra_info)
888 (remote_static_tracepoint_marker_at)
889 (remote_static_tracepoint_markers_by_strid)
890 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
891 (remote_open): Refactor as methods of remote_target.
892 (extended_remote_open, extended_remote_detach)
893 (extended_remote_attach, extended_remote_post_attach):
894 (extended_remote_supports_disable_randomization)
895 (extended_remote_create_inferior): : Refactor as method of
896 extended_remote_target.
897 (remote_set_permissions, remote_open_1, remote_detach)
898 (remote_follow_fork, remote_follow_exec, remote_disconnect)
899 (remote_resume, remote_commit_resume, remote_stop)
900 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
901 (remote_terminal_ours, remote_wait, remote_fetch_registers)
902 (remote_prepare_to_store, remote_store_registers)
903 (remote_flash_erase, remote_flash_done, remote_files_info)
904 (remote_kill, remote_mourn, remote_insert_breakpoint)
905 (remote_remove_breakpoint, remote_insert_watchpoint)
906 (remote_watchpoint_addr_within_range)
907 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
908 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
909 (remote_supports_stopped_by_sw_breakpoint)
910 (remote_stopped_by_hw_breakpoint)
911 (remote_supports_stopped_by_hw_breakpoint)
912 (remote_stopped_by_watchpoint, remote_stopped_data_address)
913 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
914 (remote_verify_memory): Refactor as methods of remote_target.
915 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
916 parameter.
917 (remote_xfer_partial, remote_get_memory_xfer_limit)
918 (remote_search_memory, remote_rcmd, remote_memory_map)
919 (remote_pid_to_str, remote_get_thread_local_address)
920 (remote_get_tib_address, remote_read_description): Refactor as
921 methods of remote_target.
922 (remote_target::fileio_open, remote_target::fileio_pwrite)
923 (remote_target::fileio_pread, remote_target::fileio_close): New.
924 (remote_hostio_readlink, remote_hostio_fstat)
925 (remote_filesystem_is_local, remote_can_execute_reverse)
926 (remote_supports_non_stop, remote_supports_disable_randomization)
927 (remote_supports_multi_process, remote_supports_cond_breakpoints)
928 (remote_supports_enable_disable_tracepoint)
929 (remote_supports_string_tracing)
930 (remote_can_run_breakpoint_commands, remote_trace_init)
931 (remote_download_tracepoint, remote_can_download_tracepoint)
932 (remote_download_trace_state_variable, remote_enable_tracepoint)
933 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
934 (remote_trace_start, remote_get_trace_status)
935 (remote_get_tracepoint_status, remote_trace_stop)
936 (remote_trace_find, remote_get_trace_state_variable_value)
937 (remote_save_trace_data, remote_get_raw_trace_data)
938 (remote_set_disconnected_tracing, remote_core_of_thread)
939 (remote_set_circular_trace_buffer, remote_traceframe_info)
940 (remote_get_min_fast_tracepoint_insn_len)
941 (remote_set_trace_buffer_size, remote_set_trace_notes)
942 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
943 (remote_disable_btrace, remote_teardown_btrace)
944 (remote_read_btrace, remote_btrace_conf)
945 (remote_augmented_libraries_svr4_read, remote_load)
946 (remote_pid_to_exec_file, remote_can_do_single_step)
947 (remote_execution_direction, remote_thread_handle_to_thread_info):
948 Refactor as methods of remote_target.
949 (init_remote_ops, init_extended_remote_ops): Delete.
950 (remote_can_async_p, remote_is_async_p, remote_async)
951 (remote_thread_events, remote_upload_tracepoints)
952 (remote_upload_trace_state_variables): Refactor as methods of
953 remote_target.
954 (_initialize_remote): Remove references to init_remote_ops and
955 init_extended_remote_ops.
956
957 * remote-sim.c (gdbsim_target): New class.
958 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
959 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
960 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
961 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
962 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
963 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
964 Refactor as methods of gdbsim_target.
965 (gdbsim_ops): Now a gdbsim_target.
966 (init_gdbsim_ops): Delete.
967 (gdbsim_cntrl_c): Adjust.
968 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
969
970 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
971 (the_amd64_linux_nat_target): New.
972 (amd64_linux_fetch_inferior_registers)
973 (amd64_linux_store_inferior_registers): Refactor as methods of
974 amd64_linux_nat_target.
975 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
976 * i386-linux-nat.c: Don't include "linux-nat.h".
977 (i386_linux_nat_target): New class.
978 (the_i386_linux_nat_target): New.
979 (i386_linux_fetch_inferior_registers)
980 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
981 as methods of i386_linux_nat_target.
982 (_initialize_i386_linux_nat): Adjust. Set linux_target.
983 * inf-child.c (inf_child_ops): Delete.
984 (inf_child_fetch_inferior_registers)
985 (inf_child_store_inferior_registers): Delete.
986 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
987 methods of inf_child_target.
988 (inf_child_target::supports_terminal_ours)
989 (inf_child_target::terminal_init)
990 (inf_child_target::terminal_inferior)
991 (inf_child_target::terminal_ours_for_output)
992 (inf_child_target::terminal_ours, inf_child_target::interrupt)
993 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
994 New.
995 (inf_child_open, inf_child_disconnect, inf_child_close)
996 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
997 (inf_child_post_startup_inferior, inf_child_can_run)
998 (inf_child_pid_to_exec_file): Refactor as methods of
999 inf_child_target.
1000 (inf_child_follow_fork): Delete.
1001 (inf_child_target::can_create_inferior)
1002 (inf_child_target::can_attach): New.
1003 (inf_child_target::has_all_memory, inf_child_target::has_memory)
1004 (inf_child_target::has_stack, inf_child_target::has_registers)
1005 (inf_child_target::has_execution): New.
1006 (inf_child_fileio_open, inf_child_fileio_pwrite)
1007 (inf_child_fileio_pread, inf_child_fileio_fstat)
1008 (inf_child_fileio_close, inf_child_fileio_unlink)
1009 (inf_child_fileio_readlink, inf_child_use_agent)
1010 (inf_child_can_use_agent): Refactor as methods of
1011 inf_child_target.
1012 (return_zero, inf_child_target): Delete.
1013 (inf_child_target::inf_child_target): New.
1014 * inf-child.h: Include "target.h".
1015 (inf_child_target): Delete function prototype.
1016 (inf_child_target): New class.
1017 (inf_child_open_target, inf_child_mourn_inferior)
1018 (inf_child_maybe_unpush_target): Delete.
1019 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
1020 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
1021 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
1022 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
1023 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
1024 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
1025 (inf_ptrace_wait, inf_ptrace_xfer_partial)
1026 (inf_ptrace_thread_alive, inf_ptrace_files_info)
1027 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
1028 methods of inf_ptrace_target.
1029 (inf_ptrace_target): Delete function.
1030 * inf-ptrace.h: Include "inf-child.h".
1031 (inf_ptrace_target): Delete function declaration.
1032 (inf_ptrace_target): New class.
1033 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
1034 * linux-nat.c (linux_target): New.
1035 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
1036 (linux_nat_target::~linux_nat_target): New.
1037 (linux_child_post_attach, linux_child_post_startup_inferior)
1038 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
1039 (linux_child_remove_fork_catchpoint)
1040 (linux_child_insert_vfork_catchpoint)
1041 (linux_child_remove_vfork_catchpoint)
1042 (linux_child_insert_exec_catchpoint)
1043 (linux_child_remove_exec_catchpoint)
1044 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
1045 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
1046 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
1047 (linux_nat_stopped_data_address)
1048 (linux_nat_stopped_by_sw_breakpoint)
1049 (linux_nat_supports_stopped_by_sw_breakpoint)
1050 (linux_nat_stopped_by_hw_breakpoint)
1051 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
1052 (linux_nat_kill, linux_nat_mourn_inferior)
1053 (linux_nat_xfer_partial, linux_nat_thread_alive)
1054 (linux_nat_update_thread_list, linux_nat_pid_to_str)
1055 (linux_nat_thread_name, linux_child_pid_to_exec_file)
1056 (linux_child_static_tracepoint_markers_by_strid)
1057 (linux_nat_is_async_p, linux_nat_can_async_p)
1058 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
1059 (linux_nat_supports_multi_process)
1060 (linux_nat_supports_disable_randomization, linux_nat_async)
1061 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
1062 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
1063 (linux_nat_fileio_open, linux_nat_fileio_readlink)
1064 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
1065 methods of linux_nat_target.
1066 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
1067 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
1068 parameter.
1069 (check_stopped_by_watchpoint): Adjust.
1070 (linux_xfer_partial): Delete.
1071 (linux_target_install_ops, linux_target, linux_nat_add_target):
1072 Delete.
1073 (linux_nat_target::linux_nat_target): New.
1074 * linux-nat.h: Include "inf-ptrace.h".
1075 (linux_nat_target): New.
1076 (linux_target, linux_target_install_ops, linux_nat_add_target):
1077 Delete function declarations.
1078 (linux_target): Declare global.
1079 * linux-thread-db.c (thread_db_target): New.
1080 (thread_db_target::thread_db_target): New.
1081 (thread_db_ops): Delete.
1082 (the_thread_db_target): New.
1083 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
1084 (thread_db_update_thread_list, thread_db_pid_to_str)
1085 (thread_db_extra_thread_info)
1086 (thread_db_thread_handle_to_thread_info)
1087 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
1088 (thread_db_resume): Refactor as methods of thread_db_target.
1089 (init_thread_db_ops): Delete.
1090 (_initialize_thread_db): Remove reference to init_thread_db_ops.
1091 * x86-linux-nat.c: Don't include "linux-nat.h".
1092 (super_post_startup_inferior): Delete.
1093 (x86_linux_nat_target::~x86_linux_nat_target): New.
1094 (x86_linux_child_post_startup_inferior)
1095 (x86_linux_read_description, x86_linux_enable_btrace)
1096 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
1097 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
1098 methods of x86_linux_nat_target.
1099 (x86_linux_create_target): Delete. Bits folded ...
1100 (x86_linux_add_target): ... here. Now takes a linux_nat_target
1101 pointer.
1102 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
1103 (x86_linux_nat_target): New class.
1104 (x86_linux_create_target): Delete.
1105 (x86_linux_add_target): Now takes a linux_nat_target pointer.
1106 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
1107 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
1108 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
1109 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
1110 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
1111 make extern.
1112 (x86_use_watchpoints): Delete.
1113 * x86-nat.h: Include "breakpoint.h" and "target.h".
1114 (x86_use_watchpoints): Delete.
1115 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
1116 (x86_stopped_by_watchpoint, x86_stopped_data_address)
1117 (x86_insert_watchpoint, x86_remove_watchpoint)
1118 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
1119 (x86_stopped_by_hw_breakpoint): New declarations.
1120 (x86_nat_target): New template class.
1121
1122 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
1123 (the_ppc_linux_nat_target): New.
1124 (ppc_linux_fetch_inferior_registers)
1125 (ppc_linux_can_use_hw_breakpoint)
1126 (ppc_linux_region_ok_for_hw_watchpoint)
1127 (ppc_linux_ranged_break_num_registers)
1128 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
1129 (ppc_linux_insert_mask_watchpoint)
1130 (ppc_linux_remove_mask_watchpoint)
1131 (ppc_linux_can_accel_watchpoint_condition)
1132 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
1133 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
1134 (ppc_linux_watchpoint_addr_within_range)
1135 (ppc_linux_masked_watch_num_registers)
1136 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
1137 (ppc_linux_read_description): Refactor as methods of
1138 ppc_linux_nat_target.
1139 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
1140
1141 * procfs.c (procfs_xfer_partial): Delete forward declaration.
1142 (procfs_target): New class.
1143 (the_procfs_target): New.
1144 (procfs_target): Delete function.
1145 (procfs_auxv_parse, procfs_attach, procfs_detach)
1146 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
1147 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
1148 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
1149 (procfs_create_inferior, procfs_update_thread_list)
1150 (procfs_thread_alive, procfs_pid_to_str)
1151 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
1152 (procfs_stopped_data_address, procfs_insert_watchpoint)
1153 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
1154 (proc_find_memory_regions, procfs_info_proc)
1155 (procfs_make_note_section): Refactor as methods of procfs_target.
1156 (_initialize_procfs): Adjust.
1157 * sol-thread.c (sol_thread_target): New class.
1158 (sol_thread_ops): Now a sol_thread_target.
1159 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
1160 (sol_thread_fetch_registers, sol_thread_store_registers)
1161 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
1162 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
1163 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
1164 (init_sol_thread_ops): Delete.
1165 (_initialize_sol_thread): Adjust. Remove references to
1166 init_sol_thread_ops and complete_target_initialization.
1167
1168 * windows-nat.c (windows_nat_target): New class.
1169 (windows_fetch_inferior_registers)
1170 (windows_store_inferior_registers, windows_resume, windows_wait)
1171 (windows_attach, windows_detach, windows_pid_to_exec_file)
1172 (windows_files_info, windows_create_inferior)
1173 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
1174 (windows_close, windows_pid_to_str, windows_xfer_partial)
1175 (windows_get_tib_address, windows_get_ada_task_ptid)
1176 (windows_thread_name, windows_thread_alive): Refactor as
1177 windows_nat_target methods.
1178 (do_initial_windows_stuff): Adjust.
1179 (windows_target): Delete function.
1180 (_initialize_windows_nat): Adjust.
1181
1182 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
1183 (darwin_mourn_inferior, darwin_kill_inferior)
1184 (darwin_create_inferior, darwin_attach, darwin_detach)
1185 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
1186 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
1187 (darwin_supports_multi_process): Refactor as darwin_nat_target
1188 methods.
1189 (darwin_resume_to, darwin_files_info): Delete.
1190 (_initialize_darwin_inferior): Rename to ...
1191 (_initialize_darwin_nat): ... this. Adjust to C++ification.
1192 * darwin-nat.h: Include "inf-child.h".
1193 (darwin_nat_target): New class.
1194 (darwin_complete_target): Delete.
1195 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
1196 (darwin_target): New.
1197 (i386_darwin_fetch_inferior_registers)
1198 (i386_darwin_store_inferior_registers): Refactor as methods of
1199 darwin_nat_target.
1200 (darwin_complete_target): Delete, with ...
1201 (_initialize_i386_darwin_nat): ... bits factored out here.
1202
1203 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
1204 (the_alpha_linux_nat_target): New.
1205 (alpha_linux_register_u_offset): Refactor as
1206 alpha_linux_nat_target method.
1207 (_initialize_alpha_linux_nat): Adjust.
1208 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
1209 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
1210 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
1211 methods of linux_nat_trad_target.
1212 (linux_trad_target): Delete.
1213 * linux-nat-trad.h (linux_trad_target): Delete function.
1214 (linux_nat_trad_target): New class.
1215 * mips-linux-nat.c (mips_linux_nat_target): New class.
1216 (super_fetch_registers, super_store_registers, super_close):
1217 Delete.
1218 (the_mips_linux_nat_target): New.
1219 (mips64_linux_regsets_fetch_registers)
1220 (mips64_linux_regsets_store_registers)
1221 (mips64_linux_fetch_registers, mips64_linux_store_registers)
1222 (mips_linux_register_u_offset, mips_linux_read_description)
1223 (mips_linux_can_use_hw_breakpoint)
1224 (mips_linux_stopped_by_watchpoint)
1225 (mips_linux_stopped_data_address)
1226 (mips_linux_region_ok_for_hw_watchpoint)
1227 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
1228 (mips_linux_close): Refactor as methods of mips_linux_nat.
1229 (_initialize_mips_linux_nat): Adjust to C++ification.
1230
1231 * aix-thread.c (aix_thread_target): New class.
1232 (aix_thread_ops): Now an aix_thread_target.
1233 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
1234 (aix_thread_fetch_registers, aix_thread_store_registers)
1235 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
1236 (aix_thread_thread_alive, aix_thread_pid_to_str)
1237 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
1238 Refactor as methods of aix_thread_target.
1239 (init_aix_thread_ops): Delete.
1240 (_initialize_aix_thread): Remove references to init_aix_thread_ops
1241 and complete_target_initialization.
1242 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
1243 (rs6000_nat_target): New class.
1244 (the_rs6000_nat_target): New.
1245 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
1246 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
1247 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
1248 (super_create_inferior): Delete.
1249 (_initialize_rs6000_nat): Adjust to C++ification.
1250
1251 * arm-linux-nat.c (arm_linux_nat_target): New class.
1252 (the_arm_linux_nat_target): New.
1253 (arm_linux_fetch_inferior_registers)
1254 (arm_linux_store_inferior_registers, arm_linux_read_description)
1255 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
1256 (arm_linux_remove_hw_breakpoint)
1257 (arm_linux_region_ok_for_hw_watchpoint)
1258 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
1259 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
1260 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
1261 arm_linux_nat_target.
1262 (_initialize_arm_linux_nat): Adjust to C++ification.
1263
1264 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
1265 (the_aarch64_linux_nat_target): New.
1266 (aarch64_linux_fetch_inferior_registers)
1267 (aarch64_linux_store_inferior_registers)
1268 (aarch64_linux_child_post_startup_inferior)
1269 (aarch64_linux_read_description)
1270 (aarch64_linux_can_use_hw_breakpoint)
1271 (aarch64_linux_insert_hw_breakpoint)
1272 (aarch64_linux_remove_hw_breakpoint)
1273 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
1274 (aarch64_linux_region_ok_for_hw_watchpoint)
1275 (aarch64_linux_stopped_data_address)
1276 (aarch64_linux_stopped_by_watchpoint)
1277 (aarch64_linux_watchpoint_addr_within_range)
1278 (aarch64_linux_can_do_single_step): Refactor as methods of
1279 aarch64_linux_nat_target.
1280 (super_post_startup_inferior): Delete.
1281 (_initialize_aarch64_linux_nat): Adjust to C++ification.
1282
1283 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
1284 (the_hppa_linux_nat_target): New.
1285 (hppa_linux_fetch_inferior_registers)
1286 (hppa_linux_store_inferior_registers): Refactor as methods of
1287 hppa_linux_nat_target.
1288 (_initialize_hppa_linux_nat): Adjust to C++ification.
1289
1290 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
1291 (the_ia64_linux_nat_target): New.
1292 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
1293 (ia64_linux_stopped_data_address)
1294 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
1295 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
1296 ia64_linux_nat_target methods.
1297 (super_xfer_partial): Delete.
1298 (_initialize_ia64_linux_nat): Adjust to C++ification.
1299
1300 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
1301 (the_m32r_linux_nat_target): New.
1302 (m32r_linux_fetch_inferior_registers)
1303 (m32r_linux_store_inferior_registers): Refactor as
1304 m32r_linux_nat_target methods.
1305 (_initialize_m32r_linux_nat): Adjust to C++ification.
1306
1307 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
1308 (the_m68k_linux_nat_target): New.
1309 (m68k_linux_fetch_inferior_registers)
1310 (m68k_linux_store_inferior_registers): Refactor as
1311 m68k_linux_nat_target methods.
1312 (_initialize_m68k_linux_nat): Adjust to C++ification.
1313
1314 * s390-linux-nat.c (s390_linux_nat_target): New class.
1315 (the_s390_linux_nat_target): New.
1316 (s390_linux_fetch_inferior_registers)
1317 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
1318 (s390_insert_watchpoint, s390_remove_watchpoint)
1319 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
1320 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
1321 (s390_auxv_parse, s390_read_description): Refactor as methods of
1322 s390_linux_nat_target.
1323 (_initialize_s390_nat): Adjust to C++ification.
1324
1325 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
1326 (the_sparc_linux_nat_target): New.
1327 (_initialize_sparc_linux_nat): Adjust to C++ification.
1328 * sparc-nat.c (sparc_fetch_inferior_registers)
1329 (sparc_store_inferior_registers): Remove target_ops parameter.
1330 * sparc-nat.h (sparc_fetch_inferior_registers)
1331 (sparc_store_inferior_registers): Remove target_ops parameter.
1332 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
1333 (the_sparc64_linux_nat_target): New.
1334 (_initialize_sparc64_linux_nat): Adjust to C++ification.
1335
1336 * spu-linux-nat.c (spu_linux_nat_target): New class.
1337 (the_spu_linux_nat_target): New.
1338 (spu_child_post_startup_inferior, spu_child_post_attach)
1339 (spu_child_wait, spu_fetch_inferior_registers)
1340 (spu_store_inferior_registers, spu_xfer_partial)
1341 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
1342 methods.
1343 (_initialize_spu_nat): Adjust to C++ification.
1344
1345 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
1346 (the_tilegx_linux_nat_target): New.
1347 (fetch_inferior_registers, store_inferior_registers):
1348 Refactor as methods.
1349 (_initialize_tile_linux_nat): Adjust to C++ification.
1350
1351 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
1352 (the_xtensa_linux_nat_target): New.
1353 (xtensa_linux_fetch_inferior_registers)
1354 (xtensa_linux_store_inferior_registers): Refactor as
1355 xtensa_linux_nat_target methods.
1356 (_initialize_xtensa_linux_nat): Adjust to C++ification.
1357
1358 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
1359 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
1360 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
1361 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
1362 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
1363 (fbsd_stopped_by_sw_breakpoint)
1364 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
1365 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
1366 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
1367 (fbsd_post_startup_inferior, fbsd_post_attach)
1368 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
1369 (fbsd_set_syscall_catchpoint)
1370 (super_xfer_partial, super_resume, super_wait)
1371 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
1372 (fbsd_handle_debug_trap): Remove target_ops parameter.
1373 (fbsd_nat_add_target): Delete.
1374 * fbsd-nat.h: Include "inf-ptrace.h".
1375 (fbsd_nat_add_target): Delete.
1376 (USE_SIGTRAP_SIGINFO): Define.
1377 (fbsd_nat_target): New class.
1378
1379 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
1380 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
1381 (amd64bsd_target): Delete.
1382 * amd64-bsd-nat.h: New file.
1383 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
1384 "x86-bsd-nat.h".
1385 (amd64_fbsd_nat_target): New class.
1386 (the_amd64_fbsd_nat_target): New.
1387 (amd64fbsd_read_description): Refactor as method of
1388 amd64_fbsd_nat_target.
1389 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
1390 (_initialize_amd64fbsd_nat): Adjust to C++ification.
1391 * amd64-nat.h (amd64bsd_target): Delete function declaration.
1392 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
1393 (i386bsd_store_inferior_registers): Remove target_ops parameter.
1394 (i386bsd_target): Delete.
1395 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
1396 (i386bsd_fetch_inferior_registers)
1397 (i386bsd_store_inferior_registers): Declare.
1398 (i386_bsd_nat_target): New class.
1399 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
1400 (the_i386_fbsd_nat_target): New.
1401 (i386fbsd_resume, i386fbsd_read_description): Refactor as
1402 i386_fbsd_nat_target methods.
1403 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
1404 (_initialize_i386fbsd_nat): Adjust to C++ification.
1405 * x86-bsd-nat.c (super_mourn_inferior): Delete.
1406 (x86bsd_mourn_inferior, x86bsd_target): Delete.
1407 (_initialize_x86_bsd_nat): Adjust to C++ification.
1408 * x86-bsd-nat.h: Include "x86-nat.h".
1409 (x86bsd_target): Delete declaration.
1410 (x86bsd_nat_target): New class.
1411
1412 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
1413 (the_aarch64_fbsd_nat_target): New.
1414 (aarch64_fbsd_fetch_inferior_registers)
1415 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
1416 aarch64_fbsd_nat_target.
1417 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
1418 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
1419 (the_alpha_bsd_nat_target): New.
1420 (alphabsd_fetch_inferior_registers)
1421 (alphabsd_store_inferior_registers): Refactor as
1422 alpha_bsd_nat_target methods.
1423 (_initialize_alphabsd_nat): Refactor as methods of
1424 alpha_bsd_nat_target.
1425 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
1426 (the_amd64_nbsd_nat_target): New.
1427 (_initialize_amd64nbsd_nat): Adjust to C++ification.
1428 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
1429 (the_amd64_obsd_nat_target): New.
1430 (_initialize_amd64obsd_nat): Adjust to C++ification.
1431 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
1432 (the_arm_fbsd_nat_target): New.
1433 (arm_fbsd_fetch_inferior_registers)
1434 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
1435 (_initialize_arm_fbsd_nat): Refactor as methods of
1436 arm_fbsd_nat_target.
1437 (_initialize_arm_fbsd_nat): Adjust to C++ification.
1438 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
1439 (the_arm_netbsd_nat_target): New.
1440 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
1441 arm_netbsd_nat_target.
1442 (_initialize_arm_netbsd_nat): Adjust to C++ification.
1443 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
1444 (the_hppa_nbsd_nat_target): New.
1445 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
1446 hppa_nbsd_nat_target methods.
1447 (_initialize_hppanbsd_nat): Adjust to C++ification.
1448 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
1449 (the_hppa_obsd_nat_target): New.
1450 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
1451 methods of hppa_obsd_nat_target.
1452 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
1453 add_target.
1454 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
1455 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
1456 add_target.
1457 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
1458 (_initialize_i386obsd_nat): Use add_target.
1459 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
1460 (the_m68k_bsd_nat_target): New.
1461 (m68kbsd_fetch_inferior_registers)
1462 (m68kbsd_store_inferior_registers): Refactor as methods of
1463 m68k_bsd_nat_target.
1464 (_initialize_m68kbsd_nat): Adjust to C++ification.
1465 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
1466 (the_mips_fbsd_nat_target): New.
1467 (mips_fbsd_fetch_inferior_registers)
1468 (mips_fbsd_store_inferior_registers): Refactor as methods of
1469 mips_fbsd_nat_target.
1470 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
1471 add_target.
1472 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
1473 (the_mips_nbsd_nat_target): New.
1474 (mipsnbsd_fetch_inferior_registers)
1475 (mipsnbsd_store_inferior_registers): Refactor as methods of
1476 mips_nbsd_nat_target.
1477 (_initialize_mipsnbsd_nat): Adjust to C++ification.
1478 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
1479 (the_mips64_obsd_nat_target): New.
1480 (mips64obsd_fetch_inferior_registers)
1481 (mips64obsd_store_inferior_registers): Refactor as methods of
1482 mips64_obsd_nat_target.
1483 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
1484 add_target.
1485 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
1486 nbsd_nat_target.
1487 * nbsd-nat.h: Include "inf-ptrace.h".
1488 (nbsd_nat_target): New class.
1489 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
1490 (obsd_wait): Refactor as methods of obsd_nat_target.
1491 (obsd_add_target): Delete.
1492 * obsd-nat.h: Include "inf-ptrace.h".
1493 (obsd_nat_target): New class.
1494 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
1495 (the_ppc_fbsd_nat_target): New.
1496 (ppcfbsd_fetch_inferior_registers)
1497 (ppcfbsd_store_inferior_registers): Refactor as methods of
1498 ppc_fbsd_nat_target.
1499 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
1500 add_target.
1501 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
1502 (the_ppc_nbsd_nat_target): New.
1503 (ppcnbsd_fetch_inferior_registers)
1504 (ppcnbsd_store_inferior_registers): Refactor as methods of
1505 ppc_nbsd_nat_target.
1506 (_initialize_ppcnbsd_nat): Adjust to C++ification.
1507 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
1508 (the_ppc_obsd_nat_target): New.
1509 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
1510 methods of ppc_obsd_nat_target.
1511 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
1512 add_target.
1513 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
1514 (the_sh_nbsd_nat_target): New.
1515 (shnbsd_fetch_inferior_registers)
1516 (shnbsd_store_inferior_registers): Refactor as methods of
1517 sh_nbsd_nat_target.
1518 (_initialize_shnbsd_nat): Adjust to C++ification.
1519 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
1520 (inf_ptrace_xfer_partial): Delete.
1521 (sparc_xfer_partial, sparc_target): Delete.
1522 * sparc-nat.h (sparc_fetch_inferior_registers)
1523 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
1524 (sparc_target): Delete function declaration.
1525 (sparc_target): New template class.
1526 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
1527 (_initialize_sparcnbsd_nat): Adjust to C++ification.
1528 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
1529 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
1530 add_target.
1531 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
1532 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
1533 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
1534 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
1535 add_target.
1536 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
1537 (the_vax_bsd_nat_target): New.
1538 (vaxbsd_fetch_inferior_registers)
1539 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
1540 methods.
1541 (_initialize_vaxbsd_nat): Adjust to C++ification.
1542
1543 * bsd-kvm.c (bsd_kvm_target): New class.
1544 (bsd_kvm_ops): Now a bsd_kvm_target.
1545 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
1546 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
1547 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
1548 bsd_kvm_target.
1549 (bsd_kvm_return_one): Delete.
1550 (bsd_kvm_add_target): Adjust to C++ification.
1551
1552 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
1553 (nto_procfs_target_procfs): New classes.
1554 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
1555 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
1556 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
1557 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
1558 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
1559 (procfs_remove_hw_breakpoint, procfs_resume)
1560 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
1561 (procfs_kill_inferior, procfs_store_registers)
1562 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
1563 as methods of nto_procfs_target.
1564 (nto_procfs_ops): Now an nto_procfs_target_procfs.
1565 (nto_native_ops): Delete.
1566 (procfs_open, procfs_native_open): Delete.
1567 (nto_native_ops): Now an nto_procfs_target_native.
1568 (init_procfs_targets): Adjust to C++ification.
1569 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
1570 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
1571 Refactor as methods of nto_procfs_target.
1572
1573 * go32-nat.c (go32_nat_target): New class.
1574 (the_go32_nat_target): New.
1575 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
1576 (go32_store_registers, go32_xfer_partial, go32_files_info)
1577 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
1578 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
1579 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
1580 (go32_pid_to_str): Refactor as methods of go32_nat_target.
1581 (go32_target): Delete.
1582 (_initialize_go32_nat): Adjust to C++ification.
1583
1584 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
1585 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
1586 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
1587 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
1588 gnu_nat_target.
1589 (gnu_target): Delete.
1590 * gnu-nat.h (gnu_target): Delete.
1591 (gnu_nat_target): New class.
1592 * i386-gnu-nat.c (gnu_base_target): New.
1593 (i386_gnu_nat_target): New class.
1594 (the_i386_gnu_nat_target): New.
1595 (_initialize_i386gnu_nat): Adjust to C++ification.
1596
3fffc070
PA
15972018-05-02 Pedro Alves <palves@redhat.com>
1598
1599 * bfd-target.c (target_bfd_xclose): Rename to ...
1600 (target_bfd_close): ... this.
1601 (target_bfd_reopen): Adjust.
1602 * target.c (target_close): Remove references to to_xclose.
1603 * target.h (target_ops::to_xclose): Delete.
1604 (target_ops::to_close): Update comments.
1605
6798487f
PA
16062018-05-02 Pedro Alves <palves@redhat.com>
1607
1608 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
1609 "linux-nat.h".
1610 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
1611 * inf-ptrace.c (inf_ptrace_register_u_offset)
1612 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
1613 (inf_ptrace_store_register, inf_ptrace_store_registers)
1614 (inf_ptrace_trad_target): Move to ...
1615 * linux-nat-trad.c: ... this new file.
1616 * linux-nat-trad.h: New file.
1617 * linux-nat.c (linux_target_install_ops): Make extern.
1618 (linux_trad_target): Delete.
1619 * linux-nat.h (linux_trad_target): Delete declaration.
1620 (linux_target_install_ops): Declare.
1621 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
1622 "linux-nat.h".
1623
c1955e17
PA
16242018-05-02 Pedro Alves <palves@redhat.com>
1625
1626 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
1627 procfs_target/add_target here.
1628 * procfs.c (procfs_target): Make static.
1629 (_initialize_procfs): Call add_target here.
1630 * procfs.h (struct target_ops): Remove forward declaration.
1631 (procfs_target): Remove declaration.
1632 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
1633
b5c8fcb1
PA
16342018-05-02 Pedro Alves <palves@redhat.com>
1635
1636 * procfs.c (procfs_stopped_by_watchpoint)
1637 (procfs_insert_watchpoint, procfs_remove_watchpoint)
1638 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
1639 Forward declare.
1640 (procfs_use_watchpoints): Delete, move contents...
1641 (procfs_target): ... here.
1642 * procfs.h (procfs_use_watchpoints): Delete declaration.
1643 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
1644 procfs_use_watchpoints.
1645 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
1646 procfs_use_watchpoints.
1647
0489430a
TT
16482018-05-02 Tom Tromey <tom@tromey.com>
1649
1650 PR python/20084:
1651 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
1652 and var_zuinteger_unlimited.
1653 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
1654 and PARAM_ZUINTEGER_UNLIMITED.
1655 (set_parameter_value): Handle var_zuinteger and
1656 var_zuinteger_unlimited.
1657 (add_setshow_generic): Likewise.
1658 (parmpy_init): Likewise.
1659
1632f8ba
DR
16602018-04-28 Dan Robertson <danlrobertson89@gmail.com>
1661
1662 PR rust/23124
1663 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
1664 pointer is not null before dereferencing it.
1665
76761936
TT
16662018-04-30 Tom Tromey <tom@tromey.com>
1667
1668 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
1669 is_mi_like_p.
1670
2d33446d
TT
16712018-04-30 Tom Tromey <tom@tromey.com>
1672
1673 * breakpoint.c (mention): Remove use of is_mi_like_p.
1674 (print_mention_ranged_breakpoint): Likewise.
1675 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
1676 of is_mi_like_p.
1677
f3c6abab
TT
16782018-04-30 Tom Tromey <tom@tromey.com>
1679
1680 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
1681
40c03530
TT
16822018-04-30 Tom Tromey <tom@tromey.com>
1683
1684 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
1685 (info_spu_event_command): Remove some uses of is_mi_like_p.
1686
2038b7fd
TT
16872018-04-30 Tom Tromey <tom@tromey.com>
1688
1689 * python/py-framefilter.c (py_print_single_arg)
1690 (enumerate_locals, py_print_args, py_print_frame): Remove some
1691 uses of is_mi_like_p.
1692
4904c3c6
TT
16932018-04-30 Tom Tromey <tom@tromey.com>
1694
1695 * ui-out.c: Update.
1696 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
1697 * ui-out.h (ui_out::is_mi_like_p): Now const.
1698 (ui_out::do_is_mi_like_p): Now const.
1699 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
1700
7c66fffc
TT
17012018-04-30 Tom Tromey <tom@tromey.com>
1702
1703 * varobj.c (varobj_set_visualizer): Use new_reference.
1704 * python/python.c (gdbpy_decode_line): Use new_reference.
1705 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
1706 new_reference.
1707
bbfa6f00
TT
17082018-04-30 Tom Tromey <tom@tromey.com>
1709
1710 * varobj.c (install_new_value): Use new_reference.
1711 * value.h (value_incref): Return void. Swap intro comment with
1712 value_decref.
1713 * value.c (set_value_parent): Use new_reference.
1714 (value_incref): Return void. Update intro comment.
1715 (release_value): Use new_reference.
1716 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
1717
1831a9f9
TT
17182018-04-30 Tom Tromey <tom@tromey.com>
1719
1720 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
1721 * gdb_bfd.h (new_bfd_ref): Remove.
1722 (gdb_bfd_open): Update comment.
1723 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
1724 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
1725 (gdb_bfd_fdopenr): Use new_reference.
1726 * exec.c (exec_file_attach): Use new_reference.
1727
7c1b5f3d
TT
17282018-04-30 Tom Tromey <tom@tromey.com>
1729
1730 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
1731 method.
1732
e11fb955
TT
17332018-04-30 Tom Tromey <tom@tromey.com>
1734
1735 * jit.c (jit_read_code_entry): Use type_align.
1736 * i386-tdep.c (i386_gdbarch_init): Don't call
1737 set_gdbarch_long_long_align_bit.
1738 * gdbarch.sh: Remove long_long_align_bit.
1739 * gdbarch.c, gdbarch.h: Rebuild.
1740 * arc-tdep.c (arc_type_align): New function.
1741 (arc_gdbarch_init): Use arc_type_align. Don't call
1742 set_gdbarch_long_long_align_bit.
1743
2fff16dd
TT
17442018-04-30 Tom Tromey <tom@tromey.com>
1745
1746 * rust-lang.c (rust_type_alignment): Remove.
1747 (rust_composite_type): Use type_align.
1748
6d7bb824
TT
17492018-04-30 Tom Tromey <tom@tromey.com>
1750
1751 * NEWS: Mention Type.align.
1752 * python/py-type.c (typy_get_alignof): New function.
1753 (type_object_getset): Add "alignof".
1754
007e1530
TT
17552018-04-30 Tom Tromey <tom@tromey.com>
1756
1757 PR exp/17095:
1758 * NEWS: Update.
1759 * std-operator.def (UNOP_ALIGNOF): New operator.
1760 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
1761 New.
1762 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
1763 * c-lang.c (c_op_print_tab): Add alignof.
1764 * c-exp.y (ALIGNOF): New token.
1765 (exp): Add "ALIGNOF" production.
1766 (ident_tokens): Add _Alignof and alignof.
1767
2b4424c3
TT
17682018-04-30 Tom Tromey <tom@tromey.com>
1769
1770 * i386-tdep.c (i386_type_align): New function.
1771 (i386_gdbarch_init): Update.
1772 * gdbarch.sh (type_align): New method.
1773 * gdbarch.c, gdbarch.h: Rebuild.
1774 * arch-utils.h (default_type_align): Declare.
1775 * arch-utils.c (default_type_align): New function.
1776 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
1777 (struct type) <align_log2>: New field.
1778 <instance_flags>: Now a bitfield.
1779 (TYPE_RAW_ALIGN): New macro.
1780 (type_align, type_raw_align, set_type_align): Declare.
1781 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
1782 functions.
1783 * dwarf2read.c (quirk_rust_enum): Set type alignment.
1784 (get_alignment, maybe_set_alignment): New functions.
1785 (read_structure_type, read_enumeration_type, read_array_type)
1786 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
1787 (read_subrange_type, read_base_type): Set type alignment.
1788
d33bc52e
SM
17892018-04-30 Simon Marchi <simon.marchi@ericsson.com>
1790
1791 * dwarf2read.c (read_index_from_section): Use bool.
1792
e28b63a9
FG
17932018-04-29 Fabian Groffen <grobian@gentoo.org>
1794
1795 PR gdb/22950
1796 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
1797 with #ifdef.
1798
cd8c76e4
JR
17992018-04-29 John Reiser <jreiser@BitWagon.com>
1800
1801 PR build/22873
1802 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
1803 last step, and do it atomically.
1804
476d250e
AO
18052018-04-27 Alexandre Oliva <aoliva@redhat.com>
1806
1807 * compile/compile-c-types.c (convert_int, convert_float):
1808 Update for C FE v1.
1809
6873858b
TT
18102018-04-27 Tom Tromey <tom@tromey.com>
1811
1812 PR rust/22545:
1813 * rust-lang.c (rust_inclusive_range_type_p): New function.
1814 (rust_range): Handle inclusive ranges.
1815 (rust_compute_range): Likewise.
1816 * rust-exp.y (struct rust_op) <inclusive>: New field.
1817 (DOTDOTEQ): New constant.
1818 (range_expr): Add "..=" productions.
1819 (operator_tokens): Add "..=" token.
1820 (ast_range): Add "inclusive" parameter.
1821 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
1822 ranges.
1823 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
1824 bounds values.
1825 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
1826 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
1827 Update comments.
1828 * expprint.c (print_subexp_standard): Handle new bounds values.
1829 (dump_subexp_body_standard): Likewise.
1830
632e107b
TT
18312018-04-27 Tom Tromey <tom@tromey.com>
1832
1833 * configure: Rebuild.
1834 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
1835 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
1836 "OVERRIDE".
1837 (class symbol_needs_eval_context): Likewise.
1838 * dwarf2read.c (mock_mapped_index::symbol_name_count)
1839 (mock_mapped_index::symbol_name_at): Use "override". Remove
1840 "virtual".
1841 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
1842 "override".
1843 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
1844 * aarch64-tdep.c (instruction_reader::read): Use "override".
1845 (instruction_reader_test::read): Likewise.
1846 * arm-tdep.c (instruction_reader::read): Use "override".
1847 (instruction_reader_thumb::read): Likewise.
1848
b75abf5b
AK
18492018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
1850
1851 PR remote/9665
1852 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
1853 instead of remote_send.
1854 (remote_send): Remove.
1855
79188d8d
PA
18562018-04-26 Pedro Alves <palves@redhat.com>
1857
1858 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
1859 find_function_start_sal instead of find_pc_line.
1860
f50776aa
PA
18612018-04-26 Pedro Alves <palves@redhat.com>
1862
1863 * breakpoint.c (set_breakpoint_location_function): Handle
1864 mst_data_gnu_ifunc.
1865 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
1866 * elfread.c (elf_symtab_read): Give data symbols with
1867 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
1868 (elf_rel_plt_read): Update comment.
1869 * linespec.c (convert_linespec_to_sals): Handle
1870 mst_data_gnu_ifunc.
1871 (minsym_found): Handle mst_data_gnu_ifunc.
1872 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
1873 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
1874 * parse.c (find_minsym_type_and_address): Handle
1875 mst_data_gnu_ifunc.
1876 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
1877 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
1878 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
1879 comment.
1880 <mst_data_gnu_ifunc>: New enumerator.
1881
20944a6e
PA
18822018-04-26 Pedro Alves <palves@redhat.com>
1883
1884 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
1885 (lookup_minimal_symbol_by_pc_section): ... this. Replace
1886 'want_trampoline' parameter by a lookup_msym_prefer parameter.
1887 Handle it.
1888 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
1889 (lookup_minimal_symbol_by_pc): Adjust.
1890 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
1891 (lookup_solib_trampoline_symbol_by_pc): Adjust.
1892 * minsyms.h (lookup_msym_prefer): New enum.
1893 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
1894 parameter by a lookup_msym_prefer parameter.
1895
1adeb822
PA
18962018-04-26 Pedro Alves <palves@redhat.com>
1897
1898 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
1899 ends in "@plt" instead of looking at the symbol's section.
1900
a0aca7b0
PA
19012018-04-26 Pedro Alves <palves@redhat.com>
1902
1903 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
1904 all references.
1905 (find_pc_partial_function_gnu_ifunc): Rename to ...
1906 (find_pc_partial_function): ... this, and remove references to
1907 'is_gnu_ifunc_p'.
1908 (find_pc_partial_function): Delete old implementation.
1909 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
1910
76af0f26
PA
19112018-04-26 Pedro Alves <palves@redhat.com>
1912
1913 * linespec.c (struct bound_minimal_symbol_search_key): New.
1914 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
1915 skip first line if we found a GNU ifunc minimal symbol by name.
1916 (compare_msymbols): Change parameters to work with a destructured
1917 lhs minsym.
1918 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
1919 functions.
1920
3467ec66
PA
19212018-04-26 Pedro Alves <palves@redhat.com>
1922
1923 * breakpoint.c (set_breakpoint_location_function): Don't resolve
1924 ifunc targets here. Instead, if we have an ifunc minsym, use its
1925 address/name.
1926 (add_location_to_breakpoint): Store the minsym and the objfile in
1927 the breakpoint location.
1928 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
1929 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
1930 Record the minsym in the sal.
1931 * symtab.h (symtab_and_line) <msymbol>: New field.
1932
28f4fa4d
PA
19332018-04-26 Pedro Alves <palves@redhat.com>
1934
1935 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
1936 unless we actually resolved the ifunc.
1937
ca31ab1d
PA
19382018-04-26 Pedro Alves <palves@redhat.com>
1939
1940 * c-exp.y (variable production): Prefer ifunc minsyms over
1941 regular function symbols.
1942 * symtab.c (find_gnu_ifunc): New function.
1943 * minsyms.h (lookup_msym_prefer): New enum.
1944 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
1945 parameter by a lookup_msym_prefer parameter.
1946 * symtab.h (find_gnu_ifunc): New declaration.
1947
8388016d
PA
19482018-04-26 Pedro Alves <palves@redhat.com>
1949
1950 * blockframe.c (find_gnu_ifunc_target_type): New function.
1951 (find_function_type): New.
1952 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
1953 return a value with a memory address.
1954 (eval_call): For calls to GNU ifunc functions, try to find the
1955 type of the target function from the type that the resolver
1956 returns.
1957 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
1958 symbols.
1959 * infcall.c (find_function_return_type): Delete.
1960 (find_function_addr): Add 'function_type' parameter. For calls to
1961 GNU ifunc functions, try to find the type of the target function
1962 from the type that the resolver returns, and return it via
1963 FUNCTION_TYPE.
1964 (call_function_by_hand_dummy): Adjust to use the function type
1965 returned by find_function_addr.
1966 (find_function_addr): Add 'function_type' parameter and move
1967 description here.
1968 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
1969 declarations.
1970
a376e11d
PA
19712018-04-26 Pedro Alves <palves@redhat.com>
1972
1973 * c-exp.y (variable production): Skip finding an alias for ifunc
1974 symbols.
1975
02e169e2
PA
19762018-04-26 Pedro Alves <palves@redhat.com>
1977
1978 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
1979
249b5733
PA
19802018-04-25 Pedro Alves <palves@redhat.com>
1981
1982 * infcmd.c (kill_command): Print the pid as string, not the whole
1983 thread's ptid. Add comment. s/has been killed/killed/ in output
1984 message.
1985 * remote.c (remote_detach_1): Print the pid as string, not the
1986 whole thread's ptid.
1987
f67c0c91
SDJ
19882018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
1989 Sergio Durigan Junior <sergiodj@redhat.com>
1990 Pedro Alves <palves@redhat.com>
1991
1992 * infcmd.c (kill_command): Print message when inferior has
1993 been killed.
1994 * inferior.c (print_inferior_events): Remove 'static'. Set as
1995 '1'.
1996 (add_inferior): Improve message printed when
1997 'print_inferior_events' is on.
1998 (exit_inferior): Remove message printed when
1999 'print_inferior_events' is on.
2000 (detach_inferior): Improve message printed when
2001 'print_inferior_events' is on.
2002 (initialize_inferiors): Use 'add_inferior_silent' to set
2003 'current_inferior_'.
2004 * inferior.h (print_inferior_events): Declare here as
2005 'extern'.
2006 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
2007 '[Detaching...]' messages when 'print_inferior_events' is on.
2008 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
2009 as prefix/suffix for messages. Remove periods. Fix erroneous
2010 'Detaching after fork from child...', replace it by '... from
2011 parent...'.
2012 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
2013 prefix/suffix when printing 'Detaching...' messages. Print
2014 them when 'print_inferior_events' is on.
2015 * remote.c (remote_detach_1): Print message when detaching
2016 from inferior and '!is_fork_parent'.
2017
e427af18
TT
20182018-04-24 Tom Tromey <tom@tromey.com>
2019
2020 * cli-out.h: Reindent.
2021
05b1d8d6
TT
20222018-04-24 Tom Tromey <tom@tromey.com>
2023
2024 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
2025 (cli_ui_out::do_field_string): Use fputs_filtered.
2026 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
2027
a95c7dab
TT
20282018-04-23 Tom Tromey <tom@tromey.com>
2029
2030 * guile/scm-frame.c (gdbscm_frame_read_var): Use
2031 gdb::unique_xmalloc_ptr.
2032
458412c3
TT
20332018-04-23 Tom Tromey <tom@tromey.com>
2034
2035 * configure: Rebuild.
2036
db86b02b
RS
20372018-04-22 Rajendra SY <rajendra.sy@gmail.com>
2038
2039 PR gdb/23095
2040 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
2041 prepare_for_testing. Set normal_bp to r_debug_state if target
2042 is bsd.
2043
00aecdcf
PA
20442018-04-21 Pedro Alves <palves@redhat.com>
2045 Rajendra SY <rajendra.sy@gmail.com>
2046
2047 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
2048 * remote.c (extended_remote_attach): In all-stop mode, mark the
2049 thread as executing.
2050
224608c3
PW
20512018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2052
2053 * thread.c (thread_apply_all_command): Fix comment.
2054 (thread_command): Fix comment.
2055
3b74854b
AH
20562018-04-10 Alan Hayward <alan.hayward@arm.com>
2057
2058 * common/tdesc.h (tdesc_create_feature): Remove xml filename
2059 parameter.
2060 * features/aarch64-core.c (create_feature_aarch64_core):
2061 Regenerate.
2062 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
2063 Likewise.
2064 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
2065 Likewise.
2066 * features/i386/32bit-avx512.c
2067 (create_feature_i386_32bit_avx512): Likewise.
2068 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
2069 Likewise.
2070 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
2071 Likewise.
2072 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
2073 Likewise.
2074 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
2075 Likewise.
2076 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
2077 Likewise.
2078 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
2079 Likewise.
2080 * features/i386/64bit-avx512.c
2081 (create_feature_i386_64bit_avx512): Likewise.
2082 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
2083 Likewise.
2084 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
2085 Likewise.
2086 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
2087 Likewise.
2088 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
2089 Likewise.
2090 * features/i386/64bit-segments.c
2091 (create_feature_i386_64bit_segments): Likewise.
2092 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
2093 Likewise.
2094 * features/i386/x32-core.c
2095 (create_feature_i386_x32_core): Likewise.
2096 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
2097 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
2098 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
2099 * target-descriptions.c: In generated code, don't pass xml
2100 filename.
2101
e98577a9
AH
21022018-04-18 Alan Hayward <alan.hayward@arm.com>
2103
2104 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
2105 (print_xml_feature::visit_post): Likewise.
2106 (print_xml_feature::visit): Likewise.
2107 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
2108 (print_xml_feature): Add new class.
2109 * regformats/regdat.sh: Null xmltarget on feature targets.
2110 * target-descriptions.c (struct target_desc): Add xmltarget.
2111 (maintenance_check_tdesc_xml_convert): Add unittest function.
2112 (tdesc_get_features_xml): Add function to get xml.
2113 (maintenance_check_xml_descriptions): Test xml generation.
2114 * xml-tdesc.c (string_read_description_xml): Add function.
2115 * xml-tdesc.h (string_read_description_xml): Add declaration.
2116
ad7fc756
AH
21172018-04-18 Alan Hayward <alan.hayward@arm.com>
2118
2119 * features/Makefile: Add feature marker to targets with new style
2120 target descriptions.
2121 * regformats/aarch64.dat: Regenerate.
2122 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
2123 * regformats/i386/amd64-avx-linux.dat: Likewise.
2124 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
2125 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
2126 * regformats/i386/amd64-linux.dat: Likewise.
2127 * regformats/i386/amd64-mpx-linux.dat: Likewise.
2128 * regformats/i386/amd64.dat: Likewise.
2129 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
2130 * regformats/i386/i386-avx-linux.dat: Likewise.
2131 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
2132 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
2133 * regformats/i386/i386-linux.dat: Likewise.
2134 * regformats/i386/i386-mmx-linux.dat: Likewise.
2135 * regformats/i386/i386-mpx-linux.dat: Likewise.
2136 * regformats/i386/i386.dat: Likewise.
2137 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
2138 * regformats/i386/x32-avx-linux.dat: Likewise.
2139 * regformats/i386/x32-linux.dat: Likewise.
2140 * regformats/tic6x-c62x-linux.dat: Likewise.
2141 * regformats/tic6x-c64x-linux.dat: Likewise.
2142 * regformats/tic6x-c64xp-linux.dat: Likewise.
2143 * regformats/regdat.sh: Parse feature marker.
2144
d278f585
AH
21452018-04-18 Alan Hayward <alan.hayward@arm.com>
2146
2147 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
2148 (tdesc_osabi_name): Likewise.
2149 * target-descriptions.c (tdesc_architecture_name): Add new
2150 function.
2151 (tdesc_osabi_name): Likewise.
2152
eee8a18d
AH
21532018-04-18 Alan Hayward <alan.hayward@arm.com>
2154
2155 * common/tdesc.c (tdesc_predefined_type): Move to here.
2156 (tdesc_named_type): Likewise.
2157 (tdesc_create_vector): Likewise.
2158 (tdesc_create_struct): Likewise.
2159 (tdesc_set_struct_size): Likewise.
2160 (tdesc_create_union): Likewise.
2161 (tdesc_create_flags): Likewise.
2162 (tdesc_create_enum): Likewise.
2163 (tdesc_add_field): Likewise.
2164 (tdesc_add_typed_bitfield): Likewise.
2165 (tdesc_add_bitfield): Likewise.
2166 (tdesc_add_flag): Likewise.
2167 (tdesc_add_enum_value): Likewise.
2168 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
2169 (struct tdesc_type_vector): Likewise.
2170 (struct tdesc_type_field): Likewise.
2171 (struct tdesc_type_with_fields): Likewise.
2172 (tdesc_create_enum): Add declaration.
2173 (tdesc_add_typed_bitfield): Likewise.
2174 (tdesc_add_enum_value): Likewise.
2175 * target-descriptions.c (tdesc_type_field): Move from here.
2176 (tdesc_type_builtin): Likewise.
2177 (tdesc_type_vector): Likewise.
2178 (tdesc_type_with_fields): Likewise.
2179 (tdesc_predefined_types): Likewise.
2180 (tdesc_named_type): Likewise.
2181 (tdesc_create_vector): Likewise.
2182 (tdesc_create_struct): Likewise.
2183 (tdesc_set_struct_size): Likewise.
2184 (tdesc_create_union): Likewise.
2185 (tdesc_create_flags): Likewise.
2186 (tdesc_create_enum): Likewise.
2187 (tdesc_add_field): Likewise.
2188 (tdesc_add_typed_bitfield): Likewise.
2189 (tdesc_add_bitfield): Likewise.
2190 (tdesc_add_flag): Likewise.
2191 (tdesc_add_enum_value): Likewise.
2192 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
2193 (tdesc_add_typed_bitfield): Likewise.
2194 (tdesc_add_enum_value): Likewise.
2195
82ec9bc7
AH
21962018-04-18 Alan Hayward <alan.hayward@arm.com>
2197
2198 * common/tdesc.c (tdesc_feature::accept): Move to here.
2199 (tdesc_feature::operator==): Likewise.
2200 (tdesc_create_reg): Likewise.
2201 * common/tdesc.h (tdesc_type_kind): Likewise.
2202 (struct tdesc_type): Likewise.
2203 (struct tdesc_feature): Likewise.
2204 * regformats/regdat.sh: Create a feature.
2205 * target-descriptions.c (tdesc_type_kind): Move from here.
2206 (tdesc_type): Likewise.
2207 (tdesc_type_up): Likewise.
2208 (tdesc_feature): Likewise.
2209 (tdesc_create_reg): Likewise.
2210
ea3e7d71
AH
22112018-04-18 Alan Hayward <alan.hayward@arm.com>
2212
2213 * Makefile.in: Add arch/tdesc.c
2214 * common/tdesc.c: New file.
2215 * common/tdesc.h (tdesc_element_visitor): Move to here.
2216 (tdesc_element): Likewise.
2217 (tdesc_reg): Likewise.
2218 (tdesc_reg_up): Likewise.
2219 * regformats/regdef.h (reg): Add offset to constructors.
2220 * target-descriptions.c (tdesc_element_visitor): Move from here.
2221 (tdesc_element): Likewise.
2222 (tdesc_reg): Likewise.
2223 (tdesc_reg_up): Likewise.
2224
bedda9ac
TT
22252018-04-17 Tom Tromey <tom@tromey.com>
2226
2227 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
2228 discriminant field.
2229
a037790e
TT
22302018-04-17 Tom Tromey <tom@tromey.com>
2231
2232 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
2233
c7dcbf88
AA
22342018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
2235
2236 * symtab.c (print_symbol_info): Skip printing filename and line
2237 number when `last' is NULL.
2238 (symtab_symbol_info): Use empty string instead of NULL for first
2239 invocation of print_symbol_info.
2240 (rbreak_command): Pass NULL to `last' parameter of
2241 print_symbol_info.
2242
07d28c77
SM
22432018-04-16 Simon Marchi <simon.marchi@ericsson.com>
2244
2245 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
2246 instead of nullptr.
2247
8a3de5e1
PA
22482018-04-16 Pedro Alves <palves@redhat.com>
2249
2250 * MAINTAINERS (sh): Remove.
2251 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
2252 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
2253 (ALLDEPFILES): Remove sh64-tdep.c.
2254 * NEWS: Mentions that support for SH-5/SH64 is removed.
2255 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
2256 (sh*-*-openbsd*): Ditto.
2257 (sh64-*-elf*): Remove.
2258 (sh*): Remove.
2259 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
2260 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
2261 * sh-tdep.c: No longer include "sh64-tdep.h".
2262 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
2263 * sh64-tdep.c, sh64-tdep.h: Remove files.
2264
a2a79012
PA
22652018-04-16 Pedro Alves <palves@redhat.com>
2266
2267 * MAINTAINERS: Remove m88k.
2268 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
2269 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
2270 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
2271 * NEWS: Mention that support for m88k was removed.
2272 * configure.host (m88*-*-*): Remove support.
2273 * configure.nat (m88k-*-*): Remove support.
2274 * configure.tgt (m88*-*-openbsd*): Remove.
2275 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
2276
eda4efb1
SM
22772018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
2278
2279 * configure.tgt (x86_tobjs): New variable.
2280 (amd64_tobjs, i386_tobjs): Use it.
2281
b744723f
AA
22822018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
2283
2284 * symtab.c (print_symbol_info): Precede the symbol definition by
2285 the line number when available.
2286 * NEWS: Advertise this enhancement.
2287
4a4495d6
MM
22882018-04-13 Markus Metzger <markus.t.metzger@intel.com>
2289
2290 * NEWS (New options): announce set/show record btrace cpu.
2291 * btrace.c: Include record-btrace.h.
2292 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
2293 the vendor is unknown.
2294 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
2295 Maybe overwrite the btrace configuration's cpu.
2296 (btrace_compute_ftrace): Add cpu parameter. Update callers.
2297 (btrace_fetch): Add cpu parameter. Update callers.
2298 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
2299 Maybe overwrite the btrace configuration's cpu. Skip enabling
2300 errata workarounds if the vendor is unknown.
2301 * python/py-record-btrace.c: Include record-btrace.h.
2302 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
2303 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
2304 * record-btrace.c (record_btrace_cpu_state_kind): New.
2305 (record_btrace_cpu): New.
2306 (set_record_btrace_cpu_cmdlist): New.
2307 (record_btrace_get_cpu): New.
2308 (require_btrace_thread, record_btrace_info)
2309 (record_btrace_resume_thread): Call record_btrace_get_cpu.
2310 (cmd_set_record_btrace_cpu_none): New.
2311 (cmd_set_record_btrace_cpu_auto): New.
2312 (cmd_set_record_btrace_cpu): New.
2313 (cmd_show_record_btrace_cpu): New.
2314 (_initialize_record_btrace): Initialize set/show record btrace cpu
2315 commands.
2316 * record-btrace.h (record_btrace_get_cpu): New.
2317
69f90c75
MM
23182018-04-13 Markus Metzger <markus.t.metzger@intel.com>
2319
2320 * record.c (set_record_command): Fix typo in message.
2321
b85310e1
MM
23222018-04-13 Markus Metzger <markus.t.metzger@intel.com>
2323
2324 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
2325
1d509aa6
MM
23262018-04-13 Markus Metzger <markus.t.metzger@intel.com>
2327
2328 * infrun.c (process_event_stop_test): Call
2329 gdbarch_in_indirect_branch_thunk.
2330 * gdbarch.sh (in_indirect_branch_thunk): New.
2331 * gdbarch.c: Regenerated.
2332 * gdbarch.h: Regenerated.
2333 * x86-tdep.h: New.
2334 * x86-tdep.c: New.
2335 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
2336 (HFILES_NO_SRCDIR): Add x86-tdep.h.
2337 (ALLDEPFILES): Add x86-tdep.c.
2338 * arch-utils.h (default_in_indirect_branch_thunk): New.
2339 * arch-utils.c (default_in_indirect_branch_thunk): New.
2340 * i386-tdep: Include x86-tdep.h.
2341 (i386_in_indirect_branch_thunk): New.
2342 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
2343 function.
2344 * amd64-tdep: Include x86-tdep.h.
2345 (amd64_in_indirect_branch_thunk): New.
2346 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
2347
b4be9bfd
JK
23482018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
2349
2350 PR gdb/23053
2351 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
2352 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
2353 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
2354 regression.
2355
53d7df28
TT
23562018-04-12 Tom Tromey <tom@tromey.com>
2357
2358 * rust-lang.c (rust_print_struct_def): Remove univariant code.
2359 (rust_evaluate_subexp): Likewise.
2360
70b33f19
PA
23612018-04-12 Pedro Alves <palves@redhat.com>
2362
2363 * procfs.c (procfs_detach): Make forward declaration's prototype
2364 match definition's protototype.
2365 (proc_get_LDT_entry): Remove stale do_cleanups call.
2366
436411b1
PA
23672018-04-12 Pedro Alves <palves@redhat.com>
2368
2369 * target.h (target_ops::to_has_exited): Delete.
2370 (target_has_exited): Delete.
2371 * target-delegates.c: Regenerate.
2372
20db9c52
PA
23732018-04-11 Pedro Alves <palves@redhat.com>
2374
2375 * target.c (fileio_fh_t::t): Add comment.
2376 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
2377 (target_fileio_close): Handle a NULL target.
2378 (invalidate_fileio_fh): New.
2379 (target_close): Call it.
2380 * remote.c (remote_hostio_send_command): No longer check whether
2381 remote_desc is open.
2382
5ff79300
PA
23832018-04-11 Pedro Alves <palves@redhat.com>
2384
2385 * target.c (fileio_fh_t): Make it a named struct instead of a
2386 typedef.
2387 (fileio_fh_t::is_closed): New method.
2388 (DEF_VEC_O (fileio_fh_t)): Remove.
2389 (fileio_fhandles): Now a std::vector.
2390 (is_closed_fileio_fh): Delete.
2391 (acquire_fileio_fd): Adjust. Rename parameters.
2392 (release_fileio_fd): Adjust.
2393 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
2394 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
2395 (target_fileio_close): Adjust.
2396
6e22e10d
SM
23972018-04-10 Simon Marchi <simon.marchi@ericsson.com>
2398
2399 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
2400 index.
2401
731f534f
PA
24022018-04-10 Pedro Alves <palves@redhat.com>
2403
2404 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
2405 (scoped_finish_thread_state): New class.
2406 * infcmd.c (run_command_1): Use it instead of finish_thread_state
2407 cleanup.
2408 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
2409 (fetch_inferior_event, normal_stop): Likewise.
2410 * thread.c (finish_thread_state_cleanup): Delete.
2411
d5f4488f
SM
24122018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2413 Pedro Alves <palves@redhat.com>
2414
2415 * value.c: Include "selftest.h" and "common/array-view.h".
2416 (struct range) <operator ==>: New.
2417 (test_ranges_contain): New.
2418 (check_ranges_vector): New.
2419 (test_insert_into_bit_range_vector): New.
2420 (_initialize_values): Register selftests.
2421 * common/array-view.h (operator==, operator!=): New.
2422
b24531ed
SM
24232018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2424
2425 * common/gdb_vecs.h (unordered_remove): Add overload that takes
2426 an iterator.
2427 * inline-frame.c: Include <algorithm>.
2428 (struct inline_state): Add constructor.
2429 (inline_state_s): Remove.
2430 (DEF_VEC_O(inline_state_s)): Remove.
2431 (inline_states): Change type to std::vector.
2432 (find_inline_frame_state): Adjust to std::vector.
2433 (allocate_inline_frame_state): Remove.
2434 (clear_inline_frame_state): Adjust to std::vector.
2435 (skip_inline_frames): Adjust to std::vector.
2436
c252925c
SM
24372018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2438
2439 * tracepoint.h (struct trace_state_variable): Add constructor.
2440 <name>: Change type to std::string.
2441 * tracepoint.c (tsv_s): Remove.
2442 (DEF_VEC_O(tsv_s)): Remove.
2443 (tvariables): Change to std::vector.
2444 (create_trace_state_variable): Adjust to std::vector.
2445 (find_trace_state_variable): Likewise.
2446 (find_trace_state_variable_by_number): Likewise.
2447 (delete_trace_state_variable): Likewise.
2448 (trace_variable_command): Adjust to std::string.
2449 (delete_trace_variable_command): Likewise.
2450 (tvariables_info_1): Adjust to std::vector.
2451 (save_trace_state_variables): Likewise.
2452 (start_tracing): Likewise.
2453 (merge_uploaded_trace_state_variables): Adjust to std::vector
2454 and std::string.
2455 * target.h (struct target_ops)
2456 <to_download_trace_state_variable>: Pass reference to
2457 trace_state_variable.
2458 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
2459 * target-delegates.c: Re-generate.
2460 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
2461 (mi_tsv_deleted): Likewise.
2462 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
2463 * remote.c (remote_download_trace_state_variable): Change
2464 pointer to reference and adjust.
2465 * make-target-delegates (parse_argtypes): Handle references.
2466 (write_function_header): Likewise.
2467 (munge_type): Likewise.
2468
c9638d26
SM
24692018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2470
2471 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2472 string_view-selftests.c.
2473 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
2474 testsuite.
2475 * unittests/basic_string_view/cons/char/1.cc: Likewise.
2476 * unittests/basic_string_view/cons/char/2.cc: Likewise.
2477 * unittests/basic_string_view/cons/char/3.cc: Likewise.
2478 * unittests/basic_string_view/element_access/char/1.cc:
2479 Likewise.
2480 * unittests/basic_string_view/element_access/char/empty.cc:
2481 Likewise.
2482 * unittests/basic_string_view/element_access/char/front_back.cc:
2483 Likewise.
2484 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
2485 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
2486 Likewise.
2487 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
2488 Likewise.
2489 * unittests/basic_string_view/modifiers/swap/char/1.cc:
2490 Likewise.
2491 * unittests/basic_string_view/operations/compare/char/1.cc:
2492 Likewise.
2493 * unittests/basic_string_view/operations/compare/char/13650.cc:
2494 Likewise.
2495 * unittests/basic_string_view/operations/copy/char/1.cc:
2496 Likewise.
2497 * unittests/basic_string_view/operations/data/char/1.cc:
2498 Likewise.
2499 * unittests/basic_string_view/operations/find/char/1.cc:
2500 Likewise.
2501 * unittests/basic_string_view/operations/find/char/2.cc:
2502 Likewise.
2503 * unittests/basic_string_view/operations/find/char/3.cc:
2504 Likewise.
2505 * unittests/basic_string_view/operations/find/char/4.cc:
2506 Likewise.
2507 * unittests/basic_string_view/operations/rfind/char/1.cc:
2508 Likewise.
2509 * unittests/basic_string_view/operations/rfind/char/2.cc:
2510 Likewise.
2511 * unittests/basic_string_view/operations/rfind/char/3.cc:
2512 Likewise.
2513 * unittests/basic_string_view/operations/substr/char/1.cc:
2514 Likewise.
2515 * unittests/basic_string_view/operators/char/2.cc: Likewise.
2516 * unittests/string_view-selftests.c: New file.
2517
fdc11678
SM
25182018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2519
2520 * unittests/basic_string_view/capacity/1.cc: New file.
2521 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
2522 * unittests/basic_string_view/cons/char/1.cc: New file.
2523 * unittests/basic_string_view/cons/char/2.cc: New file.
2524 * unittests/basic_string_view/cons/char/3.cc: New file.
2525 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
2526 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
2527 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
2528 * unittests/basic_string_view/element_access/char/1.cc: New file.
2529 * unittests/basic_string_view/element_access/char/2.cc: New file.
2530 * unittests/basic_string_view/element_access/char/empty.cc: New file.
2531 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
2532 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
2533 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
2534 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
2535 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
2536 * unittests/basic_string_view/include.cc: New file.
2537 * unittests/basic_string_view/inserters/char/1.cc: New file.
2538 * unittests/basic_string_view/inserters/char/2.cc: New file.
2539 * unittests/basic_string_view/inserters/char/3.cc: New file.
2540 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
2541 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
2542 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
2543 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
2544 * unittests/basic_string_view/literals/types.cc: New file.
2545 * unittests/basic_string_view/literals/values.cc: New file.
2546 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
2547 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
2548 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
2549 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
2550 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
2551 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
2552 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
2553 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
2554 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
2555 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
2556 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
2557 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
2558 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
2559 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
2560 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
2561 * unittests/basic_string_view/operations/data/char/1.cc: New file.
2562 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
2563 * unittests/basic_string_view/operations/find/char/1.cc: New file.
2564 * unittests/basic_string_view/operations/find/char/2.cc: New file.
2565 * unittests/basic_string_view/operations/find/char/3.cc: New file.
2566 * unittests/basic_string_view/operations/find/char/4.cc: New file.
2567 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
2568 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
2569 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
2570 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
2571 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
2572 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
2573 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
2574 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
2575 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
2576 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
2577 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
2578 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
2579 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
2580 * unittests/basic_string_view/operators/char/2.cc: New file.
2581 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
2582 * unittests/basic_string_view/range_access/char/1.cc: New file.
2583 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
2584 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
2585 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
2586 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
2587 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
2588 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
2589 * unittests/basic_string_view/requirements/typedefs.cc: New file.
2590 * unittests/basic_string_view/typedefs.cc: New file.
2591 * unittests/basic_string_view/types/1.cc: New file.
2592
8345c4a2
SM
25932018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2594
2595 * common/gdb_string_view.h: Remove libstdc++ implementation
2596 details, adjust to gdb reality.
2597 * common/gdb_string_view.tcc: Likewise.
2598 * cli/cli-script.c (struct string_view): Remove.
2599 (user_args) <m_args>: Change element type to gdb::string_view.
2600 (user_args::insert_args): Adjust.
2601
7adcdf08
SM
26022018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2603
2604 * common/gdb_string_view.h: New file.
2605 * common/gdb_string_view.tcc: New file.
2606
41260ac2
SM
26072018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
2608
2609 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
2610 * configure: Re-generate.
2611
0bee6dd4
PA
26122018-04-09 Pedro Alves <palves@redhat.com>
2613
2614 * gdbarch.sh: Include "observable.h" instead of "observer.h".
2615 (set_target_gdbarch): Call
2616 gdb::observers::architecture_changed.notify instead of
2617 observer_notify_architecture_changed.
2618
6f14adc5
SM
26192018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
2620
2621 * tracepoint.c (struct current_traceframe_cleanup): Remove.
2622 (do_restore_current_traceframe_cleanup): Remove.
2623 (restore_current_traceframe_cleanup_dtor): Remove.
2624 (make_cleanup_restore_current_traceframe): Remove.
2625 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
2626 New.
2627 * tracepoint.h (struct scoped_restore_current_traceframe): New.
2628 * infrun.c (fetch_inferior_event): Use
2629 scoped_restore_current_traceframe.
2630
b2bdb8cf
SM
26312018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
2632
2633 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
2634 Remove.
2635 <n_allocated_type_units>: Remove.
2636 <all_type_units>: Change to std::vector.
2637 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
2638 to std::vector change.
2639 (dwarf2_per_objfile::get_cutu): Likewise.
2640 (dwarf2_per_objfile::get_tu): Likewise.
2641 (create_signatured_type_table_from_index): Likewise.
2642 (create_signatured_type_table_from_debug_names): Likewise.
2643 (dw2_symtab_iter_next): Likewise.
2644 (dw2_print_stats): Likewise.
2645 (dw2_expand_all_symtabs): Likewise.
2646 (dw2_expand_marked_cus): Likewise.
2647 (dw2_debug_names_iterator::next): Likewise.
2648 (dwarf2_initialize_objfile): Likewise.
2649 (add_signatured_type_cu_to_table): Likewise.
2650 (create_all_type_units): Likewise.
2651 (add_type_unit): Likewise.
2652 (struct tu_abbrev_offset): Add constructor.
2653 (build_type_psymtabs_1): Adjust to std::vector change.
2654 (print_tu_stats): Likewise.
2655 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
2656 (write_debug_names): Likewise.
2657
b76e467d
SM
26582018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
2659
2660 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
2661 Make an std::vector.
2662 <n_comp_units>: Remove.
2663 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
2664 to std::vector change.
2665 (dwarf2_per_objfile::get_cutu): Likewise.
2666 (dwarf2_per_objfile::get_cu): Likewise.
2667 (create_cus_from_index): Likewise.
2668 (create_addrmap_from_index): Likewise.
2669 (create_addrmap_from_aranges): Likewise.
2670 (dwarf2_read_index): Likewise.
2671 (dw2_find_last_source_symtab): Likewise.
2672 (dw2_map_symtabs_matching_filename): Likewise.
2673 (dw2_symtab_iter_next): Likewise.
2674 (dw2_print_stats): Likewise.
2675 (dw2_expand_all_symtabs): Likewise.
2676 (dw2_expand_symtabs_with_fullname): Likewise.
2677 (dw2_expand_marked_cus): Likewise.
2678 (dw2_map_symbol_filenames): Likewise.
2679 (create_cus_from_debug_names): Likewise.
2680 (dwarf2_read_debug_names): Likewise.
2681 (dw2_debug_names_iterator::next): Likewise.
2682 (dwarf2_initialize_objfile): Likewise.
2683 (set_partial_user): Likewise.
2684 (dwarf2_build_psymtabs_hard): Likewise.
2685 (read_comp_units_from_section): Remove arguments, adjust to
2686 std::vector change.
2687 (create_all_comp_units): Adjust to std::vector and
2688 read_comp_units_from_section changes.
2689 (dwarf2_find_containing_comp_unit): Adjust to std::vector
2690 change.
2691 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
2692 (psyms_seen_size): Likewise.
2693 (write_gdbindex): Likewise.
2694 (write_debug_names): Likewise.
2695
12359b5e
SM
26962018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
2697
2698 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
2699 with dwarf2_per_objfile.
2700 (create_cus_from_index): Likewise.
2701 (create_signatured_type_table_from_index): Likewise.
2702 (dwarf2_read_index): Likewise.
2703 (dwarf2_initialize_objfile): Likewise.
2704 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
2705 per_cu rather than get_dwarf2_per_objfile.
2706
ff4c9fec
SM
27072018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
2708
2709 * dwarf2read.h (struct signatured_type): Forward declare.
2710 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
2711 New methods.
2712 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
2713 (dw2_get_cutu): ...this.
2714 (dwarf2_per_objfile::get_cu): Rename from...
2715 (dw2_get_cu): ...this.
2716 (dwarf2_per_objfile::get_tu): New.
2717 (create_addrmap_from_index): Adjust.
2718 (create_addrmap_from_aranges): Adjust.
2719 (dw2_find_last_source_symtab): Adjust.
2720 (dw2_map_symtabs_matching_filename): Adjust.
2721 (dw2_symtab_iter_next): Adjust.
2722 (dw2_print_stats): Adjust.
2723 (dw2_expand_all_symtabs): Adjust.
2724 (dw2_expand_symtabs_with_fullname): Adjust.
2725 (dw2_expand_marked_cus): Adjust.
2726 (dw_expand_symtabs_matching_file_matcher): Adjust.
2727 (dw2_map_symbol_filenames): Adjust.
2728 (dw2_debug_names_iterator::next): Adjust.
2729 (dwarf2_initialize_objfile): Adjust.
2730 (set_partial_user): Adjust.
2731 (dwarf2_build_psymtabs_hard): Adjust.
2732
5ca3fcb6
SM
27332018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
2734
2735 * dwarf2read.c (create_signatured_type_table_from_debug_names):
2736 Remove unused variables.
2737 (dw2_map_symtabs_matching_filename): Likewise.
2738 (dwarf2_record_block_ranges): Likewise.
2739 (dwarf2_read_addr_index): Likewise.
2740 (follow_die_offset): Likewise.
2741
b2e586e8
SM
27422018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
2743
2744 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
2745 to symbol_file_add_main.
2746
7c4e78cf
SM
27472018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
2748
2749 PR mi/22299
2750 * mi/mi-console.c (do_fputc_async_safe): New.
2751 (mi_console_file::write_async_safe): New.
2752 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
2753 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
2754 New.
2755 * ui-file.c (ui_file::putstrn): Adjust call to
2756 fputstrn_unfiltered.
2757 * utils.c (printchar): Replace do_fputs and do_fprintf
2758 parameters by do_fputc.
2759 (fputstr_filtered): Adjust call to printchar.
2760 (fputstr_unfiltered): Likewise.
2761 (fputstrn_filtered): Likewise.
2762 (fputstrn_unfiltered): Add do_fputc parameter, pass to
2763 printchar.
2764 * utils.h (do_fputc_ftype): New typedef.
2765 (fputstrn_unfiltered): Add do_fputc parameter.
2766
5dc026d3
SM
27672018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
2768
2769 * regformats/i386/i386-avx.dat: Remove.
2770
c912f608
SM
27712018-04-07 Simon Marchi <simon.marchi@ericsson.com>
2772
2773 PR gdb/22979
2774 * amd64-tdep.c (amd64_none_init_abi): New function.
2775 (amd64_x32_none_init_abi): New function.
2776 (_initialize_amd64_tdep): Register handlers for x86-64 and
2777 x64_32 with GDB_OSABI_NONE.
2778 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
2779 GDB_OSABI_NONE osabi.
2780
26540402
SM
27812018-04-07 Simon Marchi <simon.marchi@ericsson.com>
2782
2783 PR gdb/22980
2784 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
2785 GDB_OSABI_NONE.
2786 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
2787 * osabi.c (gdb_osabi_names): Add "unknown" entry.
2788
9018be22
SM
27892018-04-07 Simon Marchi <simon.marchi@ericsson.com>
2790
2791 * common/byte-vector.h (char_vector): New type.
2792 * target.h (target_read_alloc): Return
2793 gdb::optional<byte_vector>.
2794 (target_read_stralloc): Return gdb::optional<char_vector>.
2795 (target_get_osdata): Return gdb::optional<char_vector>.
2796 * target.c (target_read_alloc_1): Templatize. Replacement
2797 manual memory management with vector.
2798 (target_read_alloc): Change return type, adjust.
2799 (target_read_stralloc): Change return type, adjust.
2800 (target_get_osdata): Change return type, adjust.
2801 * auxv.c (struct auxv_info) <length>: Remove.
2802 <data>: Change type to gdb::optional<byte_vector>.
2803 (auxv_inferior_data_cleanup): Free auxv_info with delete.
2804 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
2805 (target_auxv_search): Adjust.
2806 (fprint_target_auxv): Adjust.
2807 * avr-tdep.c (avr_io_reg_read_command): Adjust.
2808 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
2809 (linux_make_corefile_notes): Adjust.
2810 * osdata.c (get_osdata): Adjust.
2811 * remote.c (remote_get_threads_with_qxfer): Adjust.
2812 (remote_memory_map): Adjust.
2813 (remote_traceframe_info): Adjust.
2814 (btrace_read_config): Adjust.
2815 (remote_read_btrace): Adjust.
2816 (remote_pid_to_exec_file): Adjust.
2817 * solib-aix.c (solib_aix_get_library_list): Adjust.
2818 * solib-dsbt.c (decode_loadmap): Don't free buf.
2819 (dsbt_get_initial_loadmaps): Adjust.
2820 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
2821 * solib-target.c (solib_target_current_sos): Adjust.
2822 * tracepoint.c (sdata_make_value): Adjust.
2823 * xml-support.c (xinclude_start_include): Adjust.
2824 (xml_fetch_content_from_file): Adjust.
2825 * xml-support.h (xml_fetch_another): Change return type.
2826 (xml_fetch_content_from_file): Change return type.
2827 * xml-syscall.c (xml_init_syscalls_info): Adjust.
2828 * xml-tdesc.c (file_read_description_xml): Adjust.
2829 (fetch_available_features_from_target): Change return type.
2830 (target_fetch_description_xml): Adjust.
2831 (target_read_description_xml): Adjust.
2832
14c88955
TT
28332018-04-06 Tom Tromey <tom@tromey.com>
2834
2835 * value.c (~value): Update.
2836 (struct value) <contents>: Now unique_xmalloc_ptr.
2837 (value_contents_bits_eq, allocate_value_contents)
2838 (value_contents_raw, value_contents_all_raw)
2839 (value_contents_for_printing, value_contents_for_printing_const)
2840 (set_value_enclosing_type): Update.
2841
0c7e6dd8
TT
28422018-04-06 Tom Tromey <tom@tromey.com>
2843
2844 * value.c (range_s): Remove typedef, VEC.
2845 (struct range): Add operator<.
2846 (range_lessthan): Remove.
2847 (ranges_contain): Change type.
2848 (~value): Update.
2849 (struct value) <unavailable, optimized_out>: Now std::vector.
2850 (value_entirely_available)
2851 (value_entirely_covered_by_range_vector)
2852 (value_entirely_unavailable, value_entirely_optimized_out):
2853 Update.
2854 (insert_into_bit_range_vector): Change argument type.
2855 (find_first_range_overlap): Likewise.
2856 (struct ranges_and_idx, value_contents_bits_eq)
2857 (require_not_optimized_out, require_available): Update.
2858 (ranges_copy_adjusted): Change argument types.
2859 (value_optimized_out, value_copy, value_fetch_lazy): Update.
2860
2c8331b9
TT
28612018-04-06 Tom Tromey <tom@tromey.com>
2862
2863 * value.c (~value): Update.
2864 (struct value) <parent>: Now a value_ref_ptr.
2865 (value_parent, set_value_parent, value_address, value_copy):
2866 Update.
2867
466ce3ae
TT
28682018-04-06 Tom Tromey <tom@tromey.com>
2869
2870 * value.c (struct value): Add constructor, destructor, and member
2871 initializers.
2872 (allocate_value_lazy, value_decref): Update.
2873
062d818d
TT
28742018-04-06 Tom Tromey <tom@tromey.com>
2875
2876 * value.c (struct value) <released, next>: Remove.
2877 (all_values): Now a std::vector.
2878 (allocate_value_lazy): Update.
2879 (value_next): Remove.
2880 (value_mark, value_free_to_mark, release_value)
2881 (value_release_to_mark): Update.
2882
a6535de1
TT
28832018-04-06 Tom Tromey <tom@tromey.com>
2884
2885 * value.h (fetch_subexp_value, value_release_to_mark): Update.
2886 (free_value_chain): Remove.
2887 * value.c (free_value_chain): Remove.
2888 (value_release_to_mark): Return a std::vector.
2889 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
2890 std::vector.
2891 (check_condition): Update.
2892 * eval.c (fetch_subexp_value): Change "val_chain" to a
2893 std::vector.
2894 * breakpoint.c (update_watchpoint): Update.
2895 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
2896
b5621201
TT
28972018-04-06 Tom Tromey <tom@tromey.com>
2898
2899 * value.h (free_all_values): Remove.
2900 * value.c (free_all_values): Remove.
2901
4d0266a0
TT
29022018-04-06 Tom Tromey <tom@tromey.com>
2903
2904 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
2905 (value_history_chain, value_history_count): Remove.
2906 (value_history): New global.
2907 (record_latest_value, access_value_history, show_values)
2908 (preserve_values): Update.
2909
b4d61099
TT
29102018-04-06 Tom Tromey <tom@tromey.com>
2911
2912 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
2913 * varobj.c (varobj_set_display_format, varobj_set_value)
2914 (install_default_visualizer, construct_visualizer)
2915 (install_new_value, ~varobj, varobj_get_value_type)
2916 (my_value_of_variable, varobj_editable_p): Update.
2917 * c-varobj.c (c_describe_child, c_value_of_variable)
2918 (cplus_number_of_children, cplus_describe_child): Update.
2919 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
2920 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
2921 (ada_value_of_variable, ada_value_is_changeable_p): Update.
2922
9b558729
TT
29232018-04-06 Tom Tromey <tom@tromey.com>
2924
2925 * printcmd.c (last_examine_address): Change type to
2926 value_ref_ptr.
2927 (do_examine, x_command): Update.
2928
850645cf
TT
29292018-04-06 Tom Tromey <tom@tromey.com>
2930
2931 * value.c (release_value): Update.
2932 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
2933 (struct bpstats) <val>: Now a value_ref_ptr.
2934 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
2935 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
2936 (~watchpoint, print_it_watchpoint, watch_command_1)
2937 (invalidate_bp_value_on_memory_change): Update.
2938
22bc8444
TT
29392018-04-06 Tom Tromey <tom@tromey.com>
2940
2941 * varobj.c (varobj_clear_saved_item)
2942 (update_dynamic_varobj_children, install_new_value, ~varobj):
2943 Update.
2944 * value.h (value_incref): Move declaration earlier.
2945 (value_decref): Rename from value_free.
2946 (struct value_ref_policy): New.
2947 (value_ref_ptr): New typedef.
2948 (struct value_deleter): Remove.
2949 (gdb_value_up): Remove typedef.
2950 (release_value): Change return type.
2951 (release_value_or_incref): Remove.
2952 * value.c (set_value_parent): Update.
2953 (value_incref): Change return type.
2954 (value_decref): Rename from value_free.
2955 (value_free_to_mark, free_all_values, free_value_chain): Update.
2956 (release_value): Return value_ref_ptr.
2957 (release_value_or_incref): Remove.
2958 (record_latest_value, set_internalvar, clear_internalvar):
2959 Update.
2960 * stack.c (info_frame_command): Don't call value_free.
2961 * python/py-value.c (valpy_dealloc, valpy_new)
2962 (value_to_value_object): Update.
2963 * printcmd.c (do_examine): Update.
2964 * opencl-lang.c (lval_func_free_closure): Update.
2965 * mi/mi-main.c (register_changed_p): Don't call value_free.
2966 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
2967 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
2968 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
2969 value_free.
2970 * guile/scm-value.c (vlscm_free_value_smob)
2971 (vlscm_scm_from_value): Update.
2972 * frame.c (frame_register_unwind, frame_unwind_register_signed)
2973 (frame_unwind_register_unsigned, get_frame_register_bytes)
2974 (put_frame_register_bytes): Don't call value_free.
2975 * findvar.c (address_from_register): Don't call value_free.
2976 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
2977 * dwarf2loc.c (entry_data_value_free_closure)
2978 (value_of_dwarf_reg_entry, free_pieced_value_closure)
2979 (dwarf2_evaluate_loc_desc_full): Update.
2980 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
2981 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
2982 (~watchpoint, watch_command_1)
2983 (invalidate_bp_value_on_memory_change): Update.
2984 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
2985
7f8a5d38
SM
29862018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
2987
2988 PR gdb/23022
2989 * warning.m4: Add -Wno-error=deprecated-register.
2990 * configure: Re-generate.
2991
8a76bd3b
TT
29922018-04-05 Tom Tromey <tom@tromey.com>
2993
2994 * linespec.h: Remove include of "vec.h".
2995
8e8d776e
TT
29962018-04-05 Tom Tromey <tom@tromey.com>
2997
2998 * linespec.c (typep): Remove typedef.
2999 (find_methods, find_superclass_methods): Take a std::vector.
3000 (find_method): Use std::vector.
3001
9b2f8581
TT
30022018-04-05 Tom Tromey <tom@tromey.com>
3003
3004 * utils.c (compare_strings): Remove.
3005 * utils.h (compare_strings): Remove.
3006 * objc-lang.h (find_imps): Update.
3007 * objc-lang.c (find_methods): Take a std::vector.
3008 (uniquify_strings, find_imps): Likewise.
3009 * linespec.c (find_methods): Take a std::vector.
3010 (decode_objc): Use std::vector.
3011 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
3012 a std::vector.
3013 (find_method, find_function_symbols): Use std::vector.
3014
459a2e4c
TT
30152018-04-05 Tom Tromey <tom@tromey.com>
3016
3017 * completer.c (completion_tracker::completion_tracker): Remove
3018 cast.
3019 (completion_tracker::discard_completions): Likewise.
3020 * breakpoint.c (ambiguous_names_p): Remove cast.
3021 * ada-lang.c (_initialize_ada_language): Remove cast.
3022 * utils.h (streq): Update.
3023 (streq_hash): Add new declaration.
3024 * utils.c (streq): Return bool.
3025 (streq_hash): New function.
3026
9be2c17a
TT
30272018-04-05 Tom Tromey <tom@tromey.com>
3028
3029 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
3030 Remove a string copy.
3031
f73c6ece
TT
30322018-04-05 Tom Tromey <tom@tromey.com>
3033
3034 * linespec.c (filter_results): Use std::vector.
3035 (decode_line_2, decode_line_full): Update.
3036
53a0f8a2
TT
30372018-04-05 Tom Tromey <tom@tromey.com>
3038
3039 * linespec.c (canonical_to_fullform): Return std::string.
3040 (filter_results): Update.
3041 (struct decode_line_2_item): Add constructor.
3042 <fullform, displayform>: Now std::string.
3043 (decode_line_2_compare_items): Now a std::sort comparator.
3044 (decode_line_2): Update.
3045
a5b5adf5
TT
30462018-04-05 Tom Tromey <tom@tromey.com>
3047
3048 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
3049 (unexpected_linespec_error): Update.
3050 (linespec_parse_basic, parse_linespec): Update.
3051
6a307fc5
TT
30522018-04-05 Tom Tromey <tom@tromey.com>
3053
3054 * linespec.c (linespec_parse_basic): Reindent.
3055
41c1efc6
TT
30562018-04-05 Tom Tromey <tom@tromey.com>
3057
3058 * minsyms.h (iterate_over_minimal_symbols): Update.
3059 * minsyms.c (iterate_over_minimal_symbols): Take a
3060 gdb::function_view.
3061 * linespec.c (struct collect_minsyms): Remove.
3062 (compare_msyms): Now a std::sort comparator.
3063 (add_minsym): Add parameters.
3064 (search_minsyms_for_name): Update. Use std::vector.
3065
c5edbf3d
TT
30662018-04-03 Tom Tromey <tom@tromey.com>
3067
3068 * mipsread.c (read_alphacoff_dynamic_symtab): Use
3069 gdb::byte_vector.
3070
b39efc48
WP
30712018-04-02 Weimin Pan <weimin.pan@oracle.com>
3072
3073 * MAINTAINERS (Write After Approval): Add Weimin Pan.
3074
121ad66c 30752018-04-02 Weimin Pan <weimin.pan@oracle.com>
79f18731
WP
3076
3077 PR gdb/16959
3078 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
3079 printing static type.
3080
09473be8
TT
30812018-04-01 Tom Tromey <tom@tromey.com>
3082
3083 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
3084 (rs6000_xfer_shared_libraries): Update.
3085
ec1f2d91
SM
30862018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
3087
3088 * common/gdb_vecs.h (char_ptr): Remove.
3089 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
3090
d8611974
SM
30912018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
3092
3093 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
3094 with std::vector.
3095 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
3096
a18ba4e4
SM
30972018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
3098
3099 * tracepoint.h (struct uploaded_tp): Initialize fields.
3100 <actions, step_actions, cmd_strings>: Change type to
3101 std::vector<char *>.
3102 * tracepoint.c (get_uploaded_tp): Allocate with new.
3103 (free_uploaded_tps): Free with delete.
3104 (parse_tracepoint_definition): Adjust to std::vector change.
3105 * breakpoint.c (read_uploaded_action): Likewise.
3106 (create_tracepoint_from_upload): Likewise.
3107 * ctf.c (ctf_write_uploaded_tp): Likewise.
3108 (SET_ARRAY_FIELD): Likewise.
3109 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
3110
a7961323
TT
31112018-03-30 Tom Tromey <tom@tromey.com>
3112
3113 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
3114 std::unique_ptr.
3115 (svr4_keep_data_in_core): Update.
3116 (svr4_read_so_list): Update.
3117
e83e4e24
TT
31182018-03-30 Tom Tromey <tom@tromey.com>
3119
3120 * windows-nat.c (handle_output_debug_string, handle_exception):
3121 Update.
3122 * target.h (target_read_string): Update.
3123 * target.c (target_read_string): Change "string" to
3124 unique_xmalloc_ptr.
3125 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
3126 Update.
3127 * solib-frv.c (frv_current_sos): Update.
3128 * solib-dsbt.c (dsbt_current_sos): Update.
3129 * solib-darwin.c (darwin_current_sos): Update.
3130 * linux-thread-db.c (inferior_has_bug): Update.
3131 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
3132 Update. Remove alloca.
3133 * ada-lang.c (ada_main_name): Update.
3134
263db9a1
TT
31352018-03-30 Tom Tromey <tom@tromey.com>
3136
3137 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
3138 (struct dwo_file_deleter): New.
3139 (dwo_file_up): New typedef.
3140 (open_and_init_dwo_file): Use dwo_file_up.
3141 (free_dwo_file_cleanup): Remove.
3142
5dafb3d1
TT
31432018-03-30 Tom Tromey <tom@tromey.com>
3144
3145 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
3146 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
3147
11ed8cad
TT
31482018-03-30 Tom Tromey <tom@tromey.com>
3149
3150 * dwarf2read.c (class free_cached_comp_units): New class.
3151 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
3152 (free_cached_comp_units): Remove function.
3153
9ae79dac
TT
31542018-03-30 Tom Tromey <tom@tromey.com>
3155
3156 * utils.h (make_cleanup_unpush_target): Remove.
3157 * inf-ptrace.c (struct target_unpusher): New.
3158 (target_unpush_up) New typedef.
3159 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
3160 target_unpush_up.
3161 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
3162
5aa89276
TT
31632018-03-27 Tom Tromey <tom@tromey.com>
3164
3165 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
3166
1dbeed45
TT
31672018-03-27 Pedro Alves <palves@redhat.com>
3168 Tom Tromey <tom@tromey.com>
3169
3170 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
3171 destructor. Now a class.
3172 (gdb_readline_wrapper_cleanup): Remove function.
3173 (gdb_readline_wrapper): Remove cleanups.
3174
c819b2c0
TT
31752018-03-27 Tom Tromey <tom@tromey.com>
3176
3177 * typeprint.h (struct type_print_options) <local_typedefs,
3178 global_typedefs>: Remove "struct" keyword.
3179 (class typedef_hash_table): New class.
3180 (recursively_update_typedef_hash, add_template_parameters)
3181 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
3182 (find_typedef_in_hash): Don't declare.
3183 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
3184 (typedef_hash_table::recursively_update): Rename from
3185 recursively_update_typedef_hash. Now a member.
3186 (typedef_hash_table::add_template_parameters): Rename from
3187 add_template_parameters. Now a member.
3188 (typedef_hash_table::typedef_hash_table): Now a constructor;
3189 rename from create_typedef_hash.
3190 (typedef_hash_table::~typedef_hash_table): Now a destructor;
3191 rename from free_typedef_hash.
3192 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
3193 (do_free_global_table): Remove.
3194 (typedef_hash_table::typedef_hash_table): New constructor; renamed
3195 from copy_type_recursive.
3196 (create_global_typedef_table): Remove.
3197 (typedef_hash_table::find_global_typedef): Now a member of
3198 typedef_hash_table.
3199 (typedef_hash_table::find_typedef): Rename from
3200 find_typedef_in_hash; now a member.
3201 (whatis_exp): Update.
3202 * extension.h (struct ext_lang_type_printers): Add constructor and
3203 destructor.
3204 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
3205 declare.
3206 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
3207 Now a constructor; rename from start_ext_lang_type_printers.
3208 (ext_lang_type_printers): Now a destructor; rename from
3209 free_ext_lang_type_printers.
3210 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
3211 Update.
3212 (c_type_print_base_struct_union): Update. Remove cleanups.
3213
608219fb
TT
32142018-03-27 Tom Tromey <tom@tromey.com>
3215
3216 * dwarf-index-write.c: Include <cmath>.
3217
3fcded8f
JB
32182018-03-27 Joel Brobecker <brobecker@adacore.com>
3219
3220 * NEWS: Add entry describing new "set|show varsize-limit" command.
3221 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
3222 command.
3223 * printcmd.c (_initialize_printcmd): Add "set var" alias of
3224 "set variable".
3225
cd4fb1b2
SM
32262018-03-27 Simon Marchi <simon.marchi@ericsson.com>
3227
3228 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
3229 dwarf-index-write.c
3230 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
3231 * dwarf-index-common.c: New file.
3232 * dwarf-index-common.h: New file.
3233 * dwarf-index-write.c: New file.
3234 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
3235 (struct dwarf2_section_info): Move from here.
3236 (dwarf2_section_info_def): Likewise.
3237 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
3238 (offset_type): Likewise.
3239 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
3240 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
3241 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
3242 (byte_swap): Likewise.
3243 (MAYBE_SWAP): Likewise.
3244 (dwarf2_per_cu_ptr): Likewise.
3245 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
3246 (struct tu_stats): Likewise.
3247 (struct dwarf2_per_objfile): Likewise.
3248 (struct dwarf2_per_cu_data): Likewise.
3249 (struct signatured_type): Likewise.
3250 (sig_type_ptr): Likewise.
3251 (DEF_VEC_P (sig_type_ptr)): Likewise.
3252 (INDEX4_SUFFIX): Likewise.
3253 (INDEX5_SUFFIX): Likewise.
3254 (DEBUG_STR_SUFFIX): Likewise.
3255 (dwarf2_read_section): Make non-static.
3256 (mapped_index_string_hash): Move from here.
3257 (dwarf5_djb_hash): Likewise.
3258 (file_write): Likewise.
3259 (class data_buf): Likewise.
3260 (struct symtab_index_entry): Likewise.
3261 (struct mapped_symtab): Likewise.
3262 (find_slot): Likewise.
3263 (hash_expand): Likewise.
3264 (add_index_entry): Likewise.
3265 (uniquify_cu_indices): Likewise.
3266 (class c_str_view): Likewise.
3267 (class c_str_view_hasher): Likewise.
3268 (class vector_hasher): Likewise.
3269 (write_hash_table): Likewise.
3270 (psym_index_map): Likewise.
3271 (struct addrmap_index_data): Likewise.
3272 (add_address_entry): Likewise.
3273 (add_address_entry_worker): Likewise.
3274 (write_address_map): Likewise.
3275 (symbol_kind): Likewise.
3276 (write_psymbols): Likewise.
3277 (struct signatured_type_index_data): Likewise.
3278 (write_one_signatured_type): Likewise.
3279 (recursively_count_psymbols): Likewise.
3280 (recursively_write_psymbols): Likewise.
3281 (class debug_names): Likewise.
3282 (check_dwarf64_offsets): Likewise.
3283 (psyms_seen_size): Likewise.
3284 (write_gdbindex): Likewise.
3285 (write_debug_names): Likewise.
3286 (assert_file_size): Likewise.
3287 (write_psymtabs_to_index): Likewise.
3288 (save_gdb_index_command): Likewise.
3289 (_initialize_dwarf2_read): Don't register the "save gdb-index"
3290 command.
3291 * dwarf2read.h: New file.
3292
59cc4834
JB
32932018-03-27 Joel Brobecker <brobecker@adacore.com>
3294
3295 PR gdb/22670
3296 * dwarf2read.c (dwarf2_physname): Do not return the demangled
3297 symbol name if the CU's language stores symbol names in linkage
3298 format.
3299 * language.h (struct language_defn)
3300 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
3301 all instances of this struct.
3302
67501539
TT
33032018-03-26 Tom Tromey <tom@tromey.com>
3304
3305 * stack.c (backtrace_command_1): Remove verbose code.
3306
76c939ac
TT
33072018-03-26 Tom Tromey <tom@tromey.com>
3308
3309 * python/py-framefilter.c (py_print_type): Don't catch
3310 exceptions. Return void.
3311 (py_print_value): Likewise.
3312 (py_print_single_arg): Likewise.
3313 (enumerate_args): Don't catch exceptions.
3314 (py_print_args): Likewise.
3315 (py_print_frame): Likewise.
3316 (gdbpy_apply_frame_filter): Catch exceptions here.
3317
9507b29c
TT
33182018-03-26 Tom Tromey <tom@tromey.com>
3319
3320 * stack.c (_initialize_stack): Remove trailing newlines from help
3321 text. Add "Usage" line to "backtrace" help.
3322
eb68e487
TT
33232018-03-26 Tom Tromey <tom@tromey.com>
3324
3325 PR python/16486:
3326 * python/py-framefilter.c (py_print_args): Call wrap_hint.
3327
1f111921
TT
33282018-03-26 Tom Tromey <tom@tromey.com>
3329
3330 * python/py-framefilter.c (py_print_single_arg): Return
3331 EXT_LANG_BT_ERROR from catch.
3332
fb7eb8b5
TT
33332018-03-26 Tom Tromey <tom@tromey.com>
3334
3335 PR backtrace/15584:
3336 * stack.c (backtrace_command_1): Move some code into no-filters
3337 "if".
3338
4ca59a9f
TT
33392018-03-26 Tom Tromey <tom@tromey.com>
3340
3341 * python/py-framefilter.c (throw_quit_or_print_exception): New
3342 function.
3343 (gdbpy_apply_frame_filter): Use it.
3344
92256134
TT
33452018-03-26 Tom Tromey <tom@tromey.com>
3346
3347 PR cli/17716:
3348 * python/py-framefilter.c (py_print_type, py_print_value)
3349 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
3350 RETURN_MASK_ERROR.
3351
7a630bc2
TT
33522018-03-26 Tom Tromey <tom@tromey.com>
3353
3354 * python/py-framefilter.c (enumerate_args): Use
3355 gdb::unique_xmalloc_ptr.
3356
63283d4a
TT
33572018-03-26 Tom Tromey <tom@tromey.com>
3358
3359 * python/py-framefilter.c (py_print_frame): Return
3360 EXT_LANG_BT_OK.
3361 (gdbpy_apply_frame_filter): Update comment.
3362 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
3363 Remove.
3364 <EXT_LANG_BT_NO_FILTERS>: Change value.
3365
978d6c75
TT
33662018-03-26 Tom Tromey <tom@tromey.com>
3367
3368 PR backtrace/15582:
3369 * stack.c (backtrace_command): Parse "hide" argument.
3370 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
3371 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
3372 constant.
3373
1cf7e640
TT
33742018-03-26 Tom Tromey <tom@tromey.com>
3375
3376 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
3377 add "flags".
3378 (backtrace_command): Remove "fulltrace", add "flags".
3379
ea3b0687
TT
33802018-03-26 Tom Tromey <tom@tromey.com>
3381
3382 * stack.c (backtrace_command): Rewrite command line parsing.
3383
9f034d75
SM
33842018-03-26 Simon Marchi <simon.marchi@ericsson.com>
3385
3386 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
3387
ce1459e5
SM
33882018-03-26 Simon Marchi <simon.marchi@ericsson.com>
3389
3390 * filename-seen-cache.h: Add include guard.
3391
4f7ae6f5
KS
33922018-03-26 Keith Seitz <keiths@redhat.com>
3393
3394 * symfile.c (place_section): Remove "struct" from section_addr_info
3395 in comment.
3396 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
3397 "struct" keyword from section_addr_info.
3398
5cd3e386
AH
33992018-03-26 Alan Hayward <alan.hayward@arm.com>
3400
3401 * regformats/regdef.h (reg): Add constructors.
3402
3e5ef9a4
PA
34032018-03-25 Pedro Alves <palves@redhat.com>
3404
3405 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
3406 if then/else bodies in var_func_name extraction.
3407
c88d2fcc 34082018-03-23 Weimin Pan <weimin.pan@oracle.com>
bce02d88
WP
3409
3410 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
3411 lookup_minimal_symbol() to find symbol entry.
3412 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
3413
b7fee5a3
KS
34142018-03-23 Keith Seitz <keiths@redhat.com>
3415
3416 PR c++/22968
3417 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
3418 nested type definitions for C++, too.
3419
2cc9b304
TT
34202018-03-23 Tom Tromey <tom@tromey.com>
3421
3422 * machoread.c (struct oso_el): Add a constructor. Don't define as
3423 a typedef.
3424 (macho_register_oso): Remove.
3425 (macho_symtab_read): Take a std::vector.
3426 (oso_el_compare_name): Now a std::sort comparator.
3427 (macho_symfile_read_all_oso): Take a std::vector.
3428 (macho_symfile_read): Use std::vector. Remove cleanups.
3429
a2b2bc12
TT
34302018-03-22 Tom Tromey <tom@tromey.com>
3431
3432 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
3433 (record_full_goto_bookmark): Use std::string.
3434
7a8f494c
PFC
34352018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3436
3437 PR tdep/18295
3438 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
3439 a single mask.
3440
dd6d677f
PFC
34412018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3442
3443 * rs6000-tdep.c (store_insn_p): New function.
3444 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
3445 and cr_reg to their unshifted values. Use store_insn_p to
3446 match LR saves using either R1 or fdata->alloca_reg. Use
3447 store_insn_p to match CR saves. Set alloca_reg_offset
3448 when alloca_reg and framep are set. Remove lr_reg shift
3449 when assigning to fdata->lr_register.
3450
26d6cec4
AA
34512018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
3452
3453 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
3454 command line args instead of emitting a warning.
3455
5d9310c4
SM
34562018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
3457
3458 * tracepoint.h (struct static_tracepoint_marker): Initialize
3459 fields, define default constructor, move constructor and move
3460 assignment, disable the rest.
3461 <str_id, extra>: Make std::string.
3462 (release_static_tracepoint_marker): Remove.
3463 (free_current_marker): Remove.
3464 * tracepoint.c (free_current_marker): Remove.
3465 (parse_static_tracepoint_marker_definition): Adjust to
3466 std::string, use new hex2str overload.
3467 (release_static_tracepoint_marker): Remove.
3468 (print_one_static_tracepoint_marker): Get marker by reference
3469 and adjust to std::string.
3470 (info_static_tracepoint_markers_command): Adjust to std::vector
3471 changes
3472 * target.h (static_tracepoint_marker_p): Remove typedef.
3473 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
3474 (struct target_ops) <to_static_tracepoint_marker_at>: Return
3475 bool.
3476 <to_static_tracepoint_markers_by_strid>: Return std::vector.
3477 * target-debug.h
3478 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
3479 (target_debug_print_std_vector_static_tracepoint_marker): New.
3480 (target_debug_print_struct_static_tracepoint_marker_p): Rename
3481 to...
3482 (target_debug_print_static_tracepoint_marker_p): ... this.
3483 * target-delegates.c: Re-generate.
3484 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
3485 Make std::string.
3486 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
3487 (decode_static_tracepoint_spec): Adjust to std::vector.
3488 (tracepoint_print_one_detail): Adjust to std::string.
3489 (strace_marker_decode_location): Adjust to std::string.
3490 (update_static_tracepoint): Adjust to std::string, remove call
3491 to release_static_tracepoint_marker.
3492 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
3493 Adjust to std::vector.
3494 * remote.c (remote_static_tracepoint_marker_at): Return bool.
3495 (remote_static_tracepoint_markers_by_strid): Adjust to
3496 std::vector.
3497 * common/rsp-low.h (hex2str): New overload with explicit count
3498 of bytes.
3499 * common/rsp-low.c (hex2str): New overload with explicit count
3500 of bytes.
3501 * unittests/rsp-low-selftests.c (test_hex2str): New function.
3502 (_initialize_rsp_low_selftests): Add test_hex2str test.
3503 * unittests/tracepoint-selftests.c
3504 (test_parse_static_tracepoint_marker_definition): Adjust to
3505 std::string.
3506
62c222b6
SM
35072018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
3508
3509 * tracepoint.c (parse_static_tracepoint_marker_definition):
3510 Consider case where the definition is followed by more
3511 definitions.
3512 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3513 tracepoint-selftests.c.
3514 * unittests/tracepoint-selftests.c: New.
3515
7eb2418f
PFC
35162018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3517
3518 * MAINTAINERS (Write After Approval): Add Pedro Franco de
3519 Carvalho.
3520
7cbe16e9
SR
35212018-03-20 Stephen Roberts <stephen.roberts@arm.com>
3522
3d6b3b82 3523 * symtab.c (find_pc_sect_line): fixed indentation.
7cbe16e9 3524
4ee89e90
SR
35252018-03-20 Stephen Roberts <stephen.roberts@arm.com>
3526
3d6b3b82 3527 * symtab.c (find_pc_sect_line): now uses binary search.
4ee89e90 3528
92630041
TT
35292018-03-19 Tom Tromey <tom@tromey.com>
3530
3531 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
3532 "IDENT" production.
3533
76727919
TT
35342018-03-19 Pedro Alves <palves@redhat.com>
3535 Tom Tromey <tom@tromey.com>
3536
3537 * unittests/observable-selftests.c: New file.
3538 * common/observable.h: New file.
3539 * observable.h: New file.
3540 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
3541 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
3542 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
3543 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
3544 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
3545 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
3546 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
3547 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
3548 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
3549 python/py-breakpoint.c, python/py-finishbreakpoint.c,
3550 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
3551 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
3552 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
3553 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
3554 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
3555 tui/tui-interp.c, valops.c: Update all users.
3556 * tui/tui-hooks.c (tui_bp_created_observer)
3557 (tui_bp_deleted_observer, tui_bp_modified_observer)
3558 (tui_inferior_exit_observer, tui_before_prompt_observer)
3559 (tui_normal_stop_observer, tui_register_changed_observer):
3560 Remove.
3561 (tui_observers_token): New global.
3562 (attach_or_detach, tui_attach_detach_observers): New functions.
3563 (tui_install_hooks, tui_remove_hooks): Use
3564 tui_attach_detach_observers.
3565 * record-btrace.c (record_btrace_thread_observer): Remove.
3566 (record_btrace_thread_observer_token): New global.
3567 * observer.sh: Remove.
3568 * observer.c: Rename to observable.c.
3569 * observable.c (namespace gdb_observers): Define new objects.
3570 (observer_debug): Move into gdb_observers namespace.
3571 (struct observer, struct observer_list, xalloc_observer_list_node)
3572 (xfree_observer_list_node, generic_observer_attach)
3573 (generic_observer_detach, generic_observer_notify): Remove.
3574 (_initialize_observer): Update.
3575 Don't include observer.inc.
3576 * Makefile.in (generated_files): Remove observer.h, observer.inc.
3577 (clean mostlyclean): Likewise.
3578 (observer.h, observer.inc): Remove targets.
3579 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
3580 (COMMON_SFILES): Use observable.c, not observer.c.
3581 * .gitignore: Remove observer.h.
3582
1cb1f3da
TT
35832018-03-18 Tom Tromey <tom@tromey.com>
3584
3585 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
3586 gdb::def_vector.
3587 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
3588
a06ab151
TT
35892018-03-17 Tom Tromey <tom@tromey.com>
3590
3591 * auto-load.c (auto_load_objfile_script_1): Use std::string.
3592
770623f7
TT
35932018-03-17 Tom Tromey <tom@tromey.com>
3594
3595 * target.c (class scoped_target_fd): New.
3596 (target_fileio_close_cleanup): Remove.
3597 (target_fileio_read_alloc_1): Use scoped_target_fd.
3598
39be3c7e
SM
35992018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
3600
3601 * silent-rules.mk: New.
3602 * Makefile.in: Include silent-rules.mk
3603 (srcdir, VPATH, top_srcdir): Move up.
3604 (COMPILE): Add ECHO_CXX.
3605 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
3606 (init.c): Add ECHO_INIT_C.
3607 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
3608 (version.c): Add ECHO_GEN.
3609 (printcmd.o): Add ECHO_CXX.
3610 (target-float.o): Add ECHO_CXX.
3611 (ada-exp.o): Add ECHO_CXX.
3612 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
3613 (insight$(EXEEXT)): Add ECHO_CXXLD.
3614 * gnulib/configure.ac: Add AM_SILENT_RULES.
3615 * gnulib/aclocal.m4: Re-generate.
3616 * gnulib/configure: Re-generate.
3617 * gnulib/import/Makefile.in: Re-generate.
3618
37e136b1
TT
36192018-03-16 Tom Tromey <tom@tromey.com>
3620
3621 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
3622 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
3623 * utils.c (do_free_section_addr_info)
3624 (make_cleanup_free_section_addr_info): Remove.
3625 * symfile.h (struct other_sections): Add constructor.
3626 (struct section_addr_info): Remove.
3627 (section_addr_info): New typedef.
3628 (struct sym_fns) <sym_offsets>: Change type of parameter.
3629 (build_section_addr_info_from_objfile)
3630 (relative_addr_info_to_section_offsets, addr_info_make_relative)
3631 (default_symfile_offsets, symbol_file_add)
3632 (symbol_file_add_from_bfd)
3633 (build_section_addr_info_from_section_table): Update.
3634 (alloc_section_addr_info, free_section_addr_info): Don't declare.
3635 * symfile.c (alloc_section_addr_info): Remove.
3636 (build_section_addr_info_from_section_table): Change return type.
3637 Update.
3638 (build_section_addr_info_from_bfd)
3639 (build_section_addr_info_from_objfile): Likewise.
3640 (free_section_addr_info): Remove.
3641 (relative_addr_info_to_section_offsets): Change type of "addrs".
3642 (addrs_section_compar): Now a std::sort comparator.
3643 (addrs_section_sort): Change return type.
3644 (addr_info_make_relative): Change type of "addrs". Update.
3645 (default_symfile_offsets, syms_from_objfile_1)
3646 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
3647 (symbol_file_add_separate): Update.
3648 (symbol_file_add): Change type of "addrs". Update.
3649 (add_symbol_file_command): Update. Remove cleanups.
3650 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
3651 cleanups.
3652 * symfile-debug.c (debug_sym_offsets): Change type of "info".
3653 * solib.c (solib_read_symbols): Update.
3654 * objfiles.c (objfile_relocate): Update. Remove cleanups.
3655 * machoread.c (macho_symfile_offsets): Update.
3656 * jit.c (jit_bfd_try_read_symtab): Update.
3657
03afa6ef
SM
36582018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
3659
3660 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3661 unittests/utils-selftests.c.
3662 * unittests/utils-selftests.c: New file.
3663
3ae9ce5d
TT
36642018-03-14 Tom Tromey <tom@tromey.com>
3665
3666 PR cli/14977:
3667 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
3668 for NULL.
3669
b8c2339b
TT
36702018-03-14 Tom Tromey <tom@tromey.com>
3671
3672 PR cli/19918:
3673 * printcmd.c (printf_pointer): Allow "-" in format.
3674
80ae639d
TT
36752018-03-14 Tom Tromey <tom@tromey.com>
3676
3677 * printcmd.c (_initialize_printcmd): Add usage to printf.
3678
0d671d99
YQ
36792018-03-14 Yao Qi <qiyao@sourceware.org>
3680
3681 * MAINTAINERS: Update my email address.
3682
b577b6af
TT
36832018-03-13 Tom Tromey <tom@tromey.com>
3684
3685 * machoread.c (macho_check_dsym): Change filenamep to a
3686 std::string*.
3687 (macho_symfile_read): Update.
3688 * symfile.c (load_command): Use std::string.
3689
89a3b63e
AB
36902018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
3691
3692 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
3693 to error message string.
3694 (riscv_register_name): Use xsnprintf instead of sprintf.
3695 (riscv_insn::fetch_instruction): Use gdb_assert instead of
3696 internal_error.
3697 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
3698 error.
3699 (riscv_push_dummy_call): Likewise.
3700
984c7238
TT
37012018-03-12 Tom Tromey <tom@tromey.com>
3702
3703 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
3704 Use gdb::byte_vector.
3705 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
3706
933522d1
YQ
37072018-03-12 Yao Qi <yao.qi@linaro.org>
3708
3709 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
3710 parameter type to readable_regcache.
3711 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
3712 the declaration.
3713
be2daae6
TT
37142018-03-11 Tom Tromey <tom@tromey.com>
3715
3716 * dwarf2read.c (struct nextfield): Add initializers.
3717 (struct nextfnfield): Remove.
3718 (struct fnfieldlist): Add initializers. Remove "length" and
3719 "head", use std::vector.
3720 (struct decl_field_list): Remove.
3721 (struct field_info): Add initializers.
3722 <fields, baseclasses>: Now std::vector.
3723 <nbaseclasses, nfnfields, typedef_field_list_count,
3724 nested_types_list_count>: Remove.
3725 (dwarf2_add_field, dwarf2_add_type_defn)
3726 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
3727 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
3728 (process_structure_scope): Update.
3729
484cf504
TT
37302018-03-11 Tom Tromey <tom@tromey.com>
3731
3732 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
3733 for use by std::sort.
3734 (build_type_psymtabs_1): Use std::vector.
3735
9bd8e0b0
EZ
37362018-03-09 Eli Zaretskii <eliz@gnu.org>
3737
3738 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
3739 and LIBMPFR in the printed configuration.
3740
5dc1a704
TT
37412018-03-08 Tom Tromey <tom@tromey.com>
3742
3743 * source.c (get_filename_and_charpos): Use scoped_fd.
3744 * nto-procfs.c (procfs_open_1): Use scoped_fd.
3745 (procfs_pidlist): Likewise.
3746 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
3747 (iterate_over_mappings): Likewise.
3748
fdf07f3a
TT
37492018-03-08 Tom Tromey <tom@tromey.com>
3750
3751 * infcall.c (struct call_return_meta_info)
3752 <stack_temporaries_enabled>: Remove.
3753 (get_call_return_value, call_function_by_hand_dummy): Update.
3754 * thread.c (disable_thread_stack_temporaries): Remove.
3755 (enable_thread_stack_temporaries): Remove.
3756 (thread_stack_temporaries_enabled_p): Return bool.
3757 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
3758 (get_last_thread_stack_temporary): Update.
3759 * eval.c (evaluate_subexp): Update.
3760 * gdbthread.h (class enable_thread_stack_temporaries): Now a
3761 class, not a function.
3762 (value_ptr, value_vec): Remove typedefs.
3763 (class thread_info) <stack_temporaries_enabled>: Now bool.
3764 <stack_temporaries>: Now a std::vector.
3765 (thread_stack_temporaries_enabled_p)
3766 (value_in_thread_stack_temporaries): Return bool.
3767
567a3e54
SM
37682018-03-08 Simon Marchi <simon.marchi@ericsson.com>
3769
3770 * remote.c (putpkt_binary): Fix omitted bytes reporting.
3771 (getpkt_or_notif_sane_1): Likewise.
3772
00b40057
SM
37732018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
3774
3775 * build-id.c (build_id_to_debug_bfd): Use std::string.
3776
a8dbfd58
SM
37772018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
3778
3779 * build-id.c (find_separate_debug_file_by_buildid): Return
3780 std::string.
3781 * build-id.h (find_separate_debug_file_by_buildid): Return
3782 std::string.
3783 * coffread.c (coff_symfile_read): Adjust to std::string.
3784 * elfread.c (elf_symfile_read): Adjust to std::string.
3785 * symfile.c (separate_debug_file_exists): Change parameter to
3786 std::string.
3787 (find_separate_debug_file): Return std::string.
3788 (find_separate_debug_file_by_debuglink): Return std::string.
3789 * symfile.h (find_separate_debug_file_by_debuglink): Return
3790 std::string.
3791
e6a58aa8
SM
37922018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
3793
3794 * common/xml-utils.c (xml_escape_text): Move code to...
3795 (xml_escape_text_append): ... this new function.
3796 * common/xml-utils.h (xml_escape_text_append): New declaration.
3797 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
3798 New function.
3799 (_initialize_xml_utils): register test_xml_escape_text_append as
3800 a selftest.
3801
4ef0bef6
AH
38022018-03-07 Alan Hayward <alan.hayward@arm.com>
3803
3804 * defs.h: Remove MAX_REGISTER_SIZE.
3805 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
3806 asserts.
3807 * python/py-unwind.c (pyuw_sniffer): Likewise.
3808
e0d3522b
TT
38092018-03-07 Tom Tromey <tom@tromey.com>
3810
3811 * linux-tdep.c (linux_info_proc): Update.
3812 * target.h (struct target_ops) <to_fileio_readlink>: Return
3813 optional<string>.
3814 (target_fileio_readlink): Return optional<string>.
3815 * remote.c (remote_hostio_readlink): Return optional<string>.
3816 * inf-child.c (inf_child_fileio_readlink): Return
3817 optional<string>.
3818 * target.c (target_fileio_readlink): Return optional<string>.
3819
ea005f31
AB
38202018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
3821
3822 * regcache.c (cooked_read_test): Add riscv to the list of
3823 architectures that have a save_reggroup.
3824
e95a97d4
AA
38252018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
3826
3827 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
3828 value is not a dynamic class object.
3829
d8344f3d
TT
38302018-03-06 Tom Tromey <tom@tromey.com>
3831
3832 * rust-exp.y: Formatting fixes.
3833
9add17f2
AB
38342018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
3835
3836 * riscv-tdep.c (riscv_register_name): Remove target description
3837 support.
3838 (riscv_gdbarch_init): Remove target description check.
3839
c9486dfe
AB
38402018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
3841
3842 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
3843 comment.
3844 * riscv-tdep.h: Likewise.
3845
d74aff3d
AB
38462018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
3847
3848 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
3849 (riscv_pseudo_register_write): Delete.
3850 (riscv_gdbarch_init): Remove all use of pseudo registers.
3851
7ea78b59
SM
38522018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
3853
3854 * record-btrace.c (btrace_print_lines): Replace cleanup
3855 parameter with RAII equivalents.
3856 (btrace_insn_history): Replace cleanup with RAII equivalents.
3857 * ui-out.h (make_cleanup_ui_out_list_begin_end,
3858 make_cleanup_ui_out_tuple_begin_end): Remove.
3859 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
3860 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
3861 make_cleanup_ui_out_list_begin_end): Remove.
3862
53127008
SM
38632018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
3864
3865 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
3866 parameter types to std::vector. Use bool.
3867 (record_btrace_wait): Replace VEC(tp_t) with
3868 std::vector<thread_info *>.
3869 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
3870
228f1508
SM
38712018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
3872
3873 * record-btrace.c (record_btrace_disable_callback): Remove.
3874 (struct scoped_btrace_disable): New.
3875 (record_btrace_open): Use scoped_btrace_disable.
3876
b2970c23
AB
38772018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
3878
3879 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
3880 reading values from registers.
3881
fb294655
AB
38822018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
3883
3884 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
3885 where appropriate.
3886
cab5bb9d
AB
38872018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
3888
3889 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
3890 change parameter type. Use GDB's print functions, and use
3891 core_addr_to_string where appropriate.
3892 (riscv_push_dummy_call): Use core_addr_to_string where
3893 appropriate, update call to riscv_print_arg_location, and reindent
3894 a few lines.
3895 (riscv_return_value): Update call to riscv_print_arg_location.
3896
dbbb1059
AB
38972018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
3898 Tim Newsome <tim@sifive.com>
3899 Albert Ou <a0u@eecs.berkeley.edu>
3900 Darius Rad <darius@bluespec.com>
3901
3902 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
3903 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
3904 (ALLDEPFILES): Add riscv-tdep.c
3905 * configure.tgt: Add riscv support.
3906 * riscv-tdep.c: New file.
3907 * riscv-tdep.h: New file.
3908 * NEWS: Mention new target.
3909 * MAINTAINERS: Add entry for riscv.
3910
5dc43913
AB
39112018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
3912
3913 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
3914 fields within aggregates.
3915
3dea1ef7
SM
39162018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
3917
3918 * record-btrace.c (btrace_print_lines): Change type of flags to
3919 gdb_disassembly_flags.
3920
7efba073
JB
39212018-03-04 John Baldwin <jhb@FreeBSD.org>
3922
3923 * fbsd-nat.c: Include "inf-ptrace.h".
3924 (USE_SIGTRAP_SIGINFO): Conditionally define.
3925 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
3926 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
3927 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
3928 function.
3929 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
3930 Likewise.
3931 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
3932 Likewise.
3933 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
3934 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
3935 "supports_stopped_by_hw_breakpoint" target methods.
3936
386a8676
JB
39372018-03-04 John Baldwin <jhb@FreeBSD.org>
3938
3939 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
3940 * fbsd-nat.c (debug_fbsd_nat): New variable.
3941 (show_fbsd_nat_debug): New function.
3942 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
3943 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
3944
12279366
JB
39452018-03-04 John Baldwin <jhb@FreeBSD.org>
3946
3947 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
3948 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
3949 prototype.
3950 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
3951 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
3952 method.
3953
54693cf5
SM
39542018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3955
3956 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
3957 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
3958
ccb2231c
SM
39592018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3960
3961 * charset.c (struct charset_vector): New.
3962 (charsets): Change type to charset_vector.
3963 (find_charset_names): Adjust.
3964 (add_one): Adjust.
3965 (_initialize_charset): Adjust.
3966
6fb16ce6
SM
39672018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3968
3969 * progspace.h (struct program_space) <deleted_solibs>: Change
3970 type to std::vector<std::string>.
3971 * progspace.c (clear_program_space_solib_cache): Adjust.
3972 * breakpoint.c (print_solib_event): Adjust.
3973 (check_status_catch_solib): Adjust.
3974 * solib.c (update_solib_list): Adjust.
3975 * ui-out.h (class ui_out) <field_string>: New overload.
3976 * ui-out.c (ui_out::field_string): New overload.
3977
564b1e3f
SM
39782018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3979
3980 * progspace.h (struct program_space): Add constructor and
3981 destructor, initialize fields.
3982 (add_program_space): Remove.
3983 * progspace.c (add_program_space): Rename to...
3984 (program_space::program_space): ... this.
3985 (release_program_space): Rename to...
3986 (program_space::~program_space): ... this.
3987 (delete_program_space): Use delete to delete program_space.
3988 (initialize_progspace): Use new to allocate program_space.
3989 * inferior.c (add_inferior_with_spaces): Likewise.
3990 (clone_inferior_command): Likewise.
3991 * infrun.c (follow_fork_inferior): Likewise.
3992 (handle_vfork_child_exec_or_exit): Likewise.
3993
e80aaf61
SM
39942018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3995
3996 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
3997 (delim_string_to_char_ptr_vec): Return std::vector of
3998 gdb::unique_xmalloc_ptr.
3999 (dirnames_to_char_ptr_vec_append): Take std::vector of
4000 gdb::unique_xmalloc_ptr.
4001 (dirnames_to_char_ptr_vec): Return std::vector of
4002 gdb::unique_xmalloc_ptr.
4003 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
4004 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
4005 (delim_string_to_char_ptr_vec): Return an std::vector of
4006 gdb::unique_xmalloc_ptr, adjust the code.
4007 (dirnames_to_char_ptr_vec_append): Take an std::vector of
4008 gdb::unique_xmalloc_ptr, adjust the code.
4009 (dirnames_to_char_ptr_vec): Return an std::vector of
4010 gdb::unique_xmalloc_ptr, adjust the code.
4011 * auto-load.c (auto_load_safe_path_vec): Change type to
4012 std::vector of gdb::unique_xmalloc_ptr.
4013 (auto_load_expand_dir_vars): Return an std::vector of
4014 gdb::unique_xmalloc_ptr, adjust the code.
4015 (auto_load_safe_path_vec_update): Adjust.
4016 (filename_is_in_auto_load_safe_path_vec): Adjust.
4017 (auto_load_objfile_script_1): Adjust.
4018 * build-id.c (build_id_to_debug_bfd): Adjust.
4019 * linux-thread-db.c (thread_db_load_search): Adjust.
4020 * source.c (add_path): Adjust.
4021 (openp): Adjust.
4022 * symfile.c (find_separate_debug_file): Adjust.
4023 * utils.c (do_free_char_ptr_vec): Remove.
4024 (make_cleanup_free_char_ptr_vec): Remove.
4025
ab818ade
SDJ
40262018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
4027
4028 PR gdb/22907
4029 * common/pathstuff.c: Conditionally include "<windows.h>".
4030
e1e6f073
GS
40312018-03-01 Georg Sauthoff <mail@georg.so>
4032
4033 PR gdb/22888
4034 * gcore.in: Quote variables and switch interpreter to bash.
4035
c7b15a66
TT
40362018-03-01 Tom Tromey <tom@tromey.com>
4037
4038 * dwarf2read.c (alloc_discriminant_info): Fix default_index
4039 assertion. Add assertion for discriminant_index.
4040 (quirk_rust_enum): Use correct base type name in univariant case.
4041
0cb7c7b0
SM
40422018-03-01 Simon Marchi <simon.marchi@ericsson.com>
4043
4044 * record.c (get_call_history_modifiers): Return a
4045 record_print_flags.
4046 (cmd_record_call_history): Adjust.
4047 * record-btrace.c (record_btrace_call_history): Adjust.
4048 (record_btrace_call_history_range): Adjust.
4049 (record_btrace_call_history_from): Adjust.
4050 * target-debug.h (target_debug_print_record_print_flags): New.
4051 * target-delegates.c: Re-generate.
4052 * target.c (target_call_history): Change flags type.
4053 (target_call_history_from): Likewise.
4054 (target_call_history_range): Likewise.
4055 * target.h (struct target_ops) <target_call_history>: Likewise.
4056 (target_call_history_from): Likewise.
4057 (target_call_history_range): Likewise.
4058
25e3c82c
SDJ
40592018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
4060 Simon Marchi <simon.marchi@polymtl.ca>
4061
4062 * common/common-utils.c: Include "sys/stat.h".
4063 (is_regular_file): Move here from "source.c"; change return
4064 type to "bool".
4065 * common/common-utils.h (is_regular_file): New prototype.
4066 * common/pathstuff.c (contains_dir_separator): New function.
4067 * common/pathstuff.h (contains_dir_separator): New prototype.
4068 * source.c: Don't include "sys/stat.h".
4069 (is_regular_file): Move to "common/common-utils.c".
4070
b4987c95
SDJ
40712018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
4072
4073 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
4074 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
4075 * auto-load.c: Include "common/pathstuff.h".
4076 * common/common-def.h (current_directory): Move here.
4077 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
4078 function.
4079 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
4080 prototype.
4081 * common/pathstuff.c: New file.
4082 * common/pathstuff.h: New file.
4083 * compile/compile.c: Include "common/pathstuff.h".
4084 * defs.h (current_directory): Move to "common/common-defs.h".
4085 * dwarf2read.c: Include "common/pathstuff.h".
4086 * exec.c: Likewise.
4087 * guile/scm-safe-call.c: Likewise.
4088 * linux-thread-db.c: Likewise.
4089 * main.c: Likewise.
4090 * nto-tdep.c: Likewise.
4091 * objfiles.c: Likewise.
4092 * source.c: Likewise.
4093 * symtab.c: Likewise.
4094 * utils.c: Include "common/pathstuff.h".
4095 (gdb_realpath): Move to "common/pathstuff.c".
4096 (gdb_realpath_keepfile): Likewise.
4097 (gdb_abspath): Likewise.
4098 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
4099 (gdb_realpath_keepfile): Likewise.
4100 (gdb_abspath): Likewise.
4101
f169cfdc
JB
41022018-02-28 John Baldwin <jhb@FreeBSD.org>
4103
4104 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
4105 wildcard process pid for super_resume for kernels with a
4106 specific bug.
4107
e05cac70
PM
41082018-02-27 Phil Muldoon <pmuldoon@redhat.com>
4109
4110 * compile/compile.c (get_args): Add additional comments
4111 explaining function.
4112
55089490
TT
41132018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
4114 Tom Tromey <tom@tromey.com>
4115
4116 * target.h (memory_write_request_s): Remove typedef. Don't define
4117 VEC.
4118 (target_write_memory_blocks): Change argument to std::vector.
4119 (struct memory_write_request): Add constructor.
4120 * target-memory.c (compare_block_starting_address): Return bool.
4121 Change argument types.
4122 (claim_memory): Change arguments to use std::vector.
4123 (split_regular_and_flash_blocks, blocks_to_erase)
4124 (compute_garbled_blocks): Likewise.
4125 (cleanup_request_data, cleanup_write_requests_vector): Remove.
4126 (target_write_memory_blocks): Change argument to std::vector.
4127 * symfile.c (struct load_section_data): Add constructor and
4128 destructor. Use std::vector for "requests".
4129 (struct load_progress_data): Add initializers.
4130 (load_section_callback): Update. Use "new".
4131 (clear_memory_write_data): Remove.
4132 (generic_load): Update.
4133
0c305b61
AH
41342018-02-27 Alan Hayward <alan.hayward@arm.com>
4135
4136 * arch/aarch64.h: Use common/tdesc.h.
4137
c5196c92
MR
41382018-02-26 Maciej W. Rozycki <macro@mips.com>
4139
4140 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
4141 architecture with a 64-bit ABI.
4142
37c33887
MR
41432018-02-26 Maciej W. Rozycki <macro@mips.com>
4144
4145 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
4146 ahead of target description loading.
4147
d4dd3282
TT
41482018-02-26 Tom Tromey <tom@tromey.com>
4149
4150 * stack.c (backtrace_command_1): Update.
4151 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
4152 of "flags".
4153 * python/py-framefilter.c (py_print_frame)
4154 (gdbpy_apply_frame_filter): Change type of "flags".
4155 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
4156 of "flags".
4157 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
4158 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
4159 * extension.h (enum frame_filter_flag): Rename from
4160 frame_filter_flags.
4161 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
4162 (apply_ext_lang_frame_filter): Change type of "flags".
4163 * extension.c (apply_ext_lang_frame_filter): Change type of
4164 "flags".
4165 * extension-priv.h (struct extension_language_ops)
4166 <apply_frame_filter>: Change type of "flags".
4167
6893c19a
TT
41682018-02-26 Tom Tromey <tom@tromey.com>
4169
4170 PR python/16497:
4171 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
4172 off-by-one in py_end computation.
4173 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
4174 PRINT_MORE_FRAMES.
4175 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
4176 constant.
4177
2ddeaf8a
TT
41782018-02-26 Tom Tromey <tom@tromey.com>
4179
4180 * dwarf2read.c (struct variant_field): New.
4181 (struct nextfield) <variant>: New field.
4182 (dwarf2_add_field): Handle DW_TAG_variant_part.
4183 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
4184 discriminated union.
4185 (read_structure_type): Handle DW_TAG_variant_part.
4186 (handle_struct_member_die): New function, extracted from
4187 process_structure_scope. Handle DW_TAG_variant.
4188 (process_structure_scope): Handle discriminated unions. Call
4189 handle_struct_member_die.
4190
c9317f21
TT
41912018-02-26 Tom Tromey <tom@tromey.com>
4192
4193 * rust-lang.h (rust_last_path_segment): Declare.
4194 * rust-lang.c (rust_last_path_segment): Now public. Change
4195 contract.
4196 (struct disr_info): Remove.
4197 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
4198 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
4199 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
4200 (rust_enum_p, rust_enum_variant): New function.
4201 (rust_underscore_fields): Remove "offset" parameter.
4202 (rust_print_enum): New function.
4203 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
4204 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
4205 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
4206 enums.
4207 (rust_internal_print_type): New function, from rust_print_type.
4208 Remove enum code.
4209 (rust_print_type): Call rust_internal_print_type.
4210 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
4211 Update enum handling.
4212 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
4213 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
4214 (rust_union_quirks): New functions.
4215 (process_full_comp_unit, process_full_type_unit): Call
4216 rust_union_quirks.
4217 (process_structure_scope): Update rust_unions if necessary.
4218
7c22600a
TT
42192018-02-26 Tom Tromey <tom@tromey.com>
4220
4221 * value.h (value_union_variant): Declare.
4222 * valops.c (value_union_variant): New function.
4223 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
4224 (struct discriminant_info): New.
4225 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
4226 enumerator.
4227 (struct main_type) <flag_discriminated_union>: New field.
4228
15ce8941
TT
42292018-02-26 Tom Tromey <tom@tromey.com>
4230
4231 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4232 unittests/unpack-selftests.c.
4233 * unittests/unpack-selftests.c: New file.
4234 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
4235
48fbe735
YQ
42362018-02-26 Yao Qi <yao.qi@linaro.org>
4237
4238 * dwarf2read.c (struct partial_die_info) <read>: New method.
4239 (read_partial_die): Remove the declaration.
4240 (load_partial_dies): Update.
4241 (partial_die_info::partial_die_info):
4242 (read_partial_die): Change it to partial_die_info::read.
4243
52356b79
YQ
42442018-02-26 Yao Qi <yao.qi@linaro.org>
4245
4246 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
4247 (fixup_partial_die): Remove declaration.
4248 (scan_partial_symbols): Update.
4249 (partial_die_parent_scope): Likewise.
4250 (partial_die_full_name): Likewise.
4251 (fixup_partial_die): Change it to partial_die_info::fixup.
4252
35cc7ed7
YQ
42532018-02-26 Yao Qi <yao.qi@linaro.org>
4254
4255 * dwarf2read.c (read_partial_die): Update the declaration.
4256 (load_partial_dies): Caller update.
4257 (read_partial_die): Remove one argument abbrev_len.
4258
6f06d47b
YQ
42592018-02-26 Yao Qi <yao.qi@linaro.org>
4260
4261 * dwarf2read.c (struct partial_die_info): Add ctor, delete
4262 assignment operator.
4263 (load_partial_dies): Use ctor and copy ctor.
4264 (read_partial_die): Update.
4265 (dwarf2_cu::find_partial_die): Use ctor.
4266
d590ff25
YQ
42672018-02-26 Yao Qi <yao.qi@linaro.org>
4268
4269 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
4270 (find_partial_die_in_comp_unit): Change it to
4271 dwarf2_cu::find_partial_die.
4272 (find_partial_die): Update.
4273
fd0a254f
YQ
42742018-02-26 Yao Qi <yao.qi@linaro.org>
4275
4276 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
4277 is NULL.
4278
cd9983dd
YQ
42792018-02-26 Yao Qi <yao.qi@linaro.org>
4280
4281 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
4282
f46cd62a
AH
42832018-02-26 Alan Hayward <alan.hayward@arm.com>
4284
4285 * arch/amd64.h: Use common/tdesc.h.
4286 * arch/i386.c: Likewise.
4287 * arch/i386.h: Likewise.
4288 * arch/tic6x.c: Likewise.
4289 * arch/tdesc.h: Move file from here...
4290 * common/tdesc.h: ...to here.
4291 * features/aarch64-core.c: Regenerate.
4292 * features/aarch64-fpu.c: Regenerate.
4293 * features/i386/32bit-avx.c: Regenerate.
4294 * features/i386/32bit-avx512.c: Regenerate.
4295 * features/i386/32bit-core.c: Regenerate.
4296 * features/i386/32bit-linux.c: Regenerate.
4297 * features/i386/32bit-mpx.c: Regenerate.
4298 * features/i386/32bit-pkeys.c: Regenerate.
4299 * features/i386/32bit-sse.c: Regenerate.
4300 * features/i386/64bit-avx.c: Regenerate.
4301 * features/i386/64bit-avx512.c: Regenerate.
4302 * features/i386/64bit-core.c: Regenerate.
4303 * features/i386/64bit-linux.c: Regenerate.
4304 * features/i386/64bit-mpx.c: Regenerate.
4305 * features/i386/64bit-pkeys.c: Regenerate.
4306 * features/i386/64bit-segments.c: Regenerate.
4307 * features/i386/64bit-sse.c: Regenerate.
4308 * features/i386/x32-core.c: Regenerate.
4309 * features/tic6x-c6xp.c: Regenerate.
4310 * features/tic6x-core.c: Regenerate.
4311 * features/tic6x-gp.c: Regenerate.
4312 * target-descriptions.c: Use common/tdesc.h.
4313 * target-descriptions.h: Likewise.
4314
9b292f68
TT
43152018-02-24 Tom Tromey <tom@tromey.com>
4316
4317 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
4318 (try_thread_db_load_from_dir, thread_db_load_search): Use
4319 std::string.
4320 (info_auto_load_libthread_db_compare): Return bool. Change
4321 argument types.
4322 (info_auto_load_libthread_db): Use std::vector, std::string.
4323 Remove cleanups.
4324
281d762b
TT
43252018-02-24 Tom Tromey <tom@tromey.com>
4326
4327 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
4328 std::string.
4329 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
4330 std::string*.
4331 * gdbarch.c: Rebuild.
4332 * gdbarch.h: Rebuild.
4333 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
4334 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
4335 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
4336 std::string*.
4337
9d8780f0
SM
43382018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
4339
4340 * gdbtypes.h (sect_offset): Change type to uint64_t.
4341 (sect_offset_str): New function.
4342 * dwarf2read.c (create_addrmap_from_aranges): Use
4343 sect_offset_str.
4344 (error_check_comp_unit_head): Likewise.
4345 (create_debug_type_hash_table): Likewise.
4346 (read_cutu_die_from_dwo): Likewise.
4347 (init_cutu_and_read_dies): Likewise.
4348 (init_cutu_and_read_dies_no_follow): Likewise.
4349 (process_psymtab_comp_unit_reader): Likewise.
4350 (partial_die_parent_scope): Likewise.
4351 (peek_die_abbrev): Likewise.
4352 (process_queue): Likewise.
4353 (dwarf2_physname): Likewise.
4354 (read_namespace_alias): Likewise.
4355 (read_import_statement): Likewise.
4356 (create_dwo_cu_reader): Likewise.
4357 (create_cus_hash_table): Likewise.
4358 (lookup_dwo_cutu): Likewise.
4359 (inherit_abstract_dies): Likewise.
4360 (read_func_scope): Likewise.
4361 (read_call_site_scope): Likewise.
4362 (dwarf2_add_member_fn): Likewise.
4363 (read_common_block): Likewise.
4364 (read_module_type): Likewise.
4365 (read_typedef): Likewise.
4366 (read_subrange_type): Likewise.
4367 (load_partial_dies): Likewise.
4368 (read_partial_die): Likewise.
4369 (find_partial_die): Likewise.
4370 (read_str_index): Likewise.
4371 (dwarf2_string_attr): Likewise.
4372 (build_error_marker_type): Likewise.
4373 (lookup_die_type): Likewise.
4374 (dump_die_shallow): Likewise.
4375 (follow_die_ref): Likewise.
4376 (dwarf2_fetch_die_loc_sect_off): Likewise.
4377 (dwarf2_fetch_constant_bytes): Likewise.
4378 (follow_die_sig): Likewise.
4379 (get_signatured_type): Likewise.
4380 (get_DW_AT_signature_type): Likewise.
4381 (dwarf2_find_containing_comp_unit): Likewise.
4382 (set_die_type): Likewise.
4383
8ec57239
JB
43842018-02-21 John Baldwin <jhb@FreeBSD.org>
4385
4386 * arch/aarch64.c: Include "common-defs.h".
4387 * arch/amd64.c: Likewise.
4388 * arch/i386.c: Likewise.
4389
3eac2b65
TT
43902018-02-21 Tom Tromey <tom@tromey.com>
4391
4392 * value.h: (extract_field_op): Update.
4393 * eval.c (extract_field_op): Return a const char *.
4394 * expression.h (parse_expression_for_completion): Update.
4395 * completer.c (complete_expression): Update.
4396 (add_struct_fields): Make fieldname const.
4397 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
4398 (mark_completion_tag, parse_exp_in_context_1): Update.
4399 (parse_expression_for_completion): Change "name" to
4400 unique_xmalloc_ptr*.
4401
6ccb583f
TT
44022018-02-21 Tom Tromey <tom@tromey.com>
4403
4404 * infcall.c (call_function_by_hand_dummy): Use std::vector.
4405
c113ed0c
YQ
44062018-02-21 Yao Qi <yao.qi@linaro.org>
4407
4408 * avr-tdep.c (avr_read_pc): Change parameter type to
4409 readable_regcache.
4410 * gdbarch.sh (read_pc): Likewise.
4411 * gdbarch.c: Re-generated.
4412 * gdbarch.h: Re-generated.
4413 * hppa-tdep.c (hppa_read_pc): Change parameter type to
4414 readable_regcache.
4415 * ia64-tdep.c (ia64_read_pc): Likewise.
4416 * mips-tdep.c (mips_read_pc): Likewise.
4417 * spu-tdep.c (spu_read_pc): Likewise.
4418
4c74fe6b
YQ
44192018-02-21 Yao Qi <yao.qi@linaro.org>
4420
4421 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
4422 * regcache-dump.c: New file.
4423 * regcache.c: Move register_dump to regcache-dump.c.
4424 (maintenance_print_registers): Likewise.
4425 (maintenance_print_raw_registers): Likewise.
4426 (maintenance_print_cooked_registers): Likewise.
4427 (maintenance_print_register_groups): Likewise.
4428 (maintenance_print_remote_registers): Likewise.
4429 (_initialize_regcache): Likewise.
4430 * regcache.h (register_dump): Moved from regcache.c.
4431
796bb026
YQ
44322018-02-21 Yao Qi <yao.qi@linaro.org>
4433
4434 * regcache.c (regcache::regcache): Update.
4435 (regcache::invalidate): Move it to detached_regcache::invalidate.
4436 (get_thread_arch_aspace_regcache): Update.
4437 (regcache::raw_update): Update.
4438 (regcache::cooked_read): Remove some code.
4439 (regcache::cooked_read_value): Likewise.
4440 (regcache::raw_write): Remove assert on m_readonly_p.
4441 (regcache::raw_supply_integer): Move it to
4442 detached_regcache::raw_supply_integer.
4443 (regcache::raw_supply_zeroed): Likewise.
4444 * regcache.h (detached_regcache) <raw_supply_integer>: New
4445 declaration.
4446 <raw_supply_zeroed, invalidate>: Likewise.
4447 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
4448 <invalidate>: Likewise.
4449 <m_readonly_p>: Removed.
4450
215c69dc
YQ
44512018-02-21 Yao Qi <yao.qi@linaro.org>
4452
4453 * infcmd.c (get_return_value): Let stop_regs point to
4454 get_current_regcache.
4455 * regcache.c (regcache::regcache): Remove.
4456 (register_dump_reg_buffer): New class.
4457 (regcache_print): Adjust.
4458 * regcache.h (regcache): Remove constructors.
4459
f3384e66
YQ
44602018-02-21 Yao Qi <yao.qi@linaro.org>
4461
4462 * regcache.c (class register_dump): New class.
4463 (register_dump_regcache, register_dump_none): New class.
4464 (register_dump_remote, register_dump_groups): New class.
4465 (regcache_print): Update.
4466 * regcache.h (regcache_dump_what): Move it to regcache.c.
4467 (regcache) <dump>: Remove.
4468
c8ec2f33
YQ
44692018-02-21 Yao Qi <yao.qi@linaro.org>
4470
4471 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
4472 reg_buffer_rw *.
4473 (jit_unwind_reg_set_impl): Call raw_supply.
4474 (jit_frame_sniffer): Use reg_buffer_rw.
4475 * record-full.c (record_full_core_regbuf): Change its type.
4476 (record_full_core_open_1): Use reg_buffer_rw.
4477 (record_full_close): Likewise.
4478 (record_full_core_fetch_registers): Use regcache->raw_supply.
4479 (record_full_core_store_registers): Likewise.
4480 * regcache.c (regcache::get_register_status): Move it to
4481 reg_buffer.
4482 (regcache_raw_set_cached_value): Remove.
4483 (regcache::raw_set_cached_value): Remove.
4484 (regcache::raw_write): Call raw_supply.
4485 (regcache::raw_supply): Move it to reg_buffer_rw.
4486 * regcache.h (regcache_raw_set_cached_value): Remove.
4487 (reg_buffer_rw): New class.
4488
daf6667d
YQ
44892018-02-21 Yao Qi <yao.qi@linaro.org>
4490
4491 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
4492 readonly_detached_regcache.
4493 (dummy_frame_prev_register): Use regcache->cooked_read.
4494 * frame.c (frame_save_as_regcache): Change return type.
4495 (frame_pop): Update.
4496 * frame.h (frame_save_as_regcache): Update declaration.
4497 * inferior.h (get_infcall_suspend_state_regcache): Update
4498 declaration.
4499 * infrun.c (infcall_suspend_state) <registers>: use
4500 readonly_detached_regcache.
4501 (save_infcall_suspend_state): Don't use regcache_dup.
4502 (get_infcall_suspend_state_regcache): Change return type.
4503 * linux-fork.c (struct fork_info) <savedregs>: Change to
4504 readonly_detached_regcache.
4505 <pc>: New field.
4506 (fork_save_infrun_state): Don't use regcache_dup.
4507 (info_checkpoints_command): Adjust.
4508 * mi/mi-main.c (register_changed_p): Update declaration.
4509 (mi_cmd_data_list_changed_registers): Use
4510 readonly_detached_regcache.
4511 (register_changed_p): Change parameter type to
4512 readonly_detached_regcache.
4513 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
4514 readonly_detached_regcache.
4515 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
4516 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
4517 New.
4518 (regcache::save): Move it to reg_buffer.
4519 (regcache::restore): Change parameter type.
4520 (regcache_dup): Remove.
4521 * regcache.h (reg_buffer) <save>: New method.
4522 (readonly_detached_regcache): New class.
4523 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
4524 readonly_detached_regcache.
4525 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
4526
fc5b8736
YQ
45272018-02-21 Yao Qi <yao.qi@linaro.org>
4528
4529 * frame.c (frame_save_as_regcache): Use regcache method save.
4530 (frame_pop): Use regcache method restore.
4531 * infrun.c (restore_infcall_suspend_state): Likewise.
4532 * linux-fork.c (fork_load_infrun_state): Likewise.
4533 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
4534 save.
4535 * regcache.c (regcache_save): Remove.
4536 (regcache::restore): More asserts.
4537 (regcache_cpy): Remove.
4538 * regcache.h (regcache_save): Remove the declaration.
4539 (regcache::restore): Move from private to public.
4540 Remove the friend declaration of regcache_cpy.
4541 (regcache_cpy): Remove declaration.
4542
849d0ba8
YQ
45432018-02-21 Yao Qi <yao.qi@linaro.org>
4544
4545 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
4546 parameter type to 'readable_regcache *'.
4547 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
4548 * arm-tdep.c (arm_neon_quad_read): Likewise.
4549 (arm_pseudo_read): Likewise.
4550 * avr-tdep.c (avr_pseudo_register_read): Likewise.
4551 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
4552 * frv-tdep.c (frv_pseudo_register_read): Likewise.
4553 * gdbarch.c: Re-generated.
4554 * gdbarch.h: Re-generated.
4555 * gdbarch.sh (pseudo_register_read): Change parameter type to
4556 'readable_regcache *'.
4557 (pseudo_register_read_value): Likewise.
4558 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
4559 (h8300_pseudo_register_read): Likewise.
4560 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
4561 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
4562 (i386_pseudo_register_read_into_value): Likewise.
4563 (i386_pseudo_register_read_value): Likewise.
4564 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
4565 declaration.
4566 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
4567 * m32c-tdep.c (m32c_raw_read): Likewise.
4568 (m32c_read_flg): Likewise.
4569 (m32c_banked_register): Likewise.
4570 (m32c_banked_read): Likewise.
4571 (m32c_sb_read): Likewise.
4572 (m32c_part_read): Likewise.
4573 (m32c_cat_read): Likewise.
4574 (m32c_r3r2r1r0_read): Likewise.
4575 (m32c_pseudo_register_read): Likewise.
4576 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
4577 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
4578 (mep_pseudo_cr64_read): Likewise.
4579 (mep_pseudo_register_read): Likewise.
4580 * mips-tdep.c (mips_pseudo_register_read): Likewise.
4581 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
4582 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
4583 * regcache.c (regcache::raw_read): Move it to readable_regcache.
4584 (regcache::cooked_read): Likewise.
4585 (regcache::cooked_read_value): Likewise.
4586 (regcache_cooked_read_signed):
4587 (regcache::cooked_read): Likewise.
4588 * regcache.h (readable_regcache): New class.
4589 (regcache): Inherit readable_regcache. Move some methods to
4590 readable_regcache.
4591 * rl78-tdep.c (rl78_pseudo_register_read): Change
4592 parameter type to 'readable_regcache *'.
4593 * rs6000-tdep.c (do_regcache_raw_read): Remove.
4594 (e500_pseudo_register_read): Change parameter type to
4595 'readable_regcache *'.
4596 (dfp_pseudo_register_read): Likewise.
4597 (vsx_pseudo_register_read): Likewise.
4598 (efpr_pseudo_register_read): Likewise.
4599 * s390-tdep.c (s390_pseudo_register_read): Likewise.
4600 * sh-tdep.c (sh_pseudo_register_read): Likewise.
4601 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
4602 (sh64_pseudo_register_read): Likewise.
4603 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
4604 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
4605 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
4606 (spu_pseudo_register_read): Likewise.
4607 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
4608 (xtensa_pseudo_register_read): Likewise.
4609
31716595
YQ
46102018-02-21 Yao Qi <yao.qi@linaro.org>
4611
4612 * regcache.c (regcache::regcache): Call reg_buffer ctor.
4613 (regcache::arch): Move it to reg_buffer::arch.
4614 (regcache::register_buffer): Likewise.
4615 (regcache::assert_regnum): Likewise.
4616 (regcache::num_raw_registers): Likewise.
4617 * regcache.h (reg_buffer): New class.
4618 (regcache): Inherit reg_buffer.
4619
7104e59b
SM
46202018-02-20 Simon Marchi <simon.marchi@ericsson.com>
4621
4622 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
4623 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
4624
2d8adcbd
MM
46252018-02-20 Markus Metzger <markus.t.metzger@intel.com>
4626
4627 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
4628
b5884fa7
AH
46292018-02-19 Alan Hayward <alan.hayward@arm.com>
4630
4631 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
4632 (SFILES): Remove common/*.c files.
4633 (COMMON_OBS): Remove some *.o files built from common/*.c files.
4634 * common/common.host: Add common reference.
4635 * configure.ac: Likewise.
4636 * configure: Regenerate.
4637
fd90ace4
YQ
46382018-02-16 Yao Qi <yao.qi@linaro.org>
4639
4640 * block.c (block_namespace_info): Inherit allocate_on_obstack.
4641 (block_initialize_namespace): Use new.
4642 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
4643 (dwarf2_free_objfile): Use delete.
4644 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
4645 (copy_type_recursive): Use new.
4646 * gdb_obstack.h (allocate_on_obstack): New.
4647
85046ae2
YQ
46482018-02-15 Yao Qi <yao.qi@linaro.org>
4649
4650 PR gdb/22849
4651 * inferior.c (exit_inferior_1): Reset inf->control.
4652
355c559b
JB
46532018-02-15 Joel Brobecker <brobecker@adacore.com>
4654
4655 * ada-lang.c (ada_to_fixed_value_create): Delete advance
4656 declaration.
4657
980548fd
PA
46582018-02-14 Pedro Alves <palves@redhat.com>
4659
4660 * frame-unwind.c (frame_unwind_try_unwinder): Always call
4661 frame_cleanup_after_sniffer on exception.
4662
692d6f97
TT
46632018-02-14 Tom Tromey <tom@tromey.com>
4664
4665 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
4666 const.
4667 (solib_bfd_open): Make pathname const.
4668 * solib.c (solib_bfd_open): Make pathname const.
4669 * solib-spu.c (spu_bfd_fopen): Make name const.
4670 (spu_bfd_open): Make pathname const.
4671 * solib-darwin.c (darwin_bfd_open): Make pathname const.
4672 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
4673
e0cc99a6
TT
46742018-02-14 Tom Tromey <tom@tromey.com>
4675
4676 * symfile.c (symfile_bfd_open): Update.
4677 * source.h (openp, source_full_path_of, find_and_open_source):
4678 Change argument type to unique_xmalloc_ptr.
4679 * source.c (openp): Take a unique_xmalloc_ptr.
4680 (source_full_path_of, find_and_open_source): Likewise.
4681 (open_source_file, symtab_to_fullname): Update.
4682 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
4683 unique_xmalloc_ptr.
4684 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
4685 (exec_file_find): Update.
4686 * psymtab.c (psymtab_to_fullname): Update.
4687 * nto-tdep.h (nto_find_and_open_solib): Update.
4688 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
4689 unique_xmalloc_ptr.
4690 * exec.c (exec_file_attach): Update.
4691 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
4692 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
4693
b46a8d7c
TT
46942018-02-14 Tom Tromey <tom@tromey.com>
4695
4696 * solib.c: Include source.h.
4697 * nto-tdep.c: Include source.h.
4698 * mi/mi-cmd-env.c: Include source.h.
4699 * infcmd.c: Include source.h.
4700 * exec.c: Include source.h.
4701 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
4702 (add_path, directory_switch, source_path, init_source_path): Move
4703 declarations...
4704 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
4705 (add_path, directory_switch, source_path, init_source_path):
4706 ...here.
4707
797bc1cb
TT
47082018-02-14 Tom Tromey <tom@tromey.com>
4709
4710 * solist.h (exec_file_find, solib_find): Return
4711 unique_xmalloc_ptr.
4712 (solib_bfd_fopen): Take a const char *.
4713 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
4714 (exec_file_find, solib_find): Likewise.
4715 (solib_bfd_fopen): Do not take ownership of "pathname".
4716 (solib_bfd_open): Use unique_xmalloc_ptr.
4717 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
4718 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
4719 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
4720 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
4721
f98b2e33
JB
47222018-02-14 Joel Brobecker <brobecker@adacore.com>
4723
4724 * ada-lang.c (name_match_type_from_name): Remove reference to
4725 ada_name_for_lookup in function's documentation.
4726 * ada-lang.h (ada_name_for_lookup): Delete declaration.
4727
24b9144d
SM
47282018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
4729
4730 * defs.h (enum openp_flags): New enum.
4731 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
4732 Move to enum openp_flags.
4733 (openp_flags): New enum flags.
4734 (openp): Change parameter type to openp_flags.
4735 * source.c (openp): Change parameter type to openp_flags.
4736 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
4737 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
4738
387cd15b
SM
47392018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
4740
4741 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
4742 per-command.
4743
b303c6f6
AB
47442018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
4745
4746 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
4747 into...
4748 (class dwarf2_queue_guard): ...the destructor of this new class.
4749 (dw2_do_instantiate_symtab): Create instance of the new class
4750 dwarf2_queue_guard, remove cleanup.
4751
9c3630e9
TT
47522018-02-09 Tom Tromey <tom@tromey.com>
4753
4754 * source.c (find_source_lines): Don't reference past the end of
4755 the vector.
4756
c4e12631
MM
47572018-02-09 Markus Metzger <markus.t.metzger@intel.com>
4758
4759 * remote.c (remote_btrace_maybe_reopen): Change error message.
4760 * btrace.c (btrace_enable): Likewise.
4761 (parse_xml_btrace): Likewise.
4762 (parse_xml_btrace_conf): Likewise.
4763
88711fbf
MM
47642018-02-09 Markus Metzger <markus.t.metzger@intel.com>
4765
4766 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
4767 (linux_enable_pt, linux_enable_bts): Call
4768 diagnose_perf_event_open_fail.
4769
17ad2a4f
MM
47702018-02-09 Markus Metzger <markus.t.metzger@intel.com>
4771
4772 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
4773 Remove parameter and change return type. Update callers. Move it.
4774 (linux_enable_bts, linux_enable_pt): Improve error message.
4775 (linux_enable_pt): Remove zero buffer size check.
4776 (linux_enable_btrace): Improve error messages. Remove NULL return
4777 check.
4778
de6242d3
MM
47792018-02-09 Markus Metzger <markus.t.metzger@intel.com>
4780
4781 * btrace.c (btrace_enable): Remove target_supports_btrace call.
4782 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
4783 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
4784 (linux_supports_pt, linux_supports_btrace): Remove.
4785 (linux_enable_bts): Call cpu_supports_bts.
4786 * nat/linux-btrace.h (linux_supports_btrace): Remove.
4787 * remote.c (remote_supports_btrace): Remove.
4788 (init_remote_ops): Remove remote_supports_btrace.
4789 * target-delegates.c: Regenerated.
4790 * target.c (target_supports_btrace): Remove.
4791 * target.h (target_ops) <to_supports_btrace>: Remove
4792 (target_supports_btrace): Remove.
4793 * x86-linux-nat.c (x86_linux_create_target): Remove
4794 linux_supports_btrace.
4795
9ee23a85
MM
47962018-02-09 Markus Metzger <markus.t.metzger@intel.com>
4797
4798 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
4799 btrace failed.
4800 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
4801 exception and use message in own exception.
4802
5c3284c1
MM
48032018-02-09 Markus Metzger <markus.t.metzger@intel.com>
4804
4805 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
4806 (perf_event_pt_event_type): Use gdb_file_up.
4807 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
4808 scoped_fd, and scoped_mmap.
4809
84696f37
MM
48102018-02-09 Markus Metzger <markus.t.metzger@intel.com>
4811
4812 * common/scoped_mmap.h: New.
4813 * unittests/scoped_mmap-selftest.c: New.
4814 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4815 unittests/scoped_mmap-selftest.c.
4816
ea4a0888
MM
48172018-02-09 Markus Metzger <markus.t.metzger@intel.com>
4818
4819 * common/scoped_fd.h: New.
4820 * unittests/scoped_fd-selftest.c: New.
4821 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4822 unittests/scoped_fd-selftest.c.
4823
869e8290
TT
48242018-02-09 Tom Tromey <tom@tromey.com>
4825
4826 * auto-load.c (auto_load_section_scripts): Use
4827 gdb::unique_xmalloc_ptr.
4828
a37a2ae7
TT
48292018-02-09 Tom Tromey <tom@tromey.com>
4830
4831 * auto-load.c (execute_script_contents): Use std::string.
4832
4e725347
JB
48332018-02-09 Joel Brobecker <brobecker@adacore.com>
4834
4835 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
4836 Python function, rather than a new command.
4837
9a897d43
TT
48382018-02-08 Tom Tromey <tom@tromey.com>
4839
4840 * solib.c (solib_find_1): Use std::string.
4841 (solib_bfd_fopen): Use unique_xmalloc_ptr.
4842
58ef3771
TT
48432018-02-08 Tom Tromey <tom@tromey.com>
4844
4845 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
4846
a9abc434
TT
48472018-02-08 Tom Tromey <tom@tromey.com>
4848
4849 * source.c (find_source_lines): Use gdb::def_vector.
4850
84f27c6f
TT
48512018-02-08 Tom Tromey <tom@tromey.com>
4852
4853 * macrocmd.c (struct temporary_macro_definition): New.
4854 (macro_define_command): Use temporary_macro_definition. Remove
4855 cleanups.
4856 (free_macro_definition_ptr): Remove.
4857
0354904b
TT
48582018-02-08 Tom Tromey <tom@tromey.com>
4859
4860 * macroexp.c (maybe_expand): Use std::string.
4861
1739cf24
TT
48622018-02-08 Tom Tromey <tom@tromey.com>
4863
4864 * macroexp.c (struct macro_buffer): Add initializers for some
4865 members.
4866 (init_buffer, init_shared_buffer, free_buffer)
4867 (free_buffer_return_text): Remove.
4868 (macro_buffer): New constructors.
4869 (~macro_buffer): New destructor.
4870 (macro_buffer::set_shared): New method.
4871 (macro_buffer::resize_buffer, macro_buffer::appendc)
4872 (macro_buffer::appendmem): Now methods, not free functions.
4873 (set_token, append_tokens_without_splicing, stringify)
4874 (macro_stringify): Update.
4875 (gather_arguments): Change return type. Remove argc_p argument,
4876 add args_ptr argument. Use std::vector.
4877 (substitute_args): Remove argc argument. Accept std::vector.
4878 (expand): Update. Use std::vector.
4879 (scan, macro_expand, macro_expand_next): Update.
4880
f6c2623e
TT
48812018-02-08 Tom Tromey <tom@tromey.com>
4882
4883 * symtab.c (default_collect_symbol_completion_matches_break_on):
4884 Use unique_xmalloc_ptr.
4885 * macroscope.h: (sal_macro_scope, user_macro_scope)
4886 (default_macro_scope): Return unique_xmalloc_ptr.
4887 * macroscope.c (sal_macro_scope, user_macro_scope)
4888 (default_macro_scope): Return unique_xmalloc_ptr.
4889 * macroexp.h (macro_expand, macro_expand_once): Return
4890 unique_xmalloc_ptr.
4891 * macroexp.c (macro_expand, macro_expand_once): Return
4892 unique_xmalloc_ptr.
4893 * macrocmd.c (macro_expand_command, macro_expand_once_command)
4894 (info_macro_command, info_macros_command): Use
4895 unique_xmalloc_ptr.
4896 * compile/compile-c-support.c (write_macro_definitions): Use
4897 unique_xmalloc_ptr.
4898 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
4899
c2e0e465
SM
49002018-02-07 Simon Marchi <simon.marchi@ericsson.com>
4901
4902 * value.c (value_static_field): Assign field type instead of
4903 containing type when returning an optimized out value.
4904
3f8c94b4
YQ
49052018-02-06 Yao Qi <yao.qi@linaro.org>
4906
4907 * ft32-tdep.c (ft32_read_pc): Remove.
4908 (ft32_write_pc): Remove.
4909 (ft32_gdbarch_init): Update.
4910 * m32r-tdep.c (m32r_read_pc): Remove.
4911 (m32r_gdbarch_init): Update.
4912 * mep-tdep.c (mep_read_pc): Remove.
4913 (mep_gdbarch_init): Update.
4914 * microblaze-tdep.c (microblaze_write_pc): Remove.
4915 (microblaze_gdbarch_init): Update.
4916 * mn10300-tdep.c (mn10300_read_pc): Remove.
4917 (mn10300_write_pc): Remove.
4918 (mn10300_gdbarch_init): Update.
4919 * moxie-tdep.c (moxie_read_pc): Remove.
4920 (moxie_write_pc): Remove.
4921 (moxie_gdbarch_init): Update.
4922
bca65a23
YQ
49232018-02-06 Yao Qi <yao.qi@linaro.org>
4924
4925 * expprint.c (print_subexp_standard): Handle
4926 OP_F77_UNDETERMINED_ARGLIST.
4927 (dump_subexp_body_standard): Likewise.
4928
583e3f90 49292018-02-05 Alan Hayward <alan.hayward@arm.com>
b8df6ca7 4930
583e3f90
YQ
4931 * target-descriptions.c (tdesc_element_visitor) Add empty
4932 implementations.
b8df6ca7
AH
4933 (tdesc_type): Move make_gdb_type from here.
4934 (tdesc_type_builtin): Likewise.
4935 (tdesc_type_vector): Likewise.
4936 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
4937 (make_gdb_type_struct): Move from tdesc_type_with_fields.
4938 (make_gdb_type_union): Likewise.
4939 (make_gdb_type_flags): Likewise.
4940 (make_gdb_type_enum): Likewise.
4941 (make_gdb_type): New function.
4942 (tdesc_register_type): Use static make_gdb_type.
4943
e813d34a
RK
49442018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
4945
4946 * infcmd.c (default_print_one_register_info): Align natural-format
4947 column values consistently one under another.
4948 (pad_to_column): New function.
4949
0eb876f5
JB
49502018-02-05 Joel Brobecker <brobecker@adacore.com>
4951
4952 * dwarf2read.c (dwarf2_physname): Move commment.
4953
0625771b
LS
49542018-02-01 Leszek Swirski <leszeks@google.com>
4955
4956 * varobj.c (varobj_formatted_print_options): Allow recursive
4957 pretty printing if pretty printing is enabled.
4958
59498c30
LS
49592018-02-01 Leszek Swirski <leszeks@google.com>
4960
4961 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
4962 names after a structop as a filename.
4963
2d9e6acb
YQ
49642018-02-01 Yao Qi <yao.qi@linaro.org>
4965
4966 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
4967 (arm_record_coproc_data_proc): Likewise.
4968
df95a9cf
YQ
49692018-02-01 Yao Qi <yao.qi@linaro.org>
4970
4971 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
4972
07e5f5cf
NP
49732018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
4974
4975 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
4976 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
4977
3045b475
PA
49782018-01-31 Pedro Alves <palves@redhat.com>
4979
4980 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
4981 * inflow.c (child_terminal_save_inferior): Wrap reference to
4982 tcgetpgrp in HAVE_TERMIOS_H.
4983 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
4984 _WIN32.
4985 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
4986 always iterate over all inferiors.
4987 (gdbsim_cntrl_c): Adjust.
4988 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
4989
929b5ad4
JB
49902018-01-31 Joel Brobecker <brobecker@adacore.com>
4991
4992 * gdbtypes.c (lookup_array_range_type): Make sure the array's
4993 index type is objfile-owned if the element type is as well.
4994
29236ca2
JB
49952018-01-31 Joel Brobecker <brobecker@adacore.com>
4996
4997 GDB 8.1 released.
4998
c81e8879
PR
49992018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
5000
5001 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
5002 "features/s390x-linux64.c".
5003 (_initialize_s390_linux_tdep): Remove initialization of tdescs
5004 s390_linux32 and s390x_linux64.
5005 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
5006 default tdesc.
5007 * s390-tdep.c: Include "features/s390-linux32.c" and
5008 "features/s390x-linux64.c".
5009 (s390_tdesc_valid): Add check for tdesc_has_registers.
5010 (s390_gdbarch_init): Make sure there is always a valid tdesc.
5011 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
5012 tdesc_s390x_linux64.
5013 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
5014 tdesc_s390x_linux64 to...
5015 * s390-tdep.h: ...here.
5016
e671cd59
PA
50172018-01-30 Pedro Alves <palves@redhat.com>
5018
5019 PR gdb/13211
5020 * config.in, configure: Regenerate.
5021 * configure.ac: Check for getpgid.
5022 * go32-nat.c (go32_pass_ctrlc): New.
5023 (go32_target): Install it.
5024 * inf-child.c (inf_child_target): Install
5025 child_terminal_save_inferior, child_pass_ctrlc and
5026 child_interrupt.
5027 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
5028 (inf_ptrace_target): No longer install it.
5029 * infcmd.c (interrupt_target_1): Adjust.
5030 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
5031 (child_interrupt): Declare.
5032 (inferior::terminal_state): New.
5033 * inflow.c (struct terminal_info): Update comments.
5034 (inferior_process_group): Delete.
5035 (terminal_is_ours): Delete.
5036 (gdb_tty_state): New.
5037 (child_terminal_init): Adjust.
5038 (is_gdb_terminal, sharing_input_terminal_1)
5039 (sharing_input_terminal): New functions.
5040 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
5041 Set the process's actual process group in the foreground if
5042 possible. Handle is_ours_for_output/is_ours distinction. Don't
5043 mark terminal as the inferior's if not sharing GDB's terminal.
5044 Don't check attach_flag.
5045 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
5046 pass down a target_terminal_state.
5047 (child_terminal_save_inferior): New, factored out from ...
5048 (child_terminal_ours_1): ... this. Handle
5049 target_terminal_state::is_ours_for_output.
5050 (child_interrupt, child_pass_ctrlc): New.
5051 (inflow_inferior_exit): Clear the inferior's terminal_state.
5052 (copy_terminal_info): Copy the inferior's terminal state.
5053 (_initialize_inflow): Remove reference to terminal_is_ours.
5054 * inflow.h (inferior_process_group): Delete.
5055 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
5056 * procfs.c (procfs_target): Don't install procfs_interrupt.
5057 (procfs_interrupt): Delete.
5058 * remote.c (remote_serial_quit_handler): Adjust.
5059 (remote_interrupt): Remove ptid parameter. Adjust.
5060 * target-delegates.c: Regenerate.
5061 * target.c: Include "terminal.h".
5062 (target_terminal::terminal_state): Rename to ...
5063 (target_terminal::m_terminal_state): ... this.
5064 (target_terminal::init): Adjust.
5065 (target_terminal::inferior): Adjust to per-inferior
5066 terminal_state.
5067 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
5068 (target_terminal::ours, target_terminal::ours_for_output): Use
5069 target_terminal_is_ours_kind.
5070 (target_interrupt): Remove ptid parameter. Adjust.
5071 (default_target_pass_ctrlc): Adjust.
5072 * target.h (target_ops::to_terminal_save_inferior): New field.
5073 (target_ops::to_interrupt): Remove ptid_t parameter.
5074 (target_interrupt): Remove ptid_t parameter. Update comment.
5075 (target_pass_ctrlc): Update comment.
5076 * target/target.h (target_terminal_state): New scoped enum,
5077 factored out of ...
5078 (target_terminal::terminal_state): ... here.
5079 (target_terminal::inferior): Update comments.
5080 (target_terminal::restore_inferior): New.
5081 (target_terminal::is_inferior, target_terminal::is_ours)
5082 (target_terminal::is_ours_for_output): Adjust.
5083 (target_terminal::scoped_restore_terminal_state): Adjust to
5084 rename, and call restore_inferior() instead of inferior().
5085 (target_terminal::scoped_restore_terminal_state::m_state): Change
5086 type.
5087 (target_terminal::terminal_state): Rename to ...
5088 (target_terminal::m_terminal_state): ... this and change type.
5089
9c3a5d93
PA
50902018-01-30 Pedro Alves <palves@redhat.com>
5091
5092 * linux-nat.c (wait_for_signal): New function.
5093 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
5094 directly.
5095 (async_terminal_is_ours)
5096 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
5097 (linux_nat_add_target): Don't override
5098 to_terminal_inferior/to_terminal_ours.
5099
69ab5edb
SDJ
51002018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
5101
5102 * remote.c (remote_follow_fork): Don't call "detach_inferior".
5103
fc8e7e75
SM
51042018-01-28 Simon Marchi <simon.marchi@ericsson.com>
5105
5106 * dwarf2read.c (free_dwo_files): Add forward-declaration.
5107 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
5108 dwarf2_per_objfile_free here.
5109 (dwarf2_per_objfile_free): Remove.
5110 (_initialize_dwarf2_read): Don't register
5111 dwarf2_per_objfile_free as a registry cleanup.
5112
b2a426e2
EZ
51132018-01-27 Eli Zaretskii <eliz@gnu.org>
5114
5115 Avoid compilation errors in MinGW native builds
5116
5117 The error is triggered by including python-internal.h, and the
5118 error message is:
5119
5120 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
5121 from build-gnulib/import/math.h:27,
5122 from d:/usr/Python26/include/pyport.h:235,
5123 from d:/usr/Python26/include/Python.h:58,
5124 from python/python-internal.h:94,
5125 from python/py-arch.c:24:
5126 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
5127 using ::hypot;
5128 ^~~~~
5129
5130 This happens because Python headers define 'hypot' to expand t
5131 '_hypot' in the Windows builds.
5132 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
5133 'hypoth'. This avoids a compilation error.
5134
0bdd8eac
AH
51352018-01-26 Alan Hayward <alan.hayward@arm.com>
5136
5137 * MAINTAINERS (Write After Approval): Fix ordering.
5138
56ae9dc3
AH
51392018-01-26 Alan Hayward <alan.hayward@arm.com>
5140
5141 * MAINTAINERS (Write After Approval): Add Alan Hayward.
5142
7433498b
AM
51432018-01-26 Alan Modra <amodra@gmail.com>
5144
5145 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
5146 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
5147 Remove nop. Make const. Comment.
5148 (powerpc32_plt_stub_so_2): New.
5149 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
5150 Correct count. Update uses.
5151 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
5152 Move common code reading PLT entry word. Correct
5153 powerpc32_plt_stub PLT address calculation.
5154 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
5155 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
5156 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
5157 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
5158 (ppc64_standard_linkage8): Likewise.
5159 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
5160 Correct insns description.
5161 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
5162
0f59d5fc
PA
51632018-01-24 Pedro Alves <palves@redhat.com>
5164
5165 GCC PR libstdc++/83906
5166 * gdbtypes.c (operator==(const dynamic_prop &,
5167 const dynamic_prop &)): New.
5168 (operator==(const range_bounds &, const range_bounds &)): New.
5169 (check_types_equal): Use them instead of memcmp.
5170 * gdbtypes.h (operator==(const dynamic_prop &,
5171 const dynamic_prop &)): Declare.
5172 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
5173 (operator==(const range_bounds &, const range_bounds &)): Declare.
5174 (operator!=(const range_bounds &, const range_bounds &)): Declare.
5175
ef8914a4
PR
51762018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5177
5178 * s390-linux-tdep.c (s390_record_address_mask)
5179 (s390_record_calc_disp_common, s390_record_calc_disp)
5180 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
5181 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
5182 (s390_process_record): Move to s390-tdep.c.
5183 (s390_linux_init_abi_any): Adjust.
5184 * s390-tdep.c (s390_record_address_mask)
5185 (s390_record_calc_disp_common, s390_record_calc_disp)
5186 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
5187 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
5188 (s390_process_record): Moved from s390-linux-tdep.c
5189 (s390_gdbarch_init): Adjust.
5190
d6e58945
PR
51912018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5192
5193 * s390-linux-nat.c (s390-tdep.h): New include.
5194 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
5195 (HFILES_NO_SRCDIR): Add s390-tdep.h.
5196 (ALLDEPFILES): Add s390-tdep.c.
5197 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
5198 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
5199 * s390-tdep.h: ...this. New file.
5200 * s390-linux-tdep.c (s390-tdep.h): New include.
5201 (_initialize_s390_tdep): Rename to...
5202 (_initialize_s390_linux_tdep): ...this and adjust.
5203 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
5204 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
5205 s390-tdep.h.
5206 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
5207 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
5208 (s390_is_partial_instruction, s390_software_single_step)
5209 (is_non_branch_ril, s390_displaced_step_copy_insn)
5210 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
5211 (s390_prologue_data, s390_addr, s390_store, s390_load)
5212 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
5213 (s390_register_call_saved, s390_guess_tracepoint_registers)
5214 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
5215 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
5216 (s390_pseudo_register_name, s390_pseudo_register_type)
5217 (s390_pseudo_register_read, s390_pseudo_register_write)
5218 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
5219 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
5220 (s390_addr_bits_remove, s390_address_class_type_flags)
5221 (s390_address_class_type_flags_to_name)
5222 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
5223 (s390_function_arg_float, s390_function_arg_vector)
5224 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
5225 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
5226 (s390_frame_align, s390_register_return_value, s390_return_value)
5227 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
5228 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
5229 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
5230 (s390_trad_frame_prev_register, s390_unwind_cache)
5231 (s390_prologue_frame_unwind_cache)
5232 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
5233 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
5234 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
5235 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
5236 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
5237 (s390_frame_base_address, s390_local_base_address)
5238 (s390_frame_base, s390_gcc_target_options)
5239 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
5240 (s390_validate_reg_range, s390_tdesc_valid)
5241 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
5242 * s390-tdep.c: ...this. New file.
5243
9c0b896e
PR
52442018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5245
5246 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
5247 (s390_process_record, s390_gdbarch_tdep_alloc)
5248 (s390_linux_init_abi_any): Use/set new hook.
5249
7042632b
PR
52502018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5251
5252 * s390-linux-tdep.c (osabi.h): New include.
5253 (s390_linux_init_abi_31, s390_linux_init_abi_64)
5254 (s390_linux_init_abi_any): New functions.
5255 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
5256
650f5e13
PR
52572018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5258
5259 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
5260 tdesc_has_registers check
5261
47c9317e
PR
52622018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5263
5264 * s390-linux-tdep.c (s390_tdesc_valid): New function.
5265 (s390_validate_reg_range): New macro.
5266 (s390_gdbarch_init): Adjust.
5267
095085d8
PR
52682018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5269
5270 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
5271 (s390_gdbarch_tdep_alloc): Adjust.
5272 (s390_gdbarch_init): Adjust.
5273
ab9bcc67
PR
52742018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5275
5276 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
5277 <have_tdb>: Change type to bool.
5278 (s390_gdbarch_tdep_alloc): Adjust.
5279 (s390_gdbarch_init): Adjust.
5280
21f6f5ff
PR
52812018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5282
5283 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
5284 (gdbarch_tdep) <have_upper, have_vx>: New fields.
5285 (s390_gdbarch_tdep_alloc): New function.
5286 (s390_gdbarch_init): Allocate tdep at start and use its fields
5287 instead of separate variables.
5288
0eb97953
PR
52892018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
5290
5291 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
5292 when looking for cached gdbarch and add comment for remaining.
5293
5c319bb2
PA
52942018-01-22 Pedro Alves <palves@redhat.com>
5295 Sergio Durigan Junior <sergiodj@redhat.com>
5296
5297 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
5298 case.
5299
d65ce302
MR
53002018-01-22 Maciej W. Rozycki <macro@mips.com>
5301
5302 * MAINTAINERS: Update my company e-mail address.
5303
ec7a5fcb
YQ
53042018-01-22 Yao Qi <yao.qi@linaro.org>
5305
5306 * regcache.c (cooked_write_test): New function.
5307 (_initialize_regcache): Register the test.
5308
11f57cb6
YQ
53092018-01-22 Yao Qi <yao.qi@linaro.org>
5310
5311 * ia64-tdep.c (ia64_pseudo_register_read): Call
5312 regcache->cooked_read instead of regcache_cooked_read_unsigned.
5313 * m32c-tdep.c (m32c_cat_read): Likewise.
5314 (m32c_r3r2r1r0_read): Likewise.
5315 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
5316 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
5317
03f50fc8
YQ
53182018-01-22 Yao Qi <yao.qi@linaro.org>
5319
5320 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
5321 method raw_read instead of regcache_raw_read.
5322 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
5323 * arm-tdep.c (arm_neon_quad_read): Likewise.
5324 * avr-tdep.c (avr_pseudo_register_read): Likewise.
5325 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
5326 * frv-tdep.c (frv_pseudo_register_read): Likewise.
5327 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
5328 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
5329 (i386_pseudo_register_read_into_value): Likewise.
5330 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
5331 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
5332 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
5333 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
5334 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
5335 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
5336 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
5337 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
5338 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
5339
dc711524
YQ
53402018-01-22 Yao Qi <yao.qi@linaro.org>
5341
5342 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
5343 * configure.tgt: Remove target mt.
5344 * mt-tdep.c: Remove.
5345 * regcache.c (cooked_read_test): Remove the check for mt.
5346
3f5a868b
YQ
53472018-01-22 Yao Qi <yao.qi@linaro.org>
5348
5349 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
5350 instead of gdbarch_pseudo_register_read_value.
5351
de4cb04a
JB
53522018-01-22 Joel Brobecker <brobecker@adacore.com>
5353
5354 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
5355 language is Ada.
5356
a9e40818
JB
53572018-01-22 Joel Brobecker <brobecker@adacore.com>
5358
5359 * linespec.c (create_sals_line_offset): Remove code that preserved
5360 the symtab_and_line's line number.
5361
e707fc44
AB
53622018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
5363
5364 * varobj.c (varobj_create): Don't set valid_block when creating a
5365 floating varobj.
5366
03d0bf7b
AB
53672018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
5368
5369 * varobj.c (varobj_create): Remove out of date comment.
5370
ae451627
AB
53712018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
5372
5373 PR mi/20395
5374 * ada-exp.y (write_var_from_sym): Pass extra parameter when
5375 updating innermost block.
5376 * parse.c (innermost_block_tracker::update): Take extra type
5377 parameter, and check types match before updating innermost block.
5378 (write_dollar_variable): Update innermost block for registers.
5379 * parser-defs.h (enum innermost_block_tracker_type): New enum.
5380 (innermost_block_tracker::innermost_block_tracker): Initialise
5381 m_types member.
5382 (innermost_block_tracker::reset): Take type parameter.
5383 (innermost_block_tracker::update): Take type parameter, and pass
5384 type through as needed.
5385 (innermost_block_tracker::m_types): New member.
5386 * varobj.c (varobj_create): Pass type when reseting innermost
5387 block.
5388
aee1fcdf
AB
53892018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
5390
5391 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
5392 * ada-lang.c (resolve_subexp): Likewise.
5393 * breakpoint.c (set_breakpoint_condition) Likewise.
5394 (watch_command_1) Likewise.
5395 * c-exp.y (variable): Likewise.
5396 * d-exp.y (PrimaryExpression): Likewise.
5397 * f-exp.y (variable): Likewise.
5398 * go-exp.y (variable): Likewise.
5399 * m2-exp.y (variable): Likewise.
5400 * objfiles.c (objfile::~objfile): Likewise.
5401 * p-exp.y (variable): Likewise.
5402 * parse.c (innermost_block): Change type.
5403 * parser-defs.h (class innermost_block_tracker): New.
5404 (innermost_block): Change to innermost_block_tracker.
5405 * printcmd.c (display_command): Switch to innermost_block API.
5406 (do_one_display): Likewise.
5407 * rust-exp.y (do_one_display): Likewise.
5408 * symfile.c (clear_symtab_users): Likewise.
5409 * varobj.c (varobj_create): Switch to innermost_block API, replace
5410 use of innermost_block with block stored on varobj object.
5411
396af9a1
AB
54122018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
5413
5414 * expression.h (innermost_block): Remove declaration.
5415 * varobj.c: Add 'parser-defs.h' include.
5416
fcfcc376
TT
54172018-01-19 Tom Tromey <tom@tromey.com>
5418
5419 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
5420 symbols in the static and global blocks.
5421
5a6c3296
JC
54222018-01-19 James Clarke <jrtc27@jrtc27.com>
5423
5424 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
5425 gdb_ptrace.h, and move including gdb_wait.h ...
5426 * nat/linux-ptrace.h: ... to here.
5427
bc09b0c1
SM
54282018-01-19 Simon Marchi <simon.marchi@ericsson.com>
5429
5430 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
5431 inf_ptrace_detach_success.
5432 (inf_ptrace_detach_success): Add inferior parameter, use it
5433 instead of inferior_ptid, pass it to detach_inferior.
5434 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
5435 parameter.
5436 * inferior.c (detach_inferior): Add overload that takes an
5437 inferior object.
5438 * inferior.h (detach_inferior): Likewise.
5439 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
5440 use inferior_ptid, adjust call to inf_ptrace_detach_success.
5441 * linux-thread-db.c (thread_db_detach): Use inf parameter.
5442
6e1e1966
SM
54432018-01-19 Simon Marchi <simon.marchi@ericsson.com>
5444
5445 * target.h (struct target_ops) <to_detach>: Add inferior
5446 parameter.
5447 (target_detach): Likewise.
5448 * target.c (dispose_inferior): Pass inferior down.
5449 (target_detach): Pass inferior down. Assert that it is equal to
5450 the current inferior.
5451 * aix-thread.c (aix_thread_detach): Pass inferior down.
5452 * corefile.c (core_file_command): Pass current_inferior() down.
5453 * corelow.c (core_detach): Add inferior parameter.
5454 * darwin-nat.c (darwin_detach): Likewise.
5455 * gnu-nat.c (gnu_detach): Likewise.
5456 * inf-ptrace.c (inf_ptrace_detach): Likewise.
5457 * infcmd.c (detach_command): Pass current_inferior() down to
5458 target_detach.
5459 * infrun.c (follow_fork_inferior): Pass parent_inf to
5460 target_detach.
5461 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
5462 target_detach.
5463 * linux-nat.c (linux_nat_detach): Add inferior parameter.
5464 * linux-thread-db.c (thread_db_detach): Likewise.
5465 * nto-procfs.c (procfs_detach): Likewise.
5466 * procfs.c (procfs_detach): Likewise.
5467 * record.c (record_detach): Likewise.
5468 * record.h (struct inferior): Forward-declare.
5469 (record_detach): Add inferior parameter.
5470 * remote-sim.c (gdbsim_detach): Likewise.
5471 * remote.c (remote_detach_1): Likewise.
5472 (remote_detach): Likewise.
5473 (extended_remote_detach): Likewise.
5474 * sol-thread.c (sol_thread_detach): Likewise.
5475 * target-debug.h (target_debug_print_inferior_p): New macro.
5476 * target-delegates.c: Re-generate.
5477 * top.c (kill_or_detach): Pass inferior down to target_detach.
5478 * windows-nat.c (windows_detach): Add inferior parameter.
5479
6bd6f3b6
SM
54802018-01-19 Simon Marchi <simon.marchi@ericsson.com>
5481
5482 * target.h (struct target_ops) <to_detach>: Remove args
5483 parameter.
5484 (target_detach): Likewise.
5485 * target.c (dispose_inferior): Adjust.
5486 (target_detach): Remove args parameter, adjust.
5487 * aix-thread.c (aix_thread_detach): Adjust.
5488 * corefile.c (core_file_command): Adjust.
5489 * corelow.c (core_detach): Adjust.
5490 * darwin-nat.c (darwin_detach): Adjust.
5491 * gnu-nat.c (gnu_detach): Adjust.
5492 * inf-ptrace.c (inf_ptrace_detach): Adjust.
5493 * infcmd.c (detach_command): Adjust
5494 * infrun.c (follow_fork_inferior): Adjust.
5495 (handle_vfork_child_exec_or_exit): Adjust.
5496 * linux-fork.c (linux_fork_detach): Remove args parameter.
5497 * linux-fork.h (linux_fork_detach): Likewise.
5498 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
5499 * linux-thread-db.c (thread_db_detach): Likewise.
5500 * nto-procfs.c (procfs_detach): Likewise.
5501 * procfs.c (procfs_detach): Likewise.
5502 (do_detach): Remove signo parameter.
5503 * record.c (record_detach): Remove args parameter.
5504 * record.h (record_detach): Likewise.
5505 * remote-sim.c (gdbsim_detach): Likewise.
5506 * remote.c (remote_detach_1): Likewise.
5507 (remote_detach): Likewise.
5508 (extended_remote_detach): Likewise.
5509 * sol-thread.c (sol_thread_detach): Likewise.
5510 * target-delegates.c: Re-generate.
5511 * top.c (struct qt_args) <args>: Remove field.
5512 (kill_or_detach): Don't pass args.
5513 (quit_force): Don't set args.
5514 * windows-nat.c (windows_detach): Remove args parameter.
5515
88af8ea8
YQ
55162018-01-19 Yao Qi <yao.qi@linaro.org>
5517
5518 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
5519 (arm_linux_init_abi): Install it.
5520
dea445b9
YQ
55212018-01-19 Yao Qi <yao.qi@linaro.org>
5522
5523 * osabi.c (gdb_osabi_names): Extend the regexp for
5524 arm-linux-gnueabihf.
5525
4a17f768
YQ
55262018-01-18 Yao Qi <yao.qi@linaro.org>
5527
5528 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
5529 m_abbrevs.
5530 (abbrev_table::add_abbrev): Update.
5531 (abbrev_table::lookup_abbrev): Update.
5532
d679c21a
YQ
55332018-01-18 Yao Qi <yao.qi@linaro.org>
5534
5535 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
5536
7d937cad
SDJ
55372018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
5538
5539 * compile/compile.c (compile_to_object): Convert "triplet_rx"
5540 to "std::string".
5541
9e14690d
TT
55422018-01-17 Tom Tromey <tom@tromey.com>
5543
5544 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
5545
50a82047
TT
55462018-01-17 Tom Tromey <tom@tromey.com>
5547
5548 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
5549 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
5550 (create_array_type_with_stride): Update.
5551 * dwarf2read.c (set_die_type): Update.
5552
c89b44cd
TT
55532018-01-17 Tom Tromey <tom@tromey.com>
5554
5555 * dwarf2read.c (delayed_method_info): Remove typedef.
5556 (dwarf2_cu::method_info): Now a std::vector.
5557 (add_to_method_list): Update.
5558 (free_delayed_list): Remove.
5559 (compute_delayed_physnames): Update.
5560 (process_full_comp_unit, process_full_type_unit): Clear the method
5561 list. Remove cleanups.
5562 (psymtab_include_file_name): Add name_holder parameter. Use
5563 unique_xmalloc_ptr.
5564 (dwarf_decode_lines): Update.
5565
fcd3b13d
SM
55662018-01-17 Tom Tromey <tom@tromey.com>
5567 Simon Marchi <simon.marchi@ericsson.com>
5568
5569 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
5570 (dwarf2_per_objfile::free_cached_comp_units)
5571 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
5572 (init_cutu_and_read_dies_no_follow): Update.
5573 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
5574 (dwarf2_cu::~dwarf2_cu): New.
5575 (free_heap_comp_unit, free_stack_comp_unit): Remove.
5576 (age_cached_comp_units, free_one_cached_comp_unit): Update.
5577
685af9cd
TT
55782018-01-17 Tom Tromey <tom@tromey.com>
5579 Simon Marchi <simon.marchi@ericsson.com>
5580
5581 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
5582 (struct die_reader_specs) <abbrev_table>: New member.
5583 (struct abbrev_table): Add constructor.
5584 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
5585 <abbrev_obstack>: Now an auto_obstack.
5586 (abbrev_table_up): New typedef.
5587 (init_cu_die_reader): Add abbrev_table parameter.
5588 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
5589 Add result_dwo_abbrev_table.
5590 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
5591 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
5592 Update.
5593 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
5594 parameter.
5595 (skip_children): Update.
5596 (abbrev_table::alloc_abbrev): Rename from
5597 abbrev_table_alloc_abbrev.
5598 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
5599 (abbrev_table::lookup_abbrev): Rename from
5600 abbrev_table_lookup_abbrev.
5601 (abbrev_table_read_table): Return abbrev_table_up.
5602 (abbrev_table_free, abbrev_table_free_cleanup)
5603 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
5604 (load_partial_dies): Update.
5605
5e2db402
TT
56062018-01-17 Tom Tromey <tom@tromey.com>
5607
5608 * dwarf2read.c (dwarf2_compute_name): Update comment.
5609 (read_func_scope, read_variable): Update.
5610 (new_symbol): Remove.
5611 (new_symbol_full): Rename to new_symbol.
5612
ee7f689e 56132018-01-17 Mike Gulick <mgulick@mathworks.com>
41667530
MG
5614
5615 PR gdb/16577
5616 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
5617 a warning instead of throwing an error, set section size to 0 and return
5618 NULL.
5619 * gdb_bfd.h (gdb_bfd_map_section): Update description.
5620
4d9b86e1
SM
56212018-01-17 Simon Marchi <simon.marchi@ericsson.com>
5622
5623 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
5624 std::string.
5625 (linux_ptrace_attach_fail_reason_string): Likewise.
5626 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
5627 Likewise.
5628 (linux_ptrace_attach_fail_reason_string): Likewise.
5629 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
5630
a7b2d0fb
SM
56312018-01-17 Simon Marchi <simon.marchi@ericsson.com>
5632
5633 * linux-nat.c (linux_nat_attach): Remove xstrdup.
5634
f517c180
EA
56352018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
5636
5637 PR gdb/21559
5638 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
5639 checking for fs_base/gs_base fields in struct user_regs_struct.
5640 * configure: Regenerate.
5641
7045b1ca
YQ
56422018-01-17 Yao Qi <yao.qi@linaro.org>
5643
5644 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
5645 function.
5646 (aarch64_linux_init_abi): Install it to gdbarch hook
5647 gcc_target_options.
5648
db422fb2
PA
56492018-01-15 Pedro Alves <palves@redhat.com>
5650
5651 * common/signals-state-save-restore.c
5652 (save_original_signals_state): Fix typos.
5653
ba643918
SDJ
56542017-01-12 Tom Tromey <tom@tromey.com>
5655 Sergio Durigan Junior <sergiodj@redhat.com>
5656
5657 * Makefile.in (install-only): Install gdb-add-index.
5658
906b4aac
JB
56592018-01-12 John Baldwin <jhb@FreeBSD.org>
5660
5661 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
5662
bdf2a94a
AA
56632018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
5664
5665 * infrun.c (keep_going_pass_signal): Clear step-over info when
5666 insert_breakpoints fails.
5667
71d378ae
PA
56682018-01-11 Pedro Alves <palves@redhat.com>
5669
5670 PR gdb/22583
5671 * infrun.c (resume): Rename to ...
5672 (resume_1): ... this.
5673 (resume): Reimplement as wrapper around resume_1.
5674
3cada740
PA
56752018-01-11 Pedro Alves <palves@redhat.com>
5676
5677 PR remote/22597
5678 * remote.c (remote_parse_stop_reply): Default to the last-set
5679 general thread instead of to 'magic_null_ptid'.
5680
618daa93
PA
56812018-01-10 Pedro Alves <palves@redhat.com>
5682
5683 * language.h (language_get_symbol_name_matcher): Rename ...
5684 (get_symbol_name_matcher): ... this.
5685 * language.c (language_get_symbol_name_matcher): Ditto.
5686 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
5687 callers adjusted.
5688
c63d3e8d
PA
56892018-01-10 Pedro Alves <palves@redhat.com>
5690
5691 PR gdb/22670
5692 * dwarf2read.c
5693 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
5694 Adjust to use language_get_symbol_name_matcher instead of
5695 language_defn::la_get_symbol_name_matcher.
5696 * language.c (language_get_symbol_name_matcher): If in Ada mode
5697 and the lookup name is a verbatim match, return Ada's matcher.
5698 * language.h (language_get_symbol_name_matcher): Adjust comment.
5699 (ada_lookup_name_info::verbatim_p):: New method.
5700
d4c2a405
PA
57012018-01-10 Pedro Alves <palves@redhat.com>
5702
5703 PR gdb/22670
5704 * ada-lang.c (ada_collect_symbol_completion_matches): If the
5705 minsym's language is language_auto or language_cplus, pass down
5706 language_ada instead.
5707 * symtab.c (compare_symbol_name): Don't frob symbol language here.
5708
8825213e
PA
57092018-01-10 Pedro Alves <palves@redhat.com>
5710
5711 PR gdb/22670
5712 * minsyms.c (linkage_name_str): New function.
5713 (iterate_over_minimal_symbols): Use it.
5714
2d97a5d9
JB
57152018-01-09 John Baldwin <jhb@FreeBSD.org>
5716
5717 * NEWS: Document that 'info proc' now works on FreeBSD.
5718
92fce24d
JB
57192018-01-09 John Baldwin <jhb@FreeBSD.org>
5720
5721 * configure.ac: Check for kinfo_getfile in libutil.
5722 * configure: Regenerate.
5723 * config.in: Regenerate.
5724 * fbsd-nat.c: Include "fbsd-tdep.h".
5725 (fbsd_fetch_cmdline): New.
5726 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
5727 rather than calling error.
5728 (fbsd_info_proc): New.
5729 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
5730 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
5731 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
5732
262f62f5
JB
57332018-01-09 John Baldwin <jhb@FreeBSD.org>
5734
5735 * fbsd-nat.c (struct free_deleter): Remove.
5736 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
5737
b999e203
JB
57382018-01-09 John Baldwin <jhb@FreeBSD.org>
5739
5740 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
5741 NULL for an empty pathname.
5742
d2176225
JB
57432018-01-09 John Baldwin <jhb@FreeBSD.org>
5744
5745 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
5746 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
5747 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
5748 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
5749 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
5750 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
5751 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
5752 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
5753 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
5754 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
5755 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
5756 (fbsd_core_fetch_timeval, fbsd_print_sigset)
5757 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
5758 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
5759 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
5760
9c4ac400
ST
57612018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
5762
5763 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
5764 (gnu_xfer_auxv): New function.
5765 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
5766 TARGET_OBJECT_AUXV.
5767
1e5ded6c
YQ
57682018-01-08 Yao Qi <yao.qi@linaro.org>
5769 Simon Marchi <simon.marchi@ericsson.com>
5770
5771 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
5772 common/selftest.c.
5773 (COMMON_OBS): Remove selftest.o.
5774 * configure.ac: Append selftest-arch.c and common/selftest.c to
5775 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
5776 * configure: Re-generated.
5777 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
5778 GDB_SELF_TEST.
5779 (maintenance_info_selftests): Likewise.
5780
04bafb1e
XR
57812018-01-08 Xavier Roirand <roirand@adacore.com>
5782
5783 * ada-valprint.c (val_print_packed_array_elements): Use
5784 proper number of elements when printing an array indexed
5785 by an enumeration type.
5786
518817b3
SM
57872018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
5788
5789 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
5790 (dw2_get_file_names_reader): Adjust.
5791 (lookup_dwo_signatured_type): Adjust.
5792 (lookup_dwp_signatured_type): Adjust.
5793 (lookup_signatured_type): Adjust.
5794 (create_type_unit_group): Adjust.
5795 (get_type_unit_group): Adjust.
5796 (process_psymtab_comp_unit_reader): Adjust.
5797 (build_type_psymtabs_reader): Adjust.
5798 (scan_partial_symbols): Adjust.
5799 (add_partial_symbol): Adjust.
5800 (add_partial_subprogram): Adjust.
5801 (peek_die_abbrev): Adjust.
5802 (fixup_go_packaging): Adjust.
5803 (process_imported_unit_die): Adjust.
5804 (dwarf2_compute_name): Adjust.
5805 (dwarf2_physname): Adjust.
5806 (read_import_statement): Adjust.
5807 (handle_DW_AT_stmt_list): Adjust.
5808 (read_file_scope): Adjust.
5809 (read_func_scope): Adjust.
5810 (read_lexical_block_scope): Adjust.
5811 (read_call_site_scope): Adjust.
5812 (read_variable): Adjust.
5813 (dwarf2_rnglists_process): Adjust.
5814 (dwarf2_ranges_process): Adjust.
5815 (dwarf2_ranges_read): Adjust.
5816 (dwarf2_get_pc_bounds): Adjust.
5817 (dwarf2_record_block_ranges): Adjust.
5818 (dwarf2_add_field): Adjust.
5819 (dwarf2_add_member_fn): Adjust.
5820 (read_structure_type): Adjust.
5821 (process_structure_scope): Adjust.
5822 (read_enumeration_type): Adjust.
5823 (read_array_type): Adjust.
5824 (mark_common_block_symbol_computed): Adjust.
5825 (read_common_block): Adjust.
5826 (read_namespace_type): Adjust.
5827 (read_namespace): Adjust.
5828 (read_module_type): Adjust.
5829 (read_tag_pointer_type): Adjust.
5830 (read_tag_ptr_to_member_type): Adjust.
5831 (read_tag_string_type): Adjust.
5832 (read_subroutine_type): Adjust.
5833 (read_typedef): Adjust.
5834 (read_base_type): Adjust.
5835 (attr_to_dynamic_prop): Adjust.
5836 (read_subrange_type): Adjust.
5837 (read_unspecified_type): Adjust.
5838 (dwarf2_read_abbrevs): Adjust.
5839 (load_partial_dies): Adjust.
5840 (read_partial_die): Adjust.
5841 (find_partial_die): Adjust.
5842 (guess_partial_die_structure_name): Adjust.
5843 (fixup_partial_die): Adjust.
5844 (read_attribute_value): Adjust.
5845 (read_addr_index): Adjust.
5846 (read_addr_index_from_leb128): Adjust.
5847 (read_str_index): Adjust.
5848 (dwarf2_string_attr): Adjust.
5849 (get_debug_line_section): Adjust.
5850 (dwarf_decode_line_header): Adjust.
5851 (lnp_state_machine::check_line_address): Adjust.
5852 (dwarf_decode_lines_1): Adjust.
5853 (dwarf_decode_lines): Adjust.
5854 (dwarf2_start_symtab): Adjust.
5855 (var_decode_location): Adjust.
5856 (new_symbol_full): Adjust.
5857 (dwarf2_const_value_data): Adjust.
5858 (dwarf2_const_value_attr): Adjust.
5859 (dwarf2_const_value): Adjust.
5860 (die_type): Adjust.
5861 (die_containing_type): Adjust.
5862 (build_error_marker_type): Adjust.
5863 (lookup_die_type): Adjust.
5864 (guess_full_die_structure_name): Adjust.
5865 (anonymous_struct_prefix): Adjust.
5866 (determine_prefix): Adjust.
5867 (dwarf2_name): Adjust.
5868 (follow_die_ref_or_sig): Adjust.
5869 (follow_die_offset): Adjust.
5870 (follow_die_ref): Adjust.
5871 (follow_die_sig_1): Adjust.
5872 (follow_die_sig): Adjust.
5873 (get_signatured_type): Adjust.
5874 (get_DW_AT_signature_type): Adjust.
5875 (decode_locdesc): Adjust.
5876 (dwarf_decode_macros): Adjust.
5877 (cu_debug_loc_section): Adjust.
5878 (fill_in_loclist_baton): Adjust.
5879 (dwarf2_symbol_mark_computed): Adjust.
5880 (init_one_comp_unit): Don't assign
5881 dwarf2_cu::dwarf2_per_objfile.
5882 (set_die_type): Adjust.
5883
ed2dc618
SM
58842018-01-07 Simon Marchi <simon.marchi@ericsson.com>
5885
5886 * dwarf2read.c (struct mapped_debug_names): Add constructor.
5887 <dwarf2_per_objfile>: New field.
5888 (dwarf2_per_objfile): Remove global.
5889 (get_dwarf2_per_objfile): New function.
5890 (set_dwarf2_per_objfile): New function.
5891 (dwarf2_build_psymtabs_hard): Change objfile parameter to
5892 dwarf2_per_objfile.
5893 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
5894 (read_abbrev_offset): Likewise.
5895 (read_indirect_string): Likewise.
5896 (read_indirect_line_string): Likewise.
5897 (read_indirect_string_at_offset): Likewise.
5898 (read_indirect_string_from_dwz): Likewise.
5899 (dwarf2_find_containing_comp_unit): Change objfile parameter to
5900 dwarf2_per_objfile.
5901 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
5902 (create_all_comp_units): Change objfile parameter to
5903 dwarf2_per_objfile.
5904 (create_all_type_units): Likewise.
5905 (process_queue): Add dwarf2_per_objfile parameter.
5906 (read_and_check_comp_unit_head): Likewise.
5907 (lookup_dwo_unit_in_dwp): Likewise.
5908 (get_dwp_file): Likewise.
5909 (process_cu_includes): Likewise.
5910 (struct free_dwo_file_cleanup_data): New struct.
5911 (dwarf2_has_info): Use get_dwarf2_per_objfile and
5912 set_dwarf2_per_objfile.
5913 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
5914 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
5915 context, adjust calls.
5916 (dw2_instantiate_symtab): Likewise.
5917 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
5918 (dw2_get_cu): Likewise.
5919 (create_cu_from_index_list): Change objfile parameter to
5920 dwarf2_per_objfile.
5921 (create_cus_from_index_list): Get dwarf2_per_objfile from
5922 context, adjust calls.
5923 (create_cus_from_index): Likewise.
5924 (create_signatured_type_table_from_index): Change objfile
5925 parameter to dwarf2_per_objfile.
5926 (create_signatured_type_table_from_debug_names): Change objfile
5927 parameter to dwarf2_per_objfile.
5928 (create_addrmap_from_index): Likewise.
5929 (create_addrmap_from_aranges): Likewise.
5930 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
5931 (dw2_setup): Remove.
5932 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
5933 context.
5934 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
5935 get_dwarf2_per_objfile.
5936 (dw2_forget_cached_source_info): Likewise.
5937 (dw2_map_symtabs_matching_filename): Likewise.
5938 (struct dw2_symtab_iterator) <index>: Remove.
5939 <dwarf2_per_objfile>: New field.
5940 (dw2_symtab_iter_init): Replace index parameter with
5941 dwarf2_per_objfile.
5942 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
5943 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
5944 (dw2_print_stats): Likewise.
5945 (dw2_dump): Likewise.
5946 (dw2_expand_symtabs_for_function): Likewise.
5947 (dw2_expand_all_symtabs): Likewise.
5948 (dw2_expand_symtabs_with_fullname): Likewise.
5949 (dw2_expand_marked_cus): Replace index and objfile parameters
5950 with dwarf2_per_objfile.
5951 (dw_expand_symtabs_matching_file_matcher): Add
5952 dwarf2_per_objfile parameter and adjust calls.
5953 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
5954 adjust calls.
5955 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
5956 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
5957 adjust calls.
5958 (create_cus_from_debug_names_list): Replace objfile parameter
5959 with dwarf2_per_objfile and adjust calls.
5960 (create_cus_from_debug_names): Likewise.
5961 (dwarf2_read_debug_names): Likewise.
5962 (mapped_debug_names::namei_to_name): Adjust call.
5963 (dw2_debug_names_iterator::next): Likewise.
5964 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
5965 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
5966 (dw2_debug_names_dump): Likewise.
5967 (dw2_debug_names_expand_symtabs_for_function): Likewise.
5968 (dw2_debug_names_expand_symtabs_matching): Likewise.
5969 (dwarf2_initialize_objfile): Likewise.
5970 (dwarf2_build_psymtabs): Likewise.
5971 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
5972 this_cu.
5973 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
5974 (read_and_check_comp_unit_head): Likewise.
5975 (read_abbrev_offset): Likewise.
5976 (create_debug_type_hash_table): Likewise.
5977 (create_debug_types_hash_table): Likewise.
5978 (create_all_type_units): Replace objfile parameter with
5979 dwarf2_per_objfile.
5980 (add_type_unit): Add dwarf2_per_objfile parameter.
5981 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
5982 with dwarf2_per_objfile.
5983 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
5984 (lookup_dwp_signatured_type): Likewise.
5985 (lookup_signatured_type): Likewise.
5986 (read_cutu_die_from_dwo): Likewise.
5987 (init_tu_and_read_dwo_dies): Likewise.
5988 (init_cutu_and_read_dies): Likewise.
5989 (init_cutu_and_read_dies_no_follow): Likewise.
5990 (allocate_type_unit_groups_table): Add objfile parameter.
5991 (create_type_unit_group): Use dwarf2_per_objfile from cu.
5992 (get_type_unit_group): Likewise.
5993 (process_psymtab_comp_unit): Update call.
5994 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
5995 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
5996 (print_tu_stats): Likewise.
5997 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
5998 in void* parameter.
5999 (build_type_psymtabs): Change objfile parameter to
6000 dwarf2_per_objfile.
6001 (process_skeletonless_type_unit): Use dwarf2_per_objfile
6002 passed in void* parameter.
6003 (process_skeletonless_type_units): Change objfile parameter to
6004 dwarf2_per_objfile.
6005 (set_partial_user): Likewise.
6006 (dwarf2_build_psymtabs_hard): Likewise.
6007 (read_comp_units_from_section): Likewise.
6008 (create_all_comp_units): Likewise.
6009 (scan_partial_symbols): Update calls.
6010 (add_partial_symbol): Likewise.
6011 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
6012 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
6013 (process_queue): Add dwarf2_per_objfile parameter.
6014 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
6015 (compute_compunit_symtab_includes): Likewise.
6016 (process_cu_includes): Add dwarf2_per_objfile parameter.
6017 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
6018 (process_full_type_unit): Likewise.
6019 (process_imported_unit_die): Update call.
6020 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
6021 (read_file_scope): Likewise.
6022 (allocate_dwo_file_hash_table): Add objfile parameter.
6023 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
6024 (create_cus_hash_table): Likewise.
6025 (create_dwp_hash_table): Likewise.
6026 (create_dwo_unit_in_dwp_v1): Likewise.
6027 (create_dwp_v2_section): Likewise.
6028 (create_dwo_unit_in_dwp_v2): Likewise.
6029 (lookup_dwo_unit_in_dwp): Likewise.
6030 (try_open_dwop_file): Likewise.
6031 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
6032 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
6033 cleanup to include a reference to dwarf2_per_objfile.
6034 (open_dwp_file): Add dwarf2_per_objfile parameter.
6035 (open_and_init_dwp_file): Likewise.
6036 (get_dwp_file): Likewise.
6037 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
6038 (queue_and_load_all_dwo_tus): Update call.
6039 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
6040 data.
6041 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
6042 (dwarf2_ranges_process): Likewise.
6043 (dwarf2_get_pc_bounds): Likewise.
6044 (mark_common_block_symbol_computed): Likewise.
6045 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
6046 (dwarf2_read_abbrevs): Update call.
6047 (read_partial_die): Use dwarf2_per_objfile from cu.
6048 (find_partial_die): Likewise.
6049 (fixup_partial_die): Likewise.
6050 (read_attribute_value): Likewise.
6051 (read_indirect_string_at_offset_from): Add objfile parameter.
6052 (read_indirect_string_at_offset): Add dwarf2_per_objfile
6053 parameter.
6054 (read_indirect_string_from_dwz): Add objfile parameter.
6055 (read_indirect_string): Add objfile parameter.
6056 (read_addr_index_1): Add dwarf2_per_objfile parameter.
6057 (read_addr_index): Use dwarf2_per_objfile from cu.
6058 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
6059 call dw2_setup.
6060 (read_str_index): Use dwarf2_per_objfile from cu.
6061 (get_debug_line_section): Likewise.
6062 (read_formatted_entries): Add dwarf2_per_objfile parameter.
6063 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
6064 (new_symbol_full): Use dwarf2_per_objfile from cu.
6065 (build_error_marker_type): Likewise.
6066 (lookup_die_type): Likewise.
6067 (determine_prefix): Likewise.
6068 (follow_die_offset): Likewise.
6069 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
6070 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
6071 (dwarf2_fetch_die_type_sect_off): Likewise.
6072 (dwarf2_get_die_type): Likewise.
6073 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
6074 (get_signatured_type): Likewise.
6075 (get_DW_AT_signature_type): Likewise.
6076 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
6077 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
6078 (cu_debug_loc_section): Likewise.
6079 (fill_in_loclist_baton): Likewise.
6080 (dwarf2_symbol_mark_computed): Likewise.
6081 (dwarf2_find_containing_comp_unit): Change objfile parameter to
6082 dwarf2_per_objfile.
6083 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
6084 parameter.
6085 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
6086 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
6087 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
6088 (set_die_type): Use dwarf2_free_objfile from cu.
6089 (get_die_type_at_offset): Likewise.
6090 (dwarf2_per_objfile_free): Don't assign global variable.
6091 (debug_names) <constructor>: Add dwarf2_per_objfile
6092 parameter, update m_debugstrlookup construction.
6093 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
6094 parameter.
6095 <m_dwarf2_per_objfile>: New field.
6096 <lookup>: Use m_dwarf2_per_objfile.
6097 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
6098 (psyms_seen_size): Likewise.
6099 (write_gdbindex): Replace objfile parameter with
6100 dwarf2_per_objfile.
6101 (write_debug_names): Likewise.
6102 (write_psymtabs_to_index): Likewise.
6103 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
6104 calls.
6105
e3b94546
SM
61062018-01-07 Simon Marchi <simon.marchi@ericsson.com>
6107
6108 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
6109 <dwarf2_per_objfile>: New field.
6110 (struct dwarf2_per_cu_data) <objfile>: Remove.
6111 <dwarf2_per_objfile>: New field.
6112 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
6113 of objfile.
6114 (create_signatured_type_table_from_index): Likewise.
6115 (create_debug_type_hash_table): Likewise.
6116 (fill_in_sig_entry_from_dwo_entry): Likewise.
6117 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
6118 (create_type_unit_group): Assign dwarf2_per_objfile instead of
6119 objfile.
6120 (create_partial_symtab): Access objfile through
6121 dwarf2_per_objfile.
6122 (process_psymtab_comp_unit_reader): Likewise.
6123 (read_comp_units_from_section): Likewise.
6124 (scan_partial_symbols): Likewise.
6125 (add_partial_symbol): Likewise.
6126 (add_partial_subprogram): Likewise.
6127 (peek_die_abbrev): Likewise.
6128 (fixup_go_packaging): Likewise.
6129 (process_full_comp_unit): Likewise.
6130 (process_full_type_unit): Likewise.
6131 (process_imported_unit_die): Likewise.
6132 (dwarf2_compute_name): Likewise.
6133 (dwarf2_physname): Likewise.
6134 (read_import_statement): Likewise.
6135 (create_cus_hash_table): Assign dwarf2_physname instead of
6136 objfile.
6137 (read_func_scope): Access objfile through dwarf2_per_objfile.
6138 (read_lexical_block_scope): Likewise.
6139 (read_call_site_scope): Likewise.
6140 (read_variable): Likewise.
6141 (dwarf2_rnglists_process): Likewise.
6142 (dwarf2_ranges_process): Likewise.
6143 (dwarf2_ranges_read): Likewise.
6144 (dwarf2_record_block_ranges): Likewise.
6145 (dwarf2_add_field): Likewise.
6146 (dwarf2_add_member_fn): Likewise.
6147 (read_structure_type): Likewise.
6148 (process_structure_scope): Likewise.
6149 (read_enumeration_type): Likewise.
6150 (read_array_type): Likewise.
6151 (read_common_block): Likewise.
6152 (read_namespace_type): Likewise.
6153 (read_namespace): Likewise.
6154 (read_module_type): Likewise.
6155 (read_tag_pointer_type): Likewise.
6156 (read_tag_ptr_to_member_type): Likewise.
6157 (read_tag_string_type): Likewise.
6158 (read_subroutine_type): Likewise.
6159 (read_typedef): Likewise.
6160 (read_base_type): Likewise.
6161 (attr_to_dynamic_prop): Likewise.
6162 (read_subrange_type): Likewise.
6163 (read_unspecified_type): Likewise.
6164 (load_partial_dies): Likewise.
6165 (read_partial_die): Likewise.
6166 (find_partial_die): Likewise.
6167 (guess_partial_die_structure_name): Likewise.
6168 (fixup_partial_die): Likewise.
6169 (read_attribute_value): Likewise.
6170 (read_addr_index_from_leb128): Likewise.
6171 (dwarf2_read_addr_index): Likewise.
6172 (dwarf2_string_attr): Likewise.
6173 (lnp_state_machine::check_line_address): Likewise.
6174 (dwarf_decode_lines_1): Likewise.
6175 (dwarf_decode_lines): Likewise.
6176 (dwarf2_start_symtab): Likewise.
6177 (var_decode_location): Likewise.
6178 (new_symbol_full): Likewise.
6179 (dwarf2_const_value_data): Likewise.
6180 (dwarf2_const_value_attr): Likewise.
6181 (dwarf2_const_value): Likewise.
6182 (die_type): Likewise.
6183 (die_containing_type): Likewise.
6184 (lookup_die_type): Likewise.
6185 (guess_full_die_structure_name): Likewise.
6186 (anonymous_struct_prefix): Likewise.
6187 (dwarf2_name): Likewise.
6188 (follow_die_ref_or_sig): Likewise.
6189 (follow_die_offset): Likewise.
6190 (follow_die_ref): Likewise.
6191 (dwarf2_fetch_die_loc_sect_off): Likewise.
6192 (dwarf2_fetch_constant_bytes): Likewise.
6193 (dwarf2_fetch_die_type_sect_off): Likewise.
6194 (dwarf2_get_die_type): Likewise.
6195 (follow_die_sig): Likewise.
6196 (decode_locdesc): Likewise.
6197 (dwarf2_per_cu_objfile): Likewise.
6198 (dwarf2_per_cu_text_offset): Likewise.
6199 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
6200 objfile.
6201 (set_die_type): Access objfile through
6202 dwarf2_per_objfile.
6203
b01ba14d
SM
62042018-01-07 Simon Marchi <simon.marchi@ericsson.com>
6205
6206 * valprint.c (converted_character_d): Remove typedef.
6207 (DEF_VEC_O (converted_character_d)): Remove.
6208 (count_next_character): Use std::vector.
6209 (print_converted_chars_to_obstack): Likewise.
6210 (generic_printstr): Likewise.
6211
4d0fdd9b
SM
62122018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
6213
6214 * xml-support.h (struct gdb_xml_value): Add constructor.
6215 <value>: Change type to unique_xmalloc_ptr.
6216 (gdb_xml_value_s): Remove typedef.
6217 (DEF_VEC_O (gdb_xml_value_s)): Remove.
6218 (gdb_xml_element_start_handler): Change parameter type to
6219 std::vector.
6220 (xml_find_attribute): Likewise.
6221 * xml-support.c (xml_find_attribute): Change parameter type to
6222 std::vector and adjust.
6223 (gdb_xml_values_cleanup): Remove.
6224 (gdb_xml_parser::start_element): Adjust to std::vector.
6225 (xinclude_start_include): Change paraeter type to std::vector
6226 and adjust.
6227 * btrace.c (check_xml_btrace_version): Likewise.
6228 (parse_xml_btrace_block): Likewise.
6229 (parse_xml_btrace_pt_config_cpu): Likewise.
6230 (parse_xml_btrace_pt): Likewise.
6231 (parse_xml_btrace_conf_bts): Likewise.
6232 (parse_xml_btrace_conf_pt): Likewise.
6233 * memory-map.c (memory_map_start_memory): Likewise.
6234 (memory_map_start_property): Likewise.
6235 * osdata.c (osdata_start_osdata): Likewise.
6236 (osdata_start_item): Likewise.
6237 (osdata_start_column): Likewise.
6238 * remote.c (start_thread): Likewise.
6239 * solib-aix.c (library_list_start_library): Likewise.
6240 (library_list_start_list): Likewise.
6241 * solib-svr4.c (library_list_start_library): Likewise.
6242 (svr4_library_list_start_list): Likewise.
6243 * solib-target.c (library_list_start_segment): Likewise.
6244 (library_list_start_section): Likewise.
6245 (library_list_start_library): Likewise.
6246 (library_list_start_list): Likewise.
6247 * tracepoint.c (traceframe_info_start_memory): Likewise.
6248 (traceframe_info_start_tvar): Likewise.
6249 * xml-syscall.c (syscall_start_syscall): Likewise.
6250 * xml-tdesc.c (tdesc_start_target): Likewise.
6251 (tdesc_start_feature): Likewise.
6252 (tdesc_start_reg): Likewise.
6253 (tdesc_start_union): Likewise.
6254 (tdesc_start_struct): Likewise.
6255 (tdesc_start_flags): Likewise.
6256 (tdesc_start_enum): Likewise.
6257 (tdesc_start_field): Likewise.
6258 (tdesc_start_enum_value): Likewise.
6259 (tdesc_start_vector): Likewise.
6260
f979c73f
SM
62612018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
6262
6263 * extension.h (struct xmethod_worker) <clone>: Remove.
6264 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
6265 Remove.
6266 (python_xmethod_worker::clone): Remove.
6267 * valops.c (find_overload_match): Use std::move instead of
6268 clone.
6269
ba18742c
SM
62702018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
6271
6272 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
6273 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
6274 <free_xmethod_worker_data>: Remove.
6275 <get_matching_xmethod_workers>: Chance VEC to std::vector.
6276 <get_xmethod_arg_types>: Remove.
6277 <get_xmethod_result_type>: Remove.
6278 <invoke_xmethod>: Remove.
6279 * extension.c (new_xmethod_worker): Remove.
6280 (clone_xmethod_worker): Remove.
6281 (get_matching_xmethod_workers): Return void, pass std::vector by
6282 pointer.
6283 (get_xmethod_arg_types): Rename to...
6284 (xmethod_worker::get_arg_types): ... this, and adjust.
6285 (get_xmethod_result_type): Rename to...
6286 (xmethod_worker::get_result_type): ... this, and adjust.
6287 (invoke_xmethod): Remove.
6288 (free_xmethod_worker): Remove.
6289 (free_xmethod_worker_vec): Remove.
6290 * extension.h (enum ext_lang_rc): Move here from
6291 extension-priv.h.
6292 (struct xmethod_worker): Add constructor and destructor.
6293 <data>: Remove.
6294 <value>: Remove.
6295 <invoke, clone, do_get_result_type, do_get_arg_types>: New
6296 virtual pure methods.
6297 <get_arg_types, get_result_type>: New methods.
6298 (xmethod_worker_ptr): Remove typedef.
6299 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
6300 (xmethod_worker_vec): Remove typedef.
6301 (xmethod_worker_up): New typedef.
6302 (invoke_xmethod): Remove.
6303 (clone_xmethod_worker): Remove.
6304 (free_xmethod_worker): Remove.
6305 (free_xmethod_worker_vec): Remove.
6306 (get_xmethod_arg_types): Remove.
6307 (get_xmethod_result_type): Remove.
6308 * valops.c (find_method_list): Use std::vector, don't use
6309 intermediate vector.
6310 (value_find_oload_method_list): Use std::vector.
6311 (find_overload_match): Use std::vector.
6312 (find_oload_champ): Use std::vector.
6313 * value.c (value_free): Use operator delete.
6314 (value_of_xmethod): Rename to...
6315 (value_from_xmethod): ... this. Don't assign
6316 xmethod_worker::value, take rvalue-reference.
6317 (result_type_of_xmethod): Adjust.
6318 (call_xmethod): Adjust.
6319 * value.h: Include extension.h.
6320 (struct xmethod_worker): Don't forward-declare.
6321 (value_of_xmethod): Rename to...
6322 (value_from_xmethod): ... this, take rvalue-reference.
6323 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
6324 (struct python_xmethod_worker): ... this, add constructor and
6325 destructor.
6326 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
6327 (gdbpy_free_xmethod_worker_data): Rename to...
6328 (python_xmethod_worker::~python_xmethod_worker): ... this and
6329 adjust.
6330 (gdbpy_clone_xmethod_worker_data): Rename to...
6331 (python_xmethod_worker::clone): ... this and adjust.
6332 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
6333 temporary vector.
6334 (gdbpy_get_xmethod_arg_types): Rename to...
6335 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
6336 (gdbpy_get_xmethod_result_type): Rename to...
6337 (python_xmethod_worker::do_get_result_type): ... this and
6338 adjust.
6339 (gdbpy_invoke_xmethod): Rename to...
6340 (python_xmethod_worker::invoke): ... this and adjust.
6341 (new_python_xmethod_worker): Rename to...
6342 (python_xmethod_worker::python_xmethod_worker): ... this and
6343 adjust.
6344 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
6345 Remove.
6346 (gdbpy_free_xmethod_worker_data): Remove.
6347 (gdbpy_get_matching_xmethod_workers): Use std::vector.
6348 (gdbpy_get_xmethod_arg_types): Remove.
6349 (gdbpy_get_xmethod_result_type): Remove.
6350 (gdbpy_invoke_xmethod): Remove.
6351 * python/python.c (python_extension_ops): Remove obsolete
6352 callbacks.
6353
e379cee6
PA
63542018-01-05 Pedro Alves <palves@redhat.com>
6355
6356 PR gdb/18653
6357 * common/signals-state-save-restore.c
6358 (save_original_signals_state): New parameter 'quiet'. Warn if we
6359 find a custom handler preinstalled, instead of internal erroring.
6360 But only warn if !quiet.
6361 * common/signals-state-save-restore.h
6362 (save_original_signals_state): New parameter 'quiet'.
6363 * main.c (captured_main_1): Move save_original_signals_state call
6364 after option handling, and pass QUIET.
6365
a655456c
PA
63662018-01-05 Pedro Alves <palves@redhat.com>
6367
6368 * spu-tdep.c (spu_catch_start): Pass
6369 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
6370
de63c46b
PA
63712018-01-05 Pedro Alves <palves@redhat.com>
6372
6373 PR gdb/22670
6374 * ada-lang.c (literal_symbol_name_matcher): New function.
6375 (ada_get_symbol_name_matcher): Use it for
6376 symbol_name_match_type::SEARCH_NAME.
6377 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
6378 it down instead of assuming symbol_name_match_type::FULL.
6379 * block.h (block_lookup_symbol): New parameter 'match_type'.
6380 * c-valprint.c (print_unpacked_pointer): Use
6381 lookup_symbol_search_name instead of lookup_symbol.
6382 * compile/compile-object-load.c (get_out_value_type): Pass down
6383 symbol_name_match_type::SEARCH_NAME.
6384 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
6385 symbol_name_match_type::FULL.
6386 * cp-support.c (cp_get_symbol_name_matcher): Handle
6387 symbol_name_match_type::SEARCH_NAME.
6388 * infrun.c (insert_exception_resume_breakpoint): Use
6389 lookup_symbol_search_name.
6390 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
6391 * psymtab.c (maintenance_check_psymtabs): Use
6392 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
6393 * stack.c (print_frame_args): Use lookup_symbol_search_name and
6394 SYMBOL_SEARCH_NAME.
6395 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
6396 if symbol_name_match_type::SEARCH_NAME.
6397 (lookup_symbol_in_language): Pass down
6398 symbol_name_match_type::FULL.
6399 (lookup_symbol_search_name): New.
6400 (lookup_language_this): Pass down
6401 symbol_name_match_type::SEARCH_NAME.
6402 (lookup_symbol_aux, lookup_local_symbol): New parameter
6403 'match_type'. Pass it down.
6404 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
6405 (lookup_symbol_search_name): New declaration.
6406 (lookup_symbol_in_block): New 'match_type' parameter.
6407
f98fc17b
PA
64082018-01-05 Pedro Alves <palves@redhat.com>
6409
6410 PR gdb/22670
6411 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
6412 ada_lookup_symbol.
6413 (ada_lookup_symbol): Reimplement in terms of
6414 ada_lookup_symbol_list, bits factored out from
6415 ada_lookup_encoded_symbol.
6416
342f8240
JB
64172018-01-05 Joel Brobecker <brobecker@adacore.com>
6418
6419 * ada-exp.y (write_object_renaming): When subscripting an array
6420 using a symbol as the index, pass the block in call to
6421 ada_lookup_encoded_symbol when looking that symbol up.
6422
7150d33c
JG
64232018-01-05 Jerome Guitton <guitton@adacore.com>
6424
6425 * ada-lang.c (ada_array_length): Use ada_index_type instead of
6426 TYPE_INDEX_TYPE.
6427
cc0e770c
JB
64282018-01-05 Joel Brobecker <brobecker@adacore.com>
6429
6430 * ada-lang.c (ada_to_fixed_value_create): Add handling of
6431 the case where VALUE_LVAL (val0) is not lval_memory.
6432
f79da888 64332018-01-05 Xavier Roirand <roirand@adacore.com>
e3861a03
XR
6434
6435 * ada-valprint.c (print_optional_low_bound): Handle
6436 character-indexed array printing like boolean-indexed array
6437 printing.
6438
cd385f94
JB
64392018-01-05 Joel Brobecker <brobecker@adacore.com>
6440
6441 * NEWS: Create a new section for the next release branch.
6442 Rename the section of the current branch, now that it has
6443 been cut.
6444
09aca949
JB
64452018-01-05 Joel Brobecker <brobecker@adacore.com>
6446
6447 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
6448 * version.in: Bump version to 8.1.50.DATE-git.
6449
9f757bf7
XR
64502018-01-03 Xavier Roirand <roirand@adacore.com>
6451
6452 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
6453 Add field.
6454 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
6455 Add field.
6456 (default_exception_support_info) <catch_handlers_sym>: Add field.
6457 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
6458 (ada_exception_name_addr_1): Add "catch handlers" handling.
6459 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
6460 Update all callers.
6461 (create_excep_cond_exprs) <ex>: Add parameter.
6462 (re_set_exception): Update create_excep_cond_exprs call.
6463 (print_it_exception, print_one_exception, print_mention_exception)
6464 (print_recreate_exception): Add "catch handler" handling.
6465 (allocate_location_catch_handlers, re_set_catch_handlers)
6466 (check_status_catch_handlers, print_it_catch_handlers)
6467 (print_one_catch_handlers, print_mention_catch_handlers)
6468 (print_recreate_catch_handlers): New function.
6469 (catch_handlers_breakpoint_ops): New variable.
6470 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
6471 Add parameter. Add "catch handler" handling.
6472 (ada_exception_sym_name, ada_exception_breakpoint_ops):
6473 Add "catch handler" handling.
6474 (ada_exception_catchpoint_cond_string): Add "catch handler"
6475 handling.
6476 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
6477 call.
6478 (catch_ada_handlers_command): New function.
6479 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
6480 operations structure.
6481 (_initialize_ada_language): Add "catch handlers" command entry.
6482 * NEWS: Document "catch handlers" feature.
6483
9fe561ab
JB
64842018-01-02 Joel Brobecker <brobecker@adacore.com>
6485
6486 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
6487 account when creating the array type of the slice.
6488 (ada_value_slice): Likewise.
6489
a405673c
JB
64902018-01-02 Joel Brobecker <brobecker@adacore.com>
6491
6492 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
6493 New enum value.
6494 (create_array_type_with_stride): Add byte_stride_prop parameter.
6495 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
6496 New parameter. Update all callers in this file.
6497 (array_type_has_dynamic_stride): New function.
6498 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
6499 of arrays with dynamic byte strides.
6500 * dwarf2read.c (read_array_type): Add support for dynamic
6501 DW_AT_byte_stride attributes.
6502
74a2f8ff
JB
65032018-01-02 Joel Brobecker <brobecker@adacore.com>
6504
6505 * dwarf2read.c (read_unspecified_type): Treat
6506 DW_TAG_enumeration_type DIEs from Ada units as stubs.
6507
e2882c85
JB
65082018-01-01 Joel Brobecker <brobecker@adacore.com>
6509
6510 Update copyright year range in all GDB files.
6511
1690bb24
JB
65122018-01-01 Joel Brobecker <brobecker@adacore.com>
6513
6514 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
6515 and gdb/testsuite/gdb.base/step-line.c.
6516
0f0c98a8
JB
65172018-01-01 Joel Brobecker <brobecker@adacore.com>
6518
6519 * copyright.py (main): Dump the contents of
6520 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
6521 even if BY_HAND is empty.
6522
82e1e79a
JB
65232018-01-01 Joel Brobecker <brobecker@adacore.com>
6524
6525 * top.c (print_gdb_version): Update Copyright year in version
6526 message.
6527
053f54e5 65282018-01-01 Joel Brobecker <brobecker@adacore.com>
47fea877 6529
053f54e5 6530 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
47fea877 6531
053f54e5 6532For older changes see ChangeLog-2017.
c906108c
SS
6533\f
6534Local Variables:
6535mode: change-log
6536left-margin: 8
6537fill-column: 74
6538version-control: never
57da7796 6539coding: utf-8
c906108c 6540End: