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