Fix compilation error in ia64-tdep.c with libunwind-ia64
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
edb0470b
TT
12018-07-16 Tom Tromey <tom@tromey.com>
2
3 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
4 * dwarf2read.c (using_directives, new_symbol): Use
5 outermost_context_p.
6 * dbxread.c (process_one_symbol): Use outermost_context_p.
7 * coffread.c (coff_symtab_read): Use outermost_context_p.
8
6cccc9a8
TT
92018-07-16 Tom Tromey <tom@tromey.com>
10
11 * dwarf2read.c (using_directives, read_func_scope)
12 (read_lexical_block_scope): Update.
13 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
14 * buildsym.h (local_using_directives, global_using_directives):
15 Don't declare.
16 (get_local_using_directives, set_local_using_directives)
17 (get_global_using_directives): Declare.
18 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
19 m_global_using_directives>: New members.
20 (finish_block_internal, prepare_for_building)
21 (reset_symtab_globals, end_symtab_get_static_block)
22 (push_context): Update.
23 (get_local_using_directives, set_local_using_directives)
24 (get_global_using_directives): New functions.
25 (buildsym_init): Update.
26
652788a7
TT
272018-07-16 Tom Tromey <tom@tromey.com>
28
29 * xcoffread.c (xcoff_initial_scan): Don't call
30 free_pending_blocks.
31 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
32 * buildsym.h (class scoped_free_pendings): Add constructor.
33 (free_pending_blocks): Don't declare.
34 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
35 (free_pending_blocks): Now static.
36
8419ee53
TT
372018-07-16 Tom Tromey <tom@tromey.com>
38
39 * buildsym.h (push_subfile, pop_subfile): Update declarations.
40 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
41 member.
42 (struct subfile_stack): Remove.
43 (subfile_stack): Remove.
44 (push_subfile, pop_subfile, buildsym_init): Update.
45
ccdac490
TT
462018-07-16 Tom Tromey <tom@tromey.com>
47
48 * buildsym.c (push_subfile): Use gdb_assert.
49 (pop_subfile): Use gdb_assert.
50
43130d6f
TT
512018-07-16 Tom Tromey <tom@tromey.com>
52
53 * buildsym.h (merge_symbol_lists): Remove.
54 * buildsym.c (merge_symbol_lists): Remove.
55
77d6f1aa
TT
562018-07-16 Tom Tromey <tom@tromey.com>
57
58 * stabsread.c (scan_file_globals): Update comment.
59 * stabsread.h (scan_file_globals): Move from buildsym.h.
60 * buildsym.h (scan_file_globals): Move to stabsread.h.
61
2c722d18
TT
622018-07-16 Tom Tromey <tom@tromey.com>
63
64 * xcoffread.c (xcoff_new_init): Update.
65 * mipsread.c (mipscoff_new_init): Update.
66 * mdebugread.c (mdebug_build_psymtabs): Update.
67 * elfread.c (elf_new_init): Update.
68 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
69 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
70 * buildsym.h (buildsym_new_init): Don't declare.
71 * buildsym.c (buildsym_new_init): Remove.
72
5985ac61
TT
732018-07-16 Tom Tromey <tom@tromey.com>
74
75 * stabsread.h (within_function): Move from buildsym.h.
76 * stabsread.c (start_stabs): Clear within_function.
77 * coffread.c (coff_start_symtab): Clear within_function.
78 * buildsym.h (within_function): Move to stabsread.h.
79 * buildsym.c (prepare_for_building): Update.
80
6b84eeb2
TT
812018-07-16 Tom Tromey <tom@tromey.com>
82
83 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
84 * dwarf2read.c (dwarf2_start_symtab): Don't set
85 processing_gcc_compilation.
86 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
87
2150c3ef
TT
882018-07-16 Tom Tromey <tom@tromey.com>
89
90 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
91 (next_symbol_text_func): Move from buildsym.h.
92 * stabsread.c (hashname): Move from buildsym.c.
93 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
94 (next_symbol_text_func, hashname): Move to stabsread.h.
95 * buildsym.c: Don't include bcache.h
96 (hashname): Move to stasbread.c.
97
0ec44fc0
TT
982018-07-16 Tom Tromey <tom@tromey.com>
99
100 * buildsym.h (context_stack_size): Don't declare.
101 * buildsym.c (context_stack_size): New global.
102
81cc346d
TT
1032018-07-16 Tom Tromey <tom@tromey.com>
104
105 * dbxread.c (processing_acc_compilation): New global.
106 * buildsym.h (processing_acc_compilation): Don't declare.
107
2c99ee5c
TT
1082018-07-16 Tom Tromey <tom@tromey.com>
109
110 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
111 * dbxread.c (read_ofile_symtab): Update.
112 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
113 * buildsym.h (last_source_start_addr): Remove.
114 (set_last_source_start_addr, get_last_source_start_addr):
115 Declare.
116 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
117 parameter.
118 (struct buildsym_compunit) <m_last_source_start_addr>: New
119 member.
120 (prepare_for_building): Remove start_addr parameter.
121 (start_symtab, restart_symtab, end_symtab_get_static_block)
122 (end_symtab_with_blockvector): Update.
123 (set_last_source_start_addr, get_last_source_start_addr): New
124 functions.
125
530fedbc
TT
1262018-07-16 Tom Tromey <tom@tromey.com>
127
128 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
129 member.
130 (have_line_numbers): Remove.
131 (record_line, prepare_for_building, end_symtab_get_static_block)
132 (augment_type_symtab): Update.
133
6a976300
TT
1342018-07-16 Tom Tromey <tom@tromey.com>
135
136 * buildsym.c (~buildsym_compunit): Free the macro table.
137 (struct buildsym_compunit) <get_macro_table, release_macros>: New
138 methods.
139 <m_pending_macros>: New member.
140 (pending_macros): Remove.
141 (~scoped_free_pendings, get_macro_table, prepare_for_building)
142 (reset_symtab_globals, end_symtab_get_static_block)
143 (end_symtab_with_blockvector, augment_type_symtab)
144 (buildsym_init): Update.
145
c0015d44
TT
1462018-07-16 Tom Tromey <tom@tromey.com>
147
148 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
149 parameter.
150 (buildsym_compunit::set_last_source_file): New method.
151 <m_last_source_file>: New member.
152 (prepare_for_building): Remove "name" parameter.
153 (start_symtab, restart_symtab, reset_symtab_globals): Update.
154 (last_source_file): Remove.
155 (set_last_source_file, get_last_source_file): Update.
156
e62cca7c
TT
1572018-07-16 Tom Tromey <tom@tromey.com>
158
159 * buildsym.c (prepare_for_building): Add assert.
160
905eb0e2
TT
1612018-07-16 Tom Tromey <tom@tromey.com>
162
163 * buildsym.c (~buildsym_compunit): Update.
164 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
165 (start_subfile, patch_subfile_names)
166 (end_symtab_with_blockvector): Update.
167
b248663f
TT
1682018-07-16 Tom Tromey <tom@tromey.com>
169
170 * buildsym.c (struct buildsym_compunit): Add constructor,
171 destructor, initializers.
172 (start_buildsym_compunit): Remove.
173 (free_buildsym_compunit): Use "delete".
174 (start_symtab, restart_symtab): Use "new".
175
ff27d073
SM
1762018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
177
178 * symfile.c (set_objfile_default_section_offset): Remove struct
179 keyword.
180
6a15ecf5
SH
1812018-07-14 Stafford Horne <shorne@gmail.com>
182
183 * (Responsible Maintainers): Add myself as or1k maintainer.
184
027a4c30
TT
1852018-07-13 Tom Tromey <tom@tromey.com>
186
187 * symfile.c (set_objfile_default_section_offset): Use extra braces
188 around initializer.
189
5c1eda30
AA
1902018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
191
192 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
193 non-branching basr.
194
bc7b042b
PW
1952018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
196
197 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
198 unittests/cli-utils-selftests.c
199 * unittests/cli-utils-selftests.c: New file.
200
a14c4daa
PW
2012018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
202
203 * NEWS: Mention new commands. Mention change to 'thread apply'.
204
1fe75df7
PW
2052018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
206
207 * thread.c (thr_try_catch_cmd): New function.
208 (thread_apply_all_command): Handle qcs flags.
209 (thread_apply_command): Handle qcs flags.
210 (taas_command): New function.
211 (tfaas_command): New function.
212 (_initialize_thread): Update to setup the new commands 'taas
213 and 'tfaas'. Change doc string for 'thread apply'.
214
6a70eb7d
PW
2152018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
216
217 * stack.c: (trailing_outermost_frame): New function, mostly
218 extracted from backtrace_command_1.
219 (leading_innermost_frame): New function.
220 (backtrace_command_1): Update to call trailing_outermost_frame.
221 (frame_apply_command_count): New function.
222 (frame_apply_level_command): New function.
223 (frame_apply_all_command): New function.
224 (frame_apply_command): New function.
225 (faas_command): New function.
226 (frame_cmd_list): New variable.
227 (_initialize_stack): Update to setup the new commands 'frame apply'
228 and 'faas'.
229
529c08b2
PW
2302018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
231
232 * cli-utils.c (number_or_range_parser::get_number): Only handle
233 numbers or convenience var as numbers.
234 (parse_flags): New function.
235 (parse_flags_qcs): New function.
236 (number_or_range_parser::finished): Ensure parsing end is detected
237 before end of string.
238 * cli-utils.h (parse_flags): New function.
239 (parse_flags_qcs): New function.
240 (number_or_range_parser): Remove m_finished bool.
241 (number_or_range_parser::skip_range): Set m_in_range to false.
242
64b58472
SDJ
2432018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
244
245 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
246 on Windows.
247
c7ab0aef
SDJ
2482018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
249 Jan Kratochvil <jan.kratochvil@redhat.com>
250 Paul Fertser <fercerpav@gmail.com>
251 Tsutomu Seki <sekiriki@gmail.com>
252 Pedro Alves <palves@redhat.com>
253
254 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
255 'unittests/parse-connection-spec-selftests.c'.
256 (COMMON_SFILES): Add 'common/netstuff.c'.
257 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
258 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
259 * common/netstuff.c: New file.
260 * common/netstuff.h: New file.
261 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
262 (wait_for_connect): Update comment. New parameter
263 'gdb::optional<int> sock' instead of 'struct serial *scb'.
264 Use 'sock' directly instead of 'scb->fd'.
265 (try_connect): New function, with code from 'net_open'.
266 (net_open): Rewrite main loop to deal with multiple
267 sockets/addresses. Handle IPv6-style hostnames; implement
268 support for IPv6 connections.
269 * unittests/parse-connection-spec-selftests.c: New file.
270
4c7333b3
PA
2712018-07-11 Pedro Alves <palves@redhat.com>
272
273 PR gdb/23377
274 * remote.c (remote_target::remote_detach_pid): Call
275 set_current_process.
276
a6f88f6e
PA
2772018-07-11 Pedro Alves <palves@redhat.com>
278
279 * h8300-tdep.c (h8300_gdbarch_init): Remove
280 set_gdbarch_ecoff_reg_to_regnum calls.
281
16ff70dd
SDJ
2822018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
283
284 PR c++/23373
285 * c-typeprint.c (c_type_print_base_struct_union): Don't print
286 offsets/sizes for static members of a class/struct.
287
12863263
AH
2882018-07-11 Alan Hayward <alan.hayward@arm.com>
289
290 * target-descriptions.c (tdesc_register_bitsize): Rename.
291 * target-descriptions.h (tdesc_register_bitsize): Likewise.
292 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
293 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
294
1123588c
TT
2952018-07-10 Tom Tromey <tom@tromey.com>
296
297 * breakpoint.c (moribund_locations): Now static and a
298 std::vector.
299 (breakpoint_init_inferior, moribund_breakpoint_here_p)
300 (build_bpstat_chain, update_global_location_list)
301 (breakpoint_retire_moribund): Update.
302 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
303 VEC.
304
8c49aa89
AB
3052018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
306
307 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
308 (riscv_register_reggroup_p): Use new function, remove unneeded
309 parenthesis.
310 (riscv_push_dummy_call): Extend assert to compare against xlen or
311 flen based on register type.
312
42ecac17
AB
3132018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
314
315 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
316
055303e2
AB
3172018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
318
319 * remote.c (show_hardware_watchpoint_limit): New function.
320 (show_hardware_watchpoint_length_limit): New function.
321 (show_hardware_breakpoint_limit): New function.
322 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
323 where appropriate, update help text.
324
8fd32c1c
TT
3252018-07-09 Tom Tromey <tom@tromey.com>
326
327 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
328 (CLIBS): Don't mention NAT_CLIBS.
329
31278b51
TT
3302018-07-09 Tom Tromey <tom@tromey.com>
331
332 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
333 (LIBGDB_OBS, clean mostlyclean): Update.
334 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
335
e5fd1493
TT
3362018-07-09 Tom Tromey <tom@tromey.com>
337
338 * Makefile.in (%.c: %.y): Use ECHO_YACC.
339 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
340 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
341
981e0c0c
TT
3422018-07-09 Tom Tromey <tom@tromey.com>
343
344 * Makefile.in (ALLDEPFILES): Remove exec.c.
345 (COMMON_OBS): Remove exec.o.
346 (COMMON_SFILES): Add exec.c.
347
14ccceb2
TT
3482018-07-09 Tom Tromey <tom@tromey.com>
349
350 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
351
5d3c3a68
TT
3522018-07-09 Tom Tromey <tom@tromey.com>
353
354 * Makefile.in (clean mostlyclean): Remove stamp-version.
355 (version.c): Depend on stamp-version.
356 (stamp-version): New rule, from version.c rule.
357
1998086d
TT
3582018-07-09 Tom Tromey <tom@tromey.com>
359
360 * Makefile.in (init.c): Depend on stamp-init.
361 (stamp-init): New rule, from init.c rule.
362 (clean mostlyclean): Remove stamp-init.
363
4c754949
TT
3642018-07-09 Tom Tromey <tom@tromey.com>
365
366 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
367 SUBDIR_GCC_COMPILE_SRCS.
368
6497f1dd
TT
3692018-07-09 Tom Tromey <tom@tromey.com>
370
371 * Makefile.in (init.c): Remove some unused sed rules.
372
97a34db9
TT
3732018-07-09 Tom Tromey <tom@tromey.com>
374
375 * Makefile.in (TSOBS): Remove.
376 (INIT_FILES): Update.
377 (LIBGDB_OBS): Update.
378 (COMMON_SFILES): Add inflow.c.
379 (SFILES): Remove inflow.c.
380
25289ac1
JK
3812018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
382
383 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
384
e83f4d97
SM
3852018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
386
4869c585
SM
387 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
388 get_saveloc_name, is_signal_frame_name, step_name,
389 init_remote_name, create_addr_space_name,
390 destroy_addr_space_name, search_unwind_table_name,
391 find_dyn_list_name): Constify.
e83f4d97 392
6821842f
SM
3932018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
394
395 * darwin-nat.c (darwin_pthread_kill): New function.
396 (darwin_resume_thread): Use darwin_pthread_kill.
397
c530603c
TV
3982018-07-05 Tom de Vries <tdevries@suse.de>
399
400 * macroexp.c (macro_buffer) <operator=>: New member function.
401
a7d0f0f0
TT
4022018-07-04 Tom Tromey <tom@tromey.com>
403
404 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
405
6242c6a6
SM
4062018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
407
408 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
409 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
410 * maint.c: Likewise.
411 * top.c: Likewise.
412
4e5b2f89
JB
4132018-07-04 Joel Brobecker <brobecker@adacore.com>
414
415 * NEWS: Create a new section for the next release branch.
416 Rename the section of the current branch, now that it has
417 been cut.
418
538ccc4a
JB
4192018-07-04 Joel Brobecker <brobecker@adacore.com>
420
421 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
422 * version.in: Bump version to 8.2.50.DATE-git.
423
1b919490
VB
4242018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
425 Pedro Alves <palves@redhat.com>
426
427 * linux-nat.c (linux_init_ptrace): Rename to ...
428 (linux_init_ptrace_procfs): ... this. Call
429 linux_proc_init_warnings.
430 (linux_nat_target::post_attach)
431 (linux_nat_target::post_startup_inferior): Adjust.
432 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
433 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
434
1ea5da02
TV
4352018-07-04 Tom de Vries <tdevries@suse.de>
436
437 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
438 check ...
439 (read_comp_unit_head): ... here.
440
f51e0e20
TT
4412018-07-03 Tom Tromey <tom@tromey.com>
442
443 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
444 (stop_tracing, tstatus_command)
445 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
446 (print_one_static_tracepoint_marker): Update.
447 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
448 std::vector.
449 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
450 VEC.
451 (all_tracepoints, static_tracepoints_here): Return std::vector.
452
d7e15655
TT
4532018-07-03 Tom Tromey <tom@tromey.com>
454
455 * common/ptid.c (ptid_equal): Remove.
456 * common/ptid.h (ptid_equal): Don't declare.
457 * ada-tasks.c: Update.
458 * breakpoint.c: Update.
459 * common/agent.c: Update.
460 * corelow.c: Update.
461 * darwin-nat-info.c: Update.
462 * darwin-nat.c: Update.
463 * dcache.c: Update.
464 * dtrace-probe.c: Update.
465 * dummy-frame.c: Update.
466 * fbsd-nat.c: Update.
467 * frame.c: Update.
468 * gdbthread.h: Update.
469 * gnu-nat.c: Update.
470 * go32-nat.c: Update.
471 * inf-loop.c: Update.
472 * inf-ptrace.c: Update.
473 * infcall.c: Update.
474 * infcmd.c: Update.
475 * inflow.c: Update.
476 * infrun.c: Update.
477 * linux-fork.c: Update.
478 * linux-nat.c: Update.
479 * linux-thread-db.c: Update.
480 * mi/mi-cmd-var.c: Update.
481 * mi/mi-interp.c: Update.
482 * mi/mi-main.c: Update.
483 * nto-procfs.c: Update.
484 * ppc-linux-tdep.c: Update.
485 * procfs.c: Update.
486 * python/py-inferior.c: Update.
487 * python/py-record-btrace.c: Update.
488 * python/py-record.c: Update.
489 * ravenscar-thread.c: Update.
490 * regcache.c: Update.
491 * remote-sim.c: Update.
492 * remote.c: Update.
493 * sol-thread.c: Update.
494 * solib.c: Update.
495 * target.c: Update.
496 * tui/tui-stack.c: Update.
497 * varobj.c: Update.
498 * windows-nat.c: Update.
499 * windows-tdep.c: Update.
500
26a57c92
TT
5012018-07-03 Tom Tromey <tom@tromey.com>
502
503 * common/ptid.c (ptid_match): Remove.
504 * common/ptid.h (ptid_match): Don't declare.
505 * fbsd-nat.c: Update.
506 * infcmd.c: Update.
507 * infrun.c: Update.
508 * linux-nat.c: Update.
509 * record-btrace.c: Update.
510 * regcache.c: Update.
511 * remote.c: Update.
512
d2a107e3
TT
5132018-07-03 Tom Tromey <tom@tromey.com>
514
515 * common/ptid.c (ptid_tid_p): Remove.
516 * common/ptid.h (ptid_tid_p): Don't declare.
517 * sol-thread.c: Update.
518
15a9e13e
TT
5192018-07-03 Tom Tromey <tom@tromey.com>
520
521 * common/ptid.c (ptid_lwp_p): Remove.
522 * common/ptid.h (ptid_lwp_p): Don't declare.
523 * fbsd-nat.c: Update.
524 * linux-nat.c: Update.
525 * nat/linux-procfs.c: Update.
526 * nat/x86-linux-dregs.c: Update.
527 * sol-thread.c: Update.
528
0e998d96
TT
5292018-07-03 Tom Tromey <tom@tromey.com>
530
531 * common/ptid.c (ptid_is_pid): Remove.
532 * common/ptid.h (ptid_is_pid): Don't declare.
533 * infrun.c: Update.
534 * linux-nat.c: Update.
535 * mi/mi-interp.c: Update.
536 * remote.c: Update.
537 * thread.c: Update.
538
cc6bcb54
TT
5392018-07-03 Tom Tromey <tom@tromey.com>
540
541 * common/ptid.c (ptid_get_tid): Remove.
542 * common/ptid.h (ptid_get_tid): Don't declare.
543 * ada-tasks.c: Update.
544 * aix-thread.c: Update.
545 * bsd-uthread.c: Update.
546 * darwin-nat.c: Update.
547 * fbsd-nat.c: Update.
548 * i386-darwin-nat.c: Update.
549 * infrun.c: Update.
550 * linux-tdep.c: Update.
551 * nto-procfs.c: Update.
552 * ppc-ravenscar-thread.c: Update.
553 * python/py-infthread.c: Update.
554 * ravenscar-thread.c: Update.
555 * sol-thread.c: Update.
556 * sparc-ravenscar-thread.c: Update.
557 * windows-nat.c: Update.
558
e38504b3
TT
5592018-07-03 Tom Tromey <tom@tromey.com>
560
561 * common/ptid.c (ptid_get_lwp): Remove.
562 * common/ptid.h (ptid_get_lwp): Don't declare.
563 * aarch64-linux-nat.c: Update.
564 * ada-tasks.c: Update.
565 * aix-thread.c: Update.
566 * amd64-linux-nat.c: Update.
567 * arm-linux-nat.c: Update.
568 * corelow.c: Update.
569 * fbsd-nat.c: Update.
570 * fbsd-tdep.c: Update.
571 * gnu-nat.c: Update.
572 * i386-cygwin-tdep.c: Update.
573 * i386-gnu-nat.c: Update.
574 * i386-linux-nat.c: Update.
575 * ia64-linux-nat.c: Update.
576 * inf-ptrace.c: Update.
577 * infrun.c: Update.
578 * linux-fork.c: Update.
579 * linux-nat.c: Update.
580 * linux-tdep.c: Update.
581 * linux-thread-db.c: Update.
582 * mips-linux-nat.c: Update.
583 * nat/aarch64-linux-hw-point.c: Update.
584 * nat/aarch64-linux.c: Update.
585 * nat/linux-btrace.c: Update.
586 * nat/linux-osdata.c: Update.
587 * nat/linux-procfs.c: Update.
588 * nat/x86-linux-dregs.c: Update.
589 * obsd-nat.c: Update.
590 * ppc-fbsd-nat.c: Update.
591 * ppc-linux-nat.c: Update.
592 * procfs.c: Update.
593 * python/py-infthread.c: Update.
594 * ravenscar-thread.c: Update.
595 * remote.c: Update.
596 * s390-linux-nat.c: Update.
597 * sol-thread.c: Update.
598 * sol2-tdep.c: Update.
599 * spu-linux-nat.c: Update.
600 * x86-linux-nat.c: Update.
601 * xtensa-linux-nat.c: Update.
602
e99b03dc
TT
6032018-07-03 Tom Tromey <tom@tromey.com>
604
605 * common/ptid.c (ptid_get_pid): Remove.
606 * common/ptid.h (ptid_get_pid): Don't declare.
607 * aarch64-linux-nat.c: Update.
608 * ada-lang.c: Update.
609 * aix-thread.c: Update.
610 * alpha-bsd-nat.c: Update.
611 * amd64-fbsd-nat.c: Update.
612 * amd64-linux-nat.c: Update.
613 * arm-linux-nat.c: Update.
614 * arm-nbsd-nat.c: Update.
615 * auxv.c: Update.
616 * break-catch-syscall.c: Update.
617 * breakpoint.c: Update.
618 * bsd-uthread.c: Update.
619 * corelow.c: Update.
620 * ctf.c: Update.
621 * darwin-nat.c: Update.
622 * fbsd-nat.c: Update.
623 * fbsd-tdep.c: Update.
624 * gcore.c: Update.
625 * gnu-nat.c: Update.
626 * hppa-nbsd-nat.c: Update.
627 * hppa-obsd-nat.c: Update.
628 * i386-fbsd-nat.c: Update.
629 * ia64-linux-nat.c: Update.
630 * inf-ptrace.c: Update.
631 * infcmd.c: Update.
632 * inferior.c: Update.
633 * inferior.h: Update.
634 * inflow.c: Update.
635 * infrun.c: Update.
636 * linux-fork.c: Update.
637 * linux-nat.c: Update.
638 * linux-tdep.c: Update.
639 * linux-thread-db.c: Update.
640 * m68k-bsd-nat.c: Update.
641 * mi/mi-interp.c: Update.
642 * mi/mi-main.c: Update.
643 * mips-linux-nat.c: Update.
644 * mips-nbsd-nat.c: Update.
645 * mips64-obsd-nat.c: Update.
646 * nat/aarch64-linux-hw-point.c: Update.
647 * nat/aarch64-linux.c: Update.
648 * nat/linux-btrace.c: Update.
649 * nat/linux-osdata.c: Update.
650 * nat/linux-procfs.c: Update.
651 * nat/x86-linux-dregs.c: Update.
652 * nto-procfs.c: Update.
653 * obsd-nat.c: Update.
654 * ppc-linux-nat.c: Update.
655 * ppc-nbsd-nat.c: Update.
656 * ppc-obsd-nat.c: Update.
657 * proc-service.c: Update.
658 * procfs.c: Update.
659 * python/py-inferior.c: Update.
660 * python/py-infthread.c: Update.
661 * ravenscar-thread.c: Update.
662 * record.c: Update.
663 * remote-sim.c: Update.
664 * remote.c: Update.
665 * rs6000-nat.c: Update.
666 * s390-linux-nat.c: Update.
667 * sh-nbsd-nat.c: Update.
668 * sol-thread.c: Update.
669 * sparc-nat.c: Update.
670 * sparc64-tdep.c: Update.
671 * spu-linux-nat.c: Update.
672 * spu-tdep.c: Update.
673 * target-debug.h: Update.
674 * target.c: Update.
675 * thread.c: Update.
676 * tid-parse.c: Update.
677 * tracefile-tfile.c: Update.
678 * vax-bsd-nat.c: Update.
679 * windows-nat.c: Update.
680 * x86-linux-nat.c: Update.
681 * x86-nat.c: Update.
682
f2907e49
TT
6832018-07-03 Tom Tromey <tom@tromey.com>
684
685 * common/ptid.c (pid_to_ptid): Remove.
686 * common/ptid.h (pid_to_ptid): Don't declare.
687 * aix-thread.c: Update.
688 * arm-linux-nat.c: Update.
689 * common/ptid.c: Update.
690 * common/ptid.h: Update.
691 * corelow.c: Update.
692 * ctf.c: Update.
693 * darwin-nat.c: Update.
694 * fbsd-nat.c: Update.
695 * fork-child.c: Update.
696 * gnu-nat.c: Update.
697 * go32-nat.c: Update.
698 * inf-ptrace.c: Update.
699 * infcmd.c: Update.
700 * inferior.c: Update.
701 * infrun.c: Update.
702 * linux-fork.c: Update.
703 * linux-nat.c: Update.
704 * nat/aarch64-linux-hw-point.c: Update.
705 * nat/fork-inferior.c: Update.
706 * nat/x86-linux-dregs.c: Update.
707 * nto-procfs.c: Update.
708 * obsd-nat.c: Update.
709 * procfs.c: Update.
710 * progspace.c: Update.
711 * remote.c: Update.
712 * rs6000-nat.c: Update.
713 * s390-linux-nat.c: Update.
714 * sol-thread.c: Update.
715 * spu-linux-nat.c: Update.
716 * target.c: Update.
717 * top.c: Update.
718 * tracefile-tfile.c: Update.
719 * windows-nat.c: Update.
720
fd79271b
TT
7212018-07-03 Tom Tromey <tom@tromey.com>
722
723 * common/ptid.h (ptid_build): Don't declare.
724 * common/ptid.c (ptid_build): Remove.
725 * aix-thread.c: Update.
726 * bsd-kvm.c: Update.
727 * bsd-uthread.c: Update.
728 * common/agent.c: Update.
729 * common/ptid.c: Update.
730 * common/ptid.h: Update.
731 * corelow.c: Update.
732 * darwin-nat.c: Update.
733 * fbsd-nat.c: Update.
734 * gnu-nat.c: Update.
735 * linux-fork.c: Update.
736 * linux-nat.c: Update.
737 * linux-thread-db.c: Update.
738 * nat/linux-osdata.c: Update.
739 * nat/linux-procfs.c: Update.
740 * nto-procfs.c: Update.
741 * obsd-nat.c: Update.
742 * proc-service.c: Update.
743 * procfs.c: Update.
744 * ravenscar-thread.c: Update.
745 * remote-sim.c: Update.
746 * remote.c: Update.
747 * sol-thread.c: Update.
748 * target.c: Update.
749 * windows-nat.c: Update.
750
057302ce
TT
7512018-07-03 Tom Tromey <tom@tromey.com>
752
753 * infrun.c (follow_exec): Use exit_inferior_silent.
754 * inferior.c (exit_inferior_num_silent): Remove.
755 * inferior.h (exit_inferior_num_silent): Don't declare.
756
a50c11c6
TT
7572018-07-03 Tom Tromey <tom@tromey.com>
758
759 PR cli/23340:
760 * darwin-nat.c (darwin_attach_pid): Reset inferior and
761 inferior_ptid on error.
762
471b9d15
MR
7632018-07-02 Maciej W. Rozycki <macro@mips.com>
764 Simon Marchi <simon.marchi@polymtl.ca>
765
766 PR tdep/8282
767 * disasm.h (gdb_disassembler): Add
768 `m_disassembler_options_holder'. member
769 * disasm.c (get_all_disassembler_options): New function.
770 (gdb_disassembler::gdb_disassembler): Use it.
771 (gdb_buffered_insn_length_init_dis): Likewise.
772 (gdb_buffered_insn_length): Adjust accordingly.
773 (set_disassembler_options): Handle options with arguments.
774 (show_disassembler_options_sfunc): Likewise. Add a leading new
775 line if showing options with descriptions.
776 (disassembler_options_completer): Adapt to using the
777 `disasm_options_and_args_t' structure.
778 * mips-tdep.c (mips_disassembler_options): New variable.
779 (mips_disassembler_options_o32): Likewise.
780 (mips_disassembler_options_n32): Likewise.
781 (mips_disassembler_options_n64): Likewise.
782 (gdb_print_insn_mips): Don't set `disassembler_options'.
783 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
784 functions.
785 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
786 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
787 `gdbarch_disassembler_options_implicit' and
788 `gdbarch_valid_disassembler_options'.
789 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
790 `disasm_options_and_args_t' structure.
791 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
792 method.
793 (valid_disassembler_options): Switch from `disasm_options_t' to
794 the `disasm_options_and_args_t' structure.
795 * NEWS: Document `set disassembler-options' support for the MIPS
796 target.
797 * gdbarch.h: Regenerate.
798 * gdbarch.c: Regenerate.
799
41823f29
SH
8002018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
801
802 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
803
41206e32
JB
8042018-06-29 Joel Brobecker <brobecker@adacore.com>
805
806 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
807 parameter in call to amd64_target_description.
808 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
809 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
810 (amd64fbsd_init_abi): Likewise.
811 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
812 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
813 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
814 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
815
de52b960
PA
8162018-06-29 Pedro Alves <palves@redhat.com>
817
818 * gdb/amd64-tdep.h (amd64_create_target_description): Add
819 "segments" parameter.
820 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
821 (_initialize_amd64_tdep): Update call to
822 amd64_create_target_description.
823 (amd64_target_description): Add "segments" parameter. Adjust
824 the implementation to use it.
825 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
826 call to amd64_create_target_description.
827 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
828 * gdb/arch/amd64.h (amd64_create_target_description): Add
829 "segments" register.
830 * gdb/arch/amd64.c (amd64_create_target_description): Add
831 "segments" parameter. Call create_feature_i386_64bit_segments
832 only if SEGMENTS is true.
833 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
834 call to amd64_create_target_description.
835
75acb486
PA
8362018-06-29 Pedro Alves <palves@redhat.com>
837
838 * thread.c (thread_target_id_str): New, factored out from ...
839 (print_thread_info_1): ... here. Use it to compute the max
840 "Target Id" column width.
841
c76a8ea3
PA
8422018-06-29 Pedro Alves <palves@redhat.com>
843
844 * remote.c (remote_target::extra_thread_info): Delete
845 'display_buf' and 'n' locals. from the cache, regardless of
846 packet mechanims is in use. Use cache for qThreadExtra and qP
847 methods too.
848
cd2bb709
PA
8492018-06-29 Pedro Alves <palves@redhat.com>
850
851 * blockframe.c (find_pc_sect_containing_function): New function.
852 * breakpoint.c (print_breakpoint_location): Don't call
853 find_pc_sect_function.
854 * linespec.c (create_sals_line_offset): Record the location's
855 symbol in the sal.
856 * linespec.c (convert_address_location_to_sals): Fill in sal's
857 symbol with find_pc_sect_containing_function.
858 * symtab.c (find_function_start_sal): Rename to ...
859 (find_function_start_sal_1): ... this.
860 (find_function_start_sal): Reimplement as wrapper around
861 find_function_start_sal_1, and use
862 find_pc_sect_containing_function to fill in the sal's symbol.
863 (find_function_start_sal(symbol*, bool)): Adjust.
864 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
865 comments.
866 (find_pc_sect_containing_function): Declare.
867
991ff292
PA
8682018-06-29 Pedro Alves <palves@redhat.com>
869
870 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
871 true if the the location has no symbol.
872
44cee4fd
TT
8732018-06-28 Tom Tromey <tom@tromey.com>
874
875 * NEWS: Mention --enable-codesign.
876 * silent-rules.mk (ECHO_SIGN): New variable.
877 * configure.ac: Add --enable-codesign.
878 * configure: Rebuild.
879 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
880 (gdb$(EXEEXT)): Optionally invoke codesign.
881
f2ffa92b
PA
8822018-06-28 Pedro Alves <palves@redhat.com>
883
884 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
885 comments.
886 (switch_to_thread_no_regs): Adjust comment.
887 * infcmd.c (stop_pc): Delete.
888 (post_create_inferior, info_program_command): Replace references
889 to stop_pc with references to thread_info->suspend.stop_pc.
890 * inferior.h (stop_pc): Delete declaration.
891 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
892 (handle_inferior_event_1, handle_signal_stop)
893 (process_event_stop_test, keep_going_stepped_thread)
894 (handle_step_into_function, handle_step_into_function_backward)
895 (print_stop_location): Replace references to stop_pc with
896 references to thread_info->suspend.stop_pc.
897 (struct infcall_suspend_state) <stop_pc>: Delete field.
898 (save_infcall_suspend_state, restore_infcall_suspend_state):
899 Remove references to inf_stat->stop_pc.
900 * linux-fork.c (fork_load_infrun_state): Likewise.
901 * record-btrace.c (record_btrace_set_replay): Likewise.
902 * record-full.c (record_full_goto_entry): Likewise.
903 * remote.c (print_one_stopped_thread): Likewise.
904 * target.c (target_resume): Extend comment.
905 * thread.c (set_executing_thread): New.
906 (set_executing): Use it.
907 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
908 Remove references to stop_pc.
909
ecdc3a72
PA
9102018-06-28 Pedro Alves <palves@redhat.com>
911
912 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
913 Moving fetching stop_pc until after ecs->event_thread is refreshed.
914
d95d3aef
TT
9152018-06-28 Tom Tromey <tom@tromey.com>
916
917 * coffread.c (coff_symfile_finish): Update.
918 * xcoffread.c (xcoff_symfile_finish): Update.
919 * elfread.c (elf_symfile_finish): Update.
920 * symfile.h (dwarf2_free_objfile): Don't declare.
921 * dwarf2read.c (_initialize_dwarf2_read): Use
922 register_objfile_data_with_cleanup.
923 (dwarf2_free_objfile): Now static. Change signature.
924
291f9a96
PT
9252018-06-28 Petr Tesarik <ptesarik@suse.cz>
926
927 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
928 option "-o" to add-symbol-file-load to add an offset to each
929 section's load address.
930 * symfile.c (set_objfile_default_section_offset): New function.
931
d81a3eaf
PT
9322018-06-28 Petr Tesarik <ptesarik@suse.cz>
933
934 * symfile.c (add_symbol_file_command): Make sure that sections
935 with the same name are sorted in the same order.
936
ed6dfe51
PT
9372018-06-28 Petr Tesarik <ptesarik@suse.cz>
938
939 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
940 require the second argument. If omitted, load sections at the
941 addresses specified in the file.
942
d4d429d5
PT
9432018-06-28 Petr Tesarik <ptesarik@suse.cz>
944
945 * symfile.c (symbol_file_command, symbol_file_add_main_1)
946 (_initialize_symfile): Add option "-o" to symbol-file to add an
947 offset to each section of the symbol file.
948
39b27ab6
PT
9492018-06-28 Petr Tesarik <ptesarik@suse.cz>
950
951 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
952
41827fc3
TT
9532018-06-27 Tom Tromey <tom@tromey.com>
954
955 * stack.c (_initialize_stack): Update "func" help text.
956
0c6aef22
TT
9572018-06-27 Tom Tromey <tom@tromey.com>
958
959 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
960 std::vector.
961 (unwind_infopy_str, pyuw_create_unwind_info)
962 (unwind_infopy_add_saved_register, pyuw_sniffer)
963 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
964 Update.
965 (struct saved_reg): Add constructor.
966 <value>: Now a gdbpy_ref<>.
967
63177289
TT
9682018-06-27 Tom Tromey <tom@tromey.com>
969
970 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
971
e76f78a0
SM
9722018-06-27 Simon Marchi <simon.marchi@ericsson.com>
973
974 * gdb-gdb.py.in: Format using autopep8.
975
9a14af7b
SM
9762018-06-27 Simon Marchi <simon.marchi@ericsson.com>
977
978 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
979 (type_lookup_function): Recognize CORE_ADDR values.
980
189366cd
SM
9812018-06-27 Simon Marchi <simon.marchi@ericsson.com>
982
983 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
984 print tag_name.
985
68ad5fb9
SM
9862018-06-27 Simon Marchi <simon.marchi@ericsson.com>
987
988 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
989 <__lt__>: Add.
990
141ec9f6
SM
9912018-06-27 Simon Marchi <simon.marchi@ericsson.com>
992
993 * gdb-gdb.py: Move to...
994 * gdb-gdb.py.in: ... here.
995 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
996 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
997 dependencies.
998 (distclean): Remove gdb-gdb.py when cleaning.
999 (gdb-gdb.py, gdb-gdb.gdb): New rules.
1000 * configure: Re-generate.
1001
4c4e7ad4
PA
10022018-06-27 Pedro Alves <palves@redhat.com>
1003
1004 * proc-service.c (get_ps_regcache): New.
1005 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
1006 (ps_lsetfpregs): Use it.
1007
7ab6656f
OJ
10082018-06-27 Omair Javaid <omair.javaid@linaro.org>
1009
1010 PR gdb/21695
1011 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
1012 (dwarf_decode_lines_1): Adjust.
1013
bd583225
SM
10142018-06-27 Simon Marchi <simon.marchi@ericsson.com>
1015
1016 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
1017 override.
1018 <info_proc>: Likewise.
1019
9a325b7b
JB
10202018-06-26 Joel Brobecker <brobecker@adacore.com>
1021
1022 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
1023 to windows_fetch_one_register, and only handle the case of
1024 fetching one register. Move the code that reloads the context
1025 and iterates over all registers if R is negative to...
1026 (windows_nat_target::fetch_registers): ... here.
1027 (do_windows_store_inferior_registers): Rename to
1028 windows_store_one_register, and only handle the case of storing
1029 one register. Move the code that handles the case where r is
1030 negative to...
1031 (windows_nat_target::store_registers) ... here.
1032
a33ccfc7
TT
10332018-06-26 Tom Tromey <tom@tromey.com>
1034
1035 PR rust/22574:
1036 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
1037 * rust-lang.c (rust_print_struct_def): Add podata parameter.
1038 Update.
1039 (rust_internal_print_type): Add podata parameter.
1040 (rust_print_type): Update.
1041
e0c547d1
TT
10422018-06-26 Tom Tromey <tom@tromey.com>
1043
1044 * typeprint.h (struct print_offset_data) <update, finish,
1045 maybe_print_hole>: New methods.
1046 <indentation>: New constant.
1047 * typeprint.c (print_offset_data::indentation): Define.
1048 (print_offset_data::maybe_print_hole, print_offset_data::update)
1049 (print_offset_data::finish): Move from c-typeprint.c and rename.
1050 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
1051 (print_spaces_filtered_with_print_options): Update.
1052 (c_print_type_union_field_offset, maybe_print_hole)
1053 (c_print_type_struct_field_offset): Move to typeprint.c and
1054 rename.
1055 (c_type_print_base_struct_union): Update.
1056
75cbc781
PA
10572018-06-25 Pedro Alves <palves@redhat.com>
1058
1059 * gdbthread.h (thread_info_ref, delete_thread)
1060 (delete_thread_silent, first_thread_of_inferior)
1061 (any_thread_of_inferior, switch_to_thread)
1062 (enable_thread_stack_temporaries)
1063 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1064 (get_last_thread_stack_temporary)
1065 (value_in_thread_stack_temporaries, can_access_registers_thread):
1066 Spell out "struct thread_info" instead of just "thread_info".
1067 * inferior.h (notice_new_inferior): Likewise.
1068
b7a08269
PA
10692018-06-25 Pedro Alves <palves@redhat.com>
1070
1071 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
1072 pass thread_info pointer to delete_thread.
1073 (windows_nat_target::detach): Pass inferior pointer to
1074 detach_inferior.
1075 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
1076 delete_thread.
1077 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
1078 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
1079 and pass a thread_info pointer to delete_thread.
1080 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
1081 pass thread_info pointer to delete_thread.
1082 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
1083 delete_thread_silent call.
1084 * procfs.c (procfs_target::detach): Pass inferior pointer to
1085 detach_inferior.
1086 (procfs_target::wait): Pass thread_info pointer to delete_thread.
1087 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
1088 delete_thread_silent call.
1089 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
1090 pass thread_info pointer to delete_thread.
1091 (windows_nat_target::detach): Pass inferior pointer to
1092 delete_inferior.
1093
8e7767e3
AH
10942018-06-22 Alan Hayward <alan.hayward@arm.com>
1095
1096 * regcache.c (readable_regcache::read_part): Fix asserts.
1097 (reg_buffer::raw_collect_part): New function.
1098 (regcache::write_part): Fix asserts.
1099 (reg_buffer::raw_supply_part): New function.
1100 (regcache::transfer_regset_register): New helper function.
1101 (regcache::transfer_regset): Call new functions.
1102 (regcache_supply_regset): Use gdb_byte*.
1103 (regcache::supply_regset): Likewise.
1104 (regcache_collect_regset): Likewise.
1105 (regcache::collect_regset): Likewise.
1106 * regcache.h (reg_buffer::raw_collect_part): New declaration.
1107 (reg_buffer::raw_supply_part): Likewise.
1108 (regcache::transfer_regset_register): Likewise.
1109 (regcache::transfer_regset): Use gdb_byte*.
1110
bfd60e34
AH
11112018-06-22 Alan Hayward <alan.hayward@arm.com>
1112
1113 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
1114
00431a78
PA
11152018-06-21 Pedro Alves <palves@redhat.com>
1116
1117 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
1118 instead of a ptid_t. All callers adjusted.
1119 * ada-tasks.c (ada_get_task_number): Likewise. All callers
1120 adjusted.
1121 (print_ada_task_info, display_current_task_id, task_command_1):
1122 Adjust.
1123 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
1124 inferior_thread.
1125 (breakpoint_kind): Adjust.
1126 (remove_breakpoints_pid): Rename to ...
1127 (remove_breakpoints_inf): ... this. Adjust to take an inferior
1128 pointer. All callers adjusted.
1129 (bpstat_clear_actions): Use inferior_thread.
1130 (get_bpstat_thread): New.
1131 (bpstat_do_actions): Use it.
1132 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
1133 to take a thread_info pointer. All callers adjusted.
1134 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
1135 (breakpoint_re_set_thread): Use inferior_thread.
1136 * breakpoint.h (struct inferior): Forward declare.
1137 (bpstat_stop_status): Update.
1138 (remove_breakpoints_pid): Delete.
1139 (remove_breakpoints_inf): New.
1140 * bsd-uthread.c (bsd_uthread_target::wait)
1141 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
1142 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
1143 (maint_btrace_packet_history_cmd)
1144 (maint_btrace_clear_packet_history_cmd): Adjust.
1145 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
1146 inferior_thread.
1147 * cli/cli-interp.c: Include "inferior.h".
1148 * common/refcounted-object.h (struct
1149 refcounted_object_ref_policy): New.
1150 * compile/compile-object-load.c: Include gdbthread.h.
1151 (store_regs): Use inferior_thread.
1152 * corelow.c (core_target::close): Use current_inferior.
1153 (core_target_open): Adjust to use first_thread_of_inferior and use
1154 the current inferior.
1155 * ctf.c (ctf_target::close): Adjust to use current_inferior.
1156 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
1157 <thread>: ... this new field. All references adjusted.
1158 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
1159 Take a thread_info pointer instead of a ptid_t.
1160 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
1161 (dummy_frame_discard, register_dummy_frame_dtor): Take a
1162 thread_info pointer instead of a ptid_t.
1163 * elfread.c: Include "inferior.h".
1164 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
1165 Use inferior_thread.
1166 * eval.c (evaluate_subexp): Likewise.
1167 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
1168 inferior_thread.
1169 * gdb_proc_service.h (struct thread_info): Forward declare.
1170 (struct ps_prochandle) <ptid>: Delete, replaced by ...
1171 <thread>: ... this new field. All references adjusted.
1172 * gdbarch.h, gdbarch.c: Regenerate.
1173 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
1174 'thread' parameter. All implementations and callers adjusted.
1175 * gdbthread.h (thread_info) <set_running>: New method.
1176 (delete_thread, delete_thread_silent): Take a thread_info pointer
1177 instead of a ptid.
1178 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
1179 (first_thread_of_process): Delete, replaced by ...
1180 (first_thread_of_inferior): ... this new function. All callers
1181 adjusted.
1182 (any_live_thread_of_process): Delete, replaced by ...
1183 (any_live_thread_of_inferior): ... this new function. All callers
1184 adjusted.
1185 (switch_to_thread, switch_to_no_thread): Declare.
1186 (is_executing): Delete.
1187 (enable_thread_stack_temporaries): Update comment.
1188 <enable_thread_stack_temporaries>: Take a thread_info pointer
1189 instead of a ptid_t. Incref the thread.
1190 <~enable_thread_stack_temporaries>: Decref the thread.
1191 <m_ptid>: Delete
1192 <m_thr>: New.
1193 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1194 (get_last_thread_stack_temporary)
1195 (value_in_thread_stack_temporaries, can_access_registers_thread):
1196 Take a thread_info pointer instead of a ptid_t. All callers
1197 adjusted.
1198 * infcall.c (get_call_return_value): Use inferior_thread.
1199 (run_inferior_call): Work with thread pointers instead of ptid_t.
1200 (call_function_by_hand_dummy): Work with thread pointers instead
1201 of ptid_t. Use thread_info_ref.
1202 * infcmd.c (proceed_thread_callback): Access thread's state
1203 directly.
1204 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
1205 access thread's state directly.
1206 (continue_command): Use inferior_thread.
1207 (info_program_command): Use find_thread_ptid and access thread
1208 state directly.
1209 (proceed_after_attach_callback): Use thread state directly.
1210 (notice_new_inferior): Take a thread_info pointer instead of a
1211 ptid_t. All callers adjusted.
1212 (exit_inferior): Take an inferior pointer instead of a pid. All
1213 callers adjusted.
1214 (exit_inferior_silent): New.
1215 (detach_inferior): Delete.
1216 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
1217 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
1218 (detach_inferior_command, kill_inferior_command): Use
1219 find_inferior_id instead of valid_gdb_inferior_id and
1220 gdb_inferior_id_to_pid.
1221 (inferior_command): Use inferior and thread pointers.
1222 * inferior.h (struct thread_info): Forward declare.
1223 (notice_new_inferior): Take a thread_info pointer instead of a
1224 ptid_t. All callers adjusted.
1225 (detach_inferior): Delete declaration.
1226 (exit_inferior, exit_inferior_silent): Take an inferior pointer
1227 instead of a pid. All callers adjusted.
1228 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
1229 (valid_gdb_inferior_id): Delete.
1230 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
1231 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
1232 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
1233 ...
1234 <inf>: ... this new field.
1235 <step_ptid>: Delete, replaced by ...
1236 <step_thread>: ... this new field.
1237 (get_displaced_stepping_state): Take an inferior pointer instead
1238 of a pid. All callers adjusted.
1239 (displaced_step_in_progress_any_inferior): Adjust.
1240 (displaced_step_in_progress_thread): Take a thread pointer instead
1241 of a ptid_t. All callers adjusted.
1242 (displaced_step_in_progress, add_displaced_stepping_state): Take
1243 an inferior pointer instead of a pid. All callers adjusted.
1244 (get_displaced_step_closure_by_addr): Adjust.
1245 (remove_displaced_stepping_state): Take an inferior pointer
1246 instead of a pid. All callers adjusted.
1247 (displaced_step_prepare_throw, displaced_step_prepare)
1248 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
1249 All callers adjusted.
1250 (start_step_over): Adjust.
1251 (infrun_thread_ptid_changed): Remove bit updating ptids in the
1252 displaced step queue.
1253 (do_target_resume): Adjust.
1254 (fetch_inferior_event): Use inferior_thread.
1255 (context_switch, get_inferior_stop_soon): Take an
1256 execution_control_state pointer instead of a ptid_t. All callers
1257 adjusted.
1258 (switch_to_thread_cleanup): Delete.
1259 (stop_all_threads): Use scoped_restore_current_thread.
1260 * inline-frame.c: Include "gdbthread.h".
1261 (inline_state) <inline_state>: Take a thread pointer instead of a
1262 ptid_t. All callers adjusted.
1263 <ptid>: Delete, replaced by ...
1264 <thread>: ... this new field.
1265 (find_inline_frame_state): Take a thread pointer instead of a
1266 ptid_t. All callers adjusted.
1267 (skip_inline_frames, step_into_inline_frame)
1268 (inline_skipped_frames, inline_skipped_symbol): Take a thread
1269 pointer instead of a ptid_t. All callers adjusted.
1270 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
1271 (inline_skipped_frames, inline_skipped_symbol): Likewise.
1272 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
1273 pointers directly.
1274 * linux-nat.c (get_detach_signal): Likewise.
1275 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
1276 (thread_db_notice_clone): Adjust.
1277 (thread_db_find_new_threads_silently)
1278 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
1279 a thread pointer instead of a ptid_t. All callers adjusted.
1280 * mi/mi-cmd-var.c: Include "inferior.h".
1281 (mi_cmd_var_update_iter): Update to use thread pointers.
1282 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
1283 inferior directly.
1284 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
1285 out to ...
1286 (mi_output_running): ... this new function.
1287 (mi_on_resume_1): Adjust to use it.
1288 (mi_user_selected_context_changed): Adjust to use inferior_thread.
1289 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
1290 directly.
1291 (interrupt_thread_callback): : Adjust to use thread and inferior
1292 pointers.
1293 * proc-service.c: Include "gdbthread.h".
1294 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
1295 * progspace-and-thread.c: Include "inferior.h".
1296 * progspace.c: Include "inferior.h".
1297 * python/py-exitedevent.c (create_exited_event_object): Adjust to
1298 hold a reference to an inferior_object.
1299 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
1300 inferior_thread.
1301 * python/py-inferior.c (struct inferior_object): Give the type a
1302 tag name instead of a typedef.
1303 (python_on_normal_stop): No need to check if the current thread is
1304 listed.
1305 (inferior_to_inferior_object): Change return type to
1306 inferior_object. All callers adjusted.
1307 (find_thread_object): Delete, bits factored out to ...
1308 (thread_to_thread_object): ... this new function.
1309 * python/py-infthread.c (create_thread_object): Use
1310 inferior_to_inferior_object.
1311 (thpy_is_stopped): Use thread pointer directly.
1312 (gdbpy_selected_thread): Use inferior_thread.
1313 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
1314 field, replaced with ...
1315 <thread>: ... this new field. All users adjusted.
1316 (btpy_insn_or_gap_new): Drop const.
1317 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
1318 callers adjusted.
1319 * python/py-record.c: Include "gdbthread.h".
1320 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
1321 a ptid_t. All callers adjusted.
1322 (gdbpy_current_recording): Use inferior_thread.
1323 * python/py-record.h (recpy_record_object) <ptid>: Delete
1324 field, replaced with ...
1325 <thread>: ... this new field. All users adjusted.
1326 (recpy_element_object) <ptid>: Delete
1327 field, replaced with ...
1328 <thread>: ... this new field. All users adjusted.
1329 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
1330 a ptid_t. All callers adjusted.
1331 * python/py-threadevent.c: Include "gdbthread.h".
1332 (get_event_thread): Use thread_to_thread_object.
1333 * python/python-internal.h (struct inferior_object): Forward
1334 declare.
1335 (find_thread_object, find_inferior_object): Delete declarations.
1336 (thread_to_thread_object, inferior_to_inferior_object): New
1337 declarations.
1338 * record-btrace.c: Include "inferior.h".
1339 (require_btrace_thread): Use inferior_thread.
1340 (record_btrace_frame_sniffer)
1341 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
1342 (get_thread_current_frame): Use scoped_restore_current_thread and
1343 switch_to_thread.
1344 (get_thread_current_frame): Use thread pointer directly.
1345 (record_btrace_replay_at_breakpoint): Use thread's inferior
1346 pointer directly.
1347 * record-full.c: Include "inferior.h".
1348 * regcache.c: Include "gdbthread.h".
1349 (get_thread_arch_regcache): Use the inferior's address space
1350 directly.
1351 (get_thread_regcache, registers_changed_thread): New.
1352 * regcache.h (get_thread_regcache(thread_info *thread)): New
1353 overload.
1354 (registers_changed_thread): New.
1355 (remote_target) <remote_detach_1>: Swap order of parameters.
1356 (remote_add_thread): <remote_add_thread>: Return the new thread.
1357 (get_remote_thread_info(ptid_t)): New overload.
1358 (remote_target::remote_notice_new_inferior): Use thread pointers
1359 directly.
1360 (remote_target::process_initial_stop_replies): Use
1361 thread_info::set_running.
1362 (remote_target::remote_detach_1, remote_target::detach)
1363 (extended_remote_target::detach): Adjust.
1364 * stack.c (frame_show_address): Use inferior_thread.
1365 * target-debug.h (target_debug_print_thread_info_pp): New.
1366 * target-delegates.c: Regenerate.
1367 * target.c (default_thread_address_space): Delete.
1368 (memory_xfer_partial_1): Use current_inferior.
1369 (target_detach): Use current_inferior.
1370 (target_thread_address_space): Delete.
1371 (generic_mourn_inferior): Use current_inferior.
1372 * target.h (struct target_ops) <thread_address_space>: Delete.
1373 (target_thread_address_space): Delete.
1374 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
1375 pointers directly.
1376 (delete_thread_1, delete_thread, delete_thread_silent): Take a
1377 thread pointer instead of a ptid_t. Adjust all callers.
1378 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
1379 (first_thread_of_process): Delete, replaced by ...
1380 (first_thread_of_inferior): ... this new function. All callers
1381 adjusted.
1382 (any_thread_of_process): Rename to ...
1383 (any_thread_of_inferior): ... this, and take an inferior pointer.
1384 (any_live_thread_of_process): Rename to ...
1385 (any_live_thread_of_inferior): ... this, and take an inferior
1386 pointer.
1387 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1388 (value_in_thread_stack_temporaries)
1389 (get_last_thread_stack_temporary): Take a thread pointer instead
1390 of a ptid_t. Adjust all callers.
1391 (thread_info::set_running): New.
1392 (validate_registers_access): Use inferior_thread.
1393 (can_access_registers_ptid): Rename to ...
1394 (can_access_registers_thread): ... this, and take a thread
1395 pointer.
1396 (print_thread_info_1): Adjust to compare thread pointers instead
1397 of ptids.
1398 (switch_to_no_thread, switch_to_thread): Make extern.
1399 (scoped_restore_current_thread::~scoped_restore_current_thread):
1400 Use m_thread pointer directly.
1401 (scoped_restore_current_thread::scoped_restore_current_thread):
1402 Use inferior_thread.
1403 (thread_command): Use thread pointer directly.
1404 (thread_num_make_value_helper): Use inferior_thread.
1405 * top.c (execute_command): Use inferior_thread.
1406 * tui/tui-interp.c: Include "inferior.h".
1407 * varobj.c (varobj_create): Use inferior_thread.
1408 (value_of_root_1): Use find_thread_global_id instead of
1409 global_thread_id_to_ptid.
1410
33bab475
AH
14112018-06-21 Alan Hayward <alan.hayward@arm.com>
1412
1413 * regcache.c (readable_regcache::read_part): Avoid memcpy when
1414 possible.
1415 (regcache::write_part): Likewise.
1416 (readable_regcache::cooked_read_part): Update comment.
1417 (readable_regcache::cooked_write_part): Likewise.
1418 * regcache.h: (readable_regcache::read_part): Likewise.
1419 (regcache::write_part): Likewise.
1420
8363f9d5
RB
14212018-06-21 Richard Bunt <richard.bunt@arm.com>
1422 Dirk Schubert <dirk.schubert@arm.com>
1423
1424 * aarch64-linux-nat.c (post_attach): New.
1425 (aarch64_linux_nat_target::post_attach): Override post_attach to
1426 record the number of hardware debug registers.
1427
0d0b0ea2
TT
14282018-06-20 Tom Tromey <tom@tromey.com>
1429
1430 * python/py-param.c (add_setshow_generic): Make parameters const.
1431 (parmpy_init): Update.
1432
302abd6e
SM
14332018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
1434
1435 * regcache.h (regcache_cooked_read_ftype): Rename to...
1436 (register_read_ftype): ...this, change type to function_view.
1437 (class reg_buffer) <save>: Remove src parameter.
1438 (readonly_detached_regcache) <readonly_detached_regcache>: Make
1439 parameter non-const in first overload. Remove src parameter in
1440 second overload.
1441 * regcache.c (do_cooked_read): Remove.
1442 (readonly_detached_regcache::readonly_detached_regcache): Make
1443 parameter non-const, adjust call to other constructor.
1444 (reg_buffer::save): Remove src parameter.
1445 * frame.c (do_frame_register_read): Remove.
1446 (frame_save_as_regcache): Use lambda function.
1447 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
1448 parameter to ppu2spu_data *.
1449 (ppu2spu_sniffer): Use lambda function.
1450
19f3f25f
SM
14512018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
1452
1453 * record-full.c (record_full_target::insert_breakpoint): Remove
1454 "struct" keyword, add const.
1455
d0ac1c44
SM
14562018-06-19 Simon Marchi <simon.marchi@ericsson.com>
1457
1458 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
1459 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
1460 * configure.ac: Remove AC_PREREQ, add missing quoting.
1461 * gnulib/configure.ac: Modernize usage of
1462 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
1463 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
1464 (AUTOMAKE_VERSION): Bump to 1.15.1.
1465 * configure: Re-generate.
1466 * config.in: Re-generate.
1467 * aclocal.m4: Re-generate.
1468 * gnulib/aclocal.m4: Re-generate.
1469 * gnulib/config.in: Re-generate.
1470 * gnulib/configure: Re-generate.
1471 * gnulib/import/Makefile.in: Re-generate.
1472
6ae50267
PA
14732018-06-19 Pedro Alves <palves@redhat.com>
1474
1475 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
1476 (lookup_minimal_symbol_by_pc_section): ... here with
1477 gdb_assert_not_reached added.
1478
61b04dd0
PA
14792018-06-19 Pedro Alves <palves@redhat.com>
1480
1481 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
1482 parameter with a block parameter. Compare location's block symbol
1483 with the frame's block instead of addresses.
1484 (skip_inline_frames): Pass the current block instead of the
1485 frame's address. Break out as soon as we determine the frame
1486 should not be skipped.
1487
f709fabb
TT
14882018-06-18 Tom Tromey <tom@tromey.com>
1489
1490 * solib-aix.c (solib_aix_get_section_offsets): Return
1491 unique_xmalloc_ptr.
1492 (solib_aix_solib_create_inferior_hook): Update.
1493
668eb2f0
TT
14942018-06-18 Tom Tromey <tom@tromey.com>
1495
1496 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
1497
309822ca
TT
14982018-06-18 Tom Tromey <tom@tromey.com>
1499
1500 * solib-frv.c (frv_relocate_main_executable): Use
1501 unique_xmalloc_ptr.
1502 * solib-dsbt.c (dsbt_relocate_main_executable): Use
1503 unique_xmalloc_ptr.
1504
06424eac
TT
15052018-06-18 Tom Tromey <tom@tromey.com>
1506
1507 * objfiles.h (inhibit_section_map_updates): Update.
1508 (resume_section_map_updates, resume_section_map_updates_cleanup):
1509 Remove.
1510 * solib-svr4.c (svr4_handle_solib_event): Update.
1511 * objfiles.c (inhibit_section_map_updates): Return
1512 scoped_restore_tmpl<int>.
1513 (resume_section_map_updates, resume_section_map_updates_cleanup):
1514 Remove.
1515
b4be9fad
TT
15162018-06-18 Tom Tromey <tom@tromey.com>
1517
1518 * valprint.h (read_string): Update.
1519 * valprint.c (read_string): Change type of "buffer".
1520 (val_print_string): Update.
1521 * python/py-value.c (valpy_string): Update.
1522 * language.h (struct language_defn) <la_get_string>: Change
1523 type of "buffer".
1524 (default_get_string, c_get_string): Update.
1525 * language.c (default_get_string): Change type of "buffer".
1526 * guile/scm-value.c (gdbscm_value_to_string): Update.
1527 * c-lang.c (c_get_string): Change type of "buffer".
1528
3f0dbd67
TT
15292018-06-18 Tom Tromey <tom@tromey.com>
1530
1531 * ser-mingw.c (struct pipe_state_destroyer): New.
1532 (pipe_state_up): New typedef.
1533 (cleanup_pipe_state): Remove.
1534 (pipe_windows_open): Use pipe_state_up. Don't release argv.
1535
69d340c6
TT
15362018-06-18 Tom Tromey <tom@tromey.com>
1537
1538 * rust-lang.h (rust_yyerror): Don't declare.
1539 * rust-lang.c (rust_language_defn): Update.
1540 * rust-exp.y (yyerror): Now static.
1541 * parse.c (parse_exp_in_context_1): Update.
1542 * p-lang.h (p_yyerror): Don't declare.
1543 * p-lang.c (p_language_defn): Update.
1544 * p-exp.y (yyerror): Now static.
1545 * opencl-lang.c (opencl_language_defn): Update.
1546 * objc-lang.c (objc_language_defn): Update.
1547 * m2-lang.h (m2_yyerror): Don't declare.
1548 * m2-lang.c (m2_language_defn): Update.
1549 * m2-exp.y (yyerror): Now static.
1550 * language.h (struct language_defn) <la_error>: Remove.
1551 * language.c (unk_lang_error): Remove.
1552 (unknown_language_defn, auto_language_defn): Remove.
1553 * go-lang.h (go_yyerror): Don't declare.
1554 * go-lang.c (go_language_defn): Update.
1555 * go-exp.y (yyerror): Now static.
1556 * f-lang.h (f_yyerror): Don't declare.
1557 * f-lang.c (f_language_defn): Update.
1558 * f-exp.y (yyerror): Now static.
1559 * d-lang.h (d_yyerror): Don't declare.
1560 * d-lang.c (d_language_defn): Update.
1561 * d-exp.y (yyerror): Now static.
1562 * c-lang.h (c_yyerror): Don't declare.
1563 * c-lang.c (c_language_defn, cplus_language_defn)
1564 (asm_language_defn, minimal_language_defn): Update.
1565 * c-exp.y (yyerror): Now static.
1566 * ada-lang.h (ada_yyerror): Don't declare.
1567 * ada-lang.c (ada_language_defn): Update.
1568 * ada-exp.y (yyerror): Now static.
1569
e9902bfc
AH
15702018-06-18 Alan Hayward <alan.hayward@arm.com>
1571
1572 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
1573 (store_sveregs_to_thread): Likewise.
1574 (aarch64_linux_fetch_inferior_registers): Check for SVE.
1575 (aarch64_linux_store_inferior_registers): Likewise.
1576 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
1577 function.
1578 (aarch64_sve_regs_copy_to_regcache): Likewise.
1579 (aarch64_sve_regs_copy_from_regcache): Likewise.
1580 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
1581 declaration.
1582 (aarch64_sve_regs_copy_to_regcache): Likewise.
1583 (aarch64_sve_regs_copy_from_regcache): Likewise.
1584 (sve_context): Structure from Linux headers.
1585 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
1586 (SVE_SIG_ZREG_SIZE): Likewise.
1587 (SVE_SIG_PREG_SIZE): Likewise.
1588 (SVE_SIG_FFR_SIZE): Likewise.
1589 (SVE_SIG_REGS_OFFSET): Likewise.
1590 (SVE_SIG_ZREGS_OFFSET): Likewise.
1591 (SVE_SIG_ZREG_OFFSET): Likewise.
1592 (SVE_SIG_ZREGS_SIZE): Likewise.
1593 (SVE_SIG_PREGS_OFFSET): Likewise.
1594 (SVE_SIG_PREG_OFFSET): Likewise.
1595 (SVE_SIG_PREGS_SIZE): Likewise.
1596 (SVE_SIG_FFR_OFFSET): Likewise.
1597 (SVE_SIG_REGS_SIZE): Likewise.
1598 (SVE_SIG_CONTEXT_SIZE): Likewise.
1599 (SVE_PT_REGS_MASK): Likewise.
1600 (SVE_PT_REGS_FPSIMD): Likewise.
1601 (SVE_PT_REGS_SVE): Likewise.
1602 (SVE_PT_VL_INHERIT): Likewise.
1603 (SVE_PT_VL_ONEXEC): Likewise.
1604 (SVE_PT_REGS_OFFSET): Likewise.
1605 (SVE_PT_FPSIMD_OFFSET): Likewise.
1606 (SVE_PT_FPSIMD_SIZE): Likewise.
1607 (SVE_PT_SVE_ZREG_SIZE): Likewise.
1608 (SVE_PT_SVE_PREG_SIZE): Likewise.
1609 (SVE_PT_SVE_FFR_SIZE): Likewise.
1610 (SVE_PT_SVE_FPSR_SIZE): Likewise.
1611 (SVE_PT_SVE_FPCR_SIZE): Likewise.
1612 (__SVE_SIG_TO_PT): Likewise.
1613 (SVE_PT_SVE_OFFSET): Likewise.
1614 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
1615 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
1616 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
1617 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
1618 (SVE_PT_SVE_PREG_OFFSET): Likewise.
1619 (SVE_PT_SVE_PREGS_SIZE): Likewise.
1620 (SVE_PT_SVE_FFR_OFFSET): Likewise.
1621 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
1622 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
1623 (SVE_PT_SVE_SIZE): Likewise.
1624 (SVE_PT_SIZE): Likewise.
1625 (HAS_SVE_STATE): New define.
1626
17a1cc89
AH
16272018-06-18 Alan Hayward <alan.hayward@arm.com>
1628
1629 * nat/aarch64-sve-linux-sigcontext.h: New file.
1630 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
1631 new files.
1632 (SVE_VQ_MIN): Likewise.
1633 (SVE_VQ_MAX): Likewise.
1634 (SVE_VL_MIN): Likewise.
1635 (SVE_VL_MAX): Likewise.
1636 (SVE_NUM_ZREGS): Likewise.
1637 (SVE_NUM_PREGS): Likewise.
1638 (sve_vl_valid): Likewise.
1639 (struct user_sve_header): Likewise.
1640
7010835a
AB
16412018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
1642 Richard Bunt <Richard.Bunt@arm.com>
1643
1644 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
1645 was requested by GDB.
1646
479b3ef4
TV
16472018-06-15 Tom de Vries <tdevries@suse.de>
1648
1649 * MAINTAINERS (Write After Approval): Add Tom de Vries.
1650
8199b8f4
SM
16512018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
1652
1653 * gnulib/update-gnulib.sh: Print expected versions of
1654 autoconf/aclocal.
1655
55c748a1
SM
16562018-06-14 Simon Marchi <simon.marchi@ericsson.com>
1657
1658 * arch-utils.c (default_type_align): Use type_length_units.
1659 * gdbtypes.c (type_align): Use type_length_units.
1660
87a8eca7
PW
16612018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1662
1663 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
1664 of 'define' command.
1665
5d9a0608
TV
16662018-06-14 Tom de Vries <tdevries@suse.de>
1667
1668 PR cli/22573
1669 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
1670 get_no_prettyformat_print_options.
1671
ab89b5a5
SM
16722018-06-13 Simon Marchi <simon.marchi@ericsson.com>
1673
1674 * sparc-nat.h: Include target.h.
1675 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
1676 <fetch_registers>: Remove this argument in function call.
1677 <store_registers>: Remove this argument in function call, remove
1678 extra semicolon.
1679 <low_forget_process>: Call sparc64_forget_process instead of
1680 sparc_forget_process.
1681
62c808ae
RO
16822018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1683
1684 * procfs.c (_initialize_procfs): Use add_inf_child_target.
1685 (procfs_target::make_corefile_notes): Adjust to new
1686 target_read_alloc return type.
1687
1840d81a
AB
16882018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
1689 Stephen Roberts <stephen.roberts@arm.com>
1690
1691 PR gdb/22882
1692 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
1693 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
1694 Move should_notify_stop local into more inner scope.
1695
9516f85a
AB
16962018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
1697 Stephen Roberts <stephen.roberts@arm.com>
1698
1699 PR gdb/22882
1700 * infrun.c (resume_1): Add call to mark_async_event_handler.
1701
defd2172
AB
17022018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
1703
1704 * infrun.c (do_target_wait): Change old version of $pc printed.
1705
7b23e087
SM
17062018-06-11 Simon Marchi <simon.marchi@ericsson.com>
1707
1708 * dwarf2read.c (read_index_from_section): Rename to...
1709 (read_gdb_index_from_section): ... this, update all callers.
1710 (dwarf2_read_index): Rename to...
1711 (dwarf2_read_gdb_index): ... this, update all callers.
1712
69c67a0b
JDA
17132018-06-11 John David Anglin <danglin@gcc.gnu.org>
1714
1715 * gdb/hppa-linux-nat.c
1716 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
1717 hppa_linux_nat_target::fetch_registers.
1718
65d4cada
AH
17192018-06-11 Alan Hayward <alan.hayward@arm.com>
1720
1721 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
1722 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
1723 (AARCH64_DWARF_SVE_FFR): Likewise.
1724 (AARCH64_DWARF_SVE_P0): Likewise.
1725 (AARCH64_DWARF_SVE_Z0): Likewise.
1726
f868386e
AH
17272018-06-11 Alan Hayward <alan.hayward@arm.com>
1728
1729 * common/common-regcache.h (raw_compare): New function.
1730 * regcache.c (regcache::raw_compare): Likewise.
1731 * regcache.h (regcache::raw_compare): New declaration.
1732
9c861883
AH
17332018-06-11 Alan Hayward <alan.hayward@arm.com>
1734
1735 * common/common-regcache.h (reg_buffer_common): New structure.
1736 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
1737 (reg_buffer::raw_supply): Likewise.
1738 (reg_buffer::raw_supply_integer): Likewise.
1739 (reg_buffer::raw_supply_zeroed): Likewise.
1740 (reg_buffer::raw_collect): Likewise.
1741 (reg_buffer::raw_collect_integer): Likewise.
1742 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
1743 (reg_buffer::raw_supply): Likewise.
1744 (reg_buffer::raw_supply_integer): Likewise.
1745 (reg_buffer::raw_supply_zeroed): Likewise.
1746 (reg_buffer::raw_collect): Likewise.
1747 (reg_buffer::raw_collect_integer): Likewise.
1748
953edf2b
TT
17492018-06-10 Tom Tromey <tom@tromey.com>
1750
1751 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
1752 (class remote_state) <stop_reply_queue>: Now std::vector.
1753 (remote_state::~remote_state)
1754 (remote_target::stop_reply_queue_length): Update.
1755 (struct queue_iter_param, remove_child_of_pending_fork)
1756 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
1757 (check_pending_event_prevents_wildcard_vcont_callback)
1758 (remove_stop_reply_for_inferior)
1759 (remove_stop_reply_of_remote_state)
1760 (remote_notif_remove_once_on_match)
1761 (stop_reply_match_ptid_and_ws)
1762 (remote_kill_child_of_pending_fork): Remove.
1763 (remote_target::remove_new_fork_children)
1764 (remote_target::check_pending_events_prevent_wildcard_vcont)
1765 (remote_target::discard_pending_stop_replies)
1766 (remote_target::discard_pending_stop_replies_in_queue)
1767 (remote_target::remote_notif_remove_queued_reply)
1768 (remote_target::queued_stop_reply)
1769 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
1770 (remote_target::wait, remote_target::kill_new_fork_children)
1771 (remote_target::async): Update.
1772
1ddbba9d
TT
17732018-06-10 Tom Tromey <tom@tromey.com>
1774
1775 * record-full.c (record_full_arch_list_cleanups): Remove.
1776 (record_full_message): Use try/catch.
1777 (record_full_wait_cleanups): Remove.
1778 (record_full_wait_1): Use try/catch.
1779 (record_full_restore): Likewise.
1780
219605fd
TT
17812018-06-10 Tom Tromey <tom@tromey.com>
1782
1783 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
1784 declare VEC. Add constructor.
1785 <in_target_beneath>: Now bool.
1786 (record_full_breakpoints): Now a std::vector, static.
1787 (record_full_sync_record_breakpoints)
1788 (record_full_init_record_breakpoints)
1789 (record_full_target::insert_breakpoint)
1790 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
1791
71b73764
SM
17922018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
1793
1794 * dwarf2read.c (process_cu_includes): Remove struct keyword.
1795 * serial.c (serial_interface_lookup): Remove struct keyword.
1796
4360561f
TT
17972018-06-10 Tom Tromey <tom@tromey.com>
1798
1799 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
1800 method.
1801 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
1802 a method.
1803 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
1804 method.
1805 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
1806 "beneath" as a method.
1807 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
1808 Use "beneath" as a method.
1809
d14b92bf
TT
18102018-06-10 Tom Tromey <tom@tromey.com>
1811
1812 * tracefile.c (struct trace_file_writer_deleter): New.
1813 <operator()>: Rename from trace_file_writer_xfree.
1814 (trace_file_writer_up): New typedef.
1815 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
1816
835dcf92
SM
18172018-06-09 Simon Marchi <simon.marchi@ericsson.com>
1818
1819 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
1820 <m_registers, m_register_status>: Change type to
1821 std::unique_ptr.
1822 * regcache.c (reg_buffer::reg_buffer): Use new instead of
1823 XCNEWVEC.
1824
aac0d564
SM
18252018-06-09 Simon Marchi <simon.marchi@ericsson.com>
1826
1827 * common/common-regcache.h (enum register_status): Add
1828 underlying type "signed char".
1829 * regcache.h (reg_buffer) <m_register_status>: Change type to
1830 register_status *.
1831 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
1832 register_status instead of signed char.
1833 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
1834 (reg_buffer::get_register_status): Remove cast.
1835 (readable_regcache::raw_read): Remove cast.
1836 (readable_regcache::cooked_read): Remove cast.
1837
77ad7394
TT
18382018-06-09 Tom Tromey <tom@tromey.com>
1839
1840 * source.c (reverse_search_command, forward_search_command): Use
1841 scoped_fd.
1842
191cca63
TT
18432018-06-09 Tom Tromey <tom@tromey.com>
1844
1845 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
1846 (serial_ops_list): Now static, std::vector.
1847 (serial_interface_lookup, serial_add_interface): Update.
1848
c5d0225d
TT
18492018-06-09 Tom Tromey <tom@tromey.com>
1850
1851 * dwarf2read.c (process_cu_includes): Update.
1852 (process_full_comp_unit): Update.
1853 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
1854 std::vector.
1855
aeab5128
PK
18562018-06-08 Paul Koning <paul_koning@dell.com>
1857
1858 PR gdb/23252
1859
1860 * python/python.c (do_start_initialization):
1861 Avoid call to internal Python API.
1862 (init__gdb_module): New function.
1863
5045b3d7
GB
18642018-06-08 Gary Benson <gbenson@redhat.com>
1865
1866 * linux-thread-db.c (valprint.h): New include.
1867 (struct check_thread_db_info): New structure.
1868 (check_thread_db_on_load, tdb_testinfo): New static globals.
1869 (check_thread_db, check_thread_db_callback): New functions.
1870 (try_thread_db_load_1): Run integrity checks if requested.
1871 (maintenance_check_libthread_db): New function.
1872 (_initialize_thread_db): Register "maint check libthread-db"
1873 and "maint set/show check-libthread-db".
1874 * NEWS: Mention the above new commands.
1875
2f4f025f
TT
18762018-06-08 Tom Tromey <tom@tromey.com>
1877
1878 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
1879 now a method.
1880
343b0027
TT
18812018-06-08 Tom Tromey <tom@tromey.com>
1882
1883 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
1884
8dcc53b3
TT
18852018-06-08 Tom Tromey <tom@tromey.com>
1886
1887 * common/btrace-common.h (struct btrace_data): Add constructor,
1888 destructor, move assignment operator.
1889 <empty, clear, fini>: New methods.
1890 <format>: Initialize.
1891 (btrace_data_init, btrace_data_fini, btrace_data_clear)
1892 (btrace_data_empty): Don't declare.
1893 * common/btrace-common.c (btrace_data_init): Remove.
1894 (btrace_data::fini): Rename from btrace_data_fini.
1895 (btrace_data::empty): Rename from btrace_data_empty.
1896 (btrace_data::clear): Rename from btrace_data_clear. Return
1897 bool.
1898 * btrace.h (make_cleanup_btrace_data): Don't declare.
1899 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
1900 (parse_xml_btrace): Update.
1901 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
1902 (maint_btrace_clear_packet_history_cmd): Update.
1903
a1740ee1
PA
19042018-06-07 Pedro Alves <palves@redhat.com>
1905
1906 * target.h (target_ops) <beneath>: Now a method. All references
1907 updated.
1908 (class target_stack): New.
1909 * target.c (g_target_stack): New.
1910 (g_current_top_target): Delete.
1911 (current_top_target): Get the top target out of g_target_stack.
1912 (target_stack::push, target_stack::unpush): New.
1913 (push_target, unpush_target): Reimplement.
1914 (target_is_pushed): Reimplement in terms of g_target_stack.
1915 (target_ops::beneath, target_stack::find_beneath): New.
1916
d6ca69cd
PA
19172018-06-07 Pedro Alves <palves@redhat.com>
1918
1919 * target.h (find_target_beneath): Delete declaration.
1920 * target.c (find_target_beneath): Delete definition.
1921 * aix-thread.c: All callers of find_target_beneath adjusted to
1922 call target_ops::beneath instead.
1923 * bsd-uthread.c: Likewise.
1924 * linux-thread-db.c: Likewise.
1925 * ravenscar-thread.c: Likewise.
1926 * sol-thread.c: Likewise.
1927 * spu-multiarch.c: Likewise.
1928
b6a8c27b
PA
19292018-06-07 Pedro Alves <palves@redhat.com>
1930
1931 * target.h (target_ops) <beneath>: Now a method. All references
1932 updated.
1933 (target_ops) <m_beneath>: New.
1934 * target.c (target_ops::beneath): New.
1935 * corelow.c: Adjust all references to target_ops::beneath.
1936 * linux-thread-db.c: Likewise.
1937 * make-target-delegates: Likewise.
1938 * record-btrace.c: Likewise.
1939 * record-full.c: Likewise.
1940 * remote.c: Likewise.
1941 * target.c: Likewise.
1942 * target-delegates.c: Regenerate.
1943
8b88a78e
PA
19442018-06-07 Pedro Alves <palves@redhat.com>
1945
1946 * target.h (target_stack): Delete.
1947 (current_top_target): Declare function.
1948 * target.c (target_stack): Delete.
1949 (g_current_top_target): New.
1950 (current_top_target): New function.
1951 * auxv.c: Use current_top_target instead of target_stack
1952 throughout.
1953 * avr-tdep.c: Likewise.
1954 * breakpoint.c: Likewise.
1955 * corefile.c: Likewise.
1956 * elfread.c: Likewise.
1957 * eval.c: Likewise.
1958 * exceptions.c: Likewise.
1959 * frame.c: Likewise.
1960 * gdbarch-selftests.c: Likewise.
1961 * gnu-v3-abi.c: Likewise.
1962 * ia64-tdep.c: Likewise.
1963 * ia64-vms-tdep.c: Likewise.
1964 * infcall.c: Likewise.
1965 * infcmd.c: Likewise.
1966 * infrun.c: Likewise.
1967 * linespec.c: Likewise.
1968 * linux-tdep.c: Likewise.
1969 * minsyms.c: Likewise.
1970 * ppc-linux-nat.c: Likewise.
1971 * ppc-linux-tdep.c: Likewise.
1972 * procfs.c: Likewise.
1973 * regcache.c: Likewise.
1974 * remote.c: Likewise.
1975 * rs6000-tdep.c: Likewise.
1976 * s390-linux-nat.c: Likewise.
1977 * s390-tdep.c: Likewise.
1978 * solib-aix.c: Likewise.
1979 * solib-darwin.c: Likewise.
1980 * solib-dsbt.c: Likewise.
1981 * solib-spu.c: Likewise.
1982 * solib-svr4.c: Likewise.
1983 * solib-target.c: Likewise.
1984 * sparc-tdep.c: Likewise.
1985 * sparc64-tdep.c: Likewise.
1986 * spu-tdep.c: Likewise.
1987 * symfile.c: Likewise.
1988 * symtab.c: Likewise.
1989 * target-descriptions.c: Likewise.
1990 * target-memory.c: Likewise.
1991 * target.c: Likewise.
1992 * target.h: Likewise.
1993 * tracefile-tfile.c: Likewise.
1994 * tracepoint.c: Likewise.
1995 * valops.c: Likewise.
1996 * valprint.c: Likewise.
1997 * value.c: Likewise.
1998 * windows-tdep.c: Likewise.
1999 * mi/mi-main.c: Likewise.
2000
c7110220
TT
20012018-06-07 Tom Tromey <tom@tromey.com>
2002
2003 * valprint.h (build_address_symbolic): Declare.
2004 * printcmd.c (print_address_symbolic): Update.
2005 (build_address_symbolic): Change "name" and "filename" to
2006 std::string.
2007 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
2008 Update.
2009 * defs.h (build_address_symbolic): Remove declaration.
2010
63bad7b6
AH
20112018-06-07 Alan Hayward <alan.hayward@arm.com>
2012
2013 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
2014 (aarch64_vnv_type): Add function.
2015 (aarch64_pseudo_register_name): Add V regs for SVE.
2016 (aarch64_pseudo_register_type): Likewise.
2017 (aarch64_pseudo_register_reggroup_p): Likewise.
2018 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
2019 (aarch64_pseudo_read_value): Add V regs for SVE.
2020 (aarch64_pseudo_write_2): Use V0 offset for SVE
2021 (aarch64_pseudo_write): Add V regs for SVE.
2022 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
2023
13e3c608
SDJ
20242018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
2025
2026 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
2027 (sve_vl_from_vq): Likewise.
2028
c61b06a1
TT
20292018-06-05 Tom Tromey <tom@tromey.com>
2030
2031 * cli/cli-cmds.c (show_version): Update.
2032 * top.c (print_gdb_version): Add "interactive" parameter.
2033 Update.
2034 * main.c (captured_main_1): Update.
2035 * top.h (print_gdb_version): Add "interactive" parameter and a
2036 comment.
2037
115f7325
DM
20382018-06-05 David Malcolm <dmalcolm@redhat.com>
2039
2040 * common/enum-flags.h: Add trailing semicolon to example in
2041 comment.
2042
eb6af809
TT
20432018-06-05 Tom Tromey <tom@tromey.com>
2044
2045 PR cli/12326:
2046 * NEWS: Add entry about pager.
2047 * utils.c (pagination_disabled_for_command): New global.
2048 (prompt_for_continue): Allow "c" response to prompt.
2049 (reinitialize_more_filter): Clear
2050 pagination_disabled_for_command.
2051 (fputs_maybe_filtered): Check pagination_disabled_for_command.
2052
54d343a2
TT
20532018-06-04 Tom Tromey <tom@tromey.com>
2054
2055 * ada-lang.h (ada_lookup_symbol_list): Update.
2056 * ada-lang.c (resolve_subexp): Update.
2057 (symbols_are_identical_enums): Change type of syms. Remove nsyms
2058 parameter.
2059 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
2060 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
2061 results parameter to std::vector.
2062 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
2063 Update.
2064 * ada-exp.y (block_lookup): Update.
2065 (select_possible_type_sym): Change type of syms. Remove nsyms
2066 parameter.
2067 (write_var_or_type, write_name_assoc): Update.
2068
178d6a63
JB
20692018-06-04 Joel Brobecker <brobecker@adacore.com>
2070
2071 * windows-nat.c (windows_nat_target::xfer_partial): Return
2072 TARGET_XFER_E_IO if we need to delegate to the target beneath
2073 but BENEATH is NULL.
2074
baf00c2d
SM
20752018-06-04 Simon Marchi <simon.marchi@ericsson.com>
2076
2077 * Makefile.in (config.status): Add configure.nat as a
2078 dependency.
2079
214b073c
TT
20802018-06-04 Tom Tromey <tom@tromey.com>
2081
2082 * cp-name-parser.y (cpname_state): Add method declarations.
2083 (HANDLE_QUAL): Update.
2084 (cpname_state::d_grab, cpname_state::fill_comp)
2085 (cpname_state::make_operator, cpname_state::make_dtor)
2086 (cpname_state::make_builtin_type, cpname_state::make_name)
2087 (cpname_state::d_qualify, cpname_state::d_int_type)
2088 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
2089 (%union): Move earlier.
2090
62b74cb8
AH
20912018-06-04 Alan Hayward <alan.hayward@arm.com>
2092
2093 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
2094
3c5cd5c3
AH
20952018-06-04 Alan Hayward <alan.hayward@arm.com>
2096
2097 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
2098 (aarch64_pseudo_write_1): Likewise.
2099 (aarch64_pseudo_read_value): Use helper.
2100 (aarch64_pseudo_write): Likewise.
2101
59f413d5
PA
21022018-06-04 Pedro Alves <palves@redhat.com>
2103
2104 * darwin-nat.c (darwin_ops): Delete.
2105 (darwin_attach_pid): Use get_native_target.
2106
1332a140
AH
21072018-06-04 Alan Hayward <alan.hayward@arm.com>
2108
2109 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
2110 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
2111
ba2d2bb2
AH
21122018-06-04 Alan Hayward <alan.hayward@arm.com>
2113
2114 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
2115 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
2116 (aarch64_gdbarch_init): Check for SVE.
2117 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
2118
21192018-06-04 Alan Hayward <alan.hayward@arm.com>
39bfb937
AH
2120
2121 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
2122 * aarch64-tdep.h (aarch64_read_description): Likewise.
2123 * arch/aarch64.c (aarch64_create_target_description): Likewise.
2124 * arch/aarch64.h (aarch64_create_target_description): Likewise.
2125 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
2126 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
2127 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
2128
41c60b4b
SM
21292018-06-02 Simon Marchi <simon.marchi@ericsson.com>
2130
2131 * value.c (value_fetch_lazy_bitfield): New.
2132 (value_fetch_lazy_memory): New.
2133 (value_fetch_lazy_register): New.
2134 (value_fetch_lazy): Factor out to smaller functions.
2135
7b640f72
TT
21362018-06-01 Tom Tromey <tom@tromey.com>
2137
2138 * cp-name-parser.y (backslashable, represented): Now const.
2139
98e69eb3
TT
21402018-06-01 Tom Tromey <tom@tromey.com>
2141
2142 * cp-name-parser.y: Include parser-defs.h.
2143 (parser_fprintf): Remove declaration.
2144
49265499
TT
21452018-06-01 Tom Tromey <tom@tromey.com>
2146
2147 * cp-name-parser.y: Use %pure-parser, %lex-param, and
2148 %parse-param.
2149 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
2150 (global_result): Remove globals.
2151 (struct cpname_state): New.
2152 (yyparse): Don't declare.
2153 (yylex, yyerror): Move declarations after %union.
2154 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
2155 (make_name): Add state parameter.
2156 Update all callers.
2157 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
2158 parameter.
2159 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
2160 Update.
2161 (yylex): Add lvalp, state parameters.
2162 (yyerror): Add state parameter.
2163 (cp_demangled_name_to_comp): Update.
2164
55b6c984
TT
21652018-06-01 Tom Tromey <tom@tromey.com>
2166
2167 * cp-name-parser.y (parser_fprintf): Declare.
2168 (GDB_YY_REMAP_PREFIX): Define.
2169 Include yy-remap.h. Don't redefine yy* identifiers.
2170
3513a6bb
TT
21712018-06-01 Tom Tromey <tom@tromey.com>
2172
2173 * python/py-type.c (typy_legacy_template_argument): Update.
2174 * cp-support.h (cp_demangled_name_to_comp): Update.
2175 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
2176 parameter to be a "std::string *".
2177 (main): Update.
2178
e9cb46ab
L
21792018-06-01 H.J. Lu <hongjiu.lu@intel.com>
2180
2181 * ada-lex.l: Include "diagnostics.h" instead of
2182 "common/diagnostics.h".
2183 * unittests/environ-selftests.c: Likewise.
2184 * common/diagnostics.h: Moved to ../include.
2185
8e817061
JB
21862018-06-01 Joel Brobecker <brobecker@adacore.com>
2187
2188 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
2189 to language_mode_manual while calling breakpoint_re_set_one.
2190
a737d952
TT
21912018-06-01 Tom Tromey <tom@tromey.com>
2192
2193 * valops.c (value_cast_structs, destructor_name_p): Update.
2194 * symtab.c (gdb_mangle_name): Update.
2195 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
2196 Update.
2197 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
2198 (pascal_object_print_value_fields, pascal_object_print_value):
2199 Update.
2200 * p-typeprint.c (pascal_type_print_derivation_info): Update.
2201 * linespec.c (find_methods): Update.
2202 * gdbtypes.h (type_name_no_tag): Remove.
2203 (type_name_or_error): Rename from type_name_no_tag_or_error.
2204 * gdbtypes.c (type_name_no_tag): Remove.
2205 (type_name_or_error): Rename from type_name_no_tag_or_error.
2206 (lookup_struct_elt_type, check_typedef): Update.
2207 * expprint.c (print_subexp_standard): Update.
2208 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
2209 * d-namespace.c (d_lookup_nested_symbol): Update.
2210 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
2211 (cp_print_class_member): Update.
2212 * cp-namespace.c (cp_lookup_nested_symbol): Update.
2213 * completer.c (add_struct_fields): Update.
2214 * c-typeprint.c (cp_type_print_derivation_info)
2215 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
2216 Update.
2217 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
2218 (ada_prefer_type, ada_is_exception_sym): Update.
2219
e86ca25f
TT
22202018-06-01 Tom Tromey <tom@tromey.com>
2221
2222 * valops.c (enum_constant_from_type, value_namespace_elt)
2223 (value_maybe_namespace_elt): Update.
2224 * valarith.c (find_size_for_pointer_math): Update.
2225 * target-descriptions.c (make_gdb_type): Update.
2226 * symmisc.c (print_symbol): Update.
2227 * stabsread.c (define_symbol, read_type)
2228 (complain_about_struct_wipeout, add_undefined_type)
2229 (cleanup_undefined_types_1): Update.
2230 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
2231 (rust_range_type_p, val_print_struct, rust_print_struct_def)
2232 (rust_internal_print_type, rust_composite_type)
2233 (rust_evaluate_funcall, rust_evaluate_subexp)
2234 (rust_inclusive_range_type_p): Update.
2235 * python/py-type.c (typy_get_tag): Update.
2236 * p-typeprint.c (pascal_type_print_base): Update.
2237 * mdebugread.c (parse_symbol, parse_type): Update.
2238 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
2239 Update.
2240 * guile/scm-type.c (gdbscm_type_tag): Update.
2241 * go-lang.c (sixg_string_p): Update.
2242 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
2243 Update.
2244 * gdbtypes.h (struct main_type) <tag_name>: Remove.
2245 (TYPE_TAG_NAME): Remove.
2246 * gdbtypes.c (type_name_no_tag): Simplify.
2247 (check_typedef, check_types_equal, recursive_dump_type)
2248 (copy_type_recursive, arch_composite_type): Update.
2249 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
2250 in summary mode when needed.
2251 * eval.c (evaluate_funcall): Update.
2252 * dwarf2read.c (fixup_go_packaging, read_structure_type)
2253 (process_structure_scope, read_enumeration_type)
2254 (read_namespace_type, read_module_type, determine_prefix): Update.
2255 * cp-support.c (inspect_type): Update.
2256 * coffread.c (process_coff_symbol, decode_base_type): Update.
2257 * c-varobj.c (c_is_path_expr_parent): Update.
2258 * c-typeprint.c (c_type_print_base_struct_union): Update.
2259 (c_type_print_base_1): Update. Print struct/class/union/enum in
2260 summary when using C language.
2261 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
2262 (gen_maybe_namespace_elt): Update.
2263 * ada-lang.c (ada_type_name): Simplify.
2264 (empty_record, ada_template_to_fixed_record_type_1)
2265 (template_to_static_fixed_type)
2266 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
2267
c1ec8cea
TT
22682018-06-01 Tom Tromey <tom@tromey.com>
2269
2270 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
2271 c_print_type.
2272 * c-typeprint.c (c_print_type_1): Add "language" parameter.
2273 (c_print_type): Update.
2274 (c_print_type): New overload.
2275 (c_type_print_varspec_prefix, c_type_print_args)
2276 (c_type_print_varspec_suffix, c_print_type_no_offsets)
2277 (c_type_print_base_struct_union, c_type_print_base_1)
2278 (cp_type_print_method_args): Add "language" parameter.
2279 (c_type_print_base): Update.
2280 * c-lang.h (c_print_type): Add new overload.
2281
bc8453a7
TT
22822018-06-01 Tom Tromey <tom@tromey.com>
2283
2284 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
2285 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
2286
739e8682
AH
22872018-06-01 Alan Hayward <alan.hayward@arm.com>
2288
2289 * aarch64-tdep.c (aarch64_sve_register_names): New const
2290 var.
2291 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
2292 (AARCH64_SVE_Z_REGS_NUM): New define.
2293 (AARCH64_SVE_P_REGS_NUM): Likewise.
2294 (AARCH64_SVE_NUM_REGS): Likewise.
2295
8a60efe7
UB
22962018-05-31 Uros Bizjak <ubizjak@gmail.com>
2297
2298 * nat/linux-ptrace.h [__alpha__]
2299 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
2300 definitions.
2301
4b2dfa9d
MR
23022018-05-31 Maciej W. Rozycki <macro@mips.com>
2303
2304 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
2305 the endianness selected.
2306 * NEWS: Document `set endian auto' mode operation update.
2307
122394f1
AH
23082018-05-31 Alan Hayward <alan.hayward@arm.com>
2309
2310 * Makefile.in: Add new header.
2311 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
2312 (sve_vl_from_vg): Likewise.
2313 (sve_vq_from_vl): Likewise.
2314 (sve_vl_from_vq): Likewise.
2315 (sve_vq_from_vg): Likewise.
2316 (sve_vg_from_vq): Likewise.
2317 * configure.nat: Add new c file.
2318 * nat/aarch64-sve-linux-ptrace.c: New file.
2319 * nat/aarch64-sve-linux-ptrace.h: New file.
2320
95228a0d
AH
23212018-05-31 Alan Hayward <alan.hayward@arm.com>
2322
2323 * aarch64-linux-nat.c (aarch64_linux_read_description):
2324 Add parmeter zero.
2325 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
2326 Likewise.
2327 * aarch64-tdep.c (tdesc_aarch64_list): Add.
2328 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
2329 (aarch64_gdbarch_init): Add parmeter zero.
2330 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
2331 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
2332 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
2333 parmeter.
2334 * doc/gdb.texinfo: Describe SVE feature
2335 * features/aarch64-sve.c: New file.
2336
5969f0db
OJ
23372018-05-31 Omair Javaid <omair.javaid@linaro.org>
2338
2339 PR gdb/23210
2340 * gdbarch.sh (significant_addr_bit): Default to zero when
2341 not set by target architecture.
2342 * gdbarch.c: Re-generated.
2343 * utils.c (address_significant): Update.
2344
61367c61
JB
23452018-05-30 Joel Brobecker <brobecker@adacore.com>
2346
2347 * stack.c (func_command): Remove trailing newline in call to error.
2348
34a79281
SM
23492018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2350
2351 * regcache.h (regcache_raw_collect): Remove, update callers to
2352 use regcache::raw_collect.
2353 * regcache.c (regcache_raw_collect): Remove.
2354
73e1c03f
SM
23552018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2356
2357 * regcache.h (regcache_raw_supply): Remove, update callers to
2358 use detached_regcache::raw_supply.
2359 * regcache.c (regcache_raw_supply): Remove.
2360
e4c4a59b
SM
23612018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2362
2363 * regcache.h (regcache_cooked_write_part): Remove, update
2364 callers to use regcache::cooked_write_part.
2365 * regcache.c (regcache_cooked_write_part): Remove.
2366
73bb0000
SM
23672018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2368
2369 * regcache.h (regcache_cooked_read_part): Remove, update callers
2370 to use readable_regcache::cooked_read_part.
2371 * regcache.c (regcache_cooked_read_part): Remove.
2372
46a45e9d
SM
23732018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2374
2375 * regcache.h (regcache_cooked_read_value): Remove, update
2376 callers to use readable_regcache::cooked_read_value.
2377 * regcache.c (regcache_cooked_read_value): Remove.
2378
b66f5587
SM
23792018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2380
2381 * regcache.h (regcache_cooked_write): Remove, update callers to
2382 use regcache::cooked_write.
2383 * regcache.c (regcache_cooked_write): Remove.
2384
6aa7d724
SM
23852018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2386
2387 * regcache.h (regcache_invalidate): Remove, update callers to
2388 use detached_regcache::invalidate instead.
2389 * regcache.c (regcache_invalidate): Remove.
2390
4f0420fd
SM
23912018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2392
2393 * regcache.h (regcache_raw_write_part): Remove, update callers
2394 to use regcache::raw_write_part instead.
2395 * regcache.c (regcache_raw_write_part): Remove.
2396
502fe83e
SM
23972018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2398
2399 * regcache.h (regcache_raw_read_part): Remove, update callers to
2400 use readable_regcache::raw_read_part instead.
2401 * regcache.c (regcache_raw_read_part): Remove.
2402
dca08e1f
SM
24032018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2404
2405 * regcache.h (regcache_cooked_read): Remove, update callers to
2406 use readable_regcache::cooked_read instead.
2407 * regcache.c (regcache_cooked_read): Remove.
2408
10eaee5f
SM
24092018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2410
2411 * regcache.h (regcache_raw_write): Remove, update callers to use
2412 regcache::raw_write instead.
2413 * regcache.c (regcache_raw_write): Remove.
2414
0b883586
SM
24152018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2416
2417 * regcache.h (regcache_raw_read): Remove, update callers to use
2418 readable_regcache::raw_read instead.
2419 * regcache.c (regcache_raw_read): Remove.
2420
0b47d985
SM
24212018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2422
2423 * regcache.h (regcache_raw_update): Remove, update callers to
2424 use readable_regcache::raw_update instead.
2425 * regcache.c (regcache_raw_update): Remove.
2426
0ec9f114
SM
24272018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2428
2429 * regcache.h (regcache_register_status): Remove, update callers
2430 to use reg_buffer::get_register_status directly instead.
2431 * regcache.c (regcache_register_status): Remove.
2432
222312d3
SM
24332018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2434
2435 * regcache.h (regcache_get_ptid): Remove, update all callers to
2436 call regcache::ptid instead.
2437 * regcache.c (regcache_get_ptid): Remove.
2438
fdbe37e3
SM
24392018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2440
2441 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
2442
f7c6f423
PA
24432018-05-30 Pedro Alves <palves@redhat.com>
2444
2445 * common/common-exceptions.h (exception_rethrow): Use
2446 ATTRIBUTE_NORETURN.
2447
52941706
SM
24482018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
2449
2450 * breakpoint.c (print_solib_event, check_status_catch_solib):
2451 Remove struct keyword in range-based for loops.
2452 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
2453 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
2454 Likewise.
2455 * linespec.c (find_superclass_methods, search_minsyms_for_name):
2456 Likewise.
2457 * symfile.c (addr_info_make_relative): Likewise.
2458 * thread.c (value_in_thread_stack_temporaries): Likewise.
2459
bf2977b5
WP
24602018-06-12 Weimin Pan <weimin.pan@oracle.com>
2461
2462 PR gdb/16841
2463 * valops.c (value_struct_elt_for_reference): Call check_typedef on
2464 aggregate type to get its real type before accessing it.
2465
64cc34d8
WP
24662018-05-29 Weimin Pan <weimin.pan@oracle.com>
2467
2468 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
2469 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
2470 * coff-pe-read.c (add_pe_forwarded_sym): Replace
2471 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
2472 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
2473 * jit.c (jit_breakpoint_re_set_internal): Likewise.
2474 * printcmd.c (info_address_command): Likewise.
2475
e7ec8713
TT
24762018-05-29 Tom Tromey <tom@tromey.com>
2477
2478 * windows-nat.c (handle_exception): Update fall-through comment.
2479
bcb430e4
TT
24802018-05-29 Tom Tromey <tom@tromey.com>
2481
2482 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
2483 (struct program_space) <added_solibs>: Now a std::vector.
2484 * breakpoint.c (print_solib_event): Update.
2485 (check_status_catch_solib): Update.
2486 * progspace.c (clear_program_space_solib_cache): Update.
2487 * solib.c (update_solib_list): Update.
2488
894882e3
TT
24892018-05-29 Tom Tromey <tom@tromey.com>
2490
2491 * python/py-type.c (typy_richcompare): Update.
2492 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
2493 * gdbtypes.h (types_deeply_equal): Return bool.
2494 (types_equal): Likewise.
2495 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
2496 declare VEC.
2497 (check_types_equal): Change worklist to std::vector. Return
2498 bool.
2499 (struct type_equality_entry): Add constructor.
2500 (compare_maybe_null_strings): Return bool.
2501 (check_types_worklist): Return bool. Change worklist to
2502 std::vector.
2503 (types_deeply_equal): Use std::vector.
2504 (types_equal): Return bool.
2505 (compare_maybe_null_strings): Simplify.
2506
10b2ded4
TT
25072018-05-29 Tom Tromey <tom@tromey.com>
2508
2509 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
2510
4f7deebe
TT
25112018-05-29 Tom Tromey <tom@tromey.com>
2512
2513 * objc-lang.h: Don't include cp-support.h.
2514 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
2515 declare VEC.
2516
b8283aea
TT
25172018-05-27 Tom Tromey <tom@tromey.com>
2518
2519 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
2520
41a883c8
TT
25212018-05-25 Tom Tromey <tom@tromey.com>
2522
2523 * value.c (value::location): Initialize.
2524
bf259e25
TT
25252018-05-25 Tom Tromey <tom@tromey.com>
2526
2527 * dbxread.c (init_bincl_list): Remove.
2528 (bincl_list): Now a std::vector.
2529 (bincls_allocated, next_bincl): Remove.
2530 (free_bincl_list, do_free_bincl_list_cleanup)
2531 (make_cleanup_free_bincl_list): Remove.
2532 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
2533 unique_xmalloc_ptr.
2534 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
2535 (struct header_file_location): Add constructor.
2536 (add_bincl_to_list): Remove.
2537
d525a99b
TT
25382018-05-25 Tom Tromey <tom@tromey.com>
2539
2540 * tui/tui.c (tui_enable): Update.
2541 * mi/mi-interp.c (mi_interp::init): Update.
2542 * interps.h (class interp) <name>: New method.
2543 <m_name>: Rename from name.
2544 (~scoped_restore_interp): Update.
2545 * interps.c (interp::interp): Update.
2546 (interp_add, interp_set, interp_lookup_existing)
2547 (current_interp_named_p): Update.
2548
da505cff
TT
25492018-05-25 Tom Tromey <tom@tromey.com>
2550
2551 * interps.c (interp_name): Remove.
2552 * mi/mi-interp.c (mi_interp::init): Update.
2553 * interps.h (interp_name): Remove.
2554 (~scoped_restore_interp): Update.
2555 * tui/tui.c (tui_enable): Update.
2556
29f94340
TT
25572018-05-25 Tom Tromey <tom@tromey.com>
2558
2559 * utils.c (fputs_maybe_filtered): Update.
2560 * linespec.c (decode_line_full): Update.
2561 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
2562 (mi_print_breakpoint_for_event, mi_solib_loaded)
2563 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
2564 (mi_user_selected_context_changed): Update.
2565 * mi/mi-main.c (mi_execute_command): Update.
2566 * cli/cli-script.c (execute_control_command): Update.
2567 * python/python.c (execute_gdb_command): Update.
2568 * solib.c (info_sharedlibrary_command): Update.
2569 * interps.c (interp_ui_out): Remove.
2570 * interps.h (interp_ui_out): Remove.
2571
716b8bc5
TT
25722018-05-25 Tom Tromey <tom@tromey.com>
2573
2574 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
2575 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
2576 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
2577
753ff9bd
TT
25782018-05-25 Tom Tromey <tom@tromey.com>
2579
2580 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
2581 * interps.c (interp_exec): Use scoped_restore.
2582
5ca3b260
TT
25832018-05-25 Tom Tromey <tom@tromey.com>
2584
2585 * remote.c (remote_target::remote_file_get): Use
2586 gdb::byte_vector.
2587 (remote_target::remote_file_put): Likewise.
2588
3173aa2f
TT
25892018-05-25 Tom Tromey <tom@tromey.com>
2590
2591 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
2592 a std::string.
2593 (get_pe_section_index, add_pe_exported_sym): Update.
2594 (read_pe_exported_syms): Use gdb::def_vector.
2595
09a5e1b5
TT
25962018-05-25 Tom Tromey <tom@tromey.com>
2597
2598 * frame.c (remove_prev_frame): Remove.
2599 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
2600
d8dab6c3
MR
26012018-05-25 Maciej W. Rozycki <macro@mips.com>
2602
2603 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
2604 Remove prototypes.
2605 * mips-linux-nat.c (supply_fpregset): Always call
2606 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
2607 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
2608 `mips_fill_fpregset'.
2609 * mips-linux-tdep.c (mips_supply_fpregset)
2610 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
2611 (mips_fill_fpregset_wrapper): Remove functions.
2612 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
2613 (mips_linux_fpregset): Remove variable.
2614 (mips_linux_iterate_over_regset_sections): Use
2615 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
2616 (mips_linux_o32_sigframe_init): Remove comment.
2617
3c69da40
PA
26182018-05-25 Pedro Alves <palves@redhat.com>
2619
2620 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
2621 (struct readahead_cache, struct packet_reg, struct
2622 remote_arch_state, class remote_state): Move higher up in the
2623 file.
2624 (remote_target::m_remote_state): Now an object instead of a pointer.
2625 (remote_target::get_remote_state): Adjust.
2626
39f0c204
AB
26272018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
2628
2629 * stack.c (select_and_print_frame): Delete.
2630 (struct function_bounds): Move struct within function.
2631 (func_command): Most content moved into new function
2632 find_frame_for_function, use new function, print result, add
2633 function comment.
2634 (find_frame_for_function): New function, now returns a result.
2635
d392224a
PW
26362018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2637
2638 * stack.c (iterate_over_block_arg_vars): Fix comment.
2639 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
2640
45f25d6c
AB
26412018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
2642
2643 PR gdb/23203
2644 * frame.c
2645 (scoped_restore_selected_frame::scoped_restore_selected_frame):
2646 Define.
2647 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
2648 Define.
2649 * frame.h (class scoped_restore_selected_frame): New class.
2650 * stack.c (print_frame_local_vars): Remove catching and rethrowing
2651 of any exception, use scoped_restore_selected_frame to restore the
2652 frame instead.
2653
da05d921
PA
26542018-05-24 Pedro Alves <palves@redhat.com>
2655
2656 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
2657 override.
2658
a8be540e
TT
26592018-05-23 Tom Tromey <tom@tromey.com>
2660
2661 * complaints.c (struct complaints): Remove.
2662 (symfile_complaint_book): Remove.
2663 (series): New global.
2664 (complaint_internal): Update.
2665 (clear_complaints): Update.
2666
ff1cf532
TT
26672018-05-23 Tom Tromey <tom@tromey.com>
2668
2669 * complaints.c (counters): New global.
2670 (struct complain): Remove.
2671 (struct complaints) <root>: Remove.
2672 (complaint_sentinel): Remove.
2673 (symfile_complaint_book): Update.
2674 (find_complaint) Remove.
2675 (complaint_internal, clear_complaints): Update.
2676
7ff88174
TT
26772018-05-23 Tom Tromey <tom@tromey.com>
2678
2679 * complaints.c (struct complain) <file, line>: Remove.
2680 (find_complaint): Remove file, line parameters.
2681 (complaint_internal): Update.
2682
de54e1a5
TT
26832018-05-23 Tom Tromey <tom@tromey.com>
2684
2685 * complaints.c (vcomplaint): Remove.
2686 (complaint_internal) Merge in contents of vcomplaint.
2687
2ac237e5
TT
26882018-05-23 Tom Tromey <tom@tromey.com>
2689
2690 * complaints.c (struct complaints) <explanation>: Remove.
2691 (symfile_explanations): Remove.
2692 (symfile_complaint_book): Update.
2693 (vcomplaint): Update.
2694 (struct explanation): Remove.
2695
b98664d3
TT
26962018-05-23 Tom Tromey <tom@tromey.com>
2697
2698 * complaints.c (symfile_complaints): Remove.
2699 (complaint_internal): Remove "complaints" parameter.
2700 (clear_complaints, vcomplaint): Remove "c" parameter.
2701 (get_complaints): Remove.
2702 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
2703 (dwarf2_debug_line_missing_file_complaint)
2704 (dwarf2_debug_line_missing_end_sequence_complaint)
2705 (dwarf2_complex_location_expr_complaint)
2706 (dwarf2_const_value_length_mismatch_complaint)
2707 (dwarf2_section_buffer_overflow_complaint)
2708 (dwarf2_macro_malformed_definition_complaint)
2709 (dwarf2_invalid_attrib_class_complaint)
2710 (create_addrmap_from_index, dw2_symtab_iter_next)
2711 (dw2_expand_marked_cus)
2712 (dw2_debug_names_iterator::find_vec_in_debug_names)
2713 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
2714 (create_debug_type_hash_table, init_cutu_and_read_dies)
2715 (partial_die_parent_scope, add_partial_enumeration)
2716 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
2717 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
2718 (read_import_statement, read_file_scope, create_dwo_cu_reader)
2719 (create_cus_hash_table, create_dwp_hash_table)
2720 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
2721 (dwarf2_rnglists_process, dwarf2_ranges_process)
2722 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
2723 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
2724 (handle_struct_member_die, process_structure_scope)
2725 (read_array_type, read_common_block, read_module_type)
2726 (read_tag_pointer_type, read_typedef, read_base_type)
2727 (read_subrange_type, load_partial_dies, partial_die_info::read)
2728 (partial_die_info::read, partial_die_info::read)
2729 (partial_die_info::read, read_checked_initial_length_and_offset)
2730 (dwarf2_string_attr, read_formatted_entries)
2731 (dwarf_decode_line_header)
2732 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
2733 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
2734 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
2735 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
2736 (get_signatured_type, get_DW_AT_signature_type)
2737 (decode_locdesc, file_file_name, consume_improper_spaces)
2738 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
2739 (dwarf_decode_macro_bytes, dwarf_decode_macros)
2740 (dwarf2_symbol_mark_computed, set_die_type)
2741 (read_attribute_value): Update.
2742 * stap-probe.c (handle_stap_probe, get_stap_base_address):
2743 Update.
2744 * dbxread.c (unknown_symtype_complaint)
2745 (lbrac_mismatch_complaint, repeated_header_complaint)
2746 (set_namestring, function_outside_compilation_unit_complaint)
2747 (read_dbx_symtab, process_one_symbol): Update.
2748 * gdbtypes.c (stub_noname_complaint): Update.
2749 * windows-nat.c (handle_unload_dll): Update.
2750 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
2751 (decode_base_type): Update.
2752 * xcoffread.c (bf_notfound_complaint, ef_complaint)
2753 (eb_complaint, record_include_begin, record_include_end)
2754 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
2755 (process_xcoff_symbol, read_symbol)
2756 (function_outside_compilation_unit_complaint)
2757 (scan_xcoff_symtab): Update.
2758 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
2759 * buildsym.c (finish_block_internal, make_blockvector)
2760 (end_symtab_get_static_block, augment_type_symtab): Update.
2761 * dtrace-probe.c (dtrace_process_dof)
2762 (dtrace_static_probe_ops::get_probes): Update.
2763 * complaints.h (struct complaint): Don't declare.
2764 (symfile_complaints): Remove.
2765 (complaint_internal): Remove "complaints" parameter.
2766 (complaint): Likewise.
2767 (clear_complaints): Likewise.
2768 * symfile.c (syms_from_objfile_1, finish_new_objfile)
2769 (reread_symbols): Update.
2770 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
2771 (dwarf2_frame_cache, decode_frame_entry): Update.
2772 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
2773 * objc-lang.c (lookup_objc_class, lookup_child_selector)
2774 (info_selectors_command): Update.
2775 * macrotab.c (macro_include, check_for_redefinition)
2776 (macro_undef): Update.
2777 * objfiles.c (filter_overlapping_sections): Update.
2778 * stabsread.c (invalid_cpp_abbrev_complaint)
2779 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
2780 (define_symbol, error_type, read_type, rs6000_builtin_type)
2781 (stabs_method_name_from_physname, read_member_functions)
2782 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
2783 (attach_fields_to_type, complain_about_struct_wipeout)
2784 (read_range_type, read_args, common_block_start)
2785 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
2786 Update.
2787 * mdebugread.c (index_complaint, unknown_ext_complaint)
2788 (basic_type_complaint, bad_tag_guess_complaint)
2789 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
2790 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
2791 (parse_procedure, parse_lines)
2792 (function_outside_compilation_unit_complaint)
2793 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
2794 (bad_tag_guess_complaint, reg_value_complaint): Update.
2795 * cp-support.c (demangled_name_complaint): Update.
2796 * macroscope.c (sal_macro_scope): Update.
2797 * dwarf-index-write.c (class debug_names): Update.
2798
4e9668d0
TT
27992018-05-23 Tom Tromey <tom@tromey.com>
2800
2801 * complaints.c (clear_complaints): Remove "noisy" parameter.
2802 * complaints.h (clear_complaints): Update.
2803 * symfile.c (syms_from_objfile_1, finish_new_objfile)
2804 (reread_symbols): Update.
2805
43ba33c7
TT
28062018-05-23 Tom Tromey <tom@tromey.com>
2807
2808 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
2809 SUBSEQUENT_MESSAGE.
2810 (vcomplaint, clear_complaints): Update.
2811 (symfile_explanations): Remove some messages.
2812
2b9496b2
TT
28132018-05-23 Tom Tromey <tom@tromey.com>
2814
2815 * complaints.c (internal_complaint): Remove.
2816 * complaints.h (internal_complaint): Remove.
2817
35f1fea3
MR
28182018-05-22 Maciej W. Rozycki <macro@mips.com>
2819
2820 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
2821
6b8edb51
PA
28222018-05-22 Pedro Alves <palves@redhat.com>
2823
2824 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
2825 (remote_fileio_badfd, remote_fileio_return_errno)
2826 (remote_fileio_return_success, remote_fileio_func_open)
2827 (remote_fileio_func_open, remote_fileio_func_close)
2828 (remote_fileio_func_read, remote_fileio_func_write)
2829 (remote_fileio_func_lseek, remote_fileio_func_rename)
2830 (remote_fileio_func_unlink, remote_fileio_func_stat)
2831 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
2832 (remote_fileio_func_isatty, remote_fileio_func_system): Add
2833 remote_target parameter.
2834 (remote_fio_func_map) <func>: Add remote_target parameter.
2835 (do_remote_fileio_request, remote_fileio_request):
2836 * remote-fileio.h (remote_fileio_request):
2837 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
2838 remote_target parameter.
2839 (remote_notif_process, handle_notification): Adjust to pass down
2840 the remote.
2841 (remote_notif_state_allocate): Add remote_target parameter. Save
2842 it.
2843 * remote-notif.h (struct remote_target): Forward declare.
2844 (struct notif_client) <parse, ack, can_get_pending_events>: Add
2845 remote_target parameter.
2846 (struct remote_notif_state) <remote>: New field.
2847 (remote_notif_ack, remote_notif_parse): Add remote_target
2848 parameter.
2849 (remote_notif_state_allocate, remote_notif_state_allocate): Add
2850 remote_target parameter.
2851 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
2852 (threads_listing_context, rmt_thread_action, protocol_feature)
2853 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
2854 (packet_result, struct threads_listing_context, remote_state):
2855 Move definitions and declarations higher up.
2856 (remote_target) <~remote_target>: Declare.
2857 (remote_download_command_source, remote_file_put, remote_file_get)
2858 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
2859 (remote_hostio_pread_vFile, remote_hostio_send_command)
2860 (remote_hostio_set_filesystem, remote_hostio_open)
2861 (remote_hostio_close, remote_hostio_unlink, remote_state)
2862 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
2863 (get_memory_write_packet_size, get_memory_read_packet_size)
2864 (append_pending_thread_resumptions, remote_detach_1)
2865 (append_resumption, remote_resume_with_vcont)
2866 (add_current_inferior_and_thread, wait_ns, wait_as)
2867 (process_stop_reply, remote_notice_new_inferior)
2868 (process_initial_stop_replies, remote_add_thread)
2869 (btrace_sync_conf, remote_btrace_maybe_reopen)
2870 (remove_new_fork_children, kill_new_fork_children)
2871 (discard_pending_stop_replies, stop_reply_queue_length)
2872 (check_pending_events_prevent_wildcard_vcont)
2873 (discard_pending_stop_replies_in_queue, stop_reply)
2874 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
2875 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
2876 (remote_interrupt_as, remote_interrupt_ns)
2877 (remote_get_noisy_reply, remote_query_attached)
2878 (remote_add_inferior, remote_current_thread, get_current_thread)
2879 (set_thread, set_general_thread, set_continue_thread)
2880 (set_general_process, write_ptid)
2881 (remote_unpack_thread_info_response, remote_get_threadinfo)
2882 (parse_threadlist_response, remote_get_threadlist)
2883 (remote_threadlist_iterator, remote_get_threads_with_ql)
2884 (remote_get_threads_with_qxfer)
2885 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
2886 (get_offsets, remote_check_symbols, remote_supported_packet)
2887 (remote_query_supported, remote_packet_size)
2888 (remote_serial_quit_handler, remote_detach_pid)
2889 (remote_vcont_probe, remote_resume_with_hc)
2890 (send_interrupt_sequence, interrupt_query)
2891 (remote_notif_get_pending_events, fetch_register_using_p)
2892 (send_g_packet, process_g_packet, fetch_registers_using_g)
2893 (store_register_using_P, store_registers_using_G)
2894 (set_remote_traceframe, check_binary_download)
2895 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
2896 (remote_xfer_live_readonly_partial, remote_read_bytes)
2897 (remote_send_printf, remote_flash_write, readchar)
2898 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
2899 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
2900 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
2901 (extended_remote_disable_randomization, extended_remote_run)
2902 (send_environment_packet, extended_remote_environment_support)
2903 (extended_remote_set_inferior_cwd, remote_write_qxfer)
2904 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
2905 (packet_command): Now methods of ...
2906 (remote_target): ... this class.
2907 (m_remote_state) <remote_target>: New field.
2908 (struct remote_state) <stop_reply_queue,
2909 remote_async_inferior_event_token, wait_forever_enabled_p>: New
2910 fields.
2911 (remote_state::remote_state): Allocate stop_reply_queue.
2912 (remote_state): Delete global.
2913 (get_remote_state_raw): Delete.
2914 (remote_target::get_remote_state): Allocate m_remote_state on
2915 demand.
2916 (get_current_remote_target): New.
2917 (remote_ops, extended_remote_ops): Delete.
2918 (wait_forever_enabled_p, remote_async_inferior_event_token):
2919 Delete, moved to struct remote_state.
2920 (remote_target::close): Delete self. Destruction bits split to
2921 ...
2922 (remote_target::~remote_target): ... this.
2923 (show_memory_packet_size): Adjust to use
2924 get_current_remote_target.
2925 (struct protocol_feature) <func>: Add remote_target parameter.
2926 All callers adjusted.
2927 (curr_quit_handler_target): New.
2928 (remote_serial_quit_handler): Reimplement.
2929 (remote_target::open_1): Adjust to use get_current_remote_target.
2930 Heap-allocate remote_target/extended_remote_target instances.
2931 (vcont_builder::vcont_builder): Add remote_target parameter, and
2932 save it in m_remote. All callers adjusted.
2933 (vcont_builder::m_remote): New field.
2934 (vcont_builder::restart, vcont_builder::flush)
2935 (vcont_builder::push_action): Use it.
2936 (remote_target::commit_resume): Use it.
2937 (struct queue_iter_param) <remote>: New field.
2938 (remote_target::remove_new_fork_children): Fill in 'remote' field.
2939 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
2940 (check_pending_event_prevents_wildcard_vcont_callback)
2941 (remote_target::check_pending_events_prevent_wildcard_vcont)
2942 (remote_target::discard_pending_stop_replies)
2943 (remote_target::discard_pending_stop_replies_in_queue)
2944 (remote_target::remote_notif_remove_queued_reply): Fill in
2945 'remote' field.
2946 (remote_notif_get_pending_events): New.
2947 (remote_target::readchar, remote_target::remote_serial_write):
2948 Save/restore curr_quit_handler_target.
2949 (putpkt): New.
2950 (kill_new_fork_children): Fill in 'remote' field.
2951 (packet_command): Use get_current_remote_target, defer to
2952 remote_target method of same name.
2953 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
2954 parameter, and save it in m_remote. All callers adjusted.
2955 (scoped_remote_fd::release): Use m_remote.
2956 (scoped_remote_fd::m_remote): New field.
2957 (remote_file_put, remote_file_get, remote_file_delete): Use
2958 get_current_remote_target, defer to remote_target method of same
2959 name.
2960 (remote_btrace_reset): Add remote_state paremeter. Update all
2961 callers.
2962 (remote_async_inferior_event_handler). Pass down 'data'.
2963 (remote_new_objfile): Use get_current_remote_target.
2964 (remote_target::vcont_r_supported): New.
2965 (set_range_stepping): Use get_current_remote_target and
2966 remote_target::vcont_r_supported.
2967 (_initialize_remote): Don't allocate 'remote_state' and
2968 'stop_reply_queue' globals.
2969 * remote.h (struct remote_target): Forward declare.
2970 (getpkt, putpkt, remote_notif_get_pending_events): Add
2971 'remote_target' parameter.
2972
f5db4863
PA
29732018-05-22 Pedro Alves <palves@redhat.com>
2974
2975 * remote.c (vcont_builder): Now a class. Make all data members
2976 private.
2977 (vcont_builder) <vcont_builder, restart, flush, push_action>:
2978 Declare methods.
2979 (vcont_builder_restart): Rename to ...
2980 (vcont_builder::restart): ... this.
2981 (vcont_builder_flush): Rename to ...
2982 (vcont_builder::flush): ... this.
2983 (vcont_builder_push_action): Rename to ...
2984 (vcont_builder::push_action): ... this.
2985 (remote_target::commit_resume): Adjust.
2986
cc0be08f
PA
29872018-05-22 Pedro Alves <palves@redhat.com>
2988
2989 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
2990 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
2991 (get_fixed_memory_packet_size): New.
2992 (get_memory_packet_size): Use it.
2993 (set_memory_packet_size): Don't override the config size with
2994 DEFAULT_MAX_MEMORY_PACKET_SIZE.
2995 (show_memory_packet_size): Use get_fixed_memory_packet_size.
2996 Don't refer to get_memory_packet_size if not connected to a remote
2997 target. Show "(default)" if configured size is 0.
2998
9607784a
PA
29992018-05-22 Pedro Alves <palves@redhat.com>
3000
3001 * remote.c (remote_target::mourn_inferior): Move
3002 discard_pending_stop_replies call here from ...
3003 (_initialize_remote): ... here.
3004
0e9a6b2f
PA
30052018-05-22 Pedro Alves <palves@redhat.com>
3006
3007 * remote.c (compare_section_command): Remove set_general_process
3008 call.
3009
43c3a0e4
PA
30102018-05-22 Pedro Alves <palves@redhat.com>
3011
3012 * remote.c (struct packet_reg, struct remote_arch_state):
3013 Move higher up in the file.
3014 (remote_state) <m_arch_states>: Store remote_arch_state values
3015 instead of remote_arch_state pointers.
3016 (remote_state::get_remote_arch_state): Adjust.
3017
9d6eea31
PA
30182018-05-22 Pedro Alves <palves@redhat.com>
3019
3020 * remote.c: Include <unordered_map>.
3021 (remote_state): Now a class.
3022 (remote_state) <get_remote_arch_state>: Declare method.
3023 <get_remote_arch_state>: New field.
3024 (remote_arch_state) <remote_arch_state>: Declare ctor.
3025 <regs>: Now a unique_ptr.
3026 (remote_gdbarch_data_handle): Delete.
3027 (get_remote_arch_state): Delete.
3028 (remote_state::get_remote_arch_state): New.
3029 (get_remote_state): Adjust to call remote_state's
3030 get_remote_arch_state method.
3031 (init_remote_state): Delete, bits factored out to ...
3032 (remote_arch_state::remote_arch_state): ... this new method.
3033 (get_remote_packet_size, get_memory_packet_size)
3034 (process_g_packet, remote_target::fetch_registers)
3035 (remote_target::prepare_to_store, store_registers_using_G)
3036 (remote_target::store_registers, remote_target::get_trace_status):
3037 Adjust to call remote_state's method.
3038 (_initialize_remote): Remove reference to
3039 remote_gdbarch_data_handle.
3040
dd194f6b
PA
30412018-05-22 Pedro Alves <palves@redhat.com>
3042
3043 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
3044 pread>: New method declarations.
3045 (remote_target::open_1): Adjust.
3046 (readahead_cache_invalidate): Rename to ...
3047 (readahead_cache::invalidate): ... this, and adjust to be a class
3048 method.
3049 (readahead_cache_invalidate_fd): Rename to ...
3050 (readahead_cache::invalidate_fd): ... this, and adjust to be a
3051 class method.
3052 (remote_hostio_pwrite): Adjust.
3053 (remote_hostio_pread_from_cache): Rename to ...
3054 (readahead_cache::pread): ... this, and adjust to be a class
3055 method.
3056 (remote_hostio_close): Adjust.
3057
440b7aec
PA
30582018-05-22 Pedro Alves <palves@redhat.com>
3059
3060 * remote.c (remote_hostio_close_cleanup): Delete.
3061 (class scoped_remote_fd): New.
3062 (remote_file_put, remote_file_get): Use it.
3063
de44f5a7
PA
30642018-05-22 Pedro Alves <palves@redhat.com>
3065
3066 (struct vCont_action_support): Use bool and initialize all fields.
3067 (struct readahead_cache): Initialize all fields.
3068 (remote_state): Use bool and initialize all fields.
3069 (remote_state::remote_state, remote_state::~remote_state): New.
3070 (new_remote_state): Delete.
3071 (_initialize_remote): Use new to allocate remote_state.
3072
b1b60145
PA
30732018-05-22 Pedro Alves <palves@redhat.com>
3074 張俊芝 <zjz@zjz.name>
3075
3076 PR gdb/22973
3077 * c-exp.y: Include "c-support.h".
3078 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
3079 of tolower. Use c_ident_is_alpha to scan names.
3080 * c-lang.c: Include "c-support.h".
3081 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
3082 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
3083 * c-support.h: New file, with bits factored out from ...
3084 * cp-name-parser.y: ... this file.
3085 Include "c-support.h".
3086 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
3087 c-support.h and renamed.
3088 (symbol_end, yylex): Adjust.
3089
0ec848ad
PFC
30902018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3091
3092 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
3093 parameter type to CORE_ADDR.
3094 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
3095 parameter type in declaration to CORE_ADDR.
3096 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
3097 target_auxv_search to get AT_HWCAP and use the result to get the
3098 target description.
3099 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
3100 to CORE_ADDR. Remove the cast of the return value to unsigned
3101 long. Fix error predicate of target_auxv_search.
3102 (ppc_linux_nat_target::read_description): Change the type of the
3103 hwcap variable to CORE_ADDR.
3104
0fb2aaa1
PFC
31052018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3106
3107 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
3108 if the size of fpscr is larger than 32 bits.
3109
2c3305f6
PFC
31102018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3111
3112 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
3113 (ppc32_linux_vsxregmap): New global.
3114 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
3115 regcache_supply_regset, and regcache_collect_regset.
3116 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
3117 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
3118 (fetch_vsx_register, store_vsx_register): Remove.
3119 (fetch_vsx_registers): Add regno parameter. Get regset using
3120 ppc_linux_vsxregset. Use regset to supply registers.
3121 (store_vsx_registers): Add regno parameter. Get regset using
3122 ppc_linux_vsxregset. Use regset to collect registers.
3123 (fetch_register): Call fetch_vsx_registers instead of
3124 fetch_vsx_register.
3125 (store_register): Call store_vsx_registers instead of
3126 store_vsx_register.
3127 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
3128 new regno parameter.
3129 (store_ppc_registers): Call store_vsx_registers with -1 for the
3130 new regno parameter.
3131 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
3132 (ppc_collect_vsxregset): Remove.
3133
1d75a658
PFC
31342018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3135
3136 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
3137 offset fields.
3138 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
3139 for vector register offset fields.
3140 (ppc64_fbsd_reg_offsets): Likewise.
3141 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
3142 to vector register offset fields.
3143 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
3144 to vector register offset fields.
3145 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
3146 vector register offset fields.
3147 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
3148 initializers for vector register offset fields.
3149 (rs6000_aix64_reg_offsets): Likewise.
3150 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
3151 (ppc_supply_vrregset): Remove.
3152 (ppc_collect_vrregset): Remove.
3153 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
3154 (ppc_linux_vrregset) : New function.
3155 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
3156 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
3157 (ppc32_linux_vrregset): Remove.
3158 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
3159 and use result instead of ppc32_linux_vrregset.
3160 (ppc32_linux_reg_offsets): Remove initializers for vector register
3161 offset fields.
3162 (ppc64_linux_reg_offsets): Likewise.
3163 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
3164 * ppc-linux-nat.c: Include regset.h.
3165 (gdb_vrregset_t): Adjust comment to account for little-endian
3166 mode.
3167 (supply_vrregset, fill_vrregset): Remove.
3168 (fetch_altivec_register, store_altivec_register): Remove.
3169 (fetch_altivec_registers): Add regno parameter. Get regset using
3170 ppc_linux_vrregset. Use regset to supply registers.
3171 (store_altivec_registers): Add regno parameter. Get regset using
3172 ppc_linux_vrregset. Use regset to collect registers.
3173 (fetch_register): Call fetch_altivec_registers instead of
3174 fetch_altivec_register.
3175 (store_register): Call store_altivec_registers instead of
3176 store_altivec_register.
3177 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
3178 the new regno parameter.
3179 (store_ppc_registers): Call store_altivec_registers with -1 for
3180 the new regno parameter.
3181
d078308a
PFC
31822018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3183
3184 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
3185 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
3186 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
3187 (gdb_vrregset_t): Change array type size to
3188 PPC_LINUX_SIZEOF_VRREGSET.
3189 (gdb_vsxregset_t): Change array type size to
3190 PPC_LINUX_SIZEOF_VSXREGSET.
3191 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
3192 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
3193 PPC_LINUX_SIZEOF_VSXREGSET.
3194
2e077f5e
PFC
31952018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3196
3197 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
3198 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
3199 nat/ppc-linux.c.
3200 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
3201 ppc_linux_target_wordsize with tid.
3202 (ppc_linux_nat_target::read_description): Call ppc_linux_target
3203 wordsize with tid.
3204 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
3205 (ppc64_64bit_inferior_p): Add static and inline specifiers.
3206 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
3207 tid parameter. Remove static specifier.
3208 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
3209 (ppc_linux_target_wordsize): New declaration.
3210
bd64614e
PFC
32112018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3212
3213 * arch/ppc-linux-common.c: New file.
3214 * arch/ppc-linux-common.h: New file.
3215 * arch/ppc-linux-tdesc.h: New file.
3216 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
3217 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
3218 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
3219 arch/ppc-linux-tdesc.h.
3220 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
3221 arch/ppc-linux-tdesc.h.
3222 (ppc_linux_nat_target::read_description): Remove target
3223 description matching code. Fill a ppc_linux_features struct and
3224 call ppc_linux_match_description with it. Move comment about ISA
3225 2.05 to ppc-linux-common.c.
3226 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
3227 arch/ppc-linux-tdesc.h.
3228 (ppc_linux_core_read_description): Remove target description
3229 matching code. Fill a ppc_linux_features struct and call
3230 ppc_linux_match_description with it.
3231 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
3232 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
3233 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
3234 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
3235 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
3236 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
3237 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
3238 (tdesc_powerpc_e500l): Remove.
3239
241db429
JB
32402018-05-22 Joel Brobecker <brobecker@adacore.com>
3241
3242 * ada-lang.c (catch_assert_command): Pass empty string instead
3243 of NULL for excep_string argument.
3244
75d74cca
MR
32452018-05-22 Maciej W. Rozycki <macro@mips.com>
3246
3247 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
3248 the width of the requested register exceeds the width of the
3249 `ptrace' data type.
3250
122b53ea
TT
32512018-05-21 Tom Tromey <tom@tromey.com>
3252
3253 * printcmd.c (output_command): Remove.
3254 (output_command_const): Rename to output_command.
3255 * valprint.h (output_command): Rename from output_command_const.
3256 * tracepoint.c (trace_dump_actions): Call output_command.
3257
bc18fbb5
TT
32582018-05-21 Tom Tromey <tom@tromey.com>
3259
3260 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
3261 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
3262 * ada-lang.h (create_ada_exception_catchpoint): Update.
3263 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
3264 std::string.
3265 (create_excep_cond_exprs, ~ada_catchpoint)
3266 (should_stop_exception, print_one_exception)
3267 (print_mention_exception, print_recreate_exception): Update.
3268 (ada_get_next_arg): Remove.
3269 (catch_ada_exception_command_split): Use std::string. Change type
3270 of "excep_string", "cond_string".
3271 (catch_ada_exception_command): Update.
3272 (create_ada_exception_catchpoint): Change type of excep_string.
3273 (ada_exception_sal): Remove excep_string parameter.
3274 (~ada_catchpoint): Remove.
3275
790217f6
TT
32762018-05-21 Tom Tromey <tom@tromey.com>
3277
3278 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
3279 cleanup.
3280
6f46ac85
TT
32812018-05-21 Tom Tromey <tom@tromey.com>
3282
3283 * ada-lang.c (ada_exception_message_1, ada_exception_message):
3284 Return unique_xmalloc_ptr.
3285 (print_it_exception): Update.
3286
15b6611c
TT
32872018-05-21 Tom Tromey <tom@tromey.com>
3288
3289 * tracepoint.c (trace_dump_actions): Use std::string.
3290
c0c9f665
TT
32912018-05-21 Tom Tromey <tom@tromey.com>
3292
3293 * symfile.c (reread_symbols): Use std::string for original_name.
3294
22ca247e
TT
32952018-05-21 Tom Tromey <tom@tromey.com>
3296
3297 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
3298 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
3299 constructor.
3300
184cde75
SM
33012018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
3302
3303 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
3304 instance to...
3305 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
3306 * objfiles.c (get_objfile_bfd_data): Allocate
3307 objfile_per_bfd_storage with obstack_new when allocating on
3308 obstack.
3309
e39db4db
SM
33102018-05-20 Simon Marchi <simon.marchi@ericsson.com>
3311
3312 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
3313 OBSTACK_ZALLOC.
3314 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
3315 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
3316 * mdebugread.c (mdebug_build_psymtabs): Likewise.
3317 (add_pending): Likewise.
3318 (parse_symbol): Likewise.
3319 (parse_partial_symbols): Likewise.
3320 (psymtab_to_symtab_1): Likewise.
3321 (new_psymtab): Likewise.
3322 (elfmdebug_build_psymtabs): Likewise.
3323 * minsyms.c (terminate_minimal_symbol_table): Likewise.
3324 * objfiles.c (get_objfile_bfd_data): Likewise.
3325 (objfile_register_static_link): Likewise.
3326 * psymtab.c (allocate_psymtab): Likewise.
3327 * stabsread.c (read_member_functions): Likewise.
3328 * xcoffread.c (xcoff_end_psymtab): Likewise.
3329
284a0e3c
SM
33302018-05-20 Simon Marchi <simon.marchi@ericsson.com>
3331
3332 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
3333 compiler supports std::is_trivially_constructible.
3334 * common/poison.h: Include obstack.h.
3335 (IsMallocable): Define to is_trivially_constructible if the
3336 compiler supports it, define to true_type otherwise.
3337 (xobnew): New.
3338 (XOBNEW): Redefine.
3339 (xobnewvec): New.
3340 (XOBNEWVEC): Redefine.
3341 * gdb_obstack.h (obstack_zalloc): New.
3342 (OBSTACK_ZALLOC): Redefine.
3343 (obstack_calloc): New.
3344 (OBSTACK_CALLOC): Redefine.
3345 (obstack_new): New.
3346 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
3347 (gdbarch_obstack): New declaration in gdbarch.h, definition in
3348 gdbarch.c.
3349 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
3350 obstack_calloc/obstack_zalloc.
3351 (gdbarch_obstack_zalloc): Remove.
3352 * target-descriptions.c (tdesc_data_init): Use obstack_new.
3353
59f66be3
PW
33542018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3355
3356 * stack.c (backtrace_command_1): Remove useless variable int i.
3357
50c65c2d
PW
33582018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3359
3360 * stack.c (print_frame_info): Fix comment.
3361
7ff8cb8c
TT
33622018-05-18 Tom Tromey <tom@tromey.com>
3363
3364 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
3365 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
3366 (~dwarf2_per_objfile): Update
3367 (dwarf2_get_dwz_file): Use new.
3368 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
3369 unique_ptr.
3370
400174b1
TT
33712018-05-18 Tom Tromey <tom@tromey.com>
3372
3373 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
3374 unique_ptr.
3375 * dwarf2read.c (struct dwp_file): Add constructor and
3376 initializers.
3377 (open_and_init_dwp_file): Return a unique_ptr.
3378 (dwarf2_per_objfile, create_dwp_hash_table)
3379 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
3380 (lookup_dwo_unit_in_dwp): Update.
3381 (open_and_init_dwp_file, get_dwp_file): Update.
3382
3063847f
TT
33832018-05-18 Tom Tromey <tom@tromey.com>
3384
3385 * dwarf2read.c (dwarf2_per_objfile): Update.
3386 (struct mapped_index): Add initializers.
3387 (dwarf2_read_index): Use new.
3388 (dw2_symtab_iter_init): Update.
3389 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
3390 unique_ptr.
3391
d3d02dee
SM
33922018-05-18 Simon Marchi <simon.marchi@ericsson.com>
3393
3394 * dwarf2read.c (mapped_index) <total_size>: Remove.
3395
1d143c36
SM
33962018-05-18 Simon Marchi <simon.marchi@ericsson.com>
3397
3398 * unittests/format_pieces-selftests.c (test_format_specifier):
3399 Add ARI comments.
3400
ce1e8424
TT
34012018-05-18 Tom Tromey <tom@tromey.com>
3402
3403 * c-typeprint.c (maybe_print_hole): New function.
3404 (c_print_type_struct_field_offset): Update.
3405 (c_type_print_base_struct_union): Call maybe_print_hole.
3406
ddfe970e
KS
34072018-05-17 Keith Seitz <keiths@redhat.com>
3408
3409 * breakpoint.c (build_bpstat_chain): New function, moved from
3410 bpstat_stop_status.
3411 (bpstat_stop_status): Add optional parameter, `stop_chain'.
3412 If no stop chain is passed, call build_bpstat_chain to build it.
3413 * breakpoint.h (build_bpstat_chain): Declare.
3414 (bpstat_stop_status): Move documentation here from breakpoint.c.
3415 * infrun.c (handle_signal_stop): Before eliding inlined frames,
3416 build the stop chain and pass it to skip_inline_frames.
3417 Pass this stop chain to bpstat_stop_status.
3418 * inline-frame.c: Include breakpoint.h.
3419 (stopped_by_user_bp_inline_frame): New function.
3420 (skip_inline_frames): Add parameter `stop_chain'.
3421 Move documention to inline-frame.h.
3422 If non-NULL, use stopped_by_user_bp_inline_frame to determine
3423 whether the frame should be elided.
3424 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
3425 Add moved documentation and update for new parameter.
3426
b17992c1
SM
34272018-05-17 Simon Marchi <simon.marchi@ericsson.com>
3428
3429 PR cli/14975
3430 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3431 unittests/format_pieces-selftests.c.
3432 * common/format.h (format_piece) <operator==>: New.
3433 (format_pieces) <operator[]>: Remove.
3434 * common/format.c (format_pieces::format_pieces): Handle \e.
3435 * unittests/format_pieces-selftests.c: New.
3436
58f0c718
TT
34372018-05-17 Tom Tromey <tom@tromey.com>
3438
3439 PR symtab/23010:
3440 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
3441 (dw2_instantiate_symtab): Add skip_partial parameter.
3442 (dw2_find_last_source_symtab, dw2_map_expand_apply)
3443 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
3444 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
3445 (dw2_expand_symtabs_matching_one)
3446 (dw2_find_pc_sect_compunit_symtab)
3447 (dw2_debug_names_lookup_symbol)
3448 (dw2_debug_names_expand_symtabs_for_function): Update.
3449 (init_cutu_and_read_dies): Add skip_partial parameter.
3450 (process_psymtab_comp_unit, build_type_psymtabs_1)
3451 (process_skeletonless_type_unit, load_partial_comp_unit)
3452 (psymtab_to_symtab_1): Update.
3453 (load_full_comp_unit): Add skip_partial parameter.
3454 (process_imported_unit_die, dwarf2_read_addr_index)
3455 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
3456 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
3457 (read_signatured_type): Update.
3458
3e618834
SM
34592018-05-17 Simon Marchi <simon.marchi@ericsson.com>
3460
3461 * value.c (release_value): Remove unused variable.
3462 (record_latest_value): Likewise.
3463 (access_value_history): Likewise.
3464 (preserve_values): Likewise.
3465
fe10fe31
TT
34662018-05-17 Tom Tromey <tom@tromey.com>
3467
3468 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
3469 Initialize.
3470
1d761124
MR
34712018-05-16 Maciej W. Rozycki <macro@mips.com>
3472
3473 PR gdb/22286
3474 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
3475 Also handle registers whose width is not a multiple of
3476 PTRACE_TYPE_RET.
3477 (linux_nat_trad_target::store_register): Likewise.
3478
06333fea
TT
34792018-05-16 Tom Tromey <tom@tromey.com>
3480
3481 * gdbcore.h (core_bfd): Redefine.
3482 * corelow.c (core_target::close): Update.
3483 (core_target_open): Update.
3484 * progspace.h (struct program_space) <cbfd>: Now a
3485 gdb_bfd_ref_ptr.
3486
921222e2
TT
34872018-05-16 Tom Tromey <tom@tromey.com>
3488
3489 PR cli/19551:
3490 * symfile-add-flags.h (enum symfile_add_flags)
3491 <SYMFILE_NOT_FILENAME>: New constant.
3492 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
3493 objfile name from BFD.
3494 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
3495 * minidebug.c (find_separate_debug_file_in_section): Put
3496 ".gnu_debugdata" into BFD's file name.
3497
3acb7083
SM
34982018-05-16 Simon Marchi <simon.marchi@ericsson.com>
3499
3500 * regcache.c (regcache_read_ftype, regcache_write_ftype):
3501 Remove.
3502
561a72d4
TC
35032018-05-15 Tamar Christina <tamar.christina@arm.com>
3504
3505 PR binutils/21446
3506 * aarch64-tdep.c (aarch64_analyze_prologue,
3507 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
3508 Indicate not interested in errors.
3509
4e6ff0e1
MR
35102018-05-15 Maciej W. Rozycki <macro@mips.com>
3511
3512 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
3513 Supply the MIPS_ZERO_REGNUM register.
3514
ea33cd92
MR
35152018-05-15 Maciej W. Rozycki <macro@mips.com>
3516
3517 * mips-tdep.c (mask_address_var): Make variable static.
3518
2d79090e
TT
35192018-05-14 Tom Tromey <tom@tromey.com>
3520
3521 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
3522
cf4912ae
AB
35232018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
3524
3525 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
3526 FXSAVE_ADDR for the mxcsr register.
3527
67e6f569
MF
35282018-05-11 Max Filippov <jcmvbkbc@gmail.com>
3529
3530 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
3531
15244507
PA
35322018-05-11 Pedro Alves <palves@redhat.com>
3533
3534 * corelow.c (core_target) <core_target>: No longer inline.
3535 Initialize m_core_gdbarch, m_core_vec and build the section table
3536 here.
3537 <~core_target>: New.
3538 <core_gdbarch, get_core_register_section>: New methods.
3539 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
3540 factored out from ...
3541 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
3542 (core_ops): Delete.
3543 (sniff_core_bfd): Add gdbarch parameter.
3544 (core_close): Delete, merged into ...
3545 (core_target::close): ... here. Delete self.
3546 (core_close_cleanup): Delete.
3547 (core_target_open): Allocate a core_target on the heap. Use a
3548 unique_ptr instead of a cleanup. Bits moved into the core_target
3549 ctor. Adjust to use core_target methods instead of globals.
3550 (get_core_register_section): Rename to ...
3551 (core_target::get_core_register_section): ... this and adjust.
3552 (struct get_core_registers_cb_data): New.
3553 (get_core_registers_cb): Use it. Use bool.
3554 (core_target::fetch_registers, core_target::files_info)
3555 (core_target::xfer_partial, core_target::read_description)
3556 (core_target::pid_to, core_target::thread_name): Adjust to
3557 reference class fields instead of globals.
3558 * target.h (struct target_ops_deleter, target_ops_up): New.
3559
451953fa
PA
35602018-05-11 Pedro Alves <palves@redhat.com>
3561
3562 * corefile.c (core_file_command): Move to corelow.c.
3563 * corelow.c (the_core_target): Delete.
3564 (core_file_command): Moved from corefile.c. Check exec_bfd
3565 instead of the_core_target. Use target_detach instead of calling
3566 into the_core_target directly.
3567 (maybe_say_no_core_file_now): New.
3568 (core_target::detach): Use it.
3569 (_initialize_corelow): Remove references to the_core_target.
3570 * gdbcore.h (the_core_target): Delete.
3571
e540a5a2 35722018-05-11 Tom Tromey <tromey@redhat.com>
3afc23a6 3573 Pedro Alves <palves@redhat.com>
e540a5a2
TT
3574
3575 * corefile.c (core_bfd): Remove.
3576 * gdbcore.h (core_bfd): Now a macro.
3577 * progspace.h (struct program_space) <cbfd>: New field.
3578
633cf254
TT
35792018-05-11 Tom Tromey <tom@tromey.com>
3580
3581 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
3582 gdb::def_vector.
3583
1a34f210
TT
35842018-05-10 Tom Tromey <tom@tromey.com>
3585
3586 * configure: Rebuild.
3587 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
3588
190852c8
JB
35892018-05-10 Joel Brobecker <brobecker@adacore.com>
3590
3591 PR server/23158:
3592 * regformats/regdat.sh: Adjust script, following the addition
3593 of the new expedite_regs parameter to init_target_desc.
3594
8727de56
OJ
35952018-05-10 Omair Javaid <omair.javaid@linaro.org>
3596
3597 PR gdb/23127
3598 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
3599 set_gdbarch_significant_addr_bit.
3600 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
3601 set_gdbarch_significant_addr_bit.
3602 * utils.c (address_significant): Update to sign extend addr.
3603
37d9e062
MF
36042018-05-09 Max Filippov <jcmvbkbc@gmail.com>
3605
3606 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
3607 (xtensa_linux_init_abi): Limit tdep->num_regs by
3608 tdep->num_nopriv_regs.
3609 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
3610 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
3611 not initialized.
3612
7402fbca
SM
36132018-05-08 Simon Marchi <simon.marchi@ericsson.com>
3614
3615 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
3616
8ee22052
AB
36172018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
3618
3619 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
3620 (I387_MXCSR_INIT_VAL): New constant.
3621 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
3622 buffer if it was supplied by the inferior.
3623 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
3624 (i387_xsave_get_clear_bv): New function.
3625 (i387_supply_xsave): Only read x87 control registers from the
3626 xsave buffer if the feature is enabled, and the state will have
3627 been written, otherwise, provide a suitable default.
3628 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
3629 including x87 control registers. Update control registers if they
3630 have changed from the default value, and mark features as enabled
3631 as required.
3632 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
3633
968ae51b
UW
36342018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
3635
3636 * spu-tdep.c (info_spu_event_command): Fix output formatting.
3637
aff689d3
TT
36382018-05-07 Tom Tromey <tom@tromey.com>
3639
3640 * configure: Rebuild.
3641 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
3642
ce887586
TT
36432018-05-07 Tom Tromey <tom@tromey.com>
3644
3645 PR tdep/20362:
3646 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
3647 bit. Use correct value for VDIV.
3648
85e26832
TT
36492018-05-04 Tom Tromey <tom@tromey.com>
3650
3651 * configure: Rebuild.
3652 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
3653
449b1ac7
TT
36542018-05-04 Tom Tromey <tom@tromey.com>
3655
3656 * linux-record.c (record_linux_system_call) <case
3657 RECORD_SYS_RECVFROM>: Add "break".
3658
15c9ffd6
TT
36592018-05-04 Tom Tromey <tom@tromey.com>
3660
3661 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
3662 Add missing "break".
3663 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
3664 Add missing "break".
3665
e3829d13
TT
36662018-05-04 Tom Tromey <tom@tromey.com>
3667
3668 * rs6000-tdep.c (ppc_process_record_op4)
3669 (ppc_process_record_op63): Add fall-through comment.
3670
da0e1563
TT
36712018-05-04 Tom Tromey <tom@tromey.com>
3672
3673 * i386-tdep.c (i386_process_record): Add fall-through comment.
3674
0019cd49
TT
36752018-05-04 Tom Tromey <tom@tromey.com>
3676
3677 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
3678 comment.
3679
565e0eda
TT
36802018-05-04 Tom Tromey <tom@tromey.com>
3681
3682 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
3683 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
3684 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
3685 comment.
3686 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
3687 comment.
3688 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
3689 comment.
3690
621846f4
TT
36912018-05-04 Tom Tromey <tom@tromey.com>
3692
3693 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
3694
86a73007
TT
36952018-05-04 Tom Tromey <tom@tromey.com>
3696
3697 * s390-tdep.c (s390_process_record): Fix fall-through comments.
3698 * xcoffread.c (scan_xcoff_symtab): Move comment later.
3699 * symfile.c (section_is_mapped): Fix fall-through comment.
3700 * stabsread.c (define_symbol, read_member_functions): Fix
3701 fall-through comment.
3702 * s390-linux-tdep.c (s390_process_record): Fix fall-through
3703 comment.
3704 * remote.c (remote_wait_as): Fix fall-through comment.
3705 * p-exp.y (yylex): Fix fall-through comment.
3706 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
3707 comment.
3708 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
3709 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
3710 * jv-exp.y (yylex): Fix fall-through comment.
3711 * go-exp.y (lex_one_token): Fix fall-through comment.
3712 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
3713 fall-through comment.
3714 * f-exp.y (yylex): Fix fall-through comment.
3715 * dwarf2read.c (process_die): Fix fall-through comments.
3716 * dbxread.c (process_one_symbol): Fix fall-through comment.
3717 * d-exp.y (lex_one_token): Fix fall-through comment.
3718 * cp-name-parser.y (yylex): Fix fall-through comment.
3719 * coffread.c (coff_symtab_read): Fix fall-through comment.
3720 * c-exp.y (lex_one_token): Fix fall-through comment.
3721 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
3722 comment.
3723 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
3724 comment.
3725
56bcdbea
TT
37262018-05-04 Tom Tromey <tom@tromey.com>
3727
3728 PR python/22730:
3729 * NEWS: Mention gdb.execute change.
3730 * gdbcmd.h (execute_control_command): Don't declare.
3731 * python/python.c (execute_gdb_command): Use read_command_lines_1,
3732 execute_control_commands, execute_control_commands_to_string.
3733 * cli/cli-script.h (execute_control_commands)
3734 (execute_control_commands_to_string): Declare.
3735 (execute_control_command): Add from_tty parameter.
3736 * cli/cli-script.c (execute_control_commands)
3737 (execute_control_commands_to_string): New functions.
3738 (execute_user_command): Use execute_control_commands.
3739 (execute_control_command_1): Add "from_tty" parameter. Update.
3740 (execute_control_command): Likewise.
3741
a913fffb
TT
37422018-05-04 Tom Tromey <tom@tromey.com>
3743
3744 PR python/22731:
3745 * NEWS: Mention that breakpoint commands are writable.
3746 * python/py-breakpoint.c (bppy_set_commands): New function.
3747 (breakpoint_object_getset) <"commands">: Use it.
3748
60b3cef2
TT
37492018-05-04 Tom Tromey <tom@tromey.com>
3750
3751 * tracepoint.c (actions_command): Update.
3752 * mi/mi-cmd-break.c (mi_command_line_array)
3753 (mi_command_line_array_cnt, mi_command_line_array_ptr)
3754 (mi_read_next_line): Remove.
3755 (mi_cmd_break_commands): Update.
3756 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
3757 function_view.
3758 * cli/cli-script.c (get_command_line): Update.
3759 (process_next_line): Use function_view. Constify.
3760 (recurse_read_control_structure, read_command_lines)
3761 (read_command_lines_1): Change argument types to function_view.
3762 (do_define_command, document_command): Update.
3763 * breakpoint.h (check_tracepoint_command): Don't declare.
3764 * breakpoint.c (check_tracepoint_command): Remove.
3765 (commands_command_1, create_tracepoint_from_upload): Update.
3766
7a2c85f2
TT
37672018-05-04 Tom Tromey <tom@tromey.com>
3768
3769 PR gdb/11750:
3770 * cli/cli-script.h (enum command_control_type) <define_control>:
3771 New constant.
3772 * cli/cli-script.c (multi_line_command_p): Handle define_control.
3773 (build_command_line, execute_control_command_1)
3774 (process_next_line): Likewise.
3775 (do_define_command): New function, extracted from define_command.
3776 (define_command): Use it.
3777
295dc222
TT
37782018-05-04 Tom Tromey <tom@tromey.com>
3779
3780 * tracepoint.c (actions_command): Update.
3781 * cli/cli-script.h (read_command_lines): Update.
3782 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
3783 (MAX_TMPBUF): Remove define.
3784 (define_command): Use string_printf.
3785 (document_command): Likewise.
3786 * breakpoint.c (commands_command_1): Update.
3787
1263a9d5
TT
37882018-05-04 Tom Tromey <tom@tromey.com>
3789
3790 * top.c (execute_command): Update.
3791 * cli/cli-script.h (print_command_lines): Now varargs.
3792 * cli/cli-script.c (print_command_lines): Now varargs.
3793 (execute_control_command_1) <case while_control, case if_control>:
3794 Update.
3795
12973681
TT
37962018-05-04 Tom Tromey <tom@tromey.com>
3797
3798 * tracepoint.c (all_tracepoint_actions): Rename from
3799 all_tracepoint_actions_and_cleanup. Change return type.
3800 (actions_command, encode_actions_1, encode_actions)
3801 (trace_dump_actions, tdump_command): Update.
3802 * remote.c (remote_download_command_source): Update.
3803 * python/python.c (gdbpy_eval_from_control_command)
3804 (python_command, python_interactive_command): Update.
3805 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
3806 * guile/guile.c (guile_command)
3807 (gdbscm_eval_from_control_command, guile_command): Update.
3808 * compile/compile.c (compile_code_command)
3809 (compile_print_command, compile_to_object): Update.
3810 * cli/cli-script.h (struct command_lines_deleter): New.
3811 (counted_command_line): New typedef.
3812 (struct command_line): Add constructor, destructor.
3813 <body_list>: Remove.
3814 <body_list_0, body_list_1>: New members.
3815 (command_line_up): Remove typedef.
3816 (read_command_lines, read_command_lines_1, get_command_line):
3817 Update.
3818 (copy_command_lines): Don't declare.
3819 * cli/cli-script.c (build_command_line): Use "new".
3820 (get_command_line): Return counted_command_line.
3821 (print_command_lines, execute_user_command)
3822 (execute_control_command_1, while_command, if_command): Update.
3823 (realloc_body_list): Remove.
3824 (process_next_line, recurse_read_control_structure): Update.
3825 (read_command_lines, read_command_lines_1): Return counted_command_line.
3826 (free_command_lines): Use "delete".
3827 (copy_command_lines): Remove.
3828 (define_command, document_command, show_user_1): Update.
3829 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
3830 a counted_command_line.
3831 * breakpoint.h (counted_command_line): Remove typedef.
3832 (breakpoint_set_commands): Update.
3833 * breakpoint.c (check_no_tracepoint_commands)
3834 (validate_commands_for_breakpoint): Update.
3835 (breakpoint_set_commands): Change commands to be a
3836 counted_command_line.
3837 (commands_command_1, update_dprintf_command_list)
3838 (create_tracepoint_from_upload): Update.
3839
e2fc72e2
TT
38402018-05-04 Tom Tromey <tom@tromey.com>
3841
3842 * cli/cli-decode.h (cmd_list_element): New constructor.
3843 (~cmd_list_element): New destructor.
3844 (struct cmd_list_element): Add initializers.
3845 * cli/cli-decode.c (do_add_cmd): Use "new".
3846 (delete_cmd): Use "delete".
3847
a3b60e45
JK
38482018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
3849 Pedro Alves <palves@redhat.com>
3850
3851 PR breakpoints/19806 and support for PR external/20207.
3852 * NEWS: Mention Aarch64 watchpoint improvements.
3853 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
3854 watchpoints and PR external/20207 watchpoints.
3855 * nat/aarch64-linux-hw-point.c
3856 (kernel_supports_any_contiguous_range): New.
3857 (aarch64_watchpoint_offset): New.
3858 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
3859 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
3860 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
3861 (aarch64_align_watchpoint): New parameters aligned_offset_p and
3862 next_addr_orig_p. Support PR external/20207 watchpoints.
3863 (aarch64_downgrade_regs): New.
3864 (aarch64_dr_state_insert_one_point): New parameters offset and
3865 addr_orig.
3866 (aarch64_dr_state_remove_one_point): Likewise.
3867 (aarch64_handle_breakpoint): Update caller.
3868 (aarch64_handle_aligned_watchpoint): Likewise.
3869 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
3870 aligned_offset.
3871 (aarch64_linux_set_debug_regs): Remove const from state. Call
3872 aarch64_downgrade_regs.
3873 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
3874 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
3875 (DR_CONTROL_MASK): ... this.
3876 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
3877 (unsigned int aarch64_watchpoint_offset): New prototype.
3878 (aarch64_linux_set_debug_regs): Remove const from state.
3879 * utils.c (align_up, align_down): Move to ...
3880 * common/common-utils.c (align_up, align_down): ... here.
3881 * utils.h (align_up, align_down): Move to ...
3882 * common/common-utils.h (align_up, align_down): ... here.
3883
05bc7456
JB
38842018-05-04 Joel Brobecker <brobecker@adacore.com>
3885
3886 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
3887 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
3888 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
3889 Re-implement to match the ABI as summarized in GCC's
3890 gcc/config/sparc/sparc.c. All callers updated.
3891 (sparc32_store_arguments): Remove assertion.
3892
2f433492
TT
38932018-05-04 Tom Tromey <tom@tromey.com>
3894
3895 * printcmd.c: Don't include tui.h.
3896 (decode_format): Use skip_spaces.
3897
9be2ae8f
TT
38982018-05-04 Tom Tromey <tom@tromey.com>
3899
3900 PR gdb/22619:
3901 * printcmd.c (last_count): New global.
3902 (x_command): Use saved count when repeating.
3903
f0b3976b
TT
39042018-05-04 Tom Tromey <tom@tromey.com>
3905
3906 * nto-procfs.c (do_closedir_cleanup): Remove.
3907 (procfs_pidlist): Use gdb_dir_up.
3908 * procfs.c (do_closedir_cleanup): Remove.
3909 (proc_update_threads): Use gdb_dir_up.
3910 * common/filestuff.h (struct gdb_dir_deleter): New.
3911 (gdb_dir_up): New typedef.
3912
862d101a
TT
39132018-05-04 Tom Tromey <tom@tromey.com>
3914
3915 * ada-lang.c (print_mention_exception): Use std::string.
3916
cb7de75e
TT
39172018-05-04 Tom Tromey <tom@tromey.com>
3918
3919 * ada-lang.c (create_excep_cond_exprs): Update.
3920 (ada_exception_catchpoint_cond_string): Use std::string.
3921
49d83361
TT
39222018-05-04 Tom Tromey <tom@tromey.com>
3923
3924 * ada-lang.c (xget_renaming_scope): Return std::string.
3925 (old_renaming_is_invisible): Update.
3926
ade72a34
TT
39272018-05-04 Tom Tromey <tom@tromey.com>
3928
3929 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
3930 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
3931
2be4d7f0
UW
39322018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
3933
3934 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
3935
69b6ecb0
TT
39362018-05-04 Tom Tromey <tom@tromey.com>
3937
3938 * remote.c (remote_query_supported_append): Change type.
3939 (remote_check_symbols): Update.
3940
bf27f0e2
PP
39412018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
3942
3943 PR gdb/11420
3944 * configure.ac: Prepend libpython.
3945 * python/python-config.py: Likewise.
3946 * configure: Regenerate.
3947
4ea17de8
SM
39482018-05-03 Simon Marchi <simon.marchi@ericsson.com>
3949
3950 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
3951
bd732259
PA
39522018-05-03 Pedro Alves <palves@redhat.com>
3953
3954 * s390-linux-nat.c
3955 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
3956 override. Write 'true' instead of '1'.
3957 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
3958 declaration.
3959
d9f719f1
PA
39602018-05-02 Pedro Alves <palves@redhat.com>
3961
3962 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
3963 add_inf_child_target.
3964 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
3965 add_inf_child_target.
3966 * aix-thread.c (aix_thread_target_info): New.
3967 (aix_thread_target) <shortname, longname, doc>: Delete.
3968 <info>: New.
3969 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
3970 add_inf_child_target.
3971 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
3972 add_inf_child_target.
3973 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
3974 add_inf_child_target.
3975 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
3976 add_inf_child_target.
3977 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
3978 add_inf_child_target.
3979 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
3980 add_inf_child_target.
3981 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
3982 add_inf_child_target.
3983 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
3984 add_inf_child_target.
3985 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
3986 add_inf_child_target.
3987 * bfd-target.c (target_bfd_target_info): New.
3988 (target_bfd) <shortname, longname, doc>: Delete.
3989 <info>: New.
3990 * bsd-kvm.c (bsd_kvm_target_info): New.
3991 (bsd_kvm_target) <shortname, longname, doc>: Delete.
3992 <info>: New.
3993 (bsd_kvm_target::open): Rename to ...
3994 (bsd_kvm_target_open): ... this. Adjust.
3995 * bsd-uthread.c (bsd_uthread_target_info): New.
3996 (bsd_uthread_target) <shortname, longname, doc>: Delete.
3997 <info>: New.
3998 * corefile.c (core_file_command): Adjust.
3999 * corelow.c (core_target_info): New.
4000 (core_target) <shortname, longname, doc>: Delete.
4001 <info>: New.
4002 (core_target::open): Rename to ...
4003 (core_target_open): ... this. Adjust.
4004 * ctf.c (ctf_target_info): New.
4005 (ctf_target) <shortname, longname, doc>: Delete.
4006 <info>: New.
4007 (ctf_target::open): Rename to ...
4008 (ctf_target_open): ... this.
4009 (_initialize_ctf): Adjust.
4010 * exec.c (exec_target_info): New.
4011 (exec_target) <shortname, longname, doc>: Delete.
4012 <info>: New.
4013 (exec_target::open): Rename to ...
4014 (exec_target_open): ... this.
4015 * gdbcore.h (core_target_open): Declare.
4016 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
4017 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
4018 add_inf_child_target.
4019 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
4020 add_inf_child_target.
4021 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
4022 add_inf_child_target.
4023 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
4024 add_inf_child_target.
4025 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
4026 add_inf_child_target.
4027 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
4028 add_inf_child_target.
4029 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
4030 add_inf_child_target.
4031 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
4032 add_inf_child_target.
4033 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
4034 add_inf_child_target.
4035 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
4036 add_inf_child_target.
4037 * inf-child.c (inf_child_target_info): New.
4038 (inf_child_target::info): New.
4039 (inf_child_open_target): Remove 'target' parameter. Use
4040 get_native_target instead.
4041 (inf_child_target::open): Delete.
4042 (add_inf_child_target): New.
4043 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
4044 Delete.
4045 <info>: New.
4046 (add_inf_child_target): Declare.
4047 (inf_child_open_target): Declare.
4048 * linux-thread-db.c (thread_db_target_info): New.
4049 (thread_db_target) <shortname, longname, doc>: Delete.
4050 <info>: New.
4051 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
4052 add_inf_child_target.
4053 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
4054 add_inf_child_target.
4055 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
4056 add_inf_child_target.
4057 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
4058 add_inf_child_target.
4059 * make-target-delegates (print_class): Adjust.
4060 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
4061 add_inf_child_target.
4062 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
4063 add_inf_child_target.
4064 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
4065 add_inf_child_target.
4066 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
4067 add_inf_child_target.
4068 * nto-procfs.c (nto_native_target_info): New.
4069 (nto_procfs_target_native) <shortname, longname, doc>:
4070 Delete.
4071 <info>: New.
4072 (nto_procfs_target_info): New.
4073 (nto_procfs_target_procfs) <shortname, longname, doc>:
4074 Delete.
4075 <info>: New.
4076 (init_procfs_targets): Adjust.
4077 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
4078 add_inf_child_target.
4079 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
4080 add_inf_child_target.
4081 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
4082 add_inf_child_target.
4083 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
4084 add_inf_child_target.
4085 * ravenscar-thread.c (ravenscar_target_info): New.
4086 (ravenscar_thread_target) <shortname, longname, doc>:
4087 Delete.
4088 <info>: New.
4089 * record-btrace.c (record_btrace_target_info):
4090 (record_btrace_target) <shortname, longname, doc>: Delete.
4091 <info>: New.
4092 (record_btrace_target::open): Rename to ...
4093 (record_btrace_target_open): ... this. Adjust.
4094 * record-full.c (record_longname, record_doc): New.
4095 (record_full_base_target) <shortname, longname, doc>: Delete.
4096 <info>: New.
4097 (record_full_target_info): New.
4098 (record_full_target): <shortname>: Delete.
4099 <info>: New.
4100 (record_full_core_open_1, record_full_open_1): Update comments.
4101 (record_full_base_target::open): Rename to ...
4102 (record_full_open): ... this.
4103 (cmd_record_full_restore): Update.
4104 (_initialize_record_full): Update.
4105 * remote-sim.c (remote_sim_target_info): New.
4106 (gdbsim_target) <shortname, longname, doc>: Delete.
4107 <info>: New.
4108 (gdbsim_target::open): Rename to ...
4109 (gdbsim_target_open): ... this.
4110 (_initialize_remote_sim): Adjust.
4111 * remote.c (remote_doc): New.
4112 (remote_target_info): New.
4113 (remote_target) <shortname, longname, doc>: Delete.
4114 <info>: New.
4115 (extended_remote_target_info): New.
4116 (extended_remote_target) <shortname, longname, doc>: Delete.
4117 <info>: New.
4118 (remote_target::open_1): Make static. Adjust.
4119 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
4120 * s390-linux-nat.c (_initialize_s390_nat): Use
4121 add_inf_child_target.
4122 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
4123 add_inf_child_target.
4124 * sol-thread.c (thread_db_target_info): New.
4125 (sol_thread_target) <shortname, longname, doc>: Delete.
4126 <info>: New.
4127 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
4128 add_inf_child_target.
4129 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
4130 add_inf_child_target.
4131 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
4132 add_inf_child_target.
4133 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
4134 add_inf_child_target.
4135 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
4136 add_inf_child_target.
4137 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
4138 add_inf_child_target.
4139 * spu-linux-nat.c (_initialize_spu_nat): Use
4140 add_inf_child_target.
4141 * spu-multiarch.c (spu_multiarch_target_info): New.
4142 (spu_multiarch_target) <shortname, longname, doc>: Delete.
4143 <info>: New.
4144 * target-delegates.c: Regenerate.
4145 * target.c: Include <unordered_map>.
4146 (target_ops_p): Delete.
4147 (DEF_VEC_P(target_ops_p)): Delete.
4148 (target_factories): New.
4149 (test_target_info): New.
4150 (test_target_ops::info): New.
4151 (open_target): Adjust to use target_factories.
4152 (add_target_with_completer): Rename to ...
4153 (add_target): ... this. Change prototype. Register target_info
4154 and open callback in target_factories. Register target_info in
4155 command context instead of target_ops.
4156 (add_target): Delete old implementation.
4157 (add_deprecated_target_alias): Change prototype. Adjust.
4158 (the_native_target): New.
4159 (set_native_target, get_native_target): New.
4160 (find_default_run_target): Use the_native_target.
4161 (find_attach_target, find_run_target): Simplify.
4162 (target_ops::open): Delete.
4163 (dummy_target_info): New.
4164 (dummy_target::shortname, dummy_target::longname)
4165 (dummy_target::doc): Delete.
4166 (dummy_target::info): New.
4167 (debug_target::shortname, debug_target::longname)
4168 (debug_target::doc): Delete.
4169 (debug_target::info): New.
4170 * target.h (struct target_info): New.
4171 (target_ops::~target_ops): Add comment.
4172 (target_ops::info): New.
4173 (target_ops::shortname, target_ops::longname, target_ops::doc): No
4174 longer virtual. Implement in terms of target_info.
4175 (set_native_target, get_native_target): Declare.
4176 (target_open_ftype): New.
4177 (add_target, add_target_with_completer)
4178 (add_deprecated_target_alias): Change prototype.
4179 (test_target) <shortname, longname, doc>: Delete.
4180 <info>: New.
4181 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
4182 add_inf_child_target.
4183 * tracefile-tfile.c (tfile_target_info): New.
4184 (tfile_target) <shortname, longname, doc>: Delete.
4185 <info>: New.
4186 (tfile_target::open): Rename to ...
4187 (tfile_target_open): ... this.
4188 (_initialize_tracefile_tfile): Adjust.
4189 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
4190 add_inf_child_target.
4191 * windows-nat.c (_initialize_windows_nat): Use
4192 add_inf_child_target.
4193 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
4194 add_inf_child_target.
4195
135340af
PA
41962018-05-02 Pedro Alves <palves@redhat.com>
4197
4198 * linux-nat.h (linux_nat_target) <low_new_thread,
4199 low_delete_thread, low_new_fork, low_forget_process,
4200 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
4201 New virtual methods.
4202 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
4203 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
4204 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
4205 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
4206 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
4207 Delete.
4208 * linux-fork.c (delete_fork): Adjust to call low method.
4209 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
4210 (linux_nat_new_fork, linux_nat_forget_process_hook)
4211 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
4212 (linux_nat_status_is_event):
4213 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
4214 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
4215 to call low method.
4216 (sigtrap_is_event): Rename to ...
4217 (linux_nat_target::low_status_is_event): ... this.
4218 (linux_nat_set_status_is_event): Delete.
4219 (save_stop_reason, linux_nat_wait_1)
4220 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
4221 low methods.
4222 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
4223 (linux_nat_set_new_fork, linux_nat_set_forget_process)
4224 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
4225 (linux_nat_set_prepare_to_resume): Delete.
4226 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
4227 low virtual methods.
4228 * amd64-linux-nat.c: Likewise.
4229 * arm-linux-nat.c: Likewise.
4230 * i386-linux-nat.c: Likewise.
4231 * ia64-linux-nat.c: Likewise.
4232 * mips-linux-nat.c: Likewise.
4233 * ppc-linux-nat.c: Likewise.
4234 * s390-linux-nat.c: Likewise.
4235 * sparc64-linux-nat.c: Likewise.
4236 * x86-linux-nat.c: Likewise.
4237 * x86-linux-nat.h: Include "nat/x86-linux.h".
4238 (x86_linux_nat_target) <low_new_fork, low_forget_process,
4239 low_prepare_to_resume, low_new_thread, low_delete_thread>:
4240 Override methods.
4241
57810aa7
PA
42422018-05-02 Pedro Alves <palves@redhat.com>
4243
4244 * target.h (target_ops)
4245 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
4246 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
4247 stopped_by_watchpoint, have_continuable_watchpoint,
4248 stopped_data_address, watchpoint_addr_within_range,
4249 can_accel_watchpoint_condition, can_run, thread_alive,
4250 has_all_memory, has_memory, has_stack, has_registers,
4251 has_execution, can_async_p, is_async_p, supports_non_stop,
4252 always_non_stop_p, can_execute_reverse, supports_multi_process,
4253 supports_enable_disable_tracepoint,
4254 supports_disable_randomization, supports_string_tracing,
4255 supports_evaluation_of_breakpoint_conditions,
4256 can_run_breakpoint_commands, filesystem_is_local,
4257 can_download_tracepoint, get_trace_state_variable_value,
4258 set_trace_notes, get_tib_address, use_agent, can_use_agent,
4259 record_is_replaying, record_will_replay,
4260 augmented_libraries_svr4_read>: Adjust to return bool.
4261 * aarch64-linux-nat.c: All implementations adjusted.
4262 * aix-thread.c: All implementations adjusted.
4263 * arm-linux-nat.c: All implementations adjusted.
4264 * breakpoint.c: All implementations adjusted.
4265 * bsd-kvm.c: All implementations adjusted.
4266 * bsd-uthread.c: All implementations adjusted.
4267 * corelow.c: All implementations adjusted.
4268 * ctf.c: All implementations adjusted.
4269 * darwin-nat.c: All implementations adjusted.
4270 * darwin-nat.h: All implementations adjusted.
4271 * exec.c: All implementations adjusted.
4272 * fbsd-nat.c: All implementations adjusted.
4273 * fbsd-nat.h: All implementations adjusted.
4274 * gnu-nat.c: All implementations adjusted.
4275 * gnu-nat.h: All implementations adjusted.
4276 * go32-nat.c: All implementations adjusted.
4277 * ia64-linux-nat.c: All implementations adjusted.
4278 * inf-child.c: All implementations adjusted.
4279 * inf-child.h: All implementations adjusted.
4280 * inf-ptrace.c: All implementations adjusted.
4281 * inf-ptrace.h: All implementations adjusted.
4282 * linux-nat.c: All implementations adjusted.
4283 * linux-nat.h: All implementations adjusted.
4284 * mips-linux-nat.c: All implementations adjusted.
4285 * nto-procfs.c: All implementations adjusted.
4286 * ppc-linux-nat.c: All implementations adjusted.
4287 * procfs.c: All implementations adjusted.
4288 * ravenscar-thread.c: All implementations adjusted.
4289 * record-btrace.c: All implementations adjusted.
4290 * record-full.c: All implementations adjusted.
4291 * remote-sim.c: All implementations adjusted.
4292 * remote.c: All implementations adjusted.
4293 * s390-linux-nat.c: All implementations adjusted.
4294 * sol-thread.c: All implementations adjusted.
4295 * spu-multiarch.c: All implementations adjusted.
4296 * target-delegates.c: All implementations adjusted.
4297 * target.c: All implementations adjusted.
4298 * target.h: All implementations adjusted.
4299 * tracefile-tfile.c: All implementations adjusted.
4300 * tracefile.c: All implementations adjusted.
4301 * tracefile.h: All implementations adjusted.
4302 * windows-nat.c: All implementations adjusted.
4303 * x86-linux-nat.h: All implementations adjusted.
4304 * x86-nat.h: All implementations adjusted.
4305
ad6a4e2d
PA
43062018-05-02 Pedro Alves <palves@redhat.com>
4307
4308 * make-target-delegates (scan_target_h): Don't trim lines here.
4309 Replace sequences of tabs and/or whitespace with a single
4310 whitespace.
4311 (top level, parsing methods): Trim each line before processing it
4312 here.
4313
f6ac5f3d
PA
43142018-05-02 Pedro Alves <palves@redhat.com>
4315 John Baldwin <jhb@freebsd.org>
4316
4317 * target.h (enum strata) <debug_stratum>: New.
4318 (struct target_ops) <all delegation methods>: Replace by C++
4319 virtual methods, and drop "to_" prefix. All references updated
4320 throughout.
4321 <to_shortname, to_longname, to_doc, to_data,
4322 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
4323 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
4324 virtual methods. All references updated throughout.
4325 <can_attach, supports_terminal_ours, can_create_inferior,
4326 get_thread_control_capabilities, attach_no_wait>: New
4327 virtual methods.
4328 <insert_breakpoint, remove_breakpoint>: Now
4329 TARGET_DEFAULT_NORETURN methods.
4330 <info_proc>: Now returns bool.
4331 <to_magic>: Delete.
4332 (OPS_MAGIC): Delete.
4333 (current_target): Delete. All references replaced by references
4334 to ...
4335 (target_stack): ... this. New.
4336 (target_shortname, target_longname): Adjust.
4337 (target_can_run): Now a function declaration.
4338 (default_child_has_all_memory, default_child_has_memory)
4339 (default_child_has_stack, default_child_has_registers)
4340 (default_child_has_execution): Remove target_ops parameter.
4341 (complete_target_initialization): Delete.
4342 (memory_breakpoint_target): New template class.
4343 (test_target_ops): Refactor as a C++ class with virtual methods.
4344 * make-target-delegates (NAME_PART): Tighten.
4345 (POINTER_PART, CP_SYMBOL): New.
4346 (SIMPLE_RETURN_PART): Reimplement.
4347 (VEC_RETURN_PART): Expect less.
4348 (RETURN_PART, VIRTUAL_PART): New.
4349 (METHOD): Adjust to C++ virtual methods.
4350 (scan_target_h): Remove reference to C99.
4351 (dname): Output "target_ops::" prefix.
4352 (write_function_header): Adjust to output a C++ class method.
4353 (write_declaration): New.
4354 (write_delegator): Adjust to output a C++ class method.
4355 (tdname): Output "dummy_target::" prefix.
4356 (write_tdefault, write_debugmethod): Adjust to output a C++ class
4357 method.
4358 (tdefault_names, debug_names): Delete.
4359 (return_types, tdefaults, styles, argtypes_array): New.
4360 (top level): All methods are delegators.
4361 (print_class): New.
4362 (top level): Print dummy_target and debug_target classes.
4363 * target-delegates.c: Regenerate.
4364 * target-debug.h (target_debug_print_enum_info_proc_what)
4365 (target_debug_print_thread_control_capabilities)
4366 (target_debug_print_thread_info_p): New.
4367 * target.c (dummy_target): Delete.
4368 (the_dummy_target, the_debug_target): New.
4369 (target_stack): Now extern.
4370 (set_targetdebug): Push/unpush debug target.
4371 (default_child_has_all_memory, default_child_has_memory)
4372 (default_child_has_stack, default_child_has_registers)
4373 (default_child_has_execution): Remove target_ops parameter.
4374 (complete_target_initialization): Delete.
4375 (add_target_with_completer): No longer call
4376 complete_target_initialization.
4377 (target_supports_terminal_ours): Use regular delegation.
4378 (update_current_target): Delete.
4379 (push_target): No longer check magic number. Don't call
4380 update_current_target.
4381 (unpush_target): Don't call update_current_target.
4382 (target_is_pushed): No longer check magic number.
4383 (target_require_runnable): Skip for all stratums over
4384 process_stratum.
4385 (target_ops::info_proc): New.
4386 (target_info_proc): Use find_target_at and
4387 find_default_run_target.
4388 (target_supports_disable_randomization): Use regular delegation.
4389 (target_get_osdata): Use find_target_at.
4390 (target_ops::open, target_ops::close, target_ops::can_attach)
4391 (target_ops::attach, target_ops::can_create_inferior)
4392 (target_ops::create_inferior, target_ops::can_run)
4393 (target_can_run): New.
4394 (default_fileio_target): Use regular delegation.
4395 (target_ops::fileio_open, target_ops::fileio_pwrite)
4396 (target_ops::fileio_pread, target_ops::fileio_fstat)
4397 (target_ops::fileio_close, target_ops::fileio_unlink)
4398 (target_ops::fileio_readlink): New.
4399 (target_fileio_open_1, target_fileio_unlink)
4400 (target_fileio_readlink): Always call the target method. Handle
4401 FILEIO_ENOSYS.
4402 (return_zero, return_zero_has_execution): Delete.
4403 (init_dummy_target): Delete.
4404 (dummy_target::dummy_target, dummy_target::shortname)
4405 (dummy_target::longname, dummy_target::doc)
4406 (debug_target::debug_target, debug_target::shortname)
4407 (debug_target::longname, debug_target::doc): New.
4408 (target_supports_delete_record): Use regular delegation.
4409 (setup_target_debug): Delete.
4410 (maintenance_print_target_stack): Skip debug_stratum.
4411 (initialize_targets): Instantiate the_dummy_target and
4412 the_debug_target.
4413 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
4414 use target_stack.
4415 (target_auxv_search, fprint_target_auxv): Adjust.
4416 (info_auxv_command): Adjust to use target_stack.
4417 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
4418 * exceptions.c (print_flush): Handle a NULL target_stack.
4419 * regcache.c (target_ops_no_register): Refactor as class with
4420 virtual methods.
4421
4422 * exec.c (exec_target): New class.
4423 (exec_ops): Now an exec_target.
4424 (exec_open, exec_close_1, exec_get_section_table)
4425 (exec_xfer_partial, exec_files_info, exec_has_memory)
4426 (exec_make_note_section): Refactor as exec_target methods.
4427 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
4428 Delete.
4429 (exec_target::find_memory_regions): New.
4430 (_initialize_exec): Don't call init_exec_ops.
4431 * gdbcore.h (exec_file_clear): Delete.
4432
4433 * corefile.c (core_target): Delete.
4434 (core_file_command): Adjust.
4435 * corelow.c (core_target): New class.
4436 (the_core_target): New.
4437 (core_close): Remove target_ops parameter.
4438 (core_close_cleanup): Adjust.
4439 (core_target::close): New.
4440 (core_open, core_detach, get_core_registers, core_files_info)
4441 (core_xfer_partial, core_thread_alive, core_read_description)
4442 (core_pid_to_str, core_thread_name, core_has_memory)
4443 (core_has_stack, core_has_registers, core_info_proc): Rework as
4444 core_target methods.
4445 (ignore, core_remove_breakpoint, init_core_ops): Delete.
4446 (_initialize_corelow): Initialize the_core_target.
4447 * gdbcore.h (core_target): Delete.
4448 (the_core_target): New.
4449
4450 * ctf.c: (ctf_target): New class.
4451 (ctf_ops): Now a ctf_target.
4452 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
4453 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
4454 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
4455 methods.
4456 (init_ctf_ops): Delete.
4457 (_initialize_ctf): Don't call it.
4458 * tracefile-tfile.c (tfile_target): New class.
4459 (tfile_ops): Now a tfile_target.
4460 (tfile_open, tfile_close, tfile_files_info)
4461 (tfile_get_tracepoint_status, tfile_trace_find)
4462 (tfile_fetch_registers, tfile_xfer_partial)
4463 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
4464 Refactor as tfile_target methods.
4465 (tfile_xfer_partial_features): Remove target_ops parameter.
4466 (init_tfile_ops): Delete.
4467 (_initialize_tracefile_tfile): Don't call it.
4468 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
4469 (tracefile_has_stack, tracefile_has_registers)
4470 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
4471 tracefile_target methods.
4472 (init_tracefile_ops): Delete.
4473 (tracefile_target::tracefile_target): New.
4474 * tracefile.h: Include "target.h".
4475 (tracefile_target): New class.
4476 (init_tracefile_ops): Delete.
4477
4478 * spu-multiarch.c (spu_multiarch_target): New class.
4479 (spu_ops): Now a spu_multiarch_target.
4480 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
4481 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
4482 (spu_search_memory, spu_mourn_inferior): Refactor as
4483 spu_multiarch_target methods.
4484 (init_spu_ops): Delete.
4485 (_initialize_spu_multiarch): Remove references to init_spu_ops,
4486 complete_target_initialization.
4487
4488 * ravenscar-thread.c (ravenscar_thread_target): New class.
4489 (ravenscar_ops): Now a ravenscar_thread_target.
4490 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
4491 (ravenscar_thread_alive, ravenscar_pid_to_str)
4492 (ravenscar_fetch_registers, ravenscar_store_registers)
4493 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
4494 (ravenscar_stopped_by_hw_breakpoint)
4495 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
4496 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
4497 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
4498 methods.
4499 (init_ravenscar_thread_ops): Delete.
4500 (_initialize_ravenscar): Remove references to
4501 init_ravenscar_thread_ops and complete_target_initialization.
4502
4503 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
4504 (bsd_uthread_target): New class.
4505 (bsd_uthread_ops): Now a bsd_uthread_target.
4506 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
4507 (bsd_uthread_close, bsd_uthread_mourn_inferior)
4508 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
4509 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
4510 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
4511 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
4512 (bsd_uthread_target): Delete function.
4513 (_initialize_bsd_uthread): Remove reference to
4514 complete_target_initialization.
4515
4516 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
4517 (target_bfd): ... this new class.
4518 (target_bfd_xfer_partial, target_bfd_get_section_table)
4519 (target_bfd_close): Refactor as target_bfd methods.
4520 (target_bfd::~target_bfd): New.
4521 (target_bfd_reopen): Adjust.
4522 (target_bfd::close): New.
4523
4524 * record-btrace.c (record_btrace_target): New class.
4525 (record_btrace_ops): Now a record_btrace_target.
4526 (record_btrace_open, record_btrace_stop_recording)
4527 (record_btrace_disconnect, record_btrace_close)
4528 (record_btrace_async, record_btrace_info)
4529 (record_btrace_insn_history, record_btrace_insn_history_range)
4530 (record_btrace_insn_history_from, record_btrace_call_history)
4531 (record_btrace_call_history_range)
4532 (record_btrace_call_history_from, record_btrace_record_method)
4533 (record_btrace_is_replaying, record_btrace_will_replay)
4534 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
4535 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
4536 (record_btrace_store_registers, record_btrace_prepare_to_store)
4537 (record_btrace_to_get_unwinder)
4538 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
4539 (record_btrace_commit_resume, record_btrace_wait)
4540 (record_btrace_stop, record_btrace_can_execute_reverse)
4541 (record_btrace_stopped_by_sw_breakpoint)
4542 (record_btrace_supports_stopped_by_sw_breakpoint)
4543 (record_btrace_stopped_by_hw_breakpoint)
4544 (record_btrace_supports_stopped_by_hw_breakpoint)
4545 (record_btrace_update_thread_list, record_btrace_thread_alive)
4546 (record_btrace_goto_begin, record_btrace_goto_end)
4547 (record_btrace_goto, record_btrace_stop_replaying_all)
4548 (record_btrace_execution_direction)
4549 (record_btrace_prepare_to_generate_core)
4550 (record_btrace_done_generating_core): Refactor as
4551 record_btrace_target methods.
4552 (init_record_btrace_ops): Delete.
4553 (_initialize_record_btrace): Remove reference to
4554 init_record_btrace_ops.
4555 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
4556 the execution_direction global.
4557 (record_full_base_target, record_full_target)
4558 (record_full_core_target): New classes.
4559 (record_full_ops): Now a record_full_target.
4560 (record_full_core_ops): Now a record_full_core_target.
4561 (record_full_target::detach, record_full_target::disconnect)
4562 (record_full_core_target::disconnect)
4563 (record_full_target::mourn_inferior, record_full_target::kill):
4564 New.
4565 (record_full_open, record_full_close, record_full_async): Refactor
4566 as methods of the record_full_base_target class.
4567 (record_full_resume, record_full_commit_resume): Refactor
4568 as methods of the record_full_target class.
4569 (record_full_wait, record_full_stopped_by_watchpoint)
4570 (record_full_stopped_data_address)
4571 (record_full_stopped_by_sw_breakpoint)
4572 (record_full_supports_stopped_by_sw_breakpoint)
4573 (record_full_stopped_by_hw_breakpoint)
4574 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
4575 methods of the record_full_base_target class.
4576 (record_full_store_registers, record_full_xfer_partial)
4577 (record_full_insert_breakpoint, record_full_remove_breakpoint):
4578 Refactor as methods of the record_full_target class.
4579 (record_full_can_execute_reverse, record_full_get_bookmark)
4580 (record_full_goto_bookmark, record_full_execution_direction)
4581 (record_full_record_method, record_full_info, record_full_delete)
4582 (record_full_is_replaying, record_full_will_replay)
4583 (record_full_goto_begin, record_full_goto_end, record_full_goto)
4584 (record_full_stop_replaying): Refactor as methods of the
4585 record_full_base_target class.
4586 (record_full_core_resume, record_full_core_kill)
4587 (record_full_core_fetch_registers)
4588 (record_full_core_prepare_to_store)
4589 (record_full_core_store_registers, record_full_core_xfer_partial)
4590 (record_full_core_insert_breakpoint)
4591 (record_full_core_remove_breakpoint)
4592 (record_full_core_has_execution): Refactor
4593 as methods of the record_full_core_target class.
4594 (record_full_base_target::supports_delete_record): New.
4595 (init_record_full_ops): Delete.
4596 (init_record_full_core_ops): Delete.
4597 (record_full_save): Refactor as method of the
4598 record_full_base_target class.
4599 (_initialize_record_full): Remove references to
4600 init_record_full_ops and init_record_full_core_ops.
4601
4602 * remote.c (remote_target, extended_remote_target): New classes.
4603 (remote_ops): Now a remote_target.
4604 (extended_remote_ops): Now an extended_remote_target.
4605 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
4606 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
4607 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
4608 (remote_pass_signals, remote_set_syscall_catchpoint)
4609 (remote_program_signals, )
4610 (remote_thread_always_alive): Remove target_ops parameter.
4611 (remote_thread_alive, remote_thread_name)
4612 (remote_update_thread_list, remote_threads_extra_info)
4613 (remote_static_tracepoint_marker_at)
4614 (remote_static_tracepoint_markers_by_strid)
4615 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
4616 (remote_open): Refactor as methods of remote_target.
4617 (extended_remote_open, extended_remote_detach)
4618 (extended_remote_attach, extended_remote_post_attach):
4619 (extended_remote_supports_disable_randomization)
4620 (extended_remote_create_inferior): : Refactor as method of
4621 extended_remote_target.
4622 (remote_set_permissions, remote_open_1, remote_detach)
4623 (remote_follow_fork, remote_follow_exec, remote_disconnect)
4624 (remote_resume, remote_commit_resume, remote_stop)
4625 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
4626 (remote_terminal_ours, remote_wait, remote_fetch_registers)
4627 (remote_prepare_to_store, remote_store_registers)
4628 (remote_flash_erase, remote_flash_done, remote_files_info)
4629 (remote_kill, remote_mourn, remote_insert_breakpoint)
4630 (remote_remove_breakpoint, remote_insert_watchpoint)
4631 (remote_watchpoint_addr_within_range)
4632 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
4633 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
4634 (remote_supports_stopped_by_sw_breakpoint)
4635 (remote_stopped_by_hw_breakpoint)
4636 (remote_supports_stopped_by_hw_breakpoint)
4637 (remote_stopped_by_watchpoint, remote_stopped_data_address)
4638 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
4639 (remote_verify_memory): Refactor as methods of remote_target.
4640 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
4641 parameter.
4642 (remote_xfer_partial, remote_get_memory_xfer_limit)
4643 (remote_search_memory, remote_rcmd, remote_memory_map)
4644 (remote_pid_to_str, remote_get_thread_local_address)
4645 (remote_get_tib_address, remote_read_description): Refactor as
4646 methods of remote_target.
4647 (remote_target::fileio_open, remote_target::fileio_pwrite)
4648 (remote_target::fileio_pread, remote_target::fileio_close): New.
4649 (remote_hostio_readlink, remote_hostio_fstat)
4650 (remote_filesystem_is_local, remote_can_execute_reverse)
4651 (remote_supports_non_stop, remote_supports_disable_randomization)
4652 (remote_supports_multi_process, remote_supports_cond_breakpoints)
4653 (remote_supports_enable_disable_tracepoint)
4654 (remote_supports_string_tracing)
4655 (remote_can_run_breakpoint_commands, remote_trace_init)
4656 (remote_download_tracepoint, remote_can_download_tracepoint)
4657 (remote_download_trace_state_variable, remote_enable_tracepoint)
4658 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
4659 (remote_trace_start, remote_get_trace_status)
4660 (remote_get_tracepoint_status, remote_trace_stop)
4661 (remote_trace_find, remote_get_trace_state_variable_value)
4662 (remote_save_trace_data, remote_get_raw_trace_data)
4663 (remote_set_disconnected_tracing, remote_core_of_thread)
4664 (remote_set_circular_trace_buffer, remote_traceframe_info)
4665 (remote_get_min_fast_tracepoint_insn_len)
4666 (remote_set_trace_buffer_size, remote_set_trace_notes)
4667 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
4668 (remote_disable_btrace, remote_teardown_btrace)
4669 (remote_read_btrace, remote_btrace_conf)
4670 (remote_augmented_libraries_svr4_read, remote_load)
4671 (remote_pid_to_exec_file, remote_can_do_single_step)
4672 (remote_execution_direction, remote_thread_handle_to_thread_info):
4673 Refactor as methods of remote_target.
4674 (init_remote_ops, init_extended_remote_ops): Delete.
4675 (remote_can_async_p, remote_is_async_p, remote_async)
4676 (remote_thread_events, remote_upload_tracepoints)
4677 (remote_upload_trace_state_variables): Refactor as methods of
4678 remote_target.
4679 (_initialize_remote): Remove references to init_remote_ops and
4680 init_extended_remote_ops.
4681
4682 * remote-sim.c (gdbsim_target): New class.
4683 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
4684 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
4685 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
4686 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
4687 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
4688 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
4689 Refactor as methods of gdbsim_target.
4690 (gdbsim_ops): Now a gdbsim_target.
4691 (init_gdbsim_ops): Delete.
4692 (gdbsim_cntrl_c): Adjust.
4693 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
4694
4695 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
4696 (the_amd64_linux_nat_target): New.
4697 (amd64_linux_fetch_inferior_registers)
4698 (amd64_linux_store_inferior_registers): Refactor as methods of
4699 amd64_linux_nat_target.
4700 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
4701 * i386-linux-nat.c: Don't include "linux-nat.h".
4702 (i386_linux_nat_target): New class.
4703 (the_i386_linux_nat_target): New.
4704 (i386_linux_fetch_inferior_registers)
4705 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
4706 as methods of i386_linux_nat_target.
4707 (_initialize_i386_linux_nat): Adjust. Set linux_target.
4708 * inf-child.c (inf_child_ops): Delete.
4709 (inf_child_fetch_inferior_registers)
4710 (inf_child_store_inferior_registers): Delete.
4711 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
4712 methods of inf_child_target.
4713 (inf_child_target::supports_terminal_ours)
4714 (inf_child_target::terminal_init)
4715 (inf_child_target::terminal_inferior)
4716 (inf_child_target::terminal_ours_for_output)
4717 (inf_child_target::terminal_ours, inf_child_target::interrupt)
4718 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
4719 New.
4720 (inf_child_open, inf_child_disconnect, inf_child_close)
4721 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
4722 (inf_child_post_startup_inferior, inf_child_can_run)
4723 (inf_child_pid_to_exec_file): Refactor as methods of
4724 inf_child_target.
4725 (inf_child_follow_fork): Delete.
4726 (inf_child_target::can_create_inferior)
4727 (inf_child_target::can_attach): New.
4728 (inf_child_target::has_all_memory, inf_child_target::has_memory)
4729 (inf_child_target::has_stack, inf_child_target::has_registers)
4730 (inf_child_target::has_execution): New.
4731 (inf_child_fileio_open, inf_child_fileio_pwrite)
4732 (inf_child_fileio_pread, inf_child_fileio_fstat)
4733 (inf_child_fileio_close, inf_child_fileio_unlink)
4734 (inf_child_fileio_readlink, inf_child_use_agent)
4735 (inf_child_can_use_agent): Refactor as methods of
4736 inf_child_target.
4737 (return_zero, inf_child_target): Delete.
4738 (inf_child_target::inf_child_target): New.
4739 * inf-child.h: Include "target.h".
4740 (inf_child_target): Delete function prototype.
4741 (inf_child_target): New class.
4742 (inf_child_open_target, inf_child_mourn_inferior)
4743 (inf_child_maybe_unpush_target): Delete.
4744 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
4745 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
4746 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
4747 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
4748 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
4749 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
4750 (inf_ptrace_wait, inf_ptrace_xfer_partial)
4751 (inf_ptrace_thread_alive, inf_ptrace_files_info)
4752 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
4753 methods of inf_ptrace_target.
4754 (inf_ptrace_target): Delete function.
4755 * inf-ptrace.h: Include "inf-child.h".
4756 (inf_ptrace_target): Delete function declaration.
4757 (inf_ptrace_target): New class.
4758 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
4759 * linux-nat.c (linux_target): New.
4760 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
4761 (linux_nat_target::~linux_nat_target): New.
4762 (linux_child_post_attach, linux_child_post_startup_inferior)
4763 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
4764 (linux_child_remove_fork_catchpoint)
4765 (linux_child_insert_vfork_catchpoint)
4766 (linux_child_remove_vfork_catchpoint)
4767 (linux_child_insert_exec_catchpoint)
4768 (linux_child_remove_exec_catchpoint)
4769 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
4770 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
4771 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
4772 (linux_nat_stopped_data_address)
4773 (linux_nat_stopped_by_sw_breakpoint)
4774 (linux_nat_supports_stopped_by_sw_breakpoint)
4775 (linux_nat_stopped_by_hw_breakpoint)
4776 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
4777 (linux_nat_kill, linux_nat_mourn_inferior)
4778 (linux_nat_xfer_partial, linux_nat_thread_alive)
4779 (linux_nat_update_thread_list, linux_nat_pid_to_str)
4780 (linux_nat_thread_name, linux_child_pid_to_exec_file)
4781 (linux_child_static_tracepoint_markers_by_strid)
4782 (linux_nat_is_async_p, linux_nat_can_async_p)
4783 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
4784 (linux_nat_supports_multi_process)
4785 (linux_nat_supports_disable_randomization, linux_nat_async)
4786 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
4787 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
4788 (linux_nat_fileio_open, linux_nat_fileio_readlink)
4789 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
4790 methods of linux_nat_target.
4791 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
4792 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
4793 parameter.
4794 (check_stopped_by_watchpoint): Adjust.
4795 (linux_xfer_partial): Delete.
4796 (linux_target_install_ops, linux_target, linux_nat_add_target):
4797 Delete.
4798 (linux_nat_target::linux_nat_target): New.
4799 * linux-nat.h: Include "inf-ptrace.h".
4800 (linux_nat_target): New.
4801 (linux_target, linux_target_install_ops, linux_nat_add_target):
4802 Delete function declarations.
4803 (linux_target): Declare global.
4804 * linux-thread-db.c (thread_db_target): New.
4805 (thread_db_target::thread_db_target): New.
4806 (thread_db_ops): Delete.
4807 (the_thread_db_target): New.
4808 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
4809 (thread_db_update_thread_list, thread_db_pid_to_str)
4810 (thread_db_extra_thread_info)
4811 (thread_db_thread_handle_to_thread_info)
4812 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
4813 (thread_db_resume): Refactor as methods of thread_db_target.
4814 (init_thread_db_ops): Delete.
4815 (_initialize_thread_db): Remove reference to init_thread_db_ops.
4816 * x86-linux-nat.c: Don't include "linux-nat.h".
4817 (super_post_startup_inferior): Delete.
4818 (x86_linux_nat_target::~x86_linux_nat_target): New.
4819 (x86_linux_child_post_startup_inferior)
4820 (x86_linux_read_description, x86_linux_enable_btrace)
4821 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
4822 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
4823 methods of x86_linux_nat_target.
4824 (x86_linux_create_target): Delete. Bits folded ...
4825 (x86_linux_add_target): ... here. Now takes a linux_nat_target
4826 pointer.
4827 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
4828 (x86_linux_nat_target): New class.
4829 (x86_linux_create_target): Delete.
4830 (x86_linux_add_target): Now takes a linux_nat_target pointer.
4831 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
4832 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
4833 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
4834 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
4835 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
4836 make extern.
4837 (x86_use_watchpoints): Delete.
4838 * x86-nat.h: Include "breakpoint.h" and "target.h".
4839 (x86_use_watchpoints): Delete.
4840 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
4841 (x86_stopped_by_watchpoint, x86_stopped_data_address)
4842 (x86_insert_watchpoint, x86_remove_watchpoint)
4843 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
4844 (x86_stopped_by_hw_breakpoint): New declarations.
4845 (x86_nat_target): New template class.
4846
4847 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
4848 (the_ppc_linux_nat_target): New.
4849 (ppc_linux_fetch_inferior_registers)
4850 (ppc_linux_can_use_hw_breakpoint)
4851 (ppc_linux_region_ok_for_hw_watchpoint)
4852 (ppc_linux_ranged_break_num_registers)
4853 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
4854 (ppc_linux_insert_mask_watchpoint)
4855 (ppc_linux_remove_mask_watchpoint)
4856 (ppc_linux_can_accel_watchpoint_condition)
4857 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
4858 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
4859 (ppc_linux_watchpoint_addr_within_range)
4860 (ppc_linux_masked_watch_num_registers)
4861 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
4862 (ppc_linux_read_description): Refactor as methods of
4863 ppc_linux_nat_target.
4864 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
4865
4866 * procfs.c (procfs_xfer_partial): Delete forward declaration.
4867 (procfs_target): New class.
4868 (the_procfs_target): New.
4869 (procfs_target): Delete function.
4870 (procfs_auxv_parse, procfs_attach, procfs_detach)
4871 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
4872 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
4873 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
4874 (procfs_create_inferior, procfs_update_thread_list)
4875 (procfs_thread_alive, procfs_pid_to_str)
4876 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
4877 (procfs_stopped_data_address, procfs_insert_watchpoint)
4878 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
4879 (proc_find_memory_regions, procfs_info_proc)
4880 (procfs_make_note_section): Refactor as methods of procfs_target.
4881 (_initialize_procfs): Adjust.
4882 * sol-thread.c (sol_thread_target): New class.
4883 (sol_thread_ops): Now a sol_thread_target.
4884 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
4885 (sol_thread_fetch_registers, sol_thread_store_registers)
4886 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
4887 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
4888 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
4889 (init_sol_thread_ops): Delete.
4890 (_initialize_sol_thread): Adjust. Remove references to
4891 init_sol_thread_ops and complete_target_initialization.
4892
4893 * windows-nat.c (windows_nat_target): New class.
4894 (windows_fetch_inferior_registers)
4895 (windows_store_inferior_registers, windows_resume, windows_wait)
4896 (windows_attach, windows_detach, windows_pid_to_exec_file)
4897 (windows_files_info, windows_create_inferior)
4898 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
4899 (windows_close, windows_pid_to_str, windows_xfer_partial)
4900 (windows_get_tib_address, windows_get_ada_task_ptid)
4901 (windows_thread_name, windows_thread_alive): Refactor as
4902 windows_nat_target methods.
4903 (do_initial_windows_stuff): Adjust.
4904 (windows_target): Delete function.
4905 (_initialize_windows_nat): Adjust.
4906
4907 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
4908 (darwin_mourn_inferior, darwin_kill_inferior)
4909 (darwin_create_inferior, darwin_attach, darwin_detach)
4910 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
4911 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
4912 (darwin_supports_multi_process): Refactor as darwin_nat_target
4913 methods.
4914 (darwin_resume_to, darwin_files_info): Delete.
4915 (_initialize_darwin_inferior): Rename to ...
4916 (_initialize_darwin_nat): ... this. Adjust to C++ification.
4917 * darwin-nat.h: Include "inf-child.h".
4918 (darwin_nat_target): New class.
4919 (darwin_complete_target): Delete.
4920 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
4921 (darwin_target): New.
4922 (i386_darwin_fetch_inferior_registers)
4923 (i386_darwin_store_inferior_registers): Refactor as methods of
4924 darwin_nat_target.
4925 (darwin_complete_target): Delete, with ...
4926 (_initialize_i386_darwin_nat): ... bits factored out here.
4927
4928 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
4929 (the_alpha_linux_nat_target): New.
4930 (alpha_linux_register_u_offset): Refactor as
4931 alpha_linux_nat_target method.
4932 (_initialize_alpha_linux_nat): Adjust.
4933 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
4934 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
4935 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
4936 methods of linux_nat_trad_target.
4937 (linux_trad_target): Delete.
4938 * linux-nat-trad.h (linux_trad_target): Delete function.
4939 (linux_nat_trad_target): New class.
4940 * mips-linux-nat.c (mips_linux_nat_target): New class.
4941 (super_fetch_registers, super_store_registers, super_close):
4942 Delete.
4943 (the_mips_linux_nat_target): New.
4944 (mips64_linux_regsets_fetch_registers)
4945 (mips64_linux_regsets_store_registers)
4946 (mips64_linux_fetch_registers, mips64_linux_store_registers)
4947 (mips_linux_register_u_offset, mips_linux_read_description)
4948 (mips_linux_can_use_hw_breakpoint)
4949 (mips_linux_stopped_by_watchpoint)
4950 (mips_linux_stopped_data_address)
4951 (mips_linux_region_ok_for_hw_watchpoint)
4952 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
4953 (mips_linux_close): Refactor as methods of mips_linux_nat.
4954 (_initialize_mips_linux_nat): Adjust to C++ification.
4955
4956 * aix-thread.c (aix_thread_target): New class.
4957 (aix_thread_ops): Now an aix_thread_target.
4958 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
4959 (aix_thread_fetch_registers, aix_thread_store_registers)
4960 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
4961 (aix_thread_thread_alive, aix_thread_pid_to_str)
4962 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
4963 Refactor as methods of aix_thread_target.
4964 (init_aix_thread_ops): Delete.
4965 (_initialize_aix_thread): Remove references to init_aix_thread_ops
4966 and complete_target_initialization.
4967 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
4968 (rs6000_nat_target): New class.
4969 (the_rs6000_nat_target): New.
4970 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
4971 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
4972 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
4973 (super_create_inferior): Delete.
4974 (_initialize_rs6000_nat): Adjust to C++ification.
4975
4976 * arm-linux-nat.c (arm_linux_nat_target): New class.
4977 (the_arm_linux_nat_target): New.
4978 (arm_linux_fetch_inferior_registers)
4979 (arm_linux_store_inferior_registers, arm_linux_read_description)
4980 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
4981 (arm_linux_remove_hw_breakpoint)
4982 (arm_linux_region_ok_for_hw_watchpoint)
4983 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
4984 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
4985 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
4986 arm_linux_nat_target.
4987 (_initialize_arm_linux_nat): Adjust to C++ification.
4988
4989 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
4990 (the_aarch64_linux_nat_target): New.
4991 (aarch64_linux_fetch_inferior_registers)
4992 (aarch64_linux_store_inferior_registers)
4993 (aarch64_linux_child_post_startup_inferior)
4994 (aarch64_linux_read_description)
4995 (aarch64_linux_can_use_hw_breakpoint)
4996 (aarch64_linux_insert_hw_breakpoint)
4997 (aarch64_linux_remove_hw_breakpoint)
4998 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
4999 (aarch64_linux_region_ok_for_hw_watchpoint)
5000 (aarch64_linux_stopped_data_address)
5001 (aarch64_linux_stopped_by_watchpoint)
5002 (aarch64_linux_watchpoint_addr_within_range)
5003 (aarch64_linux_can_do_single_step): Refactor as methods of
5004 aarch64_linux_nat_target.
5005 (super_post_startup_inferior): Delete.
5006 (_initialize_aarch64_linux_nat): Adjust to C++ification.
5007
5008 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
5009 (the_hppa_linux_nat_target): New.
5010 (hppa_linux_fetch_inferior_registers)
5011 (hppa_linux_store_inferior_registers): Refactor as methods of
5012 hppa_linux_nat_target.
5013 (_initialize_hppa_linux_nat): Adjust to C++ification.
5014
5015 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
5016 (the_ia64_linux_nat_target): New.
5017 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
5018 (ia64_linux_stopped_data_address)
5019 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
5020 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
5021 ia64_linux_nat_target methods.
5022 (super_xfer_partial): Delete.
5023 (_initialize_ia64_linux_nat): Adjust to C++ification.
5024
5025 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
5026 (the_m32r_linux_nat_target): New.
5027 (m32r_linux_fetch_inferior_registers)
5028 (m32r_linux_store_inferior_registers): Refactor as
5029 m32r_linux_nat_target methods.
5030 (_initialize_m32r_linux_nat): Adjust to C++ification.
5031
5032 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
5033 (the_m68k_linux_nat_target): New.
5034 (m68k_linux_fetch_inferior_registers)
5035 (m68k_linux_store_inferior_registers): Refactor as
5036 m68k_linux_nat_target methods.
5037 (_initialize_m68k_linux_nat): Adjust to C++ification.
5038
5039 * s390-linux-nat.c (s390_linux_nat_target): New class.
5040 (the_s390_linux_nat_target): New.
5041 (s390_linux_fetch_inferior_registers)
5042 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
5043 (s390_insert_watchpoint, s390_remove_watchpoint)
5044 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
5045 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
5046 (s390_auxv_parse, s390_read_description): Refactor as methods of
5047 s390_linux_nat_target.
5048 (_initialize_s390_nat): Adjust to C++ification.
5049
5050 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
5051 (the_sparc_linux_nat_target): New.
5052 (_initialize_sparc_linux_nat): Adjust to C++ification.
5053 * sparc-nat.c (sparc_fetch_inferior_registers)
5054 (sparc_store_inferior_registers): Remove target_ops parameter.
5055 * sparc-nat.h (sparc_fetch_inferior_registers)
5056 (sparc_store_inferior_registers): Remove target_ops parameter.
5057 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
5058 (the_sparc64_linux_nat_target): New.
5059 (_initialize_sparc64_linux_nat): Adjust to C++ification.
5060
5061 * spu-linux-nat.c (spu_linux_nat_target): New class.
5062 (the_spu_linux_nat_target): New.
5063 (spu_child_post_startup_inferior, spu_child_post_attach)
5064 (spu_child_wait, spu_fetch_inferior_registers)
5065 (spu_store_inferior_registers, spu_xfer_partial)
5066 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
5067 methods.
5068 (_initialize_spu_nat): Adjust to C++ification.
5069
5070 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
5071 (the_tilegx_linux_nat_target): New.
5072 (fetch_inferior_registers, store_inferior_registers):
5073 Refactor as methods.
5074 (_initialize_tile_linux_nat): Adjust to C++ification.
5075
5076 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
5077 (the_xtensa_linux_nat_target): New.
5078 (xtensa_linux_fetch_inferior_registers)
5079 (xtensa_linux_store_inferior_registers): Refactor as
5080 xtensa_linux_nat_target methods.
5081 (_initialize_xtensa_linux_nat): Adjust to C++ification.
5082
5083 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
5084 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
5085 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
5086 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
5087 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
5088 (fbsd_stopped_by_sw_breakpoint)
5089 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
5090 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
5091 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
5092 (fbsd_post_startup_inferior, fbsd_post_attach)
5093 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
5094 (fbsd_set_syscall_catchpoint)
5095 (super_xfer_partial, super_resume, super_wait)
5096 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
5097 (fbsd_handle_debug_trap): Remove target_ops parameter.
5098 (fbsd_nat_add_target): Delete.
5099 * fbsd-nat.h: Include "inf-ptrace.h".
5100 (fbsd_nat_add_target): Delete.
5101 (USE_SIGTRAP_SIGINFO): Define.
5102 (fbsd_nat_target): New class.
5103
5104 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
5105 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
5106 (amd64bsd_target): Delete.
5107 * amd64-bsd-nat.h: New file.
5108 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
5109 "x86-bsd-nat.h".
5110 (amd64_fbsd_nat_target): New class.
5111 (the_amd64_fbsd_nat_target): New.
5112 (amd64fbsd_read_description): Refactor as method of
5113 amd64_fbsd_nat_target.
5114 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
5115 (_initialize_amd64fbsd_nat): Adjust to C++ification.
5116 * amd64-nat.h (amd64bsd_target): Delete function declaration.
5117 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
5118 (i386bsd_store_inferior_registers): Remove target_ops parameter.
5119 (i386bsd_target): Delete.
5120 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
5121 (i386bsd_fetch_inferior_registers)
5122 (i386bsd_store_inferior_registers): Declare.
5123 (i386_bsd_nat_target): New class.
5124 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
5125 (the_i386_fbsd_nat_target): New.
5126 (i386fbsd_resume, i386fbsd_read_description): Refactor as
5127 i386_fbsd_nat_target methods.
5128 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
5129 (_initialize_i386fbsd_nat): Adjust to C++ification.
5130 * x86-bsd-nat.c (super_mourn_inferior): Delete.
5131 (x86bsd_mourn_inferior, x86bsd_target): Delete.
5132 (_initialize_x86_bsd_nat): Adjust to C++ification.
5133 * x86-bsd-nat.h: Include "x86-nat.h".
5134 (x86bsd_target): Delete declaration.
5135 (x86bsd_nat_target): New class.
5136
5137 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
5138 (the_aarch64_fbsd_nat_target): New.
5139 (aarch64_fbsd_fetch_inferior_registers)
5140 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
5141 aarch64_fbsd_nat_target.
5142 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
5143 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
5144 (the_alpha_bsd_nat_target): New.
5145 (alphabsd_fetch_inferior_registers)
5146 (alphabsd_store_inferior_registers): Refactor as
5147 alpha_bsd_nat_target methods.
5148 (_initialize_alphabsd_nat): Refactor as methods of
5149 alpha_bsd_nat_target.
5150 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
5151 (the_amd64_nbsd_nat_target): New.
5152 (_initialize_amd64nbsd_nat): Adjust to C++ification.
5153 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
5154 (the_amd64_obsd_nat_target): New.
5155 (_initialize_amd64obsd_nat): Adjust to C++ification.
5156 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
5157 (the_arm_fbsd_nat_target): New.
5158 (arm_fbsd_fetch_inferior_registers)
5159 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
5160 (_initialize_arm_fbsd_nat): Refactor as methods of
5161 arm_fbsd_nat_target.
5162 (_initialize_arm_fbsd_nat): Adjust to C++ification.
5163 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
5164 (the_arm_netbsd_nat_target): New.
5165 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
5166 arm_netbsd_nat_target.
5167 (_initialize_arm_netbsd_nat): Adjust to C++ification.
5168 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
5169 (the_hppa_nbsd_nat_target): New.
5170 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
5171 hppa_nbsd_nat_target methods.
5172 (_initialize_hppanbsd_nat): Adjust to C++ification.
5173 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
5174 (the_hppa_obsd_nat_target): New.
5175 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
5176 methods of hppa_obsd_nat_target.
5177 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
5178 add_target.
5179 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
5180 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
5181 add_target.
5182 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
5183 (_initialize_i386obsd_nat): Use add_target.
5184 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
5185 (the_m68k_bsd_nat_target): New.
5186 (m68kbsd_fetch_inferior_registers)
5187 (m68kbsd_store_inferior_registers): Refactor as methods of
5188 m68k_bsd_nat_target.
5189 (_initialize_m68kbsd_nat): Adjust to C++ification.
5190 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
5191 (the_mips_fbsd_nat_target): New.
5192 (mips_fbsd_fetch_inferior_registers)
5193 (mips_fbsd_store_inferior_registers): Refactor as methods of
5194 mips_fbsd_nat_target.
5195 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
5196 add_target.
5197 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
5198 (the_mips_nbsd_nat_target): New.
5199 (mipsnbsd_fetch_inferior_registers)
5200 (mipsnbsd_store_inferior_registers): Refactor as methods of
5201 mips_nbsd_nat_target.
5202 (_initialize_mipsnbsd_nat): Adjust to C++ification.
5203 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
5204 (the_mips64_obsd_nat_target): New.
5205 (mips64obsd_fetch_inferior_registers)
5206 (mips64obsd_store_inferior_registers): Refactor as methods of
5207 mips64_obsd_nat_target.
5208 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
5209 add_target.
5210 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
5211 nbsd_nat_target.
5212 * nbsd-nat.h: Include "inf-ptrace.h".
5213 (nbsd_nat_target): New class.
5214 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
5215 (obsd_wait): Refactor as methods of obsd_nat_target.
5216 (obsd_add_target): Delete.
5217 * obsd-nat.h: Include "inf-ptrace.h".
5218 (obsd_nat_target): New class.
5219 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
5220 (the_ppc_fbsd_nat_target): New.
5221 (ppcfbsd_fetch_inferior_registers)
5222 (ppcfbsd_store_inferior_registers): Refactor as methods of
5223 ppc_fbsd_nat_target.
5224 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
5225 add_target.
5226 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
5227 (the_ppc_nbsd_nat_target): New.
5228 (ppcnbsd_fetch_inferior_registers)
5229 (ppcnbsd_store_inferior_registers): Refactor as methods of
5230 ppc_nbsd_nat_target.
5231 (_initialize_ppcnbsd_nat): Adjust to C++ification.
5232 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
5233 (the_ppc_obsd_nat_target): New.
5234 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
5235 methods of ppc_obsd_nat_target.
5236 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
5237 add_target.
5238 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
5239 (the_sh_nbsd_nat_target): New.
5240 (shnbsd_fetch_inferior_registers)
5241 (shnbsd_store_inferior_registers): Refactor as methods of
5242 sh_nbsd_nat_target.
5243 (_initialize_shnbsd_nat): Adjust to C++ification.
5244 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
5245 (inf_ptrace_xfer_partial): Delete.
5246 (sparc_xfer_partial, sparc_target): Delete.
5247 * sparc-nat.h (sparc_fetch_inferior_registers)
5248 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
5249 (sparc_target): Delete function declaration.
5250 (sparc_target): New template class.
5251 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
5252 (_initialize_sparcnbsd_nat): Adjust to C++ification.
5253 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
5254 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
5255 add_target.
5256 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
5257 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
5258 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
5259 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
5260 add_target.
5261 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
5262 (the_vax_bsd_nat_target): New.
5263 (vaxbsd_fetch_inferior_registers)
5264 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
5265 methods.
5266 (_initialize_vaxbsd_nat): Adjust to C++ification.
5267
5268 * bsd-kvm.c (bsd_kvm_target): New class.
5269 (bsd_kvm_ops): Now a bsd_kvm_target.
5270 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
5271 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
5272 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
5273 bsd_kvm_target.
5274 (bsd_kvm_return_one): Delete.
5275 (bsd_kvm_add_target): Adjust to C++ification.
5276
5277 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
5278 (nto_procfs_target_procfs): New classes.
5279 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
5280 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
5281 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
5282 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
5283 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
5284 (procfs_remove_hw_breakpoint, procfs_resume)
5285 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
5286 (procfs_kill_inferior, procfs_store_registers)
5287 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
5288 as methods of nto_procfs_target.
5289 (nto_procfs_ops): Now an nto_procfs_target_procfs.
5290 (nto_native_ops): Delete.
5291 (procfs_open, procfs_native_open): Delete.
5292 (nto_native_ops): Now an nto_procfs_target_native.
5293 (init_procfs_targets): Adjust to C++ification.
5294 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
5295 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
5296 Refactor as methods of nto_procfs_target.
5297
5298 * go32-nat.c (go32_nat_target): New class.
5299 (the_go32_nat_target): New.
5300 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
5301 (go32_store_registers, go32_xfer_partial, go32_files_info)
5302 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
5303 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
5304 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
5305 (go32_pid_to_str): Refactor as methods of go32_nat_target.
5306 (go32_target): Delete.
5307 (_initialize_go32_nat): Adjust to C++ification.
5308
5309 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
5310 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
5311 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
5312 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
5313 gnu_nat_target.
5314 (gnu_target): Delete.
5315 * gnu-nat.h (gnu_target): Delete.
5316 (gnu_nat_target): New class.
5317 * i386-gnu-nat.c (gnu_base_target): New.
5318 (i386_gnu_nat_target): New class.
5319 (the_i386_gnu_nat_target): New.
5320 (_initialize_i386gnu_nat): Adjust to C++ification.
5321
3fffc070
PA
53222018-05-02 Pedro Alves <palves@redhat.com>
5323
5324 * bfd-target.c (target_bfd_xclose): Rename to ...
5325 (target_bfd_close): ... this.
5326 (target_bfd_reopen): Adjust.
5327 * target.c (target_close): Remove references to to_xclose.
5328 * target.h (target_ops::to_xclose): Delete.
5329 (target_ops::to_close): Update comments.
5330
6798487f
PA
53312018-05-02 Pedro Alves <palves@redhat.com>
5332
5333 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
5334 "linux-nat.h".
5335 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
5336 * inf-ptrace.c (inf_ptrace_register_u_offset)
5337 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
5338 (inf_ptrace_store_register, inf_ptrace_store_registers)
5339 (inf_ptrace_trad_target): Move to ...
5340 * linux-nat-trad.c: ... this new file.
5341 * linux-nat-trad.h: New file.
5342 * linux-nat.c (linux_target_install_ops): Make extern.
5343 (linux_trad_target): Delete.
5344 * linux-nat.h (linux_trad_target): Delete declaration.
5345 (linux_target_install_ops): Declare.
5346 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
5347 "linux-nat.h".
5348
c1955e17
PA
53492018-05-02 Pedro Alves <palves@redhat.com>
5350
5351 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
5352 procfs_target/add_target here.
5353 * procfs.c (procfs_target): Make static.
5354 (_initialize_procfs): Call add_target here.
5355 * procfs.h (struct target_ops): Remove forward declaration.
5356 (procfs_target): Remove declaration.
5357 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
5358
b5c8fcb1
PA
53592018-05-02 Pedro Alves <palves@redhat.com>
5360
5361 * procfs.c (procfs_stopped_by_watchpoint)
5362 (procfs_insert_watchpoint, procfs_remove_watchpoint)
5363 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
5364 Forward declare.
5365 (procfs_use_watchpoints): Delete, move contents...
5366 (procfs_target): ... here.
5367 * procfs.h (procfs_use_watchpoints): Delete declaration.
5368 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
5369 procfs_use_watchpoints.
5370 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
5371 procfs_use_watchpoints.
5372
0489430a
TT
53732018-05-02 Tom Tromey <tom@tromey.com>
5374
5375 PR python/20084:
5376 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
5377 and var_zuinteger_unlimited.
5378 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
5379 and PARAM_ZUINTEGER_UNLIMITED.
5380 (set_parameter_value): Handle var_zuinteger and
5381 var_zuinteger_unlimited.
5382 (add_setshow_generic): Likewise.
5383 (parmpy_init): Likewise.
5384
1632f8ba
DR
53852018-04-28 Dan Robertson <danlrobertson89@gmail.com>
5386
5387 PR rust/23124
5388 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
5389 pointer is not null before dereferencing it.
5390
76761936
TT
53912018-04-30 Tom Tromey <tom@tromey.com>
5392
5393 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
5394 is_mi_like_p.
5395
2d33446d
TT
53962018-04-30 Tom Tromey <tom@tromey.com>
5397
5398 * breakpoint.c (mention): Remove use of is_mi_like_p.
5399 (print_mention_ranged_breakpoint): Likewise.
5400 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
5401 of is_mi_like_p.
5402
f3c6abab
TT
54032018-04-30 Tom Tromey <tom@tromey.com>
5404
5405 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
5406
40c03530
TT
54072018-04-30 Tom Tromey <tom@tromey.com>
5408
5409 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
5410 (info_spu_event_command): Remove some uses of is_mi_like_p.
5411
2038b7fd
TT
54122018-04-30 Tom Tromey <tom@tromey.com>
5413
5414 * python/py-framefilter.c (py_print_single_arg)
5415 (enumerate_locals, py_print_args, py_print_frame): Remove some
5416 uses of is_mi_like_p.
5417
4904c3c6
TT
54182018-04-30 Tom Tromey <tom@tromey.com>
5419
5420 * ui-out.c: Update.
5421 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
5422 * ui-out.h (ui_out::is_mi_like_p): Now const.
5423 (ui_out::do_is_mi_like_p): Now const.
5424 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
5425
7c66fffc
TT
54262018-04-30 Tom Tromey <tom@tromey.com>
5427
5428 * varobj.c (varobj_set_visualizer): Use new_reference.
5429 * python/python.c (gdbpy_decode_line): Use new_reference.
5430 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
5431 new_reference.
5432
bbfa6f00
TT
54332018-04-30 Tom Tromey <tom@tromey.com>
5434
5435 * varobj.c (install_new_value): Use new_reference.
5436 * value.h (value_incref): Return void. Swap intro comment with
5437 value_decref.
5438 * value.c (set_value_parent): Use new_reference.
5439 (value_incref): Return void. Update intro comment.
5440 (release_value): Use new_reference.
5441 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
5442
1831a9f9
TT
54432018-04-30 Tom Tromey <tom@tromey.com>
5444
5445 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
5446 * gdb_bfd.h (new_bfd_ref): Remove.
5447 (gdb_bfd_open): Update comment.
5448 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
5449 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
5450 (gdb_bfd_fdopenr): Use new_reference.
5451 * exec.c (exec_file_attach): Use new_reference.
5452
7c1b5f3d
TT
54532018-04-30 Tom Tromey <tom@tromey.com>
5454
5455 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
5456 method.
5457
e11fb955
TT
54582018-04-30 Tom Tromey <tom@tromey.com>
5459
5460 * jit.c (jit_read_code_entry): Use type_align.
5461 * i386-tdep.c (i386_gdbarch_init): Don't call
5462 set_gdbarch_long_long_align_bit.
5463 * gdbarch.sh: Remove long_long_align_bit.
5464 * gdbarch.c, gdbarch.h: Rebuild.
5465 * arc-tdep.c (arc_type_align): New function.
5466 (arc_gdbarch_init): Use arc_type_align. Don't call
5467 set_gdbarch_long_long_align_bit.
5468
2fff16dd
TT
54692018-04-30 Tom Tromey <tom@tromey.com>
5470
5471 * rust-lang.c (rust_type_alignment): Remove.
5472 (rust_composite_type): Use type_align.
5473
6d7bb824
TT
54742018-04-30 Tom Tromey <tom@tromey.com>
5475
5476 * NEWS: Mention Type.align.
5477 * python/py-type.c (typy_get_alignof): New function.
5478 (type_object_getset): Add "alignof".
5479
007e1530
TT
54802018-04-30 Tom Tromey <tom@tromey.com>
5481
5482 PR exp/17095:
5483 * NEWS: Update.
5484 * std-operator.def (UNOP_ALIGNOF): New operator.
5485 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
5486 New.
5487 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
5488 * c-lang.c (c_op_print_tab): Add alignof.
5489 * c-exp.y (ALIGNOF): New token.
5490 (exp): Add "ALIGNOF" production.
5491 (ident_tokens): Add _Alignof and alignof.
5492
2b4424c3
TT
54932018-04-30 Tom Tromey <tom@tromey.com>
5494
5495 * i386-tdep.c (i386_type_align): New function.
5496 (i386_gdbarch_init): Update.
5497 * gdbarch.sh (type_align): New method.
5498 * gdbarch.c, gdbarch.h: Rebuild.
5499 * arch-utils.h (default_type_align): Declare.
5500 * arch-utils.c (default_type_align): New function.
5501 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
5502 (struct type) <align_log2>: New field.
5503 <instance_flags>: Now a bitfield.
5504 (TYPE_RAW_ALIGN): New macro.
5505 (type_align, type_raw_align, set_type_align): Declare.
5506 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
5507 functions.
5508 * dwarf2read.c (quirk_rust_enum): Set type alignment.
5509 (get_alignment, maybe_set_alignment): New functions.
5510 (read_structure_type, read_enumeration_type, read_array_type)
5511 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
5512 (read_subrange_type, read_base_type): Set type alignment.
5513
d33bc52e
SM
55142018-04-30 Simon Marchi <simon.marchi@ericsson.com>
5515
5516 * dwarf2read.c (read_index_from_section): Use bool.
5517
e28b63a9
FG
55182018-04-29 Fabian Groffen <grobian@gentoo.org>
5519
5520 PR gdb/22950
5521 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
5522 with #ifdef.
5523
cd8c76e4
JR
55242018-04-29 John Reiser <jreiser@BitWagon.com>
5525
5526 PR build/22873
5527 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
5528 last step, and do it atomically.
5529
476d250e
AO
55302018-04-27 Alexandre Oliva <aoliva@redhat.com>
5531
5532 * compile/compile-c-types.c (convert_int, convert_float):
5533 Update for C FE v1.
5534
6873858b
TT
55352018-04-27 Tom Tromey <tom@tromey.com>
5536
5537 PR rust/22545:
5538 * rust-lang.c (rust_inclusive_range_type_p): New function.
5539 (rust_range): Handle inclusive ranges.
5540 (rust_compute_range): Likewise.
5541 * rust-exp.y (struct rust_op) <inclusive>: New field.
5542 (DOTDOTEQ): New constant.
5543 (range_expr): Add "..=" productions.
5544 (operator_tokens): Add "..=" token.
5545 (ast_range): Add "inclusive" parameter.
5546 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
5547 ranges.
5548 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
5549 bounds values.
5550 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
5551 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
5552 Update comments.
5553 * expprint.c (print_subexp_standard): Handle new bounds values.
5554 (dump_subexp_body_standard): Likewise.
5555
632e107b
TT
55562018-04-27 Tom Tromey <tom@tromey.com>
5557
5558 * configure: Rebuild.
5559 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
5560 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
5561 "OVERRIDE".
5562 (class symbol_needs_eval_context): Likewise.
5563 * dwarf2read.c (mock_mapped_index::symbol_name_count)
5564 (mock_mapped_index::symbol_name_at): Use "override". Remove
5565 "virtual".
5566 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
5567 "override".
5568 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
5569 * aarch64-tdep.c (instruction_reader::read): Use "override".
5570 (instruction_reader_test::read): Likewise.
5571 * arm-tdep.c (instruction_reader::read): Use "override".
5572 (instruction_reader_thumb::read): Likewise.
5573
b75abf5b
AK
55742018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
5575
5576 PR remote/9665
5577 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
5578 instead of remote_send.
5579 (remote_send): Remove.
5580
79188d8d
PA
55812018-04-26 Pedro Alves <palves@redhat.com>
5582
5583 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
5584 find_function_start_sal instead of find_pc_line.
5585
f50776aa
PA
55862018-04-26 Pedro Alves <palves@redhat.com>
5587
5588 * breakpoint.c (set_breakpoint_location_function): Handle
5589 mst_data_gnu_ifunc.
5590 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
5591 * elfread.c (elf_symtab_read): Give data symbols with
5592 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
5593 (elf_rel_plt_read): Update comment.
5594 * linespec.c (convert_linespec_to_sals): Handle
5595 mst_data_gnu_ifunc.
5596 (minsym_found): Handle mst_data_gnu_ifunc.
5597 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
5598 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
5599 * parse.c (find_minsym_type_and_address): Handle
5600 mst_data_gnu_ifunc.
5601 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
5602 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
5603 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
5604 comment.
5605 <mst_data_gnu_ifunc>: New enumerator.
5606
20944a6e
PA
56072018-04-26 Pedro Alves <palves@redhat.com>
5608
5609 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
5610 (lookup_minimal_symbol_by_pc_section): ... this. Replace
5611 'want_trampoline' parameter by a lookup_msym_prefer parameter.
5612 Handle it.
5613 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
5614 (lookup_minimal_symbol_by_pc): Adjust.
5615 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
5616 (lookup_solib_trampoline_symbol_by_pc): Adjust.
5617 * minsyms.h (lookup_msym_prefer): New enum.
5618 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
5619 parameter by a lookup_msym_prefer parameter.
5620
1adeb822
PA
56212018-04-26 Pedro Alves <palves@redhat.com>
5622
5623 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
5624 ends in "@plt" instead of looking at the symbol's section.
5625
a0aca7b0
PA
56262018-04-26 Pedro Alves <palves@redhat.com>
5627
5628 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
5629 all references.
5630 (find_pc_partial_function_gnu_ifunc): Rename to ...
5631 (find_pc_partial_function): ... this, and remove references to
5632 'is_gnu_ifunc_p'.
5633 (find_pc_partial_function): Delete old implementation.
5634 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
5635
76af0f26
PA
56362018-04-26 Pedro Alves <palves@redhat.com>
5637
5638 * linespec.c (struct bound_minimal_symbol_search_key): New.
5639 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
5640 skip first line if we found a GNU ifunc minimal symbol by name.
5641 (compare_msymbols): Change parameters to work with a destructured
5642 lhs minsym.
5643 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
5644 functions.
5645
3467ec66
PA
56462018-04-26 Pedro Alves <palves@redhat.com>
5647
5648 * breakpoint.c (set_breakpoint_location_function): Don't resolve
5649 ifunc targets here. Instead, if we have an ifunc minsym, use its
5650 address/name.
5651 (add_location_to_breakpoint): Store the minsym and the objfile in
5652 the breakpoint location.
5653 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
5654 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
5655 Record the minsym in the sal.
5656 * symtab.h (symtab_and_line) <msymbol>: New field.
5657
28f4fa4d
PA
56582018-04-26 Pedro Alves <palves@redhat.com>
5659
5660 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
5661 unless we actually resolved the ifunc.
5662
ca31ab1d
PA
56632018-04-26 Pedro Alves <palves@redhat.com>
5664
5665 * c-exp.y (variable production): Prefer ifunc minsyms over
5666 regular function symbols.
5667 * symtab.c (find_gnu_ifunc): New function.
5668 * minsyms.h (lookup_msym_prefer): New enum.
5669 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
5670 parameter by a lookup_msym_prefer parameter.
5671 * symtab.h (find_gnu_ifunc): New declaration.
5672
8388016d
PA
56732018-04-26 Pedro Alves <palves@redhat.com>
5674
5675 * blockframe.c (find_gnu_ifunc_target_type): New function.
5676 (find_function_type): New.
5677 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
5678 return a value with a memory address.
5679 (eval_call): For calls to GNU ifunc functions, try to find the
5680 type of the target function from the type that the resolver
5681 returns.
5682 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
5683 symbols.
5684 * infcall.c (find_function_return_type): Delete.
5685 (find_function_addr): Add 'function_type' parameter. For calls to
5686 GNU ifunc functions, try to find the type of the target function
5687 from the type that the resolver returns, and return it via
5688 FUNCTION_TYPE.
5689 (call_function_by_hand_dummy): Adjust to use the function type
5690 returned by find_function_addr.
5691 (find_function_addr): Add 'function_type' parameter and move
5692 description here.
5693 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
5694 declarations.
5695
a376e11d
PA
56962018-04-26 Pedro Alves <palves@redhat.com>
5697
5698 * c-exp.y (variable production): Skip finding an alias for ifunc
5699 symbols.
5700
02e169e2
PA
57012018-04-26 Pedro Alves <palves@redhat.com>
5702
5703 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
5704
249b5733
PA
57052018-04-25 Pedro Alves <palves@redhat.com>
5706
5707 * infcmd.c (kill_command): Print the pid as string, not the whole
5708 thread's ptid. Add comment. s/has been killed/killed/ in output
5709 message.
5710 * remote.c (remote_detach_1): Print the pid as string, not the
5711 whole thread's ptid.
5712
f67c0c91
SDJ
57132018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
5714 Sergio Durigan Junior <sergiodj@redhat.com>
5715 Pedro Alves <palves@redhat.com>
5716
5717 * infcmd.c (kill_command): Print message when inferior has
5718 been killed.
5719 * inferior.c (print_inferior_events): Remove 'static'. Set as
5720 '1'.
5721 (add_inferior): Improve message printed when
5722 'print_inferior_events' is on.
5723 (exit_inferior): Remove message printed when
5724 'print_inferior_events' is on.
5725 (detach_inferior): Improve message printed when
5726 'print_inferior_events' is on.
5727 (initialize_inferiors): Use 'add_inferior_silent' to set
5728 'current_inferior_'.
5729 * inferior.h (print_inferior_events): Declare here as
5730 'extern'.
5731 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
5732 '[Detaching...]' messages when 'print_inferior_events' is on.
5733 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
5734 as prefix/suffix for messages. Remove periods. Fix erroneous
5735 'Detaching after fork from child...', replace it by '... from
5736 parent...'.
5737 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
5738 prefix/suffix when printing 'Detaching...' messages. Print
5739 them when 'print_inferior_events' is on.
5740 * remote.c (remote_detach_1): Print message when detaching
5741 from inferior and '!is_fork_parent'.
5742
e427af18
TT
57432018-04-24 Tom Tromey <tom@tromey.com>
5744
5745 * cli-out.h: Reindent.
5746
05b1d8d6
TT
57472018-04-24 Tom Tromey <tom@tromey.com>
5748
5749 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
5750 (cli_ui_out::do_field_string): Use fputs_filtered.
5751 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
5752
a95c7dab
TT
57532018-04-23 Tom Tromey <tom@tromey.com>
5754
5755 * guile/scm-frame.c (gdbscm_frame_read_var): Use
5756 gdb::unique_xmalloc_ptr.
5757
458412c3
TT
57582018-04-23 Tom Tromey <tom@tromey.com>
5759
5760 * configure: Rebuild.
5761
db86b02b
RS
57622018-04-22 Rajendra SY <rajendra.sy@gmail.com>
5763
5764 PR gdb/23095
5765 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
5766 prepare_for_testing. Set normal_bp to r_debug_state if target
5767 is bsd.
5768
00aecdcf
PA
57692018-04-21 Pedro Alves <palves@redhat.com>
5770 Rajendra SY <rajendra.sy@gmail.com>
5771
5772 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
5773 * remote.c (extended_remote_attach): In all-stop mode, mark the
5774 thread as executing.
5775
224608c3
PW
57762018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5777
5778 * thread.c (thread_apply_all_command): Fix comment.
5779 (thread_command): Fix comment.
5780
3b74854b
AH
57812018-04-10 Alan Hayward <alan.hayward@arm.com>
5782
5783 * common/tdesc.h (tdesc_create_feature): Remove xml filename
5784 parameter.
5785 * features/aarch64-core.c (create_feature_aarch64_core):
5786 Regenerate.
5787 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
5788 Likewise.
5789 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
5790 Likewise.
5791 * features/i386/32bit-avx512.c
5792 (create_feature_i386_32bit_avx512): Likewise.
5793 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
5794 Likewise.
5795 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
5796 Likewise.
5797 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
5798 Likewise.
5799 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
5800 Likewise.
5801 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
5802 Likewise.
5803 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
5804 Likewise.
5805 * features/i386/64bit-avx512.c
5806 (create_feature_i386_64bit_avx512): Likewise.
5807 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
5808 Likewise.
5809 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
5810 Likewise.
5811 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
5812 Likewise.
5813 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
5814 Likewise.
5815 * features/i386/64bit-segments.c
5816 (create_feature_i386_64bit_segments): Likewise.
5817 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
5818 Likewise.
5819 * features/i386/x32-core.c
5820 (create_feature_i386_x32_core): Likewise.
5821 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
5822 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
5823 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
5824 * target-descriptions.c: In generated code, don't pass xml
5825 filename.
5826
e98577a9
AH
58272018-04-18 Alan Hayward <alan.hayward@arm.com>
5828
5829 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
5830 (print_xml_feature::visit_post): Likewise.
5831 (print_xml_feature::visit): Likewise.
5832 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
5833 (print_xml_feature): Add new class.
5834 * regformats/regdat.sh: Null xmltarget on feature targets.
5835 * target-descriptions.c (struct target_desc): Add xmltarget.
5836 (maintenance_check_tdesc_xml_convert): Add unittest function.
5837 (tdesc_get_features_xml): Add function to get xml.
5838 (maintenance_check_xml_descriptions): Test xml generation.
5839 * xml-tdesc.c (string_read_description_xml): Add function.
5840 * xml-tdesc.h (string_read_description_xml): Add declaration.
5841
ad7fc756
AH
58422018-04-18 Alan Hayward <alan.hayward@arm.com>
5843
5844 * features/Makefile: Add feature marker to targets with new style
5845 target descriptions.
5846 * regformats/aarch64.dat: Regenerate.
5847 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
5848 * regformats/i386/amd64-avx-linux.dat: Likewise.
5849 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
5850 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
5851 * regformats/i386/amd64-linux.dat: Likewise.
5852 * regformats/i386/amd64-mpx-linux.dat: Likewise.
5853 * regformats/i386/amd64.dat: Likewise.
5854 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
5855 * regformats/i386/i386-avx-linux.dat: Likewise.
5856 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
5857 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
5858 * regformats/i386/i386-linux.dat: Likewise.
5859 * regformats/i386/i386-mmx-linux.dat: Likewise.
5860 * regformats/i386/i386-mpx-linux.dat: Likewise.
5861 * regformats/i386/i386.dat: Likewise.
5862 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
5863 * regformats/i386/x32-avx-linux.dat: Likewise.
5864 * regformats/i386/x32-linux.dat: Likewise.
5865 * regformats/tic6x-c62x-linux.dat: Likewise.
5866 * regformats/tic6x-c64x-linux.dat: Likewise.
5867 * regformats/tic6x-c64xp-linux.dat: Likewise.
5868 * regformats/regdat.sh: Parse feature marker.
5869
d278f585
AH
58702018-04-18 Alan Hayward <alan.hayward@arm.com>
5871
5872 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
5873 (tdesc_osabi_name): Likewise.
5874 * target-descriptions.c (tdesc_architecture_name): Add new
5875 function.
5876 (tdesc_osabi_name): Likewise.
5877
eee8a18d
AH
58782018-04-18 Alan Hayward <alan.hayward@arm.com>
5879
5880 * common/tdesc.c (tdesc_predefined_type): Move to here.
5881 (tdesc_named_type): Likewise.
5882 (tdesc_create_vector): Likewise.
5883 (tdesc_create_struct): Likewise.
5884 (tdesc_set_struct_size): Likewise.
5885 (tdesc_create_union): Likewise.
5886 (tdesc_create_flags): Likewise.
5887 (tdesc_create_enum): Likewise.
5888 (tdesc_add_field): Likewise.
5889 (tdesc_add_typed_bitfield): Likewise.
5890 (tdesc_add_bitfield): Likewise.
5891 (tdesc_add_flag): Likewise.
5892 (tdesc_add_enum_value): Likewise.
5893 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
5894 (struct tdesc_type_vector): Likewise.
5895 (struct tdesc_type_field): Likewise.
5896 (struct tdesc_type_with_fields): Likewise.
5897 (tdesc_create_enum): Add declaration.
5898 (tdesc_add_typed_bitfield): Likewise.
5899 (tdesc_add_enum_value): Likewise.
5900 * target-descriptions.c (tdesc_type_field): Move from here.
5901 (tdesc_type_builtin): Likewise.
5902 (tdesc_type_vector): Likewise.
5903 (tdesc_type_with_fields): Likewise.
5904 (tdesc_predefined_types): Likewise.
5905 (tdesc_named_type): Likewise.
5906 (tdesc_create_vector): Likewise.
5907 (tdesc_create_struct): Likewise.
5908 (tdesc_set_struct_size): Likewise.
5909 (tdesc_create_union): Likewise.
5910 (tdesc_create_flags): Likewise.
5911 (tdesc_create_enum): Likewise.
5912 (tdesc_add_field): Likewise.
5913 (tdesc_add_typed_bitfield): Likewise.
5914 (tdesc_add_bitfield): Likewise.
5915 (tdesc_add_flag): Likewise.
5916 (tdesc_add_enum_value): Likewise.
5917 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
5918 (tdesc_add_typed_bitfield): Likewise.
5919 (tdesc_add_enum_value): Likewise.
5920
82ec9bc7
AH
59212018-04-18 Alan Hayward <alan.hayward@arm.com>
5922
5923 * common/tdesc.c (tdesc_feature::accept): Move to here.
5924 (tdesc_feature::operator==): Likewise.
5925 (tdesc_create_reg): Likewise.
5926 * common/tdesc.h (tdesc_type_kind): Likewise.
5927 (struct tdesc_type): Likewise.
5928 (struct tdesc_feature): Likewise.
5929 * regformats/regdat.sh: Create a feature.
5930 * target-descriptions.c (tdesc_type_kind): Move from here.
5931 (tdesc_type): Likewise.
5932 (tdesc_type_up): Likewise.
5933 (tdesc_feature): Likewise.
5934 (tdesc_create_reg): Likewise.
5935
ea3e7d71
AH
59362018-04-18 Alan Hayward <alan.hayward@arm.com>
5937
5938 * Makefile.in: Add arch/tdesc.c
5939 * common/tdesc.c: New file.
5940 * common/tdesc.h (tdesc_element_visitor): Move to here.
5941 (tdesc_element): Likewise.
5942 (tdesc_reg): Likewise.
5943 (tdesc_reg_up): Likewise.
5944 * regformats/regdef.h (reg): Add offset to constructors.
5945 * target-descriptions.c (tdesc_element_visitor): Move from here.
5946 (tdesc_element): Likewise.
5947 (tdesc_reg): Likewise.
5948 (tdesc_reg_up): Likewise.
5949
bedda9ac
TT
59502018-04-17 Tom Tromey <tom@tromey.com>
5951
5952 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
5953 discriminant field.
5954
a037790e
TT
59552018-04-17 Tom Tromey <tom@tromey.com>
5956
5957 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
5958
c7dcbf88
AA
59592018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
5960
5961 * symtab.c (print_symbol_info): Skip printing filename and line
5962 number when `last' is NULL.
5963 (symtab_symbol_info): Use empty string instead of NULL for first
5964 invocation of print_symbol_info.
5965 (rbreak_command): Pass NULL to `last' parameter of
5966 print_symbol_info.
5967
07d28c77
SM
59682018-04-16 Simon Marchi <simon.marchi@ericsson.com>
5969
5970 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
5971 instead of nullptr.
5972
8a3de5e1
PA
59732018-04-16 Pedro Alves <palves@redhat.com>
5974
5975 * MAINTAINERS (sh): Remove.
5976 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
5977 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
5978 (ALLDEPFILES): Remove sh64-tdep.c.
5979 * NEWS: Mentions that support for SH-5/SH64 is removed.
5980 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
5981 (sh*-*-openbsd*): Ditto.
5982 (sh64-*-elf*): Remove.
5983 (sh*): Remove.
5984 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
5985 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
5986 * sh-tdep.c: No longer include "sh64-tdep.h".
5987 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
5988 * sh64-tdep.c, sh64-tdep.h: Remove files.
5989
a2a79012
PA
59902018-04-16 Pedro Alves <palves@redhat.com>
5991
5992 * MAINTAINERS: Remove m88k.
5993 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
5994 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
5995 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
5996 * NEWS: Mention that support for m88k was removed.
5997 * configure.host (m88*-*-*): Remove support.
5998 * configure.nat (m88k-*-*): Remove support.
5999 * configure.tgt (m88*-*-openbsd*): Remove.
6000 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
6001
eda4efb1
SM
60022018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
6003
6004 * configure.tgt (x86_tobjs): New variable.
6005 (amd64_tobjs, i386_tobjs): Use it.
6006
b744723f
AA
60072018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6008
6009 * symtab.c (print_symbol_info): Precede the symbol definition by
6010 the line number when available.
6011 * NEWS: Advertise this enhancement.
6012
4a4495d6
MM
60132018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6014
6015 * NEWS (New options): announce set/show record btrace cpu.
6016 * btrace.c: Include record-btrace.h.
6017 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
6018 the vendor is unknown.
6019 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
6020 Maybe overwrite the btrace configuration's cpu.
6021 (btrace_compute_ftrace): Add cpu parameter. Update callers.
6022 (btrace_fetch): Add cpu parameter. Update callers.
6023 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
6024 Maybe overwrite the btrace configuration's cpu. Skip enabling
6025 errata workarounds if the vendor is unknown.
6026 * python/py-record-btrace.c: Include record-btrace.h.
6027 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
6028 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
6029 * record-btrace.c (record_btrace_cpu_state_kind): New.
6030 (record_btrace_cpu): New.
6031 (set_record_btrace_cpu_cmdlist): New.
6032 (record_btrace_get_cpu): New.
6033 (require_btrace_thread, record_btrace_info)
6034 (record_btrace_resume_thread): Call record_btrace_get_cpu.
6035 (cmd_set_record_btrace_cpu_none): New.
6036 (cmd_set_record_btrace_cpu_auto): New.
6037 (cmd_set_record_btrace_cpu): New.
6038 (cmd_show_record_btrace_cpu): New.
6039 (_initialize_record_btrace): Initialize set/show record btrace cpu
6040 commands.
6041 * record-btrace.h (record_btrace_get_cpu): New.
6042
69f90c75
MM
60432018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6044
6045 * record.c (set_record_command): Fix typo in message.
6046
b85310e1
MM
60472018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6048
6049 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
6050
1d509aa6
MM
60512018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6052
6053 * infrun.c (process_event_stop_test): Call
6054 gdbarch_in_indirect_branch_thunk.
6055 * gdbarch.sh (in_indirect_branch_thunk): New.
6056 * gdbarch.c: Regenerated.
6057 * gdbarch.h: Regenerated.
6058 * x86-tdep.h: New.
6059 * x86-tdep.c: New.
6060 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
6061 (HFILES_NO_SRCDIR): Add x86-tdep.h.
6062 (ALLDEPFILES): Add x86-tdep.c.
6063 * arch-utils.h (default_in_indirect_branch_thunk): New.
6064 * arch-utils.c (default_in_indirect_branch_thunk): New.
6065 * i386-tdep: Include x86-tdep.h.
6066 (i386_in_indirect_branch_thunk): New.
6067 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
6068 function.
6069 * amd64-tdep: Include x86-tdep.h.
6070 (amd64_in_indirect_branch_thunk): New.
6071 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
6072
b4be9bfd
JK
60732018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
6074
6075 PR gdb/23053
6076 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
6077 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
6078 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
6079 regression.
6080
53d7df28
TT
60812018-04-12 Tom Tromey <tom@tromey.com>
6082
6083 * rust-lang.c (rust_print_struct_def): Remove univariant code.
6084 (rust_evaluate_subexp): Likewise.
6085
70b33f19
PA
60862018-04-12 Pedro Alves <palves@redhat.com>
6087
6088 * procfs.c (procfs_detach): Make forward declaration's prototype
6089 match definition's protototype.
6090 (proc_get_LDT_entry): Remove stale do_cleanups call.
6091
436411b1
PA
60922018-04-12 Pedro Alves <palves@redhat.com>
6093
6094 * target.h (target_ops::to_has_exited): Delete.
6095 (target_has_exited): Delete.
6096 * target-delegates.c: Regenerate.
6097
20db9c52
PA
60982018-04-11 Pedro Alves <palves@redhat.com>
6099
6100 * target.c (fileio_fh_t::t): Add comment.
6101 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
6102 (target_fileio_close): Handle a NULL target.
6103 (invalidate_fileio_fh): New.
6104 (target_close): Call it.
6105 * remote.c (remote_hostio_send_command): No longer check whether
6106 remote_desc is open.
6107
5ff79300
PA
61082018-04-11 Pedro Alves <palves@redhat.com>
6109
6110 * target.c (fileio_fh_t): Make it a named struct instead of a
6111 typedef.
6112 (fileio_fh_t::is_closed): New method.
6113 (DEF_VEC_O (fileio_fh_t)): Remove.
6114 (fileio_fhandles): Now a std::vector.
6115 (is_closed_fileio_fh): Delete.
6116 (acquire_fileio_fd): Adjust. Rename parameters.
6117 (release_fileio_fd): Adjust.
6118 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
6119 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
6120 (target_fileio_close): Adjust.
6121
6e22e10d
SM
61222018-04-10 Simon Marchi <simon.marchi@ericsson.com>
6123
6124 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
6125 index.
6126
731f534f
PA
61272018-04-10 Pedro Alves <palves@redhat.com>
6128
6129 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
6130 (scoped_finish_thread_state): New class.
6131 * infcmd.c (run_command_1): Use it instead of finish_thread_state
6132 cleanup.
6133 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
6134 (fetch_inferior_event, normal_stop): Likewise.
6135 * thread.c (finish_thread_state_cleanup): Delete.
6136
d5f4488f
SM
61372018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6138 Pedro Alves <palves@redhat.com>
6139
6140 * value.c: Include "selftest.h" and "common/array-view.h".
6141 (struct range) <operator ==>: New.
6142 (test_ranges_contain): New.
6143 (check_ranges_vector): New.
6144 (test_insert_into_bit_range_vector): New.
6145 (_initialize_values): Register selftests.
6146 * common/array-view.h (operator==, operator!=): New.
6147
b24531ed
SM
61482018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6149
6150 * common/gdb_vecs.h (unordered_remove): Add overload that takes
6151 an iterator.
6152 * inline-frame.c: Include <algorithm>.
6153 (struct inline_state): Add constructor.
6154 (inline_state_s): Remove.
6155 (DEF_VEC_O(inline_state_s)): Remove.
6156 (inline_states): Change type to std::vector.
6157 (find_inline_frame_state): Adjust to std::vector.
6158 (allocate_inline_frame_state): Remove.
6159 (clear_inline_frame_state): Adjust to std::vector.
6160 (skip_inline_frames): Adjust to std::vector.
6161
c252925c
SM
61622018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6163
6164 * tracepoint.h (struct trace_state_variable): Add constructor.
6165 <name>: Change type to std::string.
6166 * tracepoint.c (tsv_s): Remove.
6167 (DEF_VEC_O(tsv_s)): Remove.
6168 (tvariables): Change to std::vector.
6169 (create_trace_state_variable): Adjust to std::vector.
6170 (find_trace_state_variable): Likewise.
6171 (find_trace_state_variable_by_number): Likewise.
6172 (delete_trace_state_variable): Likewise.
6173 (trace_variable_command): Adjust to std::string.
6174 (delete_trace_variable_command): Likewise.
6175 (tvariables_info_1): Adjust to std::vector.
6176 (save_trace_state_variables): Likewise.
6177 (start_tracing): Likewise.
6178 (merge_uploaded_trace_state_variables): Adjust to std::vector
6179 and std::string.
6180 * target.h (struct target_ops)
6181 <to_download_trace_state_variable>: Pass reference to
6182 trace_state_variable.
6183 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
6184 * target-delegates.c: Re-generate.
6185 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
6186 (mi_tsv_deleted): Likewise.
6187 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
6188 * remote.c (remote_download_trace_state_variable): Change
6189 pointer to reference and adjust.
6190 * make-target-delegates (parse_argtypes): Handle references.
6191 (write_function_header): Likewise.
6192 (munge_type): Likewise.
6193
c9638d26
SM
61942018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6195
6196 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6197 string_view-selftests.c.
6198 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
6199 testsuite.
6200 * unittests/basic_string_view/cons/char/1.cc: Likewise.
6201 * unittests/basic_string_view/cons/char/2.cc: Likewise.
6202 * unittests/basic_string_view/cons/char/3.cc: Likewise.
6203 * unittests/basic_string_view/element_access/char/1.cc:
6204 Likewise.
6205 * unittests/basic_string_view/element_access/char/empty.cc:
6206 Likewise.
6207 * unittests/basic_string_view/element_access/char/front_back.cc:
6208 Likewise.
6209 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
6210 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
6211 Likewise.
6212 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
6213 Likewise.
6214 * unittests/basic_string_view/modifiers/swap/char/1.cc:
6215 Likewise.
6216 * unittests/basic_string_view/operations/compare/char/1.cc:
6217 Likewise.
6218 * unittests/basic_string_view/operations/compare/char/13650.cc:
6219 Likewise.
6220 * unittests/basic_string_view/operations/copy/char/1.cc:
6221 Likewise.
6222 * unittests/basic_string_view/operations/data/char/1.cc:
6223 Likewise.
6224 * unittests/basic_string_view/operations/find/char/1.cc:
6225 Likewise.
6226 * unittests/basic_string_view/operations/find/char/2.cc:
6227 Likewise.
6228 * unittests/basic_string_view/operations/find/char/3.cc:
6229 Likewise.
6230 * unittests/basic_string_view/operations/find/char/4.cc:
6231 Likewise.
6232 * unittests/basic_string_view/operations/rfind/char/1.cc:
6233 Likewise.
6234 * unittests/basic_string_view/operations/rfind/char/2.cc:
6235 Likewise.
6236 * unittests/basic_string_view/operations/rfind/char/3.cc:
6237 Likewise.
6238 * unittests/basic_string_view/operations/substr/char/1.cc:
6239 Likewise.
6240 * unittests/basic_string_view/operators/char/2.cc: Likewise.
6241 * unittests/string_view-selftests.c: New file.
6242
fdc11678
SM
62432018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6244
6245 * unittests/basic_string_view/capacity/1.cc: New file.
6246 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
6247 * unittests/basic_string_view/cons/char/1.cc: New file.
6248 * unittests/basic_string_view/cons/char/2.cc: New file.
6249 * unittests/basic_string_view/cons/char/3.cc: New file.
6250 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
6251 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
6252 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
6253 * unittests/basic_string_view/element_access/char/1.cc: New file.
6254 * unittests/basic_string_view/element_access/char/2.cc: New file.
6255 * unittests/basic_string_view/element_access/char/empty.cc: New file.
6256 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
6257 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
6258 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
6259 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
6260 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
6261 * unittests/basic_string_view/include.cc: New file.
6262 * unittests/basic_string_view/inserters/char/1.cc: New file.
6263 * unittests/basic_string_view/inserters/char/2.cc: New file.
6264 * unittests/basic_string_view/inserters/char/3.cc: New file.
6265 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
6266 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
6267 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
6268 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
6269 * unittests/basic_string_view/literals/types.cc: New file.
6270 * unittests/basic_string_view/literals/values.cc: New file.
6271 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
6272 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
6273 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
6274 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
6275 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
6276 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
6277 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
6278 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
6279 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
6280 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
6281 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
6282 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
6283 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
6284 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
6285 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
6286 * unittests/basic_string_view/operations/data/char/1.cc: New file.
6287 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
6288 * unittests/basic_string_view/operations/find/char/1.cc: New file.
6289 * unittests/basic_string_view/operations/find/char/2.cc: New file.
6290 * unittests/basic_string_view/operations/find/char/3.cc: New file.
6291 * unittests/basic_string_view/operations/find/char/4.cc: New file.
6292 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
6293 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
6294 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
6295 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
6296 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
6297 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
6298 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
6299 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
6300 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
6301 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
6302 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
6303 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
6304 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
6305 * unittests/basic_string_view/operators/char/2.cc: New file.
6306 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
6307 * unittests/basic_string_view/range_access/char/1.cc: New file.
6308 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
6309 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
6310 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
6311 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
6312 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
6313 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
6314 * unittests/basic_string_view/requirements/typedefs.cc: New file.
6315 * unittests/basic_string_view/typedefs.cc: New file.
6316 * unittests/basic_string_view/types/1.cc: New file.
6317
8345c4a2
SM
63182018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6319
6320 * common/gdb_string_view.h: Remove libstdc++ implementation
6321 details, adjust to gdb reality.
6322 * common/gdb_string_view.tcc: Likewise.
6323 * cli/cli-script.c (struct string_view): Remove.
6324 (user_args) <m_args>: Change element type to gdb::string_view.
6325 (user_args::insert_args): Adjust.
6326
7adcdf08
SM
63272018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6328
6329 * common/gdb_string_view.h: New file.
6330 * common/gdb_string_view.tcc: New file.
6331
41260ac2
SM
63322018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6333
6334 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
6335 * configure: Re-generate.
6336
0bee6dd4
PA
63372018-04-09 Pedro Alves <palves@redhat.com>
6338
6339 * gdbarch.sh: Include "observable.h" instead of "observer.h".
6340 (set_target_gdbarch): Call
6341 gdb::observers::architecture_changed.notify instead of
6342 observer_notify_architecture_changed.
6343
6f14adc5
SM
63442018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6345
6346 * tracepoint.c (struct current_traceframe_cleanup): Remove.
6347 (do_restore_current_traceframe_cleanup): Remove.
6348 (restore_current_traceframe_cleanup_dtor): Remove.
6349 (make_cleanup_restore_current_traceframe): Remove.
6350 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
6351 New.
6352 * tracepoint.h (struct scoped_restore_current_traceframe): New.
6353 * infrun.c (fetch_inferior_event): Use
6354 scoped_restore_current_traceframe.
6355
b2bdb8cf
SM
63562018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6357
6358 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
6359 Remove.
6360 <n_allocated_type_units>: Remove.
6361 <all_type_units>: Change to std::vector.
6362 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
6363 to std::vector change.
6364 (dwarf2_per_objfile::get_cutu): Likewise.
6365 (dwarf2_per_objfile::get_tu): Likewise.
6366 (create_signatured_type_table_from_index): Likewise.
6367 (create_signatured_type_table_from_debug_names): Likewise.
6368 (dw2_symtab_iter_next): Likewise.
6369 (dw2_print_stats): Likewise.
6370 (dw2_expand_all_symtabs): Likewise.
6371 (dw2_expand_marked_cus): Likewise.
6372 (dw2_debug_names_iterator::next): Likewise.
6373 (dwarf2_initialize_objfile): Likewise.
6374 (add_signatured_type_cu_to_table): Likewise.
6375 (create_all_type_units): Likewise.
6376 (add_type_unit): Likewise.
6377 (struct tu_abbrev_offset): Add constructor.
6378 (build_type_psymtabs_1): Adjust to std::vector change.
6379 (print_tu_stats): Likewise.
6380 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
6381 (write_debug_names): Likewise.
6382
b76e467d
SM
63832018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6384
6385 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
6386 Make an std::vector.
6387 <n_comp_units>: Remove.
6388 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
6389 to std::vector change.
6390 (dwarf2_per_objfile::get_cutu): Likewise.
6391 (dwarf2_per_objfile::get_cu): Likewise.
6392 (create_cus_from_index): Likewise.
6393 (create_addrmap_from_index): Likewise.
6394 (create_addrmap_from_aranges): Likewise.
6395 (dwarf2_read_index): Likewise.
6396 (dw2_find_last_source_symtab): Likewise.
6397 (dw2_map_symtabs_matching_filename): Likewise.
6398 (dw2_symtab_iter_next): Likewise.
6399 (dw2_print_stats): Likewise.
6400 (dw2_expand_all_symtabs): Likewise.
6401 (dw2_expand_symtabs_with_fullname): Likewise.
6402 (dw2_expand_marked_cus): Likewise.
6403 (dw2_map_symbol_filenames): Likewise.
6404 (create_cus_from_debug_names): Likewise.
6405 (dwarf2_read_debug_names): Likewise.
6406 (dw2_debug_names_iterator::next): Likewise.
6407 (dwarf2_initialize_objfile): Likewise.
6408 (set_partial_user): Likewise.
6409 (dwarf2_build_psymtabs_hard): Likewise.
6410 (read_comp_units_from_section): Remove arguments, adjust to
6411 std::vector change.
6412 (create_all_comp_units): Adjust to std::vector and
6413 read_comp_units_from_section changes.
6414 (dwarf2_find_containing_comp_unit): Adjust to std::vector
6415 change.
6416 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
6417 (psyms_seen_size): Likewise.
6418 (write_gdbindex): Likewise.
6419 (write_debug_names): Likewise.
6420
12359b5e
SM
64212018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6422
6423 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
6424 with dwarf2_per_objfile.
6425 (create_cus_from_index): Likewise.
6426 (create_signatured_type_table_from_index): Likewise.
6427 (dwarf2_read_index): Likewise.
6428 (dwarf2_initialize_objfile): Likewise.
6429 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
6430 per_cu rather than get_dwarf2_per_objfile.
6431
ff4c9fec
SM
64322018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6433
6434 * dwarf2read.h (struct signatured_type): Forward declare.
6435 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
6436 New methods.
6437 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
6438 (dw2_get_cutu): ...this.
6439 (dwarf2_per_objfile::get_cu): Rename from...
6440 (dw2_get_cu): ...this.
6441 (dwarf2_per_objfile::get_tu): New.
6442 (create_addrmap_from_index): Adjust.
6443 (create_addrmap_from_aranges): Adjust.
6444 (dw2_find_last_source_symtab): Adjust.
6445 (dw2_map_symtabs_matching_filename): Adjust.
6446 (dw2_symtab_iter_next): Adjust.
6447 (dw2_print_stats): Adjust.
6448 (dw2_expand_all_symtabs): Adjust.
6449 (dw2_expand_symtabs_with_fullname): Adjust.
6450 (dw2_expand_marked_cus): Adjust.
6451 (dw_expand_symtabs_matching_file_matcher): Adjust.
6452 (dw2_map_symbol_filenames): Adjust.
6453 (dw2_debug_names_iterator::next): Adjust.
6454 (dwarf2_initialize_objfile): Adjust.
6455 (set_partial_user): Adjust.
6456 (dwarf2_build_psymtabs_hard): Adjust.
6457
5ca3fcb6
SM
64582018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6459
6460 * dwarf2read.c (create_signatured_type_table_from_debug_names):
6461 Remove unused variables.
6462 (dw2_map_symtabs_matching_filename): Likewise.
6463 (dwarf2_record_block_ranges): Likewise.
6464 (dwarf2_read_addr_index): Likewise.
6465 (follow_die_offset): Likewise.
6466
b2e586e8
SM
64672018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6468
6469 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
6470 to symbol_file_add_main.
6471
7c4e78cf
SM
64722018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6473
6474 PR mi/22299
6475 * mi/mi-console.c (do_fputc_async_safe): New.
6476 (mi_console_file::write_async_safe): New.
6477 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
6478 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
6479 New.
6480 * ui-file.c (ui_file::putstrn): Adjust call to
6481 fputstrn_unfiltered.
6482 * utils.c (printchar): Replace do_fputs and do_fprintf
6483 parameters by do_fputc.
6484 (fputstr_filtered): Adjust call to printchar.
6485 (fputstr_unfiltered): Likewise.
6486 (fputstrn_filtered): Likewise.
6487 (fputstrn_unfiltered): Add do_fputc parameter, pass to
6488 printchar.
6489 * utils.h (do_fputc_ftype): New typedef.
6490 (fputstrn_unfiltered): Add do_fputc parameter.
6491
5dc026d3
SM
64922018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6493
6494 * regformats/i386/i386-avx.dat: Remove.
6495
c912f608
SM
64962018-04-07 Simon Marchi <simon.marchi@ericsson.com>
6497
6498 PR gdb/22979
6499 * amd64-tdep.c (amd64_none_init_abi): New function.
6500 (amd64_x32_none_init_abi): New function.
6501 (_initialize_amd64_tdep): Register handlers for x86-64 and
6502 x64_32 with GDB_OSABI_NONE.
6503 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
6504 GDB_OSABI_NONE osabi.
6505
26540402
SM
65062018-04-07 Simon Marchi <simon.marchi@ericsson.com>
6507
6508 PR gdb/22980
6509 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
6510 GDB_OSABI_NONE.
6511 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
6512 * osabi.c (gdb_osabi_names): Add "unknown" entry.
6513
9018be22
SM
65142018-04-07 Simon Marchi <simon.marchi@ericsson.com>
6515
6516 * common/byte-vector.h (char_vector): New type.
6517 * target.h (target_read_alloc): Return
6518 gdb::optional<byte_vector>.
6519 (target_read_stralloc): Return gdb::optional<char_vector>.
6520 (target_get_osdata): Return gdb::optional<char_vector>.
6521 * target.c (target_read_alloc_1): Templatize. Replacement
6522 manual memory management with vector.
6523 (target_read_alloc): Change return type, adjust.
6524 (target_read_stralloc): Change return type, adjust.
6525 (target_get_osdata): Change return type, adjust.
6526 * auxv.c (struct auxv_info) <length>: Remove.
6527 <data>: Change type to gdb::optional<byte_vector>.
6528 (auxv_inferior_data_cleanup): Free auxv_info with delete.
6529 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
6530 (target_auxv_search): Adjust.
6531 (fprint_target_auxv): Adjust.
6532 * avr-tdep.c (avr_io_reg_read_command): Adjust.
6533 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
6534 (linux_make_corefile_notes): Adjust.
6535 * osdata.c (get_osdata): Adjust.
6536 * remote.c (remote_get_threads_with_qxfer): Adjust.
6537 (remote_memory_map): Adjust.
6538 (remote_traceframe_info): Adjust.
6539 (btrace_read_config): Adjust.
6540 (remote_read_btrace): Adjust.
6541 (remote_pid_to_exec_file): Adjust.
6542 * solib-aix.c (solib_aix_get_library_list): Adjust.
6543 * solib-dsbt.c (decode_loadmap): Don't free buf.
6544 (dsbt_get_initial_loadmaps): Adjust.
6545 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
6546 * solib-target.c (solib_target_current_sos): Adjust.
6547 * tracepoint.c (sdata_make_value): Adjust.
6548 * xml-support.c (xinclude_start_include): Adjust.
6549 (xml_fetch_content_from_file): Adjust.
6550 * xml-support.h (xml_fetch_another): Change return type.
6551 (xml_fetch_content_from_file): Change return type.
6552 * xml-syscall.c (xml_init_syscalls_info): Adjust.
6553 * xml-tdesc.c (file_read_description_xml): Adjust.
6554 (fetch_available_features_from_target): Change return type.
6555 (target_fetch_description_xml): Adjust.
6556 (target_read_description_xml): Adjust.
6557
14c88955
TT
65582018-04-06 Tom Tromey <tom@tromey.com>
6559
6560 * value.c (~value): Update.
6561 (struct value) <contents>: Now unique_xmalloc_ptr.
6562 (value_contents_bits_eq, allocate_value_contents)
6563 (value_contents_raw, value_contents_all_raw)
6564 (value_contents_for_printing, value_contents_for_printing_const)
6565 (set_value_enclosing_type): Update.
6566
0c7e6dd8
TT
65672018-04-06 Tom Tromey <tom@tromey.com>
6568
6569 * value.c (range_s): Remove typedef, VEC.
6570 (struct range): Add operator<.
6571 (range_lessthan): Remove.
6572 (ranges_contain): Change type.
6573 (~value): Update.
6574 (struct value) <unavailable, optimized_out>: Now std::vector.
6575 (value_entirely_available)
6576 (value_entirely_covered_by_range_vector)
6577 (value_entirely_unavailable, value_entirely_optimized_out):
6578 Update.
6579 (insert_into_bit_range_vector): Change argument type.
6580 (find_first_range_overlap): Likewise.
6581 (struct ranges_and_idx, value_contents_bits_eq)
6582 (require_not_optimized_out, require_available): Update.
6583 (ranges_copy_adjusted): Change argument types.
6584 (value_optimized_out, value_copy, value_fetch_lazy): Update.
6585
2c8331b9
TT
65862018-04-06 Tom Tromey <tom@tromey.com>
6587
6588 * value.c (~value): Update.
6589 (struct value) <parent>: Now a value_ref_ptr.
6590 (value_parent, set_value_parent, value_address, value_copy):
6591 Update.
6592
466ce3ae
TT
65932018-04-06 Tom Tromey <tom@tromey.com>
6594
6595 * value.c (struct value): Add constructor, destructor, and member
6596 initializers.
6597 (allocate_value_lazy, value_decref): Update.
6598
062d818d
TT
65992018-04-06 Tom Tromey <tom@tromey.com>
6600
6601 * value.c (struct value) <released, next>: Remove.
6602 (all_values): Now a std::vector.
6603 (allocate_value_lazy): Update.
6604 (value_next): Remove.
6605 (value_mark, value_free_to_mark, release_value)
6606 (value_release_to_mark): Update.
6607
a6535de1
TT
66082018-04-06 Tom Tromey <tom@tromey.com>
6609
6610 * value.h (fetch_subexp_value, value_release_to_mark): Update.
6611 (free_value_chain): Remove.
6612 * value.c (free_value_chain): Remove.
6613 (value_release_to_mark): Return a std::vector.
6614 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
6615 std::vector.
6616 (check_condition): Update.
6617 * eval.c (fetch_subexp_value): Change "val_chain" to a
6618 std::vector.
6619 * breakpoint.c (update_watchpoint): Update.
6620 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
6621
b5621201
TT
66222018-04-06 Tom Tromey <tom@tromey.com>
6623
6624 * value.h (free_all_values): Remove.
6625 * value.c (free_all_values): Remove.
6626
4d0266a0
TT
66272018-04-06 Tom Tromey <tom@tromey.com>
6628
6629 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
6630 (value_history_chain, value_history_count): Remove.
6631 (value_history): New global.
6632 (record_latest_value, access_value_history, show_values)
6633 (preserve_values): Update.
6634
b4d61099
TT
66352018-04-06 Tom Tromey <tom@tromey.com>
6636
6637 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
6638 * varobj.c (varobj_set_display_format, varobj_set_value)
6639 (install_default_visualizer, construct_visualizer)
6640 (install_new_value, ~varobj, varobj_get_value_type)
6641 (my_value_of_variable, varobj_editable_p): Update.
6642 * c-varobj.c (c_describe_child, c_value_of_variable)
6643 (cplus_number_of_children, cplus_describe_child): Update.
6644 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
6645 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
6646 (ada_value_of_variable, ada_value_is_changeable_p): Update.
6647
9b558729
TT
66482018-04-06 Tom Tromey <tom@tromey.com>
6649
6650 * printcmd.c (last_examine_address): Change type to
6651 value_ref_ptr.
6652 (do_examine, x_command): Update.
6653
850645cf
TT
66542018-04-06 Tom Tromey <tom@tromey.com>
6655
6656 * value.c (release_value): Update.
6657 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
6658 (struct bpstats) <val>: Now a value_ref_ptr.
6659 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
6660 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
6661 (~watchpoint, print_it_watchpoint, watch_command_1)
6662 (invalidate_bp_value_on_memory_change): Update.
6663
22bc8444
TT
66642018-04-06 Tom Tromey <tom@tromey.com>
6665
6666 * varobj.c (varobj_clear_saved_item)
6667 (update_dynamic_varobj_children, install_new_value, ~varobj):
6668 Update.
6669 * value.h (value_incref): Move declaration earlier.
6670 (value_decref): Rename from value_free.
6671 (struct value_ref_policy): New.
6672 (value_ref_ptr): New typedef.
6673 (struct value_deleter): Remove.
6674 (gdb_value_up): Remove typedef.
6675 (release_value): Change return type.
6676 (release_value_or_incref): Remove.
6677 * value.c (set_value_parent): Update.
6678 (value_incref): Change return type.
6679 (value_decref): Rename from value_free.
6680 (value_free_to_mark, free_all_values, free_value_chain): Update.
6681 (release_value): Return value_ref_ptr.
6682 (release_value_or_incref): Remove.
6683 (record_latest_value, set_internalvar, clear_internalvar):
6684 Update.
6685 * stack.c (info_frame_command): Don't call value_free.
6686 * python/py-value.c (valpy_dealloc, valpy_new)
6687 (value_to_value_object): Update.
6688 * printcmd.c (do_examine): Update.
6689 * opencl-lang.c (lval_func_free_closure): Update.
6690 * mi/mi-main.c (register_changed_p): Don't call value_free.
6691 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
6692 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
6693 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
6694 value_free.
6695 * guile/scm-value.c (vlscm_free_value_smob)
6696 (vlscm_scm_from_value): Update.
6697 * frame.c (frame_register_unwind, frame_unwind_register_signed)
6698 (frame_unwind_register_unsigned, get_frame_register_bytes)
6699 (put_frame_register_bytes): Don't call value_free.
6700 * findvar.c (address_from_register): Don't call value_free.
6701 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
6702 * dwarf2loc.c (entry_data_value_free_closure)
6703 (value_of_dwarf_reg_entry, free_pieced_value_closure)
6704 (dwarf2_evaluate_loc_desc_full): Update.
6705 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
6706 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
6707 (~watchpoint, watch_command_1)
6708 (invalidate_bp_value_on_memory_change): Update.
6709 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
6710
7f8a5d38
SM
67112018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
6712
6713 PR gdb/23022
6714 * warning.m4: Add -Wno-error=deprecated-register.
6715 * configure: Re-generate.
6716
8a76bd3b
TT
67172018-04-05 Tom Tromey <tom@tromey.com>
6718
6719 * linespec.h: Remove include of "vec.h".
6720
8e8d776e
TT
67212018-04-05 Tom Tromey <tom@tromey.com>
6722
6723 * linespec.c (typep): Remove typedef.
6724 (find_methods, find_superclass_methods): Take a std::vector.
6725 (find_method): Use std::vector.
6726
9b2f8581
TT
67272018-04-05 Tom Tromey <tom@tromey.com>
6728
6729 * utils.c (compare_strings): Remove.
6730 * utils.h (compare_strings): Remove.
6731 * objc-lang.h (find_imps): Update.
6732 * objc-lang.c (find_methods): Take a std::vector.
6733 (uniquify_strings, find_imps): Likewise.
6734 * linespec.c (find_methods): Take a std::vector.
6735 (decode_objc): Use std::vector.
6736 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
6737 a std::vector.
6738 (find_method, find_function_symbols): Use std::vector.
6739
459a2e4c
TT
67402018-04-05 Tom Tromey <tom@tromey.com>
6741
6742 * completer.c (completion_tracker::completion_tracker): Remove
6743 cast.
6744 (completion_tracker::discard_completions): Likewise.
6745 * breakpoint.c (ambiguous_names_p): Remove cast.
6746 * ada-lang.c (_initialize_ada_language): Remove cast.
6747 * utils.h (streq): Update.
6748 (streq_hash): Add new declaration.
6749 * utils.c (streq): Return bool.
6750 (streq_hash): New function.
6751
9be2c17a
TT
67522018-04-05 Tom Tromey <tom@tromey.com>
6753
6754 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
6755 Remove a string copy.
6756
f73c6ece
TT
67572018-04-05 Tom Tromey <tom@tromey.com>
6758
6759 * linespec.c (filter_results): Use std::vector.
6760 (decode_line_2, decode_line_full): Update.
6761
53a0f8a2
TT
67622018-04-05 Tom Tromey <tom@tromey.com>
6763
6764 * linespec.c (canonical_to_fullform): Return std::string.
6765 (filter_results): Update.
6766 (struct decode_line_2_item): Add constructor.
6767 <fullform, displayform>: Now std::string.
6768 (decode_line_2_compare_items): Now a std::sort comparator.
6769 (decode_line_2): Update.
6770
a5b5adf5
TT
67712018-04-05 Tom Tromey <tom@tromey.com>
6772
6773 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
6774 (unexpected_linespec_error): Update.
6775 (linespec_parse_basic, parse_linespec): Update.
6776
6a307fc5
TT
67772018-04-05 Tom Tromey <tom@tromey.com>
6778
6779 * linespec.c (linespec_parse_basic): Reindent.
6780
41c1efc6
TT
67812018-04-05 Tom Tromey <tom@tromey.com>
6782
6783 * minsyms.h (iterate_over_minimal_symbols): Update.
6784 * minsyms.c (iterate_over_minimal_symbols): Take a
6785 gdb::function_view.
6786 * linespec.c (struct collect_minsyms): Remove.
6787 (compare_msyms): Now a std::sort comparator.
6788 (add_minsym): Add parameters.
6789 (search_minsyms_for_name): Update. Use std::vector.
6790
c5edbf3d
TT
67912018-04-03 Tom Tromey <tom@tromey.com>
6792
6793 * mipsread.c (read_alphacoff_dynamic_symtab): Use
6794 gdb::byte_vector.
6795
b39efc48
WP
67962018-04-02 Weimin Pan <weimin.pan@oracle.com>
6797
6798 * MAINTAINERS (Write After Approval): Add Weimin Pan.
6799
121ad66c 68002018-04-02 Weimin Pan <weimin.pan@oracle.com>
79f18731
WP
6801
6802 PR gdb/16959
6803 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
6804 printing static type.
6805
09473be8
TT
68062018-04-01 Tom Tromey <tom@tromey.com>
6807
6808 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
6809 (rs6000_xfer_shared_libraries): Update.
6810
ec1f2d91
SM
68112018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
6812
6813 * common/gdb_vecs.h (char_ptr): Remove.
6814 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
6815
d8611974
SM
68162018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
6817
6818 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
6819 with std::vector.
6820 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
6821
a18ba4e4
SM
68222018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
6823
6824 * tracepoint.h (struct uploaded_tp): Initialize fields.
6825 <actions, step_actions, cmd_strings>: Change type to
6826 std::vector<char *>.
6827 * tracepoint.c (get_uploaded_tp): Allocate with new.
6828 (free_uploaded_tps): Free with delete.
6829 (parse_tracepoint_definition): Adjust to std::vector change.
6830 * breakpoint.c (read_uploaded_action): Likewise.
6831 (create_tracepoint_from_upload): Likewise.
6832 * ctf.c (ctf_write_uploaded_tp): Likewise.
6833 (SET_ARRAY_FIELD): Likewise.
6834 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
6835
a7961323
TT
68362018-03-30 Tom Tromey <tom@tromey.com>
6837
6838 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
6839 std::unique_ptr.
6840 (svr4_keep_data_in_core): Update.
6841 (svr4_read_so_list): Update.
6842
e83e4e24
TT
68432018-03-30 Tom Tromey <tom@tromey.com>
6844
6845 * windows-nat.c (handle_output_debug_string, handle_exception):
6846 Update.
6847 * target.h (target_read_string): Update.
6848 * target.c (target_read_string): Change "string" to
6849 unique_xmalloc_ptr.
6850 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
6851 Update.
6852 * solib-frv.c (frv_current_sos): Update.
6853 * solib-dsbt.c (dsbt_current_sos): Update.
6854 * solib-darwin.c (darwin_current_sos): Update.
6855 * linux-thread-db.c (inferior_has_bug): Update.
6856 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
6857 Update. Remove alloca.
6858 * ada-lang.c (ada_main_name): Update.
6859
263db9a1
TT
68602018-03-30 Tom Tromey <tom@tromey.com>
6861
6862 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
6863 (struct dwo_file_deleter): New.
6864 (dwo_file_up): New typedef.
6865 (open_and_init_dwo_file): Use dwo_file_up.
6866 (free_dwo_file_cleanup): Remove.
6867
5dafb3d1
TT
68682018-03-30 Tom Tromey <tom@tromey.com>
6869
6870 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
6871 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
6872
11ed8cad
TT
68732018-03-30 Tom Tromey <tom@tromey.com>
6874
6875 * dwarf2read.c (class free_cached_comp_units): New class.
6876 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
6877 (free_cached_comp_units): Remove function.
6878
9ae79dac
TT
68792018-03-30 Tom Tromey <tom@tromey.com>
6880
6881 * utils.h (make_cleanup_unpush_target): Remove.
6882 * inf-ptrace.c (struct target_unpusher): New.
6883 (target_unpush_up) New typedef.
6884 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
6885 target_unpush_up.
6886 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
6887
5aa89276
TT
68882018-03-27 Tom Tromey <tom@tromey.com>
6889
6890 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
6891
1dbeed45
TT
68922018-03-27 Pedro Alves <palves@redhat.com>
6893 Tom Tromey <tom@tromey.com>
6894
6895 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
6896 destructor. Now a class.
6897 (gdb_readline_wrapper_cleanup): Remove function.
6898 (gdb_readline_wrapper): Remove cleanups.
6899
c819b2c0
TT
69002018-03-27 Tom Tromey <tom@tromey.com>
6901
6902 * typeprint.h (struct type_print_options) <local_typedefs,
6903 global_typedefs>: Remove "struct" keyword.
6904 (class typedef_hash_table): New class.
6905 (recursively_update_typedef_hash, add_template_parameters)
6906 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
6907 (find_typedef_in_hash): Don't declare.
6908 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
6909 (typedef_hash_table::recursively_update): Rename from
6910 recursively_update_typedef_hash. Now a member.
6911 (typedef_hash_table::add_template_parameters): Rename from
6912 add_template_parameters. Now a member.
6913 (typedef_hash_table::typedef_hash_table): Now a constructor;
6914 rename from create_typedef_hash.
6915 (typedef_hash_table::~typedef_hash_table): Now a destructor;
6916 rename from free_typedef_hash.
6917 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
6918 (do_free_global_table): Remove.
6919 (typedef_hash_table::typedef_hash_table): New constructor; renamed
6920 from copy_type_recursive.
6921 (create_global_typedef_table): Remove.
6922 (typedef_hash_table::find_global_typedef): Now a member of
6923 typedef_hash_table.
6924 (typedef_hash_table::find_typedef): Rename from
6925 find_typedef_in_hash; now a member.
6926 (whatis_exp): Update.
6927 * extension.h (struct ext_lang_type_printers): Add constructor and
6928 destructor.
6929 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
6930 declare.
6931 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
6932 Now a constructor; rename from start_ext_lang_type_printers.
6933 (ext_lang_type_printers): Now a destructor; rename from
6934 free_ext_lang_type_printers.
6935 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
6936 Update.
6937 (c_type_print_base_struct_union): Update. Remove cleanups.
6938
608219fb
TT
69392018-03-27 Tom Tromey <tom@tromey.com>
6940
6941 * dwarf-index-write.c: Include <cmath>.
6942
3fcded8f
JB
69432018-03-27 Joel Brobecker <brobecker@adacore.com>
6944
6945 * NEWS: Add entry describing new "set|show varsize-limit" command.
6946 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
6947 command.
6948 * printcmd.c (_initialize_printcmd): Add "set var" alias of
6949 "set variable".
6950
cd4fb1b2
SM
69512018-03-27 Simon Marchi <simon.marchi@ericsson.com>
6952
6953 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
6954 dwarf-index-write.c
6955 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
6956 * dwarf-index-common.c: New file.
6957 * dwarf-index-common.h: New file.
6958 * dwarf-index-write.c: New file.
6959 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
6960 (struct dwarf2_section_info): Move from here.
6961 (dwarf2_section_info_def): Likewise.
6962 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
6963 (offset_type): Likewise.
6964 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
6965 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
6966 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
6967 (byte_swap): Likewise.
6968 (MAYBE_SWAP): Likewise.
6969 (dwarf2_per_cu_ptr): Likewise.
6970 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
6971 (struct tu_stats): Likewise.
6972 (struct dwarf2_per_objfile): Likewise.
6973 (struct dwarf2_per_cu_data): Likewise.
6974 (struct signatured_type): Likewise.
6975 (sig_type_ptr): Likewise.
6976 (DEF_VEC_P (sig_type_ptr)): Likewise.
6977 (INDEX4_SUFFIX): Likewise.
6978 (INDEX5_SUFFIX): Likewise.
6979 (DEBUG_STR_SUFFIX): Likewise.
6980 (dwarf2_read_section): Make non-static.
6981 (mapped_index_string_hash): Move from here.
6982 (dwarf5_djb_hash): Likewise.
6983 (file_write): Likewise.
6984 (class data_buf): Likewise.
6985 (struct symtab_index_entry): Likewise.
6986 (struct mapped_symtab): Likewise.
6987 (find_slot): Likewise.
6988 (hash_expand): Likewise.
6989 (add_index_entry): Likewise.
6990 (uniquify_cu_indices): Likewise.
6991 (class c_str_view): Likewise.
6992 (class c_str_view_hasher): Likewise.
6993 (class vector_hasher): Likewise.
6994 (write_hash_table): Likewise.
6995 (psym_index_map): Likewise.
6996 (struct addrmap_index_data): Likewise.
6997 (add_address_entry): Likewise.
6998 (add_address_entry_worker): Likewise.
6999 (write_address_map): Likewise.
7000 (symbol_kind): Likewise.
7001 (write_psymbols): Likewise.
7002 (struct signatured_type_index_data): Likewise.
7003 (write_one_signatured_type): Likewise.
7004 (recursively_count_psymbols): Likewise.
7005 (recursively_write_psymbols): Likewise.
7006 (class debug_names): Likewise.
7007 (check_dwarf64_offsets): Likewise.
7008 (psyms_seen_size): Likewise.
7009 (write_gdbindex): Likewise.
7010 (write_debug_names): Likewise.
7011 (assert_file_size): Likewise.
7012 (write_psymtabs_to_index): Likewise.
7013 (save_gdb_index_command): Likewise.
7014 (_initialize_dwarf2_read): Don't register the "save gdb-index"
7015 command.
7016 * dwarf2read.h: New file.
7017
59cc4834
JB
70182018-03-27 Joel Brobecker <brobecker@adacore.com>
7019
7020 PR gdb/22670
7021 * dwarf2read.c (dwarf2_physname): Do not return the demangled
7022 symbol name if the CU's language stores symbol names in linkage
7023 format.
7024 * language.h (struct language_defn)
7025 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
7026 all instances of this struct.
7027
67501539
TT
70282018-03-26 Tom Tromey <tom@tromey.com>
7029
7030 * stack.c (backtrace_command_1): Remove verbose code.
7031
76c939ac
TT
70322018-03-26 Tom Tromey <tom@tromey.com>
7033
7034 * python/py-framefilter.c (py_print_type): Don't catch
7035 exceptions. Return void.
7036 (py_print_value): Likewise.
7037 (py_print_single_arg): Likewise.
7038 (enumerate_args): Don't catch exceptions.
7039 (py_print_args): Likewise.
7040 (py_print_frame): Likewise.
7041 (gdbpy_apply_frame_filter): Catch exceptions here.
7042
9507b29c
TT
70432018-03-26 Tom Tromey <tom@tromey.com>
7044
7045 * stack.c (_initialize_stack): Remove trailing newlines from help
7046 text. Add "Usage" line to "backtrace" help.
7047
eb68e487
TT
70482018-03-26 Tom Tromey <tom@tromey.com>
7049
7050 PR python/16486:
7051 * python/py-framefilter.c (py_print_args): Call wrap_hint.
7052
1f111921
TT
70532018-03-26 Tom Tromey <tom@tromey.com>
7054
7055 * python/py-framefilter.c (py_print_single_arg): Return
7056 EXT_LANG_BT_ERROR from catch.
7057
fb7eb8b5
TT
70582018-03-26 Tom Tromey <tom@tromey.com>
7059
7060 PR backtrace/15584:
7061 * stack.c (backtrace_command_1): Move some code into no-filters
7062 "if".
7063
4ca59a9f
TT
70642018-03-26 Tom Tromey <tom@tromey.com>
7065
7066 * python/py-framefilter.c (throw_quit_or_print_exception): New
7067 function.
7068 (gdbpy_apply_frame_filter): Use it.
7069
92256134
TT
70702018-03-26 Tom Tromey <tom@tromey.com>
7071
7072 PR cli/17716:
7073 * python/py-framefilter.c (py_print_type, py_print_value)
7074 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
7075 RETURN_MASK_ERROR.
7076
7a630bc2
TT
70772018-03-26 Tom Tromey <tom@tromey.com>
7078
7079 * python/py-framefilter.c (enumerate_args): Use
7080 gdb::unique_xmalloc_ptr.
7081
63283d4a
TT
70822018-03-26 Tom Tromey <tom@tromey.com>
7083
7084 * python/py-framefilter.c (py_print_frame): Return
7085 EXT_LANG_BT_OK.
7086 (gdbpy_apply_frame_filter): Update comment.
7087 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
7088 Remove.
7089 <EXT_LANG_BT_NO_FILTERS>: Change value.
7090
978d6c75
TT
70912018-03-26 Tom Tromey <tom@tromey.com>
7092
7093 PR backtrace/15582:
7094 * stack.c (backtrace_command): Parse "hide" argument.
7095 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
7096 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
7097 constant.
7098
1cf7e640
TT
70992018-03-26 Tom Tromey <tom@tromey.com>
7100
7101 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
7102 add "flags".
7103 (backtrace_command): Remove "fulltrace", add "flags".
7104
ea3b0687
TT
71052018-03-26 Tom Tromey <tom@tromey.com>
7106
7107 * stack.c (backtrace_command): Rewrite command line parsing.
7108
9f034d75
SM
71092018-03-26 Simon Marchi <simon.marchi@ericsson.com>
7110
7111 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
7112
ce1459e5
SM
71132018-03-26 Simon Marchi <simon.marchi@ericsson.com>
7114
7115 * filename-seen-cache.h: Add include guard.
7116
4f7ae6f5
KS
71172018-03-26 Keith Seitz <keiths@redhat.com>
7118
7119 * symfile.c (place_section): Remove "struct" from section_addr_info
7120 in comment.
7121 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
7122 "struct" keyword from section_addr_info.
7123
5cd3e386
AH
71242018-03-26 Alan Hayward <alan.hayward@arm.com>
7125
7126 * regformats/regdef.h (reg): Add constructors.
7127
3e5ef9a4
PA
71282018-03-25 Pedro Alves <palves@redhat.com>
7129
7130 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
7131 if then/else bodies in var_func_name extraction.
7132
c88d2fcc 71332018-03-23 Weimin Pan <weimin.pan@oracle.com>
bce02d88
WP
7134
7135 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
7136 lookup_minimal_symbol() to find symbol entry.
7137 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
7138
b7fee5a3
KS
71392018-03-23 Keith Seitz <keiths@redhat.com>
7140
7141 PR c++/22968
7142 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
7143 nested type definitions for C++, too.
7144
2cc9b304
TT
71452018-03-23 Tom Tromey <tom@tromey.com>
7146
7147 * machoread.c (struct oso_el): Add a constructor. Don't define as
7148 a typedef.
7149 (macho_register_oso): Remove.
7150 (macho_symtab_read): Take a std::vector.
7151 (oso_el_compare_name): Now a std::sort comparator.
7152 (macho_symfile_read_all_oso): Take a std::vector.
7153 (macho_symfile_read): Use std::vector. Remove cleanups.
7154
a2b2bc12
TT
71552018-03-22 Tom Tromey <tom@tromey.com>
7156
7157 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
7158 (record_full_goto_bookmark): Use std::string.
7159
7a8f494c
PFC
71602018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7161
7162 PR tdep/18295
7163 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
7164 a single mask.
7165
dd6d677f
PFC
71662018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7167
7168 * rs6000-tdep.c (store_insn_p): New function.
7169 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
7170 and cr_reg to their unshifted values. Use store_insn_p to
7171 match LR saves using either R1 or fdata->alloca_reg. Use
7172 store_insn_p to match CR saves. Set alloca_reg_offset
7173 when alloca_reg and framep are set. Remove lr_reg shift
7174 when assigning to fdata->lr_register.
7175
26d6cec4
AA
71762018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
7177
7178 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
7179 command line args instead of emitting a warning.
7180
5d9310c4
SM
71812018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
7182
7183 * tracepoint.h (struct static_tracepoint_marker): Initialize
7184 fields, define default constructor, move constructor and move
7185 assignment, disable the rest.
7186 <str_id, extra>: Make std::string.
7187 (release_static_tracepoint_marker): Remove.
7188 (free_current_marker): Remove.
7189 * tracepoint.c (free_current_marker): Remove.
7190 (parse_static_tracepoint_marker_definition): Adjust to
7191 std::string, use new hex2str overload.
7192 (release_static_tracepoint_marker): Remove.
7193 (print_one_static_tracepoint_marker): Get marker by reference
7194 and adjust to std::string.
7195 (info_static_tracepoint_markers_command): Adjust to std::vector
7196 changes
7197 * target.h (static_tracepoint_marker_p): Remove typedef.
7198 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
7199 (struct target_ops) <to_static_tracepoint_marker_at>: Return
7200 bool.
7201 <to_static_tracepoint_markers_by_strid>: Return std::vector.
7202 * target-debug.h
7203 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
7204 (target_debug_print_std_vector_static_tracepoint_marker): New.
7205 (target_debug_print_struct_static_tracepoint_marker_p): Rename
7206 to...
7207 (target_debug_print_static_tracepoint_marker_p): ... this.
7208 * target-delegates.c: Re-generate.
7209 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
7210 Make std::string.
7211 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
7212 (decode_static_tracepoint_spec): Adjust to std::vector.
7213 (tracepoint_print_one_detail): Adjust to std::string.
7214 (strace_marker_decode_location): Adjust to std::string.
7215 (update_static_tracepoint): Adjust to std::string, remove call
7216 to release_static_tracepoint_marker.
7217 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
7218 Adjust to std::vector.
7219 * remote.c (remote_static_tracepoint_marker_at): Return bool.
7220 (remote_static_tracepoint_markers_by_strid): Adjust to
7221 std::vector.
7222 * common/rsp-low.h (hex2str): New overload with explicit count
7223 of bytes.
7224 * common/rsp-low.c (hex2str): New overload with explicit count
7225 of bytes.
7226 * unittests/rsp-low-selftests.c (test_hex2str): New function.
7227 (_initialize_rsp_low_selftests): Add test_hex2str test.
7228 * unittests/tracepoint-selftests.c
7229 (test_parse_static_tracepoint_marker_definition): Adjust to
7230 std::string.
7231
62c222b6
SM
72322018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
7233
7234 * tracepoint.c (parse_static_tracepoint_marker_definition):
7235 Consider case where the definition is followed by more
7236 definitions.
7237 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7238 tracepoint-selftests.c.
7239 * unittests/tracepoint-selftests.c: New.
7240
7eb2418f
PFC
72412018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7242
7243 * MAINTAINERS (Write After Approval): Add Pedro Franco de
7244 Carvalho.
7245
7cbe16e9
SR
72462018-03-20 Stephen Roberts <stephen.roberts@arm.com>
7247
3d6b3b82 7248 * symtab.c (find_pc_sect_line): fixed indentation.
7cbe16e9 7249
4ee89e90
SR
72502018-03-20 Stephen Roberts <stephen.roberts@arm.com>
7251
3d6b3b82 7252 * symtab.c (find_pc_sect_line): now uses binary search.
4ee89e90 7253
92630041
TT
72542018-03-19 Tom Tromey <tom@tromey.com>
7255
7256 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
7257 "IDENT" production.
7258
76727919
TT
72592018-03-19 Pedro Alves <palves@redhat.com>
7260 Tom Tromey <tom@tromey.com>
7261
7262 * unittests/observable-selftests.c: New file.
7263 * common/observable.h: New file.
7264 * observable.h: New file.
7265 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
7266 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
7267 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
7268 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
7269 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
7270 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
7271 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
7272 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
7273 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
7274 python/py-breakpoint.c, python/py-finishbreakpoint.c,
7275 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
7276 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
7277 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
7278 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
7279 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
7280 tui/tui-interp.c, valops.c: Update all users.
7281 * tui/tui-hooks.c (tui_bp_created_observer)
7282 (tui_bp_deleted_observer, tui_bp_modified_observer)
7283 (tui_inferior_exit_observer, tui_before_prompt_observer)
7284 (tui_normal_stop_observer, tui_register_changed_observer):
7285 Remove.
7286 (tui_observers_token): New global.
7287 (attach_or_detach, tui_attach_detach_observers): New functions.
7288 (tui_install_hooks, tui_remove_hooks): Use
7289 tui_attach_detach_observers.
7290 * record-btrace.c (record_btrace_thread_observer): Remove.
7291 (record_btrace_thread_observer_token): New global.
7292 * observer.sh: Remove.
7293 * observer.c: Rename to observable.c.
7294 * observable.c (namespace gdb_observers): Define new objects.
7295 (observer_debug): Move into gdb_observers namespace.
7296 (struct observer, struct observer_list, xalloc_observer_list_node)
7297 (xfree_observer_list_node, generic_observer_attach)
7298 (generic_observer_detach, generic_observer_notify): Remove.
7299 (_initialize_observer): Update.
7300 Don't include observer.inc.
7301 * Makefile.in (generated_files): Remove observer.h, observer.inc.
7302 (clean mostlyclean): Likewise.
7303 (observer.h, observer.inc): Remove targets.
7304 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
7305 (COMMON_SFILES): Use observable.c, not observer.c.
7306 * .gitignore: Remove observer.h.
7307
1cb1f3da
TT
73082018-03-18 Tom Tromey <tom@tromey.com>
7309
7310 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
7311 gdb::def_vector.
7312 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
7313
a06ab151
TT
73142018-03-17 Tom Tromey <tom@tromey.com>
7315
7316 * auto-load.c (auto_load_objfile_script_1): Use std::string.
7317
770623f7
TT
73182018-03-17 Tom Tromey <tom@tromey.com>
7319
7320 * target.c (class scoped_target_fd): New.
7321 (target_fileio_close_cleanup): Remove.
7322 (target_fileio_read_alloc_1): Use scoped_target_fd.
7323
39be3c7e
SM
73242018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
7325
7326 * silent-rules.mk: New.
7327 * Makefile.in: Include silent-rules.mk
7328 (srcdir, VPATH, top_srcdir): Move up.
7329 (COMPILE): Add ECHO_CXX.
7330 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
7331 (init.c): Add ECHO_INIT_C.
7332 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
7333 (version.c): Add ECHO_GEN.
7334 (printcmd.o): Add ECHO_CXX.
7335 (target-float.o): Add ECHO_CXX.
7336 (ada-exp.o): Add ECHO_CXX.
7337 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
7338 (insight$(EXEEXT)): Add ECHO_CXXLD.
7339 * gnulib/configure.ac: Add AM_SILENT_RULES.
7340 * gnulib/aclocal.m4: Re-generate.
7341 * gnulib/configure: Re-generate.
7342 * gnulib/import/Makefile.in: Re-generate.
7343
37e136b1
TT
73442018-03-16 Tom Tromey <tom@tromey.com>
7345
7346 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
7347 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
7348 * utils.c (do_free_section_addr_info)
7349 (make_cleanup_free_section_addr_info): Remove.
7350 * symfile.h (struct other_sections): Add constructor.
7351 (struct section_addr_info): Remove.
7352 (section_addr_info): New typedef.
7353 (struct sym_fns) <sym_offsets>: Change type of parameter.
7354 (build_section_addr_info_from_objfile)
7355 (relative_addr_info_to_section_offsets, addr_info_make_relative)
7356 (default_symfile_offsets, symbol_file_add)
7357 (symbol_file_add_from_bfd)
7358 (build_section_addr_info_from_section_table): Update.
7359 (alloc_section_addr_info, free_section_addr_info): Don't declare.
7360 * symfile.c (alloc_section_addr_info): Remove.
7361 (build_section_addr_info_from_section_table): Change return type.
7362 Update.
7363 (build_section_addr_info_from_bfd)
7364 (build_section_addr_info_from_objfile): Likewise.
7365 (free_section_addr_info): Remove.
7366 (relative_addr_info_to_section_offsets): Change type of "addrs".
7367 (addrs_section_compar): Now a std::sort comparator.
7368 (addrs_section_sort): Change return type.
7369 (addr_info_make_relative): Change type of "addrs". Update.
7370 (default_symfile_offsets, syms_from_objfile_1)
7371 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
7372 (symbol_file_add_separate): Update.
7373 (symbol_file_add): Change type of "addrs". Update.
7374 (add_symbol_file_command): Update. Remove cleanups.
7375 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
7376 cleanups.
7377 * symfile-debug.c (debug_sym_offsets): Change type of "info".
7378 * solib.c (solib_read_symbols): Update.
7379 * objfiles.c (objfile_relocate): Update. Remove cleanups.
7380 * machoread.c (macho_symfile_offsets): Update.
7381 * jit.c (jit_bfd_try_read_symtab): Update.
7382
03afa6ef
SM
73832018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
7384
7385 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7386 unittests/utils-selftests.c.
7387 * unittests/utils-selftests.c: New file.
7388
3ae9ce5d
TT
73892018-03-14 Tom Tromey <tom@tromey.com>
7390
7391 PR cli/14977:
7392 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
7393 for NULL.
7394
b8c2339b
TT
73952018-03-14 Tom Tromey <tom@tromey.com>
7396
7397 PR cli/19918:
7398 * printcmd.c (printf_pointer): Allow "-" in format.
7399
80ae639d
TT
74002018-03-14 Tom Tromey <tom@tromey.com>
7401
7402 * printcmd.c (_initialize_printcmd): Add usage to printf.
7403
0d671d99
YQ
74042018-03-14 Yao Qi <qiyao@sourceware.org>
7405
7406 * MAINTAINERS: Update my email address.
7407
b577b6af
TT
74082018-03-13 Tom Tromey <tom@tromey.com>
7409
7410 * machoread.c (macho_check_dsym): Change filenamep to a
7411 std::string*.
7412 (macho_symfile_read): Update.
7413 * symfile.c (load_command): Use std::string.
7414
89a3b63e
AB
74152018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
7416
7417 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
7418 to error message string.
7419 (riscv_register_name): Use xsnprintf instead of sprintf.
7420 (riscv_insn::fetch_instruction): Use gdb_assert instead of
7421 internal_error.
7422 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
7423 error.
7424 (riscv_push_dummy_call): Likewise.
7425
984c7238
TT
74262018-03-12 Tom Tromey <tom@tromey.com>
7427
7428 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
7429 Use gdb::byte_vector.
7430 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
7431
933522d1
YQ
74322018-03-12 Yao Qi <yao.qi@linaro.org>
7433
7434 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
7435 parameter type to readable_regcache.
7436 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
7437 the declaration.
7438
be2daae6
TT
74392018-03-11 Tom Tromey <tom@tromey.com>
7440
7441 * dwarf2read.c (struct nextfield): Add initializers.
7442 (struct nextfnfield): Remove.
7443 (struct fnfieldlist): Add initializers. Remove "length" and
7444 "head", use std::vector.
7445 (struct decl_field_list): Remove.
7446 (struct field_info): Add initializers.
7447 <fields, baseclasses>: Now std::vector.
7448 <nbaseclasses, nfnfields, typedef_field_list_count,
7449 nested_types_list_count>: Remove.
7450 (dwarf2_add_field, dwarf2_add_type_defn)
7451 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
7452 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
7453 (process_structure_scope): Update.
7454
484cf504
TT
74552018-03-11 Tom Tromey <tom@tromey.com>
7456
7457 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
7458 for use by std::sort.
7459 (build_type_psymtabs_1): Use std::vector.
7460
9bd8e0b0
EZ
74612018-03-09 Eli Zaretskii <eliz@gnu.org>
7462
7463 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
7464 and LIBMPFR in the printed configuration.
7465
5dc1a704
TT
74662018-03-08 Tom Tromey <tom@tromey.com>
7467
7468 * source.c (get_filename_and_charpos): Use scoped_fd.
7469 * nto-procfs.c (procfs_open_1): Use scoped_fd.
7470 (procfs_pidlist): Likewise.
7471 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
7472 (iterate_over_mappings): Likewise.
7473
fdf07f3a
TT
74742018-03-08 Tom Tromey <tom@tromey.com>
7475
7476 * infcall.c (struct call_return_meta_info)
7477 <stack_temporaries_enabled>: Remove.
7478 (get_call_return_value, call_function_by_hand_dummy): Update.
7479 * thread.c (disable_thread_stack_temporaries): Remove.
7480 (enable_thread_stack_temporaries): Remove.
7481 (thread_stack_temporaries_enabled_p): Return bool.
7482 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
7483 (get_last_thread_stack_temporary): Update.
7484 * eval.c (evaluate_subexp): Update.
7485 * gdbthread.h (class enable_thread_stack_temporaries): Now a
7486 class, not a function.
7487 (value_ptr, value_vec): Remove typedefs.
7488 (class thread_info) <stack_temporaries_enabled>: Now bool.
7489 <stack_temporaries>: Now a std::vector.
7490 (thread_stack_temporaries_enabled_p)
7491 (value_in_thread_stack_temporaries): Return bool.
7492
567a3e54
SM
74932018-03-08 Simon Marchi <simon.marchi@ericsson.com>
7494
7495 * remote.c (putpkt_binary): Fix omitted bytes reporting.
7496 (getpkt_or_notif_sane_1): Likewise.
7497
00b40057
SM
74982018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
7499
7500 * build-id.c (build_id_to_debug_bfd): Use std::string.
7501
a8dbfd58
SM
75022018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
7503
7504 * build-id.c (find_separate_debug_file_by_buildid): Return
7505 std::string.
7506 * build-id.h (find_separate_debug_file_by_buildid): Return
7507 std::string.
7508 * coffread.c (coff_symfile_read): Adjust to std::string.
7509 * elfread.c (elf_symfile_read): Adjust to std::string.
7510 * symfile.c (separate_debug_file_exists): Change parameter to
7511 std::string.
7512 (find_separate_debug_file): Return std::string.
7513 (find_separate_debug_file_by_debuglink): Return std::string.
7514 * symfile.h (find_separate_debug_file_by_debuglink): Return
7515 std::string.
7516
e6a58aa8
SM
75172018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
7518
7519 * common/xml-utils.c (xml_escape_text): Move code to...
7520 (xml_escape_text_append): ... this new function.
7521 * common/xml-utils.h (xml_escape_text_append): New declaration.
7522 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
7523 New function.
7524 (_initialize_xml_utils): register test_xml_escape_text_append as
7525 a selftest.
7526
4ef0bef6
AH
75272018-03-07 Alan Hayward <alan.hayward@arm.com>
7528
7529 * defs.h: Remove MAX_REGISTER_SIZE.
7530 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
7531 asserts.
7532 * python/py-unwind.c (pyuw_sniffer): Likewise.
7533
e0d3522b
TT
75342018-03-07 Tom Tromey <tom@tromey.com>
7535
7536 * linux-tdep.c (linux_info_proc): Update.
7537 * target.h (struct target_ops) <to_fileio_readlink>: Return
7538 optional<string>.
7539 (target_fileio_readlink): Return optional<string>.
7540 * remote.c (remote_hostio_readlink): Return optional<string>.
7541 * inf-child.c (inf_child_fileio_readlink): Return
7542 optional<string>.
7543 * target.c (target_fileio_readlink): Return optional<string>.
7544
ea005f31
AB
75452018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
7546
7547 * regcache.c (cooked_read_test): Add riscv to the list of
7548 architectures that have a save_reggroup.
7549
e95a97d4
AA
75502018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
7551
7552 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
7553 value is not a dynamic class object.
7554
d8344f3d
TT
75552018-03-06 Tom Tromey <tom@tromey.com>
7556
7557 * rust-exp.y: Formatting fixes.
7558
9add17f2
AB
75592018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7560
7561 * riscv-tdep.c (riscv_register_name): Remove target description
7562 support.
7563 (riscv_gdbarch_init): Remove target description check.
7564
c9486dfe
AB
75652018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7566
7567 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
7568 comment.
7569 * riscv-tdep.h: Likewise.
7570
d74aff3d
AB
75712018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7572
7573 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
7574 (riscv_pseudo_register_write): Delete.
7575 (riscv_gdbarch_init): Remove all use of pseudo registers.
7576
7ea78b59
SM
75772018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7578
7579 * record-btrace.c (btrace_print_lines): Replace cleanup
7580 parameter with RAII equivalents.
7581 (btrace_insn_history): Replace cleanup with RAII equivalents.
7582 * ui-out.h (make_cleanup_ui_out_list_begin_end,
7583 make_cleanup_ui_out_tuple_begin_end): Remove.
7584 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
7585 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
7586 make_cleanup_ui_out_list_begin_end): Remove.
7587
53127008
SM
75882018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7589
7590 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
7591 parameter types to std::vector. Use bool.
7592 (record_btrace_wait): Replace VEC(tp_t) with
7593 std::vector<thread_info *>.
7594 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
7595
228f1508
SM
75962018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7597
7598 * record-btrace.c (record_btrace_disable_callback): Remove.
7599 (struct scoped_btrace_disable): New.
7600 (record_btrace_open): Use scoped_btrace_disable.
7601
b2970c23
AB
76022018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7603
7604 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
7605 reading values from registers.
7606
fb294655
AB
76072018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7608
7609 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
7610 where appropriate.
7611
cab5bb9d
AB
76122018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7613
7614 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
7615 change parameter type. Use GDB's print functions, and use
7616 core_addr_to_string where appropriate.
7617 (riscv_push_dummy_call): Use core_addr_to_string where
7618 appropriate, update call to riscv_print_arg_location, and reindent
7619 a few lines.
7620 (riscv_return_value): Update call to riscv_print_arg_location.
7621
dbbb1059
AB
76222018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7623 Tim Newsome <tim@sifive.com>
7624 Albert Ou <a0u@eecs.berkeley.edu>
7625 Darius Rad <darius@bluespec.com>
7626
7627 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
7628 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
7629 (ALLDEPFILES): Add riscv-tdep.c
7630 * configure.tgt: Add riscv support.
7631 * riscv-tdep.c: New file.
7632 * riscv-tdep.h: New file.
7633 * NEWS: Mention new target.
7634 * MAINTAINERS: Add entry for riscv.
7635
5dc43913
AB
76362018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7637
7638 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
7639 fields within aggregates.
7640
3dea1ef7
SM
76412018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
7642
7643 * record-btrace.c (btrace_print_lines): Change type of flags to
7644 gdb_disassembly_flags.
7645
7efba073
JB
76462018-03-04 John Baldwin <jhb@FreeBSD.org>
7647
7648 * fbsd-nat.c: Include "inf-ptrace.h".
7649 (USE_SIGTRAP_SIGINFO): Conditionally define.
7650 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
7651 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
7652 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
7653 function.
7654 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
7655 Likewise.
7656 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
7657 Likewise.
7658 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
7659 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
7660 "supports_stopped_by_hw_breakpoint" target methods.
7661
386a8676
JB
76622018-03-04 John Baldwin <jhb@FreeBSD.org>
7663
7664 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
7665 * fbsd-nat.c (debug_fbsd_nat): New variable.
7666 (show_fbsd_nat_debug): New function.
7667 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
7668 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
7669
12279366
JB
76702018-03-04 John Baldwin <jhb@FreeBSD.org>
7671
7672 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
7673 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
7674 prototype.
7675 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
7676 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
7677 method.
7678
54693cf5
SM
76792018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7680
7681 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
7682 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
7683
ccb2231c
SM
76842018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7685
7686 * charset.c (struct charset_vector): New.
7687 (charsets): Change type to charset_vector.
7688 (find_charset_names): Adjust.
7689 (add_one): Adjust.
7690 (_initialize_charset): Adjust.
7691
6fb16ce6
SM
76922018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7693
7694 * progspace.h (struct program_space) <deleted_solibs>: Change
7695 type to std::vector<std::string>.
7696 * progspace.c (clear_program_space_solib_cache): Adjust.
7697 * breakpoint.c (print_solib_event): Adjust.
7698 (check_status_catch_solib): Adjust.
7699 * solib.c (update_solib_list): Adjust.
7700 * ui-out.h (class ui_out) <field_string>: New overload.
7701 * ui-out.c (ui_out::field_string): New overload.
7702
564b1e3f
SM
77032018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7704
7705 * progspace.h (struct program_space): Add constructor and
7706 destructor, initialize fields.
7707 (add_program_space): Remove.
7708 * progspace.c (add_program_space): Rename to...
7709 (program_space::program_space): ... this.
7710 (release_program_space): Rename to...
7711 (program_space::~program_space): ... this.
7712 (delete_program_space): Use delete to delete program_space.
7713 (initialize_progspace): Use new to allocate program_space.
7714 * inferior.c (add_inferior_with_spaces): Likewise.
7715 (clone_inferior_command): Likewise.
7716 * infrun.c (follow_fork_inferior): Likewise.
7717 (handle_vfork_child_exec_or_exit): Likewise.
7718
e80aaf61
SM
77192018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7720
7721 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
7722 (delim_string_to_char_ptr_vec): Return std::vector of
7723 gdb::unique_xmalloc_ptr.
7724 (dirnames_to_char_ptr_vec_append): Take std::vector of
7725 gdb::unique_xmalloc_ptr.
7726 (dirnames_to_char_ptr_vec): Return std::vector of
7727 gdb::unique_xmalloc_ptr.
7728 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
7729 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
7730 (delim_string_to_char_ptr_vec): Return an std::vector of
7731 gdb::unique_xmalloc_ptr, adjust the code.
7732 (dirnames_to_char_ptr_vec_append): Take an std::vector of
7733 gdb::unique_xmalloc_ptr, adjust the code.
7734 (dirnames_to_char_ptr_vec): Return an std::vector of
7735 gdb::unique_xmalloc_ptr, adjust the code.
7736 * auto-load.c (auto_load_safe_path_vec): Change type to
7737 std::vector of gdb::unique_xmalloc_ptr.
7738 (auto_load_expand_dir_vars): Return an std::vector of
7739 gdb::unique_xmalloc_ptr, adjust the code.
7740 (auto_load_safe_path_vec_update): Adjust.
7741 (filename_is_in_auto_load_safe_path_vec): Adjust.
7742 (auto_load_objfile_script_1): Adjust.
7743 * build-id.c (build_id_to_debug_bfd): Adjust.
7744 * linux-thread-db.c (thread_db_load_search): Adjust.
7745 * source.c (add_path): Adjust.
7746 (openp): Adjust.
7747 * symfile.c (find_separate_debug_file): Adjust.
7748 * utils.c (do_free_char_ptr_vec): Remove.
7749 (make_cleanup_free_char_ptr_vec): Remove.
7750
ab818ade
SDJ
77512018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
7752
7753 PR gdb/22907
7754 * common/pathstuff.c: Conditionally include "<windows.h>".
7755
e1e6f073
GS
77562018-03-01 Georg Sauthoff <mail@georg.so>
7757
7758 PR gdb/22888
7759 * gcore.in: Quote variables and switch interpreter to bash.
7760
c7b15a66
TT
77612018-03-01 Tom Tromey <tom@tromey.com>
7762
7763 * dwarf2read.c (alloc_discriminant_info): Fix default_index
7764 assertion. Add assertion for discriminant_index.
7765 (quirk_rust_enum): Use correct base type name in univariant case.
7766
0cb7c7b0
SM
77672018-03-01 Simon Marchi <simon.marchi@ericsson.com>
7768
7769 * record.c (get_call_history_modifiers): Return a
7770 record_print_flags.
7771 (cmd_record_call_history): Adjust.
7772 * record-btrace.c (record_btrace_call_history): Adjust.
7773 (record_btrace_call_history_range): Adjust.
7774 (record_btrace_call_history_from): Adjust.
7775 * target-debug.h (target_debug_print_record_print_flags): New.
7776 * target-delegates.c: Re-generate.
7777 * target.c (target_call_history): Change flags type.
7778 (target_call_history_from): Likewise.
7779 (target_call_history_range): Likewise.
7780 * target.h (struct target_ops) <target_call_history>: Likewise.
7781 (target_call_history_from): Likewise.
7782 (target_call_history_range): Likewise.
7783
25e3c82c
SDJ
77842018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
7785 Simon Marchi <simon.marchi@polymtl.ca>
7786
7787 * common/common-utils.c: Include "sys/stat.h".
7788 (is_regular_file): Move here from "source.c"; change return
7789 type to "bool".
7790 * common/common-utils.h (is_regular_file): New prototype.
7791 * common/pathstuff.c (contains_dir_separator): New function.
7792 * common/pathstuff.h (contains_dir_separator): New prototype.
7793 * source.c: Don't include "sys/stat.h".
7794 (is_regular_file): Move to "common/common-utils.c".
7795
b4987c95
SDJ
77962018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
7797
7798 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
7799 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
7800 * auto-load.c: Include "common/pathstuff.h".
7801 * common/common-def.h (current_directory): Move here.
7802 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
7803 function.
7804 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
7805 prototype.
7806 * common/pathstuff.c: New file.
7807 * common/pathstuff.h: New file.
7808 * compile/compile.c: Include "common/pathstuff.h".
7809 * defs.h (current_directory): Move to "common/common-defs.h".
7810 * dwarf2read.c: Include "common/pathstuff.h".
7811 * exec.c: Likewise.
7812 * guile/scm-safe-call.c: Likewise.
7813 * linux-thread-db.c: Likewise.
7814 * main.c: Likewise.
7815 * nto-tdep.c: Likewise.
7816 * objfiles.c: Likewise.
7817 * source.c: Likewise.
7818 * symtab.c: Likewise.
7819 * utils.c: Include "common/pathstuff.h".
7820 (gdb_realpath): Move to "common/pathstuff.c".
7821 (gdb_realpath_keepfile): Likewise.
7822 (gdb_abspath): Likewise.
7823 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
7824 (gdb_realpath_keepfile): Likewise.
7825 (gdb_abspath): Likewise.
7826
f169cfdc
JB
78272018-02-28 John Baldwin <jhb@FreeBSD.org>
7828
7829 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
7830 wildcard process pid for super_resume for kernels with a
7831 specific bug.
7832
e05cac70
PM
78332018-02-27 Phil Muldoon <pmuldoon@redhat.com>
7834
7835 * compile/compile.c (get_args): Add additional comments
7836 explaining function.
7837
55089490
TT
78382018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
7839 Tom Tromey <tom@tromey.com>
7840
7841 * target.h (memory_write_request_s): Remove typedef. Don't define
7842 VEC.
7843 (target_write_memory_blocks): Change argument to std::vector.
7844 (struct memory_write_request): Add constructor.
7845 * target-memory.c (compare_block_starting_address): Return bool.
7846 Change argument types.
7847 (claim_memory): Change arguments to use std::vector.
7848 (split_regular_and_flash_blocks, blocks_to_erase)
7849 (compute_garbled_blocks): Likewise.
7850 (cleanup_request_data, cleanup_write_requests_vector): Remove.
7851 (target_write_memory_blocks): Change argument to std::vector.
7852 * symfile.c (struct load_section_data): Add constructor and
7853 destructor. Use std::vector for "requests".
7854 (struct load_progress_data): Add initializers.
7855 (load_section_callback): Update. Use "new".
7856 (clear_memory_write_data): Remove.
7857 (generic_load): Update.
7858
0c305b61
AH
78592018-02-27 Alan Hayward <alan.hayward@arm.com>
7860
7861 * arch/aarch64.h: Use common/tdesc.h.
7862
c5196c92
MR
78632018-02-26 Maciej W. Rozycki <macro@mips.com>
7864
7865 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
7866 architecture with a 64-bit ABI.
7867
37c33887
MR
78682018-02-26 Maciej W. Rozycki <macro@mips.com>
7869
7870 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
7871 ahead of target description loading.
7872
d4dd3282
TT
78732018-02-26 Tom Tromey <tom@tromey.com>
7874
7875 * stack.c (backtrace_command_1): Update.
7876 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
7877 of "flags".
7878 * python/py-framefilter.c (py_print_frame)
7879 (gdbpy_apply_frame_filter): Change type of "flags".
7880 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
7881 of "flags".
7882 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
7883 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
7884 * extension.h (enum frame_filter_flag): Rename from
7885 frame_filter_flags.
7886 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
7887 (apply_ext_lang_frame_filter): Change type of "flags".
7888 * extension.c (apply_ext_lang_frame_filter): Change type of
7889 "flags".
7890 * extension-priv.h (struct extension_language_ops)
7891 <apply_frame_filter>: Change type of "flags".
7892
6893c19a
TT
78932018-02-26 Tom Tromey <tom@tromey.com>
7894
7895 PR python/16497:
7896 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
7897 off-by-one in py_end computation.
7898 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
7899 PRINT_MORE_FRAMES.
7900 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
7901 constant.
7902
2ddeaf8a
TT
79032018-02-26 Tom Tromey <tom@tromey.com>
7904
7905 * dwarf2read.c (struct variant_field): New.
7906 (struct nextfield) <variant>: New field.
7907 (dwarf2_add_field): Handle DW_TAG_variant_part.
7908 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
7909 discriminated union.
7910 (read_structure_type): Handle DW_TAG_variant_part.
7911 (handle_struct_member_die): New function, extracted from
7912 process_structure_scope. Handle DW_TAG_variant.
7913 (process_structure_scope): Handle discriminated unions. Call
7914 handle_struct_member_die.
7915
c9317f21
TT
79162018-02-26 Tom Tromey <tom@tromey.com>
7917
7918 * rust-lang.h (rust_last_path_segment): Declare.
7919 * rust-lang.c (rust_last_path_segment): Now public. Change
7920 contract.
7921 (struct disr_info): Remove.
7922 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
7923 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
7924 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
7925 (rust_enum_p, rust_enum_variant): New function.
7926 (rust_underscore_fields): Remove "offset" parameter.
7927 (rust_print_enum): New function.
7928 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
7929 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
7930 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
7931 enums.
7932 (rust_internal_print_type): New function, from rust_print_type.
7933 Remove enum code.
7934 (rust_print_type): Call rust_internal_print_type.
7935 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
7936 Update enum handling.
7937 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
7938 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
7939 (rust_union_quirks): New functions.
7940 (process_full_comp_unit, process_full_type_unit): Call
7941 rust_union_quirks.
7942 (process_structure_scope): Update rust_unions if necessary.
7943
7c22600a
TT
79442018-02-26 Tom Tromey <tom@tromey.com>
7945
7946 * value.h (value_union_variant): Declare.
7947 * valops.c (value_union_variant): New function.
7948 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
7949 (struct discriminant_info): New.
7950 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
7951 enumerator.
7952 (struct main_type) <flag_discriminated_union>: New field.
7953
15ce8941
TT
79542018-02-26 Tom Tromey <tom@tromey.com>
7955
7956 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7957 unittests/unpack-selftests.c.
7958 * unittests/unpack-selftests.c: New file.
7959 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
7960
48fbe735
YQ
79612018-02-26 Yao Qi <yao.qi@linaro.org>
7962
7963 * dwarf2read.c (struct partial_die_info) <read>: New method.
7964 (read_partial_die): Remove the declaration.
7965 (load_partial_dies): Update.
7966 (partial_die_info::partial_die_info):
7967 (read_partial_die): Change it to partial_die_info::read.
7968
52356b79
YQ
79692018-02-26 Yao Qi <yao.qi@linaro.org>
7970
7971 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
7972 (fixup_partial_die): Remove declaration.
7973 (scan_partial_symbols): Update.
7974 (partial_die_parent_scope): Likewise.
7975 (partial_die_full_name): Likewise.
7976 (fixup_partial_die): Change it to partial_die_info::fixup.
7977
35cc7ed7
YQ
79782018-02-26 Yao Qi <yao.qi@linaro.org>
7979
7980 * dwarf2read.c (read_partial_die): Update the declaration.
7981 (load_partial_dies): Caller update.
7982 (read_partial_die): Remove one argument abbrev_len.
7983
6f06d47b
YQ
79842018-02-26 Yao Qi <yao.qi@linaro.org>
7985
7986 * dwarf2read.c (struct partial_die_info): Add ctor, delete
7987 assignment operator.
7988 (load_partial_dies): Use ctor and copy ctor.
7989 (read_partial_die): Update.
7990 (dwarf2_cu::find_partial_die): Use ctor.
7991
d590ff25
YQ
79922018-02-26 Yao Qi <yao.qi@linaro.org>
7993
7994 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
7995 (find_partial_die_in_comp_unit): Change it to
7996 dwarf2_cu::find_partial_die.
7997 (find_partial_die): Update.
7998
fd0a254f
YQ
79992018-02-26 Yao Qi <yao.qi@linaro.org>
8000
8001 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
8002 is NULL.
8003
cd9983dd
YQ
80042018-02-26 Yao Qi <yao.qi@linaro.org>
8005
8006 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
8007
f46cd62a
AH
80082018-02-26 Alan Hayward <alan.hayward@arm.com>
8009
8010 * arch/amd64.h: Use common/tdesc.h.
8011 * arch/i386.c: Likewise.
8012 * arch/i386.h: Likewise.
8013 * arch/tic6x.c: Likewise.
8014 * arch/tdesc.h: Move file from here...
8015 * common/tdesc.h: ...to here.
8016 * features/aarch64-core.c: Regenerate.
8017 * features/aarch64-fpu.c: Regenerate.
8018 * features/i386/32bit-avx.c: Regenerate.
8019 * features/i386/32bit-avx512.c: Regenerate.
8020 * features/i386/32bit-core.c: Regenerate.
8021 * features/i386/32bit-linux.c: Regenerate.
8022 * features/i386/32bit-mpx.c: Regenerate.
8023 * features/i386/32bit-pkeys.c: Regenerate.
8024 * features/i386/32bit-sse.c: Regenerate.
8025 * features/i386/64bit-avx.c: Regenerate.
8026 * features/i386/64bit-avx512.c: Regenerate.
8027 * features/i386/64bit-core.c: Regenerate.
8028 * features/i386/64bit-linux.c: Regenerate.
8029 * features/i386/64bit-mpx.c: Regenerate.
8030 * features/i386/64bit-pkeys.c: Regenerate.
8031 * features/i386/64bit-segments.c: Regenerate.
8032 * features/i386/64bit-sse.c: Regenerate.
8033 * features/i386/x32-core.c: Regenerate.
8034 * features/tic6x-c6xp.c: Regenerate.
8035 * features/tic6x-core.c: Regenerate.
8036 * features/tic6x-gp.c: Regenerate.
8037 * target-descriptions.c: Use common/tdesc.h.
8038 * target-descriptions.h: Likewise.
8039
9b292f68
TT
80402018-02-24 Tom Tromey <tom@tromey.com>
8041
8042 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
8043 (try_thread_db_load_from_dir, thread_db_load_search): Use
8044 std::string.
8045 (info_auto_load_libthread_db_compare): Return bool. Change
8046 argument types.
8047 (info_auto_load_libthread_db): Use std::vector, std::string.
8048 Remove cleanups.
8049
281d762b
TT
80502018-02-24 Tom Tromey <tom@tromey.com>
8051
8052 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
8053 std::string.
8054 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
8055 std::string*.
8056 * gdbarch.c: Rebuild.
8057 * gdbarch.h: Rebuild.
8058 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
8059 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
8060 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
8061 std::string*.
8062
9d8780f0
SM
80632018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
8064
8065 * gdbtypes.h (sect_offset): Change type to uint64_t.
8066 (sect_offset_str): New function.
8067 * dwarf2read.c (create_addrmap_from_aranges): Use
8068 sect_offset_str.
8069 (error_check_comp_unit_head): Likewise.
8070 (create_debug_type_hash_table): Likewise.
8071 (read_cutu_die_from_dwo): Likewise.
8072 (init_cutu_and_read_dies): Likewise.
8073 (init_cutu_and_read_dies_no_follow): Likewise.
8074 (process_psymtab_comp_unit_reader): Likewise.
8075 (partial_die_parent_scope): Likewise.
8076 (peek_die_abbrev): Likewise.
8077 (process_queue): Likewise.
8078 (dwarf2_physname): Likewise.
8079 (read_namespace_alias): Likewise.
8080 (read_import_statement): Likewise.
8081 (create_dwo_cu_reader): Likewise.
8082 (create_cus_hash_table): Likewise.
8083 (lookup_dwo_cutu): Likewise.
8084 (inherit_abstract_dies): Likewise.
8085 (read_func_scope): Likewise.
8086 (read_call_site_scope): Likewise.
8087 (dwarf2_add_member_fn): Likewise.
8088 (read_common_block): Likewise.
8089 (read_module_type): Likewise.
8090 (read_typedef): Likewise.
8091 (read_subrange_type): Likewise.
8092 (load_partial_dies): Likewise.
8093 (read_partial_die): Likewise.
8094 (find_partial_die): Likewise.
8095 (read_str_index): Likewise.
8096 (dwarf2_string_attr): Likewise.
8097 (build_error_marker_type): Likewise.
8098 (lookup_die_type): Likewise.
8099 (dump_die_shallow): Likewise.
8100 (follow_die_ref): Likewise.
8101 (dwarf2_fetch_die_loc_sect_off): Likewise.
8102 (dwarf2_fetch_constant_bytes): Likewise.
8103 (follow_die_sig): Likewise.
8104 (get_signatured_type): Likewise.
8105 (get_DW_AT_signature_type): Likewise.
8106 (dwarf2_find_containing_comp_unit): Likewise.
8107 (set_die_type): Likewise.
8108
8ec57239
JB
81092018-02-21 John Baldwin <jhb@FreeBSD.org>
8110
8111 * arch/aarch64.c: Include "common-defs.h".
8112 * arch/amd64.c: Likewise.
8113 * arch/i386.c: Likewise.
8114
3eac2b65
TT
81152018-02-21 Tom Tromey <tom@tromey.com>
8116
8117 * value.h: (extract_field_op): Update.
8118 * eval.c (extract_field_op): Return a const char *.
8119 * expression.h (parse_expression_for_completion): Update.
8120 * completer.c (complete_expression): Update.
8121 (add_struct_fields): Make fieldname const.
8122 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
8123 (mark_completion_tag, parse_exp_in_context_1): Update.
8124 (parse_expression_for_completion): Change "name" to
8125 unique_xmalloc_ptr*.
8126
6ccb583f
TT
81272018-02-21 Tom Tromey <tom@tromey.com>
8128
8129 * infcall.c (call_function_by_hand_dummy): Use std::vector.
8130
c113ed0c
YQ
81312018-02-21 Yao Qi <yao.qi@linaro.org>
8132
8133 * avr-tdep.c (avr_read_pc): Change parameter type to
8134 readable_regcache.
8135 * gdbarch.sh (read_pc): Likewise.
8136 * gdbarch.c: Re-generated.
8137 * gdbarch.h: Re-generated.
8138 * hppa-tdep.c (hppa_read_pc): Change parameter type to
8139 readable_regcache.
8140 * ia64-tdep.c (ia64_read_pc): Likewise.
8141 * mips-tdep.c (mips_read_pc): Likewise.
8142 * spu-tdep.c (spu_read_pc): Likewise.
8143
4c74fe6b
YQ
81442018-02-21 Yao Qi <yao.qi@linaro.org>
8145
8146 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
8147 * regcache-dump.c: New file.
8148 * regcache.c: Move register_dump to regcache-dump.c.
8149 (maintenance_print_registers): Likewise.
8150 (maintenance_print_raw_registers): Likewise.
8151 (maintenance_print_cooked_registers): Likewise.
8152 (maintenance_print_register_groups): Likewise.
8153 (maintenance_print_remote_registers): Likewise.
8154 (_initialize_regcache): Likewise.
8155 * regcache.h (register_dump): Moved from regcache.c.
8156
796bb026
YQ
81572018-02-21 Yao Qi <yao.qi@linaro.org>
8158
8159 * regcache.c (regcache::regcache): Update.
8160 (regcache::invalidate): Move it to detached_regcache::invalidate.
8161 (get_thread_arch_aspace_regcache): Update.
8162 (regcache::raw_update): Update.
8163 (regcache::cooked_read): Remove some code.
8164 (regcache::cooked_read_value): Likewise.
8165 (regcache::raw_write): Remove assert on m_readonly_p.
8166 (regcache::raw_supply_integer): Move it to
8167 detached_regcache::raw_supply_integer.
8168 (regcache::raw_supply_zeroed): Likewise.
8169 * regcache.h (detached_regcache) <raw_supply_integer>: New
8170 declaration.
8171 <raw_supply_zeroed, invalidate>: Likewise.
8172 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
8173 <invalidate>: Likewise.
8174 <m_readonly_p>: Removed.
8175
215c69dc
YQ
81762018-02-21 Yao Qi <yao.qi@linaro.org>
8177
8178 * infcmd.c (get_return_value): Let stop_regs point to
8179 get_current_regcache.
8180 * regcache.c (regcache::regcache): Remove.
8181 (register_dump_reg_buffer): New class.
8182 (regcache_print): Adjust.
8183 * regcache.h (regcache): Remove constructors.
8184
f3384e66
YQ
81852018-02-21 Yao Qi <yao.qi@linaro.org>
8186
8187 * regcache.c (class register_dump): New class.
8188 (register_dump_regcache, register_dump_none): New class.
8189 (register_dump_remote, register_dump_groups): New class.
8190 (regcache_print): Update.
8191 * regcache.h (regcache_dump_what): Move it to regcache.c.
8192 (regcache) <dump>: Remove.
8193
c8ec2f33
YQ
81942018-02-21 Yao Qi <yao.qi@linaro.org>
8195
8196 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
8197 reg_buffer_rw *.
8198 (jit_unwind_reg_set_impl): Call raw_supply.
8199 (jit_frame_sniffer): Use reg_buffer_rw.
8200 * record-full.c (record_full_core_regbuf): Change its type.
8201 (record_full_core_open_1): Use reg_buffer_rw.
8202 (record_full_close): Likewise.
8203 (record_full_core_fetch_registers): Use regcache->raw_supply.
8204 (record_full_core_store_registers): Likewise.
8205 * regcache.c (regcache::get_register_status): Move it to
8206 reg_buffer.
8207 (regcache_raw_set_cached_value): Remove.
8208 (regcache::raw_set_cached_value): Remove.
8209 (regcache::raw_write): Call raw_supply.
8210 (regcache::raw_supply): Move it to reg_buffer_rw.
8211 * regcache.h (regcache_raw_set_cached_value): Remove.
8212 (reg_buffer_rw): New class.
8213
daf6667d
YQ
82142018-02-21 Yao Qi <yao.qi@linaro.org>
8215
8216 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
8217 readonly_detached_regcache.
8218 (dummy_frame_prev_register): Use regcache->cooked_read.
8219 * frame.c (frame_save_as_regcache): Change return type.
8220 (frame_pop): Update.
8221 * frame.h (frame_save_as_regcache): Update declaration.
8222 * inferior.h (get_infcall_suspend_state_regcache): Update
8223 declaration.
8224 * infrun.c (infcall_suspend_state) <registers>: use
8225 readonly_detached_regcache.
8226 (save_infcall_suspend_state): Don't use regcache_dup.
8227 (get_infcall_suspend_state_regcache): Change return type.
8228 * linux-fork.c (struct fork_info) <savedregs>: Change to
8229 readonly_detached_regcache.
8230 <pc>: New field.
8231 (fork_save_infrun_state): Don't use regcache_dup.
8232 (info_checkpoints_command): Adjust.
8233 * mi/mi-main.c (register_changed_p): Update declaration.
8234 (mi_cmd_data_list_changed_registers): Use
8235 readonly_detached_regcache.
8236 (register_changed_p): Change parameter type to
8237 readonly_detached_regcache.
8238 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
8239 readonly_detached_regcache.
8240 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
8241 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
8242 New.
8243 (regcache::save): Move it to reg_buffer.
8244 (regcache::restore): Change parameter type.
8245 (regcache_dup): Remove.
8246 * regcache.h (reg_buffer) <save>: New method.
8247 (readonly_detached_regcache): New class.
8248 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
8249 readonly_detached_regcache.
8250 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
8251
fc5b8736
YQ
82522018-02-21 Yao Qi <yao.qi@linaro.org>
8253
8254 * frame.c (frame_save_as_regcache): Use regcache method save.
8255 (frame_pop): Use regcache method restore.
8256 * infrun.c (restore_infcall_suspend_state): Likewise.
8257 * linux-fork.c (fork_load_infrun_state): Likewise.
8258 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
8259 save.
8260 * regcache.c (regcache_save): Remove.
8261 (regcache::restore): More asserts.
8262 (regcache_cpy): Remove.
8263 * regcache.h (regcache_save): Remove the declaration.
8264 (regcache::restore): Move from private to public.
8265 Remove the friend declaration of regcache_cpy.
8266 (regcache_cpy): Remove declaration.
8267
849d0ba8
YQ
82682018-02-21 Yao Qi <yao.qi@linaro.org>
8269
8270 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
8271 parameter type to 'readable_regcache *'.
8272 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
8273 * arm-tdep.c (arm_neon_quad_read): Likewise.
8274 (arm_pseudo_read): Likewise.
8275 * avr-tdep.c (avr_pseudo_register_read): Likewise.
8276 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
8277 * frv-tdep.c (frv_pseudo_register_read): Likewise.
8278 * gdbarch.c: Re-generated.
8279 * gdbarch.h: Re-generated.
8280 * gdbarch.sh (pseudo_register_read): Change parameter type to
8281 'readable_regcache *'.
8282 (pseudo_register_read_value): Likewise.
8283 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
8284 (h8300_pseudo_register_read): Likewise.
8285 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
8286 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
8287 (i386_pseudo_register_read_into_value): Likewise.
8288 (i386_pseudo_register_read_value): Likewise.
8289 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
8290 declaration.
8291 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
8292 * m32c-tdep.c (m32c_raw_read): Likewise.
8293 (m32c_read_flg): Likewise.
8294 (m32c_banked_register): Likewise.
8295 (m32c_banked_read): Likewise.
8296 (m32c_sb_read): Likewise.
8297 (m32c_part_read): Likewise.
8298 (m32c_cat_read): Likewise.
8299 (m32c_r3r2r1r0_read): Likewise.
8300 (m32c_pseudo_register_read): Likewise.
8301 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
8302 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
8303 (mep_pseudo_cr64_read): Likewise.
8304 (mep_pseudo_register_read): Likewise.
8305 * mips-tdep.c (mips_pseudo_register_read): Likewise.
8306 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
8307 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
8308 * regcache.c (regcache::raw_read): Move it to readable_regcache.
8309 (regcache::cooked_read): Likewise.
8310 (regcache::cooked_read_value): Likewise.
8311 (regcache_cooked_read_signed):
8312 (regcache::cooked_read): Likewise.
8313 * regcache.h (readable_regcache): New class.
8314 (regcache): Inherit readable_regcache. Move some methods to
8315 readable_regcache.
8316 * rl78-tdep.c (rl78_pseudo_register_read): Change
8317 parameter type to 'readable_regcache *'.
8318 * rs6000-tdep.c (do_regcache_raw_read): Remove.
8319 (e500_pseudo_register_read): Change parameter type to
8320 'readable_regcache *'.
8321 (dfp_pseudo_register_read): Likewise.
8322 (vsx_pseudo_register_read): Likewise.
8323 (efpr_pseudo_register_read): Likewise.
8324 * s390-tdep.c (s390_pseudo_register_read): Likewise.
8325 * sh-tdep.c (sh_pseudo_register_read): Likewise.
8326 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
8327 (sh64_pseudo_register_read): Likewise.
8328 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
8329 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
8330 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
8331 (spu_pseudo_register_read): Likewise.
8332 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
8333 (xtensa_pseudo_register_read): Likewise.
8334
31716595
YQ
83352018-02-21 Yao Qi <yao.qi@linaro.org>
8336
8337 * regcache.c (regcache::regcache): Call reg_buffer ctor.
8338 (regcache::arch): Move it to reg_buffer::arch.
8339 (regcache::register_buffer): Likewise.
8340 (regcache::assert_regnum): Likewise.
8341 (regcache::num_raw_registers): Likewise.
8342 * regcache.h (reg_buffer): New class.
8343 (regcache): Inherit reg_buffer.
8344
7104e59b
SM
83452018-02-20 Simon Marchi <simon.marchi@ericsson.com>
8346
8347 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
8348 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
8349
2d8adcbd
MM
83502018-02-20 Markus Metzger <markus.t.metzger@intel.com>
8351
8352 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
8353
b5884fa7
AH
83542018-02-19 Alan Hayward <alan.hayward@arm.com>
8355
8356 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
8357 (SFILES): Remove common/*.c files.
8358 (COMMON_OBS): Remove some *.o files built from common/*.c files.
8359 * common/common.host: Add common reference.
8360 * configure.ac: Likewise.
8361 * configure: Regenerate.
8362
fd90ace4
YQ
83632018-02-16 Yao Qi <yao.qi@linaro.org>
8364
8365 * block.c (block_namespace_info): Inherit allocate_on_obstack.
8366 (block_initialize_namespace): Use new.
8367 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
8368 (dwarf2_free_objfile): Use delete.
8369 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
8370 (copy_type_recursive): Use new.
8371 * gdb_obstack.h (allocate_on_obstack): New.
8372
85046ae2
YQ
83732018-02-15 Yao Qi <yao.qi@linaro.org>
8374
8375 PR gdb/22849
8376 * inferior.c (exit_inferior_1): Reset inf->control.
8377
355c559b
JB
83782018-02-15 Joel Brobecker <brobecker@adacore.com>
8379
8380 * ada-lang.c (ada_to_fixed_value_create): Delete advance
8381 declaration.
8382
980548fd
PA
83832018-02-14 Pedro Alves <palves@redhat.com>
8384
8385 * frame-unwind.c (frame_unwind_try_unwinder): Always call
8386 frame_cleanup_after_sniffer on exception.
8387
692d6f97
TT
83882018-02-14 Tom Tromey <tom@tromey.com>
8389
8390 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
8391 const.
8392 (solib_bfd_open): Make pathname const.
8393 * solib.c (solib_bfd_open): Make pathname const.
8394 * solib-spu.c (spu_bfd_fopen): Make name const.
8395 (spu_bfd_open): Make pathname const.
8396 * solib-darwin.c (darwin_bfd_open): Make pathname const.
8397 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
8398
e0cc99a6
TT
83992018-02-14 Tom Tromey <tom@tromey.com>
8400
8401 * symfile.c (symfile_bfd_open): Update.
8402 * source.h (openp, source_full_path_of, find_and_open_source):
8403 Change argument type to unique_xmalloc_ptr.
8404 * source.c (openp): Take a unique_xmalloc_ptr.
8405 (source_full_path_of, find_and_open_source): Likewise.
8406 (open_source_file, symtab_to_fullname): Update.
8407 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
8408 unique_xmalloc_ptr.
8409 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
8410 (exec_file_find): Update.
8411 * psymtab.c (psymtab_to_fullname): Update.
8412 * nto-tdep.h (nto_find_and_open_solib): Update.
8413 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
8414 unique_xmalloc_ptr.
8415 * exec.c (exec_file_attach): Update.
8416 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
8417 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
8418
b46a8d7c
TT
84192018-02-14 Tom Tromey <tom@tromey.com>
8420
8421 * solib.c: Include source.h.
8422 * nto-tdep.c: Include source.h.
8423 * mi/mi-cmd-env.c: Include source.h.
8424 * infcmd.c: Include source.h.
8425 * exec.c: Include source.h.
8426 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
8427 (add_path, directory_switch, source_path, init_source_path): Move
8428 declarations...
8429 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
8430 (add_path, directory_switch, source_path, init_source_path):
8431 ...here.
8432
797bc1cb
TT
84332018-02-14 Tom Tromey <tom@tromey.com>
8434
8435 * solist.h (exec_file_find, solib_find): Return
8436 unique_xmalloc_ptr.
8437 (solib_bfd_fopen): Take a const char *.
8438 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
8439 (exec_file_find, solib_find): Likewise.
8440 (solib_bfd_fopen): Do not take ownership of "pathname".
8441 (solib_bfd_open): Use unique_xmalloc_ptr.
8442 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
8443 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
8444 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
8445 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
8446
f98b2e33
JB
84472018-02-14 Joel Brobecker <brobecker@adacore.com>
8448
8449 * ada-lang.c (name_match_type_from_name): Remove reference to
8450 ada_name_for_lookup in function's documentation.
8451 * ada-lang.h (ada_name_for_lookup): Delete declaration.
8452
24b9144d
SM
84532018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
8454
8455 * defs.h (enum openp_flags): New enum.
8456 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
8457 Move to enum openp_flags.
8458 (openp_flags): New enum flags.
8459 (openp): Change parameter type to openp_flags.
8460 * source.c (openp): Change parameter type to openp_flags.
8461 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
8462 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
8463
387cd15b
SM
84642018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
8465
8466 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
8467 per-command.
8468
b303c6f6
AB
84692018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
8470
8471 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
8472 into...
8473 (class dwarf2_queue_guard): ...the destructor of this new class.
8474 (dw2_do_instantiate_symtab): Create instance of the new class
8475 dwarf2_queue_guard, remove cleanup.
8476
9c3630e9
TT
84772018-02-09 Tom Tromey <tom@tromey.com>
8478
8479 * source.c (find_source_lines): Don't reference past the end of
8480 the vector.
8481
c4e12631
MM
84822018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8483
8484 * remote.c (remote_btrace_maybe_reopen): Change error message.
8485 * btrace.c (btrace_enable): Likewise.
8486 (parse_xml_btrace): Likewise.
8487 (parse_xml_btrace_conf): Likewise.
8488
88711fbf
MM
84892018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8490
8491 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
8492 (linux_enable_pt, linux_enable_bts): Call
8493 diagnose_perf_event_open_fail.
8494
17ad2a4f
MM
84952018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8496
8497 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
8498 Remove parameter and change return type. Update callers. Move it.
8499 (linux_enable_bts, linux_enable_pt): Improve error message.
8500 (linux_enable_pt): Remove zero buffer size check.
8501 (linux_enable_btrace): Improve error messages. Remove NULL return
8502 check.
8503
de6242d3
MM
85042018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8505
8506 * btrace.c (btrace_enable): Remove target_supports_btrace call.
8507 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
8508 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
8509 (linux_supports_pt, linux_supports_btrace): Remove.
8510 (linux_enable_bts): Call cpu_supports_bts.
8511 * nat/linux-btrace.h (linux_supports_btrace): Remove.
8512 * remote.c (remote_supports_btrace): Remove.
8513 (init_remote_ops): Remove remote_supports_btrace.
8514 * target-delegates.c: Regenerated.
8515 * target.c (target_supports_btrace): Remove.
8516 * target.h (target_ops) <to_supports_btrace>: Remove
8517 (target_supports_btrace): Remove.
8518 * x86-linux-nat.c (x86_linux_create_target): Remove
8519 linux_supports_btrace.
8520
9ee23a85
MM
85212018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8522
8523 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
8524 btrace failed.
8525 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
8526 exception and use message in own exception.
8527
5c3284c1
MM
85282018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8529
8530 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
8531 (perf_event_pt_event_type): Use gdb_file_up.
8532 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
8533 scoped_fd, and scoped_mmap.
8534
84696f37
MM
85352018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8536
8537 * common/scoped_mmap.h: New.
8538 * unittests/scoped_mmap-selftest.c: New.
8539 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8540 unittests/scoped_mmap-selftest.c.
8541
ea4a0888
MM
85422018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8543
8544 * common/scoped_fd.h: New.
8545 * unittests/scoped_fd-selftest.c: New.
8546 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8547 unittests/scoped_fd-selftest.c.
8548
869e8290
TT
85492018-02-09 Tom Tromey <tom@tromey.com>
8550
8551 * auto-load.c (auto_load_section_scripts): Use
8552 gdb::unique_xmalloc_ptr.
8553
a37a2ae7
TT
85542018-02-09 Tom Tromey <tom@tromey.com>
8555
8556 * auto-load.c (execute_script_contents): Use std::string.
8557
4e725347
JB
85582018-02-09 Joel Brobecker <brobecker@adacore.com>
8559
8560 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
8561 Python function, rather than a new command.
8562
9a897d43
TT
85632018-02-08 Tom Tromey <tom@tromey.com>
8564
8565 * solib.c (solib_find_1): Use std::string.
8566 (solib_bfd_fopen): Use unique_xmalloc_ptr.
8567
58ef3771
TT
85682018-02-08 Tom Tromey <tom@tromey.com>
8569
8570 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
8571
a9abc434
TT
85722018-02-08 Tom Tromey <tom@tromey.com>
8573
8574 * source.c (find_source_lines): Use gdb::def_vector.
8575
84f27c6f
TT
85762018-02-08 Tom Tromey <tom@tromey.com>
8577
8578 * macrocmd.c (struct temporary_macro_definition): New.
8579 (macro_define_command): Use temporary_macro_definition. Remove
8580 cleanups.
8581 (free_macro_definition_ptr): Remove.
8582
0354904b
TT
85832018-02-08 Tom Tromey <tom@tromey.com>
8584
8585 * macroexp.c (maybe_expand): Use std::string.
8586
1739cf24
TT
85872018-02-08 Tom Tromey <tom@tromey.com>
8588
8589 * macroexp.c (struct macro_buffer): Add initializers for some
8590 members.
8591 (init_buffer, init_shared_buffer, free_buffer)
8592 (free_buffer_return_text): Remove.
8593 (macro_buffer): New constructors.
8594 (~macro_buffer): New destructor.
8595 (macro_buffer::set_shared): New method.
8596 (macro_buffer::resize_buffer, macro_buffer::appendc)
8597 (macro_buffer::appendmem): Now methods, not free functions.
8598 (set_token, append_tokens_without_splicing, stringify)
8599 (macro_stringify): Update.
8600 (gather_arguments): Change return type. Remove argc_p argument,
8601 add args_ptr argument. Use std::vector.
8602 (substitute_args): Remove argc argument. Accept std::vector.
8603 (expand): Update. Use std::vector.
8604 (scan, macro_expand, macro_expand_next): Update.
8605
f6c2623e
TT
86062018-02-08 Tom Tromey <tom@tromey.com>
8607
8608 * symtab.c (default_collect_symbol_completion_matches_break_on):
8609 Use unique_xmalloc_ptr.
8610 * macroscope.h: (sal_macro_scope, user_macro_scope)
8611 (default_macro_scope): Return unique_xmalloc_ptr.
8612 * macroscope.c (sal_macro_scope, user_macro_scope)
8613 (default_macro_scope): Return unique_xmalloc_ptr.
8614 * macroexp.h (macro_expand, macro_expand_once): Return
8615 unique_xmalloc_ptr.
8616 * macroexp.c (macro_expand, macro_expand_once): Return
8617 unique_xmalloc_ptr.
8618 * macrocmd.c (macro_expand_command, macro_expand_once_command)
8619 (info_macro_command, info_macros_command): Use
8620 unique_xmalloc_ptr.
8621 * compile/compile-c-support.c (write_macro_definitions): Use
8622 unique_xmalloc_ptr.
8623 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
8624
c2e0e465
SM
86252018-02-07 Simon Marchi <simon.marchi@ericsson.com>
8626
8627 * value.c (value_static_field): Assign field type instead of
8628 containing type when returning an optimized out value.
8629
3f8c94b4
YQ
86302018-02-06 Yao Qi <yao.qi@linaro.org>
8631
8632 * ft32-tdep.c (ft32_read_pc): Remove.
8633 (ft32_write_pc): Remove.
8634 (ft32_gdbarch_init): Update.
8635 * m32r-tdep.c (m32r_read_pc): Remove.
8636 (m32r_gdbarch_init): Update.
8637 * mep-tdep.c (mep_read_pc): Remove.
8638 (mep_gdbarch_init): Update.
8639 * microblaze-tdep.c (microblaze_write_pc): Remove.
8640 (microblaze_gdbarch_init): Update.
8641 * mn10300-tdep.c (mn10300_read_pc): Remove.
8642 (mn10300_write_pc): Remove.
8643 (mn10300_gdbarch_init): Update.
8644 * moxie-tdep.c (moxie_read_pc): Remove.
8645 (moxie_write_pc): Remove.
8646 (moxie_gdbarch_init): Update.
8647
bca65a23
YQ
86482018-02-06 Yao Qi <yao.qi@linaro.org>
8649
8650 * expprint.c (print_subexp_standard): Handle
8651 OP_F77_UNDETERMINED_ARGLIST.
8652 (dump_subexp_body_standard): Likewise.
8653
583e3f90 86542018-02-05 Alan Hayward <alan.hayward@arm.com>
b8df6ca7 8655
583e3f90
YQ
8656 * target-descriptions.c (tdesc_element_visitor) Add empty
8657 implementations.
b8df6ca7
AH
8658 (tdesc_type): Move make_gdb_type from here.
8659 (tdesc_type_builtin): Likewise.
8660 (tdesc_type_vector): Likewise.
8661 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
8662 (make_gdb_type_struct): Move from tdesc_type_with_fields.
8663 (make_gdb_type_union): Likewise.
8664 (make_gdb_type_flags): Likewise.
8665 (make_gdb_type_enum): Likewise.
8666 (make_gdb_type): New function.
8667 (tdesc_register_type): Use static make_gdb_type.
8668
e813d34a
RK
86692018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
8670
8671 * infcmd.c (default_print_one_register_info): Align natural-format
8672 column values consistently one under another.
8673 (pad_to_column): New function.
8674
0eb876f5
JB
86752018-02-05 Joel Brobecker <brobecker@adacore.com>
8676
8677 * dwarf2read.c (dwarf2_physname): Move commment.
8678
0625771b
LS
86792018-02-01 Leszek Swirski <leszeks@google.com>
8680
8681 * varobj.c (varobj_formatted_print_options): Allow recursive
8682 pretty printing if pretty printing is enabled.
8683
59498c30
LS
86842018-02-01 Leszek Swirski <leszeks@google.com>
8685
8686 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
8687 names after a structop as a filename.
8688
2d9e6acb
YQ
86892018-02-01 Yao Qi <yao.qi@linaro.org>
8690
8691 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
8692 (arm_record_coproc_data_proc): Likewise.
8693
df95a9cf
YQ
86942018-02-01 Yao Qi <yao.qi@linaro.org>
8695
8696 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
8697
07e5f5cf
NP
86982018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
8699
8700 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
8701 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
8702
3045b475
PA
87032018-01-31 Pedro Alves <palves@redhat.com>
8704
8705 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
8706 * inflow.c (child_terminal_save_inferior): Wrap reference to
8707 tcgetpgrp in HAVE_TERMIOS_H.
8708 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
8709 _WIN32.
8710 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
8711 always iterate over all inferiors.
8712 (gdbsim_cntrl_c): Adjust.
8713 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
8714
929b5ad4
JB
87152018-01-31 Joel Brobecker <brobecker@adacore.com>
8716
8717 * gdbtypes.c (lookup_array_range_type): Make sure the array's
8718 index type is objfile-owned if the element type is as well.
8719
29236ca2
JB
87202018-01-31 Joel Brobecker <brobecker@adacore.com>
8721
8722 GDB 8.1 released.
8723
c81e8879
PR
87242018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
8725
8726 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
8727 "features/s390x-linux64.c".
8728 (_initialize_s390_linux_tdep): Remove initialization of tdescs
8729 s390_linux32 and s390x_linux64.
8730 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
8731 default tdesc.
8732 * s390-tdep.c: Include "features/s390-linux32.c" and
8733 "features/s390x-linux64.c".
8734 (s390_tdesc_valid): Add check for tdesc_has_registers.
8735 (s390_gdbarch_init): Make sure there is always a valid tdesc.
8736 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
8737 tdesc_s390x_linux64.
8738 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
8739 tdesc_s390x_linux64 to...
8740 * s390-tdep.h: ...here.
8741
e671cd59
PA
87422018-01-30 Pedro Alves <palves@redhat.com>
8743
8744 PR gdb/13211
8745 * config.in, configure: Regenerate.
8746 * configure.ac: Check for getpgid.
8747 * go32-nat.c (go32_pass_ctrlc): New.
8748 (go32_target): Install it.
8749 * inf-child.c (inf_child_target): Install
8750 child_terminal_save_inferior, child_pass_ctrlc and
8751 child_interrupt.
8752 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
8753 (inf_ptrace_target): No longer install it.
8754 * infcmd.c (interrupt_target_1): Adjust.
8755 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
8756 (child_interrupt): Declare.
8757 (inferior::terminal_state): New.
8758 * inflow.c (struct terminal_info): Update comments.
8759 (inferior_process_group): Delete.
8760 (terminal_is_ours): Delete.
8761 (gdb_tty_state): New.
8762 (child_terminal_init): Adjust.
8763 (is_gdb_terminal, sharing_input_terminal_1)
8764 (sharing_input_terminal): New functions.
8765 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
8766 Set the process's actual process group in the foreground if
8767 possible. Handle is_ours_for_output/is_ours distinction. Don't
8768 mark terminal as the inferior's if not sharing GDB's terminal.
8769 Don't check attach_flag.
8770 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
8771 pass down a target_terminal_state.
8772 (child_terminal_save_inferior): New, factored out from ...
8773 (child_terminal_ours_1): ... this. Handle
8774 target_terminal_state::is_ours_for_output.
8775 (child_interrupt, child_pass_ctrlc): New.
8776 (inflow_inferior_exit): Clear the inferior's terminal_state.
8777 (copy_terminal_info): Copy the inferior's terminal state.
8778 (_initialize_inflow): Remove reference to terminal_is_ours.
8779 * inflow.h (inferior_process_group): Delete.
8780 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
8781 * procfs.c (procfs_target): Don't install procfs_interrupt.
8782 (procfs_interrupt): Delete.
8783 * remote.c (remote_serial_quit_handler): Adjust.
8784 (remote_interrupt): Remove ptid parameter. Adjust.
8785 * target-delegates.c: Regenerate.
8786 * target.c: Include "terminal.h".
8787 (target_terminal::terminal_state): Rename to ...
8788 (target_terminal::m_terminal_state): ... this.
8789 (target_terminal::init): Adjust.
8790 (target_terminal::inferior): Adjust to per-inferior
8791 terminal_state.
8792 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
8793 (target_terminal::ours, target_terminal::ours_for_output): Use
8794 target_terminal_is_ours_kind.
8795 (target_interrupt): Remove ptid parameter. Adjust.
8796 (default_target_pass_ctrlc): Adjust.
8797 * target.h (target_ops::to_terminal_save_inferior): New field.
8798 (target_ops::to_interrupt): Remove ptid_t parameter.
8799 (target_interrupt): Remove ptid_t parameter. Update comment.
8800 (target_pass_ctrlc): Update comment.
8801 * target/target.h (target_terminal_state): New scoped enum,
8802 factored out of ...
8803 (target_terminal::terminal_state): ... here.
8804 (target_terminal::inferior): Update comments.
8805 (target_terminal::restore_inferior): New.
8806 (target_terminal::is_inferior, target_terminal::is_ours)
8807 (target_terminal::is_ours_for_output): Adjust.
8808 (target_terminal::scoped_restore_terminal_state): Adjust to
8809 rename, and call restore_inferior() instead of inferior().
8810 (target_terminal::scoped_restore_terminal_state::m_state): Change
8811 type.
8812 (target_terminal::terminal_state): Rename to ...
8813 (target_terminal::m_terminal_state): ... this and change type.
8814
9c3a5d93
PA
88152018-01-30 Pedro Alves <palves@redhat.com>
8816
8817 * linux-nat.c (wait_for_signal): New function.
8818 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
8819 directly.
8820 (async_terminal_is_ours)
8821 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
8822 (linux_nat_add_target): Don't override
8823 to_terminal_inferior/to_terminal_ours.
8824
69ab5edb
SDJ
88252018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
8826
8827 * remote.c (remote_follow_fork): Don't call "detach_inferior".
8828
fc8e7e75
SM
88292018-01-28 Simon Marchi <simon.marchi@ericsson.com>
8830
8831 * dwarf2read.c (free_dwo_files): Add forward-declaration.
8832 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
8833 dwarf2_per_objfile_free here.
8834 (dwarf2_per_objfile_free): Remove.
8835 (_initialize_dwarf2_read): Don't register
8836 dwarf2_per_objfile_free as a registry cleanup.
8837
b2a426e2
EZ
88382018-01-27 Eli Zaretskii <eliz@gnu.org>
8839
8840 Avoid compilation errors in MinGW native builds
8841
8842 The error is triggered by including python-internal.h, and the
8843 error message is:
8844
8845 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
8846 from build-gnulib/import/math.h:27,
8847 from d:/usr/Python26/include/pyport.h:235,
8848 from d:/usr/Python26/include/Python.h:58,
8849 from python/python-internal.h:94,
8850 from python/py-arch.c:24:
8851 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
8852 using ::hypot;
8853 ^~~~~
8854
8855 This happens because Python headers define 'hypot' to expand t
8856 '_hypot' in the Windows builds.
8857 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
8858 'hypoth'. This avoids a compilation error.
8859
0bdd8eac
AH
88602018-01-26 Alan Hayward <alan.hayward@arm.com>
8861
8862 * MAINTAINERS (Write After Approval): Fix ordering.
8863
56ae9dc3
AH
88642018-01-26 Alan Hayward <alan.hayward@arm.com>
8865
8866 * MAINTAINERS (Write After Approval): Add Alan Hayward.
8867
7433498b
AM
88682018-01-26 Alan Modra <amodra@gmail.com>
8869
8870 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
8871 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
8872 Remove nop. Make const. Comment.
8873 (powerpc32_plt_stub_so_2): New.
8874 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
8875 Correct count. Update uses.
8876 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
8877 Move common code reading PLT entry word. Correct
8878 powerpc32_plt_stub PLT address calculation.
8879 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
8880 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
8881 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
8882 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
8883 (ppc64_standard_linkage8): Likewise.
8884 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
8885 Correct insns description.
8886 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
8887
0f59d5fc
PA
88882018-01-24 Pedro Alves <palves@redhat.com>
8889
8890 GCC PR libstdc++/83906
8891 * gdbtypes.c (operator==(const dynamic_prop &,
8892 const dynamic_prop &)): New.
8893 (operator==(const range_bounds &, const range_bounds &)): New.
8894 (check_types_equal): Use them instead of memcmp.
8895 * gdbtypes.h (operator==(const dynamic_prop &,
8896 const dynamic_prop &)): Declare.
8897 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
8898 (operator==(const range_bounds &, const range_bounds &)): Declare.
8899 (operator!=(const range_bounds &, const range_bounds &)): Declare.
8900
ef8914a4
PR
89012018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8902
8903 * s390-linux-tdep.c (s390_record_address_mask)
8904 (s390_record_calc_disp_common, s390_record_calc_disp)
8905 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
8906 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
8907 (s390_process_record): Move to s390-tdep.c.
8908 (s390_linux_init_abi_any): Adjust.
8909 * s390-tdep.c (s390_record_address_mask)
8910 (s390_record_calc_disp_common, s390_record_calc_disp)
8911 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
8912 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
8913 (s390_process_record): Moved from s390-linux-tdep.c
8914 (s390_gdbarch_init): Adjust.
8915
d6e58945
PR
89162018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8917
8918 * s390-linux-nat.c (s390-tdep.h): New include.
8919 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
8920 (HFILES_NO_SRCDIR): Add s390-tdep.h.
8921 (ALLDEPFILES): Add s390-tdep.c.
8922 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
8923 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
8924 * s390-tdep.h: ...this. New file.
8925 * s390-linux-tdep.c (s390-tdep.h): New include.
8926 (_initialize_s390_tdep): Rename to...
8927 (_initialize_s390_linux_tdep): ...this and adjust.
8928 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
8929 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
8930 s390-tdep.h.
8931 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
8932 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
8933 (s390_is_partial_instruction, s390_software_single_step)
8934 (is_non_branch_ril, s390_displaced_step_copy_insn)
8935 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
8936 (s390_prologue_data, s390_addr, s390_store, s390_load)
8937 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
8938 (s390_register_call_saved, s390_guess_tracepoint_registers)
8939 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
8940 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
8941 (s390_pseudo_register_name, s390_pseudo_register_type)
8942 (s390_pseudo_register_read, s390_pseudo_register_write)
8943 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
8944 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
8945 (s390_addr_bits_remove, s390_address_class_type_flags)
8946 (s390_address_class_type_flags_to_name)
8947 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
8948 (s390_function_arg_float, s390_function_arg_vector)
8949 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
8950 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
8951 (s390_frame_align, s390_register_return_value, s390_return_value)
8952 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
8953 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
8954 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
8955 (s390_trad_frame_prev_register, s390_unwind_cache)
8956 (s390_prologue_frame_unwind_cache)
8957 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
8958 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
8959 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
8960 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
8961 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
8962 (s390_frame_base_address, s390_local_base_address)
8963 (s390_frame_base, s390_gcc_target_options)
8964 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
8965 (s390_validate_reg_range, s390_tdesc_valid)
8966 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
8967 * s390-tdep.c: ...this. New file.
8968
9c0b896e
PR
89692018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8970
8971 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
8972 (s390_process_record, s390_gdbarch_tdep_alloc)
8973 (s390_linux_init_abi_any): Use/set new hook.
8974
7042632b
PR
89752018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8976
8977 * s390-linux-tdep.c (osabi.h): New include.
8978 (s390_linux_init_abi_31, s390_linux_init_abi_64)
8979 (s390_linux_init_abi_any): New functions.
8980 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
8981
650f5e13
PR
89822018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8983
8984 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
8985 tdesc_has_registers check
8986
47c9317e
PR
89872018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8988
8989 * s390-linux-tdep.c (s390_tdesc_valid): New function.
8990 (s390_validate_reg_range): New macro.
8991 (s390_gdbarch_init): Adjust.
8992
095085d8
PR
89932018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8994
8995 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
8996 (s390_gdbarch_tdep_alloc): Adjust.
8997 (s390_gdbarch_init): Adjust.
8998
ab9bcc67
PR
89992018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9000
9001 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
9002 <have_tdb>: Change type to bool.
9003 (s390_gdbarch_tdep_alloc): Adjust.
9004 (s390_gdbarch_init): Adjust.
9005
21f6f5ff
PR
90062018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9007
9008 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
9009 (gdbarch_tdep) <have_upper, have_vx>: New fields.
9010 (s390_gdbarch_tdep_alloc): New function.
9011 (s390_gdbarch_init): Allocate tdep at start and use its fields
9012 instead of separate variables.
9013
0eb97953
PR
90142018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9015
9016 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
9017 when looking for cached gdbarch and add comment for remaining.
9018
5c319bb2
PA
90192018-01-22 Pedro Alves <palves@redhat.com>
9020 Sergio Durigan Junior <sergiodj@redhat.com>
9021
9022 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
9023 case.
9024
d65ce302
MR
90252018-01-22 Maciej W. Rozycki <macro@mips.com>
9026
9027 * MAINTAINERS: Update my company e-mail address.
9028
ec7a5fcb
YQ
90292018-01-22 Yao Qi <yao.qi@linaro.org>
9030
9031 * regcache.c (cooked_write_test): New function.
9032 (_initialize_regcache): Register the test.
9033
11f57cb6
YQ
90342018-01-22 Yao Qi <yao.qi@linaro.org>
9035
9036 * ia64-tdep.c (ia64_pseudo_register_read): Call
9037 regcache->cooked_read instead of regcache_cooked_read_unsigned.
9038 * m32c-tdep.c (m32c_cat_read): Likewise.
9039 (m32c_r3r2r1r0_read): Likewise.
9040 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
9041 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
9042
03f50fc8
YQ
90432018-01-22 Yao Qi <yao.qi@linaro.org>
9044
9045 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
9046 method raw_read instead of regcache_raw_read.
9047 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
9048 * arm-tdep.c (arm_neon_quad_read): Likewise.
9049 * avr-tdep.c (avr_pseudo_register_read): Likewise.
9050 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
9051 * frv-tdep.c (frv_pseudo_register_read): Likewise.
9052 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
9053 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
9054 (i386_pseudo_register_read_into_value): Likewise.
9055 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
9056 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
9057 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
9058 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
9059 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
9060 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
9061 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
9062 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
9063 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
9064
dc711524
YQ
90652018-01-22 Yao Qi <yao.qi@linaro.org>
9066
9067 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
9068 * configure.tgt: Remove target mt.
9069 * mt-tdep.c: Remove.
9070 * regcache.c (cooked_read_test): Remove the check for mt.
9071
3f5a868b
YQ
90722018-01-22 Yao Qi <yao.qi@linaro.org>
9073
9074 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
9075 instead of gdbarch_pseudo_register_read_value.
9076
de4cb04a
JB
90772018-01-22 Joel Brobecker <brobecker@adacore.com>
9078
9079 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
9080 language is Ada.
9081
a9e40818
JB
90822018-01-22 Joel Brobecker <brobecker@adacore.com>
9083
9084 * linespec.c (create_sals_line_offset): Remove code that preserved
9085 the symtab_and_line's line number.
9086
e707fc44
AB
90872018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9088
9089 * varobj.c (varobj_create): Don't set valid_block when creating a
9090 floating varobj.
9091
03d0bf7b
AB
90922018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9093
9094 * varobj.c (varobj_create): Remove out of date comment.
9095
ae451627
AB
90962018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9097
9098 PR mi/20395
9099 * ada-exp.y (write_var_from_sym): Pass extra parameter when
9100 updating innermost block.
9101 * parse.c (innermost_block_tracker::update): Take extra type
9102 parameter, and check types match before updating innermost block.
9103 (write_dollar_variable): Update innermost block for registers.
9104 * parser-defs.h (enum innermost_block_tracker_type): New enum.
9105 (innermost_block_tracker::innermost_block_tracker): Initialise
9106 m_types member.
9107 (innermost_block_tracker::reset): Take type parameter.
9108 (innermost_block_tracker::update): Take type parameter, and pass
9109 type through as needed.
9110 (innermost_block_tracker::m_types): New member.
9111 * varobj.c (varobj_create): Pass type when reseting innermost
9112 block.
9113
aee1fcdf
AB
91142018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9115
9116 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
9117 * ada-lang.c (resolve_subexp): Likewise.
9118 * breakpoint.c (set_breakpoint_condition) Likewise.
9119 (watch_command_1) Likewise.
9120 * c-exp.y (variable): Likewise.
9121 * d-exp.y (PrimaryExpression): Likewise.
9122 * f-exp.y (variable): Likewise.
9123 * go-exp.y (variable): Likewise.
9124 * m2-exp.y (variable): Likewise.
9125 * objfiles.c (objfile::~objfile): Likewise.
9126 * p-exp.y (variable): Likewise.
9127 * parse.c (innermost_block): Change type.
9128 * parser-defs.h (class innermost_block_tracker): New.
9129 (innermost_block): Change to innermost_block_tracker.
9130 * printcmd.c (display_command): Switch to innermost_block API.
9131 (do_one_display): Likewise.
9132 * rust-exp.y (do_one_display): Likewise.
9133 * symfile.c (clear_symtab_users): Likewise.
9134 * varobj.c (varobj_create): Switch to innermost_block API, replace
9135 use of innermost_block with block stored on varobj object.
9136
396af9a1
AB
91372018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9138
9139 * expression.h (innermost_block): Remove declaration.
9140 * varobj.c: Add 'parser-defs.h' include.
9141
fcfcc376
TT
91422018-01-19 Tom Tromey <tom@tromey.com>
9143
9144 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
9145 symbols in the static and global blocks.
9146
5a6c3296
JC
91472018-01-19 James Clarke <jrtc27@jrtc27.com>
9148
9149 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
9150 gdb_ptrace.h, and move including gdb_wait.h ...
9151 * nat/linux-ptrace.h: ... to here.
9152
bc09b0c1
SM
91532018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9154
9155 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
9156 inf_ptrace_detach_success.
9157 (inf_ptrace_detach_success): Add inferior parameter, use it
9158 instead of inferior_ptid, pass it to detach_inferior.
9159 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
9160 parameter.
9161 * inferior.c (detach_inferior): Add overload that takes an
9162 inferior object.
9163 * inferior.h (detach_inferior): Likewise.
9164 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
9165 use inferior_ptid, adjust call to inf_ptrace_detach_success.
9166 * linux-thread-db.c (thread_db_detach): Use inf parameter.
9167
6e1e1966
SM
91682018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9169
9170 * target.h (struct target_ops) <to_detach>: Add inferior
9171 parameter.
9172 (target_detach): Likewise.
9173 * target.c (dispose_inferior): Pass inferior down.
9174 (target_detach): Pass inferior down. Assert that it is equal to
9175 the current inferior.
9176 * aix-thread.c (aix_thread_detach): Pass inferior down.
9177 * corefile.c (core_file_command): Pass current_inferior() down.
9178 * corelow.c (core_detach): Add inferior parameter.
9179 * darwin-nat.c (darwin_detach): Likewise.
9180 * gnu-nat.c (gnu_detach): Likewise.
9181 * inf-ptrace.c (inf_ptrace_detach): Likewise.
9182 * infcmd.c (detach_command): Pass current_inferior() down to
9183 target_detach.
9184 * infrun.c (follow_fork_inferior): Pass parent_inf to
9185 target_detach.
9186 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
9187 target_detach.
9188 * linux-nat.c (linux_nat_detach): Add inferior parameter.
9189 * linux-thread-db.c (thread_db_detach): Likewise.
9190 * nto-procfs.c (procfs_detach): Likewise.
9191 * procfs.c (procfs_detach): Likewise.
9192 * record.c (record_detach): Likewise.
9193 * record.h (struct inferior): Forward-declare.
9194 (record_detach): Add inferior parameter.
9195 * remote-sim.c (gdbsim_detach): Likewise.
9196 * remote.c (remote_detach_1): Likewise.
9197 (remote_detach): Likewise.
9198 (extended_remote_detach): Likewise.
9199 * sol-thread.c (sol_thread_detach): Likewise.
9200 * target-debug.h (target_debug_print_inferior_p): New macro.
9201 * target-delegates.c: Re-generate.
9202 * top.c (kill_or_detach): Pass inferior down to target_detach.
9203 * windows-nat.c (windows_detach): Add inferior parameter.
9204
6bd6f3b6
SM
92052018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9206
9207 * target.h (struct target_ops) <to_detach>: Remove args
9208 parameter.
9209 (target_detach): Likewise.
9210 * target.c (dispose_inferior): Adjust.
9211 (target_detach): Remove args parameter, adjust.
9212 * aix-thread.c (aix_thread_detach): Adjust.
9213 * corefile.c (core_file_command): Adjust.
9214 * corelow.c (core_detach): Adjust.
9215 * darwin-nat.c (darwin_detach): Adjust.
9216 * gnu-nat.c (gnu_detach): Adjust.
9217 * inf-ptrace.c (inf_ptrace_detach): Adjust.
9218 * infcmd.c (detach_command): Adjust
9219 * infrun.c (follow_fork_inferior): Adjust.
9220 (handle_vfork_child_exec_or_exit): Adjust.
9221 * linux-fork.c (linux_fork_detach): Remove args parameter.
9222 * linux-fork.h (linux_fork_detach): Likewise.
9223 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
9224 * linux-thread-db.c (thread_db_detach): Likewise.
9225 * nto-procfs.c (procfs_detach): Likewise.
9226 * procfs.c (procfs_detach): Likewise.
9227 (do_detach): Remove signo parameter.
9228 * record.c (record_detach): Remove args parameter.
9229 * record.h (record_detach): Likewise.
9230 * remote-sim.c (gdbsim_detach): Likewise.
9231 * remote.c (remote_detach_1): Likewise.
9232 (remote_detach): Likewise.
9233 (extended_remote_detach): Likewise.
9234 * sol-thread.c (sol_thread_detach): Likewise.
9235 * target-delegates.c: Re-generate.
9236 * top.c (struct qt_args) <args>: Remove field.
9237 (kill_or_detach): Don't pass args.
9238 (quit_force): Don't set args.
9239 * windows-nat.c (windows_detach): Remove args parameter.
9240
88af8ea8
YQ
92412018-01-19 Yao Qi <yao.qi@linaro.org>
9242
9243 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
9244 (arm_linux_init_abi): Install it.
9245
dea445b9
YQ
92462018-01-19 Yao Qi <yao.qi@linaro.org>
9247
9248 * osabi.c (gdb_osabi_names): Extend the regexp for
9249 arm-linux-gnueabihf.
9250
4a17f768
YQ
92512018-01-18 Yao Qi <yao.qi@linaro.org>
9252
9253 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
9254 m_abbrevs.
9255 (abbrev_table::add_abbrev): Update.
9256 (abbrev_table::lookup_abbrev): Update.
9257
d679c21a
YQ
92582018-01-18 Yao Qi <yao.qi@linaro.org>
9259
9260 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
9261
7d937cad
SDJ
92622018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
9263
9264 * compile/compile.c (compile_to_object): Convert "triplet_rx"
9265 to "std::string".
9266
9e14690d
TT
92672018-01-17 Tom Tromey <tom@tromey.com>
9268
9269 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
9270
50a82047
TT
92712018-01-17 Tom Tromey <tom@tromey.com>
9272
9273 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
9274 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
9275 (create_array_type_with_stride): Update.
9276 * dwarf2read.c (set_die_type): Update.
9277
c89b44cd
TT
92782018-01-17 Tom Tromey <tom@tromey.com>
9279
9280 * dwarf2read.c (delayed_method_info): Remove typedef.
9281 (dwarf2_cu::method_info): Now a std::vector.
9282 (add_to_method_list): Update.
9283 (free_delayed_list): Remove.
9284 (compute_delayed_physnames): Update.
9285 (process_full_comp_unit, process_full_type_unit): Clear the method
9286 list. Remove cleanups.
9287 (psymtab_include_file_name): Add name_holder parameter. Use
9288 unique_xmalloc_ptr.
9289 (dwarf_decode_lines): Update.
9290
fcd3b13d
SM
92912018-01-17 Tom Tromey <tom@tromey.com>
9292 Simon Marchi <simon.marchi@ericsson.com>
9293
9294 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
9295 (dwarf2_per_objfile::free_cached_comp_units)
9296 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
9297 (init_cutu_and_read_dies_no_follow): Update.
9298 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
9299 (dwarf2_cu::~dwarf2_cu): New.
9300 (free_heap_comp_unit, free_stack_comp_unit): Remove.
9301 (age_cached_comp_units, free_one_cached_comp_unit): Update.
9302
685af9cd
TT
93032018-01-17 Tom Tromey <tom@tromey.com>
9304 Simon Marchi <simon.marchi@ericsson.com>
9305
9306 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
9307 (struct die_reader_specs) <abbrev_table>: New member.
9308 (struct abbrev_table): Add constructor.
9309 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
9310 <abbrev_obstack>: Now an auto_obstack.
9311 (abbrev_table_up): New typedef.
9312 (init_cu_die_reader): Add abbrev_table parameter.
9313 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
9314 Add result_dwo_abbrev_table.
9315 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
9316 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
9317 Update.
9318 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
9319 parameter.
9320 (skip_children): Update.
9321 (abbrev_table::alloc_abbrev): Rename from
9322 abbrev_table_alloc_abbrev.
9323 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
9324 (abbrev_table::lookup_abbrev): Rename from
9325 abbrev_table_lookup_abbrev.
9326 (abbrev_table_read_table): Return abbrev_table_up.
9327 (abbrev_table_free, abbrev_table_free_cleanup)
9328 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
9329 (load_partial_dies): Update.
9330
5e2db402
TT
93312018-01-17 Tom Tromey <tom@tromey.com>
9332
9333 * dwarf2read.c (dwarf2_compute_name): Update comment.
9334 (read_func_scope, read_variable): Update.
9335 (new_symbol): Remove.
9336 (new_symbol_full): Rename to new_symbol.
9337
ee7f689e 93382018-01-17 Mike Gulick <mgulick@mathworks.com>
41667530
MG
9339
9340 PR gdb/16577
9341 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
9342 a warning instead of throwing an error, set section size to 0 and return
9343 NULL.
9344 * gdb_bfd.h (gdb_bfd_map_section): Update description.
9345
4d9b86e1
SM
93462018-01-17 Simon Marchi <simon.marchi@ericsson.com>
9347
9348 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
9349 std::string.
9350 (linux_ptrace_attach_fail_reason_string): Likewise.
9351 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
9352 Likewise.
9353 (linux_ptrace_attach_fail_reason_string): Likewise.
9354 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
9355
a7b2d0fb
SM
93562018-01-17 Simon Marchi <simon.marchi@ericsson.com>
9357
9358 * linux-nat.c (linux_nat_attach): Remove xstrdup.
9359
f517c180
EA
93602018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
9361
9362 PR gdb/21559
9363 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
9364 checking for fs_base/gs_base fields in struct user_regs_struct.
9365 * configure: Regenerate.
9366
7045b1ca
YQ
93672018-01-17 Yao Qi <yao.qi@linaro.org>
9368
9369 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
9370 function.
9371 (aarch64_linux_init_abi): Install it to gdbarch hook
9372 gcc_target_options.
9373
db422fb2
PA
93742018-01-15 Pedro Alves <palves@redhat.com>
9375
9376 * common/signals-state-save-restore.c
9377 (save_original_signals_state): Fix typos.
9378
ba643918
SDJ
93792017-01-12 Tom Tromey <tom@tromey.com>
9380 Sergio Durigan Junior <sergiodj@redhat.com>
9381
9382 * Makefile.in (install-only): Install gdb-add-index.
9383
906b4aac
JB
93842018-01-12 John Baldwin <jhb@FreeBSD.org>
9385
9386 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
9387
bdf2a94a
AA
93882018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9389
9390 * infrun.c (keep_going_pass_signal): Clear step-over info when
9391 insert_breakpoints fails.
9392
71d378ae
PA
93932018-01-11 Pedro Alves <palves@redhat.com>
9394
9395 PR gdb/22583
9396 * infrun.c (resume): Rename to ...
9397 (resume_1): ... this.
9398 (resume): Reimplement as wrapper around resume_1.
9399
3cada740
PA
94002018-01-11 Pedro Alves <palves@redhat.com>
9401
9402 PR remote/22597
9403 * remote.c (remote_parse_stop_reply): Default to the last-set
9404 general thread instead of to 'magic_null_ptid'.
9405
618daa93
PA
94062018-01-10 Pedro Alves <palves@redhat.com>
9407
9408 * language.h (language_get_symbol_name_matcher): Rename ...
9409 (get_symbol_name_matcher): ... this.
9410 * language.c (language_get_symbol_name_matcher): Ditto.
9411 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
9412 callers adjusted.
9413
c63d3e8d
PA
94142018-01-10 Pedro Alves <palves@redhat.com>
9415
9416 PR gdb/22670
9417 * dwarf2read.c
9418 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
9419 Adjust to use language_get_symbol_name_matcher instead of
9420 language_defn::la_get_symbol_name_matcher.
9421 * language.c (language_get_symbol_name_matcher): If in Ada mode
9422 and the lookup name is a verbatim match, return Ada's matcher.
9423 * language.h (language_get_symbol_name_matcher): Adjust comment.
9424 (ada_lookup_name_info::verbatim_p):: New method.
9425
d4c2a405
PA
94262018-01-10 Pedro Alves <palves@redhat.com>
9427
9428 PR gdb/22670
9429 * ada-lang.c (ada_collect_symbol_completion_matches): If the
9430 minsym's language is language_auto or language_cplus, pass down
9431 language_ada instead.
9432 * symtab.c (compare_symbol_name): Don't frob symbol language here.
9433
8825213e
PA
94342018-01-10 Pedro Alves <palves@redhat.com>
9435
9436 PR gdb/22670
9437 * minsyms.c (linkage_name_str): New function.
9438 (iterate_over_minimal_symbols): Use it.
9439
2d97a5d9
JB
94402018-01-09 John Baldwin <jhb@FreeBSD.org>
9441
9442 * NEWS: Document that 'info proc' now works on FreeBSD.
9443
92fce24d
JB
94442018-01-09 John Baldwin <jhb@FreeBSD.org>
9445
9446 * configure.ac: Check for kinfo_getfile in libutil.
9447 * configure: Regenerate.
9448 * config.in: Regenerate.
9449 * fbsd-nat.c: Include "fbsd-tdep.h".
9450 (fbsd_fetch_cmdline): New.
9451 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
9452 rather than calling error.
9453 (fbsd_info_proc): New.
9454 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
9455 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
9456 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
9457
262f62f5
JB
94582018-01-09 John Baldwin <jhb@FreeBSD.org>
9459
9460 * fbsd-nat.c (struct free_deleter): Remove.
9461 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
9462
b999e203
JB
94632018-01-09 John Baldwin <jhb@FreeBSD.org>
9464
9465 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
9466 NULL for an empty pathname.
9467
d2176225
JB
94682018-01-09 John Baldwin <jhb@FreeBSD.org>
9469
9470 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
9471 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
9472 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
9473 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
9474 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
9475 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
9476 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
9477 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
9478 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
9479 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
9480 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
9481 (fbsd_core_fetch_timeval, fbsd_print_sigset)
9482 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
9483 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
9484 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
9485
9c4ac400
ST
94862018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
9487
9488 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
9489 (gnu_xfer_auxv): New function.
9490 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
9491 TARGET_OBJECT_AUXV.
9492
1e5ded6c
YQ
94932018-01-08 Yao Qi <yao.qi@linaro.org>
9494 Simon Marchi <simon.marchi@ericsson.com>
9495
9496 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
9497 common/selftest.c.
9498 (COMMON_OBS): Remove selftest.o.
9499 * configure.ac: Append selftest-arch.c and common/selftest.c to
9500 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
9501 * configure: Re-generated.
9502 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
9503 GDB_SELF_TEST.
9504 (maintenance_info_selftests): Likewise.
9505
04bafb1e
XR
95062018-01-08 Xavier Roirand <roirand@adacore.com>
9507
9508 * ada-valprint.c (val_print_packed_array_elements): Use
9509 proper number of elements when printing an array indexed
9510 by an enumeration type.
9511
518817b3
SM
95122018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9513
9514 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
9515 (dw2_get_file_names_reader): Adjust.
9516 (lookup_dwo_signatured_type): Adjust.
9517 (lookup_dwp_signatured_type): Adjust.
9518 (lookup_signatured_type): Adjust.
9519 (create_type_unit_group): Adjust.
9520 (get_type_unit_group): Adjust.
9521 (process_psymtab_comp_unit_reader): Adjust.
9522 (build_type_psymtabs_reader): Adjust.
9523 (scan_partial_symbols): Adjust.
9524 (add_partial_symbol): Adjust.
9525 (add_partial_subprogram): Adjust.
9526 (peek_die_abbrev): Adjust.
9527 (fixup_go_packaging): Adjust.
9528 (process_imported_unit_die): Adjust.
9529 (dwarf2_compute_name): Adjust.
9530 (dwarf2_physname): Adjust.
9531 (read_import_statement): Adjust.
9532 (handle_DW_AT_stmt_list): Adjust.
9533 (read_file_scope): Adjust.
9534 (read_func_scope): Adjust.
9535 (read_lexical_block_scope): Adjust.
9536 (read_call_site_scope): Adjust.
9537 (read_variable): Adjust.
9538 (dwarf2_rnglists_process): Adjust.
9539 (dwarf2_ranges_process): Adjust.
9540 (dwarf2_ranges_read): Adjust.
9541 (dwarf2_get_pc_bounds): Adjust.
9542 (dwarf2_record_block_ranges): Adjust.
9543 (dwarf2_add_field): Adjust.
9544 (dwarf2_add_member_fn): Adjust.
9545 (read_structure_type): Adjust.
9546 (process_structure_scope): Adjust.
9547 (read_enumeration_type): Adjust.
9548 (read_array_type): Adjust.
9549 (mark_common_block_symbol_computed): Adjust.
9550 (read_common_block): Adjust.
9551 (read_namespace_type): Adjust.
9552 (read_namespace): Adjust.
9553 (read_module_type): Adjust.
9554 (read_tag_pointer_type): Adjust.
9555 (read_tag_ptr_to_member_type): Adjust.
9556 (read_tag_string_type): Adjust.
9557 (read_subroutine_type): Adjust.
9558 (read_typedef): Adjust.
9559 (read_base_type): Adjust.
9560 (attr_to_dynamic_prop): Adjust.
9561 (read_subrange_type): Adjust.
9562 (read_unspecified_type): Adjust.
9563 (dwarf2_read_abbrevs): Adjust.
9564 (load_partial_dies): Adjust.
9565 (read_partial_die): Adjust.
9566 (find_partial_die): Adjust.
9567 (guess_partial_die_structure_name): Adjust.
9568 (fixup_partial_die): Adjust.
9569 (read_attribute_value): Adjust.
9570 (read_addr_index): Adjust.
9571 (read_addr_index_from_leb128): Adjust.
9572 (read_str_index): Adjust.
9573 (dwarf2_string_attr): Adjust.
9574 (get_debug_line_section): Adjust.
9575 (dwarf_decode_line_header): Adjust.
9576 (lnp_state_machine::check_line_address): Adjust.
9577 (dwarf_decode_lines_1): Adjust.
9578 (dwarf_decode_lines): Adjust.
9579 (dwarf2_start_symtab): Adjust.
9580 (var_decode_location): Adjust.
9581 (new_symbol_full): Adjust.
9582 (dwarf2_const_value_data): Adjust.
9583 (dwarf2_const_value_attr): Adjust.
9584 (dwarf2_const_value): Adjust.
9585 (die_type): Adjust.
9586 (die_containing_type): Adjust.
9587 (build_error_marker_type): Adjust.
9588 (lookup_die_type): Adjust.
9589 (guess_full_die_structure_name): Adjust.
9590 (anonymous_struct_prefix): Adjust.
9591 (determine_prefix): Adjust.
9592 (dwarf2_name): Adjust.
9593 (follow_die_ref_or_sig): Adjust.
9594 (follow_die_offset): Adjust.
9595 (follow_die_ref): Adjust.
9596 (follow_die_sig_1): Adjust.
9597 (follow_die_sig): Adjust.
9598 (get_signatured_type): Adjust.
9599 (get_DW_AT_signature_type): Adjust.
9600 (decode_locdesc): Adjust.
9601 (dwarf_decode_macros): Adjust.
9602 (cu_debug_loc_section): Adjust.
9603 (fill_in_loclist_baton): Adjust.
9604 (dwarf2_symbol_mark_computed): Adjust.
9605 (init_one_comp_unit): Don't assign
9606 dwarf2_cu::dwarf2_per_objfile.
9607 (set_die_type): Adjust.
9608
ed2dc618
SM
96092018-01-07 Simon Marchi <simon.marchi@ericsson.com>
9610
9611 * dwarf2read.c (struct mapped_debug_names): Add constructor.
9612 <dwarf2_per_objfile>: New field.
9613 (dwarf2_per_objfile): Remove global.
9614 (get_dwarf2_per_objfile): New function.
9615 (set_dwarf2_per_objfile): New function.
9616 (dwarf2_build_psymtabs_hard): Change objfile parameter to
9617 dwarf2_per_objfile.
9618 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
9619 (read_abbrev_offset): Likewise.
9620 (read_indirect_string): Likewise.
9621 (read_indirect_line_string): Likewise.
9622 (read_indirect_string_at_offset): Likewise.
9623 (read_indirect_string_from_dwz): Likewise.
9624 (dwarf2_find_containing_comp_unit): Change objfile parameter to
9625 dwarf2_per_objfile.
9626 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
9627 (create_all_comp_units): Change objfile parameter to
9628 dwarf2_per_objfile.
9629 (create_all_type_units): Likewise.
9630 (process_queue): Add dwarf2_per_objfile parameter.
9631 (read_and_check_comp_unit_head): Likewise.
9632 (lookup_dwo_unit_in_dwp): Likewise.
9633 (get_dwp_file): Likewise.
9634 (process_cu_includes): Likewise.
9635 (struct free_dwo_file_cleanup_data): New struct.
9636 (dwarf2_has_info): Use get_dwarf2_per_objfile and
9637 set_dwarf2_per_objfile.
9638 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
9639 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
9640 context, adjust calls.
9641 (dw2_instantiate_symtab): Likewise.
9642 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
9643 (dw2_get_cu): Likewise.
9644 (create_cu_from_index_list): Change objfile parameter to
9645 dwarf2_per_objfile.
9646 (create_cus_from_index_list): Get dwarf2_per_objfile from
9647 context, adjust calls.
9648 (create_cus_from_index): Likewise.
9649 (create_signatured_type_table_from_index): Change objfile
9650 parameter to dwarf2_per_objfile.
9651 (create_signatured_type_table_from_debug_names): Change objfile
9652 parameter to dwarf2_per_objfile.
9653 (create_addrmap_from_index): Likewise.
9654 (create_addrmap_from_aranges): Likewise.
9655 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
9656 (dw2_setup): Remove.
9657 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
9658 context.
9659 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
9660 get_dwarf2_per_objfile.
9661 (dw2_forget_cached_source_info): Likewise.
9662 (dw2_map_symtabs_matching_filename): Likewise.
9663 (struct dw2_symtab_iterator) <index>: Remove.
9664 <dwarf2_per_objfile>: New field.
9665 (dw2_symtab_iter_init): Replace index parameter with
9666 dwarf2_per_objfile.
9667 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
9668 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
9669 (dw2_print_stats): Likewise.
9670 (dw2_dump): Likewise.
9671 (dw2_expand_symtabs_for_function): Likewise.
9672 (dw2_expand_all_symtabs): Likewise.
9673 (dw2_expand_symtabs_with_fullname): Likewise.
9674 (dw2_expand_marked_cus): Replace index and objfile parameters
9675 with dwarf2_per_objfile.
9676 (dw_expand_symtabs_matching_file_matcher): Add
9677 dwarf2_per_objfile parameter and adjust calls.
9678 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
9679 adjust calls.
9680 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
9681 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
9682 adjust calls.
9683 (create_cus_from_debug_names_list): Replace objfile parameter
9684 with dwarf2_per_objfile and adjust calls.
9685 (create_cus_from_debug_names): Likewise.
9686 (dwarf2_read_debug_names): Likewise.
9687 (mapped_debug_names::namei_to_name): Adjust call.
9688 (dw2_debug_names_iterator::next): Likewise.
9689 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
9690 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
9691 (dw2_debug_names_dump): Likewise.
9692 (dw2_debug_names_expand_symtabs_for_function): Likewise.
9693 (dw2_debug_names_expand_symtabs_matching): Likewise.
9694 (dwarf2_initialize_objfile): Likewise.
9695 (dwarf2_build_psymtabs): Likewise.
9696 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
9697 this_cu.
9698 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
9699 (read_and_check_comp_unit_head): Likewise.
9700 (read_abbrev_offset): Likewise.
9701 (create_debug_type_hash_table): Likewise.
9702 (create_debug_types_hash_table): Likewise.
9703 (create_all_type_units): Replace objfile parameter with
9704 dwarf2_per_objfile.
9705 (add_type_unit): Add dwarf2_per_objfile parameter.
9706 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
9707 with dwarf2_per_objfile.
9708 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
9709 (lookup_dwp_signatured_type): Likewise.
9710 (lookup_signatured_type): Likewise.
9711 (read_cutu_die_from_dwo): Likewise.
9712 (init_tu_and_read_dwo_dies): Likewise.
9713 (init_cutu_and_read_dies): Likewise.
9714 (init_cutu_and_read_dies_no_follow): Likewise.
9715 (allocate_type_unit_groups_table): Add objfile parameter.
9716 (create_type_unit_group): Use dwarf2_per_objfile from cu.
9717 (get_type_unit_group): Likewise.
9718 (process_psymtab_comp_unit): Update call.
9719 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
9720 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
9721 (print_tu_stats): Likewise.
9722 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
9723 in void* parameter.
9724 (build_type_psymtabs): Change objfile parameter to
9725 dwarf2_per_objfile.
9726 (process_skeletonless_type_unit): Use dwarf2_per_objfile
9727 passed in void* parameter.
9728 (process_skeletonless_type_units): Change objfile parameter to
9729 dwarf2_per_objfile.
9730 (set_partial_user): Likewise.
9731 (dwarf2_build_psymtabs_hard): Likewise.
9732 (read_comp_units_from_section): Likewise.
9733 (create_all_comp_units): Likewise.
9734 (scan_partial_symbols): Update calls.
9735 (add_partial_symbol): Likewise.
9736 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
9737 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
9738 (process_queue): Add dwarf2_per_objfile parameter.
9739 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
9740 (compute_compunit_symtab_includes): Likewise.
9741 (process_cu_includes): Add dwarf2_per_objfile parameter.
9742 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
9743 (process_full_type_unit): Likewise.
9744 (process_imported_unit_die): Update call.
9745 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
9746 (read_file_scope): Likewise.
9747 (allocate_dwo_file_hash_table): Add objfile parameter.
9748 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
9749 (create_cus_hash_table): Likewise.
9750 (create_dwp_hash_table): Likewise.
9751 (create_dwo_unit_in_dwp_v1): Likewise.
9752 (create_dwp_v2_section): Likewise.
9753 (create_dwo_unit_in_dwp_v2): Likewise.
9754 (lookup_dwo_unit_in_dwp): Likewise.
9755 (try_open_dwop_file): Likewise.
9756 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
9757 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
9758 cleanup to include a reference to dwarf2_per_objfile.
9759 (open_dwp_file): Add dwarf2_per_objfile parameter.
9760 (open_and_init_dwp_file): Likewise.
9761 (get_dwp_file): Likewise.
9762 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
9763 (queue_and_load_all_dwo_tus): Update call.
9764 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
9765 data.
9766 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
9767 (dwarf2_ranges_process): Likewise.
9768 (dwarf2_get_pc_bounds): Likewise.
9769 (mark_common_block_symbol_computed): Likewise.
9770 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
9771 (dwarf2_read_abbrevs): Update call.
9772 (read_partial_die): Use dwarf2_per_objfile from cu.
9773 (find_partial_die): Likewise.
9774 (fixup_partial_die): Likewise.
9775 (read_attribute_value): Likewise.
9776 (read_indirect_string_at_offset_from): Add objfile parameter.
9777 (read_indirect_string_at_offset): Add dwarf2_per_objfile
9778 parameter.
9779 (read_indirect_string_from_dwz): Add objfile parameter.
9780 (read_indirect_string): Add objfile parameter.
9781 (read_addr_index_1): Add dwarf2_per_objfile parameter.
9782 (read_addr_index): Use dwarf2_per_objfile from cu.
9783 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
9784 call dw2_setup.
9785 (read_str_index): Use dwarf2_per_objfile from cu.
9786 (get_debug_line_section): Likewise.
9787 (read_formatted_entries): Add dwarf2_per_objfile parameter.
9788 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
9789 (new_symbol_full): Use dwarf2_per_objfile from cu.
9790 (build_error_marker_type): Likewise.
9791 (lookup_die_type): Likewise.
9792 (determine_prefix): Likewise.
9793 (follow_die_offset): Likewise.
9794 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
9795 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
9796 (dwarf2_fetch_die_type_sect_off): Likewise.
9797 (dwarf2_get_die_type): Likewise.
9798 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
9799 (get_signatured_type): Likewise.
9800 (get_DW_AT_signature_type): Likewise.
9801 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
9802 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
9803 (cu_debug_loc_section): Likewise.
9804 (fill_in_loclist_baton): Likewise.
9805 (dwarf2_symbol_mark_computed): Likewise.
9806 (dwarf2_find_containing_comp_unit): Change objfile parameter to
9807 dwarf2_per_objfile.
9808 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
9809 parameter.
9810 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
9811 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
9812 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
9813 (set_die_type): Use dwarf2_free_objfile from cu.
9814 (get_die_type_at_offset): Likewise.
9815 (dwarf2_per_objfile_free): Don't assign global variable.
9816 (debug_names) <constructor>: Add dwarf2_per_objfile
9817 parameter, update m_debugstrlookup construction.
9818 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
9819 parameter.
9820 <m_dwarf2_per_objfile>: New field.
9821 <lookup>: Use m_dwarf2_per_objfile.
9822 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
9823 (psyms_seen_size): Likewise.
9824 (write_gdbindex): Replace objfile parameter with
9825 dwarf2_per_objfile.
9826 (write_debug_names): Likewise.
9827 (write_psymtabs_to_index): Likewise.
9828 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
9829 calls.
9830
e3b94546
SM
98312018-01-07 Simon Marchi <simon.marchi@ericsson.com>
9832
9833 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
9834 <dwarf2_per_objfile>: New field.
9835 (struct dwarf2_per_cu_data) <objfile>: Remove.
9836 <dwarf2_per_objfile>: New field.
9837 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
9838 of objfile.
9839 (create_signatured_type_table_from_index): Likewise.
9840 (create_debug_type_hash_table): Likewise.
9841 (fill_in_sig_entry_from_dwo_entry): Likewise.
9842 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
9843 (create_type_unit_group): Assign dwarf2_per_objfile instead of
9844 objfile.
9845 (create_partial_symtab): Access objfile through
9846 dwarf2_per_objfile.
9847 (process_psymtab_comp_unit_reader): Likewise.
9848 (read_comp_units_from_section): Likewise.
9849 (scan_partial_symbols): Likewise.
9850 (add_partial_symbol): Likewise.
9851 (add_partial_subprogram): Likewise.
9852 (peek_die_abbrev): Likewise.
9853 (fixup_go_packaging): Likewise.
9854 (process_full_comp_unit): Likewise.
9855 (process_full_type_unit): Likewise.
9856 (process_imported_unit_die): Likewise.
9857 (dwarf2_compute_name): Likewise.
9858 (dwarf2_physname): Likewise.
9859 (read_import_statement): Likewise.
9860 (create_cus_hash_table): Assign dwarf2_physname instead of
9861 objfile.
9862 (read_func_scope): Access objfile through dwarf2_per_objfile.
9863 (read_lexical_block_scope): Likewise.
9864 (read_call_site_scope): Likewise.
9865 (read_variable): Likewise.
9866 (dwarf2_rnglists_process): Likewise.
9867 (dwarf2_ranges_process): Likewise.
9868 (dwarf2_ranges_read): Likewise.
9869 (dwarf2_record_block_ranges): Likewise.
9870 (dwarf2_add_field): Likewise.
9871 (dwarf2_add_member_fn): Likewise.
9872 (read_structure_type): Likewise.
9873 (process_structure_scope): Likewise.
9874 (read_enumeration_type): Likewise.
9875 (read_array_type): Likewise.
9876 (read_common_block): Likewise.
9877 (read_namespace_type): Likewise.
9878 (read_namespace): Likewise.
9879 (read_module_type): Likewise.
9880 (read_tag_pointer_type): Likewise.
9881 (read_tag_ptr_to_member_type): Likewise.
9882 (read_tag_string_type): Likewise.
9883 (read_subroutine_type): Likewise.
9884 (read_typedef): Likewise.
9885 (read_base_type): Likewise.
9886 (attr_to_dynamic_prop): Likewise.
9887 (read_subrange_type): Likewise.
9888 (read_unspecified_type): Likewise.
9889 (load_partial_dies): Likewise.
9890 (read_partial_die): Likewise.
9891 (find_partial_die): Likewise.
9892 (guess_partial_die_structure_name): Likewise.
9893 (fixup_partial_die): Likewise.
9894 (read_attribute_value): Likewise.
9895 (read_addr_index_from_leb128): Likewise.
9896 (dwarf2_read_addr_index): Likewise.
9897 (dwarf2_string_attr): Likewise.
9898 (lnp_state_machine::check_line_address): Likewise.
9899 (dwarf_decode_lines_1): Likewise.
9900 (dwarf_decode_lines): Likewise.
9901 (dwarf2_start_symtab): Likewise.
9902 (var_decode_location): Likewise.
9903 (new_symbol_full): Likewise.
9904 (dwarf2_const_value_data): Likewise.
9905 (dwarf2_const_value_attr): Likewise.
9906 (dwarf2_const_value): Likewise.
9907 (die_type): Likewise.
9908 (die_containing_type): Likewise.
9909 (lookup_die_type): Likewise.
9910 (guess_full_die_structure_name): Likewise.
9911 (anonymous_struct_prefix): Likewise.
9912 (dwarf2_name): Likewise.
9913 (follow_die_ref_or_sig): Likewise.
9914 (follow_die_offset): Likewise.
9915 (follow_die_ref): Likewise.
9916 (dwarf2_fetch_die_loc_sect_off): Likewise.
9917 (dwarf2_fetch_constant_bytes): Likewise.
9918 (dwarf2_fetch_die_type_sect_off): Likewise.
9919 (dwarf2_get_die_type): Likewise.
9920 (follow_die_sig): Likewise.
9921 (decode_locdesc): Likewise.
9922 (dwarf2_per_cu_objfile): Likewise.
9923 (dwarf2_per_cu_text_offset): Likewise.
9924 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
9925 objfile.
9926 (set_die_type): Access objfile through
9927 dwarf2_per_objfile.
9928
b01ba14d
SM
99292018-01-07 Simon Marchi <simon.marchi@ericsson.com>
9930
9931 * valprint.c (converted_character_d): Remove typedef.
9932 (DEF_VEC_O (converted_character_d)): Remove.
9933 (count_next_character): Use std::vector.
9934 (print_converted_chars_to_obstack): Likewise.
9935 (generic_printstr): Likewise.
9936
4d0fdd9b
SM
99372018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9938
9939 * xml-support.h (struct gdb_xml_value): Add constructor.
9940 <value>: Change type to unique_xmalloc_ptr.
9941 (gdb_xml_value_s): Remove typedef.
9942 (DEF_VEC_O (gdb_xml_value_s)): Remove.
9943 (gdb_xml_element_start_handler): Change parameter type to
9944 std::vector.
9945 (xml_find_attribute): Likewise.
9946 * xml-support.c (xml_find_attribute): Change parameter type to
9947 std::vector and adjust.
9948 (gdb_xml_values_cleanup): Remove.
9949 (gdb_xml_parser::start_element): Adjust to std::vector.
9950 (xinclude_start_include): Change paraeter type to std::vector
9951 and adjust.
9952 * btrace.c (check_xml_btrace_version): Likewise.
9953 (parse_xml_btrace_block): Likewise.
9954 (parse_xml_btrace_pt_config_cpu): Likewise.
9955 (parse_xml_btrace_pt): Likewise.
9956 (parse_xml_btrace_conf_bts): Likewise.
9957 (parse_xml_btrace_conf_pt): Likewise.
9958 * memory-map.c (memory_map_start_memory): Likewise.
9959 (memory_map_start_property): Likewise.
9960 * osdata.c (osdata_start_osdata): Likewise.
9961 (osdata_start_item): Likewise.
9962 (osdata_start_column): Likewise.
9963 * remote.c (start_thread): Likewise.
9964 * solib-aix.c (library_list_start_library): Likewise.
9965 (library_list_start_list): Likewise.
9966 * solib-svr4.c (library_list_start_library): Likewise.
9967 (svr4_library_list_start_list): Likewise.
9968 * solib-target.c (library_list_start_segment): Likewise.
9969 (library_list_start_section): Likewise.
9970 (library_list_start_library): Likewise.
9971 (library_list_start_list): Likewise.
9972 * tracepoint.c (traceframe_info_start_memory): Likewise.
9973 (traceframe_info_start_tvar): Likewise.
9974 * xml-syscall.c (syscall_start_syscall): Likewise.
9975 * xml-tdesc.c (tdesc_start_target): Likewise.
9976 (tdesc_start_feature): Likewise.
9977 (tdesc_start_reg): Likewise.
9978 (tdesc_start_union): Likewise.
9979 (tdesc_start_struct): Likewise.
9980 (tdesc_start_flags): Likewise.
9981 (tdesc_start_enum): Likewise.
9982 (tdesc_start_field): Likewise.
9983 (tdesc_start_enum_value): Likewise.
9984 (tdesc_start_vector): Likewise.
9985
f979c73f
SM
99862018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9987
9988 * extension.h (struct xmethod_worker) <clone>: Remove.
9989 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
9990 Remove.
9991 (python_xmethod_worker::clone): Remove.
9992 * valops.c (find_overload_match): Use std::move instead of
9993 clone.
9994
ba18742c
SM
99952018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9996
9997 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
9998 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
9999 <free_xmethod_worker_data>: Remove.
10000 <get_matching_xmethod_workers>: Chance VEC to std::vector.
10001 <get_xmethod_arg_types>: Remove.
10002 <get_xmethod_result_type>: Remove.
10003 <invoke_xmethod>: Remove.
10004 * extension.c (new_xmethod_worker): Remove.
10005 (clone_xmethod_worker): Remove.
10006 (get_matching_xmethod_workers): Return void, pass std::vector by
10007 pointer.
10008 (get_xmethod_arg_types): Rename to...
10009 (xmethod_worker::get_arg_types): ... this, and adjust.
10010 (get_xmethod_result_type): Rename to...
10011 (xmethod_worker::get_result_type): ... this, and adjust.
10012 (invoke_xmethod): Remove.
10013 (free_xmethod_worker): Remove.
10014 (free_xmethod_worker_vec): Remove.
10015 * extension.h (enum ext_lang_rc): Move here from
10016 extension-priv.h.
10017 (struct xmethod_worker): Add constructor and destructor.
10018 <data>: Remove.
10019 <value>: Remove.
10020 <invoke, clone, do_get_result_type, do_get_arg_types>: New
10021 virtual pure methods.
10022 <get_arg_types, get_result_type>: New methods.
10023 (xmethod_worker_ptr): Remove typedef.
10024 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
10025 (xmethod_worker_vec): Remove typedef.
10026 (xmethod_worker_up): New typedef.
10027 (invoke_xmethod): Remove.
10028 (clone_xmethod_worker): Remove.
10029 (free_xmethod_worker): Remove.
10030 (free_xmethod_worker_vec): Remove.
10031 (get_xmethod_arg_types): Remove.
10032 (get_xmethod_result_type): Remove.
10033 * valops.c (find_method_list): Use std::vector, don't use
10034 intermediate vector.
10035 (value_find_oload_method_list): Use std::vector.
10036 (find_overload_match): Use std::vector.
10037 (find_oload_champ): Use std::vector.
10038 * value.c (value_free): Use operator delete.
10039 (value_of_xmethod): Rename to...
10040 (value_from_xmethod): ... this. Don't assign
10041 xmethod_worker::value, take rvalue-reference.
10042 (result_type_of_xmethod): Adjust.
10043 (call_xmethod): Adjust.
10044 * value.h: Include extension.h.
10045 (struct xmethod_worker): Don't forward-declare.
10046 (value_of_xmethod): Rename to...
10047 (value_from_xmethod): ... this, take rvalue-reference.
10048 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
10049 (struct python_xmethod_worker): ... this, add constructor and
10050 destructor.
10051 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
10052 (gdbpy_free_xmethod_worker_data): Rename to...
10053 (python_xmethod_worker::~python_xmethod_worker): ... this and
10054 adjust.
10055 (gdbpy_clone_xmethod_worker_data): Rename to...
10056 (python_xmethod_worker::clone): ... this and adjust.
10057 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
10058 temporary vector.
10059 (gdbpy_get_xmethod_arg_types): Rename to...
10060 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
10061 (gdbpy_get_xmethod_result_type): Rename to...
10062 (python_xmethod_worker::do_get_result_type): ... this and
10063 adjust.
10064 (gdbpy_invoke_xmethod): Rename to...
10065 (python_xmethod_worker::invoke): ... this and adjust.
10066 (new_python_xmethod_worker): Rename to...
10067 (python_xmethod_worker::python_xmethod_worker): ... this and
10068 adjust.
10069 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
10070 Remove.
10071 (gdbpy_free_xmethod_worker_data): Remove.
10072 (gdbpy_get_matching_xmethod_workers): Use std::vector.
10073 (gdbpy_get_xmethod_arg_types): Remove.
10074 (gdbpy_get_xmethod_result_type): Remove.
10075 (gdbpy_invoke_xmethod): Remove.
10076 * python/python.c (python_extension_ops): Remove obsolete
10077 callbacks.
10078
e379cee6
PA
100792018-01-05 Pedro Alves <palves@redhat.com>
10080
10081 PR gdb/18653
10082 * common/signals-state-save-restore.c
10083 (save_original_signals_state): New parameter 'quiet'. Warn if we
10084 find a custom handler preinstalled, instead of internal erroring.
10085 But only warn if !quiet.
10086 * common/signals-state-save-restore.h
10087 (save_original_signals_state): New parameter 'quiet'.
10088 * main.c (captured_main_1): Move save_original_signals_state call
10089 after option handling, and pass QUIET.
10090
a655456c
PA
100912018-01-05 Pedro Alves <palves@redhat.com>
10092
10093 * spu-tdep.c (spu_catch_start): Pass
10094 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
10095
de63c46b
PA
100962018-01-05 Pedro Alves <palves@redhat.com>
10097
10098 PR gdb/22670
10099 * ada-lang.c (literal_symbol_name_matcher): New function.
10100 (ada_get_symbol_name_matcher): Use it for
10101 symbol_name_match_type::SEARCH_NAME.
10102 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
10103 it down instead of assuming symbol_name_match_type::FULL.
10104 * block.h (block_lookup_symbol): New parameter 'match_type'.
10105 * c-valprint.c (print_unpacked_pointer): Use
10106 lookup_symbol_search_name instead of lookup_symbol.
10107 * compile/compile-object-load.c (get_out_value_type): Pass down
10108 symbol_name_match_type::SEARCH_NAME.
10109 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
10110 symbol_name_match_type::FULL.
10111 * cp-support.c (cp_get_symbol_name_matcher): Handle
10112 symbol_name_match_type::SEARCH_NAME.
10113 * infrun.c (insert_exception_resume_breakpoint): Use
10114 lookup_symbol_search_name.
10115 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
10116 * psymtab.c (maintenance_check_psymtabs): Use
10117 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
10118 * stack.c (print_frame_args): Use lookup_symbol_search_name and
10119 SYMBOL_SEARCH_NAME.
10120 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
10121 if symbol_name_match_type::SEARCH_NAME.
10122 (lookup_symbol_in_language): Pass down
10123 symbol_name_match_type::FULL.
10124 (lookup_symbol_search_name): New.
10125 (lookup_language_this): Pass down
10126 symbol_name_match_type::SEARCH_NAME.
10127 (lookup_symbol_aux, lookup_local_symbol): New parameter
10128 'match_type'. Pass it down.
10129 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
10130 (lookup_symbol_search_name): New declaration.
10131 (lookup_symbol_in_block): New 'match_type' parameter.
10132
f98fc17b
PA
101332018-01-05 Pedro Alves <palves@redhat.com>
10134
10135 PR gdb/22670
10136 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
10137 ada_lookup_symbol.
10138 (ada_lookup_symbol): Reimplement in terms of
10139 ada_lookup_symbol_list, bits factored out from
10140 ada_lookup_encoded_symbol.
10141
342f8240
JB
101422018-01-05 Joel Brobecker <brobecker@adacore.com>
10143
10144 * ada-exp.y (write_object_renaming): When subscripting an array
10145 using a symbol as the index, pass the block in call to
10146 ada_lookup_encoded_symbol when looking that symbol up.
10147
7150d33c
JG
101482018-01-05 Jerome Guitton <guitton@adacore.com>
10149
10150 * ada-lang.c (ada_array_length): Use ada_index_type instead of
10151 TYPE_INDEX_TYPE.
10152
cc0e770c
JB
101532018-01-05 Joel Brobecker <brobecker@adacore.com>
10154
10155 * ada-lang.c (ada_to_fixed_value_create): Add handling of
10156 the case where VALUE_LVAL (val0) is not lval_memory.
10157
f79da888 101582018-01-05 Xavier Roirand <roirand@adacore.com>
e3861a03
XR
10159
10160 * ada-valprint.c (print_optional_low_bound): Handle
10161 character-indexed array printing like boolean-indexed array
10162 printing.
10163
cd385f94
JB
101642018-01-05 Joel Brobecker <brobecker@adacore.com>
10165
10166 * NEWS: Create a new section for the next release branch.
10167 Rename the section of the current branch, now that it has
10168 been cut.
10169
09aca949
JB
101702018-01-05 Joel Brobecker <brobecker@adacore.com>
10171
10172 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
10173 * version.in: Bump version to 8.1.50.DATE-git.
10174
9f757bf7
XR
101752018-01-03 Xavier Roirand <roirand@adacore.com>
10176
10177 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
10178 Add field.
10179 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
10180 Add field.
10181 (default_exception_support_info) <catch_handlers_sym>: Add field.
10182 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
10183 (ada_exception_name_addr_1): Add "catch handlers" handling.
10184 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
10185 Update all callers.
10186 (create_excep_cond_exprs) <ex>: Add parameter.
10187 (re_set_exception): Update create_excep_cond_exprs call.
10188 (print_it_exception, print_one_exception, print_mention_exception)
10189 (print_recreate_exception): Add "catch handler" handling.
10190 (allocate_location_catch_handlers, re_set_catch_handlers)
10191 (check_status_catch_handlers, print_it_catch_handlers)
10192 (print_one_catch_handlers, print_mention_catch_handlers)
10193 (print_recreate_catch_handlers): New function.
10194 (catch_handlers_breakpoint_ops): New variable.
10195 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
10196 Add parameter. Add "catch handler" handling.
10197 (ada_exception_sym_name, ada_exception_breakpoint_ops):
10198 Add "catch handler" handling.
10199 (ada_exception_catchpoint_cond_string): Add "catch handler"
10200 handling.
10201 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
10202 call.
10203 (catch_ada_handlers_command): New function.
10204 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
10205 operations structure.
10206 (_initialize_ada_language): Add "catch handlers" command entry.
10207 * NEWS: Document "catch handlers" feature.
10208
9fe561ab
JB
102092018-01-02 Joel Brobecker <brobecker@adacore.com>
10210
10211 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
10212 account when creating the array type of the slice.
10213 (ada_value_slice): Likewise.
10214
a405673c
JB
102152018-01-02 Joel Brobecker <brobecker@adacore.com>
10216
10217 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
10218 New enum value.
10219 (create_array_type_with_stride): Add byte_stride_prop parameter.
10220 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
10221 New parameter. Update all callers in this file.
10222 (array_type_has_dynamic_stride): New function.
10223 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
10224 of arrays with dynamic byte strides.
10225 * dwarf2read.c (read_array_type): Add support for dynamic
10226 DW_AT_byte_stride attributes.
10227
74a2f8ff
JB
102282018-01-02 Joel Brobecker <brobecker@adacore.com>
10229
10230 * dwarf2read.c (read_unspecified_type): Treat
10231 DW_TAG_enumeration_type DIEs from Ada units as stubs.
10232
e2882c85
JB
102332018-01-01 Joel Brobecker <brobecker@adacore.com>
10234
10235 Update copyright year range in all GDB files.
10236
1690bb24
JB
102372018-01-01 Joel Brobecker <brobecker@adacore.com>
10238
10239 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
10240 and gdb/testsuite/gdb.base/step-line.c.
10241
0f0c98a8
JB
102422018-01-01 Joel Brobecker <brobecker@adacore.com>
10243
10244 * copyright.py (main): Dump the contents of
10245 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
10246 even if BY_HAND is empty.
10247
82e1e79a
JB
102482018-01-01 Joel Brobecker <brobecker@adacore.com>
10249
10250 * top.c (print_gdb_version): Update Copyright year in version
10251 message.
10252
053f54e5 102532018-01-01 Joel Brobecker <brobecker@adacore.com>
47fea877 10254
053f54e5 10255 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
47fea877 10256
053f54e5 10257For older changes see ChangeLog-2017.
c906108c
SS
10258\f
10259Local Variables:
10260mode: change-log
10261left-margin: 8
10262fill-column: 74
10263version-control: never
57da7796 10264coding: utf-8
c906108c 10265End:
This page took 2.733173 seconds and 4 git commands to generate.