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