695bc0573b16ce63900eafc6edfcb041581d3cfc
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2018-12-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2
3 * nat/linux-ptrace.c (kill_child): Fix ARI warning by removing
4 warning trailing new line.
5
6 2018-12-16 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7
8 * nat/linux-ptrace.c (kill_child): New function.
9 (linux_ptrace_test_ret_to_nx): Use kill_child instead of local code.
10 Add a call to kill_child in case of early return after fork.
11 (linux_check_ptrace_features): Use kill_child instead of local code.
12 (linux_test_for_tracefork): Likewise.
13
14 2018-12-14 Tom Tromey <tom@tromey.com>
15
16 * Makefile.in: Remove "alloca" comment.
17 (INFOFILES): Remove.
18 (local-maintainer-clean): Don't use INFOFILES.
19
20 2018-12-13 John Baldwin <jhb@FreeBSD.org>
21
22 * syscalls/update-freebsd.sh: New file.
23 * syscalls/freebsd.xml: Regenerate.
24
25 2018-12-13 John Baldwin <jhb@FreeBSD.org>
26
27 * NEWS: Add entry documenting system call aliases.
28 * break-catch-syscall.c (catch_syscall_split_args): Pass 'result'
29 to get_syscalls_by_name.
30 * gdbarch.sh (UNKNOWN_SYSCALL): Remove.
31 * gdbarch.h: Regenerate.
32 * syscalls/gdb-syscalls.dtd (syscall): Add alias attribute.
33 * xml-syscall.c [!HAVE_LIBEXPAT] (get_syscalls_by_name): Rename
34 from get_syscall_by_name. Now accepts a pointer to a vector of
35 integers and returns a bool.
36 [HAVE_LIBEXPAT] (struct syscall_desc): Add alias member.
37 (syscall_create_syscall_desc): Add alias parameter and pass it to
38 syscall_desc constructor.
39 (syscall_start_syscall): Handle alias attribute.
40 (syscall_attr): Add alias attribute.
41 (xml_get_syscalls_by_name): Rename from xml_get_syscall_number.
42 Now accepts a pointer to a vector of integers and returns a
43 bool. Add syscalls whose alias or name matches the requested
44 name.
45 (get_syscalls_by_name): Rename from get_syscall_by_name. Now
46 accepts a pointer to a vector of integers and returns a bool.
47 * xml-syscall.h (get_syscalls_by_name): Likewise.
48
49 2018-12-13 John Baldwin <jhb@FreeBSD.org>
50
51 * break-catch-syscall.c (catch_syscall_split_args): Pass 'result'
52 to get_syscalls_by_group.
53 * xml-syscall.c [!HAVE_LIBEXPAT] (get_syscalls_by_group): Return
54 false.
55 [HAVE_LIBEXPAT] (xml_list_syscalls_by_group): Append syscall
56 numbers to an existing vector of integers and return a bool.
57 (get_syscalls_by_group): Accept pointer to vector of integers
58 and change return type to bool.
59 * xml-syscall.h (get_syscalls_by_group): Likewise.
60
61 2018-12-13 Jim Wilson <jimw@sifive.com>
62
63 * riscv-tdep.c (riscv_print_one_register_info): For MSTATUS, add
64 comment for SD field, and correct xlen calculation. For MISA, add
65 comment for MXL field, add call to register_size, and correct base
66 calculation.
67
68 2018-12-13 Stafford Horne <shorne@gmail.com>
69
70 * NEWS(New targets): Add or1k*-*-linux*.
71
72 2018-12-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
73
74 * nat/linux-osdata.c (linux_xfer_osdata_info_os_types): Forward
75 declare on one line to fix ARI warning.
76
77 2018-12-12 Andrew Burgess <andrew.burgess@embecosm.com>
78
79 * infrun.c (infcall_suspend_state::infcall_suspend_state): New.
80 (infcall_suspend_state::registers): New.
81 (infcall_suspend_state::restore): New.
82 (infcall_suspend_state::thread_suspend): Rename to...
83 (infcall_suspend_state::m_thread_suspend): ...this.
84 (infcall_suspend_state::registers): Rename to...
85 (infcall_suspend_state::m_registers): ...this.
86 (infcall_suspend_state::siginfo_gdbarch): Rename to...
87 (infcall_suspend_state::m_siginfo_gdbarch): ...this.
88 (infcall_suspend_state::siginfo_data): Rename to...
89 (infcall_suspend_state::m_siginfo_data): ...this.
90 (save_infcall_suspend_state): Rewrite to use infcall_suspend_state
91 constructor.
92 (restore_infcall_suspend_state): Rewrite to use
93 infcall_suspend_state::restore method.
94 (get_infcall_suspend_state_regcache): Use
95 infcall_suspend_state::registers method.
96
97 2018-12-12 Andrew Burgess <andrew.burgess@embecosm.com>
98
99 * riscv-tdep.c (riscv_call_arg_scalar_float): Unnamed (variadic)
100 arguments are passed in integer registers.
101 (riscv_call_arg_complex_float): Likewise.
102
103 2018-12-11 Philippe Waroquiers <philippe.waroquiers@skynet.be>
104
105 * nat/linux-osdata.c (common_getter): New function.
106 (struct osdata_type): Change getter to take_snapshot.
107 Add LONGEST len_avail and struct buffer buffer.
108 Change all elements in the initializer.
109 Add an element for the list of types.
110 (linux_xfer_osdata_info_os_types): New function.
111 (linux_common_xfer_osdata): Use common_getter for the list of types.
112 Replace getter call by common_getter.
113 (linux_xfer_osdata_cpus): Remove args READBUF, OFFSET, LEN.
114 Add arg BUFFER. Only keep the code that adds data in BUFFER.
115 (linux_xfer_osdata_fds): Likewise.
116 (linux_xfer_osdata_modules): Likewise.
117 (linux_xfer_osdata_msg): Likewise.
118 (linux_xfer_osdata_processes): Likewise.
119 (linux_xfer_osdata_processgroups): Likewise.
120 (linux_xfer_osdata_sem): Likewise.
121 (linux_xfer_osdata_shm): Likewise.
122 (linux_xfer_osdata_isockets): Likewise.
123 (linux_xfer_osdata_threads): Likewise.
124
125 2018-12-11 Philippe Waroquiers <philippe.waroquiers@skynet.be>
126
127 * nat/linux-osdata.c: Removed various trailing spaces.
128
129 2018-12-10 Andrew Burgess <andrew.burgess@embecosm.com>
130
131 * riscv-tdep.c (riscv_register_name): Fix ARI warning by removing
132 leading whitespace before #include line.
133
134 2018-12-08 Simon Marchi <simon.marchi@ericsson.com>
135 Дилян Палаузов <dilyan.palauzov@aegee.org>
136
137 PR gdb/23950
138 * configure.ac: Search for tgetent in libtinfow.
139 * configure: Re-generate.
140
141 2018-12-08 Philippe Waroquiers <philippe.waroquiers@skynet.be>
142
143 * linux-thread-db.c (struct thread_db_info): Add td_ta_delete_p.
144 (thread_db_err_str): Forward declare.
145 (delete_thread_db_info): Call td_ta_delete_p if available.
146 (try_thread_db_load_1): Acquire td_ta_delete address.
147 * nat/gdb_thread_db.h (td_ta_delete_ftype): Declare.
148
149 2018-12-08 Pedro Alves <palves@redhat.com>
150
151 * source.c (forward_search_command): Rename to ...
152 (search_command_helper): ... this. Add 'forward' parameter.
153 Tweak to use a gdb::def_vector<char> instead of a xrealloc'ed
154 buffer. Handle backward searches too.
155 (forward_search_command, reverse_search_command): Reimplement by
156 calling search_command_helper.
157
158 2018-12-07 Andrew Burgess <andrew.burgess@embecosm.com>
159
160 * .dir-locals.el: Copy most of the settings from c-mode over to
161 c++-mode.
162
163 2018-12-08 Stafford Horne <shorne@gmail.com>
164
165 * Makefile.in (ALL_TARGET_OBS): Add or1k-linux-tdep.o.
166 * configure.tgt: Add or1k*-*-linux*.
167 * or1k-linux-tdep.c: New file.
168 * or1k-tdep.c (or1k_gdbarch_init): Call gdbarch_init_osabi.
169
170 2018-12-07 Pedro Alves <palves@redhat.com>
171
172 * dwarf2read.c (get_gdb_index_contents_from_section): Use
173 gdb::make_array_view.
174
175 2018-12-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
176
177 * language.c (_initialize_language): Fix leak by assigning
178 a static string to language. Same for range and case_sensitive,
179 even if no leak is detected for these variables.
180
181 2018-12-05 John Baldwin <jhb@FreeBSD.org>
182
183 * configure: Re-generate.
184 * configure.ac: Use separate sed expressions to escape variables
185 in auto-load directories.
186
187 2018-12-05 Andrew Burgess <andrew.burgess@embecosm.com>
188
189 * riscv-tdep.c (riscv_features_from_gdbarch_info): New function.
190 (riscv_find_default_target_description): Use new function to
191 extract feature from gdbarch_info.
192 (riscv_gdbarch_init): Add error checks for xlen and flen between
193 target description and bfd headers. Be smarter about when we
194 think the hardware floating point abi should be used.
195
196 2018-12-05 Alan Hayward <alan.hayward@arm.com>
197
198 * nat/aarch64-linux-hw-point.c
199 (aarch64_linux_any_set_debug_regs_state): New function.
200 * nat/aarch64-linux-hw-point.h
201 (aarch64_linux_any_set_debug_regs_state): New declaration.
202 * nat/aarch64-linux.c (aarch64_linux_new_thread): Check if any
203 BPs or WPs are set.
204
205 2018-11-30 John Baldwin <jhb@FreeBSD.org>
206
207 * common/filestuff.c [HAVE_KINFO_GETFILE]: Include headers.
208 (fdwalk) [HAVE_KINFO_GETFILE]: Use kinfo_getfile.
209
210 2018-11-30 Philippe Waroquiers <philippe.waroquiers@skynet.be>
211 Simon Marchi <simon.marchi@ericsson.com>
212
213 * linespec.c (symtab_vector_up): Remove.
214 (symtabs_from_filename): Change return type to std::vector.
215 (collect_symtabs_from_filename): Likewise.
216 (create_sals_line_offset): Assign return value of
217 collect_symtabs_from_filename to *ls->file_symtabs.
218 (convert_explicit_location_to_linespec): Remove call to release.
219 (parse_linespec): Likewise.
220 (symtab_collector) <symtab_collector>: Remove initialization of
221 m_symtabs.
222 <release_symtabs>: Change return type to std::vector<symtab *>.
223 <operator ()>: Adjust.
224
225 2018-11-30 John Baldwin <jhb@FreeBSD.org>
226
227 * fbsd-nat.c [__FreeBSD_version >= 700009] (USE_SIGINFO): Macro
228 defined.
229 (union sigval32, struct siginfo32, fbsd_siginfo_size)
230 (fbsd_convert_siginfo): Make conditional on USE_SIGINFO instead
231 of KERN_PROC_AUXV and PT_LWPINFO.
232 (fbsd_nat_target::xfer_partial): Define method unconditionally.
233 Make TARGET_OBJECT_SIGNAL_INFO conditional on USE_SIGINFO.
234 Make TARGET_OBJECT_AUXV conditional on KERN_PROC_AUXV.
235 Make TARGET_OBJECT_FREEBSD_VMMAP and
236 TARGET_OBJECT_FREEBSD_PS_STRINGS conditional on KERN_PROC_VMMAP
237 and KERN_PROC_PS_STRINGS.
238 * fbsd-nat.h: Include <sys/proc.h>.
239 (fbsd_nat_target::xfer_partial): Declare method unconditionally.
240
241 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
242
243 * riscv-linux-nat.c: Add 'inferior.h' and 'target-descriptions.h'
244 header files.
245 (riscv_linux_nat_target::read_description): New method.
246
247 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
248
249 * arch/riscv.h (riscv_gdbarch_features::hash): New method.
250 * arch/riscv.c (struct riscv_gdbarch_features_hasher): New.
251 (riscv_tdesc_cache): New global.
252 (riscv_create_target_description): Look in the cache before
253 creating a new target description.
254
255 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
256
257 * arch/riscv.h (riscv_gdb_features::operator==): New.
258 (riscv_gdb_features::operator!=): New.
259 * riscv-tdep.c (riscv_gdbarch_init): Make use of the inequality
260 operator.
261
262 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
263
264 * arch/riscv.h (riscv_create_target_description): Make return type
265 const.
266 * arch/riscv.c (riscv_create_target_description): Likewise.
267 * riscv-tdep.c (riscv_find_default_target_description): Likewise.
268
269 2018-11-30 Jan Kratochvil <jan.kratochvil@redhat.com>
270 Keith Seitz <keiths@redhat.com>
271 Tom Tromey <tom@tromey.com>
272 Sergio Durigan Junior <sergiodj@redhat.com>
273
274 https://bugzilla.redhat.com/show_bug.cgi?id=1613614
275 * dwarf2read.c (dwarf2_find_containing_comp_unit): Add
276 'mid_cu->length' to '*cu_off' when checking if 'sect_off' is
277 inside the CU.
278
279 2018-11-30 Pedro Alves <palves@redhat.com>
280
281 * aix-thread.c (aix_thread_target) <aix_thread_target>: Delete.
282 <stratum>: New override.
283 * bfd-target.c (aix_thread_target) <aix_thread_target>: Delete.
284 <stratum>: New override.
285 * bsd-uthread.c (bsd_uthread_target) <bsd_uthread_target>: Delete.
286 <stratum>: New override.
287 * exec.c (exec_target) <exec_target>: Delete.
288 <stratum>: New override.
289 * gdbarch-selftests.c (register_to_value_test): Adjust to use the
290 stratum method instead of the to_stratum field.
291 * linux-thread-db.c (thread_db_target) <thread_db_target>: Delete.
292 <stratum>: New override.
293 (thread_db_target::thread_db_target): Delete.
294 * make-target-delegates (print_class): Don't print a ctor
295 declaration. Print a stratum method override declaration.
296 * process-stratum-target.h (process_stratum_target)
297 <process_stratum_target>: Delete.
298 <stratum>: New override.
299 * ravenscar-thread.c (ravenscar_thread_target)
300 <ravenscar_thread_target>: Delete.
301 <stratum>: New override.
302 * record-btrace.c (record_btrace_target)
303 <record_btrace_target>: Delete.
304 <stratum>: New override.
305 * record-full.c (record_full_base_target)
306 <record_full_base_target>: Delete.
307 <stratum>: New override.
308 * record.c (record_disconnect, record_detach)
309 (record_mourn_inferior, record_kill): Adjust to use the stratum
310 method instead of the to_stratum field.
311 * regcache.c (cooked_read_test, cooked_write_test): Likewise.
312 * sol-thread.c (sol_thread_target)
313 <sol_thread_target>: Delete.
314 <stratum>: New override.
315 * spu-multiarch.c (spu_multiarch_target)
316 <spu_multiarch_target>: Delete.
317 <stratum>: New override.
318 * target-delegates.c: Regenerate.
319 * target.c (target_stack::push, target_stack::unpush)
320 (pop_all_targets_above, pop_all_targets_at_and_above)
321 (info_target_command, target_require_runnable)
322 (target_stack::find_beneath): Adjust to use the stratum method
323 instead of the to_stratum field.
324 (dummy_target::dummy_target): Delete.
325 (dummy_target::stratum): New.
326 (debug_target::debug_target): Delete.
327 (debug_target::stratum): New.
328 (maintenance_print_target_stack): Adjust to use the stratum method
329 instead of the to_stratum field.
330 * target.h (struct target_ops) <stratum>: New method.
331 <to_stratum>: Delete.
332 <is_pushed>: Adjust to use the stratum method
333 instead of the to_stratum field.
334
335 2018-11-30 Pedro Alves <palves@redhat.com>
336
337 * corelow.c (core_target) <has_all_memory, has_execution>: New
338 overrides.
339 * inf-child.c (inf_child_target::has_all_memory)
340 (inf_child_target::has_memory, inf_child_target::has_stack)
341 (inf_child_target::has_registers)
342 (inf_child_target::has_execution): Delete.
343 * inf-child.h (inf_child_target) <has_all_memory, has_memory,
344 has_stack, has_registers, has_execution>: Delete.
345 * process-stratum-target.c
346 (process_stratum_target::has_all_memory)
347 (process_stratum_target::has_memory)
348 (process_stratum_target::has_stack)
349 (process_stratum_target::has_registers)
350 (process_stratum_target::has_execution): New.
351 * process-stratum-target.h (process_stratum_target)
352 <has_all_memory, has_memory, has_stack, has_registers,
353 has_execution>: New method overrides.
354 * ravenscar-thread.c (ravenscar_thread_target) <has_all_memory,
355 has_memory, has_stack, has_registers, has_execution>: Delete.
356 * remote-sim.c (gdbsim_target) <has_stack, has_registers,
357 has_execution>: Delete.
358 * remote.c (remote_target) <has_all_memory, has_memory, has_stack,
359 has_registers, has_execution>: Delete.
360 * target.c (default_child_has_all_memory)
361 (default_child_has_memory, default_child_has_stack)
362 (default_child_has_registers, default_child_has_execution):
363 Delete.
364 * target.h (default_child_has_all_memory)
365 (default_child_has_memory, default_child_has_stack)
366 (default_child_has_registers, default_child_has_execution):
367 Delete.
368 * tracefile.h (tracefile_target) <has_execution>: New override.
369
370 2018-11-30 Pedro Alves <palves@redhat.com>
371
372 * Makefile.in (COMMON_SFILES): Add process-stratum-target.c.
373 * bsd-kvm.c: Include "process-stratum-target.h".
374 (bsd_kvm_target): Now inherits from process_stratum_target.
375 (bsd_kvm_target::bsd_kvm_target): Default it.
376 * corelow.c: Include "process-stratum-target.h".
377 (core_target): Now inherits from process_stratum_target.
378 (core_target::core_target): Don't set to_stratum here.
379 * inf-child.c (inf_child_target::inf_child_target): Delete.
380 * inf-child.h: Include "process-stratum-target.h".
381 (inf_child_target): Inherit from process_stratum_target.
382 (inf_child_target) <inf_child_target>: Default it.
383 <can_async_p, supports_non_stop, supports_disable_randomization>:
384 Delete overrides.
385 * process-stratum-target.c: New file.
386 * process-stratum-target.h: New file.
387 * remote-sim.c: Include "process-stratum-target.h".
388 (gdbsim_target): Inherit from process_stratum_target.
389 <gdbsim_target>: Default it.
390 * remote.c: Include "process-stratum-target.h".
391 (remote_target): Inherit from process_stratum_target.
392 <remote_target>: Default it.
393 * target.c (default_thread_address_space)
394 (default_thread_architecture): Delete.
395 * target.h (target_ops) <thread_architecture>: Now returns NULL by
396 default.
397 <thread_address_space>: Ditto.
398 * test-target.h: Include "process-stratum-target.h" instead of
399 "target.h".
400 (test_target_ops): Inherit from process_stratum_target.
401 <test_target_ops>: Default it.
402 * tracefile.c (tracefile_target::tracefile_target): Delete.
403 * tracefile.h: Include "process-stratum-target.h".
404 (tracefile_target): Inherit from process_stratum_target.
405 <tracefile_target>: Default it.
406 * target-delegates.c: Regenerate.
407
408 2018-11-30 Pedro Alves <palves@redhat.com>
409
410 * Makefile.in (COMMON_SFILES): Add test-target.c.
411 * gdbarch-selftests.c: Include "test-target.h".
412 * regcache.c: Include "test-target.h".
413 * target.c (test_target_info, test_target_ops::info): Move to ...
414 * test-target.c: ... this new file.
415 * target.h (test_target_ops): Move to ...
416 * test-target.h: ... this new file.
417
418 2018-11-29 Philippe Waroquiers <philippe.waroquiers@skynet.be>
419
420 * source.c (forward_search_command): Fix leak by using
421 xrealloc even for the first allocation in the loop, as buf
422 is static.
423
424 2018-11-29 Rajendra SY <rajendra.sy@gmail.com>
425
426 PR gdb/23093
427 * gdb/fbsd-tdep.c (fbsd_gdb_signal_from_target)
428 (fbsd_gdb_signal_to_target): New.
429 (fbsd_init_abi): Install gdbarch "signal_from_target" and
430 "signal_to_target" methods.
431
432 2018-11-29 Tom Tromey <tom@tromey.com>
433
434 * valarith.c (value_x_unop): Don't set argvec[3].
435
436 2018-11-26 Simon Marchi <simon.marchi@ericsson.com>
437
438 PR gdb/23917
439 * sparc-linux-nat.c (sparc_linux_nat_target): Remove extraneous
440 semicolon.
441
442 2018-11-26 Pedro Alves <palves@redhat.com>
443
444 * procfs.c (procfs_notice_thread): Replace uses of
445 in_thread_list/is_exited with find_thread_ptid/THREAD_EXITED.
446 * sol-thread.c (sol_thread_target::wait)
447 (sol_update_thread_list_callback): Likewise.
448
449 2018-11-25 Tom Tromey <tom@tromey.com>
450
451 * ui-out.c (ui_out::field_fmt): Remove comment.
452 * tui/tui-out.c (tui_ui_out::do_field_fmt): Remove comment.
453 * mi/mi-out.c (mi_ui_out::do_field_fmt): Remove comment.
454
455 2018-11-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
456
457 * source.c (open_source_file): Leak fixed in '8e6a5953e1d Fix 4K
458 leak in open_source_file' has been partially undone by '2179fbc36d23
459 Return scoped_fd from open_source_file'. Re-add the transfer of
460 current s->fullname to the unique_xmalloc_ptr fullname given
461 to find_and_open_source.
462
463 2018-11-23 Pedro Alves <palves@redhat.com>
464
465 * gdbthread.h (enum thread_state): Move comments here.
466 (is_running, is_stopped, is_exited): Remove declarations.
467
468 2018-11-22 Pedro Alves <palves@redhat.com>
469
470 * Makefile.in (COMMON_SFILES): Add thread-iter.c.
471 * breakpoint.c (breakpoints_should_be_inserted_now): Replace
472 ALL_NON_EXITED_THREADS with all_non_exited_threads.
473 (print_one_breakpoint_location): Replace ALL_INFERIORS with
474 all_inferiors.
475 * bsd-kvm.c: Include inferior.h.
476 * btrace.c (btrace_free_objfile): Replace ALL_NON_EXITED_THREADS
477 with all_non_exited_threads.
478 * common/filtered-iterator.h: New.
479 * common/safe-iterator.h: New.
480 * corelow.c (core_target_open): Don't call init_thread_list here.
481 * darwin-nat.c (thread_info_from_private_thread_info): Replace
482 ALL_THREADS with all_threads.
483 * fbsd-nat.c (fbsd_nat_target::resume): Replace
484 ALL_NON_EXITED_THREADS with inf->non_exited_threads.
485 * fbsd-tdep.c (fbsd_make_corefile_notes): Replace
486 ALL_NON_EXITED_THREADS with inf->non_exited_threads.
487 * fork-child.c (postfork_hook): Don't call init_thread_list here.
488 * gdbarch-selftests.c (register_to_value_test): Adjust.
489 * gdbthread.h: Don't include "inferior.h" here.
490 (struct inferior): Forward declare.
491 (enum step_over_calls_kind): Moved here from inferior.h.
492 (thread_info::deletable): Definition moved to thread.c.
493 (find_thread_ptid (inferior *, ptid_t)): Declare.
494 (ALL_THREADS, ALL_THREADS_BY_INFERIOR, ALL_THREADS_SAFE): Delete.
495 Include "thread-iter.h".
496 (all_threads, all_non_exited_threads, all_threads_safe): New.
497 (any_thread_p): Declare.
498 (thread_list): Delete.
499 * infcmd.c (signal_command): Replace ALL_NON_EXITED_THREADS with
500 all_non_exited_threads.
501 (proceed_after_attach_callback): Delete.
502 (proceed_after_attach): Take an inferior pointer instead of an
503 integer PID. Adjust to use range-for.
504 (attach_post_wait): Pass down inferior pointer instead of pid.
505 Use range-for instead of ALL_NON_EXITED_THREADS.
506 (detach_command): Remove init_thread_list call.
507 * inferior-iter.h: New.
508 * inferior.c (struct delete_thread_of_inferior_arg): Delete.
509 (delete_thread_of_inferior): Delete.
510 (delete_inferior, exit_inferior_1): Use range-for with
511 inf->threads_safe() instead of iterate_over_threads.
512 (inferior_appeared): Call init_thread_list here.
513 (discard_all_inferiors): Use all_non_exited_inferiors.
514 (find_inferior_id, find_inferior_pid): Use all_inferiors.
515 (iterate_over_inferiors): Use all_inferiors_safe.
516 (have_inferiors, number_of_live_inferiors): Use
517 all_non_exited_inferiors.
518 (number_of_inferiors): Use all_inferiors and std::distance.
519 (print_inferior): Use all_inferiors.
520 * inferior.h: Include gdbthread.h.
521 (enum step_over_calls_kind): Moved to gdbthread.h.
522 (struct inferior) <thread_list>: New field.
523 <threads, non_exited_threads, threads_safe>: New methods.
524 (ALL_INFERIORS): Delete.
525 Include "inferior-iter.h".
526 (ALL_NON_EXITED_INFERIORS): Delete.
527 (all_inferiors_safe, all_inferiors, all_non_exited_inferiors): New
528 functions.
529 * inflow.c (child_interrupt, child_pass_ctrlc): Replace
530 ALL_NON_EXITED_THREADS with all_non_exited_threads.
531 * infrun.c (follow_exec): Use all_threads_safe.
532 (clear_proceed_status, proceed): Use all_non_exited_threads.
533 (init_wait_for_inferior): Don't clear inline frame state here.
534 (infrun_thread_stop_requested, for_each_just_stopped_thread): Use
535 all_threads instead of ALL_NON_EXITED_THREADS.
536 (random_pending_event_thread): Use all_non_exited_threads instead
537 of ALL_NON_EXITED_THREADS. Use a lambda for repeated code.
538 (clean_up_just_stopped_threads_fsms): Use all_non_exited_threads
539 instead of ALL_NON_EXITED_THREADS.
540 (handle_no_resumed): Use all_non_exited_threads instead of
541 ALL_NON_EXITED_THREADS. Use all_inferiors instead of
542 ALL_INFERIORS.
543 (restart_threads, switch_back_to_stepped_thread): Use
544 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
545 * linux-nat.c (check_zombie_leaders): Replace ALL_INFERIORS with
546 all_inferiors.
547 (kill_unfollowed_fork_children): Use inf->non_exited_threads
548 instead of ALL_NON_EXITED_THREADS.
549 * linux-tdep.c (linux_make_corefile_notes): Use
550 inf->non_exited_threads instead of ALL_NON_EXITED_THREADS.
551 * linux-thread-db.c (thread_db_target::update_thread_list):
552 Replace ALL_INFERIORS with all_inferiors.
553 (thread_db_target::thread_handle_to_thread_info): Use
554 inf->non_exited_threads instead of ALL_NON_EXITED_THREADS.
555 * mi/mi-interp.c (multiple_inferiors_p): New.
556 (mi_on_resume_1): Simplify using all_non_exited_threads and
557 multiple_inferiors_p.
558 * mi/mi-main.c (mi_cmd_thread_list_ids): Use all_non_exited_threads
559 instead of ALL_NON_EXITED_THREADS.
560 * nto-procfs.c (nto_procfs_target::open): Don't call
561 init_thread_list here.
562 * record-btrace.c (record_btrace_target_open)
563 (record_btrace_target::stop_recording)
564 (record_btrace_target::close)
565 (record_btrace_target::record_is_replaying)
566 (record_btrace_target::resume, record_btrace_target::wait)
567 (record_btrace_target::record_stop_replaying): Use
568 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
569 * record-full.c (record_full_wait_1): Use all_non_exited_threads
570 instead of ALL_NON_EXITED_THREADS.
571 * regcache.c (cooked_read_test): Remove reference to global
572 thread_list.
573 * remote-sim.c (gdbsim_target::create_inferior): Don't call
574 init_thread_list here.
575 * remote.c (remote_target::update_thread_list): Use
576 all_threads_safe instead of ALL_NON_EXITED_THREADS.
577 (remote_target::process_initial_stop_replies): Replace
578 ALL_INFERIORS with all_non_exited_inferiors and use
579 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
580 (remote_target::open_1): Don't call init_thread_list here.
581 (remote_target::append_pending_thread_resumptions)
582 (remote_target::remote_resume_with_hc): Use all_non_exited_threads
583 instead of ALL_NON_EXITED_THREADS.
584 (remote_target::commit_resume)
585 (remote_target::remove_new_fork_children): Replace ALL_INFERIORS
586 with all_non_exited_inferiors and use all_non_exited_threads
587 instead of ALL_NON_EXITED_THREADS.
588 (remote_target::kill_new_fork_children): Use
589 all_non_exited_threads instead of ALL_NON_EXITED_THREADS. Remove
590 init_thread_list and init_wait_for_inferior calls.
591 (remote_target::remote_btrace_maybe_reopen)
592 (remote_target::thread_handle_to_thread_info): Use
593 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
594 * target.c (target_terminal::restore_inferior)
595 (target_terminal_is_ours_kind): Replace ALL_INFERIORS with
596 all_non_exited_inferiors.
597 * thread-iter.c: New file.
598 * thread-iter.h: New file.
599 * thread.c: Include "inline-frame.h".
600 (thread_list): Delete.
601 (clear_thread_inferior_resources): Call clear_inline_frame_state.
602 (init_thread_list): Use all_threads_safe instead of
603 ALL_THREADS_SAFE. Adjust to per-inferior thread lists.
604 (new_thread): Adjust to per-inferior thread lists.
605 (add_thread_silent): Pass inferior to find_thread_ptid.
606 (thread_info::deletable): New, moved from the header.
607 (delete_thread_1): Adjust to per-inferior thread lists.
608 (find_thread_global_id): Use inf->threads().
609 (find_thread_ptid): Use find_inferior_ptid and pass inferior to
610 find_thread_ptid.
611 (find_thread_ptid(inferior*, ptid_t)): New overload.
612 (iterate_over_threads): Use all_threads_safe.
613 (any_thread_p): New.
614 (thread_count): Use all_threads and std::distance.
615 (live_threads_count): Use all_non_exited_threads and
616 std::distance.
617 (valid_global_thread_id): Use all_threads.
618 (in_thread_list): Use find_thread_ptid.
619 (first_thread_of_inferior): Adjust to per-inferior thread lists.
620 (any_thread_of_inferior, any_live_thread_of_inferior): Use
621 inf->non_exited_threads().
622 (prune_threads, delete_exited_threads): Use all_threads_safe.
623 (thread_change_ptid): Pass inferior pointer to find_thread_ptid.
624 (set_resumed, set_running): Use all_non_exited_threads.
625 (is_thread_state, is_stopped, is_exited, is_running)
626 (is_executing): Delete.
627 (set_executing, set_stop_requested, finish_thread_state): Use
628 all_non_exited_threads.
629 (print_thread_info_1): Use all_inferiors and all_threads.
630 (thread_apply_all_command): Use all_non_exited_threads.
631 (thread_find_command): Use all_threads.
632 (update_threads_executing): Use all_non_exited_threads.
633 * tid-parse.c (parse_thread_id): Use inf->threads.
634 * x86-bsd-nat.c (x86bsd_dr_set): Use inf->non_exited_threads ().
635
636 2018-11-22 Pedro Alves <palves@redhat.com>
637
638 * infrun.c (follow_exec) <set follow-exec new>: Add thread and
639 switch to it before calling into try_open_exec_file.
640
641 2018-11-22 Pedro Alves <palves@redhat.com>
642
643 * cli/cli-interp.c (cli_on_user_selected_context_changed): Use
644 inferior_thread instead of find_thread_ptid, and only when
645 inferior_ptid is not null_ptid.
646 * inferior.c (add_inferior): Don't include target_pid_to_str
647 output when the inferior is not started.
648 * python/py-inferior.c (python_on_normal_stop): Don't use
649 find_thread_ptid.
650 (tui_on_user_selected_context_changed): Use inferior_thread
651 instead of find_thread_ptid, and only when inferior_ptid is not
652 null_ptid.
653
654 2018-11-21 Benno Fünfstück <benno.fuenfstueck@gmail.com>
655
656 PR python/23714
657 * gdb/python/python.c (execute_gdb_command): Call
658 prevent_dont_repeat earlier to avoid affecting dont_repeat.
659
660 2018-11-21 Andrew Burgess <andrew.burgess@embecosm.com>
661
662 * Makefile.in (ALL_TARGET_OBS): Add arch/riscv.o.
663 (HFILES_NO_SRCDIR): Add arch/riscv.h.
664 * arch/riscv.c: New file.
665 * arch/riscv.h: New file.
666 * configure.tgt: Add cpu_obs list of riscv, move riscv-tdep.o into
667 this list, and add arch/riscv.o.
668 * features/Makefile: Add riscv features.
669 * features/riscv/32bit-cpu.c: New file.
670 * features/riscv/32bit-cpu.xml: New file.
671 * features/riscv/32bit-csr.c: New file.
672 * features/riscv/32bit-csr.xml: New file.
673 * features/riscv/32bit-fpu.c: New file.
674 * features/riscv/32bit-fpu.xml: New file.
675 * features/riscv/64bit-cpu.c: New file.
676 * features/riscv/64bit-cpu.xml: New file.
677 * features/riscv/64bit-csr.c: New file.
678 * features/riscv/64bit-csr.xml: New file.
679 * features/riscv/64bit-fpu.c: New file.
680 * features/riscv/64bit-fpu.xml: New file.
681 * features/riscv/rebuild-csr-xml.sh: New file.
682 * riscv-tdep.c: Add 'arch/riscv.h' include.
683 (riscv_gdb_reg_names): Delete.
684 (csr_reggroup): New global.
685 (struct riscv_register_alias): Delete.
686 (struct riscv_register_feature): New structure.
687 (riscv_register_aliases): Delete.
688 (riscv_xreg_feature): New global.
689 (riscv_freg_feature): New global.
690 (riscv_virtual_feature): New global.
691 (riscv_csr_feature): New global.
692 (riscv_create_csr_aliases): New function.
693 (riscv_read_misa_reg): Delete.
694 (riscv_has_feature): Delete.
695 (riscv_isa_xlen): Simplify, just return cached xlen.
696 (riscv_isa_flen): Simplify, just return cached flen.
697 (riscv_has_fp_abi): Update for changes in struct gdbarch_tdep.
698 (riscv_register_name): Update to make use of tdesc_register_name.
699 Look up xreg and freg names in the new globals riscv_xreg_feature
700 and riscv_freg_feature. Don't supply csr aliases here.
701 (riscv_fpreg_q_type): Delete.
702 (riscv_register_type): Use tdesc_register_type in almost all
703 cases, override the returned type in a few specific cases only.
704 (riscv_print_one_register_info): Handle errors reading registers.
705 (riscv_register_reggroup_p): Use tdesc_register_in_reggroup_p for
706 registers that are otherwise unknown to GDB. Also check the
707 csr_reggroup.
708 (riscv_print_registers_info): Remove assert about upper register
709 number, and use gdbarch_register_reggroup_p instead of
710 short-cutting.
711 (riscv_find_default_target_description): New function.
712 (riscv_check_tdesc_feature): New function.
713 (riscv_add_reggroups): New function.
714 (riscv_setup_register_aliases): New function.
715 (riscv_init_reggroups): New function.
716 (_initialize_riscv_tdep): Add calls to setup CSR aliases, and
717 setup register groups. Register new riscv debug variable.
718 * riscv-tdep.h: Add 'arch/riscv.h' include.
719 (struct gdbarch_tdep): Remove abi union, and add
720 riscv_gdbarch_features field. Remove cached quad floating point
721 type, and provide initialisation for double type field.
722 * target-descriptions.c (maint_print_c_tdesc_cmd): Add riscv to
723 the list of targets using the feature based target descriptions.
724 * NEWS: Mention target description support.
725
726 2018-11-21 Pedro Alves <palves@redhat.com>
727
728 * valops.c (find_method_list, value_find_oload_method_list)
729 (find_overload_match, find_oload_champ): Rename parameters and
730 locals.
731
732 2018-11-21 Pedro Alves <palves@redhat.com>
733
734 * valops.c (find_method_list): Replace pointer and length
735 parameters with an gdb::array_view. Adjust.
736 (value_find_oload_method_list): Likewise.
737 (find_overload_match): Use gdb::array_view for methods list.
738 Adjust to find_oload_champ interface change.
739 (find_oload_champ): 'xm_worker_vec' parameter now a pointer/array.
740 'num_fns' parameter now a size_t. Eliminate 'fn_count' local.
741
742 2018-11-21 Pedro Alves <palves@redhat.com>
743
744 * gdbtypes.c (compare_badness): Change type of parameters to const
745 reference. Adjust to badness_vector being a std::vector now.
746 (rank_function): Adjust to badness_vector being a std::vector now.
747 * gdbtypes.h (badness_vector): Now a typedef to std::vector.
748 (LENGTH_MATCH): Delete.
749 (compare_badness): Change type of parameters to const reference.
750 (rank_function): Return a badness_vector by value now.
751 (find_overload_match): Adjust to badness_vector being a
752 std::vector now. Remove cleanups.
753 (find_oload_champ_namespace): 'oload_champ_bv' parameter now a
754 badness_vector pointer.
755 (find_oload_champ_namespace_loop): 'oload_champ_bv' parameter now
756 a badness_vector pointer. Adjust to badness_vector being a
757 std::vector now. Remove cleanups.
758 (find_oload_champ): 'oload_champ_bv' parameter now
759 a badness_vector pointer. Adjust to badness_vector being a
760 std::vector now. Remove cleanups.
761
762 2018-11-21 Pedro Alves <palves@redhat.com>
763
764 * cp-support.c (sym_return_val_size, sym_return_val_index)
765 (sym_return_val): Delete.
766 (overload_list_add_symbol): Add std::vector parameter. Adjust to
767 add to the vector.
768 (make_symbol_overload_list): Adjust to return a std::vector
769 instead of maintaining a global open coded vector.
770 (make_symbol_overload_list_block): Add std::vector parameter.
771 (make_symbol_overload_list_block): Rename to ...
772 (add_symbol_overload_list_block): ... this and add std::vector
773 parameter.
774 (make_symbol_overload_list_namespace): Rename to ...
775 (add_symbol_overload_list_namespace): ... this and add std::vector
776 parameter.
777 (make_symbol_overload_list_adl_namespace): Rename to ...
778 (add_symbol_overload_list_adl_namespace): ... this and add
779 std::vector parameter.
780 (make_symbol_overload_list_adl): Delete.
781 (add_symbol_overload_list_adl): New.
782 (make_symbol_overload_list_using): Rename to ...
783 (add_symbol_overload_list_using): ... this and add std::vector
784 parameter.
785 (make_symbol_overload_list_qualified): Rename to ...
786 (add_symbol_overload_list_qualified): ... this and add std::vector
787 parameter.
788 * cp-support.h: Include "common/array-view.h" and <vector>.
789 (make_symbol_overload_list): Change return type to std::vector.
790 (make_symbol_overload_list_adl): Delete declaration.
791 (add_symbol_overload_list_adl): New declaration.
792 * valops.c (find_overload_match): Local 'oload_syms' now a
793 std::vector.
794 (find_oload_champ_namespace): 'oload_syms' parameter now a
795 std::vector pointer.
796 (find_oload_champ_namespace_loop): 'oload_syms' parameter now a
797 std::vector pointer. Adjust to new make_symbol_overload_list
798 interface.
799
800 2018-11-21 Pedro Alves <palves@redhat.com>
801
802 * common/array-view.h (array_view::splice(size_type, size_t)): New.
803 (array_view::splice(size_type)): New.
804 * eval.c (eval_call, evaluate_funcall): Adjust to use array_view.
805 * extension.c (xmethod_worker::get_arg_types): Adjust to return an
806 std::vector.
807 (xmethod_worker::get_result_type): Adjust to use gdb::array_view.
808 * extension.h: Include "common/array-view.h".
809 (xmethod_worker::invoke): Adjust to use gdb::array_view.
810 (xmethod_worker::get_arg_types): Adjust to return an std::vector.
811 (xmethod_worker::get_result_type): Adjust to use gdb::array_view.
812 (xmethod_worker::do_get_arg_types): Adjust to use std::vector.
813 (xmethod_worker::do_get_result_type): Adjust to use
814 gdb::array_view.
815 * gdbtypes.c (rank_function): Adjust to use gdb::array_view.
816 * gdbtypes.h: Include "common/array-view.h".
817 (rank_function): Adjust to use gdb::array_view.
818 * python/py-xmethods.c (python_xmethod_worker::invoke)
819 (python_xmethod_worker::do_get_arg_types)
820 (python_xmethod_worker::do_get_result_type)
821 (python_xmethod_worker::invoke): Adjust to new interfaces.
822 * valarith.c (value_user_defined_cpp_op, value_user_defined_op)
823 (value_x_binop, value_x_unop): Adjust to use gdb::array_view.
824 * valops.c (find_overload_match, find_oload_champ_namespace)
825 (find_oload_champ_namespace_loop, find_oload_champ): Adjust to use
826 gdb:array_view and the new xmethod_worker interfaces.
827 * value.c (result_type_of_xmethod, call_xmethod): Adjust to use
828 gdb::array_view.
829 * value.h (find_overload_match, result_type_of_xmethod)
830 (call_xmethod): Adjust to use gdb::array_view.
831 * unittests/array-view-selftests.c: Add slicing tests.
832
833 2018-11-21 Pedro Alves <palves@redhat.com>
834
835 * ada-lang.c (ada_evaluate_subexp): Adjust to pass an array_view.
836 * common/array-view.h (make_array_view): New.
837 * compile/compile-object-run.c (compile_object_run): Adjust to
838 pass an array_view.
839 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust.
840 * eval.c (eval_call): Adjust to pass an array_view.
841 (evaluate_subexp_standard): Adjust to pass an array_view.
842 * gcore.c (call_target_sbrk): Adjust to pass an array_view.
843 * guile/scm-value.c (gdbscm_value_call): Likewise.
844 * infcall.c (push_dummy_code): Replace pointer + size parameters
845 with an array_view parameter.
846 (call_function_by_hand, call_function_by_hand_dummy): Likewise and
847 adjust.
848 * infcall.h: Include "common/array-view.h".
849 (call_function_by_hand, call_function_by_hand_dummy): Replace
850 pointer + size parameters with an array_view parameter.
851 * linux-fork.c (inferior_call_waitpid): Adjust to use array_view.
852 * linux-tdep.c (linux_infcall_mmap): Likewise.
853 * objc-lang.c (lookup_objc_class, lookup_child_selector)
854 (value_nsstring, print_object_command): Likewise.
855 * python/py-value.c (valpy_call): Likewise.
856 * rust-lang.c (rust_evaluate_funcall): Likewise.
857 * spu-tdep.c (flush_ea_cache): Likewise.
858 * valarith.c (value_x_binop, value_x_unop): Likewise.
859 * valops.c (value_allocate_space_in_inferior): Likewise.
860 * unittests/array-view-selftests.c (run_tests): Add
861 gdb::make_array_view test.
862
863 2018-11-20 Andrew Burgess <andrew.burgess@embecosm.com>
864
865 * cli-out.c (cli_ui_out::do_field_int): Use string_printf rather
866 than a fixed size buffer.
867
868 2018-11-20 Andrew Burgess <andrew.burgess@embecosm.com>
869
870 * breakpoint.c (print_one_breakpoint_location): Reduce whitespace,
871 and remove insertion of extra spaces in GDB's output.
872 * cli-out.c (cli_ui_out::do_field_fmt): Update header comment.
873 Layout field into a temporary buffer, and then output it as a
874 string field.
875
876 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
877
878 * NEWS: Document the language choice done by
879 'info [types|functions|variables]|rbreak'.
880
881 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
882
883 * symtab.c (treg_matches_sym_type_name): Use
884 scoped_switch_to_sym_language_if_auto instead of local logic.
885 (print_symbol_info): Use scoped_switch_to_sym_language_if_auto
886 to switch to SYM language when language mode is auto.
887
888 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
889
890 * language.h (scoped_switch_to_sym_language_if_auto): New class.
891
892 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
893
894 * symtab.c (search_symbols): Properly check absence of type regexp
895 before entering the loop scanning the minimal symbols.
896
897 2018-11-20 John Darrington <john@darrington.wattle.id.au>
898
899 * s12z-tdep.c (s12z_extract_return_value): New function.
900 (inv_reg_perm) New array.
901 (s12z_return_value): Populate readbuf if non-null.
902
903 2018-11-20 Eli Zaretskii <eliz@gnu.org>
904
905 * common/filestuff.c (gdb_fopen_cloexec): Disable use of "e" mode
906 with 'fopen' also if O_CLOEXEC is equal to O_NOINHERIT, to cater
907 to MinGW fixed by Gnulib.
908 (O_NOINHERIT): Define if not defined.
909
910 2018-11-19 John Darrington <john@darrington.wattle.id.au>
911
912 * s12z-tdep.c (s12z_frame_cache): Add an assertion.
913
914 2018-11-19 Simon Marchi <simon.marchi@polymtl.ca>
915
916 * infrun.c (displaced_step_inferior_state) <next>: Remove.
917
918 2018-11-19 Tom Tromey <tom@tromey.com>
919
920 * source.c (get_filename_and_charpos): Return void.
921
922 2018-11-19 Simon Marchi <simon.marchi@polymtl.ca>
923
924 * skip.c (_initialize_step_skip): Fix "info skip" help.
925
926 2018-11-16 Tom Tromey <tom@tromey.com>
927
928 PR rust/23625:
929 * rust-lang.c (rust_internal_print_type): Handle TYPE_CODE_PTR.
930
931 2018-11-19 Simon Marchi <simon.marchi@ericsson.com>
932
933 * infrun.c (displaced_step_inferior_states): Change type to
934 std::forward_list.
935 (get_displaced_stepping_state): Adjust.
936 (displaced_step_in_progress_any_inferior): Adjust.
937 (add_displaced_stepping_state): Adjust.
938 (remove_displaced_stepping_state): Adjust.
939
940 2018-11-18 Tom Tromey <tom@tromey.com>
941
942 PR build/23814:
943 * target-delegates.c: Rebuild.
944 * ia64-linux-nat.c (class ia64_linux_nat_target)
945 <have_steppable_watchpoint>: Use override. Return true, not 1.
946 (ia64_linux_nat_target::can_use_hw_breakpoint): Rename. Remove
947 "self" argument.
948 (ia64_linux_nat_target::low_new_thread): Rename.
949 (class ia64_linux_nat_target) <read_description>: Don't declare.
950 * target.h (struct target_ops) <have_steppable_watchpoint>: Return
951 bool.
952
953 2018-11-16 Alan Hayward <alan.hayward@arm.com>
954
955 PR gdb/22736:
956 * aarch64-tdep.c (aarch64_push_dummy_call): Remove
957 lang_struct_return code.
958
959 2018-11-16 Alan Hayward <alan.hayward@arm.com>
960
961 * aarch64-tdep.c (aarch64_push_dummy_call): Replace arg with
962 return_method.
963 * alpha-tdep.c (alpha_push_dummy_call): Likewise.
964 * amd64-tdep.c (amd64_push_arguments): Likewise.
965 (amd64_push_dummy_call): Likewise.
966 * amd64-windows-tdep.c (amd64_windows_push_arguments): Likewise.
967 * arc-tdep.c (arc_push_dummy_call): Likewise.
968 * arm-tdep.c (arm_push_dummy_call): Likewise.
969 * avr-tdep.c (avr_push_dummy_call): Likewise.
970 * bfin-tdep.c (bfin_push_dummy_call): Likewise.
971 * cris-tdep.c (cris_push_dummy_call): Likewise.
972 * csky-tdep.c (csky_push_dummy_call): Likewise.
973 * frv-tdep.c (frv_push_dummy_call): Likewise.
974 * gdbarch.c: Regenerate.
975 * gdbarch.h: Regenerate.
976 * gdbarch.sh (gdbarch_push_dummy_call): Replace arg with
977 return_method.
978 * h8300-tdep.c (h8300_push_dummy_call): Likewise.
979 * hppa-tdep.c (hppa32_push_dummy_call): Likewise.
980 (hppa64_push_dummy_call): Likewise.
981 * i386-darwin-tdep.c (i386_darwin_push_dummy_call): Likewise.
982 * i386-tdep.c (i386_push_dummy_call): Likewise.
983 * ia64-tdep.c (ia64_push_dummy_call): Likewise.
984 * infcall.c (call_function_by_hand_dummy): Likewise.
985 * iq2000-tdep.c (iq2000_push_dummy_call): Likewise.
986 * lm32-tdep.c (lm32_push_dummy_call): Likewise.
987 * m32c-tdep.c (m32c_push_dummy_call): Likewise.
988 * m32r-tdep.c (m32r_push_dummy_call): Likewise.
989 * m68hc11-tdep.c (m68hc11_push_dummy_call): Likewise.
990 * m68k-tdep.c (m68k_push_dummy_call): Likewise.
991 * mep-tdep.c (mep_push_dummy_call): Likewise.
992 * mips-tdep.c (mips_eabi_push_dummy_call): Likewise.
993 (mips_n32n64_push_dummy_call): Likewise.
994 (mips_o32_push_dummy_call): Likewise.
995 (mips_o64_push_dummy_call): Likewise.
996 * mn10300-tdep.c (mn10300_push_dummy_call): Likewise.
997 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
998 * nds32-tdep.c (nds32_push_dummy_call): Likewise.
999 * nios2-tdep.c (nios2_push_dummy_call): Likewise.
1000 * or1k-tdep.c (or1k_push_dummy_call): Likewise.
1001 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
1002 (ppc64_sysv_abi_push_dummy_call): Likewise.
1003 * ppc-tdep.h (ppc_sysv_abi_push_dummy_call): Likewise.
1004 (ppc64_sysv_abi_push_dummy_call): Likewise.
1005 * riscv-tdep.c (riscv_push_dummy_call): Likewise.
1006 * rl78-tdep.c (rl78_push_dummy_call): Likewise.
1007 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
1008 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
1009 * rx-tdep.c (rx_push_dummy_call): Likewise.
1010 * s390-tdep.c (s390_push_dummy_call): Likewise.
1011 * score-tdep.c (score_push_dummy_call): Likewise.
1012 * sh-tdep.c (sh_push_dummy_call_fpu): Likewise.
1013 (sh_push_dummy_call_nofpu): Likewise.
1014 * sparc-tdep.c (sparc32_store_arguments): Likewise.
1015 (sparc32_push_dummy_call): Likewise.
1016 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
1017 (sparc64_push_dummy_call): Likewise.
1018 * spu-tdep.c (spu_push_dummy_call): Likewise.
1019 * tic6x-tdep.c (tic6x_push_dummy_call): Likewise.
1020 * tilegx-tdep.c (tilegx_push_dummy_call): Likewise.
1021 * v850-tdep.c (v850_push_dummy_call): Likewise.
1022 * vax-tdep.c (vax_push_dummy_call): Likewise.
1023 * xstormy16-tdep.c (xstormy16_push_dummy_call): Likewise.
1024 * xtensa-tdep.c (xtensa_push_dummy_call): Likewise.
1025
1026 2018-11-16 Alan Hayward <alan.hayward@arm.com>
1027
1028 * gdbarch.sh (enum function_call_return_method): Add enum.
1029 * gdbarch.h: Regenerate.
1030 * infcall.c (call_function_by_hand_dummy): Replace vars with enum.
1031
1032 2018-11-15 Joel Brobecker <brobecker@adacore.com>
1033
1034 * unittests/copy_bitwise-selftests.c: New file.
1035 * utils.c (selftests::bits_to_str, selftests::check_copy_bitwise)
1036 (selftests::copy_bitwise_tests): Delete, moving this code to
1037 unittests/copy_bitwise-selftests.c instead.
1038 (_initialize_utils): Do not register copy_bitwise tests.
1039 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1040 unittests/copy_bitwise-selftests.c.
1041
1042 2018-11-14 Joel Brobecker <brobecker@adacore.com>
1043
1044 * ada-lang.c (move_bits): Delete. Update all callers to use
1045 copy_bitwise instead.
1046 * dwarf2loc.c (copy_bitwise, bits_to_str::bits_to_str)
1047 (selftests::check_copy_bitwise, selftests::copy_bitwise_tests):
1048 Move from here to utils.c.
1049 (_initialize_dwarf2loc): Remove call to register copy_bitwise
1050 selftests.
1051 * utils.h (copy_bitwise): Add declaration.
1052 * utils.c (copy_bitwise, bits_to_str::bits_to_str)
1053 (selftests::check_copy_bitwise, selftests::copy_bitwise_tests):
1054 Moved here from dwarf2loc.c.
1055 (_initialize_utils): Register copy_bitwise selftests.
1056
1057 2018-11-14 Jim Wilson <jimw@sifive.com>
1058
1059 * riscv-tdep.c (struct riscv_arg_info): New field is_unnamed.
1060 (riscv_call_arg_scalar_int): If unnamed arg with twice xlen alignment,
1061 then increment next_regnum if odd.
1062 (riscv_arg_location): New arg is_unnamed. Set ainfo->is_unnamed.
1063 (riscv_push_dummy_call): New local ftype. Call check_typedef to set
1064 function type. Pass new arg to riscv_arg_location based on function
1065 type.
1066 (riscv_return_value): Pass new arg to riscv_arg_location.
1067
1068 * riscv-tdep.c (BIGGEST_ALIGNMENT): New.
1069 (riscv_type_alignment) <TYPE_CODE_ARRAY>: If TYPE_VECTOR, return min
1070 of TYPE_LENGTH and BIGGEST_ALIGNMENT.
1071
1072 * riscv-tdep.c (riscv_call_arg_scalar_int): Use std::min when
1073 setting len. New local align, set to max of arg align and xlen,
1074 and pass to first riscv_assign_stack_location call.
1075
1076 2018-11-12 Simon Marchi <simon.marchi@polymtl.ca>
1077
1078 * skip.c (complete_skip_number): New function.
1079 (_initialize_step_skip): Add completers to some skip commands.
1080
1081 2018-11-09 Tom Tromey <tom@tromey.com>
1082
1083 * remote.c (remote_g_packet_guess_s): Remove typedef and DEF_VEC.
1084 (struct remote_g_packet_data): Derive from allocate_on_obstack.
1085 <guesses>: Now a std::vector.
1086 (remote_g_packet_data_init, register_remote_g_packet_guess):
1087 Update.
1088 (remote_read_description_p): Update. Return bool.
1089 (remote_target::read_description): Update.
1090 (struct remote_g_packet_guess): Add constructor.
1091
1092 2018-11-09 Tom Tromey <tom@tromey.com>
1093
1094 * common/scoped_fd.h (class scoped_fd): Add move constructor and
1095 move assignment operator.
1096 * psymtab.c (psymtab_to_fullname): Update.
1097 * source.h (open_source_file): Return scoped_fd.
1098 (find_and_open_source): Likewise.
1099 * source.c (open_source_file): Return scoped_fd.
1100 (get_filename_and_charpos): Update.
1101 (print_source_lines_base): Update. Use scoped_fd::to_file.
1102 (forward_search_command): Likewise.
1103 (reverse_search_command): Likewise.
1104 (find_and_open_source): Return scoped_fd.
1105 * tui/tui-source.c (tui_set_source_content): Update. Use
1106 gdb_file_up.
1107
1108 2018-11-09 John Baldwin <jhb@FreeBSD.org>
1109
1110 * minsyms.c (minimal_symbol_reader::install): Fix unsigned
1111 overflow.
1112
1113 2018-11-09 Hafiz Abid Qadeer <abidh@codesourcery.com>
1114
1115 * configure: Regenerate.
1116
1117 2018-11-09 Tom de Vries <tdevries@suse.de>
1118
1119 * symtab.c (symbol_set_names): Call symbol_find_demangled_name
1120 unconditionally, to set the language of the symbol. Manage freeing
1121 returned pointer using gdb::unique_xmalloc_ptr.
1122
1123 2018-11-08 Tom Tromey <tom@tromey.com>
1124
1125 * record.c (require_record_target): Upper-case "<TAB>".
1126
1127 2018-11-08 Tom Tromey <tom@tromey.com>
1128
1129 * python/lib/gdb/command/pretty_printers.py
1130 (InfoPrettyPrinter.invoke): Don't indent "objfile" heading.
1131
1132 2018-11-08 Tom Tromey <tom@tromey.com>
1133
1134 PR gdb/23555:
1135 PR gdb/23838:
1136 * target.h (target_supports_terminal_ours): Return bool.
1137 * target.c (target_supports_terminal_ours): Handle case where
1138 current_top_target returns nullptr. Return bool.
1139
1140 2018-11-08 Joel Brobecker <brobecker@adacore.com>
1141
1142 * aarch64-tdep.c (aapcs_is_vfp_call_or_return_candidate_1):
1143 return the correct count for potential HFAs.
1144
1145 2018-11-08 Jan Beulich <jbeulich@suse.com>
1146
1147 * i387-tdep.c (i387_supply_xsave): Split handling of
1148 X86_XSTATE_ZMM_H and X86_XSTATE_ZMM.
1149 (i387_collect_xsave): Likewise.
1150
1151 2018-11-08 Andrew Burgess <andrew.burgess@embecosm.com>
1152
1153 * riscv-tdep.c (riscv_insn::decode): Update header comment.
1154 (riscv_frame_this_id): Catch errors thrown while building the
1155 frame cache, leave the frame id as the default, which is the outer
1156 frame id.
1157
1158 2018-11-07 Joel Brobecker <brobecker@adacore.com>
1159
1160 * ada-lang.c (read_atcb): Only set task_info->called_task if
1161 task_info->state == Entry_Caller_Sleep.
1162 (print_ada_task_info): Do not check task_info->state before
1163 checking task_info->called_task.
1164 (info_task): Likewise.
1165
1166 2018-11-07 Joel Brobecker <brobecker@adacore.com>
1167
1168 * ada-tasks.c (read_atcb): Clear task_info before computing
1169 the value of each of its fields.
1170
1171 2018-11-07 Andrew Burgess <andrew.burgess@embecosm.com>
1172
1173 * dwarf2read.c (dwarf2_init_integer_type): Check for name being
1174 NULL before dereferencing it.
1175
1176 2018-11-06 Tom de Vries <tdevries@suse.de>
1177
1178 * linux-tdep.c (linux_vsyscall_range_raw): Use xmalloc to allocate
1179 program headers.
1180
1181 2018-11-06 Max Filippov <jcmvbkbc@gmail.com>
1182
1183 * configure.tgt (xtensa*-*-linux*): Change to xtensa*-*-*linux*
1184 so that it applies to uclinux as well.
1185
1186 2018-11-06 Marius Muench <marius.muench@eurecom.fr>
1187
1188 * arm-tdep.c (arm_scan_prologue): Don't dereference FP reg
1189 when on AAPCS.
1190
1191 2018-11-06 John Baldwin <jhb@FreeBSD.org>
1192
1193 * riscv-fbsd-nat.c (getregs_supplies): Return true for
1194 RISCV_CSR_SSTATUS_REGNUM.
1195
1196 2018-11-04 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1197
1198 * source.c (open_source_file): Fix leak by transferring the
1199 current s->fullname to the unique_xmalloc_ptr fullname given
1200 to find_and_open_source.
1201
1202 2018-11-04 Tom Tromey <tom@tromey.com>
1203
1204 * varobj.c (install_default_visualizer): Update.
1205 * python/python-internal.h (gdbpy_get_varobj_pretty_printer):
1206 Return gdbpy_ref.
1207 * python/py-prettyprint.c (search_pp_list): Return gdbpy_ref.
1208 (find_pretty_printer_from_progspace)
1209 (find_pretty_printer_from_gdb, find_pretty_printer)
1210 (gdbpy_get_varobj_pretty_printer): Return gdbpy_ref.
1211 (gdbpy_get_varobj_pretty_printer, gdbpy_default_visualizer):
1212 Update.
1213
1214 2018-11-04 Tom Tromey <tom@tromey.com>
1215
1216 * python/python.c (gdbpy_parameter_value): Update.
1217 * python/python-internal.h (python_string_to_unicode)
1218 (python_string_to_target_python_string)
1219 (host_string_to_python_string): Return gdbpy_ref.
1220 * python/py-utils.c (python_string_to_unicode)
1221 (unicode_to_encoded_python_string)
1222 (unicode_to_target_python_string)
1223 (python_string_to_target_string)
1224 (python_string_to_target_python_string): Return gdbpy_ref.
1225 (python_string_to_host_string): Update.
1226 (host_string_to_python_string): Return gdbpy_ref.
1227 * python/py-symtab.c (stpy_get_filename, stpy_get_producer)
1228 (stpy_fullname): Update.
1229 * python/py-progspace.c (pspy_get_filename, pspy_solib_name):
1230 Update.
1231 * python/py-prettyprint.c (print_string_repr): Update.
1232 * python/py-objfile.c (objfpy_get_filename, objfpy_get_username)
1233 (objfpy_get_build_id): Update.
1234 * python/py-breakpoint.c (bppy_get_location)
1235 (bppy_get_expression, bppy_get_condition, bppy_get_commands):
1236 Update.
1237
1238 2018-11-04 Tom Tromey <tom@tromey.com>
1239
1240 * python/python-internal.h (gdb_py_object_from_longest)
1241 (gdb_py_object_from_ulongest): Return gdbpy_ref.
1242 * python/py-value.c (valpy_int): Update.
1243 * python/py-utils.c (gdb_py_object_from_longest): Return
1244 gdbpy_ref.
1245 (gdb_py_object_from_ulongest): Likewise.
1246 * python/py-type.c (typy_get_alignof): Update.
1247 * python/py-linetable.c (ltpy_get_all_source_lines)
1248 (ltpy_entry_get_line, ltpy_entry_get_pc): Update.
1249 * python/py-block.c (blpy_get_start, blpy_get_end): Update.
1250
1251 2018-11-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1252
1253 * ada-lang.c (_initialize_ada_language): Fix typo.
1254
1255 2018-11-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1256
1257 * language.c (type): Remove.
1258 (_initialize_language): Remove assignment to type.
1259
1260 2018-11-02 Joel Brobecker <brobecker@adacore.com>
1261
1262 * aarch64-ravenscar-thread.h, aarch64-ravenscar-thread.c: New files.
1263 * aarch64-tdep.c: #include "aarch64-ravenscar-thread.h".
1264 (aarch64_gdbarch_init): Add call to register_aarch64_ravenscar_ops.
1265 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-ravenscar-thread.o.
1266 (HFILES_NO_SRCDIR): Add aarch64-ravenscar-thread.h.
1267 (ALLDEPFILES): Add aarch64-ravenscar-thread.c.
1268 * configure.tgt (cpu_obs) [aarch64*-*-*]: Add ravenscar-thread.o
1269 and aarch64-ravenscar-thread.o.
1270 * NEWS: Add entry documenting Ravenscar tasking support
1271 on AArch64 ELF.
1272
1273 2018-11-02 Matthew Malcomson <matthew.malcomson@arm.com>
1274
1275 * symtab.c (info_functions_command): Initialize quiet flag.
1276 * stack.c (info_args_command): Likewise.
1277
1278 2018-11-01 Jim Wilson <jimw@sifive.com>
1279
1280 * riscv-tdep.c (riscv_breakpoint_kind_from_pc): New local unaligned_p.
1281 Set if pcptr if unaligned. Return 2 if unaligned_p true. Update
1282 debugging messages.
1283
1284 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1285
1286 * ada-lang.c (ada_watch_location_expression): New function.
1287 (ada_language_defn): Set la_watch_location_expression to
1288 ada_watch_location_expression.
1289
1290 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1291
1292 * print-utils.c (int_string): Remove unnecessary trailing spaces.
1293
1294 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1295
1296 * rs6000-tdep.c (skip_prologue): Fix potential negative left
1297 shifting.
1298
1299 2018-11-01 Jerome Guitton <guitton@adacore.com>
1300 Joel Brobecker <brobecker@adacore.com>
1301
1302 * defs.h (enum gdb_osabi): Add GDB_OSABI_PIKEOS.
1303 * osabi.c (gdb_osabi_names): Add name for GDB_OSABI_PIKEOS.
1304 * arm-pikeos-tdep.c: New file.
1305 * configure.tgt: Add arm-pikeos-tdep.o to the case of ARM
1306 embedded system.
1307 * Makefile.in (ALL_TARGET_OBS): Add arm-pikeos-tdep.o.
1308
1309 2018-11-01 Simon Marchi <simon.marchi@ericsson.com>
1310
1311 * common/pathstuff.c (get_standard_temp_dir): New.
1312 * common/pathstuff.h (get_standard_temp_dir): New.
1313 * config.in: Re-generate.
1314 * configure: Re-generate.
1315 * configure.ac: Don't check for mkdtemp.
1316 * gnulib/aclocal-m4-deps.mk: Re-generate.
1317 * gnulib/aclocal.m4: Re-generate.
1318 * gnulib/config.in: Re-generate.
1319 * gnulib/configure: Re-generate.
1320 * gnulib/import/Makefile.am: Re-generate.
1321 * gnulib/import/Makefile.in: Re-generate.
1322 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
1323 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
1324 * gnulib/import/m4/mkdtemp.m4: New file.
1325 * gnulib/import/mkdtemp.c: New file.
1326 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES):
1327 Add mkdtemp module.
1328 * unittests/mkdir-recursive-selftests.c (test): Use
1329 get_standard_temp_dir.
1330 (_initialize_mkdir_recursive_selftests): Remove HAVE_MKDTEMP
1331 ifdef.
1332 * compile/compile.c (get_compile_file_tempdir): Likewise.
1333
1334 2018-11-01 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
1335
1336 * rs6000-aix-tdep.c: Include "trad-frame.h" and "frame-unwind.h".
1337 (SIG_FRAME_LR_OFFSET64): New define.
1338 (SIG_FRAME_FP_OFFSET64): New define.
1339 (aix_sighandle_frame_cache): New Function.
1340 (aix_sighandle_frame_this_id): New Function.
1341 (aix_sighandle_frame_prev_register): New Function.
1342 (aix_sighandle_frame_sniffer): New Function.
1343 (aix_sighandle_frame_unwind): New global variable.
1344 (rs6000_aix_init_osabi): Install new frame unwinder.
1345
1346 2018-10-31 Sergio Durigan Junior <sergiodj@redhat.com>
1347
1348 PR gdb/23835
1349 * common/common-defs.h: Don't redefine _FORTIFY_SOURCE if it's
1350 already defined.
1351
1352 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1353
1354 * ppc-linux-nat.c: Include nat/linux-ptrace.h.
1355
1356 2018-10-31 Andrew Burgess <andrew.burgess@embecosm.com>
1357
1358 * dwarf2read.c (struct dwarf2_cu): Add producer_is_icc field.
1359 (producer_is_icc): New function.
1360 (check_producer): Set producer_is_icc field on dwarf2_cu.
1361 (dwarf2_init_integer_type): New function.
1362 (read_base_type): Call dwarf2_init_integer_type instead of
1363 init_integer_type in all cases.
1364 (dwarf2_cu::dwarf2_cu): Initialise producer_is_icc field.
1365 * valprint.c (maybe_negate_by_bytes): Add an assertion that the
1366 LEN is greater than 0.
1367
1368 2018-10-30 Tom Tromey <tom@tromey.com>
1369
1370 * main.c (captured_main_1): Check return value of bfd_init.
1371
1372 2018-10-29 Sergio Durigan Junior <sergiodj@redhat.com>
1373
1374 * common/offset-type.h (DEFINE_OFFSET_REL_OP): Delete.
1375 Adjust comments.
1376
1377 2018-10-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1378
1379 * procfs.c: Include common/pathstuff.h.
1380
1381 2018-10-28 Andrew Burgess <andrew.burgess@embecosm.com>
1382
1383 * riscv-linux-nat.c (riscv_linux_nat_target::fetch_registers):
1384 Add missing braces. No functional change.
1385
1386 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1387
1388 * macrocmd.c (info_macro_command): Use report_unrecognized_option_error
1389 to report a bad option and fix indentation.
1390 * demangle.c (demangle_command): Use report_unrecognized_option_error
1391 to report a bad option and correctly report the bad option.
1392
1393 2018-10-27 Tom Tromey <tom@tromey.com>
1394
1395 PR cli/23364:
1396 * darwin-nat.c (copied_shell): New global.
1397 (may_have_sip): Rename from should_disable_startup_with_shell.
1398 (copy_shell_to_cache, maybe_cache_shell): New functions.
1399 (darwin_nat_target::create_inferior): Update. Use
1400 copied_shell.
1401
1402 2018-10-27 Tom Tromey <tom@tromey.com>
1403
1404 * unittests/scoped_fd-selftests.c (test_to_file): New function.
1405 (run_tests): Call test_to_file.
1406 * dwarf-index-write.c (write_psymtabs_to_index): Do not reopen
1407 temporary files.
1408 * common/scoped_fd.h (scoped_fd::to_file): New method.
1409
1410 2018-10-27 Tom Tromey <tom@tromey.com>
1411
1412 * unittests/scoped_mmap-selftests.c (test_normal): Use
1413 gdb_mkostemp_cloexec.
1414 * unittests/scoped_fd-selftests.c (test_destroy, test_release):
1415 Use gdb_mkostemp_cloexec.
1416 * gnulib/aclocal-m4-deps.mk, gnulib/aclocal.m4,
1417 gnulib/config.in, gnulib/configure,
1418 gnulib/import/Makefile.am, gnulib/import/Makefile.in,
1419 gnulib/import/m4/gnulib-cache.m4,
1420 gnulib/import/m4/gnulib-comp.m4: Update.
1421 * gnulib/import/m4/mkostemp.m4: New file.
1422 * gnulib/import/m4/mkstemp.m4: Remove.
1423 * gnulib/import/mkostemp.c: New file.
1424 * gnulib/import/mkstemp.m4: Remove.
1425 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Remove
1426 mkstemp, add mkostemp. Apply new patch.
1427 * gnulib/import/stdlib.in.h: Apply patch.
1428 * gnulib/patches/0002-mkostemp-mkostemps-Fix-compilation-error-in-C-mode-o.patch:
1429 New file.
1430 * dwarf-index-write.c (write_psymtabs_to_index): Use
1431 gdb_mkostemp_cloexec.
1432 * common/filestuff.h (gdb_mkostemp_cloexec): New function.
1433
1434 2018-10-27 Tom Tromey <tom@tromey.com>
1435
1436 * unittests/mkdir-recursive-selftests.c: New file.
1437 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1438 unittests/mkdir-recursive-selftests.c.
1439 * dwarf-index-cache.c (mkdir_recursive): Move to
1440 common/filestuff.c.
1441 (index_cache::store): Check return value of mkdir_recursive.
1442 (create_dir_and_check, test_mkdir_recursive): Move to new file.
1443 (_initialize_index_cache): Don't register test.
1444 * common/filestuff.h (mkdir_recursive): Declare.
1445 * common/filestuff.c (mkdir_recursive): Move from
1446 dwarf-index-cache.c. Return bool.
1447
1448 2018-10-27 Tom Tromey <tom@tromey.com>
1449
1450 * dwarf-index-write.c (write_psymtabs_to_index): Move
1451 make_temp_filename to common/pathstuff.c.
1452 * common/pathstuff.h (make_temp_filename): Declare.
1453 * common/pathstuff.c (make_temp_filename): New function, moved
1454 from dwarf-index-write.c.
1455
1456 2018-10-27 Tom Tromey <tom@tromey.com>
1457
1458 * procfs.c (procfs_target::create_inferior): Use get_shell.
1459 * cli/cli-cmds.c (shell_escape): Use get_shell.
1460 * windows-nat.c (windows_nat_target::create_inferior): Use
1461 get_shell.
1462 * common/pathstuff.c (get_shell): New function.
1463 * nat/fork-inferior.c (SHELL_FILE, get_startup_shell): Remove.
1464 (fork_inferior): Use get_shell.
1465 * common/pathstuff.h (get_shell): Declare.
1466
1467 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1468
1469 * NEWS: Mention changes to 'info [args|functions|locals|variables]'
1470
1471 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1472
1473 * stack.c (print_variable_and_value_data): Add preg and treg.
1474 (print_frame_local_vars): Add quiet, regexp and t_regexp arguments,
1475 and update callers.
1476 (print_frame_arg_vars): Likewise.
1477 (prepare_reg): New function.
1478 (info_locals_command): Extract info print args and use them.
1479 (info_args_command): Likewise.
1480 (_initialize_stack): Modify on-line help.
1481 * symtab.c (treg_matches_sym_type_name): New function.
1482 (search_symbols): New arg t_regexp.
1483 (symtab_symbol_info): New args quiet, regexp, t_regexp.
1484 (info_variables_command): Extract info print args and use them.
1485 (info_functions_command): Likewise.
1486 (info_types_command): Update call to symtab_symbol_info.
1487 (_initialize_symtab): Modify on-line help.
1488 * symtab.h (treg_matches_sym_type_name): New function.
1489 (search_symbols): New t_regexp arg.
1490
1491 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1492
1493 * cli-utils.c (extract_arg_maybe_quoted): New function.
1494 (extract_info_print_args): New function.
1495 (info_print_args_help): New function.
1496 (report_unrecognized_option_error): New function.
1497 * cli-utils.h (extract_arg_maybe_quoted): New function.
1498 (extract_info_print_args): New function.
1499 (info_print_args_help): New function.
1500 (report_unrecognized_option_error): New function.
1501
1502 2018-10-26 Tom Tromey <tom@tromey.com>
1503
1504 * dwarf2read.c (recursively_compute_inclusions): Use std::vector.
1505 (compute_compunit_symtab_includes): Update.
1506 * symtab.h: (symtab_ptr): Remove typedef. Don't define a VEC.
1507 (compunit_symtab_ptr): Likewise.
1508
1509 2018-10-26 John Baldwin <jhb@FreeBSD.org>
1510
1511 * fbsd-tdep.c (fbsd_print_auxv_entry): Only use
1512 default_print_auxv_entry for specific tag values.
1513
1514 2018-10-26 John Baldwin <jhb@FreeBSD.org>
1515
1516 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_HWCAP2.
1517
1518 2018-10-26 Jim Wilson <jimw@sifive.com>
1519
1520 * riscv-linux-tdep.c: Include tramp-frame.h and trad-frame.h.
1521 (riscv_linux_sigframe_init): Declare.
1522 (RISCV_INST_LI_A7_SIGRETURN, RISCV_INT_ECALL): New.
1523 (riscv_linux_sigframe): New.
1524 (SIGFRAME_SIGINFO_SIZE, UCONTEXT_MCONTEXT_OFFSET): New.
1525 (riscv_linux_sigframe_init): Define.
1526 (riscv_linux_init_abi): Call tramp_frame_prepend_unwinder.
1527
1528 * riscv-tdep.c (riscv_isa_xlen): Refer to riscv-tdep.h comment.
1529 (riscv_isa_flen): Likewise. Drop static.
1530 * riscv-tdep.h (riscv_isa_xlen): Move riscv-tdep.c comment to here.
1531 (riscv_isa_flen): Likewise. Declare.
1532
1533 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1534 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1535
1536 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa207_htm_vsx32l)
1537 (tdesc_powerpc_isa207_htm_vsx64l): Declare.
1538 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_TM_SPRREGSET)
1539 (PPC32_LINUX_SIZEOF_CGPRREGSET, PPC64_LINUX_SIZEOF_CGPRREGSET)
1540 (PPC_LINUX_SIZEOF_CFPRREGSET, PPC_LINUX_SIZEOF_CVMXREGSET)
1541 (PPC_LINUX_SIZEOF_CVSXREGSET, PPC_LINUX_SIZEOF_CPPRREGSET)
1542 (PPC_LINUX_SIZEOF_CDSCRREGSET, PPC_LINUX_SIZEOF_CTARREGSET):
1543 Define.
1544 (struct ppc_linux_features) <htm>: New field.
1545 (ppc_linux_no_features): Add initializer for htm field.
1546 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
1547 new tdescs.
1548 * nat/ppc-linux.h (PPC_FEATURE2_HTM, NT_PPC_TM_CGPR)
1549 (NT_PPC_TM_CFPR, NT_PPC_TM_CVMX, NT_PPC_TM_CVSX)
1550 (NT_PPC_TM_SPR, NT_PPC_TM_CTAR, NT_PPC_TM_CPPR, NT_PPC_TM_CDSCR):
1551 Define if not already defined.
1552 * features/Makefile (WHICH): Add rs6000/powerpc-isa207-htm-vsx32l
1553 and rs6000/powerpc-isa207-htm-vsx64l.
1554 (XMLTOC): Add rs6000/powerpc-isa207-htm-vsx32l.xml and
1555 rs6000/powerpc-isa207-htm-vsx64l.xml.
1556 * features/rs6000/power-htm-spr.xml: New file.
1557 * features/rs6000/power-htm-core.xml: New file.
1558 * features/rs6000/power64-htm-core.xml: New file.
1559 * features/rs6000/power-htm-fpu.xml: New file.
1560 * features/rs6000/power-htm-altivec.xml: New file.
1561 * features/rs6000/power-htm-vsx.xml: New file.
1562 * features/rs6000/power-htm-ppr.xml: New file.
1563 * features/rs6000/power-htm-dscr.xml: New file.
1564 * features/rs6000/power-htm-tar.xml: New file.
1565 * features/rs6000/powerpc-isa207-htm-vsx32l.xml: New file.
1566 * features/rs6000/powerpc-isa207-htm-vsx64l.xml: New file.
1567 * features/rs6000/powerpc-isa207-htm-vsx32l.c: Generate.
1568 * features/rs6000/powerpc-isa207-htm-vsx64l.c: Generate.
1569 * regformats/rs6000/powerpc-isa207-htm-vsx32l.dat: Generate.
1570 * regformats/rs6000/powerpc-isa207-htm-vsx64l.dat: Generate.
1571 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
1572 fetch_regset with HTM regsets.
1573 (store_register, store_ppc_registers): Call store_regset with HTM
1574 regsets.
1575 (ppc_linux_nat_target::read_description): Set htm field in the
1576 features struct if needed.
1577 * ppc-linux-tdep.c: Include
1578 features/rs6000/powerpc-isa207-htm-vsx32l.c and
1579 features/rs6000/powerpc-isa207-htm-vsx64l.c.
1580 (ppc32_regmap_tm_spr, ppc32_regmap_cgpr, ppc64_le_regmap_cgpr)
1581 (ppc64_be_regmap_cgpr, ppc32_regmap_cfpr, ppc32_le_regmap_cvmx)
1582 (ppc32_be_regmap_cvmx, ppc32_regmap_cvsx, ppc32_regmap_cppr)
1583 (ppc32_regmap_cdscr, ppc32_regmap_ctar): New globals.
1584 (ppc32_linux_tm_sprregset, ppc32_linux_cgprregset)
1585 (ppc64_be_linux_cgprregset, ppc64_le_linux_cgprregset)
1586 (ppc32_linux_cfprregset, ppc32_le_linux_cvmxregset)
1587 (ppc32_be_linux_cvmxregset, ppc32_linux_cvsxregset)
1588 (ppc32_linux_cpprregset, ppc32_linux_cdscrregset)
1589 (ppc32_linux_ctarregset): New globals.
1590 (ppc_linux_cgprregset, ppc_linux_cvmxregset): New functions.
1591 (ppc_linux_collect_core_cpgrregset): New function.
1592 (ppc_linux_iterate_over_regset_sections): Call back with the htm
1593 regsets.
1594 (ppc_linux_core_read_description): Check if the tm spr section is
1595 present and set htm in the features struct.
1596 (_initialize_ppc_linux_tdep): Call
1597 initialize_tdesc_powerpc_isa207_htm_vsx32l and
1598 initialize_tdesc_powerpc_isa207_htm_vsx64l.
1599 * ppc-linux-tdep.h (ppc_linux_cgprregset, ppc_linux_cvmxregset):
1600 Declare.
1601 (ppc32_linux_tm_sprregset, ppc32_linux_cfprregset)
1602 (ppc32_linux_cvsxregset, ppc32_linux_cpprregset)
1603 (ppc32_linux_cdscrregset, ppc32_linux_ctarregset): Declare.
1604 * ppc-tdep.h (struct gdbarch_tdep) <have_htm_spr, have_htm_core>:
1605 New fields.
1606 <have_htm_fpu, have_htm_altivec, have_htm_vsx>:
1607 Likewise.
1608 <ppc_cppr_regnum, ppc_cdscr_regnum, ppc_ctar_regnum>: Likewise.
1609 <ppc_cdl0_regnum, ppc_cvsr0_regnum, ppc_cefpr0_regnum>: Likewise.
1610 (enum) <PPC_TFHAR_REGNUM, PPC_TEXASR_REGNUM, PPC_TFIAR_REGNUM>:
1611 New enum fields.
1612 <PPC_CR0_REGNUM, PPC_CCR_REGNUM, PPC_CXER_REGNUM>: Likewise.
1613 <PPC_CLR_REGNUM, PPC_CCTR_REGNUM, PPC_CF0_REGNUM>: Likewise.
1614 <PPC_CFPSCR_REGNUM, PPC_CVR0_REGNUM, PPC_CVSCR_REGNUM>: Likewise.
1615 <PPC_CVRSAVE_REGNUM, PPC_CVSR0_UPPER_REGNUM>: Likewise.
1616 <PPC_CPPR_REGNUM, PPC_CDSCR_REGNUM>: Likewise.
1617 <PPC_CTAR_REGNUM>: Likewise.
1618 (PPC_IS_TMSPR_REGNUM, PPC_IS_CKPTGP_REGNUM, PPC_IS_CKPTFP_REGNUM)
1619 (PPC_IS_CKPTVMX_REGNUM, PPC_IS_CKPTVSX_REGNUM): Define.
1620 * rs6000-tdep.c (IS_CDFP_PSEUDOREG, IS_CVSX_PSEUDOREG)
1621 (IS_CEFP_PSEUDOREG): Define.
1622 (rs6000_register_name): Hide the upper halves of checkpointed VSX
1623 registers. Return names for the checkpointed DFP, VSX, and EFP
1624 pseudo registers.
1625 (rs6000_pseudo_register_type): Remove initial assert and raise an
1626 internal error in the else clause instead. Return types for the
1627 checkpointed DFP, VSX, and EFP pseudo registers.
1628 (dfp_pseudo_register_read, dfp_pseudo_register_write): Handle
1629 checkpointed DFP pseudo registers.
1630 (vsx_pseudo_register_read, vsx_pseudo_register_write): Handle
1631 checkpointed VSX pseudo registers.
1632 (efp_pseudo_register_read, efp_pseudo_register_write): Rename
1633 from efpr_pseudo_register_read and
1634 efpr_pseudo_register_write. Handle checkpointed EFP pseudo
1635 registers.
1636 (rs6000_pseudo_register_read, rs6000_pseudo_register_write):
1637 Handle checkpointed DFP, VSX, and EFP registers.
1638 (dfp_ax_pseudo_register_collect, vsx_ax_pseudo_register_collect)
1639 (efp_ax_pseudo_register_collect): New functions.
1640 (rs6000_ax_pseudo_register_collect): Move DFP, VSX and EFP pseudo
1641 register logic to new functions. Handle checkpointed DFP, VSX,
1642 and EFP pseudo registers.
1643 (rs6000_gdbarch_init): Look for and validate the htm features.
1644 Include checkpointed DFP, VSX and EFP pseudo-registers.
1645 * NEWS: Mention access to PPR, DSCR, TAR, EBB/PMU registers and
1646 HTM registers.
1647
1648 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1649
1650 * rs6000-tdep.c (rs6000_gdbarch_init): Reject tdescs with vsx but
1651 without altivec or fpu.
1652
1653 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1654 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1655
1656 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_EBBREGSET)
1657 (PPC_LINUX_SIZEOF_PMUREGSET): Declare.
1658 * nat/ppc-linux.h (PPC_FEATURE2_EBB, NT_PPC_EBB, NT_PPC_PMU):
1659 Define if not already defined.
1660 * features/rs6000/power-ebb.xml: New file.
1661 * features/rs6000/power-linux-pmu.xml: New file.
1662 * features/rs6000/powerpc-isa207-vsx32l.xml: Include ebb and pmu
1663 features.
1664 * features/rs6000/powerpc-isa207-vsx64l.xml: Likewise.
1665 * features/rs6000/powerpc-isa207-vsx32l.c: Re-generate.
1666 * features/rs6000/powerpc-isa207-vsx64l.c: Re-generate.
1667 * regformats/rs6000/powerpc-isa207-vsx32l.dat: Re-generate.
1668 * regformats/rs6000/powerpc-isa207-vsx64l.dat: Re-generate.
1669 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
1670 fetch_regset with ebb and pmu regsets.
1671 (store_register, store_ppc_registers): Call store_regset with ebb
1672 and pmu regsets.
1673 (ppc_linux_nat_target::read_description): Set isa207 field in the
1674 features struct if ebb and pmu are avaiable.
1675 * ppc-linux-tdep.c (ppc32_regmap_ebb, ppc32_regmap_pmu)
1676 (ppc32_linux_ebbregset, ppc32_linux_pmuregset): New globals.
1677 (ppc_linux_iterate_over_regset_sections): Call back with the ebb
1678 and pmu regsets.
1679 (ppc_linux_core_read_description): Check if the pmu section is
1680 present and set isa207 in the features struct.
1681 * ppc-linux-tdep.h (ppc32_linux_ebbregset)
1682 (ppc32_linux_pmuregset): Declare.
1683 * ppc-tdep.h (struct gdbarch_tdep) <ppc_mmcr0_regnum>: New field.
1684 <ppc_mmcr2_regnum, ppc_siar_regnum, ppc_sdar_regnum>: New fields.
1685 <ppc_sier_regnum>: New field.
1686 (enum): <PPC_BESCR_REGNUM, PPC_EBBHR_REGNUM, PPC_EBBRR_REGNUM>:
1687 New enum values.
1688 <PPC_MMCR0_REGNUM, PPC_MMCR2_REGNUM, PPC_SIAR_REGNUM>: New enum
1689 values.
1690 <PPC_SDAR_REGNUM, PPC_SIER_REGNUM>: New enum values.
1691 (PPC_IS_EBB_REGNUM, PPC_IS_PMU_REGNUM): Define.
1692 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate the
1693 ebb and pmu features.
1694
1695 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1696 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1697
1698 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa207_vsx32l)
1699 (tdesc_powerpc_isa207_vsx64l): Declare.
1700 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_TARREGSET): Define.
1701 (struct ppc_linux_features) <isa207>: New field.
1702 (ppc_linux_no_features): Add initializer for isa207 field.
1703 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
1704 new tdescs.
1705 * nat/ppc-linux.h (PPC_FEATURE2_ARCH_2_07, PPC_FEATURE2_TAR)
1706 (NT_PPC_TAR): Define if not already defined.
1707 * features/Makefile (WHICH): Add rs6000/powerpc-isa207-vsx32l and
1708 rs6000/powerpc-isa207-vsx64l.
1709 (XMLTOC): Add rs6000/powerpc-isa207-vsx32l.xml and
1710 rs6000/powerpc-isa207-vsx64l.xml.
1711 * features/rs6000/power-tar.xml: New file.
1712 * features/rs6000/powerpc-isa207-vsx32l.xml: New file.
1713 * features/rs6000/powerpc-isa207-vsx64l.xml: New file.
1714 * features/rs6000/powerpc-isa207-vsx32l.c: Generate.
1715 * features/rs6000/powerpc-isa207-vsx64l.c: Generate.
1716 * regformats/rs6000/powerpc-isa207-vsx32l.dat: Generate.
1717 * regformats/rs6000/powerpc-isa207-vsx64l.dat: Generate.
1718 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
1719 fetch_regset with the TAR regset.
1720 (store_register, store_ppc_registers): Call store_regset with the
1721 TAR regset.
1722 (ppc_linux_nat_target::read_description): Set isa207 field in the
1723 features struct if needed.
1724 * ppc-linux-tdep.c: Include
1725 features/rs6000/powerpc-isa207-vsx32l.c and
1726 features/rs6000/powerpc-isa207-vsx64l.c.
1727 (ppc32_regmap_tar, ppc32_linux_tarregset): New globals.
1728 (ppc_linux_iterate_over_regset_sections): Call back with the tar
1729 regset.
1730 (ppc_linux_core_read_description): Check if the tar section is
1731 present and set isa207 in the features struct.
1732 (_initialize_ppc_linux_tdep): Call
1733 initialize_tdesc_powerpc_isa207_vsx32l and
1734 initialize_tdesc_powerpc_isa207_vsx64l.
1735 * ppc-linux-tdep.h (ppc32_linux_tarregset): Declare.
1736 * ppc-tdep.h (gdbarch_tdep) <ppc_tar_regnum>: New field.
1737 (enum) <PPC_TAR_REGNUM>: New enum value.
1738 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate tar
1739 feature.
1740 (ppc_process_record_op31): Record changes to TAR.
1741
1742 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1743 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1744
1745 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa205_ppr_dscr_vsx32l)
1746 (tdesc_powerpc_isa205_ppr_dscr_vsx64l): Declare.
1747 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_PPRREGSET)
1748 (PPC_LINUX_SIZEOF_DSCRREGSET): Define.
1749 (struct ppc_linux_features) <ppr_dscr>: New field.
1750 (ppc_linux_no_features): Add initializer for ppr_dscr field.
1751 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
1752 new tdescs.
1753 * nat/ppc-linux.h (PPC_FEATURE2_DSCR, NT_PPC_PPR, NT_PPC_DSCR):
1754 Define if not already defined.
1755 * features/Makefile (WHICH): Add
1756 rs6000/powerpc-isa205-ppr-dscr-vsx32l and
1757 rs6000/powerpc-isa205-ppr-dscr-vsx64l.
1758 (XMLTOC): Add rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
1759 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml.
1760 * features/rs6000/power-dscr.xml: New file.
1761 * features/rs6000/power-ppr.xml: New file.
1762 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml: New file.
1763 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml: New file.
1764 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c: Generate.
1765 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c: Generate.
1766 * regformats/rs6000/powerpc-isa205-ppr-dscr-vsx32l.dat: Generate.
1767 * regformats/rs6000/powerpc-isa205-ppr-dscr-vsx64l.dat: Generate.
1768 * ppc-linux-nat.c: Include <sys/uio.h>.
1769 (fetch_regset, store_regset, check_regset): New functions.
1770 (fetch_register, fetch_ppc_registers): Call fetch_regset with
1771 DSCR and PPR regsets.
1772 (store_register, store_ppc_registers): Call store_regset with
1773 DSCR and PPR regsets.
1774 (ppc_linux_get_hwcap2): New function.
1775 (ppc_linux_nat_target::read_description): Call
1776 ppc_linux_get_hwcap2 and check_regset, set ppr_dscr field in the
1777 features struct if needed.
1778 * ppc-linux-tdep.c: Include
1779 features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c and
1780 features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c.
1781 (ppc32_regmap_ppr, ppc32_regmap_dscr, ppc32_linux_pprregset)
1782 (ppc32_linux_dscrregset): New globals.
1783 (ppc_linux_iterate_over_regset_sections): Call back with the ppr
1784 and dscr regsets.
1785 (ppc_linux_core_read_description): Check if the ppr and dscr
1786 sections are present and set ppr_dscr in the features struct.
1787 (_initialize_ppc_linux_tdep): Call
1788 initialize_tdesc_powerpc_isa205_ppr_dscr_vsx32l and
1789 initialize_tdesc_powerpc_isa205_ppr_dscr_vsx64l.
1790 * ppc-linux-tdep.h (ppc32_linux_pprregset)
1791 (ppc32_linux_dscrregset): Declare.
1792 * ppc-tdep.h (struct gdbarch_tdep) <ppc_ppr_regnum>: New field.
1793 <ppc_dscr_regnum>: New field.
1794 (enum) <PPC_PPR_REGNUM, PPC_DSCR_REGNUM>: New enum values.
1795 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate ppr
1796 and dscr features.
1797 (ppc_process_record_op31): Record changes to PPR and DSCR.
1798
1799 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1800
1801 * rs6000-tdep.c (rs6000_gdbarch_init): Replace line wrapping by a
1802 second initializer line for the have_* variables. Initialize
1803 have_fpu to 0 instead of 1.
1804
1805 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1806
1807 * arch/ppc-linux-common.c (ppc_linux_match_description):
1808 Parenthesize tdesc assignements and indent them properly.
1809
1810 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1811
1812 * ppc-linux-nat.c (fetch_register): Change if statement to else
1813 if.
1814 (store_register): Likewise.
1815
1816 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1817
1818 * rs6000-tdep.c: Remove reggroups.h include.
1819 (rs6000_pseudo_register_reggroup_p): Remove.
1820 (rs6000_gdbarch_init): Remove call to
1821 set_tdesc_pseudo_register_reggroup_p.
1822
1823 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1824
1825 * reggroups.c (default_register_reggroup_p): Return true for
1826 decfloat registers and float_reggroup.
1827
1828 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1829
1830 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): Remove.
1831 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): Replace
1832 ppc_linux_collect_vrregset by regcache_collect_regset.
1833
1834 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1835
1836 * linux-tdep.c (linux_collect_regset_section_cb): Use
1837 std::vector<gdb_byte> instead of char * and malloc for buf.
1838 Remove xfree.
1839
1840 2018-10-26 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
1841
1842 * xcoffread.c (read_xcoff_symtab): Pass deduced language to
1843 symtab_start instead of always using language_unknown.
1844
1845 2018-10-26 Andrew Burgess <andrew.burgess@embecosm.com>
1846
1847 * riscv-tdep.c (riscv_read_misa_reg): Update comment, remove
1848 READ_P parameter, catch and ignore register access errors from
1849 either the old or new MISA location.
1850 (riscv_has_feature): Update call to riscv_read_misa_reg.
1851
1852 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
1853
1854 * python/py-function.c (convert_values_to_python): Return
1855 gdbpy_ref<>. Add header comment.
1856 (fnpy_call): Adjust.
1857
1858 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
1859
1860 * python/py-cmd.c (cmdpy_completer_helper): Return gdbpy_ref<>.
1861 (cmdpy_completer_handle_brkchars): Adjust.
1862 (cmdpy_completer): Adjust.
1863
1864 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
1865
1866 * riscv-linux-nat.c (riscv_linux_nat_target::fetch_registers):
1867 Pass correct regnum to raw_supply_zeroed.
1868
1869 2018-10-23 Hafiz Abid Qadeer <abidh@codesourcery.com>
1870
1871 * regcache.c (cooked_read_test): Add CSKY to the list of
1872 architectures with a save_reggroup
1873
1874 2018-10-23 Simon Marchi <simon.marchi@polymtl.ca>
1875
1876 PR gdb/23368
1877 * infrun.c (follow_exec): In the follow_exec_mode_new case,
1878 transfer terminal state from old new new inferior.
1879 * terminal.h (swap_terminal_info): New function.
1880 * inflow.c (swap_terminal_info): New function.
1881
1882 2018-10-23 Tom Tromey <tom@tromey.com>
1883
1884 * record-btrace.c (get_thread_current_frame_id): Rename from
1885 get_thread_current_frame. Return a frame_id.
1886 (record_btrace_start_replaying): Update.
1887
1888 2018-10-23 Andrew Burgess <andrew.burgess@embecosm.com>
1889
1890 * riscv-tdep.c (riscv_register_name): Use the user-friendly names
1891 for CSRs.
1892
1893 2018-10-23 Joel Brobecker <brobecker@adacore.com>
1894
1895 * riscv-tdep.c (riscv_gdbarch_init): Set the gdbarch's
1896 have_nonsteppable_watchpoint attribute to 1.
1897
1898 2018-10-23 Andrew Burgess <andrew.burgess@embecosm.com>
1899
1900 * riscv-tdep.c (riscv_gdb_reg_names): Update comment, and all
1901 register names.
1902 (struct register_alias): Rename to...
1903 (struct riscv_register_alias): ...this, and update comment.
1904 (riscv_register_aliases): Update type, and alias names. Remove
1905 CSR names from this list.
1906 (riscv_register_name): Use riscv_gdb_reg_names for int and float
1907 register names. Add an extra assertion.
1908 (riscv_is_regnum_a_named_csr): New function.
1909 (riscv_register_reggroup_p): Use riscv_is_regnum_a_named_csr.
1910
1911 2018-10-23 John Darrington <john@darrington.wattle.id.au>
1912
1913 * configure.tgt: Add configuration for s12z.
1914 * s12z-tdep.c: New file.
1915 * NEWS: Mention new target.
1916
1917 2018-10-22 Jim Wilson <jimw@sifive.com>
1918
1919 * riscv-tdep.c (riscv_push_dummy_call) <in_reg>: Check for value in
1920 FP reg smaller than FP reg size, and fill with -1 instead of 0.
1921
1922 * riscv-tdep.c (riscv_fpreg_d_type, riscv_fpreg_q_type): New.
1923 (riscv_register_type): Use them.
1924 (riscv_print_one_register_info): Handle union of floats same as float.
1925 * riscv-tdep.h (struct gdbarch_tdep): Add riscv_fpreg_d_type and
1926 riscv_fpreg_q_type fields.
1927
1928 2018-10-21 Simon Marchi <simon.marchi@ericsson.com>
1929
1930 * gdbarch.sh (gdbarch_num_cooked_regs): New.
1931 * gdbarch.h: Re-generate.
1932 * ax-gdb.c (gen_expr): Use gdbarch_num_cooked_regs.
1933 * dwarf2-frame.c (dwarf2_frame_cache): Likewise.
1934 * eval.c (evaluate_subexp_standard): Likewise.
1935 * findvar.c (value_of_register): Likewise.
1936 (value_of_register_lazy): Likewise.
1937 (address_from_register): Likewise.
1938 * frame.c (get_frame_register_bytes): Likewise.
1939 * gdbarch-selftests.c (register_to_value_test): Likewise.
1940 * h8300-tdep.c (h8300_register_type): Likewise.
1941 * i386-tdep.c (i386_dbx_reg_to_regnum): Likewise.
1942 (i386_svr4_reg_to_regnum): Likewise.
1943 * infcmd.c (default_print_registers_info): Likewise.
1944 (registers_info): Likewise.
1945 (print_vector_info): Likewise.
1946 (default_print_float_info): Likewise.
1947 * m68hc11-tdep.c (m68hc11_frame_unwind_cache): Likewise.
1948 * mdebugread.c (mdebug_reg_to_regnum): Likewise.
1949 * mi/mi-main.c (mi_cmd_data_list_register_names): Likewise.
1950 (mi_cmd_data_list_changed_registers): Likewise.
1951 (mi_cmd_data_list_register_values): Likewise.
1952 (mi_cmd_data_write_register_values): Likewise.
1953 (mi_cmd_trace_frame_collected): Likewise.
1954 * mips-tdep.c (print_gp_register_row): Likewise.
1955 (mips_print_registers_info): Likewise.
1956 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
1957 * regcache.c (init_regcache_descr): Likewise.
1958 (register_size): Likewise.
1959 (register_dump::dump): Likewise.
1960 (cooked_read_test): Likewise.
1961 (cooked_write_test): Likewise.
1962 * rs6000-tdep.c (rs6000_register_sim_regno): Likewise.
1963 (rs6000_gdbarch_init): Likewise.
1964 * stabsread.c (stab_reg_to_regnum): Likewise.
1965 * stack.c (info_frame_command): Likewise.
1966 * target-descriptions.c (tdesc_register_name): Likewise.
1967 * trad-frame.c (trad_frame_alloc_saved_regs): Likewise.
1968 * tui/tui-regs.c (tui_show_register_group): Likewise.
1969 * user-regs.c (user_reg_map_name_to_regnum): Likewise.
1970 (user_reg_map_regnum_to_name): Likewise.
1971 (value_of_user_reg): Likewise.
1972 (maintenance_print_user_registers): Likewise.
1973 * xtensa-tdep.c (xtensa_find_register_by_name): Likewise.
1974 (xtensa_register_name): Likewise.
1975 (xtensa_register_type): Likewise.
1976 (xtensa_reg_to_regnum): Likewise.
1977 (xtensa_pseudo_register_read): Likewise.
1978 (xtensa_pseudo_register_write): Likewise.
1979
1980 2018-10-21 Simon Marchi <simon.marchi@polymtl.ca>
1981
1982 * amd64-tdep.c (amd64_pseudo_register_read_value): Use
1983 correctly-sized buffer with raw_read.
1984 (amd64_pseudo_register_write): Use correctly-sized buffer for
1985 raw_read/raw_write.
1986
1987 2018-10-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1988
1989 * typeprint.c (_initialize_typeprint): Fix wrong prefixname arg
1990 in add_prefix_cmd of set print type.
1991
1992 2018-10-19 Tom Tromey <tom@tromey.com>
1993
1994 PR tui/18388:
1995 * NEWS: Mention tabset deprecation.
1996 * tui/tui-win.c (tui_tab_width, internal_tab_width): New globals.
1997 (update_tab_width): New function.
1998 (tui_set_tab_width, tui_show_tab_width): New functions.
1999 (tui_set_tab_width_command): Use update_tab_width.
2000 (_initialize_tui_win): Move to end of file. Deprecate "tabset".
2001 Add new "set tui tab-width" command.
2002 * tui/tui-source.c (tui_set_source_content): Update.
2003 * tui/tui-disasm.c (tui_set_disassem_content): Update.
2004 * tui/tui-data.h (tui_default_tab_len, tui_set_default_tab_len):
2005 Don't declare.
2006 (tui_tab_width): Declare.
2007 * tui/tui-data.c (default_tab_len, tui_default_tab_len)
2008 (tui_set_default_tab_len): Remove.
2009
2010 2018-10-19 Tom Tromey <tom@tromey.com>
2011
2012 * tui/tui-io.h (key_is_start_sequence, key_is_end_sequence)
2013 (key_is_backspace, tui_getc): Don't declare.
2014 * tui/tui-io.c (key_is_start_sequence): Now static.
2015 (key_is_end_sequence, key_is_backspace): Remove.
2016 (tui_getc): Now static.
2017
2018 2018-10-19 Tom Tromey <tom@tromey.com>
2019
2020 * symfile.c (reread_symbols): Clear "static_links".
2021
2022 2018-10-19 Alan Hayward <alan.hayward@arm.com>
2023
2024 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_SIZE): New
2025 define.
2026 (aarch64_linux_sigframe_init): Extra boundary checks.
2027
2028 2018-10-19 Andreas Arnez <arnez@linux.ibm.com>
2029
2030 * s390-tdep.c (s390_pseudo_register_type): For v0-v15 don't yield
2031 the possibly non-existent tdesc type 'vec128', but the type of raw
2032 register v16 instead.
2033
2034 2018-10-19 Gary Benson <gbenson@redhat.com>
2035
2036 * cli/cli-interp.c (cli_interp::~cli_interp): New function.
2037
2038 2018-10-18 Sergio Durigan Junior <sergiodj@redhat.com>
2039
2040 PR cli/23785
2041 * cli/cli-dump.c (restore_binary_file): Check if "file" is
2042 NULL.
2043
2044 2018-10-17 Paul Koning <paul_koning@dell.com>
2045
2046 * charset.c (convert_between_encodings): Fix unsigned overflow.
2047
2048 2018-10-17 John Baldwin <jhb@FreeBSD.org>
2049
2050 * fbsd-nat.c (fbsd_nat_target::info_proc) Use
2051 fbsd_info_proc_mappings_header and fbsd_info_proc_mappings_entry.
2052 * fbsd-tdep.c (fbsd_vm_map_entry_flags): Mark static.
2053 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
2054 New functions.
2055 (fbsd_core_info_proc_mappings): Use fbsd_info_proc_mappings_header
2056 and fbsd_info_proc_mappings_header.
2057 * fbsd-tdep.h (fbsd_vm_map_entry_flags): Remove.
2058 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
2059 New.
2060
2061 2018-10-17 Joel Brobecker <brobecker@adacore.com>
2062
2063 * MAINTAINERS (Responsible Maintainers): Add Rainer Orth as
2064 Solaris Maintainer.
2065
2066 2018-10-15 Tom Tromey <tom@tromey.com>
2067
2068 * tui/tui.c (strcat_to_buf): Remove casts.
2069 * tui/tui-winsource.c (tui_show_source_line)
2070 (tui_set_is_exec_point_at, tui_line_is_displayed): Remove casts.
2071 * tui/tui-wingeneral.c (tui_refresh_win, box_win): Remove casts.
2072 * tui/tui-windata.c (tui_first_data_item_displayed)
2073 (tui_delete_data_content_windows, tui_erase_data_content)
2074 (tui_display_all_data, tui_display_data_from)
2075 (tui_refresh_data_win, tui_vertical_data_scroll): Remove casts.
2076 * tui/tui-win.c (tui_set_win_height)
2077 (make_invisible_and_set_new_height, parse_scrolling_args): Remove
2078 casts.
2079 * tui/tui-win.c (tui_resize_all): Remove casts.
2080 (tui_scroll_backward_command, tui_set_focus)
2081 (tui_set_tab_width_command): Likewise.
2082 * tui/tui-source.c (tui_vertical_source_scroll): Remove cast.
2083 * tui/tui-regs.c (tui_show_register_group): Remove cast.
2084 * tui/tui-layout.c (tui_set_layout_by_name): Remove cast.
2085 * tui/tui-disasm.c (tui_vertical_disassem_scroll): Remove cast.
2086 * tui/tui-data.c (tui_partial_win_by_name, tui_free_win_content):
2087 Remove casts.
2088
2089 2018-10-15 Simon Marchi <simon.marchi@ericsson.com>
2090
2091 * MAINTAINERS (Responsible Maintainers): Add Alan Hayward as
2092 AArch64/ARM maintainer.
2093
2094 2018-10-11 Gary Benson <gbenson@redhat.com>
2095
2096 * interps.h (interp::m_name): Make private and mutable.
2097 * interps.c (interp::~interp): Free m_name.
2098
2099 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
2100 Simon Marchi <simark@simark.ca>
2101
2102 * README (`configure' options): Add documentation for new
2103 "--enable-unit-tests" option.
2104 * acinclude.m4: Include "selftest.m4".
2105 * configure: Regenerate.
2106 * configure.ac: Use "GDB_AC_SELFTEST".
2107 * maint.c (maintenance_selftest): Update message informing
2108 that selftests have been disabled.
2109 (maintenance_info_selftests): Likewise.
2110 * selftest.m4: New file.
2111
2112 2018-10-10 Gary Benson <gbenson@redhat.com>
2113
2114 * remote.c (remote_target::remote_send_printf): Add
2115 missing va_end found by Coverity.
2116
2117 2018-10-10 Markus Metzger <markus.t.metzger@intel.com>
2118
2119 * btrace.c (ftrace_update_function): Add indirect jump heuristic.
2120
2121 2018-10-09 Tom Tromey <tom@tromey.com>
2122
2123 * configure: Rebuild.
2124 * sanitize.m4 (AM_GDB_UBSAN): Default to no.
2125 * NEWS: Update --enable-ubsan documentation.
2126
2127 2018-10-09 Gary Benson <gbenson@redhat.com>
2128
2129 * dwarf2read.c (create_dwp_hash_table): Fix buffer overrun
2130 found by Coverity.
2131
2132 2018-10-08 Tom Tromey <tom@tromey.com>
2133
2134 * riscv-fbsd-tdep.c (riscv_fbsd_sigframe_init): Remove unused
2135 variable.
2136 (riscv_fbsd_init_abi): Likewise.
2137
2138 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
2139 * valops.c (value_struct_elt_for_reference): Rename local variable
2140 to work around the shadowing a previous local warning.
2141
2142 2018-10-08 John Baldwin <jhb@FreeBSD.org>
2143
2144 * Makefile.in (ALLDEPFILES): Add riscv-fbsd-nat.c.
2145 * NEWS: Mention new FreeBSD/riscv native configuration.
2146 * configure.host: Add riscv*-*-freebsd*.
2147 * configure.nat: Likewise.
2148 * riscv-fbsd-nat.c: New file.
2149
2150 2018-10-08 John Baldwin <jhb@FreeBSD.org>
2151
2152 * Makefile.in (ALL_TARGET_OBS): Add riscv-fbsd-tdep.o.
2153 (HFILES_NO_SRCDIR): Add riscv-fbsd-tdep.h.
2154 (ALLDEPFILES): Add riscv-fbsd-tdep.c.
2155 * NEWS: Mention new FreeBSD/riscv target.
2156 * configure.tgt: Add riscv*-*-freebsd*.
2157 * riscv-fbsd-tdep.c: New file.
2158 * riscv-fbsd-tdep.h: New file.
2159
2160 2018-10-08 John Baldwin <jhb@FreeBSD.org>
2161
2162 * regcache.h (struct regcache_map_entry): Note that this type can
2163 be used with traditional frame caches.
2164 * trad-frame.c (trad_frame_set_reg_regmap): New.
2165 * trad-frame.h (trad_frame_set_reg_regmap): New.
2166
2167 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
2168
2169 PR c++/16841
2170 * valops.c (get_virtual_base_offset): New function.
2171 (value_struct_elt_for_reference): Use it to get virtual base offset
2172 and add it in calculating class member address.
2173
2174 2018-10-08 John Darrington <john@darrington.wattle.id.au>
2175
2176 * dwarf2read.c (dwarf2_cu) <producer_is_codewarrior>: New field.
2177 (check_producer): Check if the producer is codewarrior.
2178 (producer_is_codewarrior): New function.
2179 (lnp_state_machine::record_line): Ignore is_stmt flag for records
2180 produced by codewarrior.
2181 (dwarf2_cu::dwarf2_cu): Initialize producer_is_codewarrior.
2182
2183 2018-10-06 Tom Tromey <tom@tromey.com>
2184
2185 PR python/19399:
2186 * python/py-inferior.c: Add "architecture" entry.
2187 (infpy_architecture): New function.
2188
2189 2018-10-06 Tom Tromey <tom@tromey.com>
2190
2191 PR python/21765:
2192 * python/py-symbol.c (gdbpy_initialize_symbols): Redefine
2193 SYMBOL_VARIABLES_DOMAIN, SYMBOL_FUNCTIONS_DOMAIN,
2194 SYMBOL_TYPES_DOMAIN. Define SYMBOL_MODULE_DOMAIN,
2195 SYMBOL_COMMON_BLOCK_DOMAIN, SYMBOL_LOC_COMMON_BLOCK.
2196
2197 2018-10-06 Tom Tromey <tom@tromey.com>
2198
2199 PR build/17077:
2200 * Makefile.in (OPCODES_CFLAGS): Remove "-I$(OPCODES_SRC)/..".
2201 * arc-tdep.c, frv-tdep.c, lm32-tdep.c, mep-tdep.c,
2202 microblaze-tdep.c, or1k-tdep.h: Use ../opcodes, not opcodes, in
2203 #include.
2204
2205 2018-10-06 Tom Tromey <tom@tromey.com>
2206
2207 * python/py-breakpoint.c (bppy_get_location): Handle a
2208 bp_breakpoint without a location.
2209
2210 2018-10-06 Tom Tromey <tom@tromey.com>
2211
2212 * python/lib/gdb/function/strfns.py (_MemEq, _StrLen, _StrEq)
2213 (_RegEx): Reformat help text.
2214 * python/lib/gdb/function/caller_is.py (CallerIs, CallerMatches)
2215 (AnyCallerIs, AnyCallerMatches): Reformat help text.
2216 * python/lib/gdb/function/as_string.py (_AsString): Reformat help
2217 text.
2218 * python/lib/gdb/command/xmethods.py (InfoXMethod)
2219 (EnableXMethod, DisableXMethod): Remove help indentation.
2220 Capitalize meta-syntactic variables.
2221 * python/lib/gdb/command/unwinders.py (InfoUnwinder)
2222 (EnableUnwinder, DisableUnwinder): Remove help indentation.
2223 Capitalize meta-syntactic variables.
2224 * python/lib/gdb/command/explore.py (ExploreCommand)
2225 (ExploreValueCommand, ExploreTypeCommand): Reformat help text.
2226 * python/lib/gdb/command/type_printers.py (InfoTypePrinter)
2227 (EnableTypePrinter, DisableTypePrinter): Remove help indentation.
2228 * python/lib/gdb/command/pretty_printers.py (InfoPrettyPrinter):
2229 Remove help indentation.
2230 (EnablePrettyPrinter, DisablePrettyPrinter): Likewise.
2231 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter)
2232 (DisableFrameFilter, SetFrameFilterPriority)
2233 (ShowFrameFilterPriority, InfoFrameFilter): Reword help text.
2234
2235 2018-10-06 Tom Tromey <tom@tromey.com>
2236
2237 PR tui/28819:
2238 * tui/tui-io.c (gdb_wgetch): New function.
2239 (tui_mld_getc, tui_getc): Use it.
2240
2241 2018-10-05 Tom Tromey <tom@tromey.com>
2242
2243 * sol-thread.c (sol_thread_target::wait): Rename inner
2244 "save_ptid".
2245
2246 2018-10-04 Tom Tromey <tom@tromey.com>
2247
2248 * configure: Rebuild.
2249 * warning.m4 (AM_GDB_WARNINGS): Add -Wshadow=local.
2250
2251 2018-10-04 Tom Tromey <tom@tromey.com>
2252
2253 * guile/scm-frame.c (gdbscm_frame_read_var): Remove inner
2254 declaration of "block".
2255
2256 2018-10-04 Tom Tromey <tom@tromey.com>
2257
2258 * common/filestuff.c (fdwalk): Remove inner declaration of
2259 "result".
2260
2261 2018-10-04 Tom Tromey <tom@tromey.com>
2262
2263 * msp430-tdep.c (msp430_push_dummy_call): Rename inner
2264 "structs_addr" and hoist declaration.
2265
2266 2018-10-04 Tom Tromey <tom@tromey.com>
2267
2268 * linux-tdep.c (linux_make_mappings_corefile_notes): Introduce new
2269 variable "size".
2270
2271 2018-10-04 Tom Tromey <tom@tromey.com>
2272
2273 * mdebugread.c (parse_partial_symbols): Use std::string.
2274
2275 2018-10-04 Tom Tromey <tom@tromey.com>
2276
2277 * ctf.c (SET_ARRAY_FIELD): Rename "u32".
2278 * p-valprint.c (pascal_val_print): Split inner "i" variable.
2279 * xtensa-tdep.c (xtensa_push_dummy_call): Declare "i" in loop
2280 header.
2281 * xstormy16-tdep.c (xstormy16_push_dummy_call): Declare "val" in
2282 more inner scope.
2283 * xcoffread.c (read_xcoff_symtab): Rename inner "symbol".
2284 * varobj.c (varobj_update): Rename inner "newobj",
2285 "type_changed".
2286 * valprint.c (generic_emit_char): Rename inner "buf".
2287 * valops.c (find_overload_match): Rename inner "temp".
2288 (value_struct_elt_for_reference): Declare "v" in more inner
2289 scope.
2290 * v850-tdep.c (v850_push_dummy_call): Rename "len".
2291 * unittests/array-view-selftests.c (run_tests): Rename inner
2292 "vec".
2293 * tui/tui-stack.c (tui_show_frame_info): Declare "i" in loop
2294 header.
2295 * tracepoint.c (merge_uploaded_trace_state_variables): Declare
2296 "tsv" in more inner scope.
2297 (print_one_static_tracepoint_marker): Rename inner
2298 "tuple_emitter".
2299 * tic6x-tdep.c (tic6x_analyze_prologue): Declare "inst" lower.
2300 (tic6x_push_dummy_call): Don't redeclare "addr".
2301 * target-float.c: Declare "dto" lower.
2302 * symtab.c (lookup_local_symbol): Rename inner "sym".
2303 (find_pc_sect_line): Rename inner "pc".
2304 * stack.c (print_frame): Don't redeclare "gdbarch".
2305 (return_command): Rename inner "gdbarch".
2306 * s390-tdep.c (s390_prologue_frame_unwind_cache): Renam inner
2307 "sp".
2308 * rust-lang.c (rust_internal_print_type): Declare "i" in loop
2309 header.
2310 * rs6000-tdep.c (ppc_process_record): Rename inner "addr".
2311 * riscv-tdep.c (riscv_push_dummy_call): Declare "info" in inner
2312 scope.
2313 * remote.c (remote_target::update_thread_list): Don't redeclare
2314 "tp".
2315 (remote_target::process_initial_stop_replies): Rename inner
2316 "thread".
2317 (remote_target::remote_parse_stop_reply): Don't redeclare "p".
2318 (remote_target::wait_as): Don't redeclare "stop_reply".
2319 (remote_target::get_thread_local_address): Rename inner
2320 "result".
2321 (remote_target::get_tib_address): Likewise.
2322
2323 * regcache.c (cooked_read_test): Rename "regnum".
2324 * record-btrace.c (cmd_record_btrace_start): Rename inner
2325 "exception".
2326 * ppc-sysv-tdep.c (ppc64_sysv_abi_return_value): Declare "i" in
2327 loop header.
2328 * ppc-linux-tdep.c (ppc_linux_syscall_record): Declare "i" in loop
2329 header.
2330 (ppu2spu_sniffer): Rename inner "buf".
2331 * parse.c (operator_check_standard): Rename inner "type",
2332 "objfile".
2333 * p-valprint.c (pascal_val_print): Introduce new scope for
2334 "low_bound", "high_bound".
2335 * p-exp.y (yylex): Declare "i" in loop header.
2336 * objfiles.c (objfile_relocate1): Declare "i" in loop header.
2337 Lower declaration of "s".
2338 * nios2-tdep.c (nios2_analyze_prologue): Declare "i" in loop
2339 header.
2340 (nios2_push_dummy_call): Rename "len".
2341 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Rename static
2342 "buf".
2343 (linux_xfer_osdata_fds, linux_xfer_osdata_shm)
2344 (linux_xfer_osdata_sem, linux_xfer_osdata_msg)
2345 (linux_xfer_osdata_modules): Likewise.
2346 * mips-tdep.c (mips_eabi_push_dummy_call): Rename outer "len".
2347 (mips_n32n64_push_dummy_call, mips_o32_push_dummy_call)
2348 (mips_o64_push_dummy_call): Likewise.
2349 * microblaze-tdep.c (microblaze_analyze_prologue): Rename inner
2350 "op".
2351 * mi/mi-main.c (list_available_thread_groups): Rename inner
2352 "tuple_emitter".
2353 (mi_cmd_data_read_memory): Rename inner "opts".
2354 * mi/mi-cmd-var.c (varobj_update_one): Rename inner
2355 "tuple_emitter".
2356 * mep-tdep.c (mep_analyze_prologue): Declare "rn" in loop header.
2357 * mdebugread.c (parse_symbol): Rename inner "b". Declare "f" in
2358 more inner scope.
2359 (parse_partial_symbols): Rename inner "pst", "p", "name"
2360 * main.c (captured_main_1): Rename inner "i"s.
2361 * machoread.c (macho_symfile_read_all_oso): Don't redeclare
2362 "oso2".
2363 * linux-tdep.c (linux_info_proc): Rename inner "filename".
2364 * linespec.c (linespec_lexer_lex_string): Rename inner "p".
2365 * infrun.c (handle_no_resumed): Don't redeclare "thread".
2366 (handle_signal_stop): Rename inner "gdbarch".
2367 (handle_command): Declare "signum" in loop header.
2368 * ia64-tdep.c (ia64_pseudo_register_read): Don't redeclare
2369 "status".
2370 (examine_prologue): Rename inner "sol" and "sof".
2371 (ia64_extract_return_value): Rename inner "val". Declare another
2372 "val" in a more inner scope.
2373 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Declare "buf" in
2374 inner scope.
2375 * guile/scm-symbol.c (gdbscm_lookup_symbol): Rename inner
2376 "except".
2377 * findvar.c (default_read_var_value): Don't redeclare "addr".
2378 * f-exp.y (yylex): Declare "i" in loop header.
2379 * eval.c (evaluate_subexp_standard): Don't redeclare "type".
2380 Rename inner "type", "expect_type".
2381 (evaluate_subexp_for_sizeof): Rename inner "pc".
2382 * elfread.c (elf_symfile_read): Rename inner "abfd".
2383 * dwarf2read.c (read_debug_names_from_section): Don't redeclare
2384 "bytes_read".
2385 (process_psymtab_comp_unit_reader): Don't redeclare "gdbarch".
2386 (add_partial_subprogram): Rename inner "lowpc" and "highpc".
2387 (dwarf_decode_line_header): Rename inner "lh".
2388 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Don't redeclare
2389 "offset". Declare "i" in loop header.
2390 (disassemble_dwarf_expression): Rename inner "addr_size".
2391 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Rename
2392 inner "result".
2393 (dwarf_expr_context::execute_stack_op): Rename inner "offset".
2394 * dwarf2-frame.c (decode_frame_entry_1): Rename inner "length"s.
2395 * disasm.c (do_mixed_source_and_assembly_deprecated): Rename inner
2396 "inner_list_emitter".
2397 (do_mixed_source_and_assembly): Rename inner "tuple_emitter".
2398 * disasm-selftests.c (print_one_insn_test): Wrap "bplen"
2399 declaration in a block.
2400 * csky-tdep.c (csky_analyze_prologue): Declare "offset" lower.
2401 * cp-valprint.c (cp_print_value_fields): Don't redeclare
2402 "obstack_final_size".
2403 * cp-support.c (inspect_type): Declare "i" in loop header.
2404 * compile/compile.c (compile_instance::insert_symbol_error):
2405 Rename inner "e".
2406 * common/agent.c (agent_run_command): Remove inner "ret"
2407 declaration.
2408 * coffread.c (coff_symfile_read): Rename inner "name".
2409 (coff_symfile_read): Rename inner "abfd".
2410 * cli/cli-utils.c (get_number_trailer): Rename inner "val".
2411 * cli/cli-cmds.c (print_disassembly): Rename inner "low" and
2412 "high".
2413 * c-exp.y (lex_one_token): Move "len" declaration lower.
2414 * breakpoint.c (create_longjmp_master_breakpoint): Don't redeclare
2415 "gdbarch".
2416 (create_exception_master_breakpoint): Likewise. Don't redeclare
2417 "b".
2418 (watch_command_1): Declare "mark" later.
2419 (clear_command): Don't shadow "a" or "b".
2420 (delete_command): Rename inner "b".
2421 (delete_trace_command): Likewise.
2422 * arm-tdep.c (thumb_process_displaced_32bit_insn): Rename inner
2423 "op".
2424 (arm_gdbarch_init): Remove inner "e_flags".
2425 * arch/arm-get-next-pcs.c (thumb_get_next_pcs_raw): Declare
2426 "offset" in inner blocks.
2427
2428 2018-10-04 Simon Marchi <simon.marchi@ericsson.com>
2429
2430 * dwarf-index-write.c (file_write): Don't write if the vector is
2431 empty.
2432
2433 2018-10-05 Tom de Vries <tdevries@suse.de>
2434
2435 * python/py-progspace.c (pspy_solib_name): Fix type mismatch in
2436 PyArg_ParseTuple call.
2437
2438 2018-10-05 Tom de Vries <tdevries@suse.de>
2439
2440 * python/py-record-btrace.c (recpy_bt_goto): Fix type mismatch in
2441 PyArg_ParseTuple call.
2442
2443 2018-10-04 Joel Brobecker <brobecker@adacore.com>
2444
2445 * psymtab.c (recursively_search_psymtabs): Reformat parameters
2446 to avoid exceeding 80 characters per line limit.
2447
2448 2018-10-04 Tom Tromey <tom@tromey.com>
2449
2450 * symfile.c (syms_from_objfile_1, finish_new_objfile)
2451 (reread_symbols): Update.
2452 * complaints.h (clear_complaints): Remove argument.
2453 * complaints.c (enum complaint_series): Remove.
2454 (series): Remove global.
2455 (complaint_internal): Update.
2456 (clear_complaints): Remove argument.
2457
2458 2018-10-04 Tom Tromey <tom@tromey.com>
2459
2460 * symfile.c (symbol_file_add_with_addrs): Do not print "no
2461 debugging symbols" message if there is a separate debug objfile.
2462
2463 2018-10-04 Tom Tromey <tom@tromey.com>
2464
2465 PR cli/19551:
2466 * symfile.c (symbol_file_add_with_addrs): Update output.
2467 * psymtab.c (require_partial_symbols): Update output.
2468
2469 2018-10-04 Tom Tromey <tom@tromey.com>
2470
2471 PR cli/22234:
2472 * complaints.c: Emit \n.
2473
2474 2018-10-04 Tom Tromey <tom@tromey.com>
2475
2476 * symfile.c (symbol_file_add_with_addrs, symbol_file_clear)
2477 (separate_debug_file_exists, find_separate_debug_file)
2478 (add_symbol_file_command, reread_symbols, allocate_symtab)
2479 (allocate_compunit_symtab): Use filtered printing, not
2480 unfiltered.
2481 * psymtab.c (require_partial_symbols, dump_psymtab)
2482 (allocate_psymtab): Use filtered printing, not unfiltered.
2483
2484 2018-10-04 Tom Tromey <tom@tromey.com>
2485
2486 * complaints.c (complaint_internal): Correctly check complaint
2487 count.
2488
2489 2018-10-04 Tom Tromey <tom@tromey.com>
2490
2491 * complaints.h (struct complaints): Remove declaration.
2492 * complaints.c (clear_complaints): Remove an unused variable.
2493
2494 2018-10-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2495
2496 * MAINTAINERS (Write After Approval): Add self.
2497
2498 2018-10-03 Tom Tromey <tom@tromey.com>
2499
2500 * guile/scm-value.c (gdbscm_value_to_string): Initialize
2501 "buffer_contents".
2502 * coffread.c (coff_symtab_read): Initialize "newobj".
2503
2504 2018-10-03 Simon Marchi <simon.marchi@polymtl.ca>
2505
2506 * dwarf2read.c (read_func_scope): Remove struct keyword in
2507 range-based for.
2508
2509 2018-10-03 Tom Tromey <tom@tromey.com>
2510
2511 * README: Mention --enable-ubsan.
2512 * NEWS: Mention --enable-ubsan.
2513 * acinclude.m4: Include sanitize.m4.
2514 * configure: Rebuild.
2515 * configure.ac: Call AM_GDB_UBSAN.
2516 * sanitize.m4: New file.
2517
2518 2018-10-03 Tom Tromey <tom@tromey.com>
2519
2520 * expression.h (enum exp_opcode): Use uint8_t as base type.
2521 * expprint.c (op_name): Handle invalid opcodes.
2522
2523 2018-10-03 Tom Tromey <tom@tromey.com>
2524
2525 * parse.c (prefixify_expression): Add assert.
2526 (parse_exp_in_context_1): Throw exception if the expression is
2527 empty.
2528
2529 2018-10-03 Tom Tromey <tom@tromey.com>
2530
2531 * dwarf2read.c (read_signed_leb128): Work in ULONGEST.
2532
2533 2018-10-03 Tom Tromey <tom@tromey.com>
2534
2535 * c-exp.y (parse_number): Work in unsigned. Remove casts.
2536
2537 2018-10-03 Tom Tromey <tom@tromey.com>
2538
2539 * dwarf2read.c (read_subrange_type): Make "negative_mask"
2540 unsigned.
2541
2542 2018-10-03 Tom Tromey <tom@tromey.com>
2543
2544 * findvar.c (extract_integer): Do work in an unsigned type.
2545
2546 2018-10-03 Tom Tromey <tom@tromey.com>
2547
2548 * common/enum-flags.h (enum_flags::operator~): Add static assert.
2549 * symfile-add-flags.h (enum symfile_add_flag): Use unsigned as
2550 base type.
2551 * objfile-flags.h (enum objfile_flag): Use unsigned as base type.
2552 * gdbtypes.h (enum type_instance_flag_value): Use unsigned as base
2553 type.
2554 * c-lang.h (enum c_string_type_values): Use unsigned as base
2555 type.
2556 * btrace.h (enum btrace_thread_flag): Use unsigned as base type.
2557
2558 2018-10-03 Tom Tromey <tom@tromey.com>
2559
2560 * dwarf2-frame.h (dwarf2_frame_state_reg_info)
2561 <~dwarf2_frame_state_reg_info>: Update.
2562 <dwarf2_frame_state_reg_info>: Update.
2563 <alloc_regs>: Add assertion. Update.
2564 <reg>: Now a std::vector.
2565 <num_regs>: Remove.
2566 <swap>: Update.
2567 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
2568 (execute_cfa_program_test, dwarf2_frame_cache): Update.
2569
2570 2018-10-03 Tom Tromey <tom@tromey.com>
2571
2572 * namespace.c (add_using_directive): Don't pass NULL to memcpy.
2573
2574 2018-10-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2575
2576 * tid-parse.c (tid_is_in_list): Fix wrong 'See' comment.
2577
2578 2018-10-02 Tom Tromey <tom@tromey.com>
2579
2580 * aarch64-linux-tdep.c (aarch64_linux_sigframe_init): Use pulongest.
2581
2582 2018-10-02 John Darrington <john@darrington.wattle.id.au>
2583
2584 * NEWS: Mention changed commands.
2585 * ser-uds.c: New file.
2586 * configure.ac (SER_HARDWIRE): Add ser-uds.o.
2587 * configure: Regenerate.
2588 * Makefile.in: Add new file.
2589 * serial.c (serial_open): Check if filename is a socket
2590 and lookup the appropriate interface accordingly.
2591
2592 2018-10-01 Alan Hayward <alan.hayward@arm.com>
2593
2594 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_OFFSET): Add
2595 define.
2596 (AARCH64_EXTRA_MAGIC): Likewise.
2597 (AARCH64_FPSIMD_MAGIC): Likewise.
2598 (AARCH64_SVE_MAGIC): Likewise.
2599 (AARCH64_EXTRA_DATAP_OFFSET): Likewise.
2600 (AARCH64_FPSIMD_FPSR_OFFSET): Likewise.
2601 (AARCH64_FPSIMD_FPCR_OFFSET): Likewise.
2602 (AARCH64_FPSIMD_V0_OFFSET): Likewise.
2603 (AARCH64_FPSIMD_VREG_SIZE): Likewise.
2604 (AARCH64_SVE_CONTEXT_VL_OFFSET): Likewise.
2605 (AARCH64_SVE_CONTEXT_REGS_OFFSET): Likewise.
2606 (AARCH64_SVE_CONTEXT_P_REGS_OFFSET): Likewise.
2607 (AARCH64_SVE_CONTEXT_FFR_OFFSET): Likewise.
2608 (AARCH64_SVE_CONTEXT_SIZE): Likewise.
2609 (read_aarch64_ctx): Add function.
2610 (aarch64_linux_sigframe_init): Detect FP registers.
2611
2612 2018-10-01 Alan Hayward <alan.hayward@arm.com>
2613
2614 * aarch64-tdep.c (AARCH64_Q0_REGNUM): Move to here.
2615 (AARCH64_D0_REGNUM): Likewise.
2616 (AARCH64_S0_REGNUM): Likewise.
2617 (AARCH64_H0_REGNUM): Likewise.
2618 (AARCH64_B0_REGNUM): Likewise.
2619 (AARCH64_SVE_V0_REGNUM): Likewise.
2620 * arch/aarch64.h (AARCH64_Q0_REGNUM): Move from here.
2621 (AARCH64_D0_REGNUM): Likewise.
2622 (AARCH64_S0_REGNUM): Likewise.
2623 (AARCH64_H0_REGNUM): Likewise.
2624 (AARCH64_B0_REGNUM): Likewise.
2625 (AARCH64_SVE_V0_REGNUM): Likewise.
2626
2627 2018-10-01 Gary Benson <gbenson@redhat.com>
2628
2629 * gdb_proc_service.h (gdb_prfpregset_t): Remove typedef.
2630 * proc-service.c (ps_lgetfpregs, ps_lsetfpregs): Use
2631 prfpregset_t instead of gdb_prfpregset_t.
2632 * configure.ac (PRFPREGSET_T_BROKEN): Remove check.
2633 * configure, config.in: Rebuild.
2634
2635 2018-10-01 Gary Benson <gbenson@redhat.com>
2636
2637 * common/gdb_proc_service.h: New file, factored out from...
2638 * gdb_proc_service.h: Moved common code to the above file.
2639 * Makefile.in (HFILES_NO_SRCDIR): Add the above new file.
2640
2641 2018-10-01 Gary Benson <gbenson@redhat.com>
2642
2643 * gdb_proc_service.h: Use elf_gregset_t if prgregset_t is
2644 undefined. Use elf_fpregset_t if prfpregset_t is undefined.
2645
2646 2018-10-01 Gary Benson <gbenson@redhat.com>
2647
2648 * configure.ac: Check if sys/procfs.h defines elf_fpregset_t.
2649 (AC_CHECK_HEADERS): Check for linux/elf.h.
2650 * configure, config.in: Rebuild.
2651 * gdb_proc_service.h: Include linux/elf.h if sys/procfs.h
2652 doesn't define elf_fpregset_t.
2653
2654 2018-10-01 Gary Benson <gbenson@redhat.com>
2655
2656 * gdb_proc_service.h: Whitespace change.
2657
2658 2018-10-01 Tom Tromey <tom@tromey.com>
2659
2660 * unittests/scoped_mmap-selftests.c: Don't check HAVE_UNISTD_H.
2661 * unittests/scoped_fd-selftests.c: Don't check HAVE_UNISTD_H.
2662 * common/scoped_fd.h: Don't check HAVE_UNISTD_H.
2663
2664 2018-10-01 Tom Tromey <tom@tromey.com>
2665
2666 * README: Minor change.
2667
2668 2018-09-30 Pedro Alves <palves@redhat.com>
2669
2670 * darwin-nat-info.c (darwin_debug_regions_recurse)
2671 (info_mach_exceptions_command): Remove unused local variables.
2672 * darwin-nat.c (darwin_decode_notify_message)
2673 (darwin_nat_target::resume, darwin_nat_target::mourn_inferior)
2674 (darwin_stop_inferior, darwin_setup_exceptions)
2675 (darwin_nat_target::kill, darwin_attach_pid, darwin_ptrace_him)
2676 (darwin_nat_target::attach, darwin_nat_target::detach)
2677 (darwin_read_write_inferior, darwin_read_dyld_info): Remove unused
2678 local variables.
2679 * i386-darwin-nat.c (i386_darwin_dr_set): Remove unused local
2680 variables.
2681
2682 2018-09-29 Tom Tromey <tom@tromey.com>
2683
2684 * README: Remove some leftover text.
2685
2686 2018-09-29 Tom Tromey <tom@tromey.com>
2687
2688 * PROBLEMS: Rewrite.
2689 * README: Update.
2690
2691 2018-09-28 John Baldwin <jhb@FreeBSD.org>
2692
2693 * disasm-selftests.c (print_one_insn_test): Add bfd_arch_riscv to
2694 case with explicit breakpoint kind.
2695 * riscv-tdep.c (show_use_compressed_breakpoints): Remove
2696 'additional_info' and related logic.
2697 (riscv_debug_breakpoints): New variable.
2698 (riscv_breakpoint_kind_from_pc): Use the length of the existing
2699 instruction to determine the breakpoint kind.
2700 (_initialize_riscv_tdep): Add 'set/show debug riscv breakpoints'
2701 flag. Update description of 'set/show riscv
2702 use-compressed-breakpoints' flag.
2703
2704 2018-09-28 Andrew Burgess <andrew.burgess@embecosm.com>
2705
2706 (NEWS): Mention changes to frame related commands.
2707 * cli/cli-decode.c (add_cmd_suppress_notification): New function.
2708 (add_prefix_cmd_suppress_notification): New function.
2709 (add_com_suppress_notification): Call
2710 add_cmd_suppress_notification.
2711 * command.h (add_cmd_suppress_notification): Declare.
2712 (add_prefix_cmd_suppress_notification): Declare.
2713 * mi/mi-cmd-stack.c: Add 'safe-ctype.h' include.
2714 (parse_frame_specification): Moved from stack.c, with
2715 simplification to handle a single argument.
2716 (mi_cmd_stack_select_frame): Use parse_frame_specification, the
2717 switch to the selected frame. Add a header comment.
2718 * stack.c: Remove 'safe-ctype.h' include.
2719 (find_frame_for_function): Add declaration.
2720 (find_frame_for_address): New function.
2721 (parse_frame_specification): Moved into mi/mi-cmd-stack.c.
2722 (frame_selection_by_function_completer): New function.
2723 (info_frame_command): Rename to...
2724 (info_frame_command_core): ...this, and update parameter types.
2725 (select_frame_command): Rename to...
2726 (select_frame_command_core): ...this, and update parameter types.
2727 (frame_command): Rename to...
2728 (frame_command_core): ...this, and update parameter types.
2729 (class frame_command_helper): New class to wrap implementations of
2730 frame related sub-commands.
2731 (frame_apply_cmd_list): New static global.
2732 (frame_cmd_list): Make static.
2733 (select_frame_cmd_list): New global for sub-commands.
2734 (info_frame_cmd_list): New global for sub-commands.
2735 (_initialize_stack): Register sub-commands for 'frame',
2736 'select-frame', and 'info frame'. Update 'frame apply' commands
2737 to use frame_apply_cmd_list. Move function local static
2738 frame_apply_list to file static frame_apply_cmd_list for
2739 consistency.
2740 * stack.h (select_frame_command): Delete declarationn.
2741 (select_frame_for_mi): Declare new function.
2742
2743 2018-09-26 Andrew Burgess <andrew.burgess@embecosm.com>
2744
2745 * riscv-tdep.c (riscv_insn::decode): Decode c.lui.
2746 (riscv_scan_prologue): Split handling of AUIPC, LUI, ADD, ADDI,
2747 and NOP.
2748
2749 2018-09-26 Simon Marchi <simon.marchi@ericsson.com>
2750
2751 * elf32-nds32.c (elf32_nds32_allocate_dynrelocs): Remove.
2752
2753 2018-09-26 Tom Tromey <tom@tromey.com>
2754
2755 * valops.c (auto_abandon): Remove dead code.
2756
2757 2018-09-26 Tom Tromey <tom@tromey.com>
2758
2759 * tui/tui-win.c (WIN_HEIGHT_USAGE): Remove extra ">"s.
2760
2761 2018-09-24 Tom Tromey <tom@tromey.com>
2762
2763 * common/pathstuff.c (get_standard_cache_dir): Make
2764 "xdg_cache_home" and "home" const.
2765 * top.c (init_history): Make "tmpenv" const.
2766 * main.c (get_init_files): Make "homedir" const.
2767
2768 2018-09-23 Tom Tromey <tom@tromey.com>
2769
2770 PR python/18852:
2771 * python/py-param.c (get_set_value): Use gdbpy_handle_exception.
2772
2773 2018-09-23 Tom Tromey <tom@tromey.com>
2774
2775 * python/py-function.c (fnpy_call): Use gdbpy_handle_exception.
2776 * python/py-cmd.c (cmdpy_function): Use gdbpy_handle_exception.
2777 * python/python-internal.h (gdbpy_handle_exception): Declare.
2778 * python/py-utils.c (gdbpy_handle_exception): New function.
2779
2780 2018-09-23 Tom Tromey <tom@tromey.com>
2781
2782 PR python/17284:
2783 * python/py-type.c (typy_template_argument): Check for negative
2784 argument number.
2785
2786 2018-09-23 Tom Tromey <tom@tromey.com>
2787
2788 PR python/14062:
2789 * python/python.c (gdbpy_run_events): Do not ignore exceptions.
2790
2791 2018-09-23 Tom Tromey <tom@tromey.com>
2792
2793 PR python/18170:
2794 * python/py-value.c (valpy_int): Allow conversion from pointer
2795 type.
2796
2797 2018-09-23 Tom Tromey <tom@tromey.com>
2798
2799 PR python/20126:
2800 * python/py-value.c (valpy_int): Respect type sign.
2801
2802 2018-09-23 Tom Tromey <tom@tromey.com>
2803
2804 PR python/18352;
2805 * python/py-value.c (valpy_float): Allow conversions from int or
2806 char.
2807 (valpy_int, valpy_long): Allow conversions from float.
2808
2809 2018-09-23 Tom Tromey <tom@tromey.com>
2810
2811 * ctf.c (ctf_start): Use gdb_fopen_cloexec.
2812 * common/scoped_mmap.c (mmap_file): Use gdb_open_cloexec.
2813
2814 2018-09-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2815
2816 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Also recognize
2817 __sighndlr.
2818 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Likewise.
2819
2820 2018-08-02 Jon Turney <jon.turney@dronecode.org.uk>
2821
2822 * windows-nat.c (windows_nat_target::wait): Remove a spurious
2823 target_terminal::ours().
2824
2825 2018-09-23 Simon Marchi <simon.marchi@ericsson.com>
2826
2827 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): Change type
2828 of vl to ULONGEST.
2829
2830 2018-09-21 Yacov Simhony <ysimhony@gmail.com>
2831
2832 * breakpoint.c (update_inserted_breakpoint_locations): Remove
2833 redundant condition.
2834
2835 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2836
2837 * proc-utils.h (PROC_CTL_WORD_TYPE): Remove.
2838
2839 * procfs.c: Don't check for PR_MODEL_NATIVE definition.
2840 * sparc-sol2-nat.c: Likewise. Remove Linux, __arch64__ references.
2841 * sol-thread.c (ps_pdmodel): Don't guard definition.
2842
2843 * procfs.c: Fix formatting.
2844
2845 * procfs.c (sysset_t_alloc): Remove.
2846 (create_procinfo): Use XNEW instead of sysset_t_alloc.
2847 (procfs_debug_inferior): Likewise.
2848 (procfs_set_exec_trap): Likewise.
2849 (proc_set_traced_sysentry): Don't allocate argp dynamically.
2850 (proc_set_traced_sysexit): Likewise.
2851
2852 * procfs.c (create_procinfo): Use xsnprintf to fix ARI warning.
2853 (dead_procinfo): Likewise.
2854 (proc_warn): Likewise.
2855 (proc_error): Likewise.
2856 (proc_get_LDT_entry): Likewise.
2857 (do_attach): Likewise.
2858 (procfs_target::pid_to_str): Likewise.
2859 (iterate_over_mappings): Likewise.
2860
2861 * procfs.c (create_procinfo): Fix ARI warning.
2862 (proc_get_status): Likewise.
2863 (proc_stop_process): Likewise.
2864 (proc_run_process): Likewise.
2865 (proc_kill): Likewise.
2866 (proc_get_LDT_entry): Likewise.
2867 (procfs_find_LDT_entry): Likewise.
2868 (proc_update_threads): Likewise.
2869 (proc_iterate_over_threads): Likewise.
2870 (do_attach): Likewise.
2871 (procfs_xfer_memory): Likewise.
2872 (invalidate_cache): Likewise.
2873 (procfs_target::resume): Likewise.
2874 (procfs_init_inferior): Likewise.
2875 (procfs_set_exec_trap): Likewise.
2876 (procfs_target::thread_alive): Likewise.
2877 (procfs_target::pid_to_exec_file): Likewise.
2878 (iterate_over_mappings): Likewise.
2879 (procfs_target::make_corefile_notes): Likewise.
2880 * sol-thread.c (sol_thread_target::thread_alive): Likewise.
2881
2882 * procfs.c (procfs_find_LDT_entry): Silence ARI warning.
2883 (procfs_find_LDT_entry): Likewise.
2884 * sol-thread.c (ps_lgetLDT): Likewise.
2885
2886 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2887
2888 PR tdep/17903
2889 * procfs.c (procfs_target): Declare pid_to_exec_file.
2890 (procfs_target::pid_to_exec_file): New.
2891
2892 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2893
2894 * auxv.c (default_print_auxv_entry): Reflect AT_SUN_CAP_HW1
2895 renaming.
2896 Handle AT_SUN_EMULATOR, AT_SUN_BRANDNAME, AT_SUN_BRAND_AUX1,
2897 AT_SUN_BRAND_AUX2, AT_SUN_BRAND_AUX3, AT_SUN_CAP_HW2.
2898
2899 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2900
2901 * i386-v4-nat.c (regmap, supply_gregset, fill_gregset)
2902 (supply_fpregset, fill_fpregset): Move ...
2903 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64]: ... here.
2904 Remove HAVE_GREGSET_T, HAVE_FPREGET_T guards.
2905 Remove references to ioctl-based procfs.
2906 Include <sys/reg.h>.
2907 Remove PR_MODEL_NATIVE guards.
2908 * configure.nat <sol2, i386> (NATDEPFILES): Remove i386-v4-nat.o.
2909 * Makefile.in (ALLDEPFILES): Remove i386-v4-nat.c.
2910
2911 2018-09-19 Xavier Roirand <roirand@adacore.com>
2912
2913 PR gdb/20981:
2914 * solib-darwin.c (darwin_get_dyld_bfd): New function.
2915 (darwin_solib_get_all_image_info_addr_at_init): Update call.
2916 (darwin_solib_create_inferior_hook): Handle unrelocated dyld.
2917
2918 2018-09-19 John Baldwin <jhb@FreeBSD.org>
2919
2920 * fbsd-tdep.c (fbsd_print_sockaddr_in): Style fix.
2921 (fbsd_print_sockaddr_in6): Likewise.
2922
2923 2018-09-19 Richard Bunt <richard.bunt@arm.com>
2924 Chris January <chris.january@arm.com>
2925
2926 * eval.c (skip_undetermined_arglist): Skip argument list helper.
2927 (evaluate_subexp_standard): Return a dummy type when
2928 honoring EVAL_SKIP in OP_VAR_VALUE and handle skipping in the
2929 OP_F77_UNDETERMINED_ARGLIST case.
2930 * expression.h (enum noside): Update comment.
2931
2932 2018-09-19 George Vasick <george.vasick@oracle.com>
2933
2934 * solib-svr4.c (svr4_same_1): Also handle amd64 ld.so.1.
2935
2936 2018-09-19 Stefan Teleman <stefan.teleman@oracle.com>
2937 April Chin <april.chin@oracle.com>
2938 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2939
2940 * procfs.c (MAX_PROC_NAME_SIZE): Allow for 6-digit PID_MAX and
2941 uint_t lwpid_t.
2942 (create_procinfo): Print pids in /proc without leading zeros.
2943
2944 2018-09-18 Sandra Loosemore <sandra@codesourcery.com>
2945
2946 * nios2-tdep.c (nios2_gcc_target_options): New.
2947 (nios2_gdb_arch_init): Install new hook.
2948
2949 2018-09-18 Simon Marchi <simon.marchi@ericsson.com>
2950
2951 * patches/0001-Fix-PR-gdb-23558-Use-system-s-getcwd-when-cross-comp.patch:
2952 New file.
2953 * update-gnulib.sh: Apply patch.
2954 * configure: Re-generate.
2955
2956 2018-09-18 John Baldwin <jhb@FreeBSD.org>
2957
2958 * infcmd.c (_initialize_infcmd): Remove "running" from "info proc"
2959 description. Make "info proc" command descriptions more
2960 consistent.
2961
2962 2018-09-18 John Baldwin <jhb@FreeBSD.org>
2963
2964 * NEWS: Mention 'info proc files' command.
2965
2966 2018-09-18 John Baldwin <jhb@FreeBSD.org>
2967
2968 * fbsd-nat.c (fbsd_nat_target::info_proc): List open file
2969 descriptors for IP_FILES and IP_ALL.
2970
2971 2018-09-18 John Baldwin <jhb@FreeBSD.org>
2972
2973 * fbsd-tdep.c (KF_FLAGS, KF_OFFSET, KF_VNODE_TYPE, KF_SOCK_DOMAIN)
2974 (KF_SOCK_TYPE, KF_SOCK_PROTOCOL, KF_SA_LOCAL, KF_SA_PEER)
2975 (KINFO_FILE_TYPE_SOCKET, KINFO_FILE_TYPE_PIPE)
2976 (KINFO_FILE_TYPE_FIFO, KINFO_FILE_TYPE_KQUEUE)
2977 (KINFO_FILE_TYPE_CRYPTO, KINFO_FILE_TYPE_MQUEUE)
2978 (KINFO_FILE_TYPE_SHM, KINFO_FILE_TYPE_SEM, KINFO_FILE_TYPE_PTS)
2979 (KINFO_FILE_TYPE_PROCDESC, KINFO_FILE_FD_TYPE_ROOT)
2980 (KINFO_FILE_FD_TYPE_JAIL, KINFO_FILE_FD_TYPE_TRACE)
2981 (KINFO_FILE_FD_TYPE_CTTY, KINFO_FILE_FLAG_READ)
2982 (KINFO_FILE_FLAG_WRITE, KINFO_FILE_FLAG_APPEND)
2983 (KINFO_FILE_FLAG_ASYNC, KINFO_FILE_FLAG_FSYNC)
2984 (KINFO_FILE_FLAG_NONBLOCK, KINFO_FILE_FLAG_DIRECT)
2985 (KINFO_FILE_FLAG_HASLOCK, KINFO_FILE_FLAG_EXEC)
2986 (KINFO_FILE_VTYPE_VREG, KINFO_FILE_VTYPE_VDIR)
2987 (KINFO_FILE_VTYPE_VCHR, KINFO_FILE_VTYPE_VLNK)
2988 (KINFO_FILE_VTYPE_VSOCK, KINFO_FILE_VTYPE_VFIFO, FBSD_AF_UNIX)
2989 (FBSD_AF_INET, FBSD_AF_INET6, FBSD_SOCK_STREAM, FBSD_SOCK_DGRAM)
2990 (FBSD_SOCK_SEQPACKET, FBSD_IPPROTO_ICMP, FBSD_IPPROTO_TCP)
2991 (FBSD_IPPROTO_UDP, FBSD_IPPROTO_SCTP): New defines.
2992 (struct fbsd_sockaddr_in, struct fbsd_sockaddr_in6)
2993 (struct fbsd_sockaddr_un): New types.
2994 (fbsd_file_fd, fbsd_file_type, fbsd_file_flags, fbsd_ipproto)
2995 (fbsd_print_sockaddr_in, fbsd_print_sockaddr_in6)
2996 (fbsd_info_proc_files_header, fbsd_info_proc_files_entry)
2997 (fbsd_core_info_proc_files): New functions.
2998 (fbsd_core_info_proc): List open file descriptors for IP_FILES and
2999 IP_ALL.
3000 * fbsd-tdep.h (fbsd_info_proc_files_header)
3001 (fbsd_info_proc_files_entry): New.
3002
3003 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3004
3005 * defs.h (enum info_proc_what) [IP_FILES]: New value.
3006 * infcmd.c (info_proc_cmd_files): New function.
3007 (_initialize_infcmd): Register 'info proc files' command.
3008
3009 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3010
3011 * gnulib/aclocal-m4-deps.mk: Re-generate.
3012 * gnulib/aclocal.m4: Re-generate.
3013 * gnulib/config.in: Re-generate.
3014 * gnulib/configure: Re-generate.
3015 * gnulib/import/Makefile.am: Re-generate.
3016 * gnulib/import/Makefile.in: Re-generate.
3017 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
3018 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
3019 * gnulib/import/arpa_inet.in.h: New file.
3020 * gnulib/import/inet_ntop.c: New file.
3021 * gnulib/import/m4/arpa_inet_h.m4: New file.
3022 * gnulib/import/m4/inet_ntop.m4: New file.
3023 * gnulib/import/m4/netinet_in_h.m4: New file.
3024 * gnulib/import/m4/socklen.m4: New file.
3025 * gnulib/import/m4/sockpfaf.m4: New file.
3026 * gnulib/import/m4/stdalign.m4: New file.
3027 * gnulib/import/m4/sys_uio_h.m4: New file.
3028 * gnulib/import/netinet_in.in.h: New file.
3029 * gnulib/import/stdalign.in.h: New file.
3030 * gnulib/import/sys_socket.c: New file.
3031 * gnulib/import/sys_socket.in.h: New file.
3032 * gnulib/import/sys_uio.in.h: New file.
3033 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add inet_ntop
3034 module.
3035
3036 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3037
3038 * gnulib/aclocal-m4-deps.mk: New file.
3039 * gnulib/update-gnulib.sh: Generate "aclocal-m4-deps.mk"
3040 deterministically.
3041
3042 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3043
3044 * fbsd-tdep.c (fbsd_core_vnode_path): Use KF_PATH instead of
3045 KVE_PATH.
3046
3047 2018-09-18 Tom Tromey <tom@tromey.com>
3048
3049 * compile/compile-object-load.c (struct
3050 link_hash_table_cleanup_data): Add constructor and destructor.
3051 Use DISABLE_COPY_AND_ASSIGN.
3052 (~link_hash_table_cleanup_data): Rename from
3053 link_hash_table_free. Now a destructor.
3054 (copy_sections): Use gdb::unique_xmalloc_ptr. Remove cleanups.
3055
3056 2018-09-18 Tom Tromey <tom@tromey.com>
3057
3058 * compile/compile-object-run.c (do_module_cleanup): Use delete.
3059 * compile/compile-object-load.c (struct munmap_list): Move to
3060 header file.
3061 (munmap_list::add): Rename from munmap_list_add; rewrite.
3062 (munmap_list::~munmap_list): Rename from munmap_list_free.
3063 (munmap_listp_free_cleanup): Remove.
3064 (compile_object_load): Update.
3065 * compile/compile-object-load.h (struct munmap_list): Move from
3066 compile-object-load.c. Rewrite.
3067
3068 2018-09-18 Alan Hayward <alan.hayward@arm.com>
3069
3070 * aarch64-tdep.c (pass_in_v): Use register size.
3071 (aarch64_extract_return_value): Likewise.
3072 (aarch64_store_return_value): Likewise.
3073
3074 2018-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3075
3076 * utils.c (dump_core) [HAVE_SETRLIMIT]: Cast RLIM_INFINITY to
3077 rlim_t.
3078
3079 2018-09-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3080
3081 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter):
3082 Fix short help line.
3083
3084 2018-09-17 Tom Tromey <tom@tromey.com>
3085
3086 PR python/20445:
3087 * configure: Rebuild.
3088 * configure.ac: Conditionally use -DNDEBUG for Python.
3089
3090 2018-09-17 Tom Tromey <tom@tromey.com>
3091
3092 * configure: Rebuild.
3093 * configure.ac: Use gmp as a library dependency when checking for
3094 mpfr.
3095
3096 2018-09-17 Pedro Alves <palves@redhat.com>
3097
3098 * python/py-inferior.c (find_inferior_object): Delete.
3099
3100 2018-09-17 Simon Marchi <simon.marchi@ericsson.com>
3101
3102 * compile/compile-cplus-types.c
3103 (compile_cplus_instance::enter_scope): Don't use new_scope after
3104 std::move.
3105
3106 2018-09-17 Tom Tromey <tom@tromey.com>
3107
3108 * common/pathstuff.c (get_standard_cache_dir): Use
3109 ~/Library/Caches on macOS.
3110 * common/pathstuff.h (get_standard_cache_dir): Update comment.
3111
3112 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
3113
3114 PR python/23669
3115 * breakpoint.c (commands_cmd_element): New.
3116 (_initialize_breakpoint): Assign commands_cmd_element.
3117 * breakpoint.h (commands_cmd_element): New.
3118 * cli/cli-script.c (while_cmd_element, if_command,
3119 define_cmd_element): New.
3120 (command_name_equals): Remove.
3121 (process_next_line): Compare commands by pointer, not by name.
3122 (_initialize_cli_script): Assign the various cmd_list_element
3123 variables.
3124 * compile/compile.c (compile_cmd_element): New.
3125 (_initialize_compile): Assign compile_cmd_element.
3126 * compile/compile.h (compile_cmd_element): New.
3127 * guile/guile.c (guile_cmd_element): New.
3128 (install_gdb_commands): Assign guile_cmd_element.
3129 * guile/guile.h (guile_cmd_element): New.
3130 * python/python.c (python_cmd_element): New.
3131 (_initialize_python): Assign python_cmd_element.
3132 * python/python.h (python_cmd_element): New.
3133 * tracepoint.c (while_stepping_cmd_element): New.
3134 (_initialize_tracepoint): Assign while_stepping_cmd_element.
3135 * tracepoint.h (while_stepping_cmd_element): New.
3136
3137 2018-09-17 Tom Tromey <tom@tromey.com>
3138
3139 * infrun.c (save_infcall_suspend_state): Return
3140 infcall_suspend_state_up.
3141 (save_infcall_control_state): Return infcall_control_state_up.
3142 * inferior.h (save_infcall_suspend_state)
3143 (save_infcall_control_state): Declare later. Return unique
3144 pointers.
3145
3146 2018-09-17 Tom Tromey <tom@tromey.com>
3147
3148 * infrun.c (struct stop_context): Declare constructor,
3149 destructor, "changed" method.
3150 (stop_context::stop_context): Rename from save_stop_context.
3151 (stop_context::~stop_context): Rename from
3152 release_stop_context_cleanup.
3153 (normal_stop): Update.
3154 (stop_context::changed): Rename from stop_context_changed. Return
3155 bool.
3156
3157 2018-09-17 Tom Tromey <tom@tromey.com>
3158
3159 * inferior.h (struct infcall_suspend_state_deleter): New.
3160 (infcall_suspend_state_up): New typedef.
3161 (struct infcall_control_state_deleter): New.
3162 (infcall_control_state_up): New typedef.
3163 (make_cleanup_restore_infcall_suspend_state)
3164 (make_cleanup_restore_infcall_control_state): Don't declare.
3165 * infcall.c (call_function_by_hand_dummy): Update.
3166 * infrun.c (do_restore_infcall_suspend_state_cleanup)
3167 (make_cleanup_restore_infcall_suspend_state): Remove.
3168 (do_restore_infcall_control_state_cleanup)
3169 (make_cleanup_restore_infcall_control_state): Remove.
3170
3171 2018-09-17 Tom Tromey <tom@tromey.com>
3172
3173 * gdbthread.h (struct thread_control_state): Add initializer.
3174 (class thread_info) <control>: Remove initializer.
3175 * inferior.h (struct inferior_control_state): Add initializer.
3176 (class inferior) <control>: Remove initializer.
3177 (exit_inferior_1): Update.
3178 * infrun.c (struct infcall_control_state): Add constructors.
3179 (save_infcall_control_state): Use new.
3180 (restore_infcall_control_state, discard_infcall_control_state):
3181 Use delete.
3182
3183 2018-09-17 Tom Tromey <tom@tromey.com>
3184
3185 * infrun.c (struct infcall_suspend_state) <registers>: Now a
3186 unique_ptr.
3187 <siginfo_data>: Now a unique_xmalloc_ptr.
3188 (save_infcall_suspend_state, restore_infcall_suspend_state)
3189 (discard_infcall_suspend_state)
3190 (get_infcall_suspend_state_regcache): Update.
3191
3192 2018-09-17 Tom Tromey <tom@tromey.com>
3193
3194 * gdbthread.h (struct thread_suspend_state): Add initializers.
3195 (class thread_info) <suspend>: Remove initializer.
3196 * infrun.c (struct infcall_suspend_state): Add initializers.
3197 (save_infcall_suspend_state): Use new.
3198 (discard_infcall_suspend_state): Use delete.
3199
3200 2018-09-16 Tom Tromey <tom@tromey.com>
3201
3202 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
3203 Remove.
3204 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
3205 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
3206 (py_varobj_iter_new): Likewise.
3207 (py_varobj_get_iterator): Use gdbpy_ref.
3208
3209 2018-09-16 Tom Tromey <tom@tromey.com>
3210
3211 * python/py-threadevent.c (py_get_event_thread): Simplify.
3212 * python/py-inferior.c (infpy_thread_from_thread_handle):
3213 Return immediately after calling thread_to_thread_object. Use
3214 Py_RETURN_NONE.
3215 (thread_to_thread_object): Set the exception on a NULL return.
3216
3217 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
3218
3219 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
3220
3221 2018-09-16 Tom Tromey <tom@tromey.com>
3222
3223 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
3224 Remove.
3225
3226 2018-09-16 Tom Tromey <tom@tromey.com>
3227
3228 * python/python-internal.h (thread_to_thread_object): Change
3229 return type.
3230 * python/py-inferior.c (thread_to_thread_object): Return a new
3231 reference.
3232 (infpy_thread_from_thread_handle): Update.
3233 * python/py-infthread.c (gdbpy_selected_thread): Update.
3234 * python/py-stopevent.c (create_stop_event_object): Update.
3235 * python/py-threadevent.c (py_get_event_thread): Return a new
3236 reference.
3237 (py_get_event_thread): Update.
3238 * python/py-event.h (py_get_event_thread): Change return type.
3239 * python/py-continueevent.c (create_continue_event_object):
3240 Update.
3241
3242 2018-09-16 Tom Tromey <tom@tromey.com>
3243
3244 * python/py-progspace.c (pspy_get_objfiles): Update.
3245 * python/python-internal.h (objfile_to_objfile_object): Change
3246 return type.
3247 * python/py-newobjfileevent.c (create_new_objfile_event_object):
3248 Update.
3249 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
3250 Update.
3251 * python/python.c (gdbpy_get_current_objfile): Update.
3252 (gdbpy_objfiles): Update.
3253 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
3254 Update.
3255 (objfile_to_objfile_object): Return a new reference.
3256 * python/py-symtab.c (stpy_get_objfile): Update.
3257 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
3258 Update.
3259
3260 2018-09-16 Tom Tromey <tom@tromey.com>
3261
3262 * python/py-inferior.c (infpy_get_progspace): Update.
3263 * python/python-internal.h (pspace_to_pspace_object): Change
3264 return type.
3265 * python/py-newobjfileevent.c
3266 (create_clear_objfiles_event_object): Update.
3267 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
3268 Update.
3269 * python/python.c (gdbpy_get_current_progspace): Update.
3270 (gdbpy_progspaces): Update.
3271 * python/py-progspace.c (pspace_to_pspace_object): Return a new
3272 reference.
3273 * python/py-objfile.c (objfpy_get_progspace): Update.
3274 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
3275 Update.
3276
3277 2018-09-16 Tom Tromey <tom@tromey.com>
3278
3279 * python/lib/gdb/__init__.py (current_progspace, objfiles)
3280 (solib_name, block_for_pc, find_pc_line): New functions.
3281 (execute_unwinders): Update.
3282 * python/py-block.c (gdbpy_block_for_pc): Remove.
3283 * python/py-inferior.c (infpy_get_progspace): New function.
3284 (inferior_object_getset) <progspace>: Add.
3285 * python/py-progspace.c (pspy_objfiles): Rewrite.
3286 (pspy_solib_name, pspy_block_for_pc)
3287 (pspy_find_pc_line, pspy_is_valid): New functions.
3288 (progspace_object_methods): Add entries for solib_name,
3289 block_for_pc, find_pc_line, is_valid.
3290 * python/python-internal.h (gdbpy_block_for_pc)
3291 (build_objfiles_list): Don't declare.
3292 * python/python.c: Don't include solib.h.
3293 (gdbpy_solib_name, gdbpy_find_pc_line)
3294 (gdbpy_get_current_progspace, build_objfiles_list)
3295 (gdbpy_objfiles): Remove.
3296 (GdbMethods) <current_progspace, objfiles, block_for_pc,
3297 solib_name, find_pc_line>: Remove entries.
3298
3299 2018-09-16 Tom Tromey <tom@tromey.com>
3300
3301 * top.c (new_ui_command): Use GNU style for metasyntactic
3302 variables.
3303 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
3304 variables.
3305 * maint.c (maintenance_translate_address): Remove "<>" around
3306 text.
3307 * interps.c (interpreter_exec_cmd): Use GNU style for
3308 metasyntactic variables.
3309 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
3310 metasyntactic variables.
3311 * tracepoint.c (tfind_range_command): Use GNU style for
3312 metasyntactic variables.
3313 (tfind_outside_command): Likewise.
3314 (_initialize_tracepoint): Likewise.
3315 * remote.c (extended_remote_target::create_inferior): Use GNU
3316 style for metasyntactic variables.
3317 * sparc64-tdep.c (adi_examine_command): Use GNU style for
3318 metasyntactic variables.
3319 (adi_assign_command): Likewise.
3320
3321 2018-09-16 Tom Tromey <tom@tromey.com>
3322
3323 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
3324 metasyntactic variables. Print message if no disassembler options
3325 are available.
3326
3327 2018-09-15 Tom Tromey <tom@tromey.com>
3328
3329 * infcmd.c (get_inferior_args): Return const char *.
3330 * inferior.h (get_inferior_args): Return type now const.
3331 * linux-tdep.c (linux_fill_prpsinfo): Update.
3332 * procfs.c (procfs_target::make_corefile_notes): Update.
3333
3334 2018-09-07 Tom Tromey <tom@tromey.com>
3335
3336 * python/python.c (execute_gdb_command): Call bpstat_do_actions
3337 inside the TRY.
3338
3339 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
3340
3341 * nios2-tdep.c (nios2_type_align): New.
3342 (nios2_gdb_arch_init): Install type_align hook.
3343
3344 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
3345
3346 * eval.c (fake_method::fake_method): Call xzalloc directly for a
3347 type that is neither object file owned, nor gdbarch owned.
3348 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
3349 gdbarch is non-NULL.
3350 (alloc_type_instance): Allocate non-objfile owned types on the
3351 gdbarch obstack.
3352 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
3353 using TYPE_ALLOC to ensure memory is allocated on the correct
3354 obstack.
3355 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
3356 obstack, or the gdbarch obstack.
3357 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
3358
3359 2018-09-14 Tom Tromey <tom@tromey.com>
3360
3361 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
3362 block.
3363
3364 2018-09-14 Tom Tromey <tom@tromey.com>
3365
3366 * nat/fork-inferior.c (get_startup_shell): Remove "static".
3367
3368 2018-09-13 Tom Tromey <tom@tromey.com>
3369
3370 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
3371 static.
3372
3373 2018-09-13 Tom Tromey <tom@tromey.com>
3374
3375 * exec.c (try_open_exec_file): Use std::string.
3376
3377 2018-09-13 Tom Tromey <tom@tromey.com>
3378
3379 * utils.h (gdb_bfd_errmsg): Return std::string.
3380 * exec.c (exec_file_attach): Update.
3381 * compile/compile-object-load.c (compile_object_load): Update.
3382 * utils.c (gdb_bfd_errmsg): Return std::string.
3383
3384 2018-09-13 Tom Tromey <tom@tromey.com>
3385
3386 * procfs.c (struct procinfo_deleter): New.
3387 (procinfo_up): New typedef.
3388 (do_destroy_procinfo_cleanup): Remove.
3389 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
3390
3391 2018-09-13 Tom Tromey <tom@tromey.com>
3392
3393 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
3394
3395 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3396 2018-09-13 Tom Tromey <tom@tromey.com>
3397
3398 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
3399 (pspy_get_objfiles): New function.
3400 (progspace_object_methods): New.
3401 (pspace_object_type): Add tp_methods callback.
3402 * python/python-internal.h (build_objfiles_list): New
3403 declaration.
3404 * python/python.c (build_objfiles_list): New function.
3405 (gdbpy_objfiles): Implement using build_objfiles_list.
3406 * NEWS: Mention the Progspace.objfiles method.
3407
3408 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3409
3410 * python/py-inferior.c (infpy_get_progspace): New function.
3411 (inferior_object_getset): Add progspace property.
3412 * NEWS: Mention the new property.
3413
3414 2018-09-13 Tom Tromey <tom@tromey.com>
3415
3416 PR rust/23650:
3417 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
3418
3419 2018-09-13 Tom Tromey <tom@tromey.com>
3420
3421 PR rust/23626:
3422 * rust-lang.c (rust_enum_variant): Now static.
3423 (rust_empty_enum_p): New function.
3424 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
3425 Handle empty enum.
3426
3427 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3428
3429 * python/py-inferior.c (infpy_repr): New.
3430 (inferior_object_type): Register infpy_repr.
3431 * python/py-objfile.c (objfpy_repr): New.
3432 (objfile_object_type): Register objfpy_repr.
3433
3434 2018-09-12 John Baldwin <jhb@FreeBSD.org>
3435
3436 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
3437
3438 2018-09-12 John Baldwin <jhb@FreeBSD.org>
3439
3440 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
3441 typo.
3442
3443 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
3444
3445 * common/common-utils.c: Don't include '<sys/stat.h>'.
3446 (is_regular_file): Move to...
3447 * common/filestuff.c (is_regular_file): ... here.
3448 * common/common-utils.h (is_regular_file): Move to...
3449 * common/filestuff.h (is_regular_file): ... here.
3450
3451 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
3452
3453 * skip.c (debug_skip): New variable.
3454 (skiplist_entry::do_skip_file_p): Add debug output.
3455 (skiplist_entry::do_skip_gfile_p): Likewise.
3456 (skiplist_entry::skip_function_p): Likewise.
3457 (_initialize_step_skip): Create debug command.
3458 * NEWS: Mention set/show debug skip.
3459
3460 2018-09-11 Xavier Roirand <roirand@adacore.com>
3461
3462 * darwin-nat.c (should_disable_startup_with_shell):
3463 New function.
3464 (darwin_nat_target::create_inferior): Add call.
3465
3466 2018-09-11 Xavier Roirand <roirand@adacore.com>
3467
3468 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
3469 inf_port, msg_state>: Initialize.
3470 (struct darwin_thread_info) <signaled, single_step>: Change
3471 type and initialize.
3472 (struct darwin_thread_info) <event>: Initialize.
3473
3474 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3475
3476 PR gdb/23555
3477 PR gdb/23558
3478 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
3479 guesses.
3480
3481 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3482
3483 Revert:
3484 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
3485
3486 PR gdb/23555
3487 PR gdb/23558
3488 * gnulib/aclocal.m4: Regenerate.
3489 * gnulib/config.in: Regenerate.
3490 * gnulib/configure: Regenerate.
3491 * gnulib/import/Makefile.am: Update.
3492 * gnulib/import/Makefile.in: Update.
3493 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
3494 * gnulib/import/_Noreturn.h: ... this.
3495 * gnulib/import/alloca.in.h: Update.
3496 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
3497 * gnulib/import/arg-nonnull.h: ... this.
3498 * gnulib/import/assure.h: Update.
3499 * gnulib/import/at-func.c: Update.
3500 * gnulib/import/basename-lgpl.c: Update.
3501 * gnulib/import/extra/snippet/c++defs.h: Rename to...
3502 * gnulib/import/c++defs.h: ... this.
3503 * gnulib/import/canonicalize-lgpl.c: Update.
3504 * gnulib/import/cdefs.h: Update.
3505 * gnulib/import/chdir-long.c: Update.
3506 * gnulib/import/chdir-long.h: Update.
3507 * gnulib/import/cloexec.c: Update.
3508 * gnulib/import/cloexec.h: Update.
3509 * gnulib/import/close.c: Update.
3510 * gnulib/import/closedir.c: Update.
3511 * gnulib/import/config.charset: Update.
3512 * gnulib/import/dirent-private.h: Update.
3513 * gnulib/import/dirent.in.h: Update.
3514 * gnulib/import/dirfd.c: Update.
3515 * gnulib/import/dirname-lgpl.c: Update.
3516 * gnulib/import/dirname.h: Update.
3517 * gnulib/import/dosname.h: Update.
3518 * gnulib/import/dup-safer-flag.c: Update.
3519 * gnulib/import/dup-safer.c: Update.
3520 * gnulib/import/dup.c: Update.
3521 * gnulib/import/dup2.c: Update.
3522 * gnulib/import/errno.in.h: Update.
3523 * gnulib/import/error.c: Update.
3524 * gnulib/import/error.h: Update.
3525 * gnulib/import/exitfail.c: Update.
3526 * gnulib/import/exitfail.h: Update.
3527 * gnulib/import/extra/update-copyright: Update.
3528 * gnulib/import/fchdir.c: Update.
3529 * gnulib/import/fcntl.c: Update.
3530 * gnulib/import/fcntl.in.h: Update.
3531 * gnulib/import/fd-hook.c: Update.
3532 * gnulib/import/fd-hook.h: Update.
3533 * gnulib/import/fd-safer-flag.c: Update.
3534 * gnulib/import/fd-safer.c: Update.
3535 * gnulib/import/fdopendir.c: Update.
3536 * gnulib/import/filename.h: Update.
3537 * gnulib/import/filenamecat-lgpl.c: Update.
3538 * gnulib/import/filenamecat.h: Update.
3539 * gnulib/import/flexmember.h: Update.
3540 * gnulib/import/float+.h: Update.
3541 * gnulib/import/float.c: Update.
3542 * gnulib/import/float.in.h: Update.
3543 * gnulib/import/fnmatch.c: Update.
3544 * gnulib/import/fnmatch.in.h: Update.
3545 * gnulib/import/fnmatch_loop.c: Update.
3546 * gnulib/import/fpucw.h: Update.
3547 * gnulib/import/frexp.c: Update.
3548 * gnulib/import/frexpl.c: Update.
3549 * gnulib/import/fstat.c: Update.
3550 * gnulib/import/fstatat.c: Update.
3551 * gnulib/import/getcwd-lgpl.c: Update.
3552 * gnulib/import/getcwd.c: Update.
3553 * gnulib/import/getdtablesize.c: Update.
3554 * gnulib/import/getlogin_r.c: Update.
3555 * gnulib/import/getprogname.c: Update.
3556 * gnulib/import/getprogname.h: Update.
3557 * gnulib/import/gettext.h: Update.
3558 * gnulib/import/gettimeofday.c: Update.
3559 * gnulib/import/glob-libc.h: Update.
3560 * gnulib/import/glob.c: Update.
3561 * gnulib/import/glob.in.h: Update.
3562 * gnulib/import/glob_internal.h: Update.
3563 * gnulib/import/glob_pattern_p.c: Update.
3564 * gnulib/import/globfree.c: Update.
3565 * gnulib/import/hard-locale.c: Update.
3566 * gnulib/import/hard-locale.h: Update.
3567 * gnulib/import/intprops.h: Update.
3568 * gnulib/import/inttypes.in.h: Update.
3569 * gnulib/import/isnan.c: Update.
3570 * gnulib/import/isnand-nolibm.h: Update.
3571 * gnulib/import/isnand.c: Update.
3572 * gnulib/import/isnanl-nolibm.h: Update.
3573 * gnulib/import/isnanl.c: Update.
3574 * gnulib/import/itold.c: Update.
3575 * gnulib/import/libc-config.h: Update.
3576 * gnulib/import/limits.in.h: Update.
3577 * gnulib/import/localcharset.c: Update.
3578 * gnulib/import/localcharset.h: Update.
3579 * gnulib/import/localtime-buffer.c: Update.
3580 * gnulib/import/localtime-buffer.h: Update.
3581 * gnulib/import/lstat.c: Update.
3582 * gnulib/import/m4/00gnulib.m4: Update.
3583 * gnulib/import/m4/__inline.m4: Update.
3584 * gnulib/import/m4/absolute-header.m4: Update.
3585 * gnulib/import/m4/alloca.m4: Update.
3586 * gnulib/import/m4/builtin-expect.m4: Update.
3587 * gnulib/import/m4/canonicalize.m4: Update.
3588 * gnulib/import/m4/chdir-long.m4: Update.
3589 * gnulib/import/m4/close.m4: Update.
3590 * gnulib/import/m4/closedir.m4: Update.
3591 * gnulib/import/m4/configmake.m4: Update.
3592 * gnulib/import/m4/d-ino.m4: Update.
3593 * gnulib/import/m4/d-type.m4: Update.
3594 * gnulib/import/m4/dirent_h.m4: Update.
3595 * gnulib/import/m4/dirfd.m4: Update.
3596 * gnulib/import/m4/dirname.m4: Update.
3597 * gnulib/import/m4/double-slash-root.m4: Update.
3598 * gnulib/import/m4/dup.m4: Update.
3599 * gnulib/import/m4/dup2.m4: Update.
3600 * gnulib/import/m4/eealloc.m4: Update.
3601 * gnulib/import/m4/environ.m4: Update.
3602 * gnulib/import/m4/errno_h.m4: Update.
3603 * gnulib/import/m4/error.m4: Update.
3604 * gnulib/import/m4/exponentd.m4: Update.
3605 * gnulib/import/m4/exponentl.m4: Update.
3606 * gnulib/import/m4/extensions.m4: Update.
3607 * gnulib/import/m4/extern-inline.m4: Update.
3608 * gnulib/import/m4/fchdir.m4: Update.
3609 * gnulib/import/m4/fcntl-o.m4: Update.
3610 * gnulib/import/m4/fcntl.m4: Update.
3611 * gnulib/import/m4/fcntl_h.m4: Update.
3612 * gnulib/import/m4/fdopendir.m4: Update.
3613 * gnulib/import/m4/filenamecat.m4: Update.
3614 * gnulib/import/m4/flexmember.m4: Update.
3615 * gnulib/import/m4/float_h.m4: Update.
3616 * gnulib/import/m4/fnmatch.m4: Update.
3617 * gnulib/import/m4/fnmatch_h.m4: Update.
3618 * gnulib/import/m4/fpieee.m4: Update.
3619 * gnulib/import/m4/frexp.m4: Update.
3620 * gnulib/import/m4/frexpl.m4: Update.
3621 * gnulib/import/m4/fstat.m4: Update.
3622 * gnulib/import/m4/fstatat.m4: Update.
3623 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
3624 * gnulib/import/m4/getcwd-path-max.m4: Update.
3625 * gnulib/import/m4/getcwd.m4: Update.
3626 * gnulib/import/m4/getdtablesize.m4: Update.
3627 * gnulib/import/m4/getlogin.m4: Update.
3628 * gnulib/import/m4/getlogin_r.m4: Update.
3629 * gnulib/import/m4/getpagesize.m4: Update.
3630 * gnulib/import/m4/getprogname.m4: Update.
3631 * gnulib/import/m4/gettimeofday.m4: Update.
3632 * gnulib/import/m4/glibc21.m4: Update.
3633 * gnulib/import/m4/glob.m4: Update.
3634 * gnulib/import/m4/glob_h.m4: Update.
3635 * gnulib/import/m4/gnulib-cache.m4: Update.
3636 * gnulib/import/m4/gnulib-common.m4: Update.
3637 * gnulib/import/m4/gnulib-comp.m4: Update.
3638 * gnulib/import/m4/gnulib-tool.m4: Update.
3639 * gnulib/import/m4/hard-locale.m4: Update.
3640 * gnulib/import/m4/include_next.m4: Update.
3641 * gnulib/import/m4/inttypes-pri.m4: Update.
3642 * gnulib/import/m4/inttypes.m4: Update.
3643 * gnulib/import/m4/isnand.m4: Update.
3644 * gnulib/import/m4/isnanl.m4: Update.
3645 * gnulib/import/m4/largefile.m4: Update.
3646 * gnulib/import/m4/limits-h.m4: Update.
3647 * gnulib/import/m4/localcharset.m4: Update.
3648 * gnulib/import/m4/locale-fr.m4: Update.
3649 * gnulib/import/m4/locale-ja.m4: Update.
3650 * gnulib/import/m4/locale-zh.m4: Update.
3651 * gnulib/import/m4/localtime-buffer.m4: Update.
3652 * gnulib/import/m4/longlong.m4: Update.
3653 * gnulib/import/m4/lstat.m4: Update.
3654 * gnulib/import/m4/malloc.m4: Update.
3655 * gnulib/import/m4/malloca.m4: Update.
3656 * gnulib/import/m4/math_h.m4: Update.
3657 * gnulib/import/m4/mbrtowc.m4: Update.
3658 * gnulib/import/m4/mbsinit.m4: Update.
3659 * gnulib/import/m4/mbsrtowcs.m4: Update.
3660 * gnulib/import/m4/mbstate_t.m4: Update.
3661 * gnulib/import/m4/memchr.m4: Update.
3662 * gnulib/import/m4/memmem.m4: Update.
3663 * gnulib/import/m4/mempcpy.m4: Update.
3664 * gnulib/import/m4/memrchr.m4: Update.
3665 * gnulib/import/m4/mkdir.m4: Update.
3666 * gnulib/import/m4/mkstemp.m4: Update.
3667 * gnulib/import/m4/mmap-anon.m4: Update.
3668 * gnulib/import/m4/mode_t.m4: Update.
3669 * gnulib/import/m4/msvc-inval.m4: Update.
3670 * gnulib/import/m4/msvc-nothrow.m4: Update.
3671 * gnulib/import/m4/multiarch.m4: Update.
3672 * gnulib/import/m4/nocrash.m4: Update.
3673 * gnulib/import/m4/off_t.m4: Update.
3674 * gnulib/import/m4/onceonly.m4: Update.
3675 * gnulib/import/m4/open-cloexec.m4: Update.
3676 * gnulib/import/m4/open.m4: Update.
3677 * gnulib/import/m4/openat.m4: Update.
3678 * gnulib/import/m4/opendir.m4: Update.
3679 * gnulib/import/m4/pathmax.m4: Update.
3680 * gnulib/import/m4/rawmemchr.m4: Update.
3681 * gnulib/import/m4/readdir.m4: Update.
3682 * gnulib/import/m4/readlink.m4: Update.
3683 * gnulib/import/m4/realloc.m4: Update.
3684 * gnulib/import/m4/rename.m4: Update.
3685 * gnulib/import/m4/rewinddir.m4: Update.
3686 * gnulib/import/m4/rmdir.m4: Update.
3687 * gnulib/import/m4/save-cwd.m4: Update.
3688 * gnulib/import/m4/secure_getenv.m4: Update.
3689 * gnulib/import/m4/setenv.m4: Update.
3690 * gnulib/import/m4/signal_h.m4: Update.
3691 * gnulib/import/m4/ssize_t.m4: Update.
3692 * gnulib/import/m4/stat-time.m4: Update.
3693 * gnulib/import/m4/stat.m4: Update.
3694 * gnulib/import/m4/std-gnu11.m4: Update.
3695 * gnulib/import/m4/stdbool.m4: Update.
3696 * gnulib/import/m4/stddef_h.m4: Update.
3697 * gnulib/import/m4/stdint.m4: Update.
3698 * gnulib/import/m4/stdio_h.m4: Update.
3699 * gnulib/import/m4/stdlib_h.m4: Update.
3700 * gnulib/import/m4/strchrnul.m4: Update.
3701 * gnulib/import/m4/strdup.m4: Update.
3702 * gnulib/import/m4/strerror.m4: Update.
3703 * gnulib/import/m4/string_h.m4: Update.
3704 * gnulib/import/m4/strstr.m4: Update.
3705 * gnulib/import/m4/strtok_r.m4: Update.
3706 * gnulib/import/m4/sys_socket_h.m4: Update.
3707 * gnulib/import/m4/sys_stat_h.m4: Update.
3708 * gnulib/import/m4/sys_time_h.m4: Update.
3709 * gnulib/import/m4/sys_types_h.m4: Update.
3710 * gnulib/import/m4/tempname.m4: Update.
3711 * gnulib/import/m4/time_h.m4: Update.
3712 * gnulib/import/m4/unistd-safer.m4: Update.
3713 * gnulib/import/m4/unistd_h.m4: Update.
3714 * gnulib/import/m4/warn-on-use.m4: Update.
3715 * gnulib/import/m4/wchar_h.m4: Update.
3716 * gnulib/import/m4/wchar_t.m4: Update.
3717 * gnulib/import/m4/wctype_h.m4: Update.
3718 * gnulib/import/m4/wint_t.m4: Update.
3719 * gnulib/import/malloc.c: Update.
3720 * gnulib/import/malloc/scratch_buffer.h: Update.
3721 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
3722 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
3723 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
3724 * gnulib/import/malloca.c: Update.
3725 * gnulib/import/malloca.h: Update.
3726 * gnulib/import/malloca.valgrind: Update.
3727 * gnulib/import/math.in.h: Update.
3728 * gnulib/import/mbrtowc.c: Update.
3729 * gnulib/import/mbsinit.c: Update.
3730 * gnulib/import/mbsrtowcs-impl.h: Update.
3731 * gnulib/import/mbsrtowcs-state.c: Update.
3732 * gnulib/import/mbsrtowcs.c: Update.
3733 * gnulib/import/memchr.c: Update.
3734 * gnulib/import/memmem.c: Update.
3735 * gnulib/import/mempcpy.c: Update.
3736 * gnulib/import/memrchr.c: Update.
3737 * gnulib/import/mkdir.c: Update.
3738 * gnulib/import/mkstemp.c: Update.
3739 * gnulib/import/msvc-inval.c: Update.
3740 * gnulib/import/msvc-inval.h: Update.
3741 * gnulib/import/msvc-nothrow.c: Update.
3742 * gnulib/import/msvc-nothrow.h: Update.
3743 * gnulib/import/open.c: Update.
3744 * gnulib/import/openat-die.c: Update.
3745 * gnulib/import/openat-priv.h: Update.
3746 * gnulib/import/openat-proc.c: Update.
3747 * gnulib/import/openat.c: Update.
3748 * gnulib/import/openat.h: Update.
3749 * gnulib/import/opendir.c: Update.
3750 * gnulib/import/pathmax.h: Update.
3751 * gnulib/import/pipe-safer.c: Update.
3752 * gnulib/import/rawmemchr.c: Update.
3753 * gnulib/import/readdir.c: Update.
3754 * gnulib/import/readlink.c: Update.
3755 * gnulib/import/realloc.c: Update.
3756 * gnulib/import/ref-add.sin: Update.
3757 * gnulib/import/ref-del.sin: Update.
3758 * gnulib/import/rename.c: Update.
3759 * gnulib/import/rewinddir.c: Update.
3760 * gnulib/import/rmdir.c: Update.
3761 * gnulib/import/same-inode.h: Update.
3762 * gnulib/import/save-cwd.c: Update.
3763 * gnulib/import/save-cwd.h: Update.
3764 * gnulib/import/scratch_buffer.h: Update.
3765 * gnulib/import/secure_getenv.c: Update.
3766 * gnulib/import/setenv.c: Update.
3767 * gnulib/import/signal.in.h: Update.
3768 * gnulib/import/stat-time.c: Update.
3769 * gnulib/import/stat-time.h: Update.
3770 * gnulib/import/stat-w32.c: Update.
3771 * gnulib/import/stat-w32.h: Update.
3772 * gnulib/import/stat.c: Update.
3773 * gnulib/import/stdbool.in.h: Update.
3774 * gnulib/import/stddef.in.h: Update.
3775 * gnulib/import/stdint.in.h: Update.
3776 * gnulib/import/stdio.in.h: Update.
3777 * gnulib/import/stdlib.in.h: Update.
3778 * gnulib/import/str-two-way.h: Update.
3779 * gnulib/import/strchrnul.c: Update.
3780 * gnulib/import/strdup.c: Update.
3781 * gnulib/import/streq.h: Update.
3782 * gnulib/import/strerror-override.c: Update.
3783 * gnulib/import/strerror-override.h: Update.
3784 * gnulib/import/strerror.c: Update.
3785 * gnulib/import/string.in.h: Update.
3786 * gnulib/import/stripslash.c: Update.
3787 * gnulib/import/strnlen1.c: Update.
3788 * gnulib/import/strnlen1.h: Update.
3789 * gnulib/import/strstr.c: Update.
3790 * gnulib/import/strtok_r.c: Update.
3791 * gnulib/import/sys_stat.in.h: Update.
3792 * gnulib/import/sys_time.in.h: Update.
3793 * gnulib/import/sys_types.in.h: Update.
3794 * gnulib/import/tempname.c: Update.
3795 * gnulib/import/tempname.h: Update.
3796 * gnulib/import/time.in.h: Update.
3797 * gnulib/import/unistd--.h: Update.
3798 * gnulib/import/unistd-safer.h: Update.
3799 * gnulib/import/unistd.in.h: Update.
3800 * gnulib/import/unsetenv.c: Update.
3801 * gnulib/import/verify.h: Update.
3802 * gnulib/import/extra/snippet/warn-on-use.h: Update.
3803 * gnulib/import/wchar.in.h: Update.
3804 * gnulib/import/wctype.in.h: Update.
3805 * gnulib/import/xalloc-oversized.h: Update.
3806 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
3807 "53e2c179f26a890fa6685af4b6c1397ee370433b".
3808
3809 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
3810
3811 * record-btrace.c (get_thread_current_frame): Remove
3812 old_inferior_ptid.
3813
3814 2018-09-10 Jerome Guitton <guitton@adacore.com>
3815
3816 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
3817 with check_tag to 1 if and only if the type is tagged and the
3818 component being searched cannot been found in the current
3819 view. Otherwise, always call ada_to_fixed_type with
3820 check_tag to 0.
3821
3822 2018-09-10 Xavier Roirand <roirand@adacore.com>
3823
3824 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
3825 declaration.
3826 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
3827 * ada-varobj.c (ada_varobj_get_number_of_children,
3828 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
3829
3830 2018-09-10 Xavier Roirand <roirand@adacore.com>
3831
3832 * ada-valprint.c (ada_value_print): Use type instead of
3833 enclosing type.
3834
3835 2018-09-10 Xavier Roirand <roirand@adacore.com>
3836
3837 * ada-lang.c (ada_value_subscript): Handle case when parameter is
3838 an array of access to unconstrained array.
3839
3840 2018-09-10 Xavier Roirand <roirand@adacore.com>
3841
3842 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
3843 (ada_check_typedef): Use it.
3844
3845 2018-09-10 Xavier Roirand <roirand@adacore.com>
3846
3847 * ada-varobj.c (ada_varobj_describe_struct_child)
3848 (ada_varobj_describe_child): Handle union case like struct one.
3849
3850 2018-09-10 Tom Tromey <tom@tromey.com>
3851
3852 PR python/18380:
3853 * python/python.c (_initialize_python): Make example in "python"
3854 help work in Python 3.
3855
3856 2018-09-10 Eli Zaretskii <eliz@gnu.org>
3857
3858 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
3859 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
3860 $(EXEEXT) to the script, as it is not a program.
3861
3862 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
3863
3864 * python/py-prettyprint.c (pretty_print_one_value): Return
3865 gdbpy_ref<>.
3866 (print_string_repr): Adjust.
3867 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
3868 * python/python-internal.h (apply_varobj_pretty_printer): Return
3869 gdbpy_ref<>.
3870 * varobj.c (varobj_value_get_print_value): Adjust.
3871
3872 2018-09-08 Tom Tromey <tom@tromey.com>
3873
3874 PR python/16047:
3875 * python/py-prettyprint.c (pretty_print_one_value): Check for
3876 to_string method.
3877
3878 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3879
3880 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
3881 replace_operator_with_call.
3882
3883 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3884
3885 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
3886
3887 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3888
3889 * ada-typeprint.c (print_range): Print the bounds using TYPE
3890 rather than its TYPE_TARGET_TYPE.
3891
3892 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3893
3894 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
3895 call to ada_to_fixed_value_create.
3896
3897 2018-09-08 Jerome Guitton <guitton@adacore.com>
3898
3899 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
3900
3901 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3902
3903 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
3904 by calls to error.
3905
3906 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3907
3908 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
3909 Move update of loop variable "fi".
3910
3911 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3912
3913 * ada-lang.c (value_assign_to_component): In the case of
3914 big-endian targets, extract the bits of the given VAL
3915 using an src_offset of zero if container is not a scalar.
3916
3917 2018-09-06 Simon Ser <contact@emersion.fr>
3918
3919 PR gdb/23105
3920 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
3921 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
3922 * fbsd-tdep.c (fbsd_make_note_desc): New.
3923 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
3924 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
3925 * target.h (enum target_object) Add FreeBSD-specific
3926 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
3927
3928 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
3929
3930 * compile/compile-c.h (generate_c_for_variable_locations):
3931 Change reference to pointer.
3932 * compile/compile-c-support.c (compile_program) <compute>:
3933 Likewise.
3934 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
3935 (generate_c_for_for_one_variable): Likewise
3936 (generate_c_for_variable_locations): Likewise
3937 * compile/compile-c-types.c (compile_c_instance::convert_type):
3938 Likewise
3939 * compile/compile-cplus-symbols.c (convert_one_symbol):
3940 std::move the scope passed to enter_scope.
3941 * compile/compile-cplus-types.c
3942 (compile_cplus_instance::enter_scope): Make parameter
3943 rvalue-reference.
3944 (compile_cplus_instance::new_scope): Change reference to
3945 pointer.
3946 (compile_cplus_instance::convert_type): Likewise
3947 (compile_cplus_convert_typedef): std::move the scope passed to
3948 enter_scope.
3949 (compile_cplus_convert_struct_or_union): Likewise.
3950 (compile_cplus_convert_enum): Likewise.
3951 (compile_cplus_convert_namespace): Likewise.
3952 * compile/compile-cplus.h (compile_cplus_instance)
3953 <enter_scope>: Make parameter rvalue-reference.
3954 * compile/compile-internal.h (compile_instance)
3955 <get_cached_type>: Likewise
3956 * compile/compile-loc2c.c (push): Likewise
3957 (pushf): Likewise
3958 (unary): Likewise
3959 (binary): Likewise
3960 (print_label): Likewise
3961 (pushf_register_address): Likewise
3962 (pushf_register): Likewise
3963 (do_compile_dwarf_expr_to_c): Likewise
3964 (compile_dwarf_expr_to_c): Likewise
3965 (compile_dwarf_bounds_to_c): Likewise
3966 * compile/compile.c (compile_instance::get_cached_type):
3967 Likewise
3968 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
3969 (compile_dwarf_bounds_to_c): Likewise
3970 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
3971 (dwarf2_compile_property_to_c): Likewise
3972 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
3973 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
3974 Likewise
3975
3976 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
3977
3978 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
3979 * tui/tui-data.c (init_content_element): Don't initialize it.
3980
3981 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
3982
3983 * tui/tui-data.h (struct tui_win_info)
3984 <detail::opaque>: Remove.
3985 * tui/tui-data.c (init_win_info): Remove assignment.
3986
3987 2018-09-05 Tom Tromey <tom@tromey.com>
3988
3989 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
3990 -Wformat-nonliteral.
3991 * target-float.c (host_float_ops<T>::to_string)
3992 (host_float_ops<T>::from_string): Use
3993 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
3994 * configure: Rebuild.
3995
3996 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
3997
3998 * printcmd.c (printf_c_string): Use
3999 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
4000 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
4001
4002 2018-09-05 Tom Tromey <tom@tromey.com>
4003
4004 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
4005
4006 2018-09-05 Tom de Vries <tdevries@suse.de>
4007
4008 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
4009 with resolve_abstract_p == true.
4010 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
4011 defaulting to false. Propagate resolve_abstract_p to
4012 dwarf2_fetch_die_loc_sect_off.
4013 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
4014 parameter, defaulting to false.
4015 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
4016 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
4017 parameter.
4018 * dwarf2read.h (struct die_info): Forward-declare.
4019 (die_info_ptr): New typedef.
4020 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
4021
4022 2018-09-05 Joel Brobecker <brobecker@adacore.com>
4023
4024 GDB 8.2 released.
4025
4026 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
4027 Pedro Alves <palves@redhat.com>
4028
4029 * gnulib/Makefile.in (aclocal_m4_deps): Move to
4030 "aclocal-m4-deps.mk". Include file here.
4031 $(srcdir)/aclocal.m4: Add "configure.ac".
4032 * gnulib/aclocal-m4-deps.mk: New file.
4033 * gnulib/update-gnulib.sh: Automatically update
4034 "aclocal-m4-deps.mk".
4035
4036 2018-09-04 Tom Tromey <tom@tromey.com>
4037
4038 * configure: Rebuild.
4039 * configure.ac: Remove multi-ice code.
4040
4041 2018-09-04 Tom Tromey <tom@tromey.com>
4042
4043 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
4044 (ada-exp.o): Update.
4045
4046 2018-09-04 Tom Tromey <tom@tromey.com>
4047
4048 * Makefile.in (printcmd.o, target-float.o): Remove.
4049 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
4050
4051 2018-09-04 Tom Tromey <tom@tromey.com>
4052
4053 * gnulib/Makefile.in: Remove obsolete comment.
4054 * Makefile.in: Remove obsolete comment.
4055
4056 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
4057
4058 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
4059 line with '+'.
4060
4061 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
4062
4063 * riscv-tdep.c: Add 'prologue-value.h' include.
4064 (struct riscv_unwind_cache): New struct.
4065 (riscv_debug_unwinder): New global.
4066 (riscv_scan_prologue): Update arguments, capture register details
4067 from prologue scan.
4068 (riscv_skip_prologue): Reformat arguments line, move end of
4069 prologue calculation into riscv_scan_prologue.
4070 (riscv_frame_cache): Update return type, create
4071 riscv_unwind_cache, scan the prologue, and fill in remaining cache
4072 details.
4073 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
4074 (riscv_frame_prev_register): Use the trad_frame within the
4075 riscv_unwind_cache.
4076 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
4077 flag.
4078
4079 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
4080
4081 * trad-frame.h (trad_frame_set_realreg): Declare.
4082 (trad_frame_set_addr): Declare.
4083 * trad-frame.c (trad_frame_set_realreg): Define new function.
4084 (trad_frame_set_addr): Define new function.
4085 (trad_frame_set_reg_realreg): Use new function.
4086 (trad_frame_set_reg_addr): Use new function.
4087
4088 2018-09-01 Keith Seitz <keiths@redhat.com>
4089
4090 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
4091 pulongest instead of "%lld".
4092 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
4093 ATTRIBUTE_UNUSED.
4094
4095 2018-08-31 Tom Tromey <tom@tromey.com>
4096
4097 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
4098 variant part type.
4099
4100 2018-08-31 Pedro Alves <palves@redhat.com>
4101
4102 * gdbarch.h: Regenerate.
4103
4104 2018-08-31 Pedro Alves <palves@redhat.com>
4105
4106 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
4107 * target.h (Hardware watchpoint interfaces): Describe
4108 continuable/steppable/non-steppable watchpoints.
4109 * gdbarch.h, gdbarch.c: Regenerate.
4110
4111 2018-08-31 Pedro Alves <palves@redhat.com>
4112
4113 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
4114 Delete.
4115 * s390-linux-nat.c
4116 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
4117 * target.h (target_ops::have_continuable_watchpoint): Delete.
4118 (target_have_continuable_watchpoint): Delete.
4119 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
4120 * target-delegates.c: Regenerate.
4121
4122 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
4123
4124 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
4125 the files present in "gnulib/import/m4/".
4126
4127 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
4128
4129 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
4130 c.sw, c.swsp, and c.sdsp.
4131
4132 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
4133
4134 * riscv-tdep.c (struct riscv_inferior_data): Delete.
4135 (riscv_read_misa_reg): Don't cache value read into inferior data.
4136 (riscv_new_inferior_data): Delete.
4137 (riscv_inferior_data_cleanup): Delete.
4138 (riscv_inferior_data): Delete.
4139 (riscv_invalidate_inferior_data): Delete.
4140 (_initialize_riscv_tdep): Remove initialisation of inferior data.
4141
4142 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
4143
4144 * compile/compile-cplus-types.c
4145 (compile_cplus_instance::leave_scope): Take the address of scope
4146 object.
4147 (compile_cplus_instance::convert_qualified_base): Compare quals
4148 to 0.
4149
4150 2018-08-30 Keith Seitz <keiths@redhat.com>
4151
4152 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
4153 Use "%s" and host_address_to_string instead of "%p" in printf.
4154
4155 2018-08-29 Keith Seitz <keiths@redhat.com>
4156
4157 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
4158 and compile-cplus-types.c.
4159 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
4160 * c-lang.c (cplus_language_defn): Set C++ compile functions.
4161 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
4162 Declare.
4163 * compile/compile-c-support.c: Include compile-cplus.h.
4164 (load_libcompile): Templatize.
4165 (get_compile_context): "New" function.
4166 (c_get_compile_context): Use get_compile_context.
4167 (cplus_get_compile_context): New function.
4168 (cplus_push_user_expression, cplus_pop_user_expression)
4169 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
4170 (cplus_compute_program): Define new structs/functions.
4171 * compile/compile-cplus-symmbols.c: New file.
4172 * compile/compile-cplus-types.c: New file.
4173 * compile/compile-cplus.h: New file.
4174 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
4175 Declare.
4176 * compile/compile-object-load.c (get_out_value_type): Use
4177 strncmp_iw when comparing symbol names.
4178 (compile_object_load): Add mst_bss and mst_data.
4179 * compile/compile.c (_initialize_compile): Remove
4180 -Wno-implicit-function-declaration from `compile_args'.
4181 * compile/gcc-cp-plugin.h: New file.
4182 * NEWS: Mention C++ compile support and new debug options.
4183
4184 2018-08-29 Keith Seitz <keiths@redhat.com>
4185
4186 * linespec.c (collect_info::add_symbol): Make virtual.
4187 (struct symbol_searcher_collect_info): New struct.
4188 (symbol_searcher::find_all_symbols): New method.
4189 * symtab.h (class symbol_searcher): New class.
4190
4191 2018-08-29 Keith Seitz <keiths@redhat.com>
4192
4193 * linespec.c (struct linespec) <function_symbols, label_symbols>:
4194 Change to vector of block_symbol. Update all users.
4195 (struct collect_info) <symbols>: Likewise.
4196 (collect_info::add_symbol): Take block_symbol as argument.
4197 Update all callers.
4198 (decode_compound_collector) <m_symbols>: Change type to vector
4199 of block_symbol. Update all users.
4200 (decode_compound_collector::operator ()): Change parameter type
4201 to block_symbol.
4202 (find_method, find_function_symbols, find_linespec_symbols)
4203 (find_label_symbols_in_block, find_label_symbols): Change symbol
4204 vectors to block_symbol vectors.
4205 * symtab.h (symbol_found_callback_ftype): Change parameter type to
4206 block_symbol.
4207
4208 2018-08-29 Keith Seitz <keiths@redhat.com>
4209
4210 * linespec.c (symbolp): Remove typedef and VEC definitions.
4211 (bound_minimal_symbol_d): Likewise.
4212
4213 2018-08-29 Keith Seitz <keiths@redhat.com>
4214
4215 * linespec.c (decode_compound_collector::decode_compound_collector):
4216 Remove initialization for `m_symtabs'.
4217 (decode_compound_collector::release_symbols): Change return type
4218 to std::vector. Update all callers.
4219 (class decode_compound_collector) <m_symbols>: Change type to
4220 std::vector.
4221 (lookup_prefix_sym): Change return type to std::vector. Update all
4222 callers.
4223 (compare_symbols): Remove.
4224 (std_compare_symbols): Rename to `compare_symbols'.
4225 (find_method): Change `sym_classes' parameter to std::vector.
4226 Update all callers. Use std::sort to sort sym_classes.
4227 (find_linespec_symbols): Remove cleanup.
4228
4229 2018-08-29 Keith Seitz <keiths@redhat.com>
4230
4231 * linespec.c (struct linespec) <minimal_symbols>: Change type to
4232 std::vector. Update all users.
4233 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
4234 (struct collect_info) <minimal_symbols>: Likewise.
4235 (compare_msymbols): Return bool. Change parameters to const
4236 bound_minimal_symbol references.
4237 (find_method, find_function_symbols, find_linespec_symbols): Change
4238 `minsyms' parameter to std::vector. Update all callers.
4239
4240 2018-08-29 Keith Seitz <keiths@redhat.com>
4241
4242 * linespec.c (struct linespec) <label_symbols>: Change type to
4243 std::vector. Update all users.
4244 (find_label_symbols_in_block): Change `result' parameter to
4245 std::vector. Update all callers.
4246 (find_label_symbols): Return std::vector. Update all callers.
4247
4248 2018-08-29 Keith Seitz <keiths@redhat.com>
4249
4250 * linespec.c (struct linespec) <function_symbols>: Change type to
4251 std::vector. Update all users.
4252 (struct collect_info) <function_symbols>: Likewise.
4253 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
4254 (std_compare_symbols): New function.
4255 (find_method, find_function_symbols, find_linespec_symbols)
4256 (find_label_symbols_in_block): Change `symbols' parameter to
4257 std::vector. Update all callers.
4258 (find_label_symbols): Likewise for `function_symbols' and
4259 `label_funcs_ret'.
4260
4261 2018-08-29 Keith Seitz <keiths@redhat.com>
4262
4263 * linespec.c (symtab_vector_up): Define.
4264 (struct linespec) <file_symtabs>: Change type to std::vector *.
4265 Update all uses.
4266 (struct collect_info) <file_symtabs>: Likewise.
4267 (collect_symtabs_from_filename): Return symtab_vector_up.
4268 Update all callers.
4269 (decode_objc): Remove cleanup.
4270 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
4271 (symtab_collector::release_symtabs): Return symtab_vector_up.
4272 Update all callers.
4273 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
4274 Update all users.
4275 (collect_symtabs_from_filename, symtabs_from_filename): Return
4276 symtab_vector_up. Update all callers.
4277
4278 2018-08-29 Tom Tromey <tom@tromey.com>
4279
4280 * csky-tdep.c (csky_analyze_prologue): Use
4281 core_addr_to_string_nz.
4282
4283 2018-08-29 Tom Tromey <tom@tromey.com>
4284
4285 * windows-nat.c (struct xlate_exception) <them>: Change type to
4286 DWORD.
4287 (xlate): Fix formatting. Remove last entry.
4288 (struct xlate_exception, xlate): Comment out.
4289 (windows_nat_target::resume): Use ranged for.
4290
4291 2018-08-29 Jim Wilson <jimw@sifive.com>
4292
4293 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
4294 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
4295 of NT_PRFPREG.
4296 (riscv_linux_nat_target::store_registers): Likewise.
4297
4298 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
4299
4300 PR gdb/23555
4301 PR gdb/23558
4302 * gnulib/aclocal.m4: Regenerate.
4303 * gnulib/config.in: Regenerate.
4304 * gnulib/configure: Regenerate.
4305 * gnulib/import/Makefile.am: Update.
4306 * gnulib/import/Makefile.in: Update.
4307 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
4308 * gnulib/import/_Noreturn.h: ... this.
4309 * gnulib/import/alloca.in.h: Update.
4310 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
4311 * gnulib/import/arg-nonnull.h: ... this.
4312 * gnulib/import/assure.h: Update.
4313 * gnulib/import/at-func.c: Update.
4314 * gnulib/import/basename-lgpl.c: Update.
4315 * gnulib/import/extra/snippet/c++defs.h: Rename to...
4316 * gnulib/import/c++defs.h: ... this.
4317 * gnulib/import/canonicalize-lgpl.c: Update.
4318 * gnulib/import/cdefs.h: Update.
4319 * gnulib/import/chdir-long.c: Update.
4320 * gnulib/import/chdir-long.h: Update.
4321 * gnulib/import/cloexec.c: Update.
4322 * gnulib/import/cloexec.h: Update.
4323 * gnulib/import/close.c: Update.
4324 * gnulib/import/closedir.c: Update.
4325 * gnulib/import/config.charset: Update.
4326 * gnulib/import/dirent-private.h: Update.
4327 * gnulib/import/dirent.in.h: Update.
4328 * gnulib/import/dirfd.c: Update.
4329 * gnulib/import/dirname-lgpl.c: Update.
4330 * gnulib/import/dirname.h: Update.
4331 * gnulib/import/dosname.h: Update.
4332 * gnulib/import/dup-safer-flag.c: Update.
4333 * gnulib/import/dup-safer.c: Update.
4334 * gnulib/import/dup.c: Update.
4335 * gnulib/import/dup2.c: Update.
4336 * gnulib/import/errno.in.h: Update.
4337 * gnulib/import/error.c: Update.
4338 * gnulib/import/error.h: Update.
4339 * gnulib/import/exitfail.c: Update.
4340 * gnulib/import/exitfail.h: Update.
4341 * gnulib/import/extra/update-copyright: Update.
4342 * gnulib/import/fchdir.c: Update.
4343 * gnulib/import/fcntl.c: Update.
4344 * gnulib/import/fcntl.in.h: Update.
4345 * gnulib/import/fd-hook.c: Update.
4346 * gnulib/import/fd-hook.h: Update.
4347 * gnulib/import/fd-safer-flag.c: Update.
4348 * gnulib/import/fd-safer.c: Update.
4349 * gnulib/import/fdopendir.c: Update.
4350 * gnulib/import/filename.h: Update.
4351 * gnulib/import/filenamecat-lgpl.c: Update.
4352 * gnulib/import/filenamecat.h: Update.
4353 * gnulib/import/flexmember.h: Update.
4354 * gnulib/import/float+.h: Update.
4355 * gnulib/import/float.c: Update.
4356 * gnulib/import/float.in.h: Update.
4357 * gnulib/import/fnmatch.c: Update.
4358 * gnulib/import/fnmatch.in.h: Update.
4359 * gnulib/import/fnmatch_loop.c: Update.
4360 * gnulib/import/fpucw.h: Update.
4361 * gnulib/import/frexp.c: Update.
4362 * gnulib/import/frexpl.c: Update.
4363 * gnulib/import/fstat.c: Update.
4364 * gnulib/import/fstatat.c: Update.
4365 * gnulib/import/getcwd-lgpl.c: Update.
4366 * gnulib/import/getcwd.c: Update.
4367 * gnulib/import/getdtablesize.c: Update.
4368 * gnulib/import/getlogin_r.c: Update.
4369 * gnulib/import/getprogname.c: Update.
4370 * gnulib/import/getprogname.h: Update.
4371 * gnulib/import/gettext.h: Update.
4372 * gnulib/import/gettimeofday.c: Update.
4373 * gnulib/import/glob-libc.h: Update.
4374 * gnulib/import/glob.c: Update.
4375 * gnulib/import/glob.in.h: Update.
4376 * gnulib/import/glob_internal.h: Update.
4377 * gnulib/import/glob_pattern_p.c: Update.
4378 * gnulib/import/globfree.c: Update.
4379 * gnulib/import/hard-locale.c: Update.
4380 * gnulib/import/hard-locale.h: Update.
4381 * gnulib/import/intprops.h: Update.
4382 * gnulib/import/inttypes.in.h: Update.
4383 * gnulib/import/isnan.c: Update.
4384 * gnulib/import/isnand-nolibm.h: Update.
4385 * gnulib/import/isnand.c: Update.
4386 * gnulib/import/isnanl-nolibm.h: Update.
4387 * gnulib/import/isnanl.c: Update.
4388 * gnulib/import/itold.c: Update.
4389 * gnulib/import/libc-config.h: Update.
4390 * gnulib/import/limits.in.h: Update.
4391 * gnulib/import/localcharset.c: Update.
4392 * gnulib/import/localcharset.h: Update.
4393 * gnulib/import/localtime-buffer.c: Update.
4394 * gnulib/import/localtime-buffer.h: Update.
4395 * gnulib/import/lstat.c: Update.
4396 * gnulib/import/m4/00gnulib.m4: Update.
4397 * gnulib/import/m4/__inline.m4: Update.
4398 * gnulib/import/m4/absolute-header.m4: Update.
4399 * gnulib/import/m4/alloca.m4: Update.
4400 * gnulib/import/m4/builtin-expect.m4: Update.
4401 * gnulib/import/m4/canonicalize.m4: Update.
4402 * gnulib/import/m4/chdir-long.m4: Update.
4403 * gnulib/import/m4/close.m4: Update.
4404 * gnulib/import/m4/closedir.m4: Update.
4405 * gnulib/import/m4/configmake.m4: Update.
4406 * gnulib/import/m4/d-ino.m4: Update.
4407 * gnulib/import/m4/d-type.m4: Update.
4408 * gnulib/import/m4/dirent_h.m4: Update.
4409 * gnulib/import/m4/dirfd.m4: Update.
4410 * gnulib/import/m4/dirname.m4: Update.
4411 * gnulib/import/m4/double-slash-root.m4: Update.
4412 * gnulib/import/m4/dup.m4: Update.
4413 * gnulib/import/m4/dup2.m4: Update.
4414 * gnulib/import/m4/eealloc.m4: Update.
4415 * gnulib/import/m4/environ.m4: Update.
4416 * gnulib/import/m4/errno_h.m4: Update.
4417 * gnulib/import/m4/error.m4: Update.
4418 * gnulib/import/m4/exponentd.m4: Update.
4419 * gnulib/import/m4/exponentl.m4: Update.
4420 * gnulib/import/m4/extensions.m4: Update.
4421 * gnulib/import/m4/extern-inline.m4: Update.
4422 * gnulib/import/m4/fchdir.m4: Update.
4423 * gnulib/import/m4/fcntl-o.m4: Update.
4424 * gnulib/import/m4/fcntl.m4: Update.
4425 * gnulib/import/m4/fcntl_h.m4: Update.
4426 * gnulib/import/m4/fdopendir.m4: Update.
4427 * gnulib/import/m4/filenamecat.m4: Update.
4428 * gnulib/import/m4/flexmember.m4: Update.
4429 * gnulib/import/m4/float_h.m4: Update.
4430 * gnulib/import/m4/fnmatch.m4: Update.
4431 * gnulib/import/m4/fnmatch_h.m4: Update.
4432 * gnulib/import/m4/fpieee.m4: Update.
4433 * gnulib/import/m4/frexp.m4: Update.
4434 * gnulib/import/m4/frexpl.m4: Update.
4435 * gnulib/import/m4/fstat.m4: Update.
4436 * gnulib/import/m4/fstatat.m4: Update.
4437 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
4438 * gnulib/import/m4/getcwd-path-max.m4: Update.
4439 * gnulib/import/m4/getcwd.m4: Update.
4440 * gnulib/import/m4/getdtablesize.m4: Update.
4441 * gnulib/import/m4/getlogin.m4: Update.
4442 * gnulib/import/m4/getlogin_r.m4: Update.
4443 * gnulib/import/m4/getpagesize.m4: Update.
4444 * gnulib/import/m4/getprogname.m4: Update.
4445 * gnulib/import/m4/gettimeofday.m4: Update.
4446 * gnulib/import/m4/glibc21.m4: Update.
4447 * gnulib/import/m4/glob.m4: Update.
4448 * gnulib/import/m4/glob_h.m4: Update.
4449 * gnulib/import/m4/gnulib-cache.m4: Update.
4450 * gnulib/import/m4/gnulib-common.m4: Update.
4451 * gnulib/import/m4/gnulib-comp.m4: Update.
4452 * gnulib/import/m4/gnulib-tool.m4: Update.
4453 * gnulib/import/m4/hard-locale.m4: Update.
4454 * gnulib/import/m4/include_next.m4: Update.
4455 * gnulib/import/m4/inttypes-pri.m4: Update.
4456 * gnulib/import/m4/inttypes.m4: Update.
4457 * gnulib/import/m4/isnand.m4: Update.
4458 * gnulib/import/m4/isnanl.m4: Update.
4459 * gnulib/import/m4/largefile.m4: Update.
4460 * gnulib/import/m4/limits-h.m4: Update.
4461 * gnulib/import/m4/localcharset.m4: Update.
4462 * gnulib/import/m4/locale-fr.m4: Update.
4463 * gnulib/import/m4/locale-ja.m4: Update.
4464 * gnulib/import/m4/locale-zh.m4: Update.
4465 * gnulib/import/m4/localtime-buffer.m4: Update.
4466 * gnulib/import/m4/longlong.m4: Update.
4467 * gnulib/import/m4/lstat.m4: Update.
4468 * gnulib/import/m4/malloc.m4: Update.
4469 * gnulib/import/m4/malloca.m4: Update.
4470 * gnulib/import/m4/math_h.m4: Update.
4471 * gnulib/import/m4/mbrtowc.m4: Update.
4472 * gnulib/import/m4/mbsinit.m4: Update.
4473 * gnulib/import/m4/mbsrtowcs.m4: Update.
4474 * gnulib/import/m4/mbstate_t.m4: Update.
4475 * gnulib/import/m4/memchr.m4: Update.
4476 * gnulib/import/m4/memmem.m4: Update.
4477 * gnulib/import/m4/mempcpy.m4: Update.
4478 * gnulib/import/m4/memrchr.m4: Update.
4479 * gnulib/import/m4/mkdir.m4: Update.
4480 * gnulib/import/m4/mkstemp.m4: Update.
4481 * gnulib/import/m4/mmap-anon.m4: Update.
4482 * gnulib/import/m4/mode_t.m4: Update.
4483 * gnulib/import/m4/msvc-inval.m4: Update.
4484 * gnulib/import/m4/msvc-nothrow.m4: Update.
4485 * gnulib/import/m4/multiarch.m4: Update.
4486 * gnulib/import/m4/nocrash.m4: Update.
4487 * gnulib/import/m4/off_t.m4: Update.
4488 * gnulib/import/m4/onceonly.m4: Update.
4489 * gnulib/import/m4/open-cloexec.m4: Update.
4490 * gnulib/import/m4/open.m4: Update.
4491 * gnulib/import/m4/openat.m4: Update.
4492 * gnulib/import/m4/opendir.m4: Update.
4493 * gnulib/import/m4/pathmax.m4: Update.
4494 * gnulib/import/m4/rawmemchr.m4: Update.
4495 * gnulib/import/m4/readdir.m4: Update.
4496 * gnulib/import/m4/readlink.m4: Update.
4497 * gnulib/import/m4/realloc.m4: Update.
4498 * gnulib/import/m4/rename.m4: Update.
4499 * gnulib/import/m4/rewinddir.m4: Update.
4500 * gnulib/import/m4/rmdir.m4: Update.
4501 * gnulib/import/m4/save-cwd.m4: Update.
4502 * gnulib/import/m4/secure_getenv.m4: Update.
4503 * gnulib/import/m4/setenv.m4: Update.
4504 * gnulib/import/m4/signal_h.m4: Update.
4505 * gnulib/import/m4/ssize_t.m4: Update.
4506 * gnulib/import/m4/stat-time.m4: Update.
4507 * gnulib/import/m4/stat.m4: Update.
4508 * gnulib/import/m4/std-gnu11.m4: Update.
4509 * gnulib/import/m4/stdbool.m4: Update.
4510 * gnulib/import/m4/stddef_h.m4: Update.
4511 * gnulib/import/m4/stdint.m4: Update.
4512 * gnulib/import/m4/stdio_h.m4: Update.
4513 * gnulib/import/m4/stdlib_h.m4: Update.
4514 * gnulib/import/m4/strchrnul.m4: Update.
4515 * gnulib/import/m4/strdup.m4: Update.
4516 * gnulib/import/m4/strerror.m4: Update.
4517 * gnulib/import/m4/string_h.m4: Update.
4518 * gnulib/import/m4/strstr.m4: Update.
4519 * gnulib/import/m4/strtok_r.m4: Update.
4520 * gnulib/import/m4/sys_socket_h.m4: Update.
4521 * gnulib/import/m4/sys_stat_h.m4: Update.
4522 * gnulib/import/m4/sys_time_h.m4: Update.
4523 * gnulib/import/m4/sys_types_h.m4: Update.
4524 * gnulib/import/m4/tempname.m4: Update.
4525 * gnulib/import/m4/time_h.m4: Update.
4526 * gnulib/import/m4/unistd-safer.m4: Update.
4527 * gnulib/import/m4/unistd_h.m4: Update.
4528 * gnulib/import/m4/warn-on-use.m4: Update.
4529 * gnulib/import/m4/wchar_h.m4: Update.
4530 * gnulib/import/m4/wchar_t.m4: Update.
4531 * gnulib/import/m4/wctype_h.m4: Update.
4532 * gnulib/import/m4/wint_t.m4: Update.
4533 * gnulib/import/malloc.c: Update.
4534 * gnulib/import/malloc/scratch_buffer.h: Update.
4535 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
4536 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
4537 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
4538 * gnulib/import/malloca.c: Update.
4539 * gnulib/import/malloca.h: Update.
4540 * gnulib/import/malloca.valgrind: Update.
4541 * gnulib/import/math.in.h: Update.
4542 * gnulib/import/mbrtowc.c: Update.
4543 * gnulib/import/mbsinit.c: Update.
4544 * gnulib/import/mbsrtowcs-impl.h: Update.
4545 * gnulib/import/mbsrtowcs-state.c: Update.
4546 * gnulib/import/mbsrtowcs.c: Update.
4547 * gnulib/import/memchr.c: Update.
4548 * gnulib/import/memmem.c: Update.
4549 * gnulib/import/mempcpy.c: Update.
4550 * gnulib/import/memrchr.c: Update.
4551 * gnulib/import/mkdir.c: Update.
4552 * gnulib/import/mkstemp.c: Update.
4553 * gnulib/import/msvc-inval.c: Update.
4554 * gnulib/import/msvc-inval.h: Update.
4555 * gnulib/import/msvc-nothrow.c: Update.
4556 * gnulib/import/msvc-nothrow.h: Update.
4557 * gnulib/import/open.c: Update.
4558 * gnulib/import/openat-die.c: Update.
4559 * gnulib/import/openat-priv.h: Update.
4560 * gnulib/import/openat-proc.c: Update.
4561 * gnulib/import/openat.c: Update.
4562 * gnulib/import/openat.h: Update.
4563 * gnulib/import/opendir.c: Update.
4564 * gnulib/import/pathmax.h: Update.
4565 * gnulib/import/pipe-safer.c: Update.
4566 * gnulib/import/rawmemchr.c: Update.
4567 * gnulib/import/readdir.c: Update.
4568 * gnulib/import/readlink.c: Update.
4569 * gnulib/import/realloc.c: Update.
4570 * gnulib/import/ref-add.sin: Update.
4571 * gnulib/import/ref-del.sin: Update.
4572 * gnulib/import/rename.c: Update.
4573 * gnulib/import/rewinddir.c: Update.
4574 * gnulib/import/rmdir.c: Update.
4575 * gnulib/import/same-inode.h: Update.
4576 * gnulib/import/save-cwd.c: Update.
4577 * gnulib/import/save-cwd.h: Update.
4578 * gnulib/import/scratch_buffer.h: Update.
4579 * gnulib/import/secure_getenv.c: Update.
4580 * gnulib/import/setenv.c: Update.
4581 * gnulib/import/signal.in.h: Update.
4582 * gnulib/import/stat-time.c: Update.
4583 * gnulib/import/stat-time.h: Update.
4584 * gnulib/import/stat-w32.c: Update.
4585 * gnulib/import/stat-w32.h: Update.
4586 * gnulib/import/stat.c: Update.
4587 * gnulib/import/stdbool.in.h: Update.
4588 * gnulib/import/stddef.in.h: Update.
4589 * gnulib/import/stdint.in.h: Update.
4590 * gnulib/import/stdio.in.h: Update.
4591 * gnulib/import/stdlib.in.h: Update.
4592 * gnulib/import/str-two-way.h: Update.
4593 * gnulib/import/strchrnul.c: Update.
4594 * gnulib/import/strdup.c: Update.
4595 * gnulib/import/streq.h: Update.
4596 * gnulib/import/strerror-override.c: Update.
4597 * gnulib/import/strerror-override.h: Update.
4598 * gnulib/import/strerror.c: Update.
4599 * gnulib/import/string.in.h: Update.
4600 * gnulib/import/stripslash.c: Update.
4601 * gnulib/import/strnlen1.c: Update.
4602 * gnulib/import/strnlen1.h: Update.
4603 * gnulib/import/strstr.c: Update.
4604 * gnulib/import/strtok_r.c: Update.
4605 * gnulib/import/sys_stat.in.h: Update.
4606 * gnulib/import/sys_time.in.h: Update.
4607 * gnulib/import/sys_types.in.h: Update.
4608 * gnulib/import/tempname.c: Update.
4609 * gnulib/import/tempname.h: Update.
4610 * gnulib/import/time.in.h: Update.
4611 * gnulib/import/unistd--.h: Update.
4612 * gnulib/import/unistd-safer.h: Update.
4613 * gnulib/import/unistd.in.h: Update.
4614 * gnulib/import/unsetenv.c: Update.
4615 * gnulib/import/verify.h: Update.
4616 * gnulib/import/extra/snippet/warn-on-use.h: Update.
4617 * gnulib/import/wchar.in.h: Update.
4618 * gnulib/import/wctype.in.h: Update.
4619 * gnulib/import/xalloc-oversized.h: Update.
4620 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
4621 "53e2c179f26a890fa6685af4b6c1397ee370433b".
4622
4623 2018-08-16 Gary Benson <gbenson@redhat.com>
4624
4625 PR gdb/13000:
4626 * gdb/main.c (captured_main_1): Exit with nonzero status
4627 in batch mode if the last command to be executed failed.
4628 * NEWS: Mention the above.
4629
4630 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
4631
4632 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
4633 end of warning message.
4634
4635 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4636
4637 PR gdb/22943:
4638 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
4639 (aarch64_extract_return_value): Use
4640 aapcs_is_vfp_call_or_return_candidate.
4641 (aarch64_return_in_memory): Likewise.
4642 (aarch64_store_return_value): Likewise.
4643
4644 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4645
4646 * aarch64-tdep.c
4647 (aapcs_is_vfp_call_or_return_candidate): Make static
4648 (pass_in_v_or_stack): Remove function.
4649 (pass_in_v_vfp_candidate): New function.
4650 (aarch64_push_dummy_call): Check for float register candidates.
4651
4652 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4653
4654 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
4655 (aapcs_is_vfp_call_or_return_candidate_1): New function.
4656 (aapcs_is_vfp_call_or_return_candidate): Likewise.
4657
4658 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
4659
4660 PR build/23399
4661 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
4662 (struct ipa_sym_addresses): Rename to...
4663 (struct ipa_sym_addresses_common): ... this.
4664 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
4665
4666 2018-08-28 Tom Tromey <tom@tromey.com>
4667
4668 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
4669 (token_fifo): Now a std::vector.
4670 (yylex, c_parse): Update.
4671 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
4672 (token_fifo): Now a std::vector.
4673 (yylex, d_parse): Update.
4674 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
4675 (token_fifo): Now a std::vector.
4676 (yylex, go_parse): Update.
4677
4678 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
4679
4680 * parser-defs.h (struct type_stack) <elements>: Change type to
4681 std::vector<union type_stack_elt>.
4682 <depth, size>: Remove.
4683 * parse.c (parse_exp_in_context_1): Adjust.
4684 (type_stack_reserve): Remove.
4685 (check_type_stack_depth): Remove.
4686 (insert_into_type_stack): Adjust to std::vector.
4687 (insert_type): Likewise.
4688 (push_type): Likewise.
4689 (push_type_int): Likewise.
4690 (insert_type_address_space): Likewise.
4691 (pop_type): Likewise.
4692 (pop_type_int): Likewise.
4693 (pop_typelist): Likewise.
4694 (pop_type_stack): Likewise.
4695 (append_type_stack): Likewise.
4696 (push_type_stack): Likewise.
4697 (get_type_stack): Likewise.
4698 (type_stack_cleanup): Likewise.
4699 (push_typelist): Likewise.
4700 (follow_types): Likewise.
4701 (_initialize_parse): Likewise.
4702
4703 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
4704
4705 * NEWS: Mention csky target.
4706
4707 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
4708 Hafiz Abid Qadeer <abidh@codesourcery.com>
4709 Don Breazeal <donb@codesourcery.com>
4710
4711 * csky-linux-tdep.c: New file.
4712 * csky-tdep.c: Likewise.
4713 * csky-tdep.h: Likewise.
4714 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
4715 csky-tdep.o.
4716 (HFILES_NO_SRCDIR): Add csky-tdep.h.
4717 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
4718 * configure.tgt: Add csky support.
4719
4720 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
4721
4722 * python/py-framefilter.c (py_print_frame): Print frame architecture
4723 when printing on an MI output.
4724
4725 2018-08-27 Tom Tromey <tom@tromey.com>
4726
4727 PR build/23087:
4728 * configure: Rebuild.
4729 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
4730
4731 2018-08-27 Tom Tromey <tom@tromey.com>
4732
4733 * aarch64-linux-tdep.c
4734 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
4735 casts to int.
4736
4737 2018-08-27 Tom Tromey <tom@tromey.com>
4738
4739 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
4740 unsigned.
4741 (ppc64_standard_linkage1, ppc64_standard_linkage2)
4742 (ppc64_standard_linkage3, ppc64_standard_linkage4)
4743 (ppc64_standard_linkage5, ppc64_standard_linkage6)
4744 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
4745 unsigned.
4746
4747 2018-08-27 Tom Tromey <tom@tromey.com>
4748
4749 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
4750 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
4751
4752 2018-08-27 Tom Tromey <tom@tromey.com>
4753
4754 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
4755 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
4756 ULONGEST_MAX.
4757 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
4758 ULONGEST_MAX.
4759 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
4760 ULONGEST_MAX.
4761 * sparc-linux-tdep.c (sparc32_linux_sigframe)
4762 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
4763 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
4764 ULONGEST_MAX.
4765 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
4766 (ppc64_linux_sigaction_tramp_frame)
4767 (ppc32_linux_sighandler_tramp_frame)
4768 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
4769 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
4770 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
4771 * mn10300-linux-tdep.c (am33_linux_sigframe)
4772 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
4773 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
4774 * mips-linux-tdep.c (mips_linux_o32_sigframe)
4775 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
4776 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
4777 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
4778 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
4779 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
4780 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
4781 * microblaze-linux-tdep.c
4782 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
4783 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
4784 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
4785 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
4786 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
4787 * common/common-types.h (ULONGEST_MAX): New define.
4788 (CORE_ADDR_MAX): Fix formatting.
4789 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
4790 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
4791 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
4792 (arm_linux_rt_sigreturn_tramp_frame)
4793 (arm_eabi_linux_sigreturn_tramp_frame)
4794 (arm_eabi_linux_rt_sigreturn_tramp_frame)
4795 (thumb2_eabi_linux_sigreturn_tramp_frame)
4796 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
4797 (arm_linux_restart_syscall_tramp_frame)
4798 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
4799 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
4800 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
4801 ULONGEST_MAX.
4802 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
4803
4804 2018-08-27 Tom Tromey <tom@tromey.com>
4805
4806 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
4807 CORE_ADDR_MAX.
4808 * mips-tdep.c (mips_deal_with_atomic_sequence)
4809 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
4810 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
4811 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
4812 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
4813 CORE_ADDR_MAX.
4814 * aarch64-tdep.c (aarch64_software_single_step): Use
4815 CORE_ADDR_MAX.
4816
4817 2018-08-27 Tom Tromey <tom@tromey.com>
4818
4819 * linespec.c (complete_linespec_component): Add cast to "char".
4820 * completer.c (completion_tracker::build_completion_result): Add
4821 cast to "char".
4822
4823 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
4824
4825 * solist.h (struct solist, struct target_so_ops): Fix
4826 indentation.
4827
4828 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
4829
4830 * ada-tasks.c (ada_task_info_s): Remove typedef.
4831 (DEF_VEC_O(ada_task_info_s)): Remove.
4832 (struct ada_tasks_inferior_data): Initialize fields.
4833 <task_list>: Make an std::vector.
4834 (get_ada_tasks_inferior_data): Allocate with new.
4835 (ada_get_task_number): Adjust.
4836 (get_task_number_from_id): Likewise.
4837 (valid_task_id): Likewise.
4838 (ada_get_task_info_from_ptid): Likewise.
4839 (iterate_over_live_ada_tasks): Likewise.
4840 (add_ada_task): Likewise.
4841 (read_known_tasks): Likewise.
4842 (ada_build_task_list): Likewise.
4843 (print_ada_task_info): Likewise.
4844 (info_task): Likewise.
4845 (task_command_1): Likewise.
4846
4847 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
4848
4849 * ada-lang.c (add_angle_brackets): Return std::string.
4850
4851 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
4852
4853 * python/py-threadevent.c (py_get_event_thread): Initialize
4854 pythread.
4855
4856 2018-08-24 Pedro Alves <palves@redhat.com>
4857
4858 * python/py-bpevent.c (create_breakpoint_event_object): Use
4859 copy-initialization.
4860 * python/py-continueevent.c (emit_continue_event): Use
4861 copy-initialization.
4862 * python/py-exitedevent.c (create_exited_event_object): Return a
4863 gdbpy_ref<>.
4864 (emit_exited_event): Use copy-initialization.
4865 * python/py-inferior.c (python_new_inferior)
4866 (python_inferior_deleted, add_thread_object): Use
4867 copy-initialization.
4868 * python/py-infevents.c (create_inferior_call_event_object)
4869 (create_register_changed_event_object)
4870 (create_memory_changed_event_object): Return a gdbpy_ref<>.
4871 (emit_inferior_call_event, emit_memory_changed_event)
4872 (emit_register_changed_event): Use copy-initialization.
4873 * python/py-newobjfileevent.c (create_new_objfile_event_object):
4874 Return a gdbpy_ref<>.
4875 (emit_new_objfile_event): Use copy-initialization.
4876 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
4877 (emit_clear_objfiles_event): Use copy-initialization.
4878 * python/py-signalevent.c (create_signal_event_object): Use
4879 copy-initialization.
4880 * python/py-threadevent.c (create_thread_event_object): Use
4881 copy-initialization.
4882
4883 2018-08-24 Pedro Alves <palves@redhat.com>
4884 Simon Marchi <simon.marchi@ericsson.com>
4885
4886 PR gdb/23379
4887 * python/py-continueevent.c: Include "gdbthread.h".
4888 (create_continue_event_object): Add intro comment. Add 'ptid'
4889 parameter. Use it to find thread to pass to
4890 create_thread_event_object.
4891 (emit_continue_event): Pass PTID down to
4892 create_continue_event_object.
4893 * python/py-event.h (py_get_event_thread): Declare.
4894 (create_thread_event_object): Remove default from 'thread'
4895 parameter.
4896 * python/py-stopevent.c (create_stop_event_object): Use
4897 py_get_event_thread.
4898 * python/py-threadevent.c (get_event_thread): Rename to ...
4899 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
4900 and use it to find the thread.
4901 (create_thread_event_object): Assert that THREAD isn't null.
4902 Don't find the event thread here.
4903
4904 2018-08-23 Kevin Buettner <kevinb@redhat.com>
4905
4906 * block.h (blockrange, blockranges): New struct declarations.
4907 (struct block): Add new field named `ranges'.
4908 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
4909 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
4910 macros for accessing ranges in struct block.
4911 (make_blockranges): New declaration.
4912 block.c (make_blockranges): New function.
4913 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
4914 for block.
4915 * symtab.h (find_pc_partial_function): Add new parameter `block'.
4916 * blockframe.c (cache_pc_function_block): New static global.
4917 (clear_pc_function_cache): Clear cache_pc_function_block.
4918 (find_pc_partial_function): Move comment to symtab.h. Add
4919 support for non-contiguous blocks.
4920 * cli/cli-cmds.c (block.h): Include.
4921 (print_disassembly): Handle printing of non-contiguous blocks.
4922 (disassemble_current_function): Likewise.
4923 (disassemble_command): Likewise.
4924
4925 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
4926 BLOCK_START.
4927 * blockframe.c (get_pc_function_start): Likewise.
4928 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
4929 (gcc_symbol_address): Likewise.
4930 * compile/compile-object-run.c (compile_object_run): Likewise.
4931 * compile/compile.c (get_expr_block_and_pc): Likewise.
4932 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
4933 (func_addr_to_tail_call_list): Likewise.
4934 * findvar.c (default_read_var_value): Likewise.
4935 * inline-frame.c (inline_frame_this_id): Likewise.
4936 (skip-inline_frames): Likewise.
4937 * infcmd.c (until_next_command): Likewise.
4938 * linespec.c (convert_linespec_to_sals): Likewise.
4939 * parse.c (parse_exp_in_context_1): Likewise.
4940 * printcmd.c (build_address_symbolic): likewise.
4941 (info_address_command): Likewise.
4942 symtab.c (find_function_start_sal): Likewise.
4943 (skip_prologue_sal): Likewise.
4944 (find_function_alias_target): Likewise.
4945 (find_gnu_ifunc): Likewise.
4946 * stack.c (find_frame_funname): Likewise.
4947 * symtab.c (fixup_symbol_section): Likewise.
4948 (find_function_start_sal): Likewise.
4949 (skip_prologue_sal): Likewsie.
4950 (find_function_alias_target): Likewise.
4951 (find_gnu_ifunc): Likewise.
4952 * tracepoint.c (info_scope_command): Likewise.
4953 * value.c (value_fn_field): Likewise.
4954
4955 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
4956 in place of find_pc_partial_function.
4957 * blockframe.c (find_function_entry_range_from_pc): New function.
4958 * symtab.h (find_function_entry_range_from_pc): Declare and document.
4959 * objfiles.c (objfile_relocate1): Relocate start and end addresses
4960 for each range in a block.
4961
4962
4963 2018-08-23 Xavier Roirand <roirand@adacore.com>
4964
4965 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
4966 incrementation.
4967
4968 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
4969
4970 * solib-svr4.c (read_program_headers_from_bfd): Return
4971 gdb::optional<gdb::byte_vector>.
4972 (svr4_exec_displacement): Adjust.
4973
4974 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
4975
4976 * solib-svr4.c (read_program_header): Return
4977 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
4978 (find_program_interpreter): Return
4979 gdb::optional<gdb::byte_vector>.
4980 (scan_dyntag_auxv): Adjust.
4981 (enable_break): Adjust.
4982 (svr4_exec_displacement): Adjust.
4983
4984 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
4985
4986 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
4987 * inf-child.c (inf_child_target::terminal_save_inferior): New.
4988
4989 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
4990
4991 * guile/scm-string.c (gdbscm_scm_from_printf): Use
4992 string_vprintf.
4993 * guile/scm-utils.c (gdbscm_printf): Likewise.
4994 * serial.c (serial_printf): Likewise.
4995 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
4996
4997 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
4998
4999 * stack.c (print_frame): Print frame architecture when printing on
5000 an MI output.
5001 * NEWS: Mention new "arch" attribute in frame output.
5002
5003 2018-08-21 Alan Hayward <alan.hayward@arm.com>
5004
5005 * arch/aarch64.h (aarch64_regnum): Update comment.
5006
5007 2018-08-21 Alan Hayward <alan.hayward@arm.com>
5008
5009 * NEWS: Add SVE to 8.2 section.
5010
5011 2018-08-21 Pedro Alves <palves@redhat.com>
5012
5013 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
5014 out from gdbscm_parse_function_args.
5015 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
5016 gdbscm_parse_function_args_1.
5017
5018 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
5019
5020 PR gdb/17816
5021 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
5022 operator.
5023
5024 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
5025
5026 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
5027
5028 2018-08-19 Michael Spang <spang@google.com>
5029
5030 PR gdb/11786
5031 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
5032 for PT_TLS segments.
5033
5034 2018-08-18 Kevin Buettner <kevinb@redhat.com>
5035
5036 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
5037 dwarf_variable_value.
5038 * dwarf2-frame.c (class dwarf_expr_executor):
5039 Add override for dwarf_variable_value.
5040 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
5041 (class symbol_needs_eval_context): Likewise.
5042 (indirect_synthetic_pointer): Add forward declaration.
5043 (sect_variable_value): New function.
5044 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
5045 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
5046 for DW_OP_GNU_variable_value.
5047
5048 2018-08-16 Tom Tromey <tom@tromey.com>
5049
5050 * top.c (read_command_file): Update.
5051 (command_line_input): Remove "repeat" argument.
5052 * ada-lang.c (get_selections): Update.
5053 * linespec.c (decode_line_2): Update.
5054 * defs.h (command_line_input): Remove argument.
5055 * cli/cli-script.c (read_next_line): Update.
5056 * python/py-gdb-readline.c: Update.
5057
5058 2018-08-17 Tom Tromey <tom@tromey.com>
5059
5060 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
5061 command_line_input.
5062
5063 2018-08-15 Tom Tromey <tom@tromey.com>
5064
5065 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
5066
5067 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
5068
5069 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
5070 If used, use find_pc_partial_function to find address range
5071 to disassemble.
5072 * mi/mi-main.c (mi_cmd_list_features): Report
5073 "data-disassemble-a-option" feature.
5074 * NEWS: Mention new -data-disassemble option -a.
5075
5076 2018-08-13 Tom Tromey <tom@tromey.com>
5077
5078 * common/common-defs.h (_FORTIFY_SOURCE): Define.
5079
5080 2018-08-13 Alan Hayward <alan.hayward@arm.com>
5081
5082 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
5083 (aarch64_linux_collect_sve_regset): Likewise.
5084 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
5085 * regcache.h (regcache_map_entry_size): New function.
5086
5087 2018-08-13 Alan Hayward <alan.hayward@arm.com>
5088
5089 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
5090 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
5091 (SVE_HEADER_VL_LENGTH): Likewise.
5092 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
5093 (SVE_HEADER_FLAGS_LENGTH): Likewise.
5094 (SVE_HEADER_RESERVED_LENGTH): Likewise.
5095 (SVE_HEADER_SIZE_OFFSET): Likewise.
5096 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
5097 (SVE_HEADER_VL_OFFSET): Likewise.
5098 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
5099 (SVE_HEADER_FLAGS_OFFSET): Likewise.
5100 (SVE_HEADER_RESERVED_OFFSET): Likewise.
5101 (SVE_HEADER_SIZE): Likewise.
5102 (aarch64_linux_core_read_vq): Add function.
5103 (aarch64_linux_core_read_description): Check for SVE section.
5104
5105 2018-08-13 Alan Hayward <alan.hayward@arm.com>
5106
5107 * aarch64-fbsd-tdep.c
5108 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
5109 collect_size.
5110 * aarch64-linux-tdep.c
5111 (aarch64_linux_iterate_over_regset_sections): Likewise.
5112 * alpha-linux-tdep.c
5113 (alpha_linux_iterate_over_regset_sections):
5114 * alpha-nbsd-tdep.c
5115 (alphanbsd_iterate_over_regset_sections): Likewise.
5116 * amd64-fbsd-tdep.c
5117 (amd64fbsd_iterate_over_regset_sections): Likewise.
5118 * amd64-linux-tdep.c
5119 (amd64_linux_iterate_over_regset_sections): Likewise.
5120 * arm-bsd-tdep.c
5121 (armbsd_iterate_over_regset_sections): Likewise.
5122 * arm-fbsd-tdep.c
5123 (arm_fbsd_iterate_over_regset_sections): Likewise.
5124 * arm-linux-tdep.c
5125 (arm_linux_iterate_over_regset_sections): Likewise.
5126 * corelow.c (get_core_registers_cb): Likewise.
5127 (core_target::fetch_registers): Likewise.
5128 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
5129 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
5130 * gdbarch.h (void): Regenerate.
5131 * gdbarch.sh: Add supply_size and collect_size.
5132 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
5133 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
5134 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
5135 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
5136 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
5137 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
5138 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
5139 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
5140 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
5141 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
5142 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
5143 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
5144 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
5145 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
5146 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections):
5147 Likewise.
5148 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
5149 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
5150 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
5151 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
5152 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
5153 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
5154 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections):
5155 Likewise.
5156 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
5157 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
5158 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
5159 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
5160 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
5161 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
5162 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
5163 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
5164
5165 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
5166
5167 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
5168 with string_printf.
5169
5170 2018-08-10 Keith Seitz <keiths@redhat.com>
5171
5172 * compile/compile-c-support.c (add_code_header, add_code_footer):
5173 Move into policy class.
5174 (c_push_user_expression, pop_user_expression_nop)
5175 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
5176 (compile_program): New host class.
5177 (c_compile_program): New typedef.
5178 (c_compute_porgram): Use c_compile_program.
5179
5180 2018-08-10 Keith Seitz <keiths@redhat.com>
5181
5182 * compile/compile-internal.h (compile_instance::~compile_instance):
5183 Remove calls to htab_delete.
5184 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
5185 * compile.c (compile_instance::compile_instance): Initialize
5186 htab unique pointers.
5187 (compile_instance::get_cached_type, compile_instance::insert_type)
5188 (compile_instance::error_symbol_once): Update for unique_ptr.
5189
5190 2018-08-10 Keith Seitz <keiths@redhat.com>
5191
5192 * compile/compile-c-symbols.c (struct symbol_error)
5193 (hash_symbol_error, eq_symbol_error, del_symbol_error)
5194 (compile_instance::insert_symbol_error)
5195 (compile_instance::error_symbol_once): Move to ...
5196 * compile/compile.c: ... here.
5197
5198 2018-08-10 Keith Seitz <keiths@redhat.com>
5199
5200 * compile/compile-c-support.c (c_get_compile_context): Use `new'
5201 instead of `new_compile_instance'.
5202 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
5203 Update description.
5204 If the symbol error map is not initialized, create it.
5205 (generate_c_for_for_one_symbol): Do not check/initialize
5206 the symbol error map.
5207 * compile/compile-c-types.c (compile_c_instance): Make a class.
5208 Update all callers.
5209 (compile_instance::compile_instance): Initialize the type cache.
5210 (get_cached_type): New function.
5211 (insert_type): Update description.
5212 (compile_c_instance::m_default_cflags): Define.
5213 (convert_type): Update description. Use get_cached_type.
5214 (delete_instance): Moved to destructor.
5215 (new_compile_instance): Moved to constructor.
5216 * compile/compile-c.h (compile_c_instance): Make class inheriting
5217 from compile_instance.
5218 <base>: Remove field.
5219 <type_map, symbol_err_map>: Move to base class.
5220 <c_plugin>: Rename to `m_plugin' and remove pointer type.
5221 * compile/compile-internal.h (compile_instance): Make class.
5222 <type_map_t, symbol_err_map_t>: Define.
5223 <fe>: Rename to `m_gcc_fe'.
5224 <scope, block, gcc_target_options>: Add `m_' prefix.
5225 <m_type_map, m_symbol_err_map>: New fields, moved from
5226 compile_c_instance.
5227 <destroy>: Remove.
5228 (convert_type, new_compile_instance): Remove.
5229 * compile/compile.c (cleanup_compile_instance): Remove.
5230 (compile_to_object): Use unique_ptr to eliminate cleanups.
5231 (compile_instance::set_print_callback, compile_instance::version)
5232 (compile_instance::set_verbose)
5233 (compile_instance::set_driver_filename)
5234 (compile_instance::set_triplet_regexp)
5235 (compile_instance::set_arguments)
5236 (compile_instance::set_source_file)
5237 (compile_instance::compile): Define.
5238
5239 2018-08-10 Keith Seitz <keiths@redhat.com>
5240
5241 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
5242 * compile/compile-c-types.c: Define GCC_METHODN macros and include
5243 gcc-c-fe.def to define C plugin.
5244 (delete_instance): Delete `c_plugin'.
5245 (new_compile_instance): Initialize `c_plugin'.
5246 * compile/compile-c.h: Include gcc_c_plugin.h.
5247 (struct compile_c_instance) <c_plugin>: New member.
5248 * gcc-c-plugin.h: New file.
5249 Update all callers with API change.
5250
5251 2018-08-10 Keith Seitz <keiths@redhat.com>
5252
5253 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
5254 (HFILES_NO_SRCDIR): ... to here.
5255 Add compile-internal.h and compile-c.h.
5256 * compile/compile-c-support.c: Include compile-c.h.
5257 * compile/compile-c-symbols.c: Include compile-c.h.
5258 (generate_c_for_variable_locations): Update comment.
5259 * compile/compile-c-types.c: Include compile-c.h.
5260 * compile/compile-c.h: New file -- moved C language declarations
5261 from other files here.
5262 * compile/compile-internal.h: Do not include hashtab.h or
5263 common/enum-flags.h.
5264 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
5265 (gcc_convert_symbol, gcc_symbol_address)
5266 (generate_c_for_variable_locations, c_get_mode_for_size)
5267 (c_get_range_decl_name): Definitions moved to compile-c.h.
5268 * compile/compile-loc2c.c: Include compile-c.h.
5269
5270 2018-08-10 Keith Seitz <keiths@redhat.com>
5271
5272 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
5273 (c_symbol_substitution_name): ... this.
5274 Update all callers.
5275
5276 2018-08-10 Keith Seitz <keiths@redhat.com>
5277
5278 * compile/compile-c-support.c (c_compute_program): Use
5279 unique_xmalloc_ptr to eliminate cleanup.
5280 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
5281 Return a unique_xmalloc_ptr and eliminate cleanup.
5282 * compile/compile-internal.h (generate_c_for_variable_locations):
5283 Return unique_xmalloc_ptr and update description.
5284
5285 2018-08-10 Alan Hayward <alan.hayward@arm.com>
5286
5287 * corelow.c (core_target::get_core_register_section): Rename
5288 min_size to section_min_size.
5289
5290 2018-08-09 Jim Wilson <jimw@sifive.com>
5291
5292 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
5293 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
5294 * NEWS: Mention new GNU/Linux RISC-V target.
5295 * configure.host: Add riscv*-*-linux*.
5296 * configure.nat: Add riscv*.
5297 * configure.tgt: Add riscv*-*-linux*.
5298 * riscv-linux-nat.c: New file.
5299 * riscv-linux-tdep.c: New file.
5300
5301 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
5302
5303 * infrun.c (resume): Make static, add forward declaration.
5304 (proceed): Update header comment.
5305 * infrun.h (resume): Delete declaration.
5306
5307 2018-08-09 Tom Tromey <tom@tromey.com>
5308
5309 * riscv-tdep.h: Minor formatting fixes.
5310
5311 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
5312
5313 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
5314 * dwarf-index-cache.c (create_dir_and_check): Likewise.
5315 (test_mkdir_recursive): Likewise.
5316 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
5317
5318 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
5319
5320 * valarith.c (value_subscripted_rvalue): If an array is not in
5321 memory, and we don't know the upper bound, then we can't know that
5322 the requested element exists or not.
5323
5324 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
5325
5326 * target.c (str_comma_list_concat_elem): Fix typo in comment.
5327 (target_options_to_string): Add comment.
5328
5329 2018-08-08 Tom Tromey <tom@tromey.com>
5330
5331 * unittests/scoped_mmap-selftests.c: Check result of "write".
5332
5333 2018-08-08 Jim Wilson <jimw@sifive.com>
5334
5335 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
5336 (decode_register_index_short): New.
5337 (decode_j_type_insn, decode_cj_type_insn): New.
5338 (decode_b_type_insn, decode_cb_type_insn): New.
5339 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
5340 local xlen. Check xlen when decoding ambiguous compressed insns. In
5341 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
5342 is_c_sw_insn instead of is_sw_insn.
5343 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
5344 (riscv_software_single_step): New.
5345 * riscv-tdep.h (riscv_software_single_step): Declare.
5346
5347 * riscv-tdep.c (riscv_isa_xlen): Drop static.
5348 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
5349
5350 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
5351
5352 PR gdb/18050:
5353 * target.c (dispose_inferior): Don't dispose of inferiors that are
5354 already killed.
5355
5356 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
5357
5358 * remote.c (remote_target::download_tracepoint): Change char* to
5359 const char*.
5360
5361 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
5362
5363 * target.h (target_options_to_string): Return an std::string.
5364 * target.c (str_comma_list_concat_elem): Return void, use
5365 std::string.
5366 (do_option): Likewise.
5367 (target_options_to_string): Return an std::string.
5368 * linux-nat.c (linux_nat_target::wait): Adjust.
5369 * target-debug.h (target_debug_print_options): Adjust.
5370
5371 2018-08-07 Tom Tromey <tom@tromey.com>
5372
5373 * Makefile.in (CPPFLAGS): New variable.
5374 (INTERNAL_CPPFLAGS): Use it.
5375
5376 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5377
5378 * NEWS: Mention the index cache.
5379
5380 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5381
5382 * common/pathstuff.h (get_standard_cache_dir): New.
5383 * common/pathstuff.c (get_standard_cache_dir): New.
5384 * build-id.h (build_id_to_string): New.
5385 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
5386 DEBUG_STR_SUFFIX): Move to here.
5387 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
5388 DEBUG_STR_SUFFIX): Move from there.
5389 (write_psymtabs_to_index): Make non-static, add basename
5390 parameter. Write to temporary files, rename when done.
5391 (save_gdb_index_command): Adjust call to
5392 write_psymtabs_to_index.
5393 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
5394 field.
5395 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
5396 (get_gdb_index_contents_from_cache): New.
5397 (get_gdb_index_contents_from_cache_dwz): New.
5398 (dwarf2_initialize_objfile): Read index from cache.
5399 (dwarf2_build_psymtabs): Save to index.
5400 * dwarf-index-cache.h: New file.
5401 * dwarf-index-cache.c: New file.
5402 * dwarf-index-write.h: New file.
5403
5404 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5405
5406 * gnulib/aclocal.m4: Re-generate.
5407 * gnulib/config.in: Re-generate.
5408 * gnulib/configure: Re-generate.
5409 * gnulib/import/Makefile.am: Re-generate.
5410 * gnulib/import/Makefile.in: Re-generate.
5411 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
5412 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
5413 * gnulib/import/m4/mkdir.m4: New file.
5414 * gnulib/import/mkdir.c: New file.
5415 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
5416 module.
5417
5418 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5419
5420 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
5421 * common/scoped_mmap.c: New file.
5422 * common/scoped_mmap.h (destroy): New method.
5423 (~scoped_mmap, reset): Use destroy.
5424 (scoped_mmap): New move constructor.
5425 (mmap_file): New declaration.
5426 * unittests/scoped_mmap-selftests.c (test_normal,
5427 test_invalid_filename, run_tests): New functions.
5428 (_initialize_scoped_mmap_selftests): Register selftest.
5429
5430 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5431
5432 * dwarf2read.c (read_gdb_index_from_section): Rename to...
5433 (read_gdb_index_from_buffer): ... this. Remove section
5434 parameter, add buffer parameter.
5435 (get_gdb_index_contents_ftype,
5436 get_gdb_index_contents_dwz_ftype): New typedefs.
5437 (dwarf2_read_gdb_index): Add callback parameters to get the
5438 index contents.
5439 (get_gdb_index_contents_from_section): New.
5440 (dwarf2_initialize_objfile): Update call to
5441 dwarf2_read_gdb_index.
5442
5443 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5444
5445 * common/filestuff.h (gdb_fopen_cloexec): New overload.
5446 (gdb_open_cloexec): Likewise.
5447 * nat/linux-osdata.c (command_from_pid): Use string_printf.
5448 (commandline_from_pid): Likewise.
5449 (linux_xfer_osdata_threads): Likewise.
5450 (linux_xfer_osdata_fds): Likewise.
5451 * ada-lang.c (is_package_name): Likewise.
5452 * auxv.c (procfs_xfer_auxv): Likewise.
5453 * breakpoint.c (print_one_breakpoint_location): Use
5454 uiout::field_fmt.
5455 (print_one_catch_solib): Use string_printf.
5456 * coff-pe-read.c (add_pe_exported_sym): Likewise.
5457 (add_pe_forwarded_sym): Likewise.
5458 * dwarf2read.c (create_type_unit_group): Likewise.
5459 (build_error_marker_type): Likewise.
5460 * infcall.c (get_function_name): Likewise.
5461 * valprint.c (print_converted_chars_to_obstack): Likewise.
5462 * xtensa-tdep.c (xtensa_register_type): Likewise.
5463
5464 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
5465
5466 * remote.c (remote_target::download_tracepoint): Fix format
5467 string errors.
5468
5469 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5470
5471 * tracefile.c: Include common/byte-vector.h.
5472 (trace_save): Change type of buf to gdb::byte_vector. Initialize
5473 with trace_regblock_size if needed. Update uses of buf.
5474
5475 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5476
5477 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
5478 std::vector<unsigned char>.
5479 * tracepoint.c (collection_list::collection_list): Remove
5480 m_regs_mask initializer from initializer list. Resize
5481 m_regs_mask using the largest remote register number.
5482 (collection_list::add_remote_register): Remove size check on
5483 m_regs_mask. Use at to access element.
5484 (collection_list::stringify): Change type of temp_buf to
5485 gdb::char_vector. Update uses of temp_buf. Resize if needed to
5486 stringify the register mask. Use pack_hex_byte for the register
5487 mask.
5488
5489 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5490
5491 * tracepoint.h (class collection_list) <add_register>: Remove.
5492 <add_remote_register, add_ax_registers, add_local_register>:
5493 Declare.
5494 <add_memrange>: Add scope parameter.
5495 * tracepoint.c (encode_actions_1): Likewise.
5496 (collection_list::add_register): Rename to ...
5497 (collection_list::add_remote_register): ... this. Update
5498 comment.
5499 (collection_list::add_ax_registers, add_local_register): New
5500 methods.
5501 (collection_list::add_memrange): Add scope parameter. Call
5502 add_local_register instead of add_register.
5503 (finalize_tracepoint_aexpr): New function.
5504 (collection_list::collect_symbol): Update calls to add_memrange.
5505 Call add_local_register instead of add_register. Call
5506 add_ax_registers. Call finalize_tracepoint_aexpr.
5507 (encode_actions_1): Get remote regnos for $reg action. Call
5508 add_remote_register, add_ax_registers, and add_local_register.
5509 Update call to add_memrange. Call finalize_tracepoint_aexpr.
5510 (validate_actionline): Call finalize_tracepoint_aexpr.
5511
5512 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5513
5514 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
5515 Replace array buf with gdb::char_vector buf, of size
5516 get_remote_packet_size (). Replace references to buf and
5517 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
5518 and xsnprintf with snprintf. Raise errors if the buffer is too
5519 small.
5520
5521 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5522
5523 * remote.c (remote_target::download_tracepoint): Fix the has_more
5524 predicate in the QTDP action list iteration.
5525
5526 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5527
5528 * remote.c (remote_target::download_tracepoint): Fix indentation
5529 in for block.
5530
5531 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5532
5533 * proc-api.c (_initialize_proc_api): Remove c, unused.
5534 * procfs.c (procfs_init_inferior): Remove signals, unused.
5535 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
5536 unused.
5537
5538 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
5539 Andrew Burgess <andrew.burgess@embecosm.com>
5540
5541 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
5542 'W_STOPCODE (0)' as this could be ambiguous.
5543
5544 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
5545
5546 * ser-tcp.c (net_open): Fix thinko when deciding whether to
5547 disable TCP's Nagle algorithm (use "ai_protocol" instead of
5548 "ai_socktype").
5549
5550 2018-08-02 Tom Tromey <tom@tromey.com>
5551
5552 PR symtab/16842.
5553 * dwarf2read.c (read_func_scope): Set symtab on template parameter
5554 symbols.
5555 (process_structure_scope): Likewise.
5556
5557 2018-08-02 Xavier Roirand <roirand@adacore.com>
5558
5559 PR gdb/22629:
5560 * darwin-nat.c (darwin_kill_inferior): Fix handling of
5561 kill inferior.
5562
5563 2018-08-02 Tom Tromey <tom@tromey.com>
5564
5565 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
5566 (darwin_suspend_inferior, darwin_resume_inferior)
5567 (darwin_decode_notify_message, darwin_resume_inferior_threads)
5568 (darwin_check_new_threads): Check result of get_darwin_inferior.
5569
5570 2018-07-31 Joel Brobecker <brobecker@adacore.com>
5571
5572 GDB 8.1.1 released.
5573
5574 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
5575
5576 * varobj.c (varobj_get_path_expr_parent): Report an error if
5577 parent is a dynamic varobj.
5578
5579 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
5580
5581 * gnulib/aclocal.m4: Re-generate.
5582 * gnulib/config.in: Re-generate.
5583 * gnulib/configure: Re-generate.
5584 * gnulib/import/Makefile.in: Re-generate.
5585 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
5586 * gnulib/import/m4/onceonly.m4: Re-generate.
5587
5588 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
5589
5590 * target-descriptions.c (struct xml_test_tdesc): New.
5591 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
5592 (record_xml_tdesc): Update.
5593 (maintenance_check_xml_descriptions): Update.
5594 * target-descriptions.h (record_xml_tdesc): Update comment.
5595
5596 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
5597
5598 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
5599 checking array bounds are defined.
5600
5601 2018-07-30 Tom Tromey <tom@tromey.com>
5602
5603 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
5604 irreflexivity violation.
5605
5606 2018-07-30 Tom Tromey <tom@tromey.com>
5607
5608 * cli/cli-decode.c (lookup_cmd): Remove lint code.
5609 * value.c (unpack_long): Remove lint code.
5610 * valops.c (value_ind): Remove lint code.
5611 * valarith.c (value_x_binop, value_x_unop, value_equal)
5612 (value_pos): Remove lint code.
5613
5614 2018-07-28 Tom de Vries <tdevries@suse.de>
5615
5616 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
5617 with undefined upper bound as <optimized out>.
5618
5619 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
5620
5621 * gcore.in: Rename variable "name" to "prefix". Expand
5622 "usage" text.
5623
5624 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
5625
5626 * windows-nat.c (windows_nat_target::create_inferior): Update to
5627 call close() in global namespace.
5628
5629 2018-07-26 Tom Tromey <tom@tromey.com>
5630
5631 * dwarf-index-write.c (add_address_entry): Don't add objfile
5632 offsets.
5633 * dbxread.c (find_stab_function): Rename from
5634 find_stab_function_addr. Return a bound_minimal_symbol.
5635 (read_dbx_symtab): Use raw_text_low, raw_text_high.
5636 Don't add objfile offsets.
5637 (end_psymtab): Use raw_text_low, raw_text_high,
5638 MSYMBOL_VALUE_RAW_ADDRESS.
5639 (read_ofile_symtab): Update.
5640 (process_one_symbol): Update.
5641 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
5642 offsets.
5643 (dw2_relocate): Remove.
5644 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
5645 searching addrmap.
5646 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
5647 Update.
5648 (process_psymtab_comp_unit_reader, add_partial_symbol)
5649 (add_partial_subprogram, dwarf2_ranges_read): Update.
5650 (load_partial_dies): Update.
5651 (add_address_entry): Don't add objfile offsets.
5652 (dwarf2_build_include_psymtabs): Update.
5653 (create_addrmap_from_aranges): Don't add objfile offsets.
5654 (dw2_find_pc_sect_compunit_symtab): Update.
5655 * mdebugread.c (parse_symbol): Don't add objfile offsets.
5656 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
5657 Update.
5658 (parse_partial_symbols): Don't add objfile offsets. Use
5659 raw_text_low, raw_text_high. Update.
5660 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
5661 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
5662 or call 'relocate' quick function. Clear psymbol_map.
5663 * psympriv.h (struct partial_symbol) <address>: Add section
5664 offset.
5665 <set_unrelocated_address>: Rename from set_address.
5666 <raw_text_low, raw_text_high>: New methods.
5667 <text_low, text_high>: Add objfile parameter.
5668 (add_psymbol_to_bcache): Add 'section' parameter. Call
5669 set_unrelocated_address.
5670 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
5671 (find_pc_psymbol): Update.
5672 (fixup_psymbol_section, relocate_psymtabs): Remove.
5673 (dump_psymtab, psym_functions): Update.
5674 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
5675 parameter.
5676 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
5677 (start_psymtab_common): Update.
5678 * symfile-debug.c (debug_qf_relocate): Remove.
5679 (debug_sym_quick_functions): Update.
5680 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
5681 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
5682 Update.
5683
5684 2018-07-26 Tom Tromey <tromey@redhat.com>
5685
5686 * dbxread.c (end_psymtab): Use text_high_valid and
5687 text_low_valid.
5688 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
5689 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
5690 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
5691 Update comment.
5692 <text_low_valid, text_high_valid>: New fields.
5693 <set_text_low, set_text_high>: Update.
5694 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
5695
5696 2018-07-26 Tom Tromey <tom@tromey.com>
5697
5698 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
5699 Update.
5700 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
5701 textlow and texthigh fields.
5702 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
5703 Update.
5704 * mdebugread.c (parse_lines, parse_partial_symbols)
5705 (psymtab_to_symtab_1): Update.
5706 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
5707 Rename fields. Update comment. Now private.
5708 <text_low, text_high, set_text_low, set_text_high>: New methods.
5709 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
5710 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
5711 (start_psymtab_common, maintenance_info_psymtabs)
5712 (maintenance_check_psymtabs): Update.
5713 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
5714 texthigh fields.
5715 (scan_xcoff_symtab): Update.
5716
5717 2018-07-26 Tom Tromey <tromey@redhat.com>
5718
5719 * psympriv.h (struct partial_symbol) <unrelocated_address,
5720 address, set_address>: New methods.
5721 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
5722 (fixup_psymbol_section, relocate_psymtabs): Update.
5723 (print_partial_symbols): Add 'objfile' parameter. Update.
5724 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
5725 Update.
5726
5727 2018-07-26 Tom Tromey <tom@tromey.com>
5728
5729 * dwarf-index-write.c (write_psymbols, debug_names::insert)
5730 (debug_names::write_psymbols): Update.
5731 * psympriv.h (struct partial_symbol): Derive from
5732 general_symbol_info.
5733 <obj_section>: New method.
5734 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
5735 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
5736 (find_pc_sect_psymbol, fixup_psymbol_section)
5737 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
5738 (print_partial_symbols, recursively_search_psymtabs)
5739 (compare_psymbols, psymbol_hash, psymbol_compare)
5740 (add_psymbol_to_bcache, maintenance_check_psymtabs)
5741 (psymbol_name_matches, psym_fill_psymbol_map): Update.
5742
5743 2018-07-26 Tom Tromey <tromey@redhat.com>
5744
5745 * dbxread.c (end_psymtab): Remove dead code.
5746
5747 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
5748
5749 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
5750 DWARF unwinders are disabled.
5751 * dwarf2-frame.c: Add dwarf2read.h include.
5752 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
5753 disabled.
5754 (dwarf2_frame_unwinders_enabled_p): Define.
5755 (show_dwarf_unwinders_enabled_p): New function.
5756 (_initialize_dwarf2_frame): Register switch to control DWARF
5757 unwinder use.
5758 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
5759 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
5760 (show_dwarf_cmdlist): Remove static keyword.
5761 * dwarf2read.h (set_dwarf_cmdlist): Declare.
5762 (show_dwarf_cmdlist): Declare.
5763 * NEWS: Document new feature.
5764
5765 2018-07-26 Tom de Vries <tdevries@suse.de>
5766
5767 PR breakpoints/23366
5768 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
5769
5770 2018-07-26 Tom de Vries <tdevries@suse.de>
5771
5772 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
5773 DW_AT_count can't be translated to a dynamic prop.
5774
5775 2018-07-25 Tom de Vries <tdevries@suse.de>
5776
5777 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
5778 try/catch.
5779
5780 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
5781
5782 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
5783
5784 2018-07-25 Joel Brobecker <brobecker@adacore.com>
5785
5786 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
5787
5788 2018-07-24 Keith Seitz <keiths@redhat.comt
5789
5790 PR symtab/23010
5791 * dwarf2read.c (dw2_add_symbol_to_list): New function.
5792 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
5793 instead of add_symbol_to_list.
5794 (read_file_scope): Call prepare_one_comp_unit before reading
5795 any other DIEs.
5796
5797 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
5798
5799 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
5800
5801 2018-07-24 Tom Tromey <tom@tromey.com>
5802
5803 * utils.c (malloc, realloc, free): Don't declare.
5804 * configure, config.in: Rebuild.
5805 * configure.ac: Don't check for declarations of free, malloc, or
5806 realloc.
5807
5808 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
5809
5810 * aarch64-linux-nat.c
5811 (aarch64_linux_nat_target::stopped_data_address): Remove unused
5812 variable.
5813 * arm-linux-nat.c (fetch_regs): Likewise.
5814 (store_regs): Likewise.
5815 (fetch_vfp_regs): Likewise.
5816 (store_vfp_regs): Likewise.
5817 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
5818 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
5819 (arm_linux_nat_target::insert_watchpoint): Likewise.
5820 (arm_linux_nat_target::remove_watchpoint): Likewise.
5821 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
5822 Likewise.
5823 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
5824 Likewise.
5825 * ppc-linux-nat.c (fetch_register): Likewise.
5826 (fetch_all_gp_regs): Likewise.
5827 (fetch_ppc_registers): Likewise.
5828 (store_all_gp_regs): Likewise.
5829 (store_ppc_registers): Likewise.
5830 (hwdebug_insert_point): Likewise.
5831 (can_use_watchpoint_cond_accel): Likewise.
5832 * remote-sim.c (gdb_os_write_stdout): Likewise.
5833
5834 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
5835 Tom Tromey <tom@tromey.com>
5836
5837 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
5838 test for it.
5839 * configure: Rebuild.
5840
5841 2018-07-22 Tom Tromey <tom@tromey.com>
5842
5843 * regformats/regdat.sh: Define xmltarget_${name} inside
5844 #ifndef IN_PROCESS_AGENT.
5845
5846 2018-07-22 Tom Tromey <tom@tromey.com>
5847
5848 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
5849
5850 2018-07-22 Tom Tromey <tom@tromey.com>
5851
5852 * symfile.c (reread_symbols): Notify iter, not objfile.
5853
5854 2018-07-22 Tom Tromey <tom@tromey.com>
5855
5856 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
5857 Use arch_ops.
5858 (ravenscar_thread_target::prepare_to_store): Likewise.
5859
5860 2018-07-22 Tom Tromey <tom@tromey.com>
5861
5862 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
5863 unused variable. Call value_fetch_lazy when needed.
5864 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
5865 Remove unused variable. Call value_fetch_lazy when needed.
5866
5867 2018-07-22 Tom Tromey <tom@tromey.com>
5868
5869 * m32c-tdep.c (mark_dma): Return void.
5870 (make_regs): Remove unused declarations.
5871
5872 2018-07-22 Tom Tromey <tom@tromey.com>
5873
5874 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
5875 cmdscm_get_valid_command_smob_arg_unsafe for effect.
5876 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
5877 bkscm_get_valid_block_smob_arg_unsafe for effect.
5878
5879 2018-07-22 Tom Tromey <tom@tromey.com>
5880
5881 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
5882 value_type.
5883
5884 2018-07-22 Tom Tromey <tom@tromey.com>
5885
5886 * windows-nat.c (saved_context): Conditionally define.
5887 * remote.c (remote_target::remote_btrace_maybe_reopen):
5888 Conditionally declare "warned".
5889 * inflow.c (sigquit_ours): Conditionally define.
5890 (new_tty): Move "tty" declaration inside #if.
5891 * guile/guile.c (guile_datadir): Conditionally define.
5892 * charset.c (set_be_le_names): Move some declarations inside #if.
5893 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
5894 #if.
5895 (parse_xml_btrace_conf): Likewise.
5896
5897 2018-07-22 Tom Tromey <tom@tromey.com>
5898
5899 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
5900
5901 2018-07-22 Tom Tromey <tom@tromey.com>
5902
5903 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
5904 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
5905 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
5906 * buildsym-legacy.c (get_macro_table): Remove unused variable.
5907 * stack.c (frame_apply_level_command): Remove unused variable.
5908 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
5909 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
5910 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
5911 unused variable.
5912 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
5913 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
5914 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
5915 variable.
5916 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
5917 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
5918 variable.
5919 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
5920 Remove unused variable.
5921 * cli/cli-script.c (recurse_read_control_structure): Remove unused
5922 variable.
5923 * common/tdesc.c (print_xml_feature::visit): Remove unused
5924 variable.
5925 * compile/compile-object-load.c (store_regs): Remove unused
5926 variables.
5927 * complaints.c (clear_complaints): Remove unused variable.
5928 * corelow.c (core_target_open): Remove unused variable.
5929 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
5930 variable.
5931 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
5932 variable.
5933 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
5934 variable.
5935 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
5936 variable.
5937 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
5938 variable.
5939 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
5940 variable.
5941 * ia64-tdep.c (examine_prologue): Remove unused variable.
5942 * infcall.c (run_inferior_call): Remove unused variable.
5943 * inferior.c (exit_inferior): Remove unused variable.
5944 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
5945 * linespec.c (decode_line_2): Remove unused variable.
5946 * linux-nat.c (super_close): Remove.
5947 * linux-tdep.c (linux_info_proc): Remove unused variable.
5948 * mi/mi-main.c (mi_execute_command): Remove unused variable.
5949 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
5950 Remove unused variable.
5951 * parse.c (find_minsym_type_and_address): Remove unused variable.
5952 * printcmd.c (info_symbol_command, printf_floating): Remove unused
5953 variable.
5954 * python/py-breakpoint.c (bppy_set_commands): Remove unused
5955 variable.
5956 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
5957 variables.
5958 * record-btrace.c (record_btrace_target::store_registers): Remove
5959 unused variable.
5960 (cmd_show_record_btrace_cpu): Remove unused variable.
5961 * riscv-tdep.c (riscv_register_reggroup_p)
5962 (riscv_push_dummy_call, riscv_return_value): Remove unused
5963 variable.
5964 * rust-exp.y (literal): Remove unused variable.
5965 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
5966 unused variable.
5967 <STRUCTOP_ANONYMOUS>: Likewise.
5968 * s390-linux-tdep.c (s390_linux_init_abi_31)
5969 (s390_linux_init_abi_64): Remove unused variable.
5970 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
5971 (file_select_thread, net_windows_open, _initialize_ser_windows):
5972 Remove unused variables.
5973 * symtab.c (find_pc_sect_line): Remove unused variable.
5974 * target-memory.c (compute_garbled_blocks): Remove unused
5975 variable.
5976 (target_write_memory_blocks): Remove unused variable.
5977 * target.c (target_stack::unpush): Remove unused variables.
5978 * tracepoint.c (start_tracing, all_tracepoint_actions)
5979 (merge_uploaded_trace_state_variables)
5980 (print_one_static_tracepoint_marker): Remove unused variable.
5981 * unittests/basic_string_view/element_access/char/1.cc (test01):
5982 Remove unused variable.
5983 * windows-nat.c (windows_continue, windows_add_all_dlls)
5984 (do_initial_windows_stuff, windows_nat_target::create_inferior):
5985 Remove unused variables.
5986
5987 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
5988
5989 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
5990 attr_profile in HAVE_ELF.
5991 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
5992 HAVE_ELF.
5993
5994 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
5995
5996 * frame.c (frame_register_unwind): Change parameter name.
5997 (frame_unwind_register): Likewise.
5998 (frame_unwind_register_value): Likewise.
5999 (frame_unwind_register_signed): Likewise.
6000 (frame_unwind_register_unsigned): Likewise.
6001 * frame.h (frame_register_unwind): Likewise.
6002 (frame_unwind_register): Likewise.
6003 (frame_unwind_register_value): Likewise.
6004 (frame_unwind_register_signed): Likewise.
6005 (frame_unwind_register_unsigned): Likewise.
6006 (frame_unwind_arch): Likewise.
6007
6008 2018-07-20 Maciej W. Rozycki <macro@mips.com>
6009
6010 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
6011 ISA maintenance.
6012
6013 2018-07-20 Maciej W. Rozycki <macro@mips.com>
6014
6015 * mips-linux-nat.c (mips_linux_nat_target::read_description):
6016 Call `get_ptrace_pid' rather than extracting the ptrace PID by
6017 hand.
6018
6019 2018-07-20 Keith Seitz <keiths@redhat.com>
6020
6021 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
6022 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
6023 m_compunit_symtab, m_language>: Add "m_" prefix.
6024 Update all uses.
6025 * buildsym.c: Update all uses.
6026
6027 2018-07-20 Tom Tromey <tom@tromey.com>
6028
6029 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
6030 * buildsym.h (record_line_ftype): Remove typedef.
6031
6032 2018-07-20 Tom Tromey <tom@tromey.com>
6033
6034 * buildsym-legacy.h (augment_type_symtab): Don't declare.
6035 (end_expandable_symtab): Likewise.
6036 (end_symtab_get_static_block): Likewise.
6037 (end_symtab_from_static_block): Likewise.
6038 * buildsym-legacy.c (augment_type_symtab): Remove.
6039 (end_expandable_symtab): Remove.
6040 (end_symtab_get_static_block): Remove.
6041 (end_symtab_from_static_block): Remove.
6042
6043 2018-07-20 Tom Tromey <tom@tromey.com>
6044
6045 * dwarf2read.c: Include buildsym.h.
6046 (struct dwarf2_cu) <builder>: New method.
6047 (fixup_go_packaging): Update.
6048 (process_full_comp_unit, process_full_type_unit): Update. Don't
6049 use scoped_free_pendings.
6050 (using_directives): Add "cu" parameter, remove "language".
6051 (read_import_statement, setup_type_unit_groups, )
6052 (read_func_scope, read_lexical_block_scope)
6053 (dwarf2_record_block_ranges, read_namespace): Update.
6054 (lnp_state_machine::lnp_state_machine): Add cu parameter.
6055 (lnp_state_machine::handle_end_sequence): Update.
6056 (class lnp_state_machine) <m_cu>: New member.
6057 <m_record_line_callback>: Remove.
6058 <m_currently_recording_lines>: New member.
6059 (lnp_state_machine::handle_set_file): Update.
6060 (noop_record_line): Remove.
6061 (dwarf_record_line_p): Add cu parameter.
6062 (dwarf_record_line_1, dwarf_finish_line): Likewise.
6063 (lnp_state_machine::record_line)
6064 (lnp_state_machine::lnp_state_machine)
6065 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
6066 (dwarf_decode_lines): Update.
6067 (dwarf2_start_subfile): Add cu parameter.
6068 (dwarf2_start_symtab, new_symbol): Update.
6069 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
6070 Remove dwarf2_per_objfile parameter.
6071 (dwarf_decode_macros): Update.
6072
6073 2018-07-20 Tom Tromey <tom@tromey.com>
6074
6075 * stabsread.c (define_symbol): Update.
6076 * buildsym-legacy.h (get_buildsym_compunit): Declare.
6077 * dwarf2read.c (new_symbol): Update.
6078 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
6079 * cp-namespace.c: Include buildsym.h.
6080 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
6081 * buildsym-legacy.c (get_buildsym_compunit): New function.
6082
6083 2018-07-20 Tom Tromey <tom@tromey.com>
6084
6085 * xcoffread.c: Include buildsym-legacy.h.
6086 * windows-nat.c: Include buildsym-legacy.h.
6087 * stabsread.c: Include buildsym-legacy.h.
6088 * mdebugread.c: Include buildsym-legacy.h.
6089 * buildsym-legacy.h: New file.
6090 * buildsym-legacy.c: New file, from buildsym.c.
6091 * go32-nat.c: Include buildsym-legacy.h.
6092 * dwarf2read.c: Include buildsym-legacy.h.
6093 * dbxread.c: Include buildsym-legacy.h.
6094 * cp-namespace.c: Include buildsym-legacy.h.
6095 * coffread.c: Include buildsym-legacy.h.
6096 * buildsym.h: Move some contents to buildsym-legacy.h.
6097 * buildsym.c: Include buildsym-legacy.h. Move many functions to
6098 buildsym-legacy.c.
6099 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
6100
6101 2018-07-20 Tom Tromey <tom@tromey.com>
6102
6103 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
6104 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
6105 (buildsym_compunit::buildsym_compunit)
6106 (buildsym_compunit::~buildsym_compunit)
6107 (buildsym_compunit::get_macro_table): Define.
6108
6109 2018-07-20 Tom Tromey <tom@tromey.com>
6110
6111 * buildsym.c (reset_symtab_globals): Remove.
6112 (buildsym_compunit::end_symtab_from_static_block): Update.
6113 (buildsym_compunit::augment_type_symtab): Update.
6114 (end_symtab_from_static_block): Call free_buildsym_compunit.
6115 (augment_type_symtab, end_symtab, end_expandable_symtab):
6116 Likewise.
6117
6118 2018-07-20 Tom Tromey <tom@tromey.com>
6119
6120 * arch-utils.c: Do not include buildsym.h.
6121 * mipsread.c: Do not include buildsym.h.
6122 * machoread.c: Do not include buildsym.h.
6123 * elfread.c: Do not include buildsym.h.
6124
6125 2018-07-20 Tom Tromey <tom@tromey.com>
6126
6127 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
6128 initialization.
6129 (buildsym_compunit): Add new constructor.
6130 (struct buildsym_compunit) <get_last_source_file, finish_block,
6131 record_block_range, start_subfile, patch_subfile_names,
6132 push_subfile, pop_subfile, record_line, get_compunit_symtab,
6133 set_last_source_start_addr, get_last_source_start_addr,
6134 get_local_using_directives, set_local_using_directives,
6135 get_global_using_directives, outermost_context_p,
6136 get_current_context_stack, get_context_stack_depth,
6137 get_current_subfile, get_local_symbols, get_file_symbols,
6138 get_global_symbols, record_debugformat, record_producer,
6139 push_context, pop_context, end_symtab_get_static_block,
6140 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
6141 New public methods.
6142 <record_pending_block, finish_block_internal, make_blockvector,
6143 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
6144 private methods.
6145 Update all users.
6146
6147 2018-05-22 Tom Tromey <tom@tromey.com>
6148
6149 * buildsym.c (record_pending_block): Move earlier. Remove objfile
6150 parameter.
6151 (finish_block_internal): Update.
6152
6153 2018-07-20 Tom Tromey <tom@tromey.com>
6154
6155 * buildsym.c (record_pending_block): Move earlier. Remove objfile
6156 parameter.
6157 (finish_block_internal): Update.
6158
6159 2018-07-20 Tom Tromey <tom@tromey.com>
6160
6161 * buildsym.h (EXTERN): Don't define or undef.
6162 * buildsym.c (EXTERN): Don't define.
6163
6164 2018-07-20 Tom Tromey <tom@tromey.com>
6165
6166 * buildsym.c: Remove TODO comment.
6167
6168 2018-07-20 Tom Tromey <tom@tromey.com>
6169
6170 * coffread.c (coff_symtab_read): Update.
6171 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
6172 (xcoff_new_init): Update.
6173 * mipsread.c (mipscoff_new_init): Update.
6174 * mdebugread.c (mdebug_build_psymtabs): Update.
6175 * elfread.c (elf_new_init): Update.
6176 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
6177 Update.
6178 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
6179 (coffstab_build_psymtabs, elfstab_build_psymtabs)
6180 (stabsect_build_psymtabs): Update.
6181 * buildsym.h (buildsym_init): Don't declare.
6182 * buildsym.c: Update comment.
6183 (prepare_for_building): Remove.
6184 (start_symtab, restart_symtab): Update.
6185 (reset_symtab_globals): Update comment.
6186 (buildsym_init): Remove.
6187
6188 2018-07-20 Tom Tromey <tom@tromey.com>
6189
6190 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
6191 * stabsread.c (patch_block_stabs, define_symbol, read_type)
6192 (read_enum_type, common_block_start, common_block_end)
6193 (cleanup_undefined_types_1, finish_global_stabs): Update.
6194 * mdebugread.c (psymtab_to_symtab_1): Update.
6195 * dwarf2read.c (fixup_go_packaging, read_func_scope)
6196 (read_lexical_block_scope, new_symbol): Update.
6197 * dbxread.c (process_one_symbol): Update.
6198 * coffread.c (coff_symtab_read, process_coff_symbol)
6199 (coff_read_enum_type): Update.
6200 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
6201 declare.
6202 (get_local_symbols, get_file_symbols, get_global_symbols): New
6203 functions.
6204 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
6205 m_global_symbols.
6206 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
6207 (~scoped_free_pendings): Update.
6208 (finish_block, prepare_for_building, reset_symtab_globals)
6209 (end_symtab_get_static_block, end_symtab_with_blockvector)
6210 (augment_type_symtab, push_context): Update.
6211 (get_local_symbols, get_file_symbols, get_global_symbols): New
6212 functions.
6213 (buildsym_init): Update.
6214
6215 2018-07-20 Tom Tromey <tom@tromey.com>
6216
6217 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
6218 (process_full_type_unit): Likewise.
6219 (dwarf2_start_symtab): Set list_in_scope.
6220
6221 2018-07-20 Tom Tromey <tom@tromey.com>
6222
6223 * dwarf2read.c (process_psymtab_comp_unit_reader)
6224 (build_type_psymtabs_reader): Do not set list_in_scope.
6225
6226 2018-07-20 Tom Tromey <tom@tromey.com>
6227
6228 * buildsym.c (free_pendings): Remove.
6229 (add_symbol_to_list, scoped_free_pendings)
6230 (finish_block_internal, buildsym_init): Update.
6231
6232 2018-07-20 Tom Tromey <tom@tromey.com>
6233
6234 * xcoffread.c (read_xcoff_symtab): Update.
6235 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
6236 Update.
6237 * dbxread.c (process_one_symbol): Update.
6238 * coffread.c (coff_symtab_read): Update.
6239 * buildsym.h (finish_block): Update.
6240 * buildsym.c (finish_block): Remove "listhead" argument.
6241 (end_symtab_get_static_block): Update.
6242
6243 2018-07-20 Tom Tromey <tom@tromey.com>
6244
6245 * buildsym.h (class scoped_free_pendings): Remove constructor.
6246 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
6247 method.
6248 <m_pending_block_obstack, m_pending_blocks>: New members.
6249 (pending_block_obstack, pending_blocks): Remove.
6250 (scoped_free_pendings::scoped_free_pendings): Default.
6251 (~scoped_free_pendings): Update.
6252 (free_pending_blocks): Remove.
6253 (finish_block_internal, record_pending_block, make_blockvector)
6254 (end_symtab_get_static_block, augment_type_symtab, push_context)
6255 (buildsym_init): Update.
6256
6257 2018-07-20 Tom Tromey <tom@tromey.com>
6258
6259 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
6260 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
6261 members.
6262 (pending_addrmap, pending_addrmap_obstack)
6263 (pending_addrmap_interesting): Remove.
6264 (scoped_free_pendings, record_block_range, make_blockvector)
6265 (prepare_for_building, reset_symtab_globals, buildsym_init):
6266 Update.
6267
6268 2018-07-20 Tom Tromey <tom@tromey.com>
6269
6270 * xcoffread.c (process_linenos): Update.
6271 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
6272 * mdebugread.c (psymtab_to_symtab_1): Update.
6273 * dwarf2read.c (setup_type_unit_groups)
6274 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
6275 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
6276 * dbxread.c (process_one_symbol): Update.
6277 * coffread.c (coff_symtab_read, enter_linenos)
6278 (process_coff_symbol): Update.
6279 * buildsym.h (current_subfile): Don't declare.
6280 (get_current_subfile): Declare.
6281 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
6282 member.
6283 (start_subfile, free_buildsym_compunit, push_subfile)
6284 (prepare_for_building, start_symtab): Update.
6285 (get_current_subfile): New function.
6286
6287 2018-07-20 Tom Tromey <tom@tromey.com>
6288
6289 * coffread.c (coff_symtab_read): Update.
6290 * xcoffread.c (read_xcoff_symtab): Update.
6291 * dwarf2read.c (new_symbol): Update.
6292 (read_func_scope, read_lexical_block_scope): Update.
6293 * dbxread.c (process_one_symbol): Update.
6294 * buildsym.h (context_stack, context_stack_depth): Don't declare.
6295 (outermost_context_p): Remove macro.
6296 (outermost_context_p, get_current_context_stack)
6297 (get_context_stack_depth): Declare.
6298 (pop_context): Return struct context_stack.
6299 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
6300 member.
6301 (context_stack_size): Remove.
6302 (INITIAL_CONTEXT_STACK_SIZE): Remove.
6303 (prepare_for_building, end_symtab_get_static_block)
6304 (augment_type_symtab, push_context): Update.
6305 (pop_context): Return struct context_stack.
6306 (outermost_context_p, get_current_context_stack)
6307 (get_context_stack_depth): New functions.
6308 (buildsym_init): Update.
6309
6310 2018-07-20 Tom Tromey <tom@tromey.com>
6311
6312 * rust-exp.y: Now a pure parser. Update all rules.
6313 (%union): Move earlier.
6314 (current_parser, work_obstack): Remove globals.
6315 (rust_parser, ~rust_parser): Update.
6316 (class rust_parser) <copy_name, concat3, crate_name, super_name,
6317 lex_character, lex_number, lex_string, lex_identifier,
6318 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
6319 convert_name, convert_params_to_expression,
6320 convert_ast_to_expression, ast_basic_type, ast_operation,
6321 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
6322 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
6323 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
6324 ast_array_type, ast_slice_type, ast_reference_type,
6325 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
6326 (rust_parse): Update.
6327 (rustyyerror, rustyylex): Add parser parameter.
6328 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
6329 (rust_lex_stringish_test, rust_lex_test_sequence)
6330 (rust_lex_test_trailing_dot, rust_lex_test_completion)
6331 (rust_lex_test_push_back, rust_lex_tests): Update.
6332
6333 2018-07-19 Pedro Alves <palves@redhat.com>
6334
6335 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
6336 gdb::unique_xmalloc_ptr.
6337 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
6338 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
6339 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
6340 copy-initialization.
6341 * guile/scm-pretty-print.c (ppscm_print_children): Use
6342 gdb::unique_xmalloc_ptr instead of cleanups.
6343 (gdbscm_apply_val_pretty_printer): Remove cleanups.
6344 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
6345 gdb::unique_xmalloc_ptr.
6346 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
6347 Adjust to use gdb::unique_xmalloc_ptr.
6348 * guile/scm-utils.c (extract_arg): Adjust.
6349 * guile/scm-value.c (gdbscm_value_field): Adjust to use
6350 gdb::unique_xmalloc_ptr instead of a cleanup.
6351
6352 2018-07-19 Tom Tromey <tom@tromey.com>
6353
6354 * utils.c (do_value_free_to_mark)
6355 (make_cleanup_value_free_to_mark): Remove.
6356 * utils.h (make_cleanup_value_free_to_mark): Remove.
6357
6358 2018-07-19 Pedro Alves <palves@redhat.com>
6359
6360 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
6361 forwarding reference.
6362
6363 2018-07-18 Pedro Alves <palves@redhat.com>
6364
6365 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
6366 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
6367 cleanup.
6368
6369 2018-07-18 Pedro Alves <palves@redhat.com>
6370
6371 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
6372 exceptions.
6373 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
6374 (gdbscm_wrap): New.
6375 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
6376 directly instead of a cleanup.
6377 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
6378 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
6379 (vlscm_binop_gdbthrow): New, factored out from ...
6380 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
6381 (vlscm_rich_compare): Use gdbscm_wrap.
6382 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
6383 instead of a cleanup.
6384 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
6385 cleanup.
6386 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
6387 Use xfree directly instead of a cleanup.
6388 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
6389 Adjust to use gdbscm_wrap and scoped_value_mark.
6390 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
6391 (gdbscm_value_address, gdbscm_value_dereference)
6392 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
6393 scoped_value_mark.
6394 (gdbscm_value_dynamic_type): Use scoped_value_mark.
6395 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
6396 scoped_value_mark.
6397 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
6398 gdbscm_wrap and scoped_value_mark.
6399 (gdbscm_value_to_string): Use xfree directly instead of a
6400 cleanup. Move 'buffer' unique_ptr to TRY scope.
6401 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
6402 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
6403 scoped_value_mark.
6404 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
6405 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
6406 scoped_value_mark.
6407 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
6408 gdbscm_wrap.
6409
6410 2018-07-18 Tom de Vries <tdevries@suse.de>
6411
6412 * findvar.c (default_read_var_value): Also resolve dynamic type for
6413 LOC_OPTIMIZED_OUT vars.
6414
6415 2018-07-18 Maciej W. Rozycki <macro@mips.com>
6416
6417 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
6418 decoding.
6419
6420 2018-07-17 Tom Tromey <tom@tromey.com>
6421
6422 * guile/scm-param.c (pascm_set_func, pascm_show_func)
6423 (compute_enum_list, pascm_set_param_value_x)
6424 (gdbscm_parameter_value): Update.
6425 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
6426 (gdbscm_scm_to_host_string): Update.
6427 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
6428 Update.
6429 * guile/scm-cmd.c (cmdscm_add_completion): Update.
6430 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
6431 * guile/scm-string.c (gdbscm_scm_to_string): Return
6432 unique_xmalloc_ptr.
6433 (gdbscm_scm_to_host_string): Likewise.
6434
6435 2018-07-17 Tom Tromey <tom@tromey.com>
6436
6437 * guile/guile.c (gdbscm_eval_from_control_command): Update.
6438 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
6439 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
6440 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
6441 unique_xmalloc_ptr.
6442
6443 2018-07-17 Tom Tromey <tom@tromey.com>
6444
6445 * guile/scm-param.c (pascm_signal_setshow_error): Update.
6446 * guile/guile-internal.h (gdbscm_exception_message_to_string):
6447 Update.
6448 * guile/scm-cmd.c (cmdscm_function): Update.
6449 * guile/scm-pretty-print.c
6450 (ppscm_print_exception_unless_memory_error): Update.
6451 * guile/scm-exception.c (gdbscm_exception_message_to_string):
6452 Return unique_xmalloc_ptr.
6453
6454 2018-07-17 Tom Tromey <tom@tromey.com>
6455
6456 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
6457 Use string_printf.
6458
6459 2018-07-17 Jim Wilson <jimw@sifive.com>
6460
6461 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
6462 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
6463 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
6464 unecessary braces after EF_RISCV_RVC test. Delete call to
6465 set_gdbarch_decr_pc_after_break.
6466
6467 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
6468 RISCV_LAST_FP_REGNUM + 1.
6469 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
6470
6471 2018-07-17 Tom Tromey <tom@tromey.com>
6472
6473 * configure.ac: Remove --disable-gdbcli.
6474 * configure: Rebuild.
6475 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
6476 (SUBDIR_CLI_CFLAGS): Remove.
6477 (SFILES): Use SUBDIR_CLI_SRCS.
6478 (COMMON_OBS): Use SUBDIR_CLI_OBS.
6479
6480 2018-07-17 Tom Tromey <tom@tromey.com>
6481
6482 PR gdb/18624:
6483 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
6484
6485 2018-07-16 Jim Wilson <jimw@sifive.com>
6486
6487 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
6488
6489 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6490
6491 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
6492 variable.
6493 (libunwind_frame_sniffer): Likewise.
6494 (libunwind_frame_prev_register): Likewise.
6495 (libunwind_sigtramp_frame_sniffer): Likewise.
6496 * ia64-tdep.c (ia64_access_reg): Likewise.
6497 (ia64_access_rse_reg): Likewise.
6498 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
6499 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
6500
6501 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6502
6503 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
6504
6505 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6506
6507 * remote-sim.c (gdbsim_target::close,
6508 gdbsim_target::mourn_inferior): Remove unused variables.
6509
6510 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
6511
6512 * ia64-tdep.c (ktab_buf): New global.
6513 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
6514 (get_kernel_table): Adjust.
6515
6516 2018-07-16 Tom Tromey <tom@tromey.com>
6517
6518 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
6519 * dwarf2read.c (using_directives, new_symbol): Use
6520 outermost_context_p.
6521 * dbxread.c (process_one_symbol): Use outermost_context_p.
6522 * coffread.c (coff_symtab_read): Use outermost_context_p.
6523
6524 2018-07-16 Tom Tromey <tom@tromey.com>
6525
6526 * dwarf2read.c (using_directives, read_func_scope)
6527 (read_lexical_block_scope): Update.
6528 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
6529 * buildsym.h (local_using_directives, global_using_directives):
6530 Don't declare.
6531 (get_local_using_directives, set_local_using_directives)
6532 (get_global_using_directives): Declare.
6533 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
6534 m_global_using_directives>: New members.
6535 (finish_block_internal, prepare_for_building)
6536 (reset_symtab_globals, end_symtab_get_static_block)
6537 (push_context): Update.
6538 (get_local_using_directives, set_local_using_directives)
6539 (get_global_using_directives): New functions.
6540 (buildsym_init): Update.
6541
6542 2018-07-16 Tom Tromey <tom@tromey.com>
6543
6544 * xcoffread.c (xcoff_initial_scan): Don't call
6545 free_pending_blocks.
6546 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
6547 * buildsym.h (class scoped_free_pendings): Add constructor.
6548 (free_pending_blocks): Don't declare.
6549 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
6550 (free_pending_blocks): Now static.
6551
6552 2018-07-16 Tom Tromey <tom@tromey.com>
6553
6554 * buildsym.h (push_subfile, pop_subfile): Update declarations.
6555 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
6556 member.
6557 (struct subfile_stack): Remove.
6558 (subfile_stack): Remove.
6559 (push_subfile, pop_subfile, buildsym_init): Update.
6560
6561 2018-07-16 Tom Tromey <tom@tromey.com>
6562
6563 * buildsym.c (push_subfile): Use gdb_assert.
6564 (pop_subfile): Use gdb_assert.
6565
6566 2018-07-16 Tom Tromey <tom@tromey.com>
6567
6568 * buildsym.h (merge_symbol_lists): Remove.
6569 * buildsym.c (merge_symbol_lists): Remove.
6570
6571 2018-07-16 Tom Tromey <tom@tromey.com>
6572
6573 * stabsread.c (scan_file_globals): Update comment.
6574 * stabsread.h (scan_file_globals): Move from buildsym.h.
6575 * buildsym.h (scan_file_globals): Move to stabsread.h.
6576
6577 2018-07-16 Tom Tromey <tom@tromey.com>
6578
6579 * xcoffread.c (xcoff_new_init): Update.
6580 * mipsread.c (mipscoff_new_init): Update.
6581 * mdebugread.c (mdebug_build_psymtabs): Update.
6582 * elfread.c (elf_new_init): Update.
6583 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
6584 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
6585 * buildsym.h (buildsym_new_init): Don't declare.
6586 * buildsym.c (buildsym_new_init): Remove.
6587
6588 2018-07-16 Tom Tromey <tom@tromey.com>
6589
6590 * stabsread.h (within_function): Move from buildsym.h.
6591 * stabsread.c (start_stabs): Clear within_function.
6592 * coffread.c (coff_start_symtab): Clear within_function.
6593 * buildsym.h (within_function): Move to stabsread.h.
6594 * buildsym.c (prepare_for_building): Update.
6595
6596 2018-07-16 Tom Tromey <tom@tromey.com>
6597
6598 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
6599 * dwarf2read.c (dwarf2_start_symtab): Don't set
6600 processing_gcc_compilation.
6601 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
6602
6603 2018-07-16 Tom Tromey <tom@tromey.com>
6604
6605 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
6606 (next_symbol_text_func): Move from buildsym.h.
6607 * stabsread.c (hashname): Move from buildsym.c.
6608 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
6609 (next_symbol_text_func, hashname): Move to stabsread.h.
6610 * buildsym.c: Don't include bcache.h
6611 (hashname): Move to stasbread.c.
6612
6613 2018-07-16 Tom Tromey <tom@tromey.com>
6614
6615 * buildsym.h (context_stack_size): Don't declare.
6616 * buildsym.c (context_stack_size): New global.
6617
6618 2018-07-16 Tom Tromey <tom@tromey.com>
6619
6620 * dbxread.c (processing_acc_compilation): New global.
6621 * buildsym.h (processing_acc_compilation): Don't declare.
6622
6623 2018-07-16 Tom Tromey <tom@tromey.com>
6624
6625 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
6626 * dbxread.c (read_ofile_symtab): Update.
6627 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
6628 * buildsym.h (last_source_start_addr): Remove.
6629 (set_last_source_start_addr, get_last_source_start_addr):
6630 Declare.
6631 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
6632 parameter.
6633 (struct buildsym_compunit) <m_last_source_start_addr>: New
6634 member.
6635 (prepare_for_building): Remove start_addr parameter.
6636 (start_symtab, restart_symtab, end_symtab_get_static_block)
6637 (end_symtab_with_blockvector): Update.
6638 (set_last_source_start_addr, get_last_source_start_addr): New
6639 functions.
6640
6641 2018-07-16 Tom Tromey <tom@tromey.com>
6642
6643 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
6644 member.
6645 (have_line_numbers): Remove.
6646 (record_line, prepare_for_building, end_symtab_get_static_block)
6647 (augment_type_symtab): Update.
6648
6649 2018-07-16 Tom Tromey <tom@tromey.com>
6650
6651 * buildsym.c (~buildsym_compunit): Free the macro table.
6652 (struct buildsym_compunit) <get_macro_table, release_macros>: New
6653 methods.
6654 <m_pending_macros>: New member.
6655 (pending_macros): Remove.
6656 (~scoped_free_pendings, get_macro_table, prepare_for_building)
6657 (reset_symtab_globals, end_symtab_get_static_block)
6658 (end_symtab_with_blockvector, augment_type_symtab)
6659 (buildsym_init): Update.
6660
6661 2018-07-16 Tom Tromey <tom@tromey.com>
6662
6663 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
6664 parameter.
6665 (buildsym_compunit::set_last_source_file): New method.
6666 <m_last_source_file>: New member.
6667 (prepare_for_building): Remove "name" parameter.
6668 (start_symtab, restart_symtab, reset_symtab_globals): Update.
6669 (last_source_file): Remove.
6670 (set_last_source_file, get_last_source_file): Update.
6671
6672 2018-07-16 Tom Tromey <tom@tromey.com>
6673
6674 * buildsym.c (prepare_for_building): Add assert.
6675
6676 2018-07-16 Tom Tromey <tom@tromey.com>
6677
6678 * buildsym.c (~buildsym_compunit): Update.
6679 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
6680 (start_subfile, patch_subfile_names)
6681 (end_symtab_with_blockvector): Update.
6682
6683 2018-07-16 Tom Tromey <tom@tromey.com>
6684
6685 * buildsym.c (struct buildsym_compunit): Add constructor,
6686 destructor, initializers.
6687 (start_buildsym_compunit): Remove.
6688 (free_buildsym_compunit): Use "delete".
6689 (start_symtab, restart_symtab): Use "new".
6690
6691 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
6692
6693 * symfile.c (set_objfile_default_section_offset): Remove struct
6694 keyword.
6695
6696 2018-07-14 Stafford Horne <shorne@gmail.com>
6697
6698 * (Responsible Maintainers): Add myself as or1k maintainer.
6699
6700 2018-07-13 Tom Tromey <tom@tromey.com>
6701
6702 * symfile.c (set_objfile_default_section_offset): Use extra braces
6703 around initializer.
6704
6705 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6706
6707 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
6708 non-branching basr.
6709
6710 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6711
6712 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6713 unittests/cli-utils-selftests.c
6714 * unittests/cli-utils-selftests.c: New file.
6715
6716 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6717
6718 * NEWS: Mention new commands. Mention change to 'thread apply'.
6719
6720 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6721
6722 * thread.c (thr_try_catch_cmd): New function.
6723 (thread_apply_all_command): Handle qcs flags.
6724 (thread_apply_command): Handle qcs flags.
6725 (taas_command): New function.
6726 (tfaas_command): New function.
6727 (_initialize_thread): Update to setup the new commands 'taas
6728 and 'tfaas'. Change doc string for 'thread apply'.
6729
6730 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6731
6732 * stack.c: (trailing_outermost_frame): New function, mostly
6733 extracted from backtrace_command_1.
6734 (leading_innermost_frame): New function.
6735 (backtrace_command_1): Update to call trailing_outermost_frame.
6736 (frame_apply_command_count): New function.
6737 (frame_apply_level_command): New function.
6738 (frame_apply_all_command): New function.
6739 (frame_apply_command): New function.
6740 (faas_command): New function.
6741 (frame_cmd_list): New variable.
6742 (_initialize_stack): Update to setup the new commands 'frame apply'
6743 and 'faas'.
6744
6745 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6746
6747 * cli-utils.c (number_or_range_parser::get_number): Only handle
6748 numbers or convenience var as numbers.
6749 (parse_flags): New function.
6750 (parse_flags_qcs): New function.
6751 (number_or_range_parser::finished): Ensure parsing end is detected
6752 before end of string.
6753 * cli-utils.h (parse_flags): New function.
6754 (parse_flags_qcs): New function.
6755 (number_or_range_parser): Remove m_finished bool.
6756 (number_or_range_parser::skip_range): Set m_in_range to false.
6757
6758 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
6759
6760 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
6761 on Windows.
6762
6763 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
6764 Jan Kratochvil <jan.kratochvil@redhat.com>
6765 Paul Fertser <fercerpav@gmail.com>
6766 Tsutomu Seki <sekiriki@gmail.com>
6767 Pedro Alves <palves@redhat.com>
6768
6769 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6770 'unittests/parse-connection-spec-selftests.c'.
6771 (COMMON_SFILES): Add 'common/netstuff.c'.
6772 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
6773 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
6774 * common/netstuff.c: New file.
6775 * common/netstuff.h: New file.
6776 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
6777 (wait_for_connect): Update comment. New parameter
6778 'gdb::optional<int> sock' instead of 'struct serial *scb'.
6779 Use 'sock' directly instead of 'scb->fd'.
6780 (try_connect): New function, with code from 'net_open'.
6781 (net_open): Rewrite main loop to deal with multiple
6782 sockets/addresses. Handle IPv6-style hostnames; implement
6783 support for IPv6 connections.
6784 * unittests/parse-connection-spec-selftests.c: New file.
6785
6786 2018-07-11 Pedro Alves <palves@redhat.com>
6787
6788 PR gdb/23377
6789 * remote.c (remote_target::remote_detach_pid): Call
6790 set_current_process.
6791
6792 2018-07-11 Pedro Alves <palves@redhat.com>
6793
6794 * h8300-tdep.c (h8300_gdbarch_init): Remove
6795 set_gdbarch_ecoff_reg_to_regnum calls.
6796
6797 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
6798
6799 PR c++/23373
6800 * c-typeprint.c (c_type_print_base_struct_union): Don't print
6801 offsets/sizes for static members of a class/struct.
6802
6803 2018-07-11 Alan Hayward <alan.hayward@arm.com>
6804
6805 * target-descriptions.c (tdesc_register_bitsize): Rename.
6806 * target-descriptions.h (tdesc_register_bitsize): Likewise.
6807 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
6808 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
6809
6810 2018-07-10 Tom Tromey <tom@tromey.com>
6811
6812 * breakpoint.c (moribund_locations): Now static and a
6813 std::vector.
6814 (breakpoint_init_inferior, moribund_breakpoint_here_p)
6815 (build_bpstat_chain, update_global_location_list)
6816 (breakpoint_retire_moribund): Update.
6817 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
6818 VEC.
6819
6820 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
6821
6822 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
6823 (riscv_register_reggroup_p): Use new function, remove unneeded
6824 parenthesis.
6825 (riscv_push_dummy_call): Extend assert to compare against xlen or
6826 flen based on register type.
6827
6828 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
6829
6830 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
6831
6832 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
6833
6834 * remote.c (show_hardware_watchpoint_limit): New function.
6835 (show_hardware_watchpoint_length_limit): New function.
6836 (show_hardware_breakpoint_limit): New function.
6837 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
6838 where appropriate, update help text.
6839
6840 2018-07-09 Tom Tromey <tom@tromey.com>
6841
6842 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
6843 (CLIBS): Don't mention NAT_CLIBS.
6844
6845 2018-07-09 Tom Tromey <tom@tromey.com>
6846
6847 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
6848 (LIBGDB_OBS, clean mostlyclean): Update.
6849 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
6850
6851 2018-07-09 Tom Tromey <tom@tromey.com>
6852
6853 * Makefile.in (%.c: %.y): Use ECHO_YACC.
6854 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
6855 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
6856
6857 2018-07-09 Tom Tromey <tom@tromey.com>
6858
6859 * Makefile.in (ALLDEPFILES): Remove exec.c.
6860 (COMMON_OBS): Remove exec.o.
6861 (COMMON_SFILES): Add exec.c.
6862
6863 2018-07-09 Tom Tromey <tom@tromey.com>
6864
6865 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
6866
6867 2018-07-09 Tom Tromey <tom@tromey.com>
6868
6869 * Makefile.in (clean mostlyclean): Remove stamp-version.
6870 (version.c): Depend on stamp-version.
6871 (stamp-version): New rule, from version.c rule.
6872
6873 2018-07-09 Tom Tromey <tom@tromey.com>
6874
6875 * Makefile.in (init.c): Depend on stamp-init.
6876 (stamp-init): New rule, from init.c rule.
6877 (clean mostlyclean): Remove stamp-init.
6878
6879 2018-07-09 Tom Tromey <tom@tromey.com>
6880
6881 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
6882 SUBDIR_GCC_COMPILE_SRCS.
6883
6884 2018-07-09 Tom Tromey <tom@tromey.com>
6885
6886 * Makefile.in (init.c): Remove some unused sed rules.
6887
6888 2018-07-09 Tom Tromey <tom@tromey.com>
6889
6890 * Makefile.in (TSOBS): Remove.
6891 (INIT_FILES): Update.
6892 (LIBGDB_OBS): Update.
6893 (COMMON_SFILES): Add inflow.c.
6894 (SFILES): Remove inflow.c.
6895
6896 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
6897
6898 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
6899
6900 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
6901
6902 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
6903 get_saveloc_name, is_signal_frame_name, step_name,
6904 init_remote_name, create_addr_space_name,
6905 destroy_addr_space_name, search_unwind_table_name,
6906 find_dyn_list_name): Constify.
6907
6908 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
6909
6910 * darwin-nat.c (darwin_pthread_kill): New function.
6911 (darwin_resume_thread): Use darwin_pthread_kill.
6912
6913 2018-07-05 Tom de Vries <tdevries@suse.de>
6914
6915 * macroexp.c (macro_buffer) <operator=>: New member function.
6916
6917 2018-07-04 Tom Tromey <tom@tromey.com>
6918
6919 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
6920
6921 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
6922
6923 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
6924 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
6925 * maint.c: Likewise.
6926 * top.c: Likewise.
6927
6928 2018-07-04 Joel Brobecker <brobecker@adacore.com>
6929
6930 * NEWS: Create a new section for the next release branch.
6931 Rename the section of the current branch, now that it has
6932 been cut.
6933
6934 2018-07-04 Joel Brobecker <brobecker@adacore.com>
6935
6936 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
6937 * version.in: Bump version to 8.2.50.DATE-git.
6938
6939 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
6940 Pedro Alves <palves@redhat.com>
6941
6942 * linux-nat.c (linux_init_ptrace): Rename to ...
6943 (linux_init_ptrace_procfs): ... this. Call
6944 linux_proc_init_warnings.
6945 (linux_nat_target::post_attach)
6946 (linux_nat_target::post_startup_inferior): Adjust.
6947 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
6948 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
6949
6950 2018-07-04 Tom de Vries <tdevries@suse.de>
6951
6952 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
6953 check ...
6954 (read_comp_unit_head): ... here.
6955
6956 2018-07-03 Tom Tromey <tom@tromey.com>
6957
6958 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
6959 (stop_tracing, tstatus_command)
6960 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
6961 (print_one_static_tracepoint_marker): Update.
6962 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
6963 std::vector.
6964 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
6965 VEC.
6966 (all_tracepoints, static_tracepoints_here): Return std::vector.
6967
6968 2018-07-03 Tom Tromey <tom@tromey.com>
6969
6970 * common/ptid.c (ptid_equal): Remove.
6971 * common/ptid.h (ptid_equal): Don't declare.
6972 * ada-tasks.c: Update.
6973 * breakpoint.c: Update.
6974 * common/agent.c: Update.
6975 * corelow.c: Update.
6976 * darwin-nat-info.c: Update.
6977 * darwin-nat.c: Update.
6978 * dcache.c: Update.
6979 * dtrace-probe.c: Update.
6980 * dummy-frame.c: Update.
6981 * fbsd-nat.c: Update.
6982 * frame.c: Update.
6983 * gdbthread.h: Update.
6984 * gnu-nat.c: Update.
6985 * go32-nat.c: Update.
6986 * inf-loop.c: Update.
6987 * inf-ptrace.c: Update.
6988 * infcall.c: Update.
6989 * infcmd.c: Update.
6990 * inflow.c: Update.
6991 * infrun.c: Update.
6992 * linux-fork.c: Update.
6993 * linux-nat.c: Update.
6994 * linux-thread-db.c: Update.
6995 * mi/mi-cmd-var.c: Update.
6996 * mi/mi-interp.c: Update.
6997 * mi/mi-main.c: Update.
6998 * nto-procfs.c: Update.
6999 * ppc-linux-tdep.c: Update.
7000 * procfs.c: Update.
7001 * python/py-inferior.c: Update.
7002 * python/py-record-btrace.c: Update.
7003 * python/py-record.c: Update.
7004 * ravenscar-thread.c: Update.
7005 * regcache.c: Update.
7006 * remote-sim.c: Update.
7007 * remote.c: Update.
7008 * sol-thread.c: Update.
7009 * solib.c: Update.
7010 * target.c: Update.
7011 * tui/tui-stack.c: Update.
7012 * varobj.c: Update.
7013 * windows-nat.c: Update.
7014 * windows-tdep.c: Update.
7015
7016 2018-07-03 Tom Tromey <tom@tromey.com>
7017
7018 * common/ptid.c (ptid_match): Remove.
7019 * common/ptid.h (ptid_match): Don't declare.
7020 * fbsd-nat.c: Update.
7021 * infcmd.c: Update.
7022 * infrun.c: Update.
7023 * linux-nat.c: Update.
7024 * record-btrace.c: Update.
7025 * regcache.c: Update.
7026 * remote.c: Update.
7027
7028 2018-07-03 Tom Tromey <tom@tromey.com>
7029
7030 * common/ptid.c (ptid_tid_p): Remove.
7031 * common/ptid.h (ptid_tid_p): Don't declare.
7032 * sol-thread.c: Update.
7033
7034 2018-07-03 Tom Tromey <tom@tromey.com>
7035
7036 * common/ptid.c (ptid_lwp_p): Remove.
7037 * common/ptid.h (ptid_lwp_p): Don't declare.
7038 * fbsd-nat.c: Update.
7039 * linux-nat.c: Update.
7040 * nat/linux-procfs.c: Update.
7041 * nat/x86-linux-dregs.c: Update.
7042 * sol-thread.c: Update.
7043
7044 2018-07-03 Tom Tromey <tom@tromey.com>
7045
7046 * common/ptid.c (ptid_is_pid): Remove.
7047 * common/ptid.h (ptid_is_pid): Don't declare.
7048 * infrun.c: Update.
7049 * linux-nat.c: Update.
7050 * mi/mi-interp.c: Update.
7051 * remote.c: Update.
7052 * thread.c: Update.
7053
7054 2018-07-03 Tom Tromey <tom@tromey.com>
7055
7056 * common/ptid.c (ptid_get_tid): Remove.
7057 * common/ptid.h (ptid_get_tid): Don't declare.
7058 * ada-tasks.c: Update.
7059 * aix-thread.c: Update.
7060 * bsd-uthread.c: Update.
7061 * darwin-nat.c: Update.
7062 * fbsd-nat.c: Update.
7063 * i386-darwin-nat.c: Update.
7064 * infrun.c: Update.
7065 * linux-tdep.c: Update.
7066 * nto-procfs.c: Update.
7067 * ppc-ravenscar-thread.c: Update.
7068 * python/py-infthread.c: Update.
7069 * ravenscar-thread.c: Update.
7070 * sol-thread.c: Update.
7071 * sparc-ravenscar-thread.c: Update.
7072 * windows-nat.c: Update.
7073
7074 2018-07-03 Tom Tromey <tom@tromey.com>
7075
7076 * common/ptid.c (ptid_get_lwp): Remove.
7077 * common/ptid.h (ptid_get_lwp): Don't declare.
7078 * aarch64-linux-nat.c: Update.
7079 * ada-tasks.c: Update.
7080 * aix-thread.c: Update.
7081 * amd64-linux-nat.c: Update.
7082 * arm-linux-nat.c: Update.
7083 * corelow.c: Update.
7084 * fbsd-nat.c: Update.
7085 * fbsd-tdep.c: Update.
7086 * gnu-nat.c: Update.
7087 * i386-cygwin-tdep.c: Update.
7088 * i386-gnu-nat.c: Update.
7089 * i386-linux-nat.c: Update.
7090 * ia64-linux-nat.c: Update.
7091 * inf-ptrace.c: Update.
7092 * infrun.c: Update.
7093 * linux-fork.c: Update.
7094 * linux-nat.c: Update.
7095 * linux-tdep.c: Update.
7096 * linux-thread-db.c: Update.
7097 * mips-linux-nat.c: Update.
7098 * nat/aarch64-linux-hw-point.c: Update.
7099 * nat/aarch64-linux.c: Update.
7100 * nat/linux-btrace.c: Update.
7101 * nat/linux-osdata.c: Update.
7102 * nat/linux-procfs.c: Update.
7103 * nat/x86-linux-dregs.c: Update.
7104 * obsd-nat.c: Update.
7105 * ppc-fbsd-nat.c: Update.
7106 * ppc-linux-nat.c: Update.
7107 * procfs.c: Update.
7108 * python/py-infthread.c: Update.
7109 * ravenscar-thread.c: Update.
7110 * remote.c: Update.
7111 * s390-linux-nat.c: Update.
7112 * sol-thread.c: Update.
7113 * sol2-tdep.c: Update.
7114 * spu-linux-nat.c: Update.
7115 * x86-linux-nat.c: Update.
7116 * xtensa-linux-nat.c: Update.
7117
7118 2018-07-03 Tom Tromey <tom@tromey.com>
7119
7120 * common/ptid.c (ptid_get_pid): Remove.
7121 * common/ptid.h (ptid_get_pid): Don't declare.
7122 * aarch64-linux-nat.c: Update.
7123 * ada-lang.c: Update.
7124 * aix-thread.c: Update.
7125 * alpha-bsd-nat.c: Update.
7126 * amd64-fbsd-nat.c: Update.
7127 * amd64-linux-nat.c: Update.
7128 * arm-linux-nat.c: Update.
7129 * arm-nbsd-nat.c: Update.
7130 * auxv.c: Update.
7131 * break-catch-syscall.c: Update.
7132 * breakpoint.c: Update.
7133 * bsd-uthread.c: Update.
7134 * corelow.c: Update.
7135 * ctf.c: Update.
7136 * darwin-nat.c: Update.
7137 * fbsd-nat.c: Update.
7138 * fbsd-tdep.c: Update.
7139 * gcore.c: Update.
7140 * gnu-nat.c: Update.
7141 * hppa-nbsd-nat.c: Update.
7142 * hppa-obsd-nat.c: Update.
7143 * i386-fbsd-nat.c: Update.
7144 * ia64-linux-nat.c: Update.
7145 * inf-ptrace.c: Update.
7146 * infcmd.c: Update.
7147 * inferior.c: Update.
7148 * inferior.h: Update.
7149 * inflow.c: Update.
7150 * infrun.c: Update.
7151 * linux-fork.c: Update.
7152 * linux-nat.c: Update.
7153 * linux-tdep.c: Update.
7154 * linux-thread-db.c: Update.
7155 * m68k-bsd-nat.c: Update.
7156 * mi/mi-interp.c: Update.
7157 * mi/mi-main.c: Update.
7158 * mips-linux-nat.c: Update.
7159 * mips-nbsd-nat.c: Update.
7160 * mips64-obsd-nat.c: Update.
7161 * nat/aarch64-linux-hw-point.c: Update.
7162 * nat/aarch64-linux.c: Update.
7163 * nat/linux-btrace.c: Update.
7164 * nat/linux-osdata.c: Update.
7165 * nat/linux-procfs.c: Update.
7166 * nat/x86-linux-dregs.c: Update.
7167 * nto-procfs.c: Update.
7168 * obsd-nat.c: Update.
7169 * ppc-linux-nat.c: Update.
7170 * ppc-nbsd-nat.c: Update.
7171 * ppc-obsd-nat.c: Update.
7172 * proc-service.c: Update.
7173 * procfs.c: Update.
7174 * python/py-inferior.c: Update.
7175 * python/py-infthread.c: Update.
7176 * ravenscar-thread.c: Update.
7177 * record.c: Update.
7178 * remote-sim.c: Update.
7179 * remote.c: Update.
7180 * rs6000-nat.c: Update.
7181 * s390-linux-nat.c: Update.
7182 * sh-nbsd-nat.c: Update.
7183 * sol-thread.c: Update.
7184 * sparc-nat.c: Update.
7185 * sparc64-tdep.c: Update.
7186 * spu-linux-nat.c: Update.
7187 * spu-tdep.c: Update.
7188 * target-debug.h: Update.
7189 * target.c: Update.
7190 * thread.c: Update.
7191 * tid-parse.c: Update.
7192 * tracefile-tfile.c: Update.
7193 * vax-bsd-nat.c: Update.
7194 * windows-nat.c: Update.
7195 * x86-linux-nat.c: Update.
7196 * x86-nat.c: Update.
7197
7198 2018-07-03 Tom Tromey <tom@tromey.com>
7199
7200 * common/ptid.c (pid_to_ptid): Remove.
7201 * common/ptid.h (pid_to_ptid): Don't declare.
7202 * aix-thread.c: Update.
7203 * arm-linux-nat.c: Update.
7204 * common/ptid.c: Update.
7205 * common/ptid.h: Update.
7206 * corelow.c: Update.
7207 * ctf.c: Update.
7208 * darwin-nat.c: Update.
7209 * fbsd-nat.c: Update.
7210 * fork-child.c: Update.
7211 * gnu-nat.c: Update.
7212 * go32-nat.c: Update.
7213 * inf-ptrace.c: Update.
7214 * infcmd.c: Update.
7215 * inferior.c: Update.
7216 * infrun.c: Update.
7217 * linux-fork.c: Update.
7218 * linux-nat.c: Update.
7219 * nat/aarch64-linux-hw-point.c: Update.
7220 * nat/fork-inferior.c: Update.
7221 * nat/x86-linux-dregs.c: Update.
7222 * nto-procfs.c: Update.
7223 * obsd-nat.c: Update.
7224 * procfs.c: Update.
7225 * progspace.c: Update.
7226 * remote.c: Update.
7227 * rs6000-nat.c: Update.
7228 * s390-linux-nat.c: Update.
7229 * sol-thread.c: Update.
7230 * spu-linux-nat.c: Update.
7231 * target.c: Update.
7232 * top.c: Update.
7233 * tracefile-tfile.c: Update.
7234 * windows-nat.c: Update.
7235
7236 2018-07-03 Tom Tromey <tom@tromey.com>
7237
7238 * common/ptid.h (ptid_build): Don't declare.
7239 * common/ptid.c (ptid_build): Remove.
7240 * aix-thread.c: Update.
7241 * bsd-kvm.c: Update.
7242 * bsd-uthread.c: Update.
7243 * common/agent.c: Update.
7244 * common/ptid.c: Update.
7245 * common/ptid.h: Update.
7246 * corelow.c: Update.
7247 * darwin-nat.c: Update.
7248 * fbsd-nat.c: Update.
7249 * gnu-nat.c: Update.
7250 * linux-fork.c: Update.
7251 * linux-nat.c: Update.
7252 * linux-thread-db.c: Update.
7253 * nat/linux-osdata.c: Update.
7254 * nat/linux-procfs.c: Update.
7255 * nto-procfs.c: Update.
7256 * obsd-nat.c: Update.
7257 * proc-service.c: Update.
7258 * procfs.c: Update.
7259 * ravenscar-thread.c: Update.
7260 * remote-sim.c: Update.
7261 * remote.c: Update.
7262 * sol-thread.c: Update.
7263 * target.c: Update.
7264 * windows-nat.c: Update.
7265
7266 2018-07-03 Tom Tromey <tom@tromey.com>
7267
7268 * infrun.c (follow_exec): Use exit_inferior_silent.
7269 * inferior.c (exit_inferior_num_silent): Remove.
7270 * inferior.h (exit_inferior_num_silent): Don't declare.
7271
7272 2018-07-03 Tom Tromey <tom@tromey.com>
7273
7274 PR cli/23340:
7275 * darwin-nat.c (darwin_attach_pid): Reset inferior and
7276 inferior_ptid on error.
7277
7278 2018-07-02 Maciej W. Rozycki <macro@mips.com>
7279 Simon Marchi <simon.marchi@polymtl.ca>
7280
7281 PR tdep/8282
7282 * disasm.h (gdb_disassembler): Add
7283 `m_disassembler_options_holder'. member
7284 * disasm.c (get_all_disassembler_options): New function.
7285 (gdb_disassembler::gdb_disassembler): Use it.
7286 (gdb_buffered_insn_length_init_dis): Likewise.
7287 (gdb_buffered_insn_length): Adjust accordingly.
7288 (set_disassembler_options): Handle options with arguments.
7289 (show_disassembler_options_sfunc): Likewise. Add a leading new
7290 line if showing options with descriptions.
7291 (disassembler_options_completer): Adapt to using the
7292 `disasm_options_and_args_t' structure.
7293 * mips-tdep.c (mips_disassembler_options): New variable.
7294 (mips_disassembler_options_o32): Likewise.
7295 (mips_disassembler_options_n32): Likewise.
7296 (mips_disassembler_options_n64): Likewise.
7297 (gdb_print_insn_mips): Don't set `disassembler_options'.
7298 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
7299 functions.
7300 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
7301 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
7302 `gdbarch_disassembler_options_implicit' and
7303 `gdbarch_valid_disassembler_options'.
7304 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
7305 `disasm_options_and_args_t' structure.
7306 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
7307 method.
7308 (valid_disassembler_options): Switch from `disasm_options_t' to
7309 the `disasm_options_and_args_t' structure.
7310 * NEWS: Document `set disassembler-options' support for the MIPS
7311 target.
7312 * gdbarch.h: Regenerate.
7313 * gdbarch.c: Regenerate.
7314
7315 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
7316
7317 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
7318
7319 2018-06-29 Joel Brobecker <brobecker@adacore.com>
7320
7321 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
7322 parameter in call to amd64_target_description.
7323 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
7324 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
7325 (amd64fbsd_init_abi): Likewise.
7326 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
7327 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
7328 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
7329 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
7330
7331 2018-06-29 Pedro Alves <palves@redhat.com>
7332
7333 * gdb/amd64-tdep.h (amd64_create_target_description): Add
7334 "segments" parameter.
7335 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
7336 (_initialize_amd64_tdep): Update call to
7337 amd64_create_target_description.
7338 (amd64_target_description): Add "segments" parameter. Adjust
7339 the implementation to use it.
7340 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
7341 call to amd64_create_target_description.
7342 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
7343 * gdb/arch/amd64.h (amd64_create_target_description): Add
7344 "segments" register.
7345 * gdb/arch/amd64.c (amd64_create_target_description): Add
7346 "segments" parameter. Call create_feature_i386_64bit_segments
7347 only if SEGMENTS is true.
7348 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
7349 call to amd64_create_target_description.
7350
7351 2018-06-29 Pedro Alves <palves@redhat.com>
7352
7353 * thread.c (thread_target_id_str): New, factored out from ...
7354 (print_thread_info_1): ... here. Use it to compute the max
7355 "Target Id" column width.
7356
7357 2018-06-29 Pedro Alves <palves@redhat.com>
7358
7359 * remote.c (remote_target::extra_thread_info): Delete
7360 'display_buf' and 'n' locals. from the cache, regardless of
7361 packet mechanims is in use. Use cache for qThreadExtra and qP
7362 methods too.
7363
7364 2018-06-29 Pedro Alves <palves@redhat.com>
7365
7366 * blockframe.c (find_pc_sect_containing_function): New function.
7367 * breakpoint.c (print_breakpoint_location): Don't call
7368 find_pc_sect_function.
7369 * linespec.c (create_sals_line_offset): Record the location's
7370 symbol in the sal.
7371 * linespec.c (convert_address_location_to_sals): Fill in sal's
7372 symbol with find_pc_sect_containing_function.
7373 * symtab.c (find_function_start_sal): Rename to ...
7374 (find_function_start_sal_1): ... this.
7375 (find_function_start_sal): Reimplement as wrapper around
7376 find_function_start_sal_1, and use
7377 find_pc_sect_containing_function to fill in the sal's symbol.
7378 (find_function_start_sal(symbol*, bool)): Adjust.
7379 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
7380 comments.
7381 (find_pc_sect_containing_function): Declare.
7382
7383 2018-06-29 Pedro Alves <palves@redhat.com>
7384
7385 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
7386 true if the the location has no symbol.
7387
7388 2018-06-28 Tom Tromey <tom@tromey.com>
7389
7390 * NEWS: Mention --enable-codesign.
7391 * silent-rules.mk (ECHO_SIGN): New variable.
7392 * configure.ac: Add --enable-codesign.
7393 * configure: Rebuild.
7394 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
7395 (gdb$(EXEEXT)): Optionally invoke codesign.
7396
7397 2018-06-28 Pedro Alves <palves@redhat.com>
7398
7399 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
7400 comments.
7401 (switch_to_thread_no_regs): Adjust comment.
7402 * infcmd.c (stop_pc): Delete.
7403 (post_create_inferior, info_program_command): Replace references
7404 to stop_pc with references to thread_info->suspend.stop_pc.
7405 * inferior.h (stop_pc): Delete declaration.
7406 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
7407 (handle_inferior_event_1, handle_signal_stop)
7408 (process_event_stop_test, keep_going_stepped_thread)
7409 (handle_step_into_function, handle_step_into_function_backward)
7410 (print_stop_location): Replace references to stop_pc with
7411 references to thread_info->suspend.stop_pc.
7412 (struct infcall_suspend_state) <stop_pc>: Delete field.
7413 (save_infcall_suspend_state, restore_infcall_suspend_state):
7414 Remove references to inf_stat->stop_pc.
7415 * linux-fork.c (fork_load_infrun_state): Likewise.
7416 * record-btrace.c (record_btrace_set_replay): Likewise.
7417 * record-full.c (record_full_goto_entry): Likewise.
7418 * remote.c (print_one_stopped_thread): Likewise.
7419 * target.c (target_resume): Extend comment.
7420 * thread.c (set_executing_thread): New.
7421 (set_executing): Use it.
7422 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
7423 Remove references to stop_pc.
7424
7425 2018-06-28 Pedro Alves <palves@redhat.com>
7426
7427 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
7428 Moving fetching stop_pc until after ecs->event_thread is refreshed.
7429
7430 2018-06-28 Tom Tromey <tom@tromey.com>
7431
7432 * coffread.c (coff_symfile_finish): Update.
7433 * xcoffread.c (xcoff_symfile_finish): Update.
7434 * elfread.c (elf_symfile_finish): Update.
7435 * symfile.h (dwarf2_free_objfile): Don't declare.
7436 * dwarf2read.c (_initialize_dwarf2_read): Use
7437 register_objfile_data_with_cleanup.
7438 (dwarf2_free_objfile): Now static. Change signature.
7439
7440 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7441
7442 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
7443 option "-o" to add-symbol-file-load to add an offset to each
7444 section's load address.
7445 * symfile.c (set_objfile_default_section_offset): New function.
7446
7447 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7448
7449 * symfile.c (add_symbol_file_command): Make sure that sections
7450 with the same name are sorted in the same order.
7451
7452 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7453
7454 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
7455 require the second argument. If omitted, load sections at the
7456 addresses specified in the file.
7457
7458 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7459
7460 * symfile.c (symbol_file_command, symbol_file_add_main_1)
7461 (_initialize_symfile): Add option "-o" to symbol-file to add an
7462 offset to each section of the symbol file.
7463
7464 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7465
7466 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
7467
7468 2018-06-27 Tom Tromey <tom@tromey.com>
7469
7470 * stack.c (_initialize_stack): Update "func" help text.
7471
7472 2018-06-27 Tom Tromey <tom@tromey.com>
7473
7474 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
7475 std::vector.
7476 (unwind_infopy_str, pyuw_create_unwind_info)
7477 (unwind_infopy_add_saved_register, pyuw_sniffer)
7478 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
7479 Update.
7480 (struct saved_reg): Add constructor.
7481 <value>: Now a gdbpy_ref<>.
7482
7483 2018-06-27 Tom Tromey <tom@tromey.com>
7484
7485 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
7486
7487 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7488
7489 * gdb-gdb.py.in: Format using autopep8.
7490
7491 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7492
7493 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
7494 (type_lookup_function): Recognize CORE_ADDR values.
7495
7496 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7497
7498 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
7499 print tag_name.
7500
7501 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7502
7503 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
7504 <__lt__>: Add.
7505
7506 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7507
7508 * gdb-gdb.py: Move to...
7509 * gdb-gdb.py.in: ... here.
7510 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
7511 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
7512 dependencies.
7513 (distclean): Remove gdb-gdb.py when cleaning.
7514 (gdb-gdb.py, gdb-gdb.gdb): New rules.
7515 * configure: Re-generate.
7516
7517 2018-06-27 Pedro Alves <palves@redhat.com>
7518
7519 * proc-service.c (get_ps_regcache): New.
7520 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
7521 (ps_lsetfpregs): Use it.
7522
7523 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
7524
7525 PR gdb/21695
7526 * dwarf2read.c (lnp_state_machine::check_line_address): Update
7527 declaration.
7528 (dwarf_decode_lines_1): Adjust.
7529
7530 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7531
7532 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
7533 override.
7534 <info_proc>: Likewise.
7535
7536 2018-06-26 Joel Brobecker <brobecker@adacore.com>
7537
7538 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
7539 to windows_fetch_one_register, and only handle the case of
7540 fetching one register. Move the code that reloads the context
7541 and iterates over all registers if R is negative to...
7542 (windows_nat_target::fetch_registers): ... here.
7543 (do_windows_store_inferior_registers): Rename to
7544 windows_store_one_register, and only handle the case of storing
7545 one register. Move the code that handles the case where r is
7546 negative to...
7547 (windows_nat_target::store_registers) ... here.
7548
7549 2018-06-26 Tom Tromey <tom@tromey.com>
7550
7551 PR rust/22574:
7552 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
7553 * rust-lang.c (rust_print_struct_def): Add podata parameter.
7554 Update.
7555 (rust_internal_print_type): Add podata parameter.
7556 (rust_print_type): Update.
7557
7558 2018-06-26 Tom Tromey <tom@tromey.com>
7559
7560 * typeprint.h (struct print_offset_data) <update, finish,
7561 maybe_print_hole>: New methods.
7562 <indentation>: New constant.
7563 * typeprint.c (print_offset_data::indentation): Define.
7564 (print_offset_data::maybe_print_hole, print_offset_data::update)
7565 (print_offset_data::finish): Move from c-typeprint.c and rename.
7566 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
7567 (print_spaces_filtered_with_print_options): Update.
7568 (c_print_type_union_field_offset, maybe_print_hole)
7569 (c_print_type_struct_field_offset): Move to typeprint.c and
7570 rename.
7571 (c_type_print_base_struct_union): Update.
7572
7573 2018-06-25 Pedro Alves <palves@redhat.com>
7574
7575 * gdbthread.h (thread_info_ref, delete_thread)
7576 (delete_thread_silent, first_thread_of_inferior)
7577 (any_thread_of_inferior, switch_to_thread)
7578 (enable_thread_stack_temporaries)
7579 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
7580 (get_last_thread_stack_temporary)
7581 (value_in_thread_stack_temporaries, can_access_registers_thread):
7582 Spell out "struct thread_info" instead of just "thread_info".
7583 * inferior.h (notice_new_inferior): Likewise.
7584
7585 2018-06-25 Pedro Alves <palves@redhat.com>
7586
7587 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
7588 pass thread_info pointer to delete_thread.
7589 (windows_nat_target::detach): Pass inferior pointer to
7590 detach_inferior.
7591 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
7592 delete_thread.
7593 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
7594 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
7595 and pass a thread_info pointer to delete_thread.
7596 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
7597 pass thread_info pointer to delete_thread.
7598 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
7599 delete_thread_silent call.
7600 * procfs.c (procfs_target::detach): Pass inferior pointer to
7601 detach_inferior.
7602 (procfs_target::wait): Pass thread_info pointer to delete_thread.
7603 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
7604 delete_thread_silent call.
7605 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
7606 pass thread_info pointer to delete_thread.
7607 (windows_nat_target::detach): Pass inferior pointer to
7608 delete_inferior.
7609
7610 2018-06-22 Alan Hayward <alan.hayward@arm.com>
7611
7612 * regcache.c (readable_regcache::read_part): Fix asserts.
7613 (reg_buffer::raw_collect_part): New function.
7614 (regcache::write_part): Fix asserts.
7615 (reg_buffer::raw_supply_part): New function.
7616 (regcache::transfer_regset_register): New helper function.
7617 (regcache::transfer_regset): Call new functions.
7618 (regcache_supply_regset): Use gdb_byte*.
7619 (regcache::supply_regset): Likewise.
7620 (regcache_collect_regset): Likewise.
7621 (regcache::collect_regset): Likewise.
7622 * regcache.h (reg_buffer::raw_collect_part): New declaration.
7623 (reg_buffer::raw_supply_part): Likewise.
7624 (regcache::transfer_regset_register): Likewise.
7625 (regcache::transfer_regset): Use gdb_byte*.
7626
7627 2018-06-22 Alan Hayward <alan.hayward@arm.com>
7628
7629 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
7630
7631 2018-06-21 Pedro Alves <palves@redhat.com>
7632
7633 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
7634 instead of a ptid_t. All callers adjusted.
7635 * ada-tasks.c (ada_get_task_number): Likewise. All callers
7636 adjusted.
7637 (print_ada_task_info, display_current_task_id, task_command_1):
7638 Adjust.
7639 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
7640 inferior_thread.
7641 (breakpoint_kind): Adjust.
7642 (remove_breakpoints_pid): Rename to ...
7643 (remove_breakpoints_inf): ... this. Adjust to take an inferior
7644 pointer. All callers adjusted.
7645 (bpstat_clear_actions): Use inferior_thread.
7646 (get_bpstat_thread): New.
7647 (bpstat_do_actions): Use it.
7648 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
7649 to take a thread_info pointer. All callers adjusted.
7650 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
7651 (breakpoint_re_set_thread): Use inferior_thread.
7652 * breakpoint.h (struct inferior): Forward declare.
7653 (bpstat_stop_status): Update.
7654 (remove_breakpoints_pid): Delete.
7655 (remove_breakpoints_inf): New.
7656 * bsd-uthread.c (bsd_uthread_target::wait)
7657 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
7658 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
7659 (maint_btrace_packet_history_cmd)
7660 (maint_btrace_clear_packet_history_cmd): Adjust.
7661 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
7662 inferior_thread.
7663 * cli/cli-interp.c: Include "inferior.h".
7664 * common/refcounted-object.h (struct
7665 refcounted_object_ref_policy): New.
7666 * compile/compile-object-load.c: Include gdbthread.h.
7667 (store_regs): Use inferior_thread.
7668 * corelow.c (core_target::close): Use current_inferior.
7669 (core_target_open): Adjust to use first_thread_of_inferior and use
7670 the current inferior.
7671 * ctf.c (ctf_target::close): Adjust to use current_inferior.
7672 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
7673 <thread>: ... this new field. All references adjusted.
7674 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
7675 Take a thread_info pointer instead of a ptid_t.
7676 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
7677 (dummy_frame_discard, register_dummy_frame_dtor): Take a
7678 thread_info pointer instead of a ptid_t.
7679 * elfread.c: Include "inferior.h".
7680 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
7681 Use inferior_thread.
7682 * eval.c (evaluate_subexp): Likewise.
7683 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
7684 inferior_thread.
7685 * gdb_proc_service.h (struct thread_info): Forward declare.
7686 (struct ps_prochandle) <ptid>: Delete, replaced by ...
7687 <thread>: ... this new field. All references adjusted.
7688 * gdbarch.h, gdbarch.c: Regenerate.
7689 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
7690 'thread' parameter. All implementations and callers adjusted.
7691 * gdbthread.h (thread_info) <set_running>: New method.
7692 (delete_thread, delete_thread_silent): Take a thread_info pointer
7693 instead of a ptid.
7694 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
7695 (first_thread_of_process): Delete, replaced by ...
7696 (first_thread_of_inferior): ... this new function. All callers
7697 adjusted.
7698 (any_live_thread_of_process): Delete, replaced by ...
7699 (any_live_thread_of_inferior): ... this new function. All callers
7700 adjusted.
7701 (switch_to_thread, switch_to_no_thread): Declare.
7702 (is_executing): Delete.
7703 (enable_thread_stack_temporaries): Update comment.
7704 <enable_thread_stack_temporaries>: Take a thread_info pointer
7705 instead of a ptid_t. Incref the thread.
7706 <~enable_thread_stack_temporaries>: Decref the thread.
7707 <m_ptid>: Delete
7708 <m_thr>: New.
7709 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
7710 (get_last_thread_stack_temporary)
7711 (value_in_thread_stack_temporaries, can_access_registers_thread):
7712 Take a thread_info pointer instead of a ptid_t. All callers
7713 adjusted.
7714 * infcall.c (get_call_return_value): Use inferior_thread.
7715 (run_inferior_call): Work with thread pointers instead of ptid_t.
7716 (call_function_by_hand_dummy): Work with thread pointers instead
7717 of ptid_t. Use thread_info_ref.
7718 * infcmd.c (proceed_thread_callback): Access thread's state
7719 directly.
7720 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
7721 access thread's state directly.
7722 (continue_command): Use inferior_thread.
7723 (info_program_command): Use find_thread_ptid and access thread
7724 state directly.
7725 (proceed_after_attach_callback): Use thread state directly.
7726 (notice_new_inferior): Take a thread_info pointer instead of a
7727 ptid_t. All callers adjusted.
7728 (exit_inferior): Take an inferior pointer instead of a pid. All
7729 callers adjusted.
7730 (exit_inferior_silent): New.
7731 (detach_inferior): Delete.
7732 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
7733 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
7734 (detach_inferior_command, kill_inferior_command): Use
7735 find_inferior_id instead of valid_gdb_inferior_id and
7736 gdb_inferior_id_to_pid.
7737 (inferior_command): Use inferior and thread pointers.
7738 * inferior.h (struct thread_info): Forward declare.
7739 (notice_new_inferior): Take a thread_info pointer instead of a
7740 ptid_t. All callers adjusted.
7741 (detach_inferior): Delete declaration.
7742 (exit_inferior, exit_inferior_silent): Take an inferior pointer
7743 instead of a pid. All callers adjusted.
7744 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
7745 (valid_gdb_inferior_id): Delete.
7746 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
7747 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
7748 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
7749 ...
7750 <inf>: ... this new field.
7751 <step_ptid>: Delete, replaced by ...
7752 <step_thread>: ... this new field.
7753 (get_displaced_stepping_state): Take an inferior pointer instead
7754 of a pid. All callers adjusted.
7755 (displaced_step_in_progress_any_inferior): Adjust.
7756 (displaced_step_in_progress_thread): Take a thread pointer instead
7757 of a ptid_t. All callers adjusted.
7758 (displaced_step_in_progress, add_displaced_stepping_state): Take
7759 an inferior pointer instead of a pid. All callers adjusted.
7760 (get_displaced_step_closure_by_addr): Adjust.
7761 (remove_displaced_stepping_state): Take an inferior pointer
7762 instead of a pid. All callers adjusted.
7763 (displaced_step_prepare_throw, displaced_step_prepare)
7764 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
7765 All callers adjusted.
7766 (start_step_over): Adjust.
7767 (infrun_thread_ptid_changed): Remove bit updating ptids in the
7768 displaced step queue.
7769 (do_target_resume): Adjust.
7770 (fetch_inferior_event): Use inferior_thread.
7771 (context_switch, get_inferior_stop_soon): Take an
7772 execution_control_state pointer instead of a ptid_t. All callers
7773 adjusted.
7774 (switch_to_thread_cleanup): Delete.
7775 (stop_all_threads): Use scoped_restore_current_thread.
7776 * inline-frame.c: Include "gdbthread.h".
7777 (inline_state) <inline_state>: Take a thread pointer instead of a
7778 ptid_t. All callers adjusted.
7779 <ptid>: Delete, replaced by ...
7780 <thread>: ... this new field.
7781 (find_inline_frame_state): Take a thread pointer instead of a
7782 ptid_t. All callers adjusted.
7783 (skip_inline_frames, step_into_inline_frame)
7784 (inline_skipped_frames, inline_skipped_symbol): Take a thread
7785 pointer instead of a ptid_t. All callers adjusted.
7786 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
7787 (inline_skipped_frames, inline_skipped_symbol): Likewise.
7788 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
7789 pointers directly.
7790 * linux-nat.c (get_detach_signal): Likewise.
7791 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
7792 (thread_db_notice_clone): Adjust.
7793 (thread_db_find_new_threads_silently)
7794 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
7795 a thread pointer instead of a ptid_t. All callers adjusted.
7796 * mi/mi-cmd-var.c: Include "inferior.h".
7797 (mi_cmd_var_update_iter): Update to use thread pointers.
7798 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
7799 inferior directly.
7800 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
7801 out to ...
7802 (mi_output_running): ... this new function.
7803 (mi_on_resume_1): Adjust to use it.
7804 (mi_user_selected_context_changed): Adjust to use inferior_thread.
7805 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
7806 directly.
7807 (interrupt_thread_callback): : Adjust to use thread and inferior
7808 pointers.
7809 * proc-service.c: Include "gdbthread.h".
7810 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
7811 * progspace-and-thread.c: Include "inferior.h".
7812 * progspace.c: Include "inferior.h".
7813 * python/py-exitedevent.c (create_exited_event_object): Adjust to
7814 hold a reference to an inferior_object.
7815 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
7816 inferior_thread.
7817 * python/py-inferior.c (struct inferior_object): Give the type a
7818 tag name instead of a typedef.
7819 (python_on_normal_stop): No need to check if the current thread is
7820 listed.
7821 (inferior_to_inferior_object): Change return type to
7822 inferior_object. All callers adjusted.
7823 (find_thread_object): Delete, bits factored out to ...
7824 (thread_to_thread_object): ... this new function.
7825 * python/py-infthread.c (create_thread_object): Use
7826 inferior_to_inferior_object.
7827 (thpy_is_stopped): Use thread pointer directly.
7828 (gdbpy_selected_thread): Use inferior_thread.
7829 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
7830 field, replaced with ...
7831 <thread>: ... this new field. All users adjusted.
7832 (btpy_insn_or_gap_new): Drop const.
7833 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
7834 callers adjusted.
7835 * python/py-record.c: Include "gdbthread.h".
7836 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
7837 a ptid_t. All callers adjusted.
7838 (gdbpy_current_recording): Use inferior_thread.
7839 * python/py-record.h (recpy_record_object) <ptid>: Delete
7840 field, replaced with ...
7841 <thread>: ... this new field. All users adjusted.
7842 (recpy_element_object) <ptid>: Delete
7843 field, replaced with ...
7844 <thread>: ... this new field. All users adjusted.
7845 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
7846 a ptid_t. All callers adjusted.
7847 * python/py-threadevent.c: Include "gdbthread.h".
7848 (get_event_thread): Use thread_to_thread_object.
7849 * python/python-internal.h (struct inferior_object): Forward
7850 declare.
7851 (find_thread_object, find_inferior_object): Delete declarations.
7852 (thread_to_thread_object, inferior_to_inferior_object): New
7853 declarations.
7854 * record-btrace.c: Include "inferior.h".
7855 (require_btrace_thread): Use inferior_thread.
7856 (record_btrace_frame_sniffer)
7857 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
7858 (get_thread_current_frame): Use scoped_restore_current_thread and
7859 switch_to_thread.
7860 (get_thread_current_frame): Use thread pointer directly.
7861 (record_btrace_replay_at_breakpoint): Use thread's inferior
7862 pointer directly.
7863 * record-full.c: Include "inferior.h".
7864 * regcache.c: Include "gdbthread.h".
7865 (get_thread_arch_regcache): Use the inferior's address space
7866 directly.
7867 (get_thread_regcache, registers_changed_thread): New.
7868 * regcache.h (get_thread_regcache(thread_info *thread)): New
7869 overload.
7870 (registers_changed_thread): New.
7871 (remote_target) <remote_detach_1>: Swap order of parameters.
7872 (remote_add_thread): <remote_add_thread>: Return the new thread.
7873 (get_remote_thread_info(ptid_t)): New overload.
7874 (remote_target::remote_notice_new_inferior): Use thread pointers
7875 directly.
7876 (remote_target::process_initial_stop_replies): Use
7877 thread_info::set_running.
7878 (remote_target::remote_detach_1, remote_target::detach)
7879 (extended_remote_target::detach): Adjust.
7880 * stack.c (frame_show_address): Use inferior_thread.
7881 * target-debug.h (target_debug_print_thread_info_pp): New.
7882 * target-delegates.c: Regenerate.
7883 * target.c (default_thread_address_space): Delete.
7884 (memory_xfer_partial_1): Use current_inferior.
7885 (target_detach): Use current_inferior.
7886 (target_thread_address_space): Delete.
7887 (generic_mourn_inferior): Use current_inferior.
7888 * target.h (struct target_ops) <thread_address_space>: Delete.
7889 (target_thread_address_space): Delete.
7890 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
7891 pointers directly.
7892 (delete_thread_1, delete_thread, delete_thread_silent): Take a
7893 thread pointer instead of a ptid_t. Adjust all callers.
7894 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
7895 (first_thread_of_process): Delete, replaced by ...
7896 (first_thread_of_inferior): ... this new function. All callers
7897 adjusted.
7898 (any_thread_of_process): Rename to ...
7899 (any_thread_of_inferior): ... this, and take an inferior pointer.
7900 (any_live_thread_of_process): Rename to ...
7901 (any_live_thread_of_inferior): ... this, and take an inferior
7902 pointer.
7903 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
7904 (value_in_thread_stack_temporaries)
7905 (get_last_thread_stack_temporary): Take a thread pointer instead
7906 of a ptid_t. Adjust all callers.
7907 (thread_info::set_running): New.
7908 (validate_registers_access): Use inferior_thread.
7909 (can_access_registers_ptid): Rename to ...
7910 (can_access_registers_thread): ... this, and take a thread
7911 pointer.
7912 (print_thread_info_1): Adjust to compare thread pointers instead
7913 of ptids.
7914 (switch_to_no_thread, switch_to_thread): Make extern.
7915 (scoped_restore_current_thread::~scoped_restore_current_thread):
7916 Use m_thread pointer directly.
7917 (scoped_restore_current_thread::scoped_restore_current_thread):
7918 Use inferior_thread.
7919 (thread_command): Use thread pointer directly.
7920 (thread_num_make_value_helper): Use inferior_thread.
7921 * top.c (execute_command): Use inferior_thread.
7922 * tui/tui-interp.c: Include "inferior.h".
7923 * varobj.c (varobj_create): Use inferior_thread.
7924 (value_of_root_1): Use find_thread_global_id instead of
7925 global_thread_id_to_ptid.
7926
7927 2018-06-21 Alan Hayward <alan.hayward@arm.com>
7928
7929 * regcache.c (readable_regcache::read_part): Avoid memcpy when
7930 possible.
7931 (regcache::write_part): Likewise.
7932 (readable_regcache::cooked_read_part): Update comment.
7933 (readable_regcache::cooked_write_part): Likewise.
7934 * regcache.h: (readable_regcache::read_part): Likewise.
7935 (regcache::write_part): Likewise.
7936
7937 2018-06-21 Richard Bunt <richard.bunt@arm.com>
7938 Dirk Schubert <dirk.schubert@arm.com>
7939
7940 * aarch64-linux-nat.c (post_attach): New.
7941 (aarch64_linux_nat_target::post_attach): Override post_attach to
7942 record the number of hardware debug registers.
7943
7944 2018-06-20 Tom Tromey <tom@tromey.com>
7945
7946 * python/py-param.c (add_setshow_generic): Make parameters const.
7947 (parmpy_init): Update.
7948
7949 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
7950
7951 * regcache.h (regcache_cooked_read_ftype): Rename to...
7952 (register_read_ftype): ...this, change type to function_view.
7953 (class reg_buffer) <save>: Remove src parameter.
7954 (readonly_detached_regcache) <readonly_detached_regcache>: Make
7955 parameter non-const in first overload. Remove src parameter in
7956 second overload.
7957 * regcache.c (do_cooked_read): Remove.
7958 (readonly_detached_regcache::readonly_detached_regcache): Make
7959 parameter non-const, adjust call to other constructor.
7960 (reg_buffer::save): Remove src parameter.
7961 * frame.c (do_frame_register_read): Remove.
7962 (frame_save_as_regcache): Use lambda function.
7963 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
7964 parameter to ppu2spu_data *.
7965 (ppu2spu_sniffer): Use lambda function.
7966
7967 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
7968
7969 * record-full.c (record_full_target::insert_breakpoint): Remove
7970 "struct" keyword, add const.
7971
7972 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
7973
7974 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
7975 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
7976 * configure.ac: Remove AC_PREREQ, add missing quoting.
7977 * gnulib/configure.ac: Modernize usage of
7978 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
7979 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
7980 (AUTOMAKE_VERSION): Bump to 1.15.1.
7981 * configure: Re-generate.
7982 * config.in: Re-generate.
7983 * aclocal.m4: Re-generate.
7984 * gnulib/aclocal.m4: Re-generate.
7985 * gnulib/config.in: Re-generate.
7986 * gnulib/configure: Re-generate.
7987 * gnulib/import/Makefile.in: Re-generate.
7988
7989 2018-06-19 Pedro Alves <palves@redhat.com>
7990
7991 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
7992 (lookup_minimal_symbol_by_pc_section): ... here with
7993 gdb_assert_not_reached added.
7994
7995 2018-06-19 Pedro Alves <palves@redhat.com>
7996
7997 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
7998 parameter with a block parameter. Compare location's block symbol
7999 with the frame's block instead of addresses.
8000 (skip_inline_frames): Pass the current block instead of the
8001 frame's address. Break out as soon as we determine the frame
8002 should not be skipped.
8003
8004 2018-06-18 Tom Tromey <tom@tromey.com>
8005
8006 * solib-aix.c (solib_aix_get_section_offsets): Return
8007 unique_xmalloc_ptr.
8008 (solib_aix_solib_create_inferior_hook): Update.
8009
8010 2018-06-18 Tom Tromey <tom@tromey.com>
8011
8012 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
8013
8014 2018-06-18 Tom Tromey <tom@tromey.com>
8015
8016 * solib-frv.c (frv_relocate_main_executable): Use
8017 unique_xmalloc_ptr.
8018 * solib-dsbt.c (dsbt_relocate_main_executable): Use
8019 unique_xmalloc_ptr.
8020
8021 2018-06-18 Tom Tromey <tom@tromey.com>
8022
8023 * objfiles.h (inhibit_section_map_updates): Update.
8024 (resume_section_map_updates, resume_section_map_updates_cleanup):
8025 Remove.
8026 * solib-svr4.c (svr4_handle_solib_event): Update.
8027 * objfiles.c (inhibit_section_map_updates): Return
8028 scoped_restore_tmpl<int>.
8029 (resume_section_map_updates, resume_section_map_updates_cleanup):
8030 Remove.
8031
8032 2018-06-18 Tom Tromey <tom@tromey.com>
8033
8034 * valprint.h (read_string): Update.
8035 * valprint.c (read_string): Change type of "buffer".
8036 (val_print_string): Update.
8037 * python/py-value.c (valpy_string): Update.
8038 * language.h (struct language_defn) <la_get_string>: Change
8039 type of "buffer".
8040 (default_get_string, c_get_string): Update.
8041 * language.c (default_get_string): Change type of "buffer".
8042 * guile/scm-value.c (gdbscm_value_to_string): Update.
8043 * c-lang.c (c_get_string): Change type of "buffer".
8044
8045 2018-06-18 Tom Tromey <tom@tromey.com>
8046
8047 * ser-mingw.c (struct pipe_state_destroyer): New.
8048 (pipe_state_up): New typedef.
8049 (cleanup_pipe_state): Remove.
8050 (pipe_windows_open): Use pipe_state_up. Don't release argv.
8051
8052 2018-06-18 Tom Tromey <tom@tromey.com>
8053
8054 * rust-lang.h (rust_yyerror): Don't declare.
8055 * rust-lang.c (rust_language_defn): Update.
8056 * rust-exp.y (yyerror): Now static.
8057 * parse.c (parse_exp_in_context_1): Update.
8058 * p-lang.h (p_yyerror): Don't declare.
8059 * p-lang.c (p_language_defn): Update.
8060 * p-exp.y (yyerror): Now static.
8061 * opencl-lang.c (opencl_language_defn): Update.
8062 * objc-lang.c (objc_language_defn): Update.
8063 * m2-lang.h (m2_yyerror): Don't declare.
8064 * m2-lang.c (m2_language_defn): Update.
8065 * m2-exp.y (yyerror): Now static.
8066 * language.h (struct language_defn) <la_error>: Remove.
8067 * language.c (unk_lang_error): Remove.
8068 (unknown_language_defn, auto_language_defn): Remove.
8069 * go-lang.h (go_yyerror): Don't declare.
8070 * go-lang.c (go_language_defn): Update.
8071 * go-exp.y (yyerror): Now static.
8072 * f-lang.h (f_yyerror): Don't declare.
8073 * f-lang.c (f_language_defn): Update.
8074 * f-exp.y (yyerror): Now static.
8075 * d-lang.h (d_yyerror): Don't declare.
8076 * d-lang.c (d_language_defn): Update.
8077 * d-exp.y (yyerror): Now static.
8078 * c-lang.h (c_yyerror): Don't declare.
8079 * c-lang.c (c_language_defn, cplus_language_defn)
8080 (asm_language_defn, minimal_language_defn): Update.
8081 * c-exp.y (yyerror): Now static.
8082 * ada-lang.h (ada_yyerror): Don't declare.
8083 * ada-lang.c (ada_language_defn): Update.
8084 * ada-exp.y (yyerror): Now static.
8085
8086 2018-06-18 Alan Hayward <alan.hayward@arm.com>
8087
8088 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
8089 (store_sveregs_to_thread): Likewise.
8090 (aarch64_linux_fetch_inferior_registers): Check for SVE.
8091 (aarch64_linux_store_inferior_registers): Likewise.
8092 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
8093 function.
8094 (aarch64_sve_regs_copy_to_regcache): Likewise.
8095 (aarch64_sve_regs_copy_from_regcache): Likewise.
8096 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
8097 declaration.
8098 (aarch64_sve_regs_copy_to_regcache): Likewise.
8099 (aarch64_sve_regs_copy_from_regcache): Likewise.
8100 (sve_context): Structure from Linux headers.
8101 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
8102 (SVE_SIG_ZREG_SIZE): Likewise.
8103 (SVE_SIG_PREG_SIZE): Likewise.
8104 (SVE_SIG_FFR_SIZE): Likewise.
8105 (SVE_SIG_REGS_OFFSET): Likewise.
8106 (SVE_SIG_ZREGS_OFFSET): Likewise.
8107 (SVE_SIG_ZREG_OFFSET): Likewise.
8108 (SVE_SIG_ZREGS_SIZE): Likewise.
8109 (SVE_SIG_PREGS_OFFSET): Likewise.
8110 (SVE_SIG_PREG_OFFSET): Likewise.
8111 (SVE_SIG_PREGS_SIZE): Likewise.
8112 (SVE_SIG_FFR_OFFSET): Likewise.
8113 (SVE_SIG_REGS_SIZE): Likewise.
8114 (SVE_SIG_CONTEXT_SIZE): Likewise.
8115 (SVE_PT_REGS_MASK): Likewise.
8116 (SVE_PT_REGS_FPSIMD): Likewise.
8117 (SVE_PT_REGS_SVE): Likewise.
8118 (SVE_PT_VL_INHERIT): Likewise.
8119 (SVE_PT_VL_ONEXEC): Likewise.
8120 (SVE_PT_REGS_OFFSET): Likewise.
8121 (SVE_PT_FPSIMD_OFFSET): Likewise.
8122 (SVE_PT_FPSIMD_SIZE): Likewise.
8123 (SVE_PT_SVE_ZREG_SIZE): Likewise.
8124 (SVE_PT_SVE_PREG_SIZE): Likewise.
8125 (SVE_PT_SVE_FFR_SIZE): Likewise.
8126 (SVE_PT_SVE_FPSR_SIZE): Likewise.
8127 (SVE_PT_SVE_FPCR_SIZE): Likewise.
8128 (__SVE_SIG_TO_PT): Likewise.
8129 (SVE_PT_SVE_OFFSET): Likewise.
8130 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
8131 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
8132 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
8133 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
8134 (SVE_PT_SVE_PREG_OFFSET): Likewise.
8135 (SVE_PT_SVE_PREGS_SIZE): Likewise.
8136 (SVE_PT_SVE_FFR_OFFSET): Likewise.
8137 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
8138 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
8139 (SVE_PT_SVE_SIZE): Likewise.
8140 (SVE_PT_SIZE): Likewise.
8141 (HAS_SVE_STATE): New define.
8142
8143 2018-06-18 Alan Hayward <alan.hayward@arm.com>
8144
8145 * nat/aarch64-sve-linux-sigcontext.h: New file.
8146 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
8147 new files.
8148 (SVE_VQ_MIN): Likewise.
8149 (SVE_VQ_MAX): Likewise.
8150 (SVE_VL_MIN): Likewise.
8151 (SVE_VL_MAX): Likewise.
8152 (SVE_NUM_ZREGS): Likewise.
8153 (SVE_NUM_PREGS): Likewise.
8154 (sve_vl_valid): Likewise.
8155 (struct user_sve_header): Likewise.
8156
8157 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
8158 Richard Bunt <Richard.Bunt@arm.com>
8159
8160 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
8161 was requested by GDB.
8162
8163 2018-06-15 Tom de Vries <tdevries@suse.de>
8164
8165 * MAINTAINERS (Write After Approval): Add Tom de Vries.
8166
8167 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
8168
8169 * gnulib/update-gnulib.sh: Print expected versions of
8170 autoconf/aclocal.
8171
8172 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
8173
8174 * arch-utils.c (default_type_align): Use type_length_units.
8175 * gdbtypes.c (type_align): Use type_length_units.
8176
8177 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8178
8179 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
8180 of 'define' command.
8181
8182 2018-06-14 Tom de Vries <tdevries@suse.de>
8183
8184 PR cli/22573
8185 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
8186 get_no_prettyformat_print_options.
8187
8188 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
8189
8190 * sparc-nat.h: Include target.h.
8191 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
8192 <fetch_registers>: Remove this argument in function call.
8193 <store_registers>: Remove this argument in function call, remove
8194 extra semicolon.
8195 <low_forget_process>: Call sparc64_forget_process instead of
8196 sparc_forget_process.
8197
8198 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8199
8200 * procfs.c (_initialize_procfs): Use add_inf_child_target.
8201 (procfs_target::make_corefile_notes): Adjust to new
8202 target_read_alloc return type.
8203
8204 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
8205 Stephen Roberts <stephen.roberts@arm.com>
8206
8207 PR gdb/22882
8208 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
8209 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
8210 Move should_notify_stop local into more inner scope.
8211
8212 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
8213 Stephen Roberts <stephen.roberts@arm.com>
8214
8215 PR gdb/22882
8216 * infrun.c (resume_1): Add call to mark_async_event_handler.
8217
8218 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
8219
8220 * infrun.c (do_target_wait): Change old version of $pc printed.
8221
8222 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
8223
8224 * dwarf2read.c (read_index_from_section): Rename to...
8225 (read_gdb_index_from_section): ... this, update all callers.
8226 (dwarf2_read_index): Rename to...
8227 (dwarf2_read_gdb_index): ... this, update all callers.
8228
8229 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
8230
8231 * hppa-linux-nat.c
8232 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
8233 hppa_linux_nat_target::fetch_registers.
8234
8235 2018-06-11 Alan Hayward <alan.hayward@arm.com>
8236
8237 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
8238 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
8239 (AARCH64_DWARF_SVE_FFR): Likewise.
8240 (AARCH64_DWARF_SVE_P0): Likewise.
8241 (AARCH64_DWARF_SVE_Z0): Likewise.
8242
8243 2018-06-11 Alan Hayward <alan.hayward@arm.com>
8244
8245 * common/common-regcache.h (raw_compare): New function.
8246 * regcache.c (regcache::raw_compare): Likewise.
8247 * regcache.h (regcache::raw_compare): New declaration.
8248
8249 2018-06-11 Alan Hayward <alan.hayward@arm.com>
8250
8251 * common/common-regcache.h (reg_buffer_common): New structure.
8252 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
8253 (reg_buffer::raw_supply): Likewise.
8254 (reg_buffer::raw_supply_integer): Likewise.
8255 (reg_buffer::raw_supply_zeroed): Likewise.
8256 (reg_buffer::raw_collect): Likewise.
8257 (reg_buffer::raw_collect_integer): Likewise.
8258 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
8259 (reg_buffer::raw_supply): Likewise.
8260 (reg_buffer::raw_supply_integer): Likewise.
8261 (reg_buffer::raw_supply_zeroed): Likewise.
8262 (reg_buffer::raw_collect): Likewise.
8263 (reg_buffer::raw_collect_integer): Likewise.
8264
8265 2018-06-10 Tom Tromey <tom@tromey.com>
8266
8267 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
8268 (class remote_state) <stop_reply_queue>: Now std::vector.
8269 (remote_state::~remote_state)
8270 (remote_target::stop_reply_queue_length): Update.
8271 (struct queue_iter_param, remove_child_of_pending_fork)
8272 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
8273 (check_pending_event_prevents_wildcard_vcont_callback)
8274 (remove_stop_reply_for_inferior)
8275 (remove_stop_reply_of_remote_state)
8276 (remote_notif_remove_once_on_match)
8277 (stop_reply_match_ptid_and_ws)
8278 (remote_kill_child_of_pending_fork): Remove.
8279 (remote_target::remove_new_fork_children)
8280 (remote_target::check_pending_events_prevent_wildcard_vcont)
8281 (remote_target::discard_pending_stop_replies)
8282 (remote_target::discard_pending_stop_replies_in_queue)
8283 (remote_target::remote_notif_remove_queued_reply)
8284 (remote_target::queued_stop_reply)
8285 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
8286 (remote_target::wait, remote_target::kill_new_fork_children)
8287 (remote_target::async): Update.
8288
8289 2018-06-10 Tom Tromey <tom@tromey.com>
8290
8291 * record-full.c (record_full_arch_list_cleanups): Remove.
8292 (record_full_message): Use try/catch.
8293 (record_full_wait_cleanups): Remove.
8294 (record_full_wait_1): Use try/catch.
8295 (record_full_restore): Likewise.
8296
8297 2018-06-10 Tom Tromey <tom@tromey.com>
8298
8299 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
8300 declare VEC. Add constructor.
8301 <in_target_beneath>: Now bool.
8302 (record_full_breakpoints): Now a std::vector, static.
8303 (record_full_sync_record_breakpoints)
8304 (record_full_init_record_breakpoints)
8305 (record_full_target::insert_breakpoint)
8306 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
8307
8308 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
8309
8310 * dwarf2read.c (process_cu_includes): Remove struct keyword.
8311 * serial.c (serial_interface_lookup): Remove struct keyword.
8312
8313 2018-06-10 Tom Tromey <tom@tromey.com>
8314
8315 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
8316 method.
8317 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
8318 a method.
8319 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
8320 method.
8321 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
8322 "beneath" as a method.
8323 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
8324 Use "beneath" as a method.
8325
8326 2018-06-10 Tom Tromey <tom@tromey.com>
8327
8328 * tracefile.c (struct trace_file_writer_deleter): New.
8329 <operator()>: Rename from trace_file_writer_xfree.
8330 (trace_file_writer_up): New typedef.
8331 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
8332
8333 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
8334
8335 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
8336 <m_registers, m_register_status>: Change type to
8337 std::unique_ptr.
8338 * regcache.c (reg_buffer::reg_buffer): Use new instead of
8339 XCNEWVEC.
8340
8341 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
8342
8343 * common/common-regcache.h (enum register_status): Add
8344 underlying type "signed char".
8345 * regcache.h (reg_buffer) <m_register_status>: Change type to
8346 register_status *.
8347 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
8348 register_status instead of signed char.
8349 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
8350 (reg_buffer::get_register_status): Remove cast.
8351 (readable_regcache::raw_read): Remove cast.
8352 (readable_regcache::cooked_read): Remove cast.
8353
8354 2018-06-09 Tom Tromey <tom@tromey.com>
8355
8356 * source.c (reverse_search_command, forward_search_command): Use
8357 scoped_fd.
8358
8359 2018-06-09 Tom Tromey <tom@tromey.com>
8360
8361 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
8362 (serial_ops_list): Now static, std::vector.
8363 (serial_interface_lookup, serial_add_interface): Update.
8364
8365 2018-06-09 Tom Tromey <tom@tromey.com>
8366
8367 * dwarf2read.c (process_cu_includes): Update.
8368 (process_full_comp_unit): Update.
8369 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
8370 std::vector.
8371
8372 2018-06-08 Paul Koning <paul_koning@dell.com>
8373
8374 PR gdb/23252
8375
8376 * python/python.c (do_start_initialization):
8377 Avoid call to internal Python API.
8378 (init__gdb_module): New function.
8379
8380 2018-06-08 Gary Benson <gbenson@redhat.com>
8381
8382 * linux-thread-db.c (valprint.h): New include.
8383 (struct check_thread_db_info): New structure.
8384 (check_thread_db_on_load, tdb_testinfo): New static globals.
8385 (check_thread_db, check_thread_db_callback): New functions.
8386 (try_thread_db_load_1): Run integrity checks if requested.
8387 (maintenance_check_libthread_db): New function.
8388 (_initialize_thread_db): Register "maint check libthread-db"
8389 and "maint set/show check-libthread-db".
8390 * NEWS: Mention the above new commands.
8391
8392 2018-06-08 Tom Tromey <tom@tromey.com>
8393
8394 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
8395 now a method.
8396
8397 2018-06-08 Tom Tromey <tom@tromey.com>
8398
8399 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
8400
8401 2018-06-08 Tom Tromey <tom@tromey.com>
8402
8403 * common/btrace-common.h (struct btrace_data): Add constructor,
8404 destructor, move assignment operator.
8405 <empty, clear, fini>: New methods.
8406 <format>: Initialize.
8407 (btrace_data_init, btrace_data_fini, btrace_data_clear)
8408 (btrace_data_empty): Don't declare.
8409 * common/btrace-common.c (btrace_data_init): Remove.
8410 (btrace_data::fini): Rename from btrace_data_fini.
8411 (btrace_data::empty): Rename from btrace_data_empty.
8412 (btrace_data::clear): Rename from btrace_data_clear. Return
8413 bool.
8414 * btrace.h (make_cleanup_btrace_data): Don't declare.
8415 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
8416 (parse_xml_btrace): Update.
8417 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
8418 (maint_btrace_clear_packet_history_cmd): Update.
8419
8420 2018-06-07 Pedro Alves <palves@redhat.com>
8421
8422 * target.h (target_ops) <beneath>: Now a method. All references
8423 updated.
8424 (class target_stack): New.
8425 * target.c (g_target_stack): New.
8426 (g_current_top_target): Delete.
8427 (current_top_target): Get the top target out of g_target_stack.
8428 (target_stack::push, target_stack::unpush): New.
8429 (push_target, unpush_target): Reimplement.
8430 (target_is_pushed): Reimplement in terms of g_target_stack.
8431 (target_ops::beneath, target_stack::find_beneath): New.
8432
8433 2018-06-07 Pedro Alves <palves@redhat.com>
8434
8435 * target.h (find_target_beneath): Delete declaration.
8436 * target.c (find_target_beneath): Delete definition.
8437 * aix-thread.c: All callers of find_target_beneath adjusted to
8438 call target_ops::beneath instead.
8439 * bsd-uthread.c: Likewise.
8440 * linux-thread-db.c: Likewise.
8441 * ravenscar-thread.c: Likewise.
8442 * sol-thread.c: Likewise.
8443 * spu-multiarch.c: Likewise.
8444
8445 2018-06-07 Pedro Alves <palves@redhat.com>
8446
8447 * target.h (target_ops) <beneath>: Now a method. All references
8448 updated.
8449 (target_ops) <m_beneath>: New.
8450 * target.c (target_ops::beneath): New.
8451 * corelow.c: Adjust all references to target_ops::beneath.
8452 * linux-thread-db.c: Likewise.
8453 * make-target-delegates: Likewise.
8454 * record-btrace.c: Likewise.
8455 * record-full.c: Likewise.
8456 * remote.c: Likewise.
8457 * target.c: Likewise.
8458 * target-delegates.c: Regenerate.
8459
8460 2018-06-07 Pedro Alves <palves@redhat.com>
8461
8462 * target.h (target_stack): Delete.
8463 (current_top_target): Declare function.
8464 * target.c (target_stack): Delete.
8465 (g_current_top_target): New.
8466 (current_top_target): New function.
8467 * auxv.c: Use current_top_target instead of target_stack
8468 throughout.
8469 * avr-tdep.c: Likewise.
8470 * breakpoint.c: Likewise.
8471 * corefile.c: Likewise.
8472 * elfread.c: Likewise.
8473 * eval.c: Likewise.
8474 * exceptions.c: Likewise.
8475 * frame.c: Likewise.
8476 * gdbarch-selftests.c: Likewise.
8477 * gnu-v3-abi.c: Likewise.
8478 * ia64-tdep.c: Likewise.
8479 * ia64-vms-tdep.c: Likewise.
8480 * infcall.c: Likewise.
8481 * infcmd.c: Likewise.
8482 * infrun.c: Likewise.
8483 * linespec.c: Likewise.
8484 * linux-tdep.c: Likewise.
8485 * minsyms.c: Likewise.
8486 * ppc-linux-nat.c: Likewise.
8487 * ppc-linux-tdep.c: Likewise.
8488 * procfs.c: Likewise.
8489 * regcache.c: Likewise.
8490 * remote.c: Likewise.
8491 * rs6000-tdep.c: Likewise.
8492 * s390-linux-nat.c: Likewise.
8493 * s390-tdep.c: Likewise.
8494 * solib-aix.c: Likewise.
8495 * solib-darwin.c: Likewise.
8496 * solib-dsbt.c: Likewise.
8497 * solib-spu.c: Likewise.
8498 * solib-svr4.c: Likewise.
8499 * solib-target.c: Likewise.
8500 * sparc-tdep.c: Likewise.
8501 * sparc64-tdep.c: Likewise.
8502 * spu-tdep.c: Likewise.
8503 * symfile.c: Likewise.
8504 * symtab.c: Likewise.
8505 * target-descriptions.c: Likewise.
8506 * target-memory.c: Likewise.
8507 * target.c: Likewise.
8508 * target.h: Likewise.
8509 * tracefile-tfile.c: Likewise.
8510 * tracepoint.c: Likewise.
8511 * valops.c: Likewise.
8512 * valprint.c: Likewise.
8513 * value.c: Likewise.
8514 * windows-tdep.c: Likewise.
8515 * mi/mi-main.c: Likewise.
8516
8517 2018-06-07 Tom Tromey <tom@tromey.com>
8518
8519 * valprint.h (build_address_symbolic): Declare.
8520 * printcmd.c (print_address_symbolic): Update.
8521 (build_address_symbolic): Change "name" and "filename" to
8522 std::string.
8523 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
8524 Update.
8525 * defs.h (build_address_symbolic): Remove declaration.
8526
8527 2018-06-07 Alan Hayward <alan.hayward@arm.com>
8528
8529 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
8530 (aarch64_vnv_type): Add function.
8531 (aarch64_pseudo_register_name): Add V regs for SVE.
8532 (aarch64_pseudo_register_type): Likewise.
8533 (aarch64_pseudo_register_reggroup_p): Likewise.
8534 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
8535 (aarch64_pseudo_read_value): Add V regs for SVE.
8536 (aarch64_pseudo_write_2): Use V0 offset for SVE
8537 (aarch64_pseudo_write): Add V regs for SVE.
8538 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
8539
8540 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
8541
8542 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
8543 (sve_vl_from_vq): Likewise.
8544
8545 2018-06-05 Tom Tromey <tom@tromey.com>
8546
8547 * cli/cli-cmds.c (show_version): Update.
8548 * top.c (print_gdb_version): Add "interactive" parameter.
8549 Update.
8550 * main.c (captured_main_1): Update.
8551 * top.h (print_gdb_version): Add "interactive" parameter and a
8552 comment.
8553
8554 2018-06-05 David Malcolm <dmalcolm@redhat.com>
8555
8556 * common/enum-flags.h: Add trailing semicolon to example in
8557 comment.
8558
8559 2018-06-05 Tom Tromey <tom@tromey.com>
8560
8561 PR cli/12326:
8562 * NEWS: Add entry about pager.
8563 * utils.c (pagination_disabled_for_command): New global.
8564 (prompt_for_continue): Allow "c" response to prompt.
8565 (reinitialize_more_filter): Clear
8566 pagination_disabled_for_command.
8567 (fputs_maybe_filtered): Check pagination_disabled_for_command.
8568
8569 2018-06-04 Tom Tromey <tom@tromey.com>
8570
8571 * ada-lang.h (ada_lookup_symbol_list): Update.
8572 * ada-lang.c (resolve_subexp): Update.
8573 (symbols_are_identical_enums): Change type of syms. Remove nsyms
8574 parameter.
8575 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
8576 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
8577 results parameter to std::vector.
8578 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
8579 Update.
8580 * ada-exp.y (block_lookup): Update.
8581 (select_possible_type_sym): Change type of syms. Remove nsyms
8582 parameter.
8583 (write_var_or_type, write_name_assoc): Update.
8584
8585 2018-06-04 Joel Brobecker <brobecker@adacore.com>
8586
8587 * windows-nat.c (windows_nat_target::xfer_partial): Return
8588 TARGET_XFER_E_IO if we need to delegate to the target beneath
8589 but BENEATH is NULL.
8590
8591 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
8592
8593 * Makefile.in (config.status): Add configure.nat as a
8594 dependency.
8595
8596 2018-06-04 Tom Tromey <tom@tromey.com>
8597
8598 * cp-name-parser.y (cpname_state): Add method declarations.
8599 (HANDLE_QUAL): Update.
8600 (cpname_state::d_grab, cpname_state::fill_comp)
8601 (cpname_state::make_operator, cpname_state::make_dtor)
8602 (cpname_state::make_builtin_type, cpname_state::make_name)
8603 (cpname_state::d_qualify, cpname_state::d_int_type)
8604 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
8605 (%union): Move earlier.
8606
8607 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8608
8609 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
8610
8611 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8612
8613 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
8614 (aarch64_pseudo_write_1): Likewise.
8615 (aarch64_pseudo_read_value): Use helper.
8616 (aarch64_pseudo_write): Likewise.
8617
8618 2018-06-04 Pedro Alves <palves@redhat.com>
8619
8620 * darwin-nat.c (darwin_ops): Delete.
8621 (darwin_attach_pid): Use get_native_target.
8622
8623 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8624
8625 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
8626 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
8627
8628 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8629
8630 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
8631 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
8632 (aarch64_gdbarch_init): Check for SVE.
8633 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
8634
8635 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8636
8637 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
8638 * aarch64-tdep.h (aarch64_read_description): Likewise.
8639 * arch/aarch64.c (aarch64_create_target_description): Likewise.
8640 * arch/aarch64.h (aarch64_create_target_description): Likewise.
8641 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
8642 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
8643 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
8644
8645 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
8646
8647 * value.c (value_fetch_lazy_bitfield): New.
8648 (value_fetch_lazy_memory): New.
8649 (value_fetch_lazy_register): New.
8650 (value_fetch_lazy): Factor out to smaller functions.
8651
8652 2018-06-01 Tom Tromey <tom@tromey.com>
8653
8654 * cp-name-parser.y (backslashable, represented): Now const.
8655
8656 2018-06-01 Tom Tromey <tom@tromey.com>
8657
8658 * cp-name-parser.y: Include parser-defs.h.
8659 (parser_fprintf): Remove declaration.
8660
8661 2018-06-01 Tom Tromey <tom@tromey.com>
8662
8663 * cp-name-parser.y: Use %pure-parser, %lex-param, and
8664 %parse-param.
8665 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
8666 (global_result): Remove globals.
8667 (struct cpname_state): New.
8668 (yyparse): Don't declare.
8669 (yylex, yyerror): Move declarations after %union.
8670 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
8671 (make_name): Add state parameter.
8672 Update all callers.
8673 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
8674 parameter.
8675 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
8676 Update.
8677 (yylex): Add lvalp, state parameters.
8678 (yyerror): Add state parameter.
8679 (cp_demangled_name_to_comp): Update.
8680
8681 2018-06-01 Tom Tromey <tom@tromey.com>
8682
8683 * cp-name-parser.y (parser_fprintf): Declare.
8684 (GDB_YY_REMAP_PREFIX): Define.
8685 Include yy-remap.h. Don't redefine yy* identifiers.
8686
8687 2018-06-01 Tom Tromey <tom@tromey.com>
8688
8689 * python/py-type.c (typy_legacy_template_argument): Update.
8690 * cp-support.h (cp_demangled_name_to_comp): Update.
8691 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
8692 parameter to be a "std::string *".
8693 (main): Update.
8694
8695 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
8696
8697 * ada-lex.l: Include "diagnostics.h" instead of
8698 "common/diagnostics.h".
8699 * unittests/environ-selftests.c: Likewise.
8700 * common/diagnostics.h: Moved to ../include.
8701
8702 2018-06-01 Joel Brobecker <brobecker@adacore.com>
8703
8704 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
8705 to language_mode_manual while calling breakpoint_re_set_one.
8706
8707 2018-06-01 Tom Tromey <tom@tromey.com>
8708
8709 * valops.c (value_cast_structs, destructor_name_p): Update.
8710 * symtab.c (gdb_mangle_name): Update.
8711 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
8712 Update.
8713 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
8714 (pascal_object_print_value_fields, pascal_object_print_value):
8715 Update.
8716 * p-typeprint.c (pascal_type_print_derivation_info): Update.
8717 * linespec.c (find_methods): Update.
8718 * gdbtypes.h (type_name_no_tag): Remove.
8719 (type_name_or_error): Rename from type_name_no_tag_or_error.
8720 * gdbtypes.c (type_name_no_tag): Remove.
8721 (type_name_or_error): Rename from type_name_no_tag_or_error.
8722 (lookup_struct_elt_type, check_typedef): Update.
8723 * expprint.c (print_subexp_standard): Update.
8724 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
8725 * d-namespace.c (d_lookup_nested_symbol): Update.
8726 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
8727 (cp_print_class_member): Update.
8728 * cp-namespace.c (cp_lookup_nested_symbol): Update.
8729 * completer.c (add_struct_fields): Update.
8730 * c-typeprint.c (cp_type_print_derivation_info)
8731 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
8732 Update.
8733 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
8734 (ada_prefer_type, ada_is_exception_sym): Update.
8735
8736 2018-06-01 Tom Tromey <tom@tromey.com>
8737
8738 * valops.c (enum_constant_from_type, value_namespace_elt)
8739 (value_maybe_namespace_elt): Update.
8740 * valarith.c (find_size_for_pointer_math): Update.
8741 * target-descriptions.c (make_gdb_type): Update.
8742 * symmisc.c (print_symbol): Update.
8743 * stabsread.c (define_symbol, read_type)
8744 (complain_about_struct_wipeout, add_undefined_type)
8745 (cleanup_undefined_types_1): Update.
8746 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
8747 (rust_range_type_p, val_print_struct, rust_print_struct_def)
8748 (rust_internal_print_type, rust_composite_type)
8749 (rust_evaluate_funcall, rust_evaluate_subexp)
8750 (rust_inclusive_range_type_p): Update.
8751 * python/py-type.c (typy_get_tag): Update.
8752 * p-typeprint.c (pascal_type_print_base): Update.
8753 * mdebugread.c (parse_symbol, parse_type): Update.
8754 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
8755 Update.
8756 * guile/scm-type.c (gdbscm_type_tag): Update.
8757 * go-lang.c (sixg_string_p): Update.
8758 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
8759 Update.
8760 * gdbtypes.h (struct main_type) <tag_name>: Remove.
8761 (TYPE_TAG_NAME): Remove.
8762 * gdbtypes.c (type_name_no_tag): Simplify.
8763 (check_typedef, check_types_equal, recursive_dump_type)
8764 (copy_type_recursive, arch_composite_type): Update.
8765 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
8766 in summary mode when needed.
8767 * eval.c (evaluate_funcall): Update.
8768 * dwarf2read.c (fixup_go_packaging, read_structure_type)
8769 (process_structure_scope, read_enumeration_type)
8770 (read_namespace_type, read_module_type, determine_prefix): Update.
8771 * cp-support.c (inspect_type): Update.
8772 * coffread.c (process_coff_symbol, decode_base_type): Update.
8773 * c-varobj.c (c_is_path_expr_parent): Update.
8774 * c-typeprint.c (c_type_print_base_struct_union): Update.
8775 (c_type_print_base_1): Update. Print struct/class/union/enum in
8776 summary when using C language.
8777 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
8778 (gen_maybe_namespace_elt): Update.
8779 * ada-lang.c (ada_type_name): Simplify.
8780 (empty_record, ada_template_to_fixed_record_type_1)
8781 (template_to_static_fixed_type)
8782 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
8783
8784 2018-06-01 Tom Tromey <tom@tromey.com>
8785
8786 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
8787 c_print_type.
8788 * c-typeprint.c (c_print_type_1): Add "language" parameter.
8789 (c_print_type): Update.
8790 (c_print_type): New overload.
8791 (c_type_print_varspec_prefix, c_type_print_args)
8792 (c_type_print_varspec_suffix, c_print_type_no_offsets)
8793 (c_type_print_base_struct_union, c_type_print_base_1)
8794 (cp_type_print_method_args): Add "language" parameter.
8795 (c_type_print_base): Update.
8796 * c-lang.h (c_print_type): Add new overload.
8797
8798 2018-06-01 Tom Tromey <tom@tromey.com>
8799
8800 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
8801 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
8802
8803 2018-06-01 Alan Hayward <alan.hayward@arm.com>
8804
8805 * aarch64-tdep.c (aarch64_sve_register_names): New const
8806 var.
8807 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
8808 (AARCH64_SVE_Z_REGS_NUM): New define.
8809 (AARCH64_SVE_P_REGS_NUM): Likewise.
8810 (AARCH64_SVE_NUM_REGS): Likewise.
8811
8812 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
8813
8814 * nat/linux-ptrace.h [__alpha__]
8815 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
8816 definitions.
8817
8818 2018-05-31 Maciej W. Rozycki <macro@mips.com>
8819
8820 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
8821 the endianness selected.
8822 * NEWS: Document `set endian auto' mode operation update.
8823
8824 2018-05-31 Alan Hayward <alan.hayward@arm.com>
8825
8826 * Makefile.in: Add new header.
8827 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
8828 (sve_vl_from_vg): Likewise.
8829 (sve_vq_from_vl): Likewise.
8830 (sve_vl_from_vq): Likewise.
8831 (sve_vq_from_vg): Likewise.
8832 (sve_vg_from_vq): Likewise.
8833 * configure.nat: Add new c file.
8834 * nat/aarch64-sve-linux-ptrace.c: New file.
8835 * nat/aarch64-sve-linux-ptrace.h: New file.
8836
8837 2018-05-31 Alan Hayward <alan.hayward@arm.com>
8838
8839 * aarch64-linux-nat.c (aarch64_linux_read_description):
8840 Add parmeter zero.
8841 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
8842 Likewise.
8843 * aarch64-tdep.c (tdesc_aarch64_list): Add.
8844 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
8845 (aarch64_gdbarch_init): Add parmeter zero.
8846 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
8847 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
8848 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
8849 parmeter.
8850 * doc/gdb.texinfo: Describe SVE feature
8851 * features/aarch64-sve.c: New file.
8852
8853 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
8854
8855 PR gdb/23210
8856 * gdbarch.sh (significant_addr_bit): Default to zero when
8857 not set by target architecture.
8858 * gdbarch.c: Re-generated.
8859 * utils.c (address_significant): Update.
8860
8861 2018-05-30 Joel Brobecker <brobecker@adacore.com>
8862
8863 * stack.c (func_command): Remove trailing newline in call to error.
8864
8865 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8866
8867 * regcache.h (regcache_raw_collect): Remove, update callers to
8868 use regcache::raw_collect.
8869 * regcache.c (regcache_raw_collect): Remove.
8870
8871 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8872
8873 * regcache.h (regcache_raw_supply): Remove, update callers to
8874 use detached_regcache::raw_supply.
8875 * regcache.c (regcache_raw_supply): Remove.
8876
8877 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8878
8879 * regcache.h (regcache_cooked_write_part): Remove, update
8880 callers to use regcache::cooked_write_part.
8881 * regcache.c (regcache_cooked_write_part): Remove.
8882
8883 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8884
8885 * regcache.h (regcache_cooked_read_part): Remove, update callers
8886 to use readable_regcache::cooked_read_part.
8887 * regcache.c (regcache_cooked_read_part): Remove.
8888
8889 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8890
8891 * regcache.h (regcache_cooked_read_value): Remove, update
8892 callers to use readable_regcache::cooked_read_value.
8893 * regcache.c (regcache_cooked_read_value): Remove.
8894
8895 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8896
8897 * regcache.h (regcache_cooked_write): Remove, update callers to
8898 use regcache::cooked_write.
8899 * regcache.c (regcache_cooked_write): Remove.
8900
8901 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8902
8903 * regcache.h (regcache_invalidate): Remove, update callers to
8904 use detached_regcache::invalidate instead.
8905 * regcache.c (regcache_invalidate): Remove.
8906
8907 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8908
8909 * regcache.h (regcache_raw_write_part): Remove, update callers
8910 to use regcache::raw_write_part instead.
8911 * regcache.c (regcache_raw_write_part): Remove.
8912
8913 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8914
8915 * regcache.h (regcache_raw_read_part): Remove, update callers to
8916 use readable_regcache::raw_read_part instead.
8917 * regcache.c (regcache_raw_read_part): Remove.
8918
8919 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8920
8921 * regcache.h (regcache_cooked_read): Remove, update callers to
8922 use readable_regcache::cooked_read instead.
8923 * regcache.c (regcache_cooked_read): Remove.
8924
8925 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8926
8927 * regcache.h (regcache_raw_write): Remove, update callers to use
8928 regcache::raw_write instead.
8929 * regcache.c (regcache_raw_write): Remove.
8930
8931 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8932
8933 * regcache.h (regcache_raw_read): Remove, update callers to use
8934 readable_regcache::raw_read instead.
8935 * regcache.c (regcache_raw_read): Remove.
8936
8937 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8938
8939 * regcache.h (regcache_raw_update): Remove, update callers to
8940 use readable_regcache::raw_update instead.
8941 * regcache.c (regcache_raw_update): Remove.
8942
8943 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8944
8945 * regcache.h (regcache_register_status): Remove, update callers
8946 to use reg_buffer::get_register_status directly instead.
8947 * regcache.c (regcache_register_status): Remove.
8948
8949 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8950
8951 * regcache.h (regcache_get_ptid): Remove, update all callers to
8952 call regcache::ptid instead.
8953 * regcache.c (regcache_get_ptid): Remove.
8954
8955 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8956
8957 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
8958
8959 2018-05-30 Pedro Alves <palves@redhat.com>
8960
8961 * common/common-exceptions.h (exception_rethrow): Use
8962 ATTRIBUTE_NORETURN.
8963
8964 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
8965
8966 * breakpoint.c (print_solib_event, check_status_catch_solib):
8967 Remove struct keyword in range-based for loops.
8968 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
8969 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
8970 Likewise.
8971 * linespec.c (find_superclass_methods, search_minsyms_for_name):
8972 Likewise.
8973 * symfile.c (addr_info_make_relative): Likewise.
8974 * thread.c (value_in_thread_stack_temporaries): Likewise.
8975
8976 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
8977
8978 PR gdb/16841
8979 * valops.c (value_struct_elt_for_reference): Call check_typedef on
8980 aggregate type to get its real type before accessing it.
8981
8982 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
8983
8984 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
8985 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
8986 * coff-pe-read.c (add_pe_forwarded_sym): Replace
8987 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
8988 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
8989 * jit.c (jit_breakpoint_re_set_internal): Likewise.
8990 * printcmd.c (info_address_command): Likewise.
8991
8992 2018-05-29 Tom Tromey <tom@tromey.com>
8993
8994 * windows-nat.c (handle_exception): Update fall-through comment.
8995
8996 2018-05-29 Tom Tromey <tom@tromey.com>
8997
8998 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
8999 (struct program_space) <added_solibs>: Now a std::vector.
9000 * breakpoint.c (print_solib_event): Update.
9001 (check_status_catch_solib): Update.
9002 * progspace.c (clear_program_space_solib_cache): Update.
9003 * solib.c (update_solib_list): Update.
9004
9005 2018-05-29 Tom Tromey <tom@tromey.com>
9006
9007 * python/py-type.c (typy_richcompare): Update.
9008 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
9009 * gdbtypes.h (types_deeply_equal): Return bool.
9010 (types_equal): Likewise.
9011 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
9012 declare VEC.
9013 (check_types_equal): Change worklist to std::vector. Return
9014 bool.
9015 (struct type_equality_entry): Add constructor.
9016 (compare_maybe_null_strings): Return bool.
9017 (check_types_worklist): Return bool. Change worklist to
9018 std::vector.
9019 (types_deeply_equal): Use std::vector.
9020 (types_equal): Return bool.
9021 (compare_maybe_null_strings): Simplify.
9022
9023 2018-05-29 Tom Tromey <tom@tromey.com>
9024
9025 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
9026
9027 2018-05-29 Tom Tromey <tom@tromey.com>
9028
9029 * objc-lang.h: Don't include cp-support.h.
9030 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
9031 declare VEC.
9032
9033 2018-05-27 Tom Tromey <tom@tromey.com>
9034
9035 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
9036
9037 2018-05-25 Tom Tromey <tom@tromey.com>
9038
9039 * value.c (value::location): Initialize.
9040
9041 2018-05-25 Tom Tromey <tom@tromey.com>
9042
9043 * dbxread.c (init_bincl_list): Remove.
9044 (bincl_list): Now a std::vector.
9045 (bincls_allocated, next_bincl): Remove.
9046 (free_bincl_list, do_free_bincl_list_cleanup)
9047 (make_cleanup_free_bincl_list): Remove.
9048 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
9049 unique_xmalloc_ptr.
9050 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
9051 (struct header_file_location): Add constructor.
9052 (add_bincl_to_list): Remove.
9053
9054 2018-05-25 Tom Tromey <tom@tromey.com>
9055
9056 * tui/tui.c (tui_enable): Update.
9057 * mi/mi-interp.c (mi_interp::init): Update.
9058 * interps.h (class interp) <name>: New method.
9059 <m_name>: Rename from name.
9060 (~scoped_restore_interp): Update.
9061 * interps.c (interp::interp): Update.
9062 (interp_add, interp_set, interp_lookup_existing)
9063 (current_interp_named_p): Update.
9064
9065 2018-05-25 Tom Tromey <tom@tromey.com>
9066
9067 * interps.c (interp_name): Remove.
9068 * mi/mi-interp.c (mi_interp::init): Update.
9069 * interps.h (interp_name): Remove.
9070 (~scoped_restore_interp): Update.
9071 * tui/tui.c (tui_enable): Update.
9072
9073 2018-05-25 Tom Tromey <tom@tromey.com>
9074
9075 * utils.c (fputs_maybe_filtered): Update.
9076 * linespec.c (decode_line_full): Update.
9077 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
9078 (mi_print_breakpoint_for_event, mi_solib_loaded)
9079 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
9080 (mi_user_selected_context_changed): Update.
9081 * mi/mi-main.c (mi_execute_command): Update.
9082 * cli/cli-script.c (execute_control_command): Update.
9083 * python/python.c (execute_gdb_command): Update.
9084 * solib.c (info_sharedlibrary_command): Update.
9085 * interps.c (interp_ui_out): Remove.
9086 * interps.h (interp_ui_out): Remove.
9087
9088 2018-05-25 Tom Tromey <tom@tromey.com>
9089
9090 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
9091 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
9092 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
9093
9094 2018-05-25 Tom Tromey <tom@tromey.com>
9095
9096 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
9097 * interps.c (interp_exec): Use scoped_restore.
9098
9099 2018-05-25 Tom Tromey <tom@tromey.com>
9100
9101 * remote.c (remote_target::remote_file_get): Use
9102 gdb::byte_vector.
9103 (remote_target::remote_file_put): Likewise.
9104
9105 2018-05-25 Tom Tromey <tom@tromey.com>
9106
9107 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
9108 a std::string.
9109 (get_pe_section_index, add_pe_exported_sym): Update.
9110 (read_pe_exported_syms): Use gdb::def_vector.
9111
9112 2018-05-25 Tom Tromey <tom@tromey.com>
9113
9114 * frame.c (remove_prev_frame): Remove.
9115 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
9116
9117 2018-05-25 Maciej W. Rozycki <macro@mips.com>
9118
9119 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
9120 Remove prototypes.
9121 * mips-linux-nat.c (supply_fpregset): Always call
9122 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
9123 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
9124 `mips_fill_fpregset'.
9125 * mips-linux-tdep.c (mips_supply_fpregset)
9126 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
9127 (mips_fill_fpregset_wrapper): Remove functions.
9128 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
9129 (mips_linux_fpregset): Remove variable.
9130 (mips_linux_iterate_over_regset_sections): Use
9131 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
9132 (mips_linux_o32_sigframe_init): Remove comment.
9133
9134 2018-05-25 Pedro Alves <palves@redhat.com>
9135
9136 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
9137 (struct readahead_cache, struct packet_reg, struct
9138 remote_arch_state, class remote_state): Move higher up in the
9139 file.
9140 (remote_target::m_remote_state): Now an object instead of a pointer.
9141 (remote_target::get_remote_state): Adjust.
9142
9143 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
9144
9145 * stack.c (select_and_print_frame): Delete.
9146 (struct function_bounds): Move struct within function.
9147 (func_command): Most content moved into new function
9148 find_frame_for_function, use new function, print result, add
9149 function comment.
9150 (find_frame_for_function): New function, now returns a result.
9151
9152 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9153
9154 * stack.c (iterate_over_block_arg_vars): Fix comment.
9155 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
9156
9157 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
9158
9159 PR gdb/23203
9160 * frame.c
9161 (scoped_restore_selected_frame::scoped_restore_selected_frame):
9162 Define.
9163 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
9164 Define.
9165 * frame.h (class scoped_restore_selected_frame): New class.
9166 * stack.c (print_frame_local_vars): Remove catching and rethrowing
9167 of any exception, use scoped_restore_selected_frame to restore the
9168 frame instead.
9169
9170 2018-05-24 Pedro Alves <palves@redhat.com>
9171
9172 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
9173 override.
9174
9175 2018-05-23 Tom Tromey <tom@tromey.com>
9176
9177 * complaints.c (struct complaints): Remove.
9178 (symfile_complaint_book): Remove.
9179 (series): New global.
9180 (complaint_internal): Update.
9181 (clear_complaints): Update.
9182
9183 2018-05-23 Tom Tromey <tom@tromey.com>
9184
9185 * complaints.c (counters): New global.
9186 (struct complain): Remove.
9187 (struct complaints) <root>: Remove.
9188 (complaint_sentinel): Remove.
9189 (symfile_complaint_book): Update.
9190 (find_complaint) Remove.
9191 (complaint_internal, clear_complaints): Update.
9192
9193 2018-05-23 Tom Tromey <tom@tromey.com>
9194
9195 * complaints.c (struct complain) <file, line>: Remove.
9196 (find_complaint): Remove file, line parameters.
9197 (complaint_internal): Update.
9198
9199 2018-05-23 Tom Tromey <tom@tromey.com>
9200
9201 * complaints.c (vcomplaint): Remove.
9202 (complaint_internal) Merge in contents of vcomplaint.
9203
9204 2018-05-23 Tom Tromey <tom@tromey.com>
9205
9206 * complaints.c (struct complaints) <explanation>: Remove.
9207 (symfile_explanations): Remove.
9208 (symfile_complaint_book): Update.
9209 (vcomplaint): Update.
9210 (struct explanation): Remove.
9211
9212 2018-05-23 Tom Tromey <tom@tromey.com>
9213
9214 * complaints.c (symfile_complaints): Remove.
9215 (complaint_internal): Remove "complaints" parameter.
9216 (clear_complaints, vcomplaint): Remove "c" parameter.
9217 (get_complaints): Remove.
9218 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
9219 (dwarf2_debug_line_missing_file_complaint)
9220 (dwarf2_debug_line_missing_end_sequence_complaint)
9221 (dwarf2_complex_location_expr_complaint)
9222 (dwarf2_const_value_length_mismatch_complaint)
9223 (dwarf2_section_buffer_overflow_complaint)
9224 (dwarf2_macro_malformed_definition_complaint)
9225 (dwarf2_invalid_attrib_class_complaint)
9226 (create_addrmap_from_index, dw2_symtab_iter_next)
9227 (dw2_expand_marked_cus)
9228 (dw2_debug_names_iterator::find_vec_in_debug_names)
9229 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
9230 (create_debug_type_hash_table, init_cutu_and_read_dies)
9231 (partial_die_parent_scope, add_partial_enumeration)
9232 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
9233 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
9234 (read_import_statement, read_file_scope, create_dwo_cu_reader)
9235 (create_cus_hash_table, create_dwp_hash_table)
9236 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
9237 (dwarf2_rnglists_process, dwarf2_ranges_process)
9238 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
9239 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
9240 (handle_struct_member_die, process_structure_scope)
9241 (read_array_type, read_common_block, read_module_type)
9242 (read_tag_pointer_type, read_typedef, read_base_type)
9243 (read_subrange_type, load_partial_dies, partial_die_info::read)
9244 (partial_die_info::read, partial_die_info::read)
9245 (partial_die_info::read, read_checked_initial_length_and_offset)
9246 (dwarf2_string_attr, read_formatted_entries)
9247 (dwarf_decode_line_header)
9248 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
9249 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
9250 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
9251 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
9252 (get_signatured_type, get_DW_AT_signature_type)
9253 (decode_locdesc, file_file_name, consume_improper_spaces)
9254 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
9255 (dwarf_decode_macro_bytes, dwarf_decode_macros)
9256 (dwarf2_symbol_mark_computed, set_die_type)
9257 (read_attribute_value): Update.
9258 * stap-probe.c (handle_stap_probe, get_stap_base_address):
9259 Update.
9260 * dbxread.c (unknown_symtype_complaint)
9261 (lbrac_mismatch_complaint, repeated_header_complaint)
9262 (set_namestring, function_outside_compilation_unit_complaint)
9263 (read_dbx_symtab, process_one_symbol): Update.
9264 * gdbtypes.c (stub_noname_complaint): Update.
9265 * windows-nat.c (handle_unload_dll): Update.
9266 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
9267 (decode_base_type): Update.
9268 * xcoffread.c (bf_notfound_complaint, ef_complaint)
9269 (eb_complaint, record_include_begin, record_include_end)
9270 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
9271 (process_xcoff_symbol, read_symbol)
9272 (function_outside_compilation_unit_complaint)
9273 (scan_xcoff_symtab): Update.
9274 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
9275 * buildsym.c (finish_block_internal, make_blockvector)
9276 (end_symtab_get_static_block, augment_type_symtab): Update.
9277 * dtrace-probe.c (dtrace_process_dof)
9278 (dtrace_static_probe_ops::get_probes): Update.
9279 * complaints.h (struct complaint): Don't declare.
9280 (symfile_complaints): Remove.
9281 (complaint_internal): Remove "complaints" parameter.
9282 (complaint): Likewise.
9283 (clear_complaints): Likewise.
9284 * symfile.c (syms_from_objfile_1, finish_new_objfile)
9285 (reread_symbols): Update.
9286 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
9287 (dwarf2_frame_cache, decode_frame_entry): Update.
9288 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
9289 * objc-lang.c (lookup_objc_class, lookup_child_selector)
9290 (info_selectors_command): Update.
9291 * macrotab.c (macro_include, check_for_redefinition)
9292 (macro_undef): Update.
9293 * objfiles.c (filter_overlapping_sections): Update.
9294 * stabsread.c (invalid_cpp_abbrev_complaint)
9295 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
9296 (define_symbol, error_type, read_type, rs6000_builtin_type)
9297 (stabs_method_name_from_physname, read_member_functions)
9298 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
9299 (attach_fields_to_type, complain_about_struct_wipeout)
9300 (read_range_type, read_args, common_block_start)
9301 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
9302 Update.
9303 * mdebugread.c (index_complaint, unknown_ext_complaint)
9304 (basic_type_complaint, bad_tag_guess_complaint)
9305 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
9306 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
9307 (parse_procedure, parse_lines)
9308 (function_outside_compilation_unit_complaint)
9309 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
9310 (bad_tag_guess_complaint, reg_value_complaint): Update.
9311 * cp-support.c (demangled_name_complaint): Update.
9312 * macroscope.c (sal_macro_scope): Update.
9313 * dwarf-index-write.c (class debug_names): Update.
9314
9315 2018-05-23 Tom Tromey <tom@tromey.com>
9316
9317 * complaints.c (clear_complaints): Remove "noisy" parameter.
9318 * complaints.h (clear_complaints): Update.
9319 * symfile.c (syms_from_objfile_1, finish_new_objfile)
9320 (reread_symbols): Update.
9321
9322 2018-05-23 Tom Tromey <tom@tromey.com>
9323
9324 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
9325 SUBSEQUENT_MESSAGE.
9326 (vcomplaint, clear_complaints): Update.
9327 (symfile_explanations): Remove some messages.
9328
9329 2018-05-23 Tom Tromey <tom@tromey.com>
9330
9331 * complaints.c (internal_complaint): Remove.
9332 * complaints.h (internal_complaint): Remove.
9333
9334 2018-05-22 Maciej W. Rozycki <macro@mips.com>
9335
9336 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
9337
9338 2018-05-22 Pedro Alves <palves@redhat.com>
9339
9340 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
9341 (remote_fileio_badfd, remote_fileio_return_errno)
9342 (remote_fileio_return_success, remote_fileio_func_open)
9343 (remote_fileio_func_open, remote_fileio_func_close)
9344 (remote_fileio_func_read, remote_fileio_func_write)
9345 (remote_fileio_func_lseek, remote_fileio_func_rename)
9346 (remote_fileio_func_unlink, remote_fileio_func_stat)
9347 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
9348 (remote_fileio_func_isatty, remote_fileio_func_system): Add
9349 remote_target parameter.
9350 (remote_fio_func_map) <func>: Add remote_target parameter.
9351 (do_remote_fileio_request, remote_fileio_request):
9352 * remote-fileio.h (remote_fileio_request):
9353 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
9354 remote_target parameter.
9355 (remote_notif_process, handle_notification): Adjust to pass down
9356 the remote.
9357 (remote_notif_state_allocate): Add remote_target parameter. Save
9358 it.
9359 * remote-notif.h (struct remote_target): Forward declare.
9360 (struct notif_client) <parse, ack, can_get_pending_events>: Add
9361 remote_target parameter.
9362 (struct remote_notif_state) <remote>: New field.
9363 (remote_notif_ack, remote_notif_parse): Add remote_target
9364 parameter.
9365 (remote_notif_state_allocate, remote_notif_state_allocate): Add
9366 remote_target parameter.
9367 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
9368 (threads_listing_context, rmt_thread_action, protocol_feature)
9369 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
9370 (packet_result, struct threads_listing_context, remote_state):
9371 Move definitions and declarations higher up.
9372 (remote_target) <~remote_target>: Declare.
9373 (remote_download_command_source, remote_file_put, remote_file_get)
9374 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
9375 (remote_hostio_pread_vFile, remote_hostio_send_command)
9376 (remote_hostio_set_filesystem, remote_hostio_open)
9377 (remote_hostio_close, remote_hostio_unlink, remote_state)
9378 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
9379 (get_memory_write_packet_size, get_memory_read_packet_size)
9380 (append_pending_thread_resumptions, remote_detach_1)
9381 (append_resumption, remote_resume_with_vcont)
9382 (add_current_inferior_and_thread, wait_ns, wait_as)
9383 (process_stop_reply, remote_notice_new_inferior)
9384 (process_initial_stop_replies, remote_add_thread)
9385 (btrace_sync_conf, remote_btrace_maybe_reopen)
9386 (remove_new_fork_children, kill_new_fork_children)
9387 (discard_pending_stop_replies, stop_reply_queue_length)
9388 (check_pending_events_prevent_wildcard_vcont)
9389 (discard_pending_stop_replies_in_queue, stop_reply)
9390 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
9391 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
9392 (remote_interrupt_as, remote_interrupt_ns)
9393 (remote_get_noisy_reply, remote_query_attached)
9394 (remote_add_inferior, remote_current_thread, get_current_thread)
9395 (set_thread, set_general_thread, set_continue_thread)
9396 (set_general_process, write_ptid)
9397 (remote_unpack_thread_info_response, remote_get_threadinfo)
9398 (parse_threadlist_response, remote_get_threadlist)
9399 (remote_threadlist_iterator, remote_get_threads_with_ql)
9400 (remote_get_threads_with_qxfer)
9401 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
9402 (get_offsets, remote_check_symbols, remote_supported_packet)
9403 (remote_query_supported, remote_packet_size)
9404 (remote_serial_quit_handler, remote_detach_pid)
9405 (remote_vcont_probe, remote_resume_with_hc)
9406 (send_interrupt_sequence, interrupt_query)
9407 (remote_notif_get_pending_events, fetch_register_using_p)
9408 (send_g_packet, process_g_packet, fetch_registers_using_g)
9409 (store_register_using_P, store_registers_using_G)
9410 (set_remote_traceframe, check_binary_download)
9411 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
9412 (remote_xfer_live_readonly_partial, remote_read_bytes)
9413 (remote_send_printf, remote_flash_write, readchar)
9414 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
9415 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
9416 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
9417 (extended_remote_disable_randomization, extended_remote_run)
9418 (send_environment_packet, extended_remote_environment_support)
9419 (extended_remote_set_inferior_cwd, remote_write_qxfer)
9420 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
9421 (packet_command): Now methods of ...
9422 (remote_target): ... this class.
9423 (m_remote_state) <remote_target>: New field.
9424 (struct remote_state) <stop_reply_queue,
9425 remote_async_inferior_event_token, wait_forever_enabled_p>: New
9426 fields.
9427 (remote_state::remote_state): Allocate stop_reply_queue.
9428 (remote_state): Delete global.
9429 (get_remote_state_raw): Delete.
9430 (remote_target::get_remote_state): Allocate m_remote_state on
9431 demand.
9432 (get_current_remote_target): New.
9433 (remote_ops, extended_remote_ops): Delete.
9434 (wait_forever_enabled_p, remote_async_inferior_event_token):
9435 Delete, moved to struct remote_state.
9436 (remote_target::close): Delete self. Destruction bits split to
9437 ...
9438 (remote_target::~remote_target): ... this.
9439 (show_memory_packet_size): Adjust to use
9440 get_current_remote_target.
9441 (struct protocol_feature) <func>: Add remote_target parameter.
9442 All callers adjusted.
9443 (curr_quit_handler_target): New.
9444 (remote_serial_quit_handler): Reimplement.
9445 (remote_target::open_1): Adjust to use get_current_remote_target.
9446 Heap-allocate remote_target/extended_remote_target instances.
9447 (vcont_builder::vcont_builder): Add remote_target parameter, and
9448 save it in m_remote. All callers adjusted.
9449 (vcont_builder::m_remote): New field.
9450 (vcont_builder::restart, vcont_builder::flush)
9451 (vcont_builder::push_action): Use it.
9452 (remote_target::commit_resume): Use it.
9453 (struct queue_iter_param) <remote>: New field.
9454 (remote_target::remove_new_fork_children): Fill in 'remote' field.
9455 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
9456 (check_pending_event_prevents_wildcard_vcont_callback)
9457 (remote_target::check_pending_events_prevent_wildcard_vcont)
9458 (remote_target::discard_pending_stop_replies)
9459 (remote_target::discard_pending_stop_replies_in_queue)
9460 (remote_target::remote_notif_remove_queued_reply): Fill in
9461 'remote' field.
9462 (remote_notif_get_pending_events): New.
9463 (remote_target::readchar, remote_target::remote_serial_write):
9464 Save/restore curr_quit_handler_target.
9465 (putpkt): New.
9466 (kill_new_fork_children): Fill in 'remote' field.
9467 (packet_command): Use get_current_remote_target, defer to
9468 remote_target method of same name.
9469 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
9470 parameter, and save it in m_remote. All callers adjusted.
9471 (scoped_remote_fd::release): Use m_remote.
9472 (scoped_remote_fd::m_remote): New field.
9473 (remote_file_put, remote_file_get, remote_file_delete): Use
9474 get_current_remote_target, defer to remote_target method of same
9475 name.
9476 (remote_btrace_reset): Add remote_state paremeter. Update all
9477 callers.
9478 (remote_async_inferior_event_handler). Pass down 'data'.
9479 (remote_new_objfile): Use get_current_remote_target.
9480 (remote_target::vcont_r_supported): New.
9481 (set_range_stepping): Use get_current_remote_target and
9482 remote_target::vcont_r_supported.
9483 (_initialize_remote): Don't allocate 'remote_state' and
9484 'stop_reply_queue' globals.
9485 * remote.h (struct remote_target): Forward declare.
9486 (getpkt, putpkt, remote_notif_get_pending_events): Add
9487 'remote_target' parameter.
9488
9489 2018-05-22 Pedro Alves <palves@redhat.com>
9490
9491 * remote.c (vcont_builder): Now a class. Make all data members
9492 private.
9493 (vcont_builder) <vcont_builder, restart, flush, push_action>:
9494 Declare methods.
9495 (vcont_builder_restart): Rename to ...
9496 (vcont_builder::restart): ... this.
9497 (vcont_builder_flush): Rename to ...
9498 (vcont_builder::flush): ... this.
9499 (vcont_builder_push_action): Rename to ...
9500 (vcont_builder::push_action): ... this.
9501 (remote_target::commit_resume): Adjust.
9502
9503 2018-05-22 Pedro Alves <palves@redhat.com>
9504
9505 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
9506 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
9507 (get_fixed_memory_packet_size): New.
9508 (get_memory_packet_size): Use it.
9509 (set_memory_packet_size): Don't override the config size with
9510 DEFAULT_MAX_MEMORY_PACKET_SIZE.
9511 (show_memory_packet_size): Use get_fixed_memory_packet_size.
9512 Don't refer to get_memory_packet_size if not connected to a remote
9513 target. Show "(default)" if configured size is 0.
9514
9515 2018-05-22 Pedro Alves <palves@redhat.com>
9516
9517 * remote.c (remote_target::mourn_inferior): Move
9518 discard_pending_stop_replies call here from ...
9519 (_initialize_remote): ... here.
9520
9521 2018-05-22 Pedro Alves <palves@redhat.com>
9522
9523 * remote.c (compare_section_command): Remove set_general_process
9524 call.
9525
9526 2018-05-22 Pedro Alves <palves@redhat.com>
9527
9528 * remote.c (struct packet_reg, struct remote_arch_state):
9529 Move higher up in the file.
9530 (remote_state) <m_arch_states>: Store remote_arch_state values
9531 instead of remote_arch_state pointers.
9532 (remote_state::get_remote_arch_state): Adjust.
9533
9534 2018-05-22 Pedro Alves <palves@redhat.com>
9535
9536 * remote.c: Include <unordered_map>.
9537 (remote_state): Now a class.
9538 (remote_state) <get_remote_arch_state>: Declare method.
9539 <get_remote_arch_state>: New field.
9540 (remote_arch_state) <remote_arch_state>: Declare ctor.
9541 <regs>: Now a unique_ptr.
9542 (remote_gdbarch_data_handle): Delete.
9543 (get_remote_arch_state): Delete.
9544 (remote_state::get_remote_arch_state): New.
9545 (get_remote_state): Adjust to call remote_state's
9546 get_remote_arch_state method.
9547 (init_remote_state): Delete, bits factored out to ...
9548 (remote_arch_state::remote_arch_state): ... this new method.
9549 (get_remote_packet_size, get_memory_packet_size)
9550 (process_g_packet, remote_target::fetch_registers)
9551 (remote_target::prepare_to_store, store_registers_using_G)
9552 (remote_target::store_registers, remote_target::get_trace_status):
9553 Adjust to call remote_state's method.
9554 (_initialize_remote): Remove reference to
9555 remote_gdbarch_data_handle.
9556
9557 2018-05-22 Pedro Alves <palves@redhat.com>
9558
9559 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
9560 pread>: New method declarations.
9561 (remote_target::open_1): Adjust.
9562 (readahead_cache_invalidate): Rename to ...
9563 (readahead_cache::invalidate): ... this, and adjust to be a class
9564 method.
9565 (readahead_cache_invalidate_fd): Rename to ...
9566 (readahead_cache::invalidate_fd): ... this, and adjust to be a
9567 class method.
9568 (remote_hostio_pwrite): Adjust.
9569 (remote_hostio_pread_from_cache): Rename to ...
9570 (readahead_cache::pread): ... this, and adjust to be a class
9571 method.
9572 (remote_hostio_close): Adjust.
9573
9574 2018-05-22 Pedro Alves <palves@redhat.com>
9575
9576 * remote.c (remote_hostio_close_cleanup): Delete.
9577 (class scoped_remote_fd): New.
9578 (remote_file_put, remote_file_get): Use it.
9579
9580 2018-05-22 Pedro Alves <palves@redhat.com>
9581
9582 (struct vCont_action_support): Use bool and initialize all fields.
9583 (struct readahead_cache): Initialize all fields.
9584 (remote_state): Use bool and initialize all fields.
9585 (remote_state::remote_state, remote_state::~remote_state): New.
9586 (new_remote_state): Delete.
9587 (_initialize_remote): Use new to allocate remote_state.
9588
9589 2018-05-22 Pedro Alves <palves@redhat.com>
9590 張俊芝 <zjz@zjz.name>
9591
9592 PR gdb/22973
9593 * c-exp.y: Include "c-support.h".
9594 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
9595 of tolower. Use c_ident_is_alpha to scan names.
9596 * c-lang.c: Include "c-support.h".
9597 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
9598 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
9599 * c-support.h: New file, with bits factored out from ...
9600 * cp-name-parser.y: ... this file.
9601 Include "c-support.h".
9602 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
9603 c-support.h and renamed.
9604 (symbol_end, yylex): Adjust.
9605
9606 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9607
9608 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
9609 parameter type to CORE_ADDR.
9610 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
9611 parameter type in declaration to CORE_ADDR.
9612 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
9613 target_auxv_search to get AT_HWCAP and use the result to get the
9614 target description.
9615 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
9616 to CORE_ADDR. Remove the cast of the return value to unsigned
9617 long. Fix error predicate of target_auxv_search.
9618 (ppc_linux_nat_target::read_description): Change the type of the
9619 hwcap variable to CORE_ADDR.
9620
9621 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9622
9623 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
9624 if the size of fpscr is larger than 32 bits.
9625
9626 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9627
9628 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
9629 (ppc32_linux_vsxregmap): New global.
9630 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
9631 regcache_supply_regset, and regcache_collect_regset.
9632 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
9633 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
9634 (fetch_vsx_register, store_vsx_register): Remove.
9635 (fetch_vsx_registers): Add regno parameter. Get regset using
9636 ppc_linux_vsxregset. Use regset to supply registers.
9637 (store_vsx_registers): Add regno parameter. Get regset using
9638 ppc_linux_vsxregset. Use regset to collect registers.
9639 (fetch_register): Call fetch_vsx_registers instead of
9640 fetch_vsx_register.
9641 (store_register): Call store_vsx_registers instead of
9642 store_vsx_register.
9643 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
9644 new regno parameter.
9645 (store_ppc_registers): Call store_vsx_registers with -1 for the
9646 new regno parameter.
9647 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
9648 (ppc_collect_vsxregset): Remove.
9649
9650 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9651
9652 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
9653 offset fields.
9654 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
9655 for vector register offset fields.
9656 (ppc64_fbsd_reg_offsets): Likewise.
9657 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
9658 to vector register offset fields.
9659 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
9660 to vector register offset fields.
9661 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
9662 vector register offset fields.
9663 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
9664 initializers for vector register offset fields.
9665 (rs6000_aix64_reg_offsets): Likewise.
9666 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
9667 (ppc_supply_vrregset): Remove.
9668 (ppc_collect_vrregset): Remove.
9669 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
9670 (ppc_linux_vrregset) : New function.
9671 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
9672 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
9673 (ppc32_linux_vrregset): Remove.
9674 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
9675 and use result instead of ppc32_linux_vrregset.
9676 (ppc32_linux_reg_offsets): Remove initializers for vector register
9677 offset fields.
9678 (ppc64_linux_reg_offsets): Likewise.
9679 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
9680 * ppc-linux-nat.c: Include regset.h.
9681 (gdb_vrregset_t): Adjust comment to account for little-endian
9682 mode.
9683 (supply_vrregset, fill_vrregset): Remove.
9684 (fetch_altivec_register, store_altivec_register): Remove.
9685 (fetch_altivec_registers): Add regno parameter. Get regset using
9686 ppc_linux_vrregset. Use regset to supply registers.
9687 (store_altivec_registers): Add regno parameter. Get regset using
9688 ppc_linux_vrregset. Use regset to collect registers.
9689 (fetch_register): Call fetch_altivec_registers instead of
9690 fetch_altivec_register.
9691 (store_register): Call store_altivec_registers instead of
9692 store_altivec_register.
9693 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
9694 the new regno parameter.
9695 (store_ppc_registers): Call store_altivec_registers with -1 for
9696 the new regno parameter.
9697
9698 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9699
9700 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
9701 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
9702 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
9703 (gdb_vrregset_t): Change array type size to
9704 PPC_LINUX_SIZEOF_VRREGSET.
9705 (gdb_vsxregset_t): Change array type size to
9706 PPC_LINUX_SIZEOF_VSXREGSET.
9707 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
9708 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
9709 PPC_LINUX_SIZEOF_VSXREGSET.
9710
9711 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9712
9713 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
9714 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
9715 nat/ppc-linux.c.
9716 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
9717 ppc_linux_target_wordsize with tid.
9718 (ppc_linux_nat_target::read_description): Call ppc_linux_target
9719 wordsize with tid.
9720 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
9721 (ppc64_64bit_inferior_p): Add static and inline specifiers.
9722 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
9723 tid parameter. Remove static specifier.
9724 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
9725 (ppc_linux_target_wordsize): New declaration.
9726
9727 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9728
9729 * arch/ppc-linux-common.c: New file.
9730 * arch/ppc-linux-common.h: New file.
9731 * arch/ppc-linux-tdesc.h: New file.
9732 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
9733 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
9734 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
9735 arch/ppc-linux-tdesc.h.
9736 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
9737 arch/ppc-linux-tdesc.h.
9738 (ppc_linux_nat_target::read_description): Remove target
9739 description matching code. Fill a ppc_linux_features struct and
9740 call ppc_linux_match_description with it. Move comment about ISA
9741 2.05 to ppc-linux-common.c.
9742 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
9743 arch/ppc-linux-tdesc.h.
9744 (ppc_linux_core_read_description): Remove target description
9745 matching code. Fill a ppc_linux_features struct and call
9746 ppc_linux_match_description with it.
9747 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
9748 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
9749 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
9750 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
9751 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
9752 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
9753 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
9754 (tdesc_powerpc_e500l): Remove.
9755
9756 2018-05-22 Joel Brobecker <brobecker@adacore.com>
9757
9758 * ada-lang.c (catch_assert_command): Pass empty string instead
9759 of NULL for excep_string argument.
9760
9761 2018-05-22 Maciej W. Rozycki <macro@mips.com>
9762
9763 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
9764 the width of the requested register exceeds the width of the
9765 `ptrace' data type.
9766
9767 2018-05-21 Tom Tromey <tom@tromey.com>
9768
9769 * printcmd.c (output_command): Remove.
9770 (output_command_const): Rename to output_command.
9771 * valprint.h (output_command): Rename from output_command_const.
9772 * tracepoint.c (trace_dump_actions): Call output_command.
9773
9774 2018-05-21 Tom Tromey <tom@tromey.com>
9775
9776 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
9777 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
9778 * ada-lang.h (create_ada_exception_catchpoint): Update.
9779 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
9780 std::string.
9781 (create_excep_cond_exprs, ~ada_catchpoint)
9782 (should_stop_exception, print_one_exception)
9783 (print_mention_exception, print_recreate_exception): Update.
9784 (ada_get_next_arg): Remove.
9785 (catch_ada_exception_command_split): Use std::string. Change type
9786 of "excep_string", "cond_string".
9787 (catch_ada_exception_command): Update.
9788 (create_ada_exception_catchpoint): Change type of excep_string.
9789 (ada_exception_sal): Remove excep_string parameter.
9790 (~ada_catchpoint): Remove.
9791
9792 2018-05-21 Tom Tromey <tom@tromey.com>
9793
9794 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
9795 cleanup.
9796
9797 2018-05-21 Tom Tromey <tom@tromey.com>
9798
9799 * ada-lang.c (ada_exception_message_1, ada_exception_message):
9800 Return unique_xmalloc_ptr.
9801 (print_it_exception): Update.
9802
9803 2018-05-21 Tom Tromey <tom@tromey.com>
9804
9805 * tracepoint.c (trace_dump_actions): Use std::string.
9806
9807 2018-05-21 Tom Tromey <tom@tromey.com>
9808
9809 * symfile.c (reread_symbols): Use std::string for original_name.
9810
9811 2018-05-21 Tom Tromey <tom@tromey.com>
9812
9813 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
9814 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
9815 constructor.
9816
9817 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
9818
9819 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
9820 instance to...
9821 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
9822 * objfiles.c (get_objfile_bfd_data): Allocate
9823 objfile_per_bfd_storage with obstack_new when allocating on
9824 obstack.
9825
9826 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
9827
9828 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
9829 OBSTACK_ZALLOC.
9830 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
9831 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
9832 * mdebugread.c (mdebug_build_psymtabs): Likewise.
9833 (add_pending): Likewise.
9834 (parse_symbol): Likewise.
9835 (parse_partial_symbols): Likewise.
9836 (psymtab_to_symtab_1): Likewise.
9837 (new_psymtab): Likewise.
9838 (elfmdebug_build_psymtabs): Likewise.
9839 * minsyms.c (terminate_minimal_symbol_table): Likewise.
9840 * objfiles.c (get_objfile_bfd_data): Likewise.
9841 (objfile_register_static_link): Likewise.
9842 * psymtab.c (allocate_psymtab): Likewise.
9843 * stabsread.c (read_member_functions): Likewise.
9844 * xcoffread.c (xcoff_end_psymtab): Likewise.
9845
9846 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
9847
9848 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
9849 compiler supports std::is_trivially_constructible.
9850 * common/poison.h: Include obstack.h.
9851 (IsMallocable): Define to is_trivially_constructible if the
9852 compiler supports it, define to true_type otherwise.
9853 (xobnew): New.
9854 (XOBNEW): Redefine.
9855 (xobnewvec): New.
9856 (XOBNEWVEC): Redefine.
9857 * gdb_obstack.h (obstack_zalloc): New.
9858 (OBSTACK_ZALLOC): Redefine.
9859 (obstack_calloc): New.
9860 (OBSTACK_CALLOC): Redefine.
9861 (obstack_new): New.
9862 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
9863 (gdbarch_obstack): New declaration in gdbarch.h, definition in
9864 gdbarch.c.
9865 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
9866 obstack_calloc/obstack_zalloc.
9867 (gdbarch_obstack_zalloc): Remove.
9868 * target-descriptions.c (tdesc_data_init): Use obstack_new.
9869
9870 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9871
9872 * stack.c (backtrace_command_1): Remove useless variable int i.
9873
9874 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9875
9876 * stack.c (print_frame_info): Fix comment.
9877
9878 2018-05-18 Tom Tromey <tom@tromey.com>
9879
9880 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
9881 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
9882 (~dwarf2_per_objfile): Update
9883 (dwarf2_get_dwz_file): Use new.
9884 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
9885 unique_ptr.
9886
9887 2018-05-18 Tom Tromey <tom@tromey.com>
9888
9889 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
9890 unique_ptr.
9891 * dwarf2read.c (struct dwp_file): Add constructor and
9892 initializers.
9893 (open_and_init_dwp_file): Return a unique_ptr.
9894 (dwarf2_per_objfile, create_dwp_hash_table)
9895 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
9896 (lookup_dwo_unit_in_dwp): Update.
9897 (open_and_init_dwp_file, get_dwp_file): Update.
9898
9899 2018-05-18 Tom Tromey <tom@tromey.com>
9900
9901 * dwarf2read.c (dwarf2_per_objfile): Update.
9902 (struct mapped_index): Add initializers.
9903 (dwarf2_read_index): Use new.
9904 (dw2_symtab_iter_init): Update.
9905 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
9906 unique_ptr.
9907
9908 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
9909
9910 * dwarf2read.c (mapped_index) <total_size>: Remove.
9911
9912 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
9913
9914 * unittests/format_pieces-selftests.c (test_format_specifier):
9915 Add ARI comments.
9916
9917 2018-05-18 Tom Tromey <tom@tromey.com>
9918
9919 * c-typeprint.c (maybe_print_hole): New function.
9920 (c_print_type_struct_field_offset): Update.
9921 (c_type_print_base_struct_union): Call maybe_print_hole.
9922
9923 2018-05-17 Keith Seitz <keiths@redhat.com>
9924
9925 * breakpoint.c (build_bpstat_chain): New function, moved from
9926 bpstat_stop_status.
9927 (bpstat_stop_status): Add optional parameter, `stop_chain'.
9928 If no stop chain is passed, call build_bpstat_chain to build it.
9929 * breakpoint.h (build_bpstat_chain): Declare.
9930 (bpstat_stop_status): Move documentation here from breakpoint.c.
9931 * infrun.c (handle_signal_stop): Before eliding inlined frames,
9932 build the stop chain and pass it to skip_inline_frames.
9933 Pass this stop chain to bpstat_stop_status.
9934 * inline-frame.c: Include breakpoint.h.
9935 (stopped_by_user_bp_inline_frame): New function.
9936 (skip_inline_frames): Add parameter `stop_chain'.
9937 Move documention to inline-frame.h.
9938 If non-NULL, use stopped_by_user_bp_inline_frame to determine
9939 whether the frame should be elided.
9940 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
9941 Add moved documentation and update for new parameter.
9942
9943 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
9944
9945 PR cli/14975
9946 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9947 unittests/format_pieces-selftests.c.
9948 * common/format.h (format_piece) <operator==>: New.
9949 (format_pieces) <operator[]>: Remove.
9950 * common/format.c (format_pieces::format_pieces): Handle \e.
9951 * unittests/format_pieces-selftests.c: New.
9952
9953 2018-05-17 Tom Tromey <tom@tromey.com>
9954
9955 PR symtab/23010:
9956 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
9957 (dw2_instantiate_symtab): Add skip_partial parameter.
9958 (dw2_find_last_source_symtab, dw2_map_expand_apply)
9959 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
9960 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
9961 (dw2_expand_symtabs_matching_one)
9962 (dw2_find_pc_sect_compunit_symtab)
9963 (dw2_debug_names_lookup_symbol)
9964 (dw2_debug_names_expand_symtabs_for_function): Update.
9965 (init_cutu_and_read_dies): Add skip_partial parameter.
9966 (process_psymtab_comp_unit, build_type_psymtabs_1)
9967 (process_skeletonless_type_unit, load_partial_comp_unit)
9968 (psymtab_to_symtab_1): Update.
9969 (load_full_comp_unit): Add skip_partial parameter.
9970 (process_imported_unit_die, dwarf2_read_addr_index)
9971 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
9972 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
9973 (read_signatured_type): Update.
9974
9975 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
9976
9977 * value.c (release_value): Remove unused variable.
9978 (record_latest_value): Likewise.
9979 (access_value_history): Likewise.
9980 (preserve_values): Likewise.
9981
9982 2018-05-17 Tom Tromey <tom@tromey.com>
9983
9984 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
9985 Initialize.
9986
9987 2018-05-16 Maciej W. Rozycki <macro@mips.com>
9988
9989 PR gdb/22286
9990 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
9991 Also handle registers whose width is not a multiple of
9992 PTRACE_TYPE_RET.
9993 (linux_nat_trad_target::store_register): Likewise.
9994
9995 2018-05-16 Tom Tromey <tom@tromey.com>
9996
9997 * gdbcore.h (core_bfd): Redefine.
9998 * corelow.c (core_target::close): Update.
9999 (core_target_open): Update.
10000 * progspace.h (struct program_space) <cbfd>: Now a
10001 gdb_bfd_ref_ptr.
10002
10003 2018-05-16 Tom Tromey <tom@tromey.com>
10004
10005 PR cli/19551:
10006 * symfile-add-flags.h (enum symfile_add_flags)
10007 <SYMFILE_NOT_FILENAME>: New constant.
10008 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
10009 objfile name from BFD.
10010 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
10011 * minidebug.c (find_separate_debug_file_in_section): Put
10012 ".gnu_debugdata" into BFD's file name.
10013
10014 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
10015
10016 * regcache.c (regcache_read_ftype, regcache_write_ftype):
10017 Remove.
10018
10019 2018-05-15 Tamar Christina <tamar.christina@arm.com>
10020
10021 PR binutils/21446
10022 * aarch64-tdep.c (aarch64_analyze_prologue,
10023 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
10024 Indicate not interested in errors.
10025
10026 2018-05-15 Maciej W. Rozycki <macro@mips.com>
10027
10028 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
10029 Supply the MIPS_ZERO_REGNUM register.
10030
10031 2018-05-15 Maciej W. Rozycki <macro@mips.com>
10032
10033 * mips-tdep.c (mask_address_var): Make variable static.
10034
10035 2018-05-14 Tom Tromey <tom@tromey.com>
10036
10037 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
10038
10039 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
10040
10041 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
10042 FXSAVE_ADDR for the mxcsr register.
10043
10044 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
10045
10046 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
10047
10048 2018-05-11 Pedro Alves <palves@redhat.com>
10049
10050 * corelow.c (core_target) <core_target>: No longer inline.
10051 Initialize m_core_gdbarch, m_core_vec and build the section table
10052 here.
10053 <~core_target>: New.
10054 <core_gdbarch, get_core_register_section>: New methods.
10055 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
10056 factored out from ...
10057 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
10058 (core_ops): Delete.
10059 (sniff_core_bfd): Add gdbarch parameter.
10060 (core_close): Delete, merged into ...
10061 (core_target::close): ... here. Delete self.
10062 (core_close_cleanup): Delete.
10063 (core_target_open): Allocate a core_target on the heap. Use a
10064 unique_ptr instead of a cleanup. Bits moved into the core_target
10065 ctor. Adjust to use core_target methods instead of globals.
10066 (get_core_register_section): Rename to ...
10067 (core_target::get_core_register_section): ... this and adjust.
10068 (struct get_core_registers_cb_data): New.
10069 (get_core_registers_cb): Use it. Use bool.
10070 (core_target::fetch_registers, core_target::files_info)
10071 (core_target::xfer_partial, core_target::read_description)
10072 (core_target::pid_to, core_target::thread_name): Adjust to
10073 reference class fields instead of globals.
10074 * target.h (struct target_ops_deleter, target_ops_up): New.
10075
10076 2018-05-11 Pedro Alves <palves@redhat.com>
10077
10078 * corefile.c (core_file_command): Move to corelow.c.
10079 * corelow.c (the_core_target): Delete.
10080 (core_file_command): Moved from corefile.c. Check exec_bfd
10081 instead of the_core_target. Use target_detach instead of calling
10082 into the_core_target directly.
10083 (maybe_say_no_core_file_now): New.
10084 (core_target::detach): Use it.
10085 (_initialize_corelow): Remove references to the_core_target.
10086 * gdbcore.h (the_core_target): Delete.
10087
10088 2018-05-11 Tom Tromey <tromey@redhat.com>
10089 Pedro Alves <palves@redhat.com>
10090
10091 * corefile.c (core_bfd): Remove.
10092 * gdbcore.h (core_bfd): Now a macro.
10093 * progspace.h (struct program_space) <cbfd>: New field.
10094
10095 2018-05-11 Tom Tromey <tom@tromey.com>
10096
10097 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
10098 gdb::def_vector.
10099
10100 2018-05-10 Tom Tromey <tom@tromey.com>
10101
10102 * configure: Rebuild.
10103 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
10104
10105 2018-05-10 Joel Brobecker <brobecker@adacore.com>
10106
10107 PR server/23158:
10108 * regformats/regdat.sh: Adjust script, following the addition
10109 of the new expedite_regs parameter to init_target_desc.
10110
10111 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
10112
10113 PR gdb/23127
10114 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
10115 set_gdbarch_significant_addr_bit.
10116 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
10117 set_gdbarch_significant_addr_bit.
10118 * utils.c (address_significant): Update to sign extend addr.
10119
10120 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
10121
10122 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
10123 (xtensa_linux_init_abi): Limit tdep->num_regs by
10124 tdep->num_nopriv_regs.
10125 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
10126 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
10127 not initialized.
10128
10129 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
10130
10131 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
10132
10133 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
10134
10135 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
10136 (I387_MXCSR_INIT_VAL): New constant.
10137 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
10138 buffer if it was supplied by the inferior.
10139 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
10140 (i387_xsave_get_clear_bv): New function.
10141 (i387_supply_xsave): Only read x87 control registers from the
10142 xsave buffer if the feature is enabled, and the state will have
10143 been written, otherwise, provide a suitable default.
10144 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
10145 including x87 control registers. Update control registers if they
10146 have changed from the default value, and mark features as enabled
10147 as required.
10148 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
10149
10150 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
10151
10152 * spu-tdep.c (info_spu_event_command): Fix output formatting.
10153
10154 2018-05-07 Tom Tromey <tom@tromey.com>
10155
10156 * configure: Rebuild.
10157 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
10158
10159 2018-05-07 Tom Tromey <tom@tromey.com>
10160
10161 PR tdep/20362:
10162 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
10163 bit. Use correct value for VDIV.
10164
10165 2018-05-04 Tom Tromey <tom@tromey.com>
10166
10167 * configure: Rebuild.
10168 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
10169
10170 2018-05-04 Tom Tromey <tom@tromey.com>
10171
10172 * linux-record.c (record_linux_system_call) <case
10173 RECORD_SYS_RECVFROM>: Add "break".
10174
10175 2018-05-04 Tom Tromey <tom@tromey.com>
10176
10177 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
10178 Add missing "break".
10179 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
10180 Add missing "break".
10181
10182 2018-05-04 Tom Tromey <tom@tromey.com>
10183
10184 * rs6000-tdep.c (ppc_process_record_op4)
10185 (ppc_process_record_op63): Add fall-through comment.
10186
10187 2018-05-04 Tom Tromey <tom@tromey.com>
10188
10189 * i386-tdep.c (i386_process_record): Add fall-through comment.
10190
10191 2018-05-04 Tom Tromey <tom@tromey.com>
10192
10193 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
10194 comment.
10195
10196 2018-05-04 Tom Tromey <tom@tromey.com>
10197
10198 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
10199 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
10200 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
10201 comment.
10202 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
10203 comment.
10204 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
10205 comment.
10206
10207 2018-05-04 Tom Tromey <tom@tromey.com>
10208
10209 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
10210
10211 2018-05-04 Tom Tromey <tom@tromey.com>
10212
10213 * s390-tdep.c (s390_process_record): Fix fall-through comments.
10214 * xcoffread.c (scan_xcoff_symtab): Move comment later.
10215 * symfile.c (section_is_mapped): Fix fall-through comment.
10216 * stabsread.c (define_symbol, read_member_functions): Fix
10217 fall-through comment.
10218 * s390-linux-tdep.c (s390_process_record): Fix fall-through
10219 comment.
10220 * remote.c (remote_wait_as): Fix fall-through comment.
10221 * p-exp.y (yylex): Fix fall-through comment.
10222 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
10223 comment.
10224 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
10225 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
10226 * jv-exp.y (yylex): Fix fall-through comment.
10227 * go-exp.y (lex_one_token): Fix fall-through comment.
10228 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
10229 fall-through comment.
10230 * f-exp.y (yylex): Fix fall-through comment.
10231 * dwarf2read.c (process_die): Fix fall-through comments.
10232 * dbxread.c (process_one_symbol): Fix fall-through comment.
10233 * d-exp.y (lex_one_token): Fix fall-through comment.
10234 * cp-name-parser.y (yylex): Fix fall-through comment.
10235 * coffread.c (coff_symtab_read): Fix fall-through comment.
10236 * c-exp.y (lex_one_token): Fix fall-through comment.
10237 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
10238 comment.
10239 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
10240 comment.
10241
10242 2018-05-04 Tom Tromey <tom@tromey.com>
10243
10244 PR python/22730:
10245 * NEWS: Mention gdb.execute change.
10246 * gdbcmd.h (execute_control_command): Don't declare.
10247 * python/python.c (execute_gdb_command): Use read_command_lines_1,
10248 execute_control_commands, execute_control_commands_to_string.
10249 * cli/cli-script.h (execute_control_commands)
10250 (execute_control_commands_to_string): Declare.
10251 (execute_control_command): Add from_tty parameter.
10252 * cli/cli-script.c (execute_control_commands)
10253 (execute_control_commands_to_string): New functions.
10254 (execute_user_command): Use execute_control_commands.
10255 (execute_control_command_1): Add "from_tty" parameter. Update.
10256 (execute_control_command): Likewise.
10257
10258 2018-05-04 Tom Tromey <tom@tromey.com>
10259
10260 PR python/22731:
10261 * NEWS: Mention that breakpoint commands are writable.
10262 * python/py-breakpoint.c (bppy_set_commands): New function.
10263 (breakpoint_object_getset) <"commands">: Use it.
10264
10265 2018-05-04 Tom Tromey <tom@tromey.com>
10266
10267 * tracepoint.c (actions_command): Update.
10268 * mi/mi-cmd-break.c (mi_command_line_array)
10269 (mi_command_line_array_cnt, mi_command_line_array_ptr)
10270 (mi_read_next_line): Remove.
10271 (mi_cmd_break_commands): Update.
10272 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
10273 function_view.
10274 * cli/cli-script.c (get_command_line): Update.
10275 (process_next_line): Use function_view. Constify.
10276 (recurse_read_control_structure, read_command_lines)
10277 (read_command_lines_1): Change argument types to function_view.
10278 (do_define_command, document_command): Update.
10279 * breakpoint.h (check_tracepoint_command): Don't declare.
10280 * breakpoint.c (check_tracepoint_command): Remove.
10281 (commands_command_1, create_tracepoint_from_upload): Update.
10282
10283 2018-05-04 Tom Tromey <tom@tromey.com>
10284
10285 PR gdb/11750:
10286 * cli/cli-script.h (enum command_control_type) <define_control>:
10287 New constant.
10288 * cli/cli-script.c (multi_line_command_p): Handle define_control.
10289 (build_command_line, execute_control_command_1)
10290 (process_next_line): Likewise.
10291 (do_define_command): New function, extracted from define_command.
10292 (define_command): Use it.
10293
10294 2018-05-04 Tom Tromey <tom@tromey.com>
10295
10296 * tracepoint.c (actions_command): Update.
10297 * cli/cli-script.h (read_command_lines): Update.
10298 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
10299 (MAX_TMPBUF): Remove define.
10300 (define_command): Use string_printf.
10301 (document_command): Likewise.
10302 * breakpoint.c (commands_command_1): Update.
10303
10304 2018-05-04 Tom Tromey <tom@tromey.com>
10305
10306 * top.c (execute_command): Update.
10307 * cli/cli-script.h (print_command_lines): Now varargs.
10308 * cli/cli-script.c (print_command_lines): Now varargs.
10309 (execute_control_command_1) <case while_control, case if_control>:
10310 Update.
10311
10312 2018-05-04 Tom Tromey <tom@tromey.com>
10313
10314 * tracepoint.c (all_tracepoint_actions): Rename from
10315 all_tracepoint_actions_and_cleanup. Change return type.
10316 (actions_command, encode_actions_1, encode_actions)
10317 (trace_dump_actions, tdump_command): Update.
10318 * remote.c (remote_download_command_source): Update.
10319 * python/python.c (gdbpy_eval_from_control_command)
10320 (python_command, python_interactive_command): Update.
10321 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
10322 * guile/guile.c (guile_command)
10323 (gdbscm_eval_from_control_command, guile_command): Update.
10324 * compile/compile.c (compile_code_command)
10325 (compile_print_command, compile_to_object): Update.
10326 * cli/cli-script.h (struct command_lines_deleter): New.
10327 (counted_command_line): New typedef.
10328 (struct command_line): Add constructor, destructor.
10329 <body_list>: Remove.
10330 <body_list_0, body_list_1>: New members.
10331 (command_line_up): Remove typedef.
10332 (read_command_lines, read_command_lines_1, get_command_line):
10333 Update.
10334 (copy_command_lines): Don't declare.
10335 * cli/cli-script.c (build_command_line): Use "new".
10336 (get_command_line): Return counted_command_line.
10337 (print_command_lines, execute_user_command)
10338 (execute_control_command_1, while_command, if_command): Update.
10339 (realloc_body_list): Remove.
10340 (process_next_line, recurse_read_control_structure): Update.
10341 (read_command_lines, read_command_lines_1): Return counted_command_line.
10342 (free_command_lines): Use "delete".
10343 (copy_command_lines): Remove.
10344 (define_command, document_command, show_user_1): Update.
10345 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
10346 a counted_command_line.
10347 * breakpoint.h (counted_command_line): Remove typedef.
10348 (breakpoint_set_commands): Update.
10349 * breakpoint.c (check_no_tracepoint_commands)
10350 (validate_commands_for_breakpoint): Update.
10351 (breakpoint_set_commands): Change commands to be a
10352 counted_command_line.
10353 (commands_command_1, update_dprintf_command_list)
10354 (create_tracepoint_from_upload): Update.
10355
10356 2018-05-04 Tom Tromey <tom@tromey.com>
10357
10358 * cli/cli-decode.h (cmd_list_element): New constructor.
10359 (~cmd_list_element): New destructor.
10360 (struct cmd_list_element): Add initializers.
10361 * cli/cli-decode.c (do_add_cmd): Use "new".
10362 (delete_cmd): Use "delete".
10363
10364 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
10365 Pedro Alves <palves@redhat.com>
10366
10367 PR breakpoints/19806 and support for PR external/20207.
10368 * NEWS: Mention Aarch64 watchpoint improvements.
10369 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
10370 watchpoints and PR external/20207 watchpoints.
10371 * nat/aarch64-linux-hw-point.c
10372 (kernel_supports_any_contiguous_range): New.
10373 (aarch64_watchpoint_offset): New.
10374 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
10375 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
10376 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
10377 (aarch64_align_watchpoint): New parameters aligned_offset_p and
10378 next_addr_orig_p. Support PR external/20207 watchpoints.
10379 (aarch64_downgrade_regs): New.
10380 (aarch64_dr_state_insert_one_point): New parameters offset and
10381 addr_orig.
10382 (aarch64_dr_state_remove_one_point): Likewise.
10383 (aarch64_handle_breakpoint): Update caller.
10384 (aarch64_handle_aligned_watchpoint): Likewise.
10385 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
10386 aligned_offset.
10387 (aarch64_linux_set_debug_regs): Remove const from state. Call
10388 aarch64_downgrade_regs.
10389 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
10390 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
10391 (DR_CONTROL_MASK): ... this.
10392 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
10393 (unsigned int aarch64_watchpoint_offset): New prototype.
10394 (aarch64_linux_set_debug_regs): Remove const from state.
10395 * utils.c (align_up, align_down): Move to ...
10396 * common/common-utils.c (align_up, align_down): ... here.
10397 * utils.h (align_up, align_down): Move to ...
10398 * common/common-utils.h (align_up, align_down): ... here.
10399
10400 2018-05-04 Joel Brobecker <brobecker@adacore.com>
10401
10402 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
10403 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
10404 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
10405 Re-implement to match the ABI as summarized in GCC's
10406 gcc/config/sparc/sparc.c. All callers updated.
10407 (sparc32_store_arguments): Remove assertion.
10408
10409 2018-05-04 Tom Tromey <tom@tromey.com>
10410
10411 * printcmd.c: Don't include tui.h.
10412 (decode_format): Use skip_spaces.
10413
10414 2018-05-04 Tom Tromey <tom@tromey.com>
10415
10416 PR gdb/22619:
10417 * printcmd.c (last_count): New global.
10418 (x_command): Use saved count when repeating.
10419
10420 2018-05-04 Tom Tromey <tom@tromey.com>
10421
10422 * nto-procfs.c (do_closedir_cleanup): Remove.
10423 (procfs_pidlist): Use gdb_dir_up.
10424 * procfs.c (do_closedir_cleanup): Remove.
10425 (proc_update_threads): Use gdb_dir_up.
10426 * common/filestuff.h (struct gdb_dir_deleter): New.
10427 (gdb_dir_up): New typedef.
10428
10429 2018-05-04 Tom Tromey <tom@tromey.com>
10430
10431 * ada-lang.c (print_mention_exception): Use std::string.
10432
10433 2018-05-04 Tom Tromey <tom@tromey.com>
10434
10435 * ada-lang.c (create_excep_cond_exprs): Update.
10436 (ada_exception_catchpoint_cond_string): Use std::string.
10437
10438 2018-05-04 Tom Tromey <tom@tromey.com>
10439
10440 * ada-lang.c (xget_renaming_scope): Return std::string.
10441 (old_renaming_is_invisible): Update.
10442
10443 2018-05-04 Tom Tromey <tom@tromey.com>
10444
10445 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
10446 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
10447
10448 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
10449
10450 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
10451
10452 2018-05-04 Tom Tromey <tom@tromey.com>
10453
10454 * remote.c (remote_query_supported_append): Change type.
10455 (remote_check_symbols): Update.
10456
10457 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
10458
10459 PR gdb/11420
10460 * configure.ac: Prepend libpython.
10461 * python/python-config.py: Likewise.
10462 * configure: Regenerate.
10463
10464 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
10465
10466 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
10467
10468 2018-05-03 Pedro Alves <palves@redhat.com>
10469
10470 * s390-linux-nat.c
10471 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
10472 override. Write 'true' instead of '1'.
10473 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
10474 declaration.
10475
10476 2018-05-02 Pedro Alves <palves@redhat.com>
10477
10478 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
10479 add_inf_child_target.
10480 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
10481 add_inf_child_target.
10482 * aix-thread.c (aix_thread_target_info): New.
10483 (aix_thread_target) <shortname, longname, doc>: Delete.
10484 <info>: New.
10485 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
10486 add_inf_child_target.
10487 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
10488 add_inf_child_target.
10489 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
10490 add_inf_child_target.
10491 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
10492 add_inf_child_target.
10493 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
10494 add_inf_child_target.
10495 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
10496 add_inf_child_target.
10497 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
10498 add_inf_child_target.
10499 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
10500 add_inf_child_target.
10501 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
10502 add_inf_child_target.
10503 * bfd-target.c (target_bfd_target_info): New.
10504 (target_bfd) <shortname, longname, doc>: Delete.
10505 <info>: New.
10506 * bsd-kvm.c (bsd_kvm_target_info): New.
10507 (bsd_kvm_target) <shortname, longname, doc>: Delete.
10508 <info>: New.
10509 (bsd_kvm_target::open): Rename to ...
10510 (bsd_kvm_target_open): ... this. Adjust.
10511 * bsd-uthread.c (bsd_uthread_target_info): New.
10512 (bsd_uthread_target) <shortname, longname, doc>: Delete.
10513 <info>: New.
10514 * corefile.c (core_file_command): Adjust.
10515 * corelow.c (core_target_info): New.
10516 (core_target) <shortname, longname, doc>: Delete.
10517 <info>: New.
10518 (core_target::open): Rename to ...
10519 (core_target_open): ... this. Adjust.
10520 * ctf.c (ctf_target_info): New.
10521 (ctf_target) <shortname, longname, doc>: Delete.
10522 <info>: New.
10523 (ctf_target::open): Rename to ...
10524 (ctf_target_open): ... this.
10525 (_initialize_ctf): Adjust.
10526 * exec.c (exec_target_info): New.
10527 (exec_target) <shortname, longname, doc>: Delete.
10528 <info>: New.
10529 (exec_target::open): Rename to ...
10530 (exec_target_open): ... this.
10531 * gdbcore.h (core_target_open): Declare.
10532 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
10533 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
10534 add_inf_child_target.
10535 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
10536 add_inf_child_target.
10537 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
10538 add_inf_child_target.
10539 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
10540 add_inf_child_target.
10541 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
10542 add_inf_child_target.
10543 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
10544 add_inf_child_target.
10545 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
10546 add_inf_child_target.
10547 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
10548 add_inf_child_target.
10549 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
10550 add_inf_child_target.
10551 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
10552 add_inf_child_target.
10553 * inf-child.c (inf_child_target_info): New.
10554 (inf_child_target::info): New.
10555 (inf_child_open_target): Remove 'target' parameter. Use
10556 get_native_target instead.
10557 (inf_child_target::open): Delete.
10558 (add_inf_child_target): New.
10559 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
10560 Delete.
10561 <info>: New.
10562 (add_inf_child_target): Declare.
10563 (inf_child_open_target): Declare.
10564 * linux-thread-db.c (thread_db_target_info): New.
10565 (thread_db_target) <shortname, longname, doc>: Delete.
10566 <info>: New.
10567 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
10568 add_inf_child_target.
10569 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
10570 add_inf_child_target.
10571 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
10572 add_inf_child_target.
10573 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
10574 add_inf_child_target.
10575 * make-target-delegates (print_class): Adjust.
10576 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
10577 add_inf_child_target.
10578 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
10579 add_inf_child_target.
10580 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
10581 add_inf_child_target.
10582 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
10583 add_inf_child_target.
10584 * nto-procfs.c (nto_native_target_info): New.
10585 (nto_procfs_target_native) <shortname, longname, doc>:
10586 Delete.
10587 <info>: New.
10588 (nto_procfs_target_info): New.
10589 (nto_procfs_target_procfs) <shortname, longname, doc>:
10590 Delete.
10591 <info>: New.
10592 (init_procfs_targets): Adjust.
10593 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
10594 add_inf_child_target.
10595 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
10596 add_inf_child_target.
10597 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
10598 add_inf_child_target.
10599 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
10600 add_inf_child_target.
10601 * ravenscar-thread.c (ravenscar_target_info): New.
10602 (ravenscar_thread_target) <shortname, longname, doc>:
10603 Delete.
10604 <info>: New.
10605 * record-btrace.c (record_btrace_target_info):
10606 (record_btrace_target) <shortname, longname, doc>: Delete.
10607 <info>: New.
10608 (record_btrace_target::open): Rename to ...
10609 (record_btrace_target_open): ... this. Adjust.
10610 * record-full.c (record_longname, record_doc): New.
10611 (record_full_base_target) <shortname, longname, doc>: Delete.
10612 <info>: New.
10613 (record_full_target_info): New.
10614 (record_full_target): <shortname>: Delete.
10615 <info>: New.
10616 (record_full_core_open_1, record_full_open_1): Update comments.
10617 (record_full_base_target::open): Rename to ...
10618 (record_full_open): ... this.
10619 (cmd_record_full_restore): Update.
10620 (_initialize_record_full): Update.
10621 * remote-sim.c (remote_sim_target_info): New.
10622 (gdbsim_target) <shortname, longname, doc>: Delete.
10623 <info>: New.
10624 (gdbsim_target::open): Rename to ...
10625 (gdbsim_target_open): ... this.
10626 (_initialize_remote_sim): Adjust.
10627 * remote.c (remote_doc): New.
10628 (remote_target_info): New.
10629 (remote_target) <shortname, longname, doc>: Delete.
10630 <info>: New.
10631 (extended_remote_target_info): New.
10632 (extended_remote_target) <shortname, longname, doc>: Delete.
10633 <info>: New.
10634 (remote_target::open_1): Make static. Adjust.
10635 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
10636 * s390-linux-nat.c (_initialize_s390_nat): Use
10637 add_inf_child_target.
10638 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
10639 add_inf_child_target.
10640 * sol-thread.c (thread_db_target_info): New.
10641 (sol_thread_target) <shortname, longname, doc>: Delete.
10642 <info>: New.
10643 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
10644 add_inf_child_target.
10645 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
10646 add_inf_child_target.
10647 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
10648 add_inf_child_target.
10649 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
10650 add_inf_child_target.
10651 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
10652 add_inf_child_target.
10653 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
10654 add_inf_child_target.
10655 * spu-linux-nat.c (_initialize_spu_nat): Use
10656 add_inf_child_target.
10657 * spu-multiarch.c (spu_multiarch_target_info): New.
10658 (spu_multiarch_target) <shortname, longname, doc>: Delete.
10659 <info>: New.
10660 * target-delegates.c: Regenerate.
10661 * target.c: Include <unordered_map>.
10662 (target_ops_p): Delete.
10663 (DEF_VEC_P(target_ops_p)): Delete.
10664 (target_factories): New.
10665 (test_target_info): New.
10666 (test_target_ops::info): New.
10667 (open_target): Adjust to use target_factories.
10668 (add_target_with_completer): Rename to ...
10669 (add_target): ... this. Change prototype. Register target_info
10670 and open callback in target_factories. Register target_info in
10671 command context instead of target_ops.
10672 (add_target): Delete old implementation.
10673 (add_deprecated_target_alias): Change prototype. Adjust.
10674 (the_native_target): New.
10675 (set_native_target, get_native_target): New.
10676 (find_default_run_target): Use the_native_target.
10677 (find_attach_target, find_run_target): Simplify.
10678 (target_ops::open): Delete.
10679 (dummy_target_info): New.
10680 (dummy_target::shortname, dummy_target::longname)
10681 (dummy_target::doc): Delete.
10682 (dummy_target::info): New.
10683 (debug_target::shortname, debug_target::longname)
10684 (debug_target::doc): Delete.
10685 (debug_target::info): New.
10686 * target.h (struct target_info): New.
10687 (target_ops::~target_ops): Add comment.
10688 (target_ops::info): New.
10689 (target_ops::shortname, target_ops::longname, target_ops::doc): No
10690 longer virtual. Implement in terms of target_info.
10691 (set_native_target, get_native_target): Declare.
10692 (target_open_ftype): New.
10693 (add_target, add_target_with_completer)
10694 (add_deprecated_target_alias): Change prototype.
10695 (test_target) <shortname, longname, doc>: Delete.
10696 <info>: New.
10697 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
10698 add_inf_child_target.
10699 * tracefile-tfile.c (tfile_target_info): New.
10700 (tfile_target) <shortname, longname, doc>: Delete.
10701 <info>: New.
10702 (tfile_target::open): Rename to ...
10703 (tfile_target_open): ... this.
10704 (_initialize_tracefile_tfile): Adjust.
10705 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
10706 add_inf_child_target.
10707 * windows-nat.c (_initialize_windows_nat): Use
10708 add_inf_child_target.
10709 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
10710 add_inf_child_target.
10711
10712 2018-05-02 Pedro Alves <palves@redhat.com>
10713
10714 * linux-nat.h (linux_nat_target) <low_new_thread,
10715 low_delete_thread, low_new_fork, low_forget_process,
10716 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
10717 New virtual methods.
10718 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
10719 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
10720 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
10721 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
10722 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
10723 Delete.
10724 * linux-fork.c (delete_fork): Adjust to call low method.
10725 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
10726 (linux_nat_new_fork, linux_nat_forget_process_hook)
10727 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
10728 (linux_nat_status_is_event):
10729 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
10730 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
10731 to call low method.
10732 (sigtrap_is_event): Rename to ...
10733 (linux_nat_target::low_status_is_event): ... this.
10734 (linux_nat_set_status_is_event): Delete.
10735 (save_stop_reason, linux_nat_wait_1)
10736 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
10737 low methods.
10738 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
10739 (linux_nat_set_new_fork, linux_nat_set_forget_process)
10740 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
10741 (linux_nat_set_prepare_to_resume): Delete.
10742 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
10743 low virtual methods.
10744 * amd64-linux-nat.c: Likewise.
10745 * arm-linux-nat.c: Likewise.
10746 * i386-linux-nat.c: Likewise.
10747 * ia64-linux-nat.c: Likewise.
10748 * mips-linux-nat.c: Likewise.
10749 * ppc-linux-nat.c: Likewise.
10750 * s390-linux-nat.c: Likewise.
10751 * sparc64-linux-nat.c: Likewise.
10752 * x86-linux-nat.c: Likewise.
10753 * x86-linux-nat.h: Include "nat/x86-linux.h".
10754 (x86_linux_nat_target) <low_new_fork, low_forget_process,
10755 low_prepare_to_resume, low_new_thread, low_delete_thread>:
10756 Override methods.
10757
10758 2018-05-02 Pedro Alves <palves@redhat.com>
10759
10760 * target.h (target_ops)
10761 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
10762 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
10763 stopped_by_watchpoint, have_continuable_watchpoint,
10764 stopped_data_address, watchpoint_addr_within_range,
10765 can_accel_watchpoint_condition, can_run, thread_alive,
10766 has_all_memory, has_memory, has_stack, has_registers,
10767 has_execution, can_async_p, is_async_p, supports_non_stop,
10768 always_non_stop_p, can_execute_reverse, supports_multi_process,
10769 supports_enable_disable_tracepoint,
10770 supports_disable_randomization, supports_string_tracing,
10771 supports_evaluation_of_breakpoint_conditions,
10772 can_run_breakpoint_commands, filesystem_is_local,
10773 can_download_tracepoint, get_trace_state_variable_value,
10774 set_trace_notes, get_tib_address, use_agent, can_use_agent,
10775 record_is_replaying, record_will_replay,
10776 augmented_libraries_svr4_read>: Adjust to return bool.
10777 * aarch64-linux-nat.c: All implementations adjusted.
10778 * aix-thread.c: All implementations adjusted.
10779 * arm-linux-nat.c: All implementations adjusted.
10780 * breakpoint.c: All implementations adjusted.
10781 * bsd-kvm.c: All implementations adjusted.
10782 * bsd-uthread.c: All implementations adjusted.
10783 * corelow.c: All implementations adjusted.
10784 * ctf.c: All implementations adjusted.
10785 * darwin-nat.c: All implementations adjusted.
10786 * darwin-nat.h: All implementations adjusted.
10787 * exec.c: All implementations adjusted.
10788 * fbsd-nat.c: All implementations adjusted.
10789 * fbsd-nat.h: All implementations adjusted.
10790 * gnu-nat.c: All implementations adjusted.
10791 * gnu-nat.h: All implementations adjusted.
10792 * go32-nat.c: All implementations adjusted.
10793 * ia64-linux-nat.c: All implementations adjusted.
10794 * inf-child.c: All implementations adjusted.
10795 * inf-child.h: All implementations adjusted.
10796 * inf-ptrace.c: All implementations adjusted.
10797 * inf-ptrace.h: All implementations adjusted.
10798 * linux-nat.c: All implementations adjusted.
10799 * linux-nat.h: All implementations adjusted.
10800 * mips-linux-nat.c: All implementations adjusted.
10801 * nto-procfs.c: All implementations adjusted.
10802 * ppc-linux-nat.c: All implementations adjusted.
10803 * procfs.c: All implementations adjusted.
10804 * ravenscar-thread.c: All implementations adjusted.
10805 * record-btrace.c: All implementations adjusted.
10806 * record-full.c: All implementations adjusted.
10807 * remote-sim.c: All implementations adjusted.
10808 * remote.c: All implementations adjusted.
10809 * s390-linux-nat.c: All implementations adjusted.
10810 * sol-thread.c: All implementations adjusted.
10811 * spu-multiarch.c: All implementations adjusted.
10812 * target-delegates.c: All implementations adjusted.
10813 * target.c: All implementations adjusted.
10814 * target.h: All implementations adjusted.
10815 * tracefile-tfile.c: All implementations adjusted.
10816 * tracefile.c: All implementations adjusted.
10817 * tracefile.h: All implementations adjusted.
10818 * windows-nat.c: All implementations adjusted.
10819 * x86-linux-nat.h: All implementations adjusted.
10820 * x86-nat.h: All implementations adjusted.
10821
10822 2018-05-02 Pedro Alves <palves@redhat.com>
10823
10824 * make-target-delegates (scan_target_h): Don't trim lines here.
10825 Replace sequences of tabs and/or whitespace with a single
10826 whitespace.
10827 (top level, parsing methods): Trim each line before processing it
10828 here.
10829
10830 2018-05-02 Pedro Alves <palves@redhat.com>
10831 John Baldwin <jhb@freebsd.org>
10832
10833 * target.h (enum strata) <debug_stratum>: New.
10834 (struct target_ops) <all delegation methods>: Replace by C++
10835 virtual methods, and drop "to_" prefix. All references updated
10836 throughout.
10837 <to_shortname, to_longname, to_doc, to_data,
10838 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
10839 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
10840 virtual methods. All references updated throughout.
10841 <can_attach, supports_terminal_ours, can_create_inferior,
10842 get_thread_control_capabilities, attach_no_wait>: New
10843 virtual methods.
10844 <insert_breakpoint, remove_breakpoint>: Now
10845 TARGET_DEFAULT_NORETURN methods.
10846 <info_proc>: Now returns bool.
10847 <to_magic>: Delete.
10848 (OPS_MAGIC): Delete.
10849 (current_target): Delete. All references replaced by references
10850 to ...
10851 (target_stack): ... this. New.
10852 (target_shortname, target_longname): Adjust.
10853 (target_can_run): Now a function declaration.
10854 (default_child_has_all_memory, default_child_has_memory)
10855 (default_child_has_stack, default_child_has_registers)
10856 (default_child_has_execution): Remove target_ops parameter.
10857 (complete_target_initialization): Delete.
10858 (memory_breakpoint_target): New template class.
10859 (test_target_ops): Refactor as a C++ class with virtual methods.
10860 * make-target-delegates (NAME_PART): Tighten.
10861 (POINTER_PART, CP_SYMBOL): New.
10862 (SIMPLE_RETURN_PART): Reimplement.
10863 (VEC_RETURN_PART): Expect less.
10864 (RETURN_PART, VIRTUAL_PART): New.
10865 (METHOD): Adjust to C++ virtual methods.
10866 (scan_target_h): Remove reference to C99.
10867 (dname): Output "target_ops::" prefix.
10868 (write_function_header): Adjust to output a C++ class method.
10869 (write_declaration): New.
10870 (write_delegator): Adjust to output a C++ class method.
10871 (tdname): Output "dummy_target::" prefix.
10872 (write_tdefault, write_debugmethod): Adjust to output a C++ class
10873 method.
10874 (tdefault_names, debug_names): Delete.
10875 (return_types, tdefaults, styles, argtypes_array): New.
10876 (top level): All methods are delegators.
10877 (print_class): New.
10878 (top level): Print dummy_target and debug_target classes.
10879 * target-delegates.c: Regenerate.
10880 * target-debug.h (target_debug_print_enum_info_proc_what)
10881 (target_debug_print_thread_control_capabilities)
10882 (target_debug_print_thread_info_p): New.
10883 * target.c (dummy_target): Delete.
10884 (the_dummy_target, the_debug_target): New.
10885 (target_stack): Now extern.
10886 (set_targetdebug): Push/unpush debug target.
10887 (default_child_has_all_memory, default_child_has_memory)
10888 (default_child_has_stack, default_child_has_registers)
10889 (default_child_has_execution): Remove target_ops parameter.
10890 (complete_target_initialization): Delete.
10891 (add_target_with_completer): No longer call
10892 complete_target_initialization.
10893 (target_supports_terminal_ours): Use regular delegation.
10894 (update_current_target): Delete.
10895 (push_target): No longer check magic number. Don't call
10896 update_current_target.
10897 (unpush_target): Don't call update_current_target.
10898 (target_is_pushed): No longer check magic number.
10899 (target_require_runnable): Skip for all stratums over
10900 process_stratum.
10901 (target_ops::info_proc): New.
10902 (target_info_proc): Use find_target_at and
10903 find_default_run_target.
10904 (target_supports_disable_randomization): Use regular delegation.
10905 (target_get_osdata): Use find_target_at.
10906 (target_ops::open, target_ops::close, target_ops::can_attach)
10907 (target_ops::attach, target_ops::can_create_inferior)
10908 (target_ops::create_inferior, target_ops::can_run)
10909 (target_can_run): New.
10910 (default_fileio_target): Use regular delegation.
10911 (target_ops::fileio_open, target_ops::fileio_pwrite)
10912 (target_ops::fileio_pread, target_ops::fileio_fstat)
10913 (target_ops::fileio_close, target_ops::fileio_unlink)
10914 (target_ops::fileio_readlink): New.
10915 (target_fileio_open_1, target_fileio_unlink)
10916 (target_fileio_readlink): Always call the target method. Handle
10917 FILEIO_ENOSYS.
10918 (return_zero, return_zero_has_execution): Delete.
10919 (init_dummy_target): Delete.
10920 (dummy_target::dummy_target, dummy_target::shortname)
10921 (dummy_target::longname, dummy_target::doc)
10922 (debug_target::debug_target, debug_target::shortname)
10923 (debug_target::longname, debug_target::doc): New.
10924 (target_supports_delete_record): Use regular delegation.
10925 (setup_target_debug): Delete.
10926 (maintenance_print_target_stack): Skip debug_stratum.
10927 (initialize_targets): Instantiate the_dummy_target and
10928 the_debug_target.
10929 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
10930 use target_stack.
10931 (target_auxv_search, fprint_target_auxv): Adjust.
10932 (info_auxv_command): Adjust to use target_stack.
10933 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
10934 * exceptions.c (print_flush): Handle a NULL target_stack.
10935 * regcache.c (target_ops_no_register): Refactor as class with
10936 virtual methods.
10937
10938 * exec.c (exec_target): New class.
10939 (exec_ops): Now an exec_target.
10940 (exec_open, exec_close_1, exec_get_section_table)
10941 (exec_xfer_partial, exec_files_info, exec_has_memory)
10942 (exec_make_note_section): Refactor as exec_target methods.
10943 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
10944 Delete.
10945 (exec_target::find_memory_regions): New.
10946 (_initialize_exec): Don't call init_exec_ops.
10947 * gdbcore.h (exec_file_clear): Delete.
10948
10949 * corefile.c (core_target): Delete.
10950 (core_file_command): Adjust.
10951 * corelow.c (core_target): New class.
10952 (the_core_target): New.
10953 (core_close): Remove target_ops parameter.
10954 (core_close_cleanup): Adjust.
10955 (core_target::close): New.
10956 (core_open, core_detach, get_core_registers, core_files_info)
10957 (core_xfer_partial, core_thread_alive, core_read_description)
10958 (core_pid_to_str, core_thread_name, core_has_memory)
10959 (core_has_stack, core_has_registers, core_info_proc): Rework as
10960 core_target methods.
10961 (ignore, core_remove_breakpoint, init_core_ops): Delete.
10962 (_initialize_corelow): Initialize the_core_target.
10963 * gdbcore.h (core_target): Delete.
10964 (the_core_target): New.
10965
10966 * ctf.c: (ctf_target): New class.
10967 (ctf_ops): Now a ctf_target.
10968 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
10969 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
10970 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
10971 methods.
10972 (init_ctf_ops): Delete.
10973 (_initialize_ctf): Don't call it.
10974 * tracefile-tfile.c (tfile_target): New class.
10975 (tfile_ops): Now a tfile_target.
10976 (tfile_open, tfile_close, tfile_files_info)
10977 (tfile_get_tracepoint_status, tfile_trace_find)
10978 (tfile_fetch_registers, tfile_xfer_partial)
10979 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
10980 Refactor as tfile_target methods.
10981 (tfile_xfer_partial_features): Remove target_ops parameter.
10982 (init_tfile_ops): Delete.
10983 (_initialize_tracefile_tfile): Don't call it.
10984 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
10985 (tracefile_has_stack, tracefile_has_registers)
10986 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
10987 tracefile_target methods.
10988 (init_tracefile_ops): Delete.
10989 (tracefile_target::tracefile_target): New.
10990 * tracefile.h: Include "target.h".
10991 (tracefile_target): New class.
10992 (init_tracefile_ops): Delete.
10993
10994 * spu-multiarch.c (spu_multiarch_target): New class.
10995 (spu_ops): Now a spu_multiarch_target.
10996 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
10997 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
10998 (spu_search_memory, spu_mourn_inferior): Refactor as
10999 spu_multiarch_target methods.
11000 (init_spu_ops): Delete.
11001 (_initialize_spu_multiarch): Remove references to init_spu_ops,
11002 complete_target_initialization.
11003
11004 * ravenscar-thread.c (ravenscar_thread_target): New class.
11005 (ravenscar_ops): Now a ravenscar_thread_target.
11006 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
11007 (ravenscar_thread_alive, ravenscar_pid_to_str)
11008 (ravenscar_fetch_registers, ravenscar_store_registers)
11009 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
11010 (ravenscar_stopped_by_hw_breakpoint)
11011 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
11012 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
11013 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
11014 methods.
11015 (init_ravenscar_thread_ops): Delete.
11016 (_initialize_ravenscar): Remove references to
11017 init_ravenscar_thread_ops and complete_target_initialization.
11018
11019 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
11020 (bsd_uthread_target): New class.
11021 (bsd_uthread_ops): Now a bsd_uthread_target.
11022 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
11023 (bsd_uthread_close, bsd_uthread_mourn_inferior)
11024 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
11025 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
11026 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
11027 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
11028 (bsd_uthread_target): Delete function.
11029 (_initialize_bsd_uthread): Remove reference to
11030 complete_target_initialization.
11031
11032 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
11033 (target_bfd): ... this new class.
11034 (target_bfd_xfer_partial, target_bfd_get_section_table)
11035 (target_bfd_close): Refactor as target_bfd methods.
11036 (target_bfd::~target_bfd): New.
11037 (target_bfd_reopen): Adjust.
11038 (target_bfd::close): New.
11039
11040 * record-btrace.c (record_btrace_target): New class.
11041 (record_btrace_ops): Now a record_btrace_target.
11042 (record_btrace_open, record_btrace_stop_recording)
11043 (record_btrace_disconnect, record_btrace_close)
11044 (record_btrace_async, record_btrace_info)
11045 (record_btrace_insn_history, record_btrace_insn_history_range)
11046 (record_btrace_insn_history_from, record_btrace_call_history)
11047 (record_btrace_call_history_range)
11048 (record_btrace_call_history_from, record_btrace_record_method)
11049 (record_btrace_is_replaying, record_btrace_will_replay)
11050 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
11051 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
11052 (record_btrace_store_registers, record_btrace_prepare_to_store)
11053 (record_btrace_to_get_unwinder)
11054 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
11055 (record_btrace_commit_resume, record_btrace_wait)
11056 (record_btrace_stop, record_btrace_can_execute_reverse)
11057 (record_btrace_stopped_by_sw_breakpoint)
11058 (record_btrace_supports_stopped_by_sw_breakpoint)
11059 (record_btrace_stopped_by_hw_breakpoint)
11060 (record_btrace_supports_stopped_by_hw_breakpoint)
11061 (record_btrace_update_thread_list, record_btrace_thread_alive)
11062 (record_btrace_goto_begin, record_btrace_goto_end)
11063 (record_btrace_goto, record_btrace_stop_replaying_all)
11064 (record_btrace_execution_direction)
11065 (record_btrace_prepare_to_generate_core)
11066 (record_btrace_done_generating_core): Refactor as
11067 record_btrace_target methods.
11068 (init_record_btrace_ops): Delete.
11069 (_initialize_record_btrace): Remove reference to
11070 init_record_btrace_ops.
11071 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
11072 the execution_direction global.
11073 (record_full_base_target, record_full_target)
11074 (record_full_core_target): New classes.
11075 (record_full_ops): Now a record_full_target.
11076 (record_full_core_ops): Now a record_full_core_target.
11077 (record_full_target::detach, record_full_target::disconnect)
11078 (record_full_core_target::disconnect)
11079 (record_full_target::mourn_inferior, record_full_target::kill):
11080 New.
11081 (record_full_open, record_full_close, record_full_async): Refactor
11082 as methods of the record_full_base_target class.
11083 (record_full_resume, record_full_commit_resume): Refactor
11084 as methods of the record_full_target class.
11085 (record_full_wait, record_full_stopped_by_watchpoint)
11086 (record_full_stopped_data_address)
11087 (record_full_stopped_by_sw_breakpoint)
11088 (record_full_supports_stopped_by_sw_breakpoint)
11089 (record_full_stopped_by_hw_breakpoint)
11090 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
11091 methods of the record_full_base_target class.
11092 (record_full_store_registers, record_full_xfer_partial)
11093 (record_full_insert_breakpoint, record_full_remove_breakpoint):
11094 Refactor as methods of the record_full_target class.
11095 (record_full_can_execute_reverse, record_full_get_bookmark)
11096 (record_full_goto_bookmark, record_full_execution_direction)
11097 (record_full_record_method, record_full_info, record_full_delete)
11098 (record_full_is_replaying, record_full_will_replay)
11099 (record_full_goto_begin, record_full_goto_end, record_full_goto)
11100 (record_full_stop_replaying): Refactor as methods of the
11101 record_full_base_target class.
11102 (record_full_core_resume, record_full_core_kill)
11103 (record_full_core_fetch_registers)
11104 (record_full_core_prepare_to_store)
11105 (record_full_core_store_registers, record_full_core_xfer_partial)
11106 (record_full_core_insert_breakpoint)
11107 (record_full_core_remove_breakpoint)
11108 (record_full_core_has_execution): Refactor
11109 as methods of the record_full_core_target class.
11110 (record_full_base_target::supports_delete_record): New.
11111 (init_record_full_ops): Delete.
11112 (init_record_full_core_ops): Delete.
11113 (record_full_save): Refactor as method of the
11114 record_full_base_target class.
11115 (_initialize_record_full): Remove references to
11116 init_record_full_ops and init_record_full_core_ops.
11117
11118 * remote.c (remote_target, extended_remote_target): New classes.
11119 (remote_ops): Now a remote_target.
11120 (extended_remote_ops): Now an extended_remote_target.
11121 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
11122 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
11123 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
11124 (remote_pass_signals, remote_set_syscall_catchpoint)
11125 (remote_program_signals, )
11126 (remote_thread_always_alive): Remove target_ops parameter.
11127 (remote_thread_alive, remote_thread_name)
11128 (remote_update_thread_list, remote_threads_extra_info)
11129 (remote_static_tracepoint_marker_at)
11130 (remote_static_tracepoint_markers_by_strid)
11131 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
11132 (remote_open): Refactor as methods of remote_target.
11133 (extended_remote_open, extended_remote_detach)
11134 (extended_remote_attach, extended_remote_post_attach):
11135 (extended_remote_supports_disable_randomization)
11136 (extended_remote_create_inferior): : Refactor as method of
11137 extended_remote_target.
11138 (remote_set_permissions, remote_open_1, remote_detach)
11139 (remote_follow_fork, remote_follow_exec, remote_disconnect)
11140 (remote_resume, remote_commit_resume, remote_stop)
11141 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
11142 (remote_terminal_ours, remote_wait, remote_fetch_registers)
11143 (remote_prepare_to_store, remote_store_registers)
11144 (remote_flash_erase, remote_flash_done, remote_files_info)
11145 (remote_kill, remote_mourn, remote_insert_breakpoint)
11146 (remote_remove_breakpoint, remote_insert_watchpoint)
11147 (remote_watchpoint_addr_within_range)
11148 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
11149 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
11150 (remote_supports_stopped_by_sw_breakpoint)
11151 (remote_stopped_by_hw_breakpoint)
11152 (remote_supports_stopped_by_hw_breakpoint)
11153 (remote_stopped_by_watchpoint, remote_stopped_data_address)
11154 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
11155 (remote_verify_memory): Refactor as methods of remote_target.
11156 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
11157 parameter.
11158 (remote_xfer_partial, remote_get_memory_xfer_limit)
11159 (remote_search_memory, remote_rcmd, remote_memory_map)
11160 (remote_pid_to_str, remote_get_thread_local_address)
11161 (remote_get_tib_address, remote_read_description): Refactor as
11162 methods of remote_target.
11163 (remote_target::fileio_open, remote_target::fileio_pwrite)
11164 (remote_target::fileio_pread, remote_target::fileio_close): New.
11165 (remote_hostio_readlink, remote_hostio_fstat)
11166 (remote_filesystem_is_local, remote_can_execute_reverse)
11167 (remote_supports_non_stop, remote_supports_disable_randomization)
11168 (remote_supports_multi_process, remote_supports_cond_breakpoints)
11169 (remote_supports_enable_disable_tracepoint)
11170 (remote_supports_string_tracing)
11171 (remote_can_run_breakpoint_commands, remote_trace_init)
11172 (remote_download_tracepoint, remote_can_download_tracepoint)
11173 (remote_download_trace_state_variable, remote_enable_tracepoint)
11174 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
11175 (remote_trace_start, remote_get_trace_status)
11176 (remote_get_tracepoint_status, remote_trace_stop)
11177 (remote_trace_find, remote_get_trace_state_variable_value)
11178 (remote_save_trace_data, remote_get_raw_trace_data)
11179 (remote_set_disconnected_tracing, remote_core_of_thread)
11180 (remote_set_circular_trace_buffer, remote_traceframe_info)
11181 (remote_get_min_fast_tracepoint_insn_len)
11182 (remote_set_trace_buffer_size, remote_set_trace_notes)
11183 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
11184 (remote_disable_btrace, remote_teardown_btrace)
11185 (remote_read_btrace, remote_btrace_conf)
11186 (remote_augmented_libraries_svr4_read, remote_load)
11187 (remote_pid_to_exec_file, remote_can_do_single_step)
11188 (remote_execution_direction, remote_thread_handle_to_thread_info):
11189 Refactor as methods of remote_target.
11190 (init_remote_ops, init_extended_remote_ops): Delete.
11191 (remote_can_async_p, remote_is_async_p, remote_async)
11192 (remote_thread_events, remote_upload_tracepoints)
11193 (remote_upload_trace_state_variables): Refactor as methods of
11194 remote_target.
11195 (_initialize_remote): Remove references to init_remote_ops and
11196 init_extended_remote_ops.
11197
11198 * remote-sim.c (gdbsim_target): New class.
11199 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
11200 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
11201 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
11202 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
11203 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
11204 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
11205 Refactor as methods of gdbsim_target.
11206 (gdbsim_ops): Now a gdbsim_target.
11207 (init_gdbsim_ops): Delete.
11208 (gdbsim_cntrl_c): Adjust.
11209 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
11210
11211 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
11212 (the_amd64_linux_nat_target): New.
11213 (amd64_linux_fetch_inferior_registers)
11214 (amd64_linux_store_inferior_registers): Refactor as methods of
11215 amd64_linux_nat_target.
11216 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
11217 * i386-linux-nat.c: Don't include "linux-nat.h".
11218 (i386_linux_nat_target): New class.
11219 (the_i386_linux_nat_target): New.
11220 (i386_linux_fetch_inferior_registers)
11221 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
11222 as methods of i386_linux_nat_target.
11223 (_initialize_i386_linux_nat): Adjust. Set linux_target.
11224 * inf-child.c (inf_child_ops): Delete.
11225 (inf_child_fetch_inferior_registers)
11226 (inf_child_store_inferior_registers): Delete.
11227 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
11228 methods of inf_child_target.
11229 (inf_child_target::supports_terminal_ours)
11230 (inf_child_target::terminal_init)
11231 (inf_child_target::terminal_inferior)
11232 (inf_child_target::terminal_ours_for_output)
11233 (inf_child_target::terminal_ours, inf_child_target::interrupt)
11234 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
11235 New.
11236 (inf_child_open, inf_child_disconnect, inf_child_close)
11237 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
11238 (inf_child_post_startup_inferior, inf_child_can_run)
11239 (inf_child_pid_to_exec_file): Refactor as methods of
11240 inf_child_target.
11241 (inf_child_follow_fork): Delete.
11242 (inf_child_target::can_create_inferior)
11243 (inf_child_target::can_attach): New.
11244 (inf_child_target::has_all_memory, inf_child_target::has_memory)
11245 (inf_child_target::has_stack, inf_child_target::has_registers)
11246 (inf_child_target::has_execution): New.
11247 (inf_child_fileio_open, inf_child_fileio_pwrite)
11248 (inf_child_fileio_pread, inf_child_fileio_fstat)
11249 (inf_child_fileio_close, inf_child_fileio_unlink)
11250 (inf_child_fileio_readlink, inf_child_use_agent)
11251 (inf_child_can_use_agent): Refactor as methods of
11252 inf_child_target.
11253 (return_zero, inf_child_target): Delete.
11254 (inf_child_target::inf_child_target): New.
11255 * inf-child.h: Include "target.h".
11256 (inf_child_target): Delete function prototype.
11257 (inf_child_target): New class.
11258 (inf_child_open_target, inf_child_mourn_inferior)
11259 (inf_child_maybe_unpush_target): Delete.
11260 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
11261 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
11262 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
11263 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
11264 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
11265 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
11266 (inf_ptrace_wait, inf_ptrace_xfer_partial)
11267 (inf_ptrace_thread_alive, inf_ptrace_files_info)
11268 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
11269 methods of inf_ptrace_target.
11270 (inf_ptrace_target): Delete function.
11271 * inf-ptrace.h: Include "inf-child.h".
11272 (inf_ptrace_target): Delete function declaration.
11273 (inf_ptrace_target): New class.
11274 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
11275 * linux-nat.c (linux_target): New.
11276 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
11277 (linux_nat_target::~linux_nat_target): New.
11278 (linux_child_post_attach, linux_child_post_startup_inferior)
11279 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
11280 (linux_child_remove_fork_catchpoint)
11281 (linux_child_insert_vfork_catchpoint)
11282 (linux_child_remove_vfork_catchpoint)
11283 (linux_child_insert_exec_catchpoint)
11284 (linux_child_remove_exec_catchpoint)
11285 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
11286 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
11287 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
11288 (linux_nat_stopped_data_address)
11289 (linux_nat_stopped_by_sw_breakpoint)
11290 (linux_nat_supports_stopped_by_sw_breakpoint)
11291 (linux_nat_stopped_by_hw_breakpoint)
11292 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
11293 (linux_nat_kill, linux_nat_mourn_inferior)
11294 (linux_nat_xfer_partial, linux_nat_thread_alive)
11295 (linux_nat_update_thread_list, linux_nat_pid_to_str)
11296 (linux_nat_thread_name, linux_child_pid_to_exec_file)
11297 (linux_child_static_tracepoint_markers_by_strid)
11298 (linux_nat_is_async_p, linux_nat_can_async_p)
11299 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
11300 (linux_nat_supports_multi_process)
11301 (linux_nat_supports_disable_randomization, linux_nat_async)
11302 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
11303 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
11304 (linux_nat_fileio_open, linux_nat_fileio_readlink)
11305 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
11306 methods of linux_nat_target.
11307 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
11308 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
11309 parameter.
11310 (check_stopped_by_watchpoint): Adjust.
11311 (linux_xfer_partial): Delete.
11312 (linux_target_install_ops, linux_target, linux_nat_add_target):
11313 Delete.
11314 (linux_nat_target::linux_nat_target): New.
11315 * linux-nat.h: Include "inf-ptrace.h".
11316 (linux_nat_target): New.
11317 (linux_target, linux_target_install_ops, linux_nat_add_target):
11318 Delete function declarations.
11319 (linux_target): Declare global.
11320 * linux-thread-db.c (thread_db_target): New.
11321 (thread_db_target::thread_db_target): New.
11322 (thread_db_ops): Delete.
11323 (the_thread_db_target): New.
11324 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
11325 (thread_db_update_thread_list, thread_db_pid_to_str)
11326 (thread_db_extra_thread_info)
11327 (thread_db_thread_handle_to_thread_info)
11328 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
11329 (thread_db_resume): Refactor as methods of thread_db_target.
11330 (init_thread_db_ops): Delete.
11331 (_initialize_thread_db): Remove reference to init_thread_db_ops.
11332 * x86-linux-nat.c: Don't include "linux-nat.h".
11333 (super_post_startup_inferior): Delete.
11334 (x86_linux_nat_target::~x86_linux_nat_target): New.
11335 (x86_linux_child_post_startup_inferior)
11336 (x86_linux_read_description, x86_linux_enable_btrace)
11337 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
11338 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
11339 methods of x86_linux_nat_target.
11340 (x86_linux_create_target): Delete. Bits folded ...
11341 (x86_linux_add_target): ... here. Now takes a linux_nat_target
11342 pointer.
11343 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
11344 (x86_linux_nat_target): New class.
11345 (x86_linux_create_target): Delete.
11346 (x86_linux_add_target): Now takes a linux_nat_target pointer.
11347 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
11348 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
11349 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
11350 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
11351 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
11352 make extern.
11353 (x86_use_watchpoints): Delete.
11354 * x86-nat.h: Include "breakpoint.h" and "target.h".
11355 (x86_use_watchpoints): Delete.
11356 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
11357 (x86_stopped_by_watchpoint, x86_stopped_data_address)
11358 (x86_insert_watchpoint, x86_remove_watchpoint)
11359 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
11360 (x86_stopped_by_hw_breakpoint): New declarations.
11361 (x86_nat_target): New template class.
11362
11363 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
11364 (the_ppc_linux_nat_target): New.
11365 (ppc_linux_fetch_inferior_registers)
11366 (ppc_linux_can_use_hw_breakpoint)
11367 (ppc_linux_region_ok_for_hw_watchpoint)
11368 (ppc_linux_ranged_break_num_registers)
11369 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
11370 (ppc_linux_insert_mask_watchpoint)
11371 (ppc_linux_remove_mask_watchpoint)
11372 (ppc_linux_can_accel_watchpoint_condition)
11373 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
11374 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
11375 (ppc_linux_watchpoint_addr_within_range)
11376 (ppc_linux_masked_watch_num_registers)
11377 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
11378 (ppc_linux_read_description): Refactor as methods of
11379 ppc_linux_nat_target.
11380 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
11381
11382 * procfs.c (procfs_xfer_partial): Delete forward declaration.
11383 (procfs_target): New class.
11384 (the_procfs_target): New.
11385 (procfs_target): Delete function.
11386 (procfs_auxv_parse, procfs_attach, procfs_detach)
11387 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
11388 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
11389 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
11390 (procfs_create_inferior, procfs_update_thread_list)
11391 (procfs_thread_alive, procfs_pid_to_str)
11392 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
11393 (procfs_stopped_data_address, procfs_insert_watchpoint)
11394 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
11395 (proc_find_memory_regions, procfs_info_proc)
11396 (procfs_make_note_section): Refactor as methods of procfs_target.
11397 (_initialize_procfs): Adjust.
11398 * sol-thread.c (sol_thread_target): New class.
11399 (sol_thread_ops): Now a sol_thread_target.
11400 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
11401 (sol_thread_fetch_registers, sol_thread_store_registers)
11402 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
11403 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
11404 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
11405 (init_sol_thread_ops): Delete.
11406 (_initialize_sol_thread): Adjust. Remove references to
11407 init_sol_thread_ops and complete_target_initialization.
11408
11409 * windows-nat.c (windows_nat_target): New class.
11410 (windows_fetch_inferior_registers)
11411 (windows_store_inferior_registers, windows_resume, windows_wait)
11412 (windows_attach, windows_detach, windows_pid_to_exec_file)
11413 (windows_files_info, windows_create_inferior)
11414 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
11415 (windows_close, windows_pid_to_str, windows_xfer_partial)
11416 (windows_get_tib_address, windows_get_ada_task_ptid)
11417 (windows_thread_name, windows_thread_alive): Refactor as
11418 windows_nat_target methods.
11419 (do_initial_windows_stuff): Adjust.
11420 (windows_target): Delete function.
11421 (_initialize_windows_nat): Adjust.
11422
11423 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
11424 (darwin_mourn_inferior, darwin_kill_inferior)
11425 (darwin_create_inferior, darwin_attach, darwin_detach)
11426 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
11427 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
11428 (darwin_supports_multi_process): Refactor as darwin_nat_target
11429 methods.
11430 (darwin_resume_to, darwin_files_info): Delete.
11431 (_initialize_darwin_inferior): Rename to ...
11432 (_initialize_darwin_nat): ... this. Adjust to C++ification.
11433 * darwin-nat.h: Include "inf-child.h".
11434 (darwin_nat_target): New class.
11435 (darwin_complete_target): Delete.
11436 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
11437 (darwin_target): New.
11438 (i386_darwin_fetch_inferior_registers)
11439 (i386_darwin_store_inferior_registers): Refactor as methods of
11440 darwin_nat_target.
11441 (darwin_complete_target): Delete, with ...
11442 (_initialize_i386_darwin_nat): ... bits factored out here.
11443
11444 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
11445 (the_alpha_linux_nat_target): New.
11446 (alpha_linux_register_u_offset): Refactor as
11447 alpha_linux_nat_target method.
11448 (_initialize_alpha_linux_nat): Adjust.
11449 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
11450 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
11451 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
11452 methods of linux_nat_trad_target.
11453 (linux_trad_target): Delete.
11454 * linux-nat-trad.h (linux_trad_target): Delete function.
11455 (linux_nat_trad_target): New class.
11456 * mips-linux-nat.c (mips_linux_nat_target): New class.
11457 (super_fetch_registers, super_store_registers, super_close):
11458 Delete.
11459 (the_mips_linux_nat_target): New.
11460 (mips64_linux_regsets_fetch_registers)
11461 (mips64_linux_regsets_store_registers)
11462 (mips64_linux_fetch_registers, mips64_linux_store_registers)
11463 (mips_linux_register_u_offset, mips_linux_read_description)
11464 (mips_linux_can_use_hw_breakpoint)
11465 (mips_linux_stopped_by_watchpoint)
11466 (mips_linux_stopped_data_address)
11467 (mips_linux_region_ok_for_hw_watchpoint)
11468 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
11469 (mips_linux_close): Refactor as methods of mips_linux_nat.
11470 (_initialize_mips_linux_nat): Adjust to C++ification.
11471
11472 * aix-thread.c (aix_thread_target): New class.
11473 (aix_thread_ops): Now an aix_thread_target.
11474 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
11475 (aix_thread_fetch_registers, aix_thread_store_registers)
11476 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
11477 (aix_thread_thread_alive, aix_thread_pid_to_str)
11478 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
11479 Refactor as methods of aix_thread_target.
11480 (init_aix_thread_ops): Delete.
11481 (_initialize_aix_thread): Remove references to init_aix_thread_ops
11482 and complete_target_initialization.
11483 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
11484 (rs6000_nat_target): New class.
11485 (the_rs6000_nat_target): New.
11486 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
11487 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
11488 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
11489 (super_create_inferior): Delete.
11490 (_initialize_rs6000_nat): Adjust to C++ification.
11491
11492 * arm-linux-nat.c (arm_linux_nat_target): New class.
11493 (the_arm_linux_nat_target): New.
11494 (arm_linux_fetch_inferior_registers)
11495 (arm_linux_store_inferior_registers, arm_linux_read_description)
11496 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
11497 (arm_linux_remove_hw_breakpoint)
11498 (arm_linux_region_ok_for_hw_watchpoint)
11499 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
11500 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
11501 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
11502 arm_linux_nat_target.
11503 (_initialize_arm_linux_nat): Adjust to C++ification.
11504
11505 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
11506 (the_aarch64_linux_nat_target): New.
11507 (aarch64_linux_fetch_inferior_registers)
11508 (aarch64_linux_store_inferior_registers)
11509 (aarch64_linux_child_post_startup_inferior)
11510 (aarch64_linux_read_description)
11511 (aarch64_linux_can_use_hw_breakpoint)
11512 (aarch64_linux_insert_hw_breakpoint)
11513 (aarch64_linux_remove_hw_breakpoint)
11514 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
11515 (aarch64_linux_region_ok_for_hw_watchpoint)
11516 (aarch64_linux_stopped_data_address)
11517 (aarch64_linux_stopped_by_watchpoint)
11518 (aarch64_linux_watchpoint_addr_within_range)
11519 (aarch64_linux_can_do_single_step): Refactor as methods of
11520 aarch64_linux_nat_target.
11521 (super_post_startup_inferior): Delete.
11522 (_initialize_aarch64_linux_nat): Adjust to C++ification.
11523
11524 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
11525 (the_hppa_linux_nat_target): New.
11526 (hppa_linux_fetch_inferior_registers)
11527 (hppa_linux_store_inferior_registers): Refactor as methods of
11528 hppa_linux_nat_target.
11529 (_initialize_hppa_linux_nat): Adjust to C++ification.
11530
11531 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
11532 (the_ia64_linux_nat_target): New.
11533 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
11534 (ia64_linux_stopped_data_address)
11535 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
11536 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
11537 ia64_linux_nat_target methods.
11538 (super_xfer_partial): Delete.
11539 (_initialize_ia64_linux_nat): Adjust to C++ification.
11540
11541 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
11542 (the_m32r_linux_nat_target): New.
11543 (m32r_linux_fetch_inferior_registers)
11544 (m32r_linux_store_inferior_registers): Refactor as
11545 m32r_linux_nat_target methods.
11546 (_initialize_m32r_linux_nat): Adjust to C++ification.
11547
11548 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
11549 (the_m68k_linux_nat_target): New.
11550 (m68k_linux_fetch_inferior_registers)
11551 (m68k_linux_store_inferior_registers): Refactor as
11552 m68k_linux_nat_target methods.
11553 (_initialize_m68k_linux_nat): Adjust to C++ification.
11554
11555 * s390-linux-nat.c (s390_linux_nat_target): New class.
11556 (the_s390_linux_nat_target): New.
11557 (s390_linux_fetch_inferior_registers)
11558 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
11559 (s390_insert_watchpoint, s390_remove_watchpoint)
11560 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
11561 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
11562 (s390_auxv_parse, s390_read_description): Refactor as methods of
11563 s390_linux_nat_target.
11564 (_initialize_s390_nat): Adjust to C++ification.
11565
11566 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
11567 (the_sparc_linux_nat_target): New.
11568 (_initialize_sparc_linux_nat): Adjust to C++ification.
11569 * sparc-nat.c (sparc_fetch_inferior_registers)
11570 (sparc_store_inferior_registers): Remove target_ops parameter.
11571 * sparc-nat.h (sparc_fetch_inferior_registers)
11572 (sparc_store_inferior_registers): Remove target_ops parameter.
11573 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
11574 (the_sparc64_linux_nat_target): New.
11575 (_initialize_sparc64_linux_nat): Adjust to C++ification.
11576
11577 * spu-linux-nat.c (spu_linux_nat_target): New class.
11578 (the_spu_linux_nat_target): New.
11579 (spu_child_post_startup_inferior, spu_child_post_attach)
11580 (spu_child_wait, spu_fetch_inferior_registers)
11581 (spu_store_inferior_registers, spu_xfer_partial)
11582 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
11583 methods.
11584 (_initialize_spu_nat): Adjust to C++ification.
11585
11586 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
11587 (the_tilegx_linux_nat_target): New.
11588 (fetch_inferior_registers, store_inferior_registers):
11589 Refactor as methods.
11590 (_initialize_tile_linux_nat): Adjust to C++ification.
11591
11592 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
11593 (the_xtensa_linux_nat_target): New.
11594 (xtensa_linux_fetch_inferior_registers)
11595 (xtensa_linux_store_inferior_registers): Refactor as
11596 xtensa_linux_nat_target methods.
11597 (_initialize_xtensa_linux_nat): Adjust to C++ification.
11598
11599 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
11600 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
11601 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
11602 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
11603 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
11604 (fbsd_stopped_by_sw_breakpoint)
11605 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
11606 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
11607 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
11608 (fbsd_post_startup_inferior, fbsd_post_attach)
11609 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
11610 (fbsd_set_syscall_catchpoint)
11611 (super_xfer_partial, super_resume, super_wait)
11612 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
11613 (fbsd_handle_debug_trap): Remove target_ops parameter.
11614 (fbsd_nat_add_target): Delete.
11615 * fbsd-nat.h: Include "inf-ptrace.h".
11616 (fbsd_nat_add_target): Delete.
11617 (USE_SIGTRAP_SIGINFO): Define.
11618 (fbsd_nat_target): New class.
11619
11620 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
11621 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
11622 (amd64bsd_target): Delete.
11623 * amd64-bsd-nat.h: New file.
11624 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
11625 "x86-bsd-nat.h".
11626 (amd64_fbsd_nat_target): New class.
11627 (the_amd64_fbsd_nat_target): New.
11628 (amd64fbsd_read_description): Refactor as method of
11629 amd64_fbsd_nat_target.
11630 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
11631 (_initialize_amd64fbsd_nat): Adjust to C++ification.
11632 * amd64-nat.h (amd64bsd_target): Delete function declaration.
11633 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
11634 (i386bsd_store_inferior_registers): Remove target_ops parameter.
11635 (i386bsd_target): Delete.
11636 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
11637 (i386bsd_fetch_inferior_registers)
11638 (i386bsd_store_inferior_registers): Declare.
11639 (i386_bsd_nat_target): New class.
11640 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
11641 (the_i386_fbsd_nat_target): New.
11642 (i386fbsd_resume, i386fbsd_read_description): Refactor as
11643 i386_fbsd_nat_target methods.
11644 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
11645 (_initialize_i386fbsd_nat): Adjust to C++ification.
11646 * x86-bsd-nat.c (super_mourn_inferior): Delete.
11647 (x86bsd_mourn_inferior, x86bsd_target): Delete.
11648 (_initialize_x86_bsd_nat): Adjust to C++ification.
11649 * x86-bsd-nat.h: Include "x86-nat.h".
11650 (x86bsd_target): Delete declaration.
11651 (x86bsd_nat_target): New class.
11652
11653 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
11654 (the_aarch64_fbsd_nat_target): New.
11655 (aarch64_fbsd_fetch_inferior_registers)
11656 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
11657 aarch64_fbsd_nat_target.
11658 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
11659 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
11660 (the_alpha_bsd_nat_target): New.
11661 (alphabsd_fetch_inferior_registers)
11662 (alphabsd_store_inferior_registers): Refactor as
11663 alpha_bsd_nat_target methods.
11664 (_initialize_alphabsd_nat): Refactor as methods of
11665 alpha_bsd_nat_target.
11666 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
11667 (the_amd64_nbsd_nat_target): New.
11668 (_initialize_amd64nbsd_nat): Adjust to C++ification.
11669 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
11670 (the_amd64_obsd_nat_target): New.
11671 (_initialize_amd64obsd_nat): Adjust to C++ification.
11672 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
11673 (the_arm_fbsd_nat_target): New.
11674 (arm_fbsd_fetch_inferior_registers)
11675 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
11676 (_initialize_arm_fbsd_nat): Refactor as methods of
11677 arm_fbsd_nat_target.
11678 (_initialize_arm_fbsd_nat): Adjust to C++ification.
11679 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
11680 (the_arm_netbsd_nat_target): New.
11681 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
11682 arm_netbsd_nat_target.
11683 (_initialize_arm_netbsd_nat): Adjust to C++ification.
11684 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
11685 (the_hppa_nbsd_nat_target): New.
11686 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
11687 hppa_nbsd_nat_target methods.
11688 (_initialize_hppanbsd_nat): Adjust to C++ification.
11689 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
11690 (the_hppa_obsd_nat_target): New.
11691 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
11692 methods of hppa_obsd_nat_target.
11693 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
11694 add_target.
11695 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
11696 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
11697 add_target.
11698 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
11699 (_initialize_i386obsd_nat): Use add_target.
11700 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
11701 (the_m68k_bsd_nat_target): New.
11702 (m68kbsd_fetch_inferior_registers)
11703 (m68kbsd_store_inferior_registers): Refactor as methods of
11704 m68k_bsd_nat_target.
11705 (_initialize_m68kbsd_nat): Adjust to C++ification.
11706 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
11707 (the_mips_fbsd_nat_target): New.
11708 (mips_fbsd_fetch_inferior_registers)
11709 (mips_fbsd_store_inferior_registers): Refactor as methods of
11710 mips_fbsd_nat_target.
11711 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
11712 add_target.
11713 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
11714 (the_mips_nbsd_nat_target): New.
11715 (mipsnbsd_fetch_inferior_registers)
11716 (mipsnbsd_store_inferior_registers): Refactor as methods of
11717 mips_nbsd_nat_target.
11718 (_initialize_mipsnbsd_nat): Adjust to C++ification.
11719 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
11720 (the_mips64_obsd_nat_target): New.
11721 (mips64obsd_fetch_inferior_registers)
11722 (mips64obsd_store_inferior_registers): Refactor as methods of
11723 mips64_obsd_nat_target.
11724 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
11725 add_target.
11726 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
11727 nbsd_nat_target.
11728 * nbsd-nat.h: Include "inf-ptrace.h".
11729 (nbsd_nat_target): New class.
11730 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
11731 (obsd_wait): Refactor as methods of obsd_nat_target.
11732 (obsd_add_target): Delete.
11733 * obsd-nat.h: Include "inf-ptrace.h".
11734 (obsd_nat_target): New class.
11735 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
11736 (the_ppc_fbsd_nat_target): New.
11737 (ppcfbsd_fetch_inferior_registers)
11738 (ppcfbsd_store_inferior_registers): Refactor as methods of
11739 ppc_fbsd_nat_target.
11740 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
11741 add_target.
11742 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
11743 (the_ppc_nbsd_nat_target): New.
11744 (ppcnbsd_fetch_inferior_registers)
11745 (ppcnbsd_store_inferior_registers): Refactor as methods of
11746 ppc_nbsd_nat_target.
11747 (_initialize_ppcnbsd_nat): Adjust to C++ification.
11748 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
11749 (the_ppc_obsd_nat_target): New.
11750 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
11751 methods of ppc_obsd_nat_target.
11752 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
11753 add_target.
11754 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
11755 (the_sh_nbsd_nat_target): New.
11756 (shnbsd_fetch_inferior_registers)
11757 (shnbsd_store_inferior_registers): Refactor as methods of
11758 sh_nbsd_nat_target.
11759 (_initialize_shnbsd_nat): Adjust to C++ification.
11760 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
11761 (inf_ptrace_xfer_partial): Delete.
11762 (sparc_xfer_partial, sparc_target): Delete.
11763 * sparc-nat.h (sparc_fetch_inferior_registers)
11764 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
11765 (sparc_target): Delete function declaration.
11766 (sparc_target): New template class.
11767 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
11768 (_initialize_sparcnbsd_nat): Adjust to C++ification.
11769 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
11770 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
11771 add_target.
11772 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
11773 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
11774 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
11775 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
11776 add_target.
11777 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
11778 (the_vax_bsd_nat_target): New.
11779 (vaxbsd_fetch_inferior_registers)
11780 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
11781 methods.
11782 (_initialize_vaxbsd_nat): Adjust to C++ification.
11783
11784 * bsd-kvm.c (bsd_kvm_target): New class.
11785 (bsd_kvm_ops): Now a bsd_kvm_target.
11786 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
11787 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
11788 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
11789 bsd_kvm_target.
11790 (bsd_kvm_return_one): Delete.
11791 (bsd_kvm_add_target): Adjust to C++ification.
11792
11793 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
11794 (nto_procfs_target_procfs): New classes.
11795 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
11796 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
11797 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
11798 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
11799 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
11800 (procfs_remove_hw_breakpoint, procfs_resume)
11801 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
11802 (procfs_kill_inferior, procfs_store_registers)
11803 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
11804 as methods of nto_procfs_target.
11805 (nto_procfs_ops): Now an nto_procfs_target_procfs.
11806 (nto_native_ops): Delete.
11807 (procfs_open, procfs_native_open): Delete.
11808 (nto_native_ops): Now an nto_procfs_target_native.
11809 (init_procfs_targets): Adjust to C++ification.
11810 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
11811 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
11812 Refactor as methods of nto_procfs_target.
11813
11814 * go32-nat.c (go32_nat_target): New class.
11815 (the_go32_nat_target): New.
11816 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
11817 (go32_store_registers, go32_xfer_partial, go32_files_info)
11818 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
11819 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
11820 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
11821 (go32_pid_to_str): Refactor as methods of go32_nat_target.
11822 (go32_target): Delete.
11823 (_initialize_go32_nat): Adjust to C++ification.
11824
11825 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
11826 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
11827 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
11828 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
11829 gnu_nat_target.
11830 (gnu_target): Delete.
11831 * gnu-nat.h (gnu_target): Delete.
11832 (gnu_nat_target): New class.
11833 * i386-gnu-nat.c (gnu_base_target): New.
11834 (i386_gnu_nat_target): New class.
11835 (the_i386_gnu_nat_target): New.
11836 (_initialize_i386gnu_nat): Adjust to C++ification.
11837
11838 2018-05-02 Pedro Alves <palves@redhat.com>
11839
11840 * bfd-target.c (target_bfd_xclose): Rename to ...
11841 (target_bfd_close): ... this.
11842 (target_bfd_reopen): Adjust.
11843 * target.c (target_close): Remove references to to_xclose.
11844 * target.h (target_ops::to_xclose): Delete.
11845 (target_ops::to_close): Update comments.
11846
11847 2018-05-02 Pedro Alves <palves@redhat.com>
11848
11849 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
11850 "linux-nat.h".
11851 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
11852 * inf-ptrace.c (inf_ptrace_register_u_offset)
11853 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
11854 (inf_ptrace_store_register, inf_ptrace_store_registers)
11855 (inf_ptrace_trad_target): Move to ...
11856 * linux-nat-trad.c: ... this new file.
11857 * linux-nat-trad.h: New file.
11858 * linux-nat.c (linux_target_install_ops): Make extern.
11859 (linux_trad_target): Delete.
11860 * linux-nat.h (linux_trad_target): Delete declaration.
11861 (linux_target_install_ops): Declare.
11862 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
11863 "linux-nat.h".
11864
11865 2018-05-02 Pedro Alves <palves@redhat.com>
11866
11867 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
11868 procfs_target/add_target here.
11869 * procfs.c (procfs_target): Make static.
11870 (_initialize_procfs): Call add_target here.
11871 * procfs.h (struct target_ops): Remove forward declaration.
11872 (procfs_target): Remove declaration.
11873 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
11874
11875 2018-05-02 Pedro Alves <palves@redhat.com>
11876
11877 * procfs.c (procfs_stopped_by_watchpoint)
11878 (procfs_insert_watchpoint, procfs_remove_watchpoint)
11879 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
11880 Forward declare.
11881 (procfs_use_watchpoints): Delete, move contents...
11882 (procfs_target): ... here.
11883 * procfs.h (procfs_use_watchpoints): Delete declaration.
11884 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
11885 procfs_use_watchpoints.
11886 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
11887 procfs_use_watchpoints.
11888
11889 2018-05-02 Tom Tromey <tom@tromey.com>
11890
11891 PR python/20084:
11892 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
11893 and var_zuinteger_unlimited.
11894 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
11895 and PARAM_ZUINTEGER_UNLIMITED.
11896 (set_parameter_value): Handle var_zuinteger and
11897 var_zuinteger_unlimited.
11898 (add_setshow_generic): Likewise.
11899 (parmpy_init): Likewise.
11900
11901 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
11902
11903 PR rust/23124
11904 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
11905 pointer is not null before dereferencing it.
11906
11907 2018-04-30 Tom Tromey <tom@tromey.com>
11908
11909 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
11910 is_mi_like_p.
11911
11912 2018-04-30 Tom Tromey <tom@tromey.com>
11913
11914 * breakpoint.c (mention): Remove use of is_mi_like_p.
11915 (print_mention_ranged_breakpoint): Likewise.
11916 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
11917 of is_mi_like_p.
11918
11919 2018-04-30 Tom Tromey <tom@tromey.com>
11920
11921 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
11922
11923 2018-04-30 Tom Tromey <tom@tromey.com>
11924
11925 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
11926 (info_spu_event_command): Remove some uses of is_mi_like_p.
11927
11928 2018-04-30 Tom Tromey <tom@tromey.com>
11929
11930 * python/py-framefilter.c (py_print_single_arg)
11931 (enumerate_locals, py_print_args, py_print_frame): Remove some
11932 uses of is_mi_like_p.
11933
11934 2018-04-30 Tom Tromey <tom@tromey.com>
11935
11936 * ui-out.c: Update.
11937 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
11938 * ui-out.h (ui_out::is_mi_like_p): Now const.
11939 (ui_out::do_is_mi_like_p): Now const.
11940 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
11941
11942 2018-04-30 Tom Tromey <tom@tromey.com>
11943
11944 * varobj.c (varobj_set_visualizer): Use new_reference.
11945 * python/python.c (gdbpy_decode_line): Use new_reference.
11946 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
11947 new_reference.
11948
11949 2018-04-30 Tom Tromey <tom@tromey.com>
11950
11951 * varobj.c (install_new_value): Use new_reference.
11952 * value.h (value_incref): Return void. Swap intro comment with
11953 value_decref.
11954 * value.c (set_value_parent): Use new_reference.
11955 (value_incref): Return void. Update intro comment.
11956 (release_value): Use new_reference.
11957 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
11958
11959 2018-04-30 Tom Tromey <tom@tromey.com>
11960
11961 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
11962 * gdb_bfd.h (new_bfd_ref): Remove.
11963 (gdb_bfd_open): Update comment.
11964 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11965 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
11966 (gdb_bfd_fdopenr): Use new_reference.
11967 * exec.c (exec_file_attach): Use new_reference.
11968
11969 2018-04-30 Tom Tromey <tom@tromey.com>
11970
11971 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
11972 method.
11973
11974 2018-04-30 Tom Tromey <tom@tromey.com>
11975
11976 * jit.c (jit_read_code_entry): Use type_align.
11977 * i386-tdep.c (i386_gdbarch_init): Don't call
11978 set_gdbarch_long_long_align_bit.
11979 * gdbarch.sh: Remove long_long_align_bit.
11980 * gdbarch.c, gdbarch.h: Rebuild.
11981 * arc-tdep.c (arc_type_align): New function.
11982 (arc_gdbarch_init): Use arc_type_align. Don't call
11983 set_gdbarch_long_long_align_bit.
11984
11985 2018-04-30 Tom Tromey <tom@tromey.com>
11986
11987 * rust-lang.c (rust_type_alignment): Remove.
11988 (rust_composite_type): Use type_align.
11989
11990 2018-04-30 Tom Tromey <tom@tromey.com>
11991
11992 * NEWS: Mention Type.align.
11993 * python/py-type.c (typy_get_alignof): New function.
11994 (type_object_getset): Add "alignof".
11995
11996 2018-04-30 Tom Tromey <tom@tromey.com>
11997
11998 PR exp/17095:
11999 * NEWS: Update.
12000 * std-operator.def (UNOP_ALIGNOF): New operator.
12001 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
12002 New.
12003 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
12004 * c-lang.c (c_op_print_tab): Add alignof.
12005 * c-exp.y (ALIGNOF): New token.
12006 (exp): Add "ALIGNOF" production.
12007 (ident_tokens): Add _Alignof and alignof.
12008
12009 2018-04-30 Tom Tromey <tom@tromey.com>
12010
12011 * i386-tdep.c (i386_type_align): New function.
12012 (i386_gdbarch_init): Update.
12013 * gdbarch.sh (type_align): New method.
12014 * gdbarch.c, gdbarch.h: Rebuild.
12015 * arch-utils.h (default_type_align): Declare.
12016 * arch-utils.c (default_type_align): New function.
12017 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
12018 (struct type) <align_log2>: New field.
12019 <instance_flags>: Now a bitfield.
12020 (TYPE_RAW_ALIGN): New macro.
12021 (type_align, type_raw_align, set_type_align): Declare.
12022 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
12023 functions.
12024 * dwarf2read.c (quirk_rust_enum): Set type alignment.
12025 (get_alignment, maybe_set_alignment): New functions.
12026 (read_structure_type, read_enumeration_type, read_array_type)
12027 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
12028 (read_subrange_type, read_base_type): Set type alignment.
12029
12030 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
12031
12032 * dwarf2read.c (read_index_from_section): Use bool.
12033
12034 2018-04-29 Fabian Groffen <grobian@gentoo.org>
12035
12036 PR gdb/22950
12037 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
12038 with #ifdef.
12039
12040 2018-04-29 John Reiser <jreiser@BitWagon.com>
12041
12042 PR build/22873
12043 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
12044 last step, and do it atomically.
12045
12046 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
12047
12048 * compile/compile-c-types.c (convert_int, convert_float):
12049 Update for C FE v1.
12050
12051 2018-04-27 Tom Tromey <tom@tromey.com>
12052
12053 PR rust/22545:
12054 * rust-lang.c (rust_inclusive_range_type_p): New function.
12055 (rust_range): Handle inclusive ranges.
12056 (rust_compute_range): Likewise.
12057 * rust-exp.y (struct rust_op) <inclusive>: New field.
12058 (DOTDOTEQ): New constant.
12059 (range_expr): Add "..=" productions.
12060 (operator_tokens): Add "..=" token.
12061 (ast_range): Add "inclusive" parameter.
12062 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
12063 ranges.
12064 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
12065 bounds values.
12066 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
12067 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
12068 Update comments.
12069 * expprint.c (print_subexp_standard): Handle new bounds values.
12070 (dump_subexp_body_standard): Likewise.
12071
12072 2018-04-27 Tom Tromey <tom@tromey.com>
12073
12074 * configure: Rebuild.
12075 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
12076 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
12077 "OVERRIDE".
12078 (class symbol_needs_eval_context): Likewise.
12079 * dwarf2read.c (mock_mapped_index::symbol_name_count)
12080 (mock_mapped_index::symbol_name_at): Use "override". Remove
12081 "virtual".
12082 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
12083 "override".
12084 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
12085 * aarch64-tdep.c (instruction_reader::read): Use "override".
12086 (instruction_reader_test::read): Likewise.
12087 * arm-tdep.c (instruction_reader::read): Use "override".
12088 (instruction_reader_thumb::read): Likewise.
12089
12090 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
12091
12092 PR remote/9665
12093 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
12094 instead of remote_send.
12095 (remote_send): Remove.
12096
12097 2018-04-26 Pedro Alves <palves@redhat.com>
12098
12099 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
12100 find_function_start_sal instead of find_pc_line.
12101
12102 2018-04-26 Pedro Alves <palves@redhat.com>
12103
12104 * breakpoint.c (set_breakpoint_location_function): Handle
12105 mst_data_gnu_ifunc.
12106 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
12107 * elfread.c (elf_symtab_read): Give data symbols with
12108 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
12109 (elf_rel_plt_read): Update comment.
12110 * linespec.c (convert_linespec_to_sals): Handle
12111 mst_data_gnu_ifunc.
12112 (minsym_found): Handle mst_data_gnu_ifunc.
12113 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
12114 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
12115 * parse.c (find_minsym_type_and_address): Handle
12116 mst_data_gnu_ifunc.
12117 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
12118 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
12119 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
12120 comment.
12121 <mst_data_gnu_ifunc>: New enumerator.
12122
12123 2018-04-26 Pedro Alves <palves@redhat.com>
12124
12125 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
12126 (lookup_minimal_symbol_by_pc_section): ... this. Replace
12127 'want_trampoline' parameter by a lookup_msym_prefer parameter.
12128 Handle it.
12129 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
12130 (lookup_minimal_symbol_by_pc): Adjust.
12131 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
12132 (lookup_solib_trampoline_symbol_by_pc): Adjust.
12133 * minsyms.h (lookup_msym_prefer): New enum.
12134 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
12135 parameter by a lookup_msym_prefer parameter.
12136
12137 2018-04-26 Pedro Alves <palves@redhat.com>
12138
12139 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
12140 ends in "@plt" instead of looking at the symbol's section.
12141
12142 2018-04-26 Pedro Alves <palves@redhat.com>
12143
12144 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
12145 all references.
12146 (find_pc_partial_function_gnu_ifunc): Rename to ...
12147 (find_pc_partial_function): ... this, and remove references to
12148 'is_gnu_ifunc_p'.
12149 (find_pc_partial_function): Delete old implementation.
12150 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
12151
12152 2018-04-26 Pedro Alves <palves@redhat.com>
12153
12154 * linespec.c (struct bound_minimal_symbol_search_key): New.
12155 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
12156 skip first line if we found a GNU ifunc minimal symbol by name.
12157 (compare_msymbols): Change parameters to work with a destructured
12158 lhs minsym.
12159 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
12160 functions.
12161
12162 2018-04-26 Pedro Alves <palves@redhat.com>
12163
12164 * breakpoint.c (set_breakpoint_location_function): Don't resolve
12165 ifunc targets here. Instead, if we have an ifunc minsym, use its
12166 address/name.
12167 (add_location_to_breakpoint): Store the minsym and the objfile in
12168 the breakpoint location.
12169 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
12170 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
12171 Record the minsym in the sal.
12172 * symtab.h (symtab_and_line) <msymbol>: New field.
12173
12174 2018-04-26 Pedro Alves <palves@redhat.com>
12175
12176 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
12177 unless we actually resolved the ifunc.
12178
12179 2018-04-26 Pedro Alves <palves@redhat.com>
12180
12181 * c-exp.y (variable production): Prefer ifunc minsyms over
12182 regular function symbols.
12183 * symtab.c (find_gnu_ifunc): New function.
12184 * minsyms.h (lookup_msym_prefer): New enum.
12185 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
12186 parameter by a lookup_msym_prefer parameter.
12187 * symtab.h (find_gnu_ifunc): New declaration.
12188
12189 2018-04-26 Pedro Alves <palves@redhat.com>
12190
12191 * blockframe.c (find_gnu_ifunc_target_type): New function.
12192 (find_function_type): New.
12193 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
12194 return a value with a memory address.
12195 (eval_call): For calls to GNU ifunc functions, try to find the
12196 type of the target function from the type that the resolver
12197 returns.
12198 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
12199 symbols.
12200 * infcall.c (find_function_return_type): Delete.
12201 (find_function_addr): Add 'function_type' parameter. For calls to
12202 GNU ifunc functions, try to find the type of the target function
12203 from the type that the resolver returns, and return it via
12204 FUNCTION_TYPE.
12205 (call_function_by_hand_dummy): Adjust to use the function type
12206 returned by find_function_addr.
12207 (find_function_addr): Add 'function_type' parameter and move
12208 description here.
12209 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
12210 declarations.
12211
12212 2018-04-26 Pedro Alves <palves@redhat.com>
12213
12214 * c-exp.y (variable production): Skip finding an alias for ifunc
12215 symbols.
12216
12217 2018-04-26 Pedro Alves <palves@redhat.com>
12218
12219 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
12220
12221 2018-04-25 Pedro Alves <palves@redhat.com>
12222
12223 * infcmd.c (kill_command): Print the pid as string, not the whole
12224 thread's ptid. Add comment. s/has been killed/killed/ in output
12225 message.
12226 * remote.c (remote_detach_1): Print the pid as string, not the
12227 whole thread's ptid.
12228
12229 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
12230 Sergio Durigan Junior <sergiodj@redhat.com>
12231 Pedro Alves <palves@redhat.com>
12232
12233 * infcmd.c (kill_command): Print message when inferior has
12234 been killed.
12235 * inferior.c (print_inferior_events): Remove 'static'. Set as
12236 '1'.
12237 (add_inferior): Improve message printed when
12238 'print_inferior_events' is on.
12239 (exit_inferior): Remove message printed when
12240 'print_inferior_events' is on.
12241 (detach_inferior): Improve message printed when
12242 'print_inferior_events' is on.
12243 (initialize_inferiors): Use 'add_inferior_silent' to set
12244 'current_inferior_'.
12245 * inferior.h (print_inferior_events): Declare here as
12246 'extern'.
12247 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
12248 '[Detaching...]' messages when 'print_inferior_events' is on.
12249 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
12250 as prefix/suffix for messages. Remove periods. Fix erroneous
12251 'Detaching after fork from child...', replace it by '... from
12252 parent...'.
12253 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
12254 prefix/suffix when printing 'Detaching...' messages. Print
12255 them when 'print_inferior_events' is on.
12256 * remote.c (remote_detach_1): Print message when detaching
12257 from inferior and '!is_fork_parent'.
12258
12259 2018-04-24 Tom Tromey <tom@tromey.com>
12260
12261 * cli-out.h: Reindent.
12262
12263 2018-04-24 Tom Tromey <tom@tromey.com>
12264
12265 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
12266 (cli_ui_out::do_field_string): Use fputs_filtered.
12267 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
12268
12269 2018-04-23 Tom Tromey <tom@tromey.com>
12270
12271 * guile/scm-frame.c (gdbscm_frame_read_var): Use
12272 gdb::unique_xmalloc_ptr.
12273
12274 2018-04-23 Tom Tromey <tom@tromey.com>
12275
12276 * configure: Rebuild.
12277
12278 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
12279
12280 PR gdb/23095
12281 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
12282 prepare_for_testing. Set normal_bp to r_debug_state if target
12283 is bsd.
12284
12285 2018-04-21 Pedro Alves <palves@redhat.com>
12286 Rajendra SY <rajendra.sy@gmail.com>
12287
12288 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
12289 * remote.c (extended_remote_attach): In all-stop mode, mark the
12290 thread as executing.
12291
12292 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
12293
12294 * thread.c (thread_apply_all_command): Fix comment.
12295 (thread_command): Fix comment.
12296
12297 2018-04-10 Alan Hayward <alan.hayward@arm.com>
12298
12299 * common/tdesc.h (tdesc_create_feature): Remove xml filename
12300 parameter.
12301 * features/aarch64-core.c (create_feature_aarch64_core):
12302 Regenerate.
12303 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
12304 Likewise.
12305 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
12306 Likewise.
12307 * features/i386/32bit-avx512.c
12308 (create_feature_i386_32bit_avx512): Likewise.
12309 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
12310 Likewise.
12311 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
12312 Likewise.
12313 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
12314 Likewise.
12315 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
12316 Likewise.
12317 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
12318 Likewise.
12319 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
12320 Likewise.
12321 * features/i386/64bit-avx512.c
12322 (create_feature_i386_64bit_avx512): Likewise.
12323 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
12324 Likewise.
12325 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
12326 Likewise.
12327 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
12328 Likewise.
12329 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
12330 Likewise.
12331 * features/i386/64bit-segments.c
12332 (create_feature_i386_64bit_segments): Likewise.
12333 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
12334 Likewise.
12335 * features/i386/x32-core.c
12336 (create_feature_i386_x32_core): Likewise.
12337 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
12338 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
12339 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
12340 * target-descriptions.c: In generated code, don't pass xml
12341 filename.
12342
12343 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12344
12345 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
12346 (print_xml_feature::visit_post): Likewise.
12347 (print_xml_feature::visit): Likewise.
12348 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
12349 (print_xml_feature): Add new class.
12350 * regformats/regdat.sh: Null xmltarget on feature targets.
12351 * target-descriptions.c (struct target_desc): Add xmltarget.
12352 (maintenance_check_tdesc_xml_convert): Add unittest function.
12353 (tdesc_get_features_xml): Add function to get xml.
12354 (maintenance_check_xml_descriptions): Test xml generation.
12355 * xml-tdesc.c (string_read_description_xml): Add function.
12356 * xml-tdesc.h (string_read_description_xml): Add declaration.
12357
12358 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12359
12360 * features/Makefile: Add feature marker to targets with new style
12361 target descriptions.
12362 * regformats/aarch64.dat: Regenerate.
12363 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
12364 * regformats/i386/amd64-avx-linux.dat: Likewise.
12365 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
12366 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
12367 * regformats/i386/amd64-linux.dat: Likewise.
12368 * regformats/i386/amd64-mpx-linux.dat: Likewise.
12369 * regformats/i386/amd64.dat: Likewise.
12370 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
12371 * regformats/i386/i386-avx-linux.dat: Likewise.
12372 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
12373 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
12374 * regformats/i386/i386-linux.dat: Likewise.
12375 * regformats/i386/i386-mmx-linux.dat: Likewise.
12376 * regformats/i386/i386-mpx-linux.dat: Likewise.
12377 * regformats/i386/i386.dat: Likewise.
12378 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
12379 * regformats/i386/x32-avx-linux.dat: Likewise.
12380 * regformats/i386/x32-linux.dat: Likewise.
12381 * regformats/tic6x-c62x-linux.dat: Likewise.
12382 * regformats/tic6x-c64x-linux.dat: Likewise.
12383 * regformats/tic6x-c64xp-linux.dat: Likewise.
12384 * regformats/regdat.sh: Parse feature marker.
12385
12386 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12387
12388 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
12389 (tdesc_osabi_name): Likewise.
12390 * target-descriptions.c (tdesc_architecture_name): Add new
12391 function.
12392 (tdesc_osabi_name): Likewise.
12393
12394 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12395
12396 * common/tdesc.c (tdesc_predefined_type): Move to here.
12397 (tdesc_named_type): Likewise.
12398 (tdesc_create_vector): Likewise.
12399 (tdesc_create_struct): Likewise.
12400 (tdesc_set_struct_size): Likewise.
12401 (tdesc_create_union): Likewise.
12402 (tdesc_create_flags): Likewise.
12403 (tdesc_create_enum): Likewise.
12404 (tdesc_add_field): Likewise.
12405 (tdesc_add_typed_bitfield): Likewise.
12406 (tdesc_add_bitfield): Likewise.
12407 (tdesc_add_flag): Likewise.
12408 (tdesc_add_enum_value): Likewise.
12409 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
12410 (struct tdesc_type_vector): Likewise.
12411 (struct tdesc_type_field): Likewise.
12412 (struct tdesc_type_with_fields): Likewise.
12413 (tdesc_create_enum): Add declaration.
12414 (tdesc_add_typed_bitfield): Likewise.
12415 (tdesc_add_enum_value): Likewise.
12416 * target-descriptions.c (tdesc_type_field): Move from here.
12417 (tdesc_type_builtin): Likewise.
12418 (tdesc_type_vector): Likewise.
12419 (tdesc_type_with_fields): Likewise.
12420 (tdesc_predefined_types): Likewise.
12421 (tdesc_named_type): Likewise.
12422 (tdesc_create_vector): Likewise.
12423 (tdesc_create_struct): Likewise.
12424 (tdesc_set_struct_size): Likewise.
12425 (tdesc_create_union): Likewise.
12426 (tdesc_create_flags): Likewise.
12427 (tdesc_create_enum): Likewise.
12428 (tdesc_add_field): Likewise.
12429 (tdesc_add_typed_bitfield): Likewise.
12430 (tdesc_add_bitfield): Likewise.
12431 (tdesc_add_flag): Likewise.
12432 (tdesc_add_enum_value): Likewise.
12433 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
12434 (tdesc_add_typed_bitfield): Likewise.
12435 (tdesc_add_enum_value): Likewise.
12436
12437 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12438
12439 * common/tdesc.c (tdesc_feature::accept): Move to here.
12440 (tdesc_feature::operator==): Likewise.
12441 (tdesc_create_reg): Likewise.
12442 * common/tdesc.h (tdesc_type_kind): Likewise.
12443 (struct tdesc_type): Likewise.
12444 (struct tdesc_feature): Likewise.
12445 * regformats/regdat.sh: Create a feature.
12446 * target-descriptions.c (tdesc_type_kind): Move from here.
12447 (tdesc_type): Likewise.
12448 (tdesc_type_up): Likewise.
12449 (tdesc_feature): Likewise.
12450 (tdesc_create_reg): Likewise.
12451
12452 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12453
12454 * Makefile.in: Add arch/tdesc.c
12455 * common/tdesc.c: New file.
12456 * common/tdesc.h (tdesc_element_visitor): Move to here.
12457 (tdesc_element): Likewise.
12458 (tdesc_reg): Likewise.
12459 (tdesc_reg_up): Likewise.
12460 * regformats/regdef.h (reg): Add offset to constructors.
12461 * target-descriptions.c (tdesc_element_visitor): Move from here.
12462 (tdesc_element): Likewise.
12463 (tdesc_reg): Likewise.
12464 (tdesc_reg_up): Likewise.
12465
12466 2018-04-17 Tom Tromey <tom@tromey.com>
12467
12468 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
12469 discriminant field.
12470
12471 2018-04-17 Tom Tromey <tom@tromey.com>
12472
12473 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
12474
12475 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
12476
12477 * symtab.c (print_symbol_info): Skip printing filename and line
12478 number when `last' is NULL.
12479 (symtab_symbol_info): Use empty string instead of NULL for first
12480 invocation of print_symbol_info.
12481 (rbreak_command): Pass NULL to `last' parameter of
12482 print_symbol_info.
12483
12484 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
12485
12486 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
12487 instead of nullptr.
12488
12489 2018-04-16 Pedro Alves <palves@redhat.com>
12490
12491 * MAINTAINERS (sh): Remove.
12492 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
12493 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
12494 (ALLDEPFILES): Remove sh64-tdep.c.
12495 * NEWS: Mentions that support for SH-5/SH64 is removed.
12496 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
12497 (sh*-*-openbsd*): Ditto.
12498 (sh64-*-elf*): Remove.
12499 (sh*): Remove.
12500 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
12501 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
12502 * sh-tdep.c: No longer include "sh64-tdep.h".
12503 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
12504 * sh64-tdep.c, sh64-tdep.h: Remove files.
12505
12506 2018-04-16 Pedro Alves <palves@redhat.com>
12507
12508 * MAINTAINERS: Remove m88k.
12509 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
12510 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
12511 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
12512 * NEWS: Mention that support for m88k was removed.
12513 * configure.host (m88*-*-*): Remove support.
12514 * configure.nat (m88k-*-*): Remove support.
12515 * configure.tgt (m88*-*-openbsd*): Remove.
12516 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
12517
12518 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
12519
12520 * configure.tgt (x86_tobjs): New variable.
12521 (amd64_tobjs, i386_tobjs): Use it.
12522
12523 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
12524
12525 * symtab.c (print_symbol_info): Precede the symbol definition by
12526 the line number when available.
12527 * NEWS: Advertise this enhancement.
12528
12529 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12530
12531 * NEWS (New options): announce set/show record btrace cpu.
12532 * btrace.c: Include record-btrace.h.
12533 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
12534 the vendor is unknown.
12535 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
12536 Maybe overwrite the btrace configuration's cpu.
12537 (btrace_compute_ftrace): Add cpu parameter. Update callers.
12538 (btrace_fetch): Add cpu parameter. Update callers.
12539 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
12540 Maybe overwrite the btrace configuration's cpu. Skip enabling
12541 errata workarounds if the vendor is unknown.
12542 * python/py-record-btrace.c: Include record-btrace.h.
12543 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
12544 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
12545 * record-btrace.c (record_btrace_cpu_state_kind): New.
12546 (record_btrace_cpu): New.
12547 (set_record_btrace_cpu_cmdlist): New.
12548 (record_btrace_get_cpu): New.
12549 (require_btrace_thread, record_btrace_info)
12550 (record_btrace_resume_thread): Call record_btrace_get_cpu.
12551 (cmd_set_record_btrace_cpu_none): New.
12552 (cmd_set_record_btrace_cpu_auto): New.
12553 (cmd_set_record_btrace_cpu): New.
12554 (cmd_show_record_btrace_cpu): New.
12555 (_initialize_record_btrace): Initialize set/show record btrace cpu
12556 commands.
12557 * record-btrace.h (record_btrace_get_cpu): New.
12558
12559 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12560
12561 * record.c (set_record_command): Fix typo in message.
12562
12563 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12564
12565 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
12566
12567 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12568
12569 * infrun.c (process_event_stop_test): Call
12570 gdbarch_in_indirect_branch_thunk.
12571 * gdbarch.sh (in_indirect_branch_thunk): New.
12572 * gdbarch.c: Regenerated.
12573 * gdbarch.h: Regenerated.
12574 * x86-tdep.h: New.
12575 * x86-tdep.c: New.
12576 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
12577 (HFILES_NO_SRCDIR): Add x86-tdep.h.
12578 (ALLDEPFILES): Add x86-tdep.c.
12579 * arch-utils.h (default_in_indirect_branch_thunk): New.
12580 * arch-utils.c (default_in_indirect_branch_thunk): New.
12581 * i386-tdep: Include x86-tdep.h.
12582 (i386_in_indirect_branch_thunk): New.
12583 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
12584 function.
12585 * amd64-tdep: Include x86-tdep.h.
12586 (amd64_in_indirect_branch_thunk): New.
12587 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
12588
12589 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
12590
12591 PR gdb/23053
12592 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
12593 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
12594 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
12595 regression.
12596
12597 2018-04-12 Tom Tromey <tom@tromey.com>
12598
12599 * rust-lang.c (rust_print_struct_def): Remove univariant code.
12600 (rust_evaluate_subexp): Likewise.
12601
12602 2018-04-12 Pedro Alves <palves@redhat.com>
12603
12604 * procfs.c (procfs_detach): Make forward declaration's prototype
12605 match definition's protototype.
12606 (proc_get_LDT_entry): Remove stale do_cleanups call.
12607
12608 2018-04-12 Pedro Alves <palves@redhat.com>
12609
12610 * target.h (target_ops::to_has_exited): Delete.
12611 (target_has_exited): Delete.
12612 * target-delegates.c: Regenerate.
12613
12614 2018-04-11 Pedro Alves <palves@redhat.com>
12615
12616 * target.c (fileio_fh_t::t): Add comment.
12617 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
12618 (target_fileio_close): Handle a NULL target.
12619 (invalidate_fileio_fh): New.
12620 (target_close): Call it.
12621 * remote.c (remote_hostio_send_command): No longer check whether
12622 remote_desc is open.
12623
12624 2018-04-11 Pedro Alves <palves@redhat.com>
12625
12626 * target.c (fileio_fh_t): Make it a named struct instead of a
12627 typedef.
12628 (fileio_fh_t::is_closed): New method.
12629 (DEF_VEC_O (fileio_fh_t)): Remove.
12630 (fileio_fhandles): Now a std::vector.
12631 (is_closed_fileio_fh): Delete.
12632 (acquire_fileio_fd): Adjust. Rename parameters.
12633 (release_fileio_fd): Adjust.
12634 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
12635 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
12636 (target_fileio_close): Adjust.
12637
12638 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
12639
12640 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
12641 index.
12642
12643 2018-04-10 Pedro Alves <palves@redhat.com>
12644
12645 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
12646 (scoped_finish_thread_state): New class.
12647 * infcmd.c (run_command_1): Use it instead of finish_thread_state
12648 cleanup.
12649 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
12650 (fetch_inferior_event, normal_stop): Likewise.
12651 * thread.c (finish_thread_state_cleanup): Delete.
12652
12653 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12654 Pedro Alves <palves@redhat.com>
12655
12656 * value.c: Include "selftest.h" and "common/array-view.h".
12657 (struct range) <operator ==>: New.
12658 (test_ranges_contain): New.
12659 (check_ranges_vector): New.
12660 (test_insert_into_bit_range_vector): New.
12661 (_initialize_values): Register selftests.
12662 * common/array-view.h (operator==, operator!=): New.
12663
12664 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12665
12666 * common/gdb_vecs.h (unordered_remove): Add overload that takes
12667 an iterator.
12668 * inline-frame.c: Include <algorithm>.
12669 (struct inline_state): Add constructor.
12670 (inline_state_s): Remove.
12671 (DEF_VEC_O(inline_state_s)): Remove.
12672 (inline_states): Change type to std::vector.
12673 (find_inline_frame_state): Adjust to std::vector.
12674 (allocate_inline_frame_state): Remove.
12675 (clear_inline_frame_state): Adjust to std::vector.
12676 (skip_inline_frames): Adjust to std::vector.
12677
12678 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12679
12680 * tracepoint.h (struct trace_state_variable): Add constructor.
12681 <name>: Change type to std::string.
12682 * tracepoint.c (tsv_s): Remove.
12683 (DEF_VEC_O(tsv_s)): Remove.
12684 (tvariables): Change to std::vector.
12685 (create_trace_state_variable): Adjust to std::vector.
12686 (find_trace_state_variable): Likewise.
12687 (find_trace_state_variable_by_number): Likewise.
12688 (delete_trace_state_variable): Likewise.
12689 (trace_variable_command): Adjust to std::string.
12690 (delete_trace_variable_command): Likewise.
12691 (tvariables_info_1): Adjust to std::vector.
12692 (save_trace_state_variables): Likewise.
12693 (start_tracing): Likewise.
12694 (merge_uploaded_trace_state_variables): Adjust to std::vector
12695 and std::string.
12696 * target.h (struct target_ops)
12697 <to_download_trace_state_variable>: Pass reference to
12698 trace_state_variable.
12699 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
12700 * target-delegates.c: Re-generate.
12701 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
12702 (mi_tsv_deleted): Likewise.
12703 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
12704 * remote.c (remote_download_trace_state_variable): Change
12705 pointer to reference and adjust.
12706 * make-target-delegates (parse_argtypes): Handle references.
12707 (write_function_header): Likewise.
12708 (munge_type): Likewise.
12709
12710 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12711
12712 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12713 string_view-selftests.c.
12714 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
12715 testsuite.
12716 * unittests/basic_string_view/cons/char/1.cc: Likewise.
12717 * unittests/basic_string_view/cons/char/2.cc: Likewise.
12718 * unittests/basic_string_view/cons/char/3.cc: Likewise.
12719 * unittests/basic_string_view/element_access/char/1.cc:
12720 Likewise.
12721 * unittests/basic_string_view/element_access/char/empty.cc:
12722 Likewise.
12723 * unittests/basic_string_view/element_access/char/front_back.cc:
12724 Likewise.
12725 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
12726 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
12727 Likewise.
12728 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
12729 Likewise.
12730 * unittests/basic_string_view/modifiers/swap/char/1.cc:
12731 Likewise.
12732 * unittests/basic_string_view/operations/compare/char/1.cc:
12733 Likewise.
12734 * unittests/basic_string_view/operations/compare/char/13650.cc:
12735 Likewise.
12736 * unittests/basic_string_view/operations/copy/char/1.cc:
12737 Likewise.
12738 * unittests/basic_string_view/operations/data/char/1.cc:
12739 Likewise.
12740 * unittests/basic_string_view/operations/find/char/1.cc:
12741 Likewise.
12742 * unittests/basic_string_view/operations/find/char/2.cc:
12743 Likewise.
12744 * unittests/basic_string_view/operations/find/char/3.cc:
12745 Likewise.
12746 * unittests/basic_string_view/operations/find/char/4.cc:
12747 Likewise.
12748 * unittests/basic_string_view/operations/rfind/char/1.cc:
12749 Likewise.
12750 * unittests/basic_string_view/operations/rfind/char/2.cc:
12751 Likewise.
12752 * unittests/basic_string_view/operations/rfind/char/3.cc:
12753 Likewise.
12754 * unittests/basic_string_view/operations/substr/char/1.cc:
12755 Likewise.
12756 * unittests/basic_string_view/operators/char/2.cc: Likewise.
12757 * unittests/string_view-selftests.c: New file.
12758
12759 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12760
12761 * unittests/basic_string_view/capacity/1.cc: New file.
12762 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
12763 * unittests/basic_string_view/cons/char/1.cc: New file.
12764 * unittests/basic_string_view/cons/char/2.cc: New file.
12765 * unittests/basic_string_view/cons/char/3.cc: New file.
12766 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
12767 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
12768 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
12769 * unittests/basic_string_view/element_access/char/1.cc: New file.
12770 * unittests/basic_string_view/element_access/char/2.cc: New file.
12771 * unittests/basic_string_view/element_access/char/empty.cc: New file.
12772 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
12773 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
12774 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
12775 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
12776 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
12777 * unittests/basic_string_view/include.cc: New file.
12778 * unittests/basic_string_view/inserters/char/1.cc: New file.
12779 * unittests/basic_string_view/inserters/char/2.cc: New file.
12780 * unittests/basic_string_view/inserters/char/3.cc: New file.
12781 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
12782 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
12783 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
12784 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
12785 * unittests/basic_string_view/literals/types.cc: New file.
12786 * unittests/basic_string_view/literals/values.cc: New file.
12787 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
12788 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
12789 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
12790 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
12791 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
12792 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
12793 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
12794 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
12795 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
12796 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
12797 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
12798 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
12799 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
12800 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
12801 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
12802 * unittests/basic_string_view/operations/data/char/1.cc: New file.
12803 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
12804 * unittests/basic_string_view/operations/find/char/1.cc: New file.
12805 * unittests/basic_string_view/operations/find/char/2.cc: New file.
12806 * unittests/basic_string_view/operations/find/char/3.cc: New file.
12807 * unittests/basic_string_view/operations/find/char/4.cc: New file.
12808 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
12809 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
12810 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
12811 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
12812 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
12813 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
12814 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
12815 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
12816 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
12817 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
12818 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
12819 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
12820 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
12821 * unittests/basic_string_view/operators/char/2.cc: New file.
12822 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
12823 * unittests/basic_string_view/range_access/char/1.cc: New file.
12824 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
12825 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
12826 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
12827 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
12828 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
12829 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
12830 * unittests/basic_string_view/requirements/typedefs.cc: New file.
12831 * unittests/basic_string_view/typedefs.cc: New file.
12832 * unittests/basic_string_view/types/1.cc: New file.
12833
12834 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12835
12836 * common/gdb_string_view.h: Remove libstdc++ implementation
12837 details, adjust to gdb reality.
12838 * common/gdb_string_view.tcc: Likewise.
12839 * cli/cli-script.c (struct string_view): Remove.
12840 (user_args) <m_args>: Change element type to gdb::string_view.
12841 (user_args::insert_args): Adjust.
12842
12843 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12844
12845 * common/gdb_string_view.h: New file.
12846 * common/gdb_string_view.tcc: New file.
12847
12848 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12849
12850 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
12851 * configure: Re-generate.
12852
12853 2018-04-09 Pedro Alves <palves@redhat.com>
12854
12855 * gdbarch.sh: Include "observable.h" instead of "observer.h".
12856 (set_target_gdbarch): Call
12857 gdb::observers::architecture_changed.notify instead of
12858 observer_notify_architecture_changed.
12859
12860 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12861
12862 * tracepoint.c (struct current_traceframe_cleanup): Remove.
12863 (do_restore_current_traceframe_cleanup): Remove.
12864 (restore_current_traceframe_cleanup_dtor): Remove.
12865 (make_cleanup_restore_current_traceframe): Remove.
12866 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
12867 New.
12868 * tracepoint.h (struct scoped_restore_current_traceframe): New.
12869 * infrun.c (fetch_inferior_event): Use
12870 scoped_restore_current_traceframe.
12871
12872 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12873
12874 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
12875 Remove.
12876 <n_allocated_type_units>: Remove.
12877 <all_type_units>: Change to std::vector.
12878 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
12879 to std::vector change.
12880 (dwarf2_per_objfile::get_cutu): Likewise.
12881 (dwarf2_per_objfile::get_tu): Likewise.
12882 (create_signatured_type_table_from_index): Likewise.
12883 (create_signatured_type_table_from_debug_names): Likewise.
12884 (dw2_symtab_iter_next): Likewise.
12885 (dw2_print_stats): Likewise.
12886 (dw2_expand_all_symtabs): Likewise.
12887 (dw2_expand_marked_cus): Likewise.
12888 (dw2_debug_names_iterator::next): Likewise.
12889 (dwarf2_initialize_objfile): Likewise.
12890 (add_signatured_type_cu_to_table): Likewise.
12891 (create_all_type_units): Likewise.
12892 (add_type_unit): Likewise.
12893 (struct tu_abbrev_offset): Add constructor.
12894 (build_type_psymtabs_1): Adjust to std::vector change.
12895 (print_tu_stats): Likewise.
12896 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
12897 (write_debug_names): Likewise.
12898
12899 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12900
12901 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
12902 Make an std::vector.
12903 <n_comp_units>: Remove.
12904 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
12905 to std::vector change.
12906 (dwarf2_per_objfile::get_cutu): Likewise.
12907 (dwarf2_per_objfile::get_cu): Likewise.
12908 (create_cus_from_index): Likewise.
12909 (create_addrmap_from_index): Likewise.
12910 (create_addrmap_from_aranges): Likewise.
12911 (dwarf2_read_index): Likewise.
12912 (dw2_find_last_source_symtab): Likewise.
12913 (dw2_map_symtabs_matching_filename): Likewise.
12914 (dw2_symtab_iter_next): Likewise.
12915 (dw2_print_stats): Likewise.
12916 (dw2_expand_all_symtabs): Likewise.
12917 (dw2_expand_symtabs_with_fullname): Likewise.
12918 (dw2_expand_marked_cus): Likewise.
12919 (dw2_map_symbol_filenames): Likewise.
12920 (create_cus_from_debug_names): Likewise.
12921 (dwarf2_read_debug_names): Likewise.
12922 (dw2_debug_names_iterator::next): Likewise.
12923 (dwarf2_initialize_objfile): Likewise.
12924 (set_partial_user): Likewise.
12925 (dwarf2_build_psymtabs_hard): Likewise.
12926 (read_comp_units_from_section): Remove arguments, adjust to
12927 std::vector change.
12928 (create_all_comp_units): Adjust to std::vector and
12929 read_comp_units_from_section changes.
12930 (dwarf2_find_containing_comp_unit): Adjust to std::vector
12931 change.
12932 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
12933 (psyms_seen_size): Likewise.
12934 (write_gdbindex): Likewise.
12935 (write_debug_names): Likewise.
12936
12937 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12938
12939 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
12940 with dwarf2_per_objfile.
12941 (create_cus_from_index): Likewise.
12942 (create_signatured_type_table_from_index): Likewise.
12943 (dwarf2_read_index): Likewise.
12944 (dwarf2_initialize_objfile): Likewise.
12945 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
12946 per_cu rather than get_dwarf2_per_objfile.
12947
12948 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12949
12950 * dwarf2read.h (struct signatured_type): Forward declare.
12951 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
12952 New methods.
12953 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
12954 (dw2_get_cutu): ...this.
12955 (dwarf2_per_objfile::get_cu): Rename from...
12956 (dw2_get_cu): ...this.
12957 (dwarf2_per_objfile::get_tu): New.
12958 (create_addrmap_from_index): Adjust.
12959 (create_addrmap_from_aranges): Adjust.
12960 (dw2_find_last_source_symtab): Adjust.
12961 (dw2_map_symtabs_matching_filename): Adjust.
12962 (dw2_symtab_iter_next): Adjust.
12963 (dw2_print_stats): Adjust.
12964 (dw2_expand_all_symtabs): Adjust.
12965 (dw2_expand_symtabs_with_fullname): Adjust.
12966 (dw2_expand_marked_cus): Adjust.
12967 (dw_expand_symtabs_matching_file_matcher): Adjust.
12968 (dw2_map_symbol_filenames): Adjust.
12969 (dw2_debug_names_iterator::next): Adjust.
12970 (dwarf2_initialize_objfile): Adjust.
12971 (set_partial_user): Adjust.
12972 (dwarf2_build_psymtabs_hard): Adjust.
12973
12974 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12975
12976 * dwarf2read.c (create_signatured_type_table_from_debug_names):
12977 Remove unused variables.
12978 (dw2_map_symtabs_matching_filename): Likewise.
12979 (dwarf2_record_block_ranges): Likewise.
12980 (dwarf2_read_addr_index): Likewise.
12981 (follow_die_offset): Likewise.
12982
12983 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12984
12985 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
12986 to symbol_file_add_main.
12987
12988 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12989
12990 PR mi/22299
12991 * mi/mi-console.c (do_fputc_async_safe): New.
12992 (mi_console_file::write_async_safe): New.
12993 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
12994 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
12995 New.
12996 * ui-file.c (ui_file::putstrn): Adjust call to
12997 fputstrn_unfiltered.
12998 * utils.c (printchar): Replace do_fputs and do_fprintf
12999 parameters by do_fputc.
13000 (fputstr_filtered): Adjust call to printchar.
13001 (fputstr_unfiltered): Likewise.
13002 (fputstrn_filtered): Likewise.
13003 (fputstrn_unfiltered): Add do_fputc parameter, pass to
13004 printchar.
13005 * utils.h (do_fputc_ftype): New typedef.
13006 (fputstrn_unfiltered): Add do_fputc parameter.
13007
13008 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13009
13010 * regformats/i386/i386-avx.dat: Remove.
13011
13012 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
13013
13014 PR gdb/22979
13015 * amd64-tdep.c (amd64_none_init_abi): New function.
13016 (amd64_x32_none_init_abi): New function.
13017 (_initialize_amd64_tdep): Register handlers for x86-64 and
13018 x64_32 with GDB_OSABI_NONE.
13019 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
13020 GDB_OSABI_NONE osabi.
13021
13022 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
13023
13024 PR gdb/22980
13025 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
13026 GDB_OSABI_NONE.
13027 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
13028 * osabi.c (gdb_osabi_names): Add "unknown" entry.
13029
13030 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
13031
13032 * common/byte-vector.h (char_vector): New type.
13033 * target.h (target_read_alloc): Return
13034 gdb::optional<byte_vector>.
13035 (target_read_stralloc): Return gdb::optional<char_vector>.
13036 (target_get_osdata): Return gdb::optional<char_vector>.
13037 * target.c (target_read_alloc_1): Templatize. Replacement
13038 manual memory management with vector.
13039 (target_read_alloc): Change return type, adjust.
13040 (target_read_stralloc): Change return type, adjust.
13041 (target_get_osdata): Change return type, adjust.
13042 * auxv.c (struct auxv_info) <length>: Remove.
13043 <data>: Change type to gdb::optional<byte_vector>.
13044 (auxv_inferior_data_cleanup): Free auxv_info with delete.
13045 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
13046 (target_auxv_search): Adjust.
13047 (fprint_target_auxv): Adjust.
13048 * avr-tdep.c (avr_io_reg_read_command): Adjust.
13049 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
13050 (linux_make_corefile_notes): Adjust.
13051 * osdata.c (get_osdata): Adjust.
13052 * remote.c (remote_get_threads_with_qxfer): Adjust.
13053 (remote_memory_map): Adjust.
13054 (remote_traceframe_info): Adjust.
13055 (btrace_read_config): Adjust.
13056 (remote_read_btrace): Adjust.
13057 (remote_pid_to_exec_file): Adjust.
13058 * solib-aix.c (solib_aix_get_library_list): Adjust.
13059 * solib-dsbt.c (decode_loadmap): Don't free buf.
13060 (dsbt_get_initial_loadmaps): Adjust.
13061 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
13062 * solib-target.c (solib_target_current_sos): Adjust.
13063 * tracepoint.c (sdata_make_value): Adjust.
13064 * xml-support.c (xinclude_start_include): Adjust.
13065 (xml_fetch_content_from_file): Adjust.
13066 * xml-support.h (xml_fetch_another): Change return type.
13067 (xml_fetch_content_from_file): Change return type.
13068 * xml-syscall.c (xml_init_syscalls_info): Adjust.
13069 * xml-tdesc.c (file_read_description_xml): Adjust.
13070 (fetch_available_features_from_target): Change return type.
13071 (target_fetch_description_xml): Adjust.
13072 (target_read_description_xml): Adjust.
13073
13074 2018-04-06 Tom Tromey <tom@tromey.com>
13075
13076 * value.c (~value): Update.
13077 (struct value) <contents>: Now unique_xmalloc_ptr.
13078 (value_contents_bits_eq, allocate_value_contents)
13079 (value_contents_raw, value_contents_all_raw)
13080 (value_contents_for_printing, value_contents_for_printing_const)
13081 (set_value_enclosing_type): Update.
13082
13083 2018-04-06 Tom Tromey <tom@tromey.com>
13084
13085 * value.c (range_s): Remove typedef, VEC.
13086 (struct range): Add operator<.
13087 (range_lessthan): Remove.
13088 (ranges_contain): Change type.
13089 (~value): Update.
13090 (struct value) <unavailable, optimized_out>: Now std::vector.
13091 (value_entirely_available)
13092 (value_entirely_covered_by_range_vector)
13093 (value_entirely_unavailable, value_entirely_optimized_out):
13094 Update.
13095 (insert_into_bit_range_vector): Change argument type.
13096 (find_first_range_overlap): Likewise.
13097 (struct ranges_and_idx, value_contents_bits_eq)
13098 (require_not_optimized_out, require_available): Update.
13099 (ranges_copy_adjusted): Change argument types.
13100 (value_optimized_out, value_copy, value_fetch_lazy): Update.
13101
13102 2018-04-06 Tom Tromey <tom@tromey.com>
13103
13104 * value.c (~value): Update.
13105 (struct value) <parent>: Now a value_ref_ptr.
13106 (value_parent, set_value_parent, value_address, value_copy):
13107 Update.
13108
13109 2018-04-06 Tom Tromey <tom@tromey.com>
13110
13111 * value.c (struct value): Add constructor, destructor, and member
13112 initializers.
13113 (allocate_value_lazy, value_decref): Update.
13114
13115 2018-04-06 Tom Tromey <tom@tromey.com>
13116
13117 * value.c (struct value) <released, next>: Remove.
13118 (all_values): Now a std::vector.
13119 (allocate_value_lazy): Update.
13120 (value_next): Remove.
13121 (value_mark, value_free_to_mark, release_value)
13122 (value_release_to_mark): Update.
13123
13124 2018-04-06 Tom Tromey <tom@tromey.com>
13125
13126 * value.h (fetch_subexp_value, value_release_to_mark): Update.
13127 (free_value_chain): Remove.
13128 * value.c (free_value_chain): Remove.
13129 (value_release_to_mark): Return a std::vector.
13130 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
13131 std::vector.
13132 (check_condition): Update.
13133 * eval.c (fetch_subexp_value): Change "val_chain" to a
13134 std::vector.
13135 * breakpoint.c (update_watchpoint): Update.
13136 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
13137
13138 2018-04-06 Tom Tromey <tom@tromey.com>
13139
13140 * value.h (free_all_values): Remove.
13141 * value.c (free_all_values): Remove.
13142
13143 2018-04-06 Tom Tromey <tom@tromey.com>
13144
13145 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
13146 (value_history_chain, value_history_count): Remove.
13147 (value_history): New global.
13148 (record_latest_value, access_value_history, show_values)
13149 (preserve_values): Update.
13150
13151 2018-04-06 Tom Tromey <tom@tromey.com>
13152
13153 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
13154 * varobj.c (varobj_set_display_format, varobj_set_value)
13155 (install_default_visualizer, construct_visualizer)
13156 (install_new_value, ~varobj, varobj_get_value_type)
13157 (my_value_of_variable, varobj_editable_p): Update.
13158 * c-varobj.c (c_describe_child, c_value_of_variable)
13159 (cplus_number_of_children, cplus_describe_child): Update.
13160 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
13161 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
13162 (ada_value_of_variable, ada_value_is_changeable_p): Update.
13163
13164 2018-04-06 Tom Tromey <tom@tromey.com>
13165
13166 * printcmd.c (last_examine_address): Change type to
13167 value_ref_ptr.
13168 (do_examine, x_command): Update.
13169
13170 2018-04-06 Tom Tromey <tom@tromey.com>
13171
13172 * value.c (release_value): Update.
13173 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
13174 (struct bpstats) <val>: Now a value_ref_ptr.
13175 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
13176 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
13177 (~watchpoint, print_it_watchpoint, watch_command_1)
13178 (invalidate_bp_value_on_memory_change): Update.
13179
13180 2018-04-06 Tom Tromey <tom@tromey.com>
13181
13182 * varobj.c (varobj_clear_saved_item)
13183 (update_dynamic_varobj_children, install_new_value, ~varobj):
13184 Update.
13185 * value.h (value_incref): Move declaration earlier.
13186 (value_decref): Rename from value_free.
13187 (struct value_ref_policy): New.
13188 (value_ref_ptr): New typedef.
13189 (struct value_deleter): Remove.
13190 (gdb_value_up): Remove typedef.
13191 (release_value): Change return type.
13192 (release_value_or_incref): Remove.
13193 * value.c (set_value_parent): Update.
13194 (value_incref): Change return type.
13195 (value_decref): Rename from value_free.
13196 (value_free_to_mark, free_all_values, free_value_chain): Update.
13197 (release_value): Return value_ref_ptr.
13198 (release_value_or_incref): Remove.
13199 (record_latest_value, set_internalvar, clear_internalvar):
13200 Update.
13201 * stack.c (info_frame_command): Don't call value_free.
13202 * python/py-value.c (valpy_dealloc, valpy_new)
13203 (value_to_value_object): Update.
13204 * printcmd.c (do_examine): Update.
13205 * opencl-lang.c (lval_func_free_closure): Update.
13206 * mi/mi-main.c (register_changed_p): Don't call value_free.
13207 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
13208 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
13209 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
13210 value_free.
13211 * guile/scm-value.c (vlscm_free_value_smob)
13212 (vlscm_scm_from_value): Update.
13213 * frame.c (frame_register_unwind, frame_unwind_register_signed)
13214 (frame_unwind_register_unsigned, get_frame_register_bytes)
13215 (put_frame_register_bytes): Don't call value_free.
13216 * findvar.c (address_from_register): Don't call value_free.
13217 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
13218 * dwarf2loc.c (entry_data_value_free_closure)
13219 (value_of_dwarf_reg_entry, free_pieced_value_closure)
13220 (dwarf2_evaluate_loc_desc_full): Update.
13221 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
13222 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
13223 (~watchpoint, watch_command_1)
13224 (invalidate_bp_value_on_memory_change): Update.
13225 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
13226
13227 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
13228
13229 PR gdb/23022
13230 * warning.m4: Add -Wno-error=deprecated-register.
13231 * configure: Re-generate.
13232
13233 2018-04-05 Tom Tromey <tom@tromey.com>
13234
13235 * linespec.h: Remove include of "vec.h".
13236
13237 2018-04-05 Tom Tromey <tom@tromey.com>
13238
13239 * linespec.c (typep): Remove typedef.
13240 (find_methods, find_superclass_methods): Take a std::vector.
13241 (find_method): Use std::vector.
13242
13243 2018-04-05 Tom Tromey <tom@tromey.com>
13244
13245 * utils.c (compare_strings): Remove.
13246 * utils.h (compare_strings): Remove.
13247 * objc-lang.h (find_imps): Update.
13248 * objc-lang.c (find_methods): Take a std::vector.
13249 (uniquify_strings, find_imps): Likewise.
13250 * linespec.c (find_methods): Take a std::vector.
13251 (decode_objc): Use std::vector.
13252 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
13253 a std::vector.
13254 (find_method, find_function_symbols): Use std::vector.
13255
13256 2018-04-05 Tom Tromey <tom@tromey.com>
13257
13258 * completer.c (completion_tracker::completion_tracker): Remove
13259 cast.
13260 (completion_tracker::discard_completions): Likewise.
13261 * breakpoint.c (ambiguous_names_p): Remove cast.
13262 * ada-lang.c (_initialize_ada_language): Remove cast.
13263 * utils.h (streq): Update.
13264 (streq_hash): Add new declaration.
13265 * utils.c (streq): Return bool.
13266 (streq_hash): New function.
13267
13268 2018-04-05 Tom Tromey <tom@tromey.com>
13269
13270 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
13271 Remove a string copy.
13272
13273 2018-04-05 Tom Tromey <tom@tromey.com>
13274
13275 * linespec.c (filter_results): Use std::vector.
13276 (decode_line_2, decode_line_full): Update.
13277
13278 2018-04-05 Tom Tromey <tom@tromey.com>
13279
13280 * linespec.c (canonical_to_fullform): Return std::string.
13281 (filter_results): Update.
13282 (struct decode_line_2_item): Add constructor.
13283 <fullform, displayform>: Now std::string.
13284 (decode_line_2_compare_items): Now a std::sort comparator.
13285 (decode_line_2): Update.
13286
13287 2018-04-05 Tom Tromey <tom@tromey.com>
13288
13289 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
13290 (unexpected_linespec_error): Update.
13291 (linespec_parse_basic, parse_linespec): Update.
13292
13293 2018-04-05 Tom Tromey <tom@tromey.com>
13294
13295 * linespec.c (linespec_parse_basic): Reindent.
13296
13297 2018-04-05 Tom Tromey <tom@tromey.com>
13298
13299 * minsyms.h (iterate_over_minimal_symbols): Update.
13300 * minsyms.c (iterate_over_minimal_symbols): Take a
13301 gdb::function_view.
13302 * linespec.c (struct collect_minsyms): Remove.
13303 (compare_msyms): Now a std::sort comparator.
13304 (add_minsym): Add parameters.
13305 (search_minsyms_for_name): Update. Use std::vector.
13306
13307 2018-04-03 Tom Tromey <tom@tromey.com>
13308
13309 * mipsread.c (read_alphacoff_dynamic_symtab): Use
13310 gdb::byte_vector.
13311
13312 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
13313
13314 * MAINTAINERS (Write After Approval): Add Weimin Pan.
13315
13316 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
13317
13318 PR gdb/16959
13319 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
13320 printing static type.
13321
13322 2018-04-01 Tom Tromey <tom@tromey.com>
13323
13324 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
13325 (rs6000_xfer_shared_libraries): Update.
13326
13327 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
13328
13329 * common/gdb_vecs.h (char_ptr): Remove.
13330 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
13331
13332 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
13333
13334 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
13335 with std::vector.
13336 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
13337
13338 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
13339
13340 * tracepoint.h (struct uploaded_tp): Initialize fields.
13341 <actions, step_actions, cmd_strings>: Change type to
13342 std::vector<char *>.
13343 * tracepoint.c (get_uploaded_tp): Allocate with new.
13344 (free_uploaded_tps): Free with delete.
13345 (parse_tracepoint_definition): Adjust to std::vector change.
13346 * breakpoint.c (read_uploaded_action): Likewise.
13347 (create_tracepoint_from_upload): Likewise.
13348 * ctf.c (ctf_write_uploaded_tp): Likewise.
13349 (SET_ARRAY_FIELD): Likewise.
13350 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
13351
13352 2018-03-30 Tom Tromey <tom@tromey.com>
13353
13354 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
13355 std::unique_ptr.
13356 (svr4_keep_data_in_core): Update.
13357 (svr4_read_so_list): Update.
13358
13359 2018-03-30 Tom Tromey <tom@tromey.com>
13360
13361 * windows-nat.c (handle_output_debug_string, handle_exception):
13362 Update.
13363 * target.h (target_read_string): Update.
13364 * target.c (target_read_string): Change "string" to
13365 unique_xmalloc_ptr.
13366 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
13367 Update.
13368 * solib-frv.c (frv_current_sos): Update.
13369 * solib-dsbt.c (dsbt_current_sos): Update.
13370 * solib-darwin.c (darwin_current_sos): Update.
13371 * linux-thread-db.c (inferior_has_bug): Update.
13372 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
13373 Update. Remove alloca.
13374 * ada-lang.c (ada_main_name): Update.
13375
13376 2018-03-30 Tom Tromey <tom@tromey.com>
13377
13378 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
13379 (struct dwo_file_deleter): New.
13380 (dwo_file_up): New typedef.
13381 (open_and_init_dwo_file): Use dwo_file_up.
13382 (free_dwo_file_cleanup): Remove.
13383
13384 2018-03-30 Tom Tromey <tom@tromey.com>
13385
13386 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
13387 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
13388
13389 2018-03-30 Tom Tromey <tom@tromey.com>
13390
13391 * dwarf2read.c (class free_cached_comp_units): New class.
13392 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
13393 (free_cached_comp_units): Remove function.
13394
13395 2018-03-30 Tom Tromey <tom@tromey.com>
13396
13397 * utils.h (make_cleanup_unpush_target): Remove.
13398 * inf-ptrace.c (struct target_unpusher): New.
13399 (target_unpush_up) New typedef.
13400 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
13401 target_unpush_up.
13402 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
13403
13404 2018-03-27 Tom Tromey <tom@tromey.com>
13405
13406 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
13407
13408 2018-03-27 Pedro Alves <palves@redhat.com>
13409 Tom Tromey <tom@tromey.com>
13410
13411 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
13412 destructor. Now a class.
13413 (gdb_readline_wrapper_cleanup): Remove function.
13414 (gdb_readline_wrapper): Remove cleanups.
13415
13416 2018-03-27 Tom Tromey <tom@tromey.com>
13417
13418 * typeprint.h (struct type_print_options) <local_typedefs,
13419 global_typedefs>: Remove "struct" keyword.
13420 (class typedef_hash_table): New class.
13421 (recursively_update_typedef_hash, add_template_parameters)
13422 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
13423 (find_typedef_in_hash): Don't declare.
13424 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
13425 (typedef_hash_table::recursively_update): Rename from
13426 recursively_update_typedef_hash. Now a member.
13427 (typedef_hash_table::add_template_parameters): Rename from
13428 add_template_parameters. Now a member.
13429 (typedef_hash_table::typedef_hash_table): Now a constructor;
13430 rename from create_typedef_hash.
13431 (typedef_hash_table::~typedef_hash_table): Now a destructor;
13432 rename from free_typedef_hash.
13433 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
13434 (do_free_global_table): Remove.
13435 (typedef_hash_table::typedef_hash_table): New constructor; renamed
13436 from copy_type_recursive.
13437 (create_global_typedef_table): Remove.
13438 (typedef_hash_table::find_global_typedef): Now a member of
13439 typedef_hash_table.
13440 (typedef_hash_table::find_typedef): Rename from
13441 find_typedef_in_hash; now a member.
13442 (whatis_exp): Update.
13443 * extension.h (struct ext_lang_type_printers): Add constructor and
13444 destructor.
13445 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
13446 declare.
13447 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
13448 Now a constructor; rename from start_ext_lang_type_printers.
13449 (ext_lang_type_printers): Now a destructor; rename from
13450 free_ext_lang_type_printers.
13451 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
13452 Update.
13453 (c_type_print_base_struct_union): Update. Remove cleanups.
13454
13455 2018-03-27 Tom Tromey <tom@tromey.com>
13456
13457 * dwarf-index-write.c: Include <cmath>.
13458
13459 2018-03-27 Joel Brobecker <brobecker@adacore.com>
13460
13461 * NEWS: Add entry describing new "set|show varsize-limit" command.
13462 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
13463 command.
13464 * printcmd.c (_initialize_printcmd): Add "set var" alias of
13465 "set variable".
13466
13467 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
13468
13469 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
13470 dwarf-index-write.c
13471 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
13472 * dwarf-index-common.c: New file.
13473 * dwarf-index-common.h: New file.
13474 * dwarf-index-write.c: New file.
13475 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
13476 (struct dwarf2_section_info): Move from here.
13477 (dwarf2_section_info_def): Likewise.
13478 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
13479 (offset_type): Likewise.
13480 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
13481 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
13482 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
13483 (byte_swap): Likewise.
13484 (MAYBE_SWAP): Likewise.
13485 (dwarf2_per_cu_ptr): Likewise.
13486 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
13487 (struct tu_stats): Likewise.
13488 (struct dwarf2_per_objfile): Likewise.
13489 (struct dwarf2_per_cu_data): Likewise.
13490 (struct signatured_type): Likewise.
13491 (sig_type_ptr): Likewise.
13492 (DEF_VEC_P (sig_type_ptr)): Likewise.
13493 (INDEX4_SUFFIX): Likewise.
13494 (INDEX5_SUFFIX): Likewise.
13495 (DEBUG_STR_SUFFIX): Likewise.
13496 (dwarf2_read_section): Make non-static.
13497 (mapped_index_string_hash): Move from here.
13498 (dwarf5_djb_hash): Likewise.
13499 (file_write): Likewise.
13500 (class data_buf): Likewise.
13501 (struct symtab_index_entry): Likewise.
13502 (struct mapped_symtab): Likewise.
13503 (find_slot): Likewise.
13504 (hash_expand): Likewise.
13505 (add_index_entry): Likewise.
13506 (uniquify_cu_indices): Likewise.
13507 (class c_str_view): Likewise.
13508 (class c_str_view_hasher): Likewise.
13509 (class vector_hasher): Likewise.
13510 (write_hash_table): Likewise.
13511 (psym_index_map): Likewise.
13512 (struct addrmap_index_data): Likewise.
13513 (add_address_entry): Likewise.
13514 (add_address_entry_worker): Likewise.
13515 (write_address_map): Likewise.
13516 (symbol_kind): Likewise.
13517 (write_psymbols): Likewise.
13518 (struct signatured_type_index_data): Likewise.
13519 (write_one_signatured_type): Likewise.
13520 (recursively_count_psymbols): Likewise.
13521 (recursively_write_psymbols): Likewise.
13522 (class debug_names): Likewise.
13523 (check_dwarf64_offsets): Likewise.
13524 (psyms_seen_size): Likewise.
13525 (write_gdbindex): Likewise.
13526 (write_debug_names): Likewise.
13527 (assert_file_size): Likewise.
13528 (write_psymtabs_to_index): Likewise.
13529 (save_gdb_index_command): Likewise.
13530 (_initialize_dwarf2_read): Don't register the "save gdb-index"
13531 command.
13532 * dwarf2read.h: New file.
13533
13534 2018-03-27 Joel Brobecker <brobecker@adacore.com>
13535
13536 PR gdb/22670
13537 * dwarf2read.c (dwarf2_physname): Do not return the demangled
13538 symbol name if the CU's language stores symbol names in linkage
13539 format.
13540 * language.h (struct language_defn)
13541 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
13542 all instances of this struct.
13543
13544 2018-03-26 Tom Tromey <tom@tromey.com>
13545
13546 * stack.c (backtrace_command_1): Remove verbose code.
13547
13548 2018-03-26 Tom Tromey <tom@tromey.com>
13549
13550 * python/py-framefilter.c (py_print_type): Don't catch
13551 exceptions. Return void.
13552 (py_print_value): Likewise.
13553 (py_print_single_arg): Likewise.
13554 (enumerate_args): Don't catch exceptions.
13555 (py_print_args): Likewise.
13556 (py_print_frame): Likewise.
13557 (gdbpy_apply_frame_filter): Catch exceptions here.
13558
13559 2018-03-26 Tom Tromey <tom@tromey.com>
13560
13561 * stack.c (_initialize_stack): Remove trailing newlines from help
13562 text. Add "Usage" line to "backtrace" help.
13563
13564 2018-03-26 Tom Tromey <tom@tromey.com>
13565
13566 PR python/16486:
13567 * python/py-framefilter.c (py_print_args): Call wrap_hint.
13568
13569 2018-03-26 Tom Tromey <tom@tromey.com>
13570
13571 * python/py-framefilter.c (py_print_single_arg): Return
13572 EXT_LANG_BT_ERROR from catch.
13573
13574 2018-03-26 Tom Tromey <tom@tromey.com>
13575
13576 PR backtrace/15584:
13577 * stack.c (backtrace_command_1): Move some code into no-filters
13578 "if".
13579
13580 2018-03-26 Tom Tromey <tom@tromey.com>
13581
13582 * python/py-framefilter.c (throw_quit_or_print_exception): New
13583 function.
13584 (gdbpy_apply_frame_filter): Use it.
13585
13586 2018-03-26 Tom Tromey <tom@tromey.com>
13587
13588 PR cli/17716:
13589 * python/py-framefilter.c (py_print_type, py_print_value)
13590 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
13591 RETURN_MASK_ERROR.
13592
13593 2018-03-26 Tom Tromey <tom@tromey.com>
13594
13595 * python/py-framefilter.c (enumerate_args): Use
13596 gdb::unique_xmalloc_ptr.
13597
13598 2018-03-26 Tom Tromey <tom@tromey.com>
13599
13600 * python/py-framefilter.c (py_print_frame): Return
13601 EXT_LANG_BT_OK.
13602 (gdbpy_apply_frame_filter): Update comment.
13603 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
13604 Remove.
13605 <EXT_LANG_BT_NO_FILTERS>: Change value.
13606
13607 2018-03-26 Tom Tromey <tom@tromey.com>
13608
13609 PR backtrace/15582:
13610 * stack.c (backtrace_command): Parse "hide" argument.
13611 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
13612 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
13613 constant.
13614
13615 2018-03-26 Tom Tromey <tom@tromey.com>
13616
13617 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
13618 add "flags".
13619 (backtrace_command): Remove "fulltrace", add "flags".
13620
13621 2018-03-26 Tom Tromey <tom@tromey.com>
13622
13623 * stack.c (backtrace_command): Rewrite command line parsing.
13624
13625 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
13626
13627 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
13628
13629 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
13630
13631 * filename-seen-cache.h: Add include guard.
13632
13633 2018-03-26 Keith Seitz <keiths@redhat.com>
13634
13635 * symfile.c (place_section): Remove "struct" from section_addr_info
13636 in comment.
13637 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
13638 "struct" keyword from section_addr_info.
13639
13640 2018-03-26 Alan Hayward <alan.hayward@arm.com>
13641
13642 * regformats/regdef.h (reg): Add constructors.
13643
13644 2018-03-25 Pedro Alves <palves@redhat.com>
13645
13646 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
13647 if then/else bodies in var_func_name extraction.
13648
13649 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
13650
13651 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
13652 lookup_minimal_symbol() to find symbol entry.
13653 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
13654
13655 2018-03-23 Keith Seitz <keiths@redhat.com>
13656
13657 PR c++/22968
13658 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
13659 nested type definitions for C++, too.
13660
13661 2018-03-23 Tom Tromey <tom@tromey.com>
13662
13663 * machoread.c (struct oso_el): Add a constructor. Don't define as
13664 a typedef.
13665 (macho_register_oso): Remove.
13666 (macho_symtab_read): Take a std::vector.
13667 (oso_el_compare_name): Now a std::sort comparator.
13668 (macho_symfile_read_all_oso): Take a std::vector.
13669 (macho_symfile_read): Use std::vector. Remove cleanups.
13670
13671 2018-03-22 Tom Tromey <tom@tromey.com>
13672
13673 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
13674 (record_full_goto_bookmark): Use std::string.
13675
13676 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
13677
13678 PR tdep/18295
13679 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
13680 a single mask.
13681
13682 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
13683
13684 * rs6000-tdep.c (store_insn_p): New function.
13685 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
13686 and cr_reg to their unshifted values. Use store_insn_p to
13687 match LR saves using either R1 or fdata->alloca_reg. Use
13688 store_insn_p to match CR saves. Set alloca_reg_offset
13689 when alloca_reg and framep are set. Remove lr_reg shift
13690 when assigning to fdata->lr_register.
13691
13692 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
13693
13694 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
13695 command line args instead of emitting a warning.
13696
13697 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
13698
13699 * tracepoint.h (struct static_tracepoint_marker): Initialize
13700 fields, define default constructor, move constructor and move
13701 assignment, disable the rest.
13702 <str_id, extra>: Make std::string.
13703 (release_static_tracepoint_marker): Remove.
13704 (free_current_marker): Remove.
13705 * tracepoint.c (free_current_marker): Remove.
13706 (parse_static_tracepoint_marker_definition): Adjust to
13707 std::string, use new hex2str overload.
13708 (release_static_tracepoint_marker): Remove.
13709 (print_one_static_tracepoint_marker): Get marker by reference
13710 and adjust to std::string.
13711 (info_static_tracepoint_markers_command): Adjust to std::vector
13712 changes
13713 * target.h (static_tracepoint_marker_p): Remove typedef.
13714 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
13715 (struct target_ops) <to_static_tracepoint_marker_at>: Return
13716 bool.
13717 <to_static_tracepoint_markers_by_strid>: Return std::vector.
13718 * target-debug.h
13719 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
13720 (target_debug_print_std_vector_static_tracepoint_marker): New.
13721 (target_debug_print_struct_static_tracepoint_marker_p): Rename
13722 to...
13723 (target_debug_print_static_tracepoint_marker_p): ... this.
13724 * target-delegates.c: Re-generate.
13725 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
13726 Make std::string.
13727 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
13728 (decode_static_tracepoint_spec): Adjust to std::vector.
13729 (tracepoint_print_one_detail): Adjust to std::string.
13730 (strace_marker_decode_location): Adjust to std::string.
13731 (update_static_tracepoint): Adjust to std::string, remove call
13732 to release_static_tracepoint_marker.
13733 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
13734 Adjust to std::vector.
13735 * remote.c (remote_static_tracepoint_marker_at): Return bool.
13736 (remote_static_tracepoint_markers_by_strid): Adjust to
13737 std::vector.
13738 * common/rsp-low.h (hex2str): New overload with explicit count
13739 of bytes.
13740 * common/rsp-low.c (hex2str): New overload with explicit count
13741 of bytes.
13742 * unittests/rsp-low-selftests.c (test_hex2str): New function.
13743 (_initialize_rsp_low_selftests): Add test_hex2str test.
13744 * unittests/tracepoint-selftests.c
13745 (test_parse_static_tracepoint_marker_definition): Adjust to
13746 std::string.
13747
13748 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
13749
13750 * tracepoint.c (parse_static_tracepoint_marker_definition):
13751 Consider case where the definition is followed by more
13752 definitions.
13753 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13754 tracepoint-selftests.c.
13755 * unittests/tracepoint-selftests.c: New.
13756
13757 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
13758
13759 * MAINTAINERS (Write After Approval): Add Pedro Franco de
13760 Carvalho.
13761
13762 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
13763
13764 * symtab.c (find_pc_sect_line): fixed indentation.
13765
13766 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
13767
13768 * symtab.c (find_pc_sect_line): now uses binary search.
13769
13770 2018-03-19 Tom Tromey <tom@tromey.com>
13771
13772 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
13773 "IDENT" production.
13774
13775 2018-03-19 Pedro Alves <palves@redhat.com>
13776 Tom Tromey <tom@tromey.com>
13777
13778 * unittests/observable-selftests.c: New file.
13779 * common/observable.h: New file.
13780 * observable.h: New file.
13781 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
13782 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
13783 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
13784 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
13785 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
13786 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
13787 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
13788 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
13789 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
13790 python/py-breakpoint.c, python/py-finishbreakpoint.c,
13791 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
13792 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
13793 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
13794 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
13795 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
13796 tui/tui-interp.c, valops.c: Update all users.
13797 * tui/tui-hooks.c (tui_bp_created_observer)
13798 (tui_bp_deleted_observer, tui_bp_modified_observer)
13799 (tui_inferior_exit_observer, tui_before_prompt_observer)
13800 (tui_normal_stop_observer, tui_register_changed_observer):
13801 Remove.
13802 (tui_observers_token): New global.
13803 (attach_or_detach, tui_attach_detach_observers): New functions.
13804 (tui_install_hooks, tui_remove_hooks): Use
13805 tui_attach_detach_observers.
13806 * record-btrace.c (record_btrace_thread_observer): Remove.
13807 (record_btrace_thread_observer_token): New global.
13808 * observer.sh: Remove.
13809 * observer.c: Rename to observable.c.
13810 * observable.c (namespace gdb_observers): Define new objects.
13811 (observer_debug): Move into gdb_observers namespace.
13812 (struct observer, struct observer_list, xalloc_observer_list_node)
13813 (xfree_observer_list_node, generic_observer_attach)
13814 (generic_observer_detach, generic_observer_notify): Remove.
13815 (_initialize_observer): Update.
13816 Don't include observer.inc.
13817 * Makefile.in (generated_files): Remove observer.h, observer.inc.
13818 (clean mostlyclean): Likewise.
13819 (observer.h, observer.inc): Remove targets.
13820 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
13821 (COMMON_SFILES): Use observable.c, not observer.c.
13822 * .gitignore: Remove observer.h.
13823
13824 2018-03-18 Tom Tromey <tom@tromey.com>
13825
13826 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
13827 gdb::def_vector.
13828 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
13829
13830 2018-03-17 Tom Tromey <tom@tromey.com>
13831
13832 * auto-load.c (auto_load_objfile_script_1): Use std::string.
13833
13834 2018-03-17 Tom Tromey <tom@tromey.com>
13835
13836 * target.c (class scoped_target_fd): New.
13837 (target_fileio_close_cleanup): Remove.
13838 (target_fileio_read_alloc_1): Use scoped_target_fd.
13839
13840 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
13841
13842 * silent-rules.mk: New.
13843 * Makefile.in: Include silent-rules.mk
13844 (srcdir, VPATH, top_srcdir): Move up.
13845 (COMPILE): Add ECHO_CXX.
13846 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
13847 (init.c): Add ECHO_INIT_C.
13848 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
13849 (version.c): Add ECHO_GEN.
13850 (printcmd.o): Add ECHO_CXX.
13851 (target-float.o): Add ECHO_CXX.
13852 (ada-exp.o): Add ECHO_CXX.
13853 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
13854 (insight$(EXEEXT)): Add ECHO_CXXLD.
13855 * gnulib/configure.ac: Add AM_SILENT_RULES.
13856 * gnulib/aclocal.m4: Re-generate.
13857 * gnulib/configure: Re-generate.
13858 * gnulib/import/Makefile.in: Re-generate.
13859
13860 2018-03-16 Tom Tromey <tom@tromey.com>
13861
13862 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
13863 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
13864 * utils.c (do_free_section_addr_info)
13865 (make_cleanup_free_section_addr_info): Remove.
13866 * symfile.h (struct other_sections): Add constructor.
13867 (struct section_addr_info): Remove.
13868 (section_addr_info): New typedef.
13869 (struct sym_fns) <sym_offsets>: Change type of parameter.
13870 (build_section_addr_info_from_objfile)
13871 (relative_addr_info_to_section_offsets, addr_info_make_relative)
13872 (default_symfile_offsets, symbol_file_add)
13873 (symbol_file_add_from_bfd)
13874 (build_section_addr_info_from_section_table): Update.
13875 (alloc_section_addr_info, free_section_addr_info): Don't declare.
13876 * symfile.c (alloc_section_addr_info): Remove.
13877 (build_section_addr_info_from_section_table): Change return type.
13878 Update.
13879 (build_section_addr_info_from_bfd)
13880 (build_section_addr_info_from_objfile): Likewise.
13881 (free_section_addr_info): Remove.
13882 (relative_addr_info_to_section_offsets): Change type of "addrs".
13883 (addrs_section_compar): Now a std::sort comparator.
13884 (addrs_section_sort): Change return type.
13885 (addr_info_make_relative): Change type of "addrs". Update.
13886 (default_symfile_offsets, syms_from_objfile_1)
13887 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
13888 (symbol_file_add_separate): Update.
13889 (symbol_file_add): Change type of "addrs". Update.
13890 (add_symbol_file_command): Update. Remove cleanups.
13891 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
13892 cleanups.
13893 * symfile-debug.c (debug_sym_offsets): Change type of "info".
13894 * solib.c (solib_read_symbols): Update.
13895 * objfiles.c (objfile_relocate): Update. Remove cleanups.
13896 * machoread.c (macho_symfile_offsets): Update.
13897 * jit.c (jit_bfd_try_read_symtab): Update.
13898
13899 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
13900
13901 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13902 unittests/utils-selftests.c.
13903 * unittests/utils-selftests.c: New file.
13904
13905 2018-03-14 Tom Tromey <tom@tromey.com>
13906
13907 PR cli/14977:
13908 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
13909 for NULL.
13910
13911 2018-03-14 Tom Tromey <tom@tromey.com>
13912
13913 PR cli/19918:
13914 * printcmd.c (printf_pointer): Allow "-" in format.
13915
13916 2018-03-14 Tom Tromey <tom@tromey.com>
13917
13918 * printcmd.c (_initialize_printcmd): Add usage to printf.
13919
13920 2018-03-14 Yao Qi <qiyao@sourceware.org>
13921
13922 * MAINTAINERS: Update my email address.
13923
13924 2018-03-13 Tom Tromey <tom@tromey.com>
13925
13926 * machoread.c (macho_check_dsym): Change filenamep to a
13927 std::string*.
13928 (macho_symfile_read): Update.
13929 * symfile.c (load_command): Use std::string.
13930
13931 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
13932
13933 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
13934 to error message string.
13935 (riscv_register_name): Use xsnprintf instead of sprintf.
13936 (riscv_insn::fetch_instruction): Use gdb_assert instead of
13937 internal_error.
13938 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
13939 error.
13940 (riscv_push_dummy_call): Likewise.
13941
13942 2018-03-12 Tom Tromey <tom@tromey.com>
13943
13944 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
13945 Use gdb::byte_vector.
13946 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
13947
13948 2018-03-12 Yao Qi <yao.qi@linaro.org>
13949
13950 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
13951 parameter type to readable_regcache.
13952 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
13953 the declaration.
13954
13955 2018-03-11 Tom Tromey <tom@tromey.com>
13956
13957 * dwarf2read.c (struct nextfield): Add initializers.
13958 (struct nextfnfield): Remove.
13959 (struct fnfieldlist): Add initializers. Remove "length" and
13960 "head", use std::vector.
13961 (struct decl_field_list): Remove.
13962 (struct field_info): Add initializers.
13963 <fields, baseclasses>: Now std::vector.
13964 <nbaseclasses, nfnfields, typedef_field_list_count,
13965 nested_types_list_count>: Remove.
13966 (dwarf2_add_field, dwarf2_add_type_defn)
13967 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
13968 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
13969 (process_structure_scope): Update.
13970
13971 2018-03-11 Tom Tromey <tom@tromey.com>
13972
13973 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
13974 for use by std::sort.
13975 (build_type_psymtabs_1): Use std::vector.
13976
13977 2018-03-09 Eli Zaretskii <eliz@gnu.org>
13978
13979 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
13980 and LIBMPFR in the printed configuration.
13981
13982 2018-03-08 Tom Tromey <tom@tromey.com>
13983
13984 * source.c (get_filename_and_charpos): Use scoped_fd.
13985 * nto-procfs.c (procfs_open_1): Use scoped_fd.
13986 (procfs_pidlist): Likewise.
13987 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
13988 (iterate_over_mappings): Likewise.
13989
13990 2018-03-08 Tom Tromey <tom@tromey.com>
13991
13992 * infcall.c (struct call_return_meta_info)
13993 <stack_temporaries_enabled>: Remove.
13994 (get_call_return_value, call_function_by_hand_dummy): Update.
13995 * thread.c (disable_thread_stack_temporaries): Remove.
13996 (enable_thread_stack_temporaries): Remove.
13997 (thread_stack_temporaries_enabled_p): Return bool.
13998 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
13999 (get_last_thread_stack_temporary): Update.
14000 * eval.c (evaluate_subexp): Update.
14001 * gdbthread.h (class enable_thread_stack_temporaries): Now a
14002 class, not a function.
14003 (value_ptr, value_vec): Remove typedefs.
14004 (class thread_info) <stack_temporaries_enabled>: Now bool.
14005 <stack_temporaries>: Now a std::vector.
14006 (thread_stack_temporaries_enabled_p)
14007 (value_in_thread_stack_temporaries): Return bool.
14008
14009 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
14010
14011 * remote.c (putpkt_binary): Fix omitted bytes reporting.
14012 (getpkt_or_notif_sane_1): Likewise.
14013
14014 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
14015
14016 * build-id.c (build_id_to_debug_bfd): Use std::string.
14017
14018 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
14019
14020 * build-id.c (find_separate_debug_file_by_buildid): Return
14021 std::string.
14022 * build-id.h (find_separate_debug_file_by_buildid): Return
14023 std::string.
14024 * coffread.c (coff_symfile_read): Adjust to std::string.
14025 * elfread.c (elf_symfile_read): Adjust to std::string.
14026 * symfile.c (separate_debug_file_exists): Change parameter to
14027 std::string.
14028 (find_separate_debug_file): Return std::string.
14029 (find_separate_debug_file_by_debuglink): Return std::string.
14030 * symfile.h (find_separate_debug_file_by_debuglink): Return
14031 std::string.
14032
14033 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
14034
14035 * common/xml-utils.c (xml_escape_text): Move code to...
14036 (xml_escape_text_append): ... this new function.
14037 * common/xml-utils.h (xml_escape_text_append): New declaration.
14038 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
14039 New function.
14040 (_initialize_xml_utils): register test_xml_escape_text_append as
14041 a selftest.
14042
14043 2018-03-07 Alan Hayward <alan.hayward@arm.com>
14044
14045 * defs.h: Remove MAX_REGISTER_SIZE.
14046 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
14047 asserts.
14048 * python/py-unwind.c (pyuw_sniffer): Likewise.
14049
14050 2018-03-07 Tom Tromey <tom@tromey.com>
14051
14052 * linux-tdep.c (linux_info_proc): Update.
14053 * target.h (struct target_ops) <to_fileio_readlink>: Return
14054 optional<string>.
14055 (target_fileio_readlink): Return optional<string>.
14056 * remote.c (remote_hostio_readlink): Return optional<string>.
14057 * inf-child.c (inf_child_fileio_readlink): Return
14058 optional<string>.
14059 * target.c (target_fileio_readlink): Return optional<string>.
14060
14061 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
14062
14063 * regcache.c (cooked_read_test): Add riscv to the list of
14064 architectures that have a save_reggroup.
14065
14066 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
14067
14068 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
14069 value is not a dynamic class object.
14070
14071 2018-03-06 Tom Tromey <tom@tromey.com>
14072
14073 * rust-exp.y: Formatting fixes.
14074
14075 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14076
14077 * riscv-tdep.c (riscv_register_name): Remove target description
14078 support.
14079 (riscv_gdbarch_init): Remove target description check.
14080
14081 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14082
14083 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
14084 comment.
14085 * riscv-tdep.h: Likewise.
14086
14087 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14088
14089 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
14090 (riscv_pseudo_register_write): Delete.
14091 (riscv_gdbarch_init): Remove all use of pseudo registers.
14092
14093 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
14094
14095 * record-btrace.c (btrace_print_lines): Replace cleanup
14096 parameter with RAII equivalents.
14097 (btrace_insn_history): Replace cleanup with RAII equivalents.
14098 * ui-out.h (make_cleanup_ui_out_list_begin_end,
14099 make_cleanup_ui_out_tuple_begin_end): Remove.
14100 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
14101 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
14102 make_cleanup_ui_out_list_begin_end): Remove.
14103
14104 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
14105
14106 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
14107 parameter types to std::vector. Use bool.
14108 (record_btrace_wait): Replace VEC(tp_t) with
14109 std::vector<thread_info *>.
14110 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
14111
14112 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
14113
14114 * record-btrace.c (record_btrace_disable_callback): Remove.
14115 (struct scoped_btrace_disable): New.
14116 (record_btrace_open): Use scoped_btrace_disable.
14117
14118 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14119
14120 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
14121 reading values from registers.
14122
14123 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14124
14125 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
14126 where appropriate.
14127
14128 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14129
14130 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
14131 change parameter type. Use GDB's print functions, and use
14132 core_addr_to_string where appropriate.
14133 (riscv_push_dummy_call): Use core_addr_to_string where
14134 appropriate, update call to riscv_print_arg_location, and reindent
14135 a few lines.
14136 (riscv_return_value): Update call to riscv_print_arg_location.
14137
14138 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14139 Tim Newsome <tim@sifive.com>
14140 Albert Ou <a0u@eecs.berkeley.edu>
14141 Darius Rad <darius@bluespec.com>
14142
14143 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
14144 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
14145 (ALLDEPFILES): Add riscv-tdep.c
14146 * configure.tgt: Add riscv support.
14147 * riscv-tdep.c: New file.
14148 * riscv-tdep.h: New file.
14149 * NEWS: Mention new target.
14150 * MAINTAINERS: Add entry for riscv.
14151
14152 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14153
14154 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
14155 fields within aggregates.
14156
14157 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
14158
14159 * record-btrace.c (btrace_print_lines): Change type of flags to
14160 gdb_disassembly_flags.
14161
14162 2018-03-04 John Baldwin <jhb@FreeBSD.org>
14163
14164 * fbsd-nat.c: Include "inf-ptrace.h".
14165 (USE_SIGTRAP_SIGINFO): Conditionally define.
14166 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
14167 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
14168 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
14169 function.
14170 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
14171 Likewise.
14172 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
14173 Likewise.
14174 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
14175 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
14176 "supports_stopped_by_hw_breakpoint" target methods.
14177
14178 2018-03-04 John Baldwin <jhb@FreeBSD.org>
14179
14180 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
14181 * fbsd-nat.c (debug_fbsd_nat): New variable.
14182 (show_fbsd_nat_debug): New function.
14183 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
14184 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
14185
14186 2018-03-04 John Baldwin <jhb@FreeBSD.org>
14187
14188 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
14189 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
14190 prototype.
14191 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
14192 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
14193 method.
14194
14195 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14196
14197 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
14198 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
14199
14200 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14201
14202 * charset.c (struct charset_vector): New.
14203 (charsets): Change type to charset_vector.
14204 (find_charset_names): Adjust.
14205 (add_one): Adjust.
14206 (_initialize_charset): Adjust.
14207
14208 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14209
14210 * progspace.h (struct program_space) <deleted_solibs>: Change
14211 type to std::vector<std::string>.
14212 * progspace.c (clear_program_space_solib_cache): Adjust.
14213 * breakpoint.c (print_solib_event): Adjust.
14214 (check_status_catch_solib): Adjust.
14215 * solib.c (update_solib_list): Adjust.
14216 * ui-out.h (class ui_out) <field_string>: New overload.
14217 * ui-out.c (ui_out::field_string): New overload.
14218
14219 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14220
14221 * progspace.h (struct program_space): Add constructor and
14222 destructor, initialize fields.
14223 (add_program_space): Remove.
14224 * progspace.c (add_program_space): Rename to...
14225 (program_space::program_space): ... this.
14226 (release_program_space): Rename to...
14227 (program_space::~program_space): ... this.
14228 (delete_program_space): Use delete to delete program_space.
14229 (initialize_progspace): Use new to allocate program_space.
14230 * inferior.c (add_inferior_with_spaces): Likewise.
14231 (clone_inferior_command): Likewise.
14232 * infrun.c (follow_fork_inferior): Likewise.
14233 (handle_vfork_child_exec_or_exit): Likewise.
14234
14235 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14236
14237 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
14238 (delim_string_to_char_ptr_vec): Return std::vector of
14239 gdb::unique_xmalloc_ptr.
14240 (dirnames_to_char_ptr_vec_append): Take std::vector of
14241 gdb::unique_xmalloc_ptr.
14242 (dirnames_to_char_ptr_vec): Return std::vector of
14243 gdb::unique_xmalloc_ptr.
14244 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
14245 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
14246 (delim_string_to_char_ptr_vec): Return an std::vector of
14247 gdb::unique_xmalloc_ptr, adjust the code.
14248 (dirnames_to_char_ptr_vec_append): Take an std::vector of
14249 gdb::unique_xmalloc_ptr, adjust the code.
14250 (dirnames_to_char_ptr_vec): Return an std::vector of
14251 gdb::unique_xmalloc_ptr, adjust the code.
14252 * auto-load.c (auto_load_safe_path_vec): Change type to
14253 std::vector of gdb::unique_xmalloc_ptr.
14254 (auto_load_expand_dir_vars): Return an std::vector of
14255 gdb::unique_xmalloc_ptr, adjust the code.
14256 (auto_load_safe_path_vec_update): Adjust.
14257 (filename_is_in_auto_load_safe_path_vec): Adjust.
14258 (auto_load_objfile_script_1): Adjust.
14259 * build-id.c (build_id_to_debug_bfd): Adjust.
14260 * linux-thread-db.c (thread_db_load_search): Adjust.
14261 * source.c (add_path): Adjust.
14262 (openp): Adjust.
14263 * symfile.c (find_separate_debug_file): Adjust.
14264 * utils.c (do_free_char_ptr_vec): Remove.
14265 (make_cleanup_free_char_ptr_vec): Remove.
14266
14267 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
14268
14269 PR gdb/22907
14270 * common/pathstuff.c: Conditionally include "<windows.h>".
14271
14272 2018-03-01 Georg Sauthoff <mail@georg.so>
14273
14274 PR gdb/22888
14275 * gcore.in: Quote variables and switch interpreter to bash.
14276
14277 2018-03-01 Tom Tromey <tom@tromey.com>
14278
14279 * dwarf2read.c (alloc_discriminant_info): Fix default_index
14280 assertion. Add assertion for discriminant_index.
14281 (quirk_rust_enum): Use correct base type name in univariant case.
14282
14283 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
14284
14285 * record.c (get_call_history_modifiers): Return a
14286 record_print_flags.
14287 (cmd_record_call_history): Adjust.
14288 * record-btrace.c (record_btrace_call_history): Adjust.
14289 (record_btrace_call_history_range): Adjust.
14290 (record_btrace_call_history_from): Adjust.
14291 * target-debug.h (target_debug_print_record_print_flags): New.
14292 * target-delegates.c: Re-generate.
14293 * target.c (target_call_history): Change flags type.
14294 (target_call_history_from): Likewise.
14295 (target_call_history_range): Likewise.
14296 * target.h (struct target_ops) <target_call_history>: Likewise.
14297 (target_call_history_from): Likewise.
14298 (target_call_history_range): Likewise.
14299
14300 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
14301 Simon Marchi <simon.marchi@polymtl.ca>
14302
14303 * common/common-utils.c: Include "sys/stat.h".
14304 (is_regular_file): Move here from "source.c"; change return
14305 type to "bool".
14306 * common/common-utils.h (is_regular_file): New prototype.
14307 * common/pathstuff.c (contains_dir_separator): New function.
14308 * common/pathstuff.h (contains_dir_separator): New prototype.
14309 * source.c: Don't include "sys/stat.h".
14310 (is_regular_file): Move to "common/common-utils.c".
14311
14312 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
14313
14314 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
14315 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
14316 * auto-load.c: Include "common/pathstuff.h".
14317 * common/common-def.h (current_directory): Move here.
14318 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
14319 function.
14320 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
14321 prototype.
14322 * common/pathstuff.c: New file.
14323 * common/pathstuff.h: New file.
14324 * compile/compile.c: Include "common/pathstuff.h".
14325 * defs.h (current_directory): Move to "common/common-defs.h".
14326 * dwarf2read.c: Include "common/pathstuff.h".
14327 * exec.c: Likewise.
14328 * guile/scm-safe-call.c: Likewise.
14329 * linux-thread-db.c: Likewise.
14330 * main.c: Likewise.
14331 * nto-tdep.c: Likewise.
14332 * objfiles.c: Likewise.
14333 * source.c: Likewise.
14334 * symtab.c: Likewise.
14335 * utils.c: Include "common/pathstuff.h".
14336 (gdb_realpath): Move to "common/pathstuff.c".
14337 (gdb_realpath_keepfile): Likewise.
14338 (gdb_abspath): Likewise.
14339 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
14340 (gdb_realpath_keepfile): Likewise.
14341 (gdb_abspath): Likewise.
14342
14343 2018-02-28 John Baldwin <jhb@FreeBSD.org>
14344
14345 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
14346 wildcard process pid for super_resume for kernels with a
14347 specific bug.
14348
14349 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
14350
14351 * compile/compile.c (get_args): Add additional comments
14352 explaining function.
14353
14354 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
14355 Tom Tromey <tom@tromey.com>
14356
14357 * target.h (memory_write_request_s): Remove typedef. Don't define
14358 VEC.
14359 (target_write_memory_blocks): Change argument to std::vector.
14360 (struct memory_write_request): Add constructor.
14361 * target-memory.c (compare_block_starting_address): Return bool.
14362 Change argument types.
14363 (claim_memory): Change arguments to use std::vector.
14364 (split_regular_and_flash_blocks, blocks_to_erase)
14365 (compute_garbled_blocks): Likewise.
14366 (cleanup_request_data, cleanup_write_requests_vector): Remove.
14367 (target_write_memory_blocks): Change argument to std::vector.
14368 * symfile.c (struct load_section_data): Add constructor and
14369 destructor. Use std::vector for "requests".
14370 (struct load_progress_data): Add initializers.
14371 (load_section_callback): Update. Use "new".
14372 (clear_memory_write_data): Remove.
14373 (generic_load): Update.
14374
14375 2018-02-27 Alan Hayward <alan.hayward@arm.com>
14376
14377 * arch/aarch64.h: Use common/tdesc.h.
14378
14379 2018-02-26 Maciej W. Rozycki <macro@mips.com>
14380
14381 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
14382 architecture with a 64-bit ABI.
14383
14384 2018-02-26 Maciej W. Rozycki <macro@mips.com>
14385
14386 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
14387 ahead of target description loading.
14388
14389 2018-02-26 Tom Tromey <tom@tromey.com>
14390
14391 * stack.c (backtrace_command_1): Update.
14392 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
14393 of "flags".
14394 * python/py-framefilter.c (py_print_frame)
14395 (gdbpy_apply_frame_filter): Change type of "flags".
14396 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
14397 of "flags".
14398 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
14399 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
14400 * extension.h (enum frame_filter_flag): Rename from
14401 frame_filter_flags.
14402 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
14403 (apply_ext_lang_frame_filter): Change type of "flags".
14404 * extension.c (apply_ext_lang_frame_filter): Change type of
14405 "flags".
14406 * extension-priv.h (struct extension_language_ops)
14407 <apply_frame_filter>: Change type of "flags".
14408
14409 2018-02-26 Tom Tromey <tom@tromey.com>
14410
14411 PR python/16497:
14412 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
14413 off-by-one in py_end computation.
14414 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
14415 PRINT_MORE_FRAMES.
14416 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
14417 constant.
14418
14419 2018-02-26 Tom Tromey <tom@tromey.com>
14420
14421 * dwarf2read.c (struct variant_field): New.
14422 (struct nextfield) <variant>: New field.
14423 (dwarf2_add_field): Handle DW_TAG_variant_part.
14424 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
14425 discriminated union.
14426 (read_structure_type): Handle DW_TAG_variant_part.
14427 (handle_struct_member_die): New function, extracted from
14428 process_structure_scope. Handle DW_TAG_variant.
14429 (process_structure_scope): Handle discriminated unions. Call
14430 handle_struct_member_die.
14431
14432 2018-02-26 Tom Tromey <tom@tromey.com>
14433
14434 * rust-lang.h (rust_last_path_segment): Declare.
14435 * rust-lang.c (rust_last_path_segment): Now public. Change
14436 contract.
14437 (struct disr_info): Remove.
14438 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
14439 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
14440 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
14441 (rust_enum_p, rust_enum_variant): New function.
14442 (rust_underscore_fields): Remove "offset" parameter.
14443 (rust_print_enum): New function.
14444 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
14445 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
14446 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
14447 enums.
14448 (rust_internal_print_type): New function, from rust_print_type.
14449 Remove enum code.
14450 (rust_print_type): Call rust_internal_print_type.
14451 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
14452 Update enum handling.
14453 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
14454 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
14455 (rust_union_quirks): New functions.
14456 (process_full_comp_unit, process_full_type_unit): Call
14457 rust_union_quirks.
14458 (process_structure_scope): Update rust_unions if necessary.
14459
14460 2018-02-26 Tom Tromey <tom@tromey.com>
14461
14462 * value.h (value_union_variant): Declare.
14463 * valops.c (value_union_variant): New function.
14464 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
14465 (struct discriminant_info): New.
14466 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
14467 enumerator.
14468 (struct main_type) <flag_discriminated_union>: New field.
14469
14470 2018-02-26 Tom Tromey <tom@tromey.com>
14471
14472 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14473 unittests/unpack-selftests.c.
14474 * unittests/unpack-selftests.c: New file.
14475 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
14476
14477 2018-02-26 Yao Qi <yao.qi@linaro.org>
14478
14479 * dwarf2read.c (struct partial_die_info) <read>: New method.
14480 (read_partial_die): Remove the declaration.
14481 (load_partial_dies): Update.
14482 (partial_die_info::partial_die_info):
14483 (read_partial_die): Change it to partial_die_info::read.
14484
14485 2018-02-26 Yao Qi <yao.qi@linaro.org>
14486
14487 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
14488 (fixup_partial_die): Remove declaration.
14489 (scan_partial_symbols): Update.
14490 (partial_die_parent_scope): Likewise.
14491 (partial_die_full_name): Likewise.
14492 (fixup_partial_die): Change it to partial_die_info::fixup.
14493
14494 2018-02-26 Yao Qi <yao.qi@linaro.org>
14495
14496 * dwarf2read.c (read_partial_die): Update the declaration.
14497 (load_partial_dies): Caller update.
14498 (read_partial_die): Remove one argument abbrev_len.
14499
14500 2018-02-26 Yao Qi <yao.qi@linaro.org>
14501
14502 * dwarf2read.c (struct partial_die_info): Add ctor, delete
14503 assignment operator.
14504 (load_partial_dies): Use ctor and copy ctor.
14505 (read_partial_die): Update.
14506 (dwarf2_cu::find_partial_die): Use ctor.
14507
14508 2018-02-26 Yao Qi <yao.qi@linaro.org>
14509
14510 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
14511 (find_partial_die_in_comp_unit): Change it to
14512 dwarf2_cu::find_partial_die.
14513 (find_partial_die): Update.
14514
14515 2018-02-26 Yao Qi <yao.qi@linaro.org>
14516
14517 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
14518 is NULL.
14519
14520 2018-02-26 Yao Qi <yao.qi@linaro.org>
14521
14522 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
14523
14524 2018-02-26 Alan Hayward <alan.hayward@arm.com>
14525
14526 * arch/amd64.h: Use common/tdesc.h.
14527 * arch/i386.c: Likewise.
14528 * arch/i386.h: Likewise.
14529 * arch/tic6x.c: Likewise.
14530 * arch/tdesc.h: Move file from here...
14531 * common/tdesc.h: ...to here.
14532 * features/aarch64-core.c: Regenerate.
14533 * features/aarch64-fpu.c: Regenerate.
14534 * features/i386/32bit-avx.c: Regenerate.
14535 * features/i386/32bit-avx512.c: Regenerate.
14536 * features/i386/32bit-core.c: Regenerate.
14537 * features/i386/32bit-linux.c: Regenerate.
14538 * features/i386/32bit-mpx.c: Regenerate.
14539 * features/i386/32bit-pkeys.c: Regenerate.
14540 * features/i386/32bit-sse.c: Regenerate.
14541 * features/i386/64bit-avx.c: Regenerate.
14542 * features/i386/64bit-avx512.c: Regenerate.
14543 * features/i386/64bit-core.c: Regenerate.
14544 * features/i386/64bit-linux.c: Regenerate.
14545 * features/i386/64bit-mpx.c: Regenerate.
14546 * features/i386/64bit-pkeys.c: Regenerate.
14547 * features/i386/64bit-segments.c: Regenerate.
14548 * features/i386/64bit-sse.c: Regenerate.
14549 * features/i386/x32-core.c: Regenerate.
14550 * features/tic6x-c6xp.c: Regenerate.
14551 * features/tic6x-core.c: Regenerate.
14552 * features/tic6x-gp.c: Regenerate.
14553 * target-descriptions.c: Use common/tdesc.h.
14554 * target-descriptions.h: Likewise.
14555
14556 2018-02-24 Tom Tromey <tom@tromey.com>
14557
14558 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
14559 (try_thread_db_load_from_dir, thread_db_load_search): Use
14560 std::string.
14561 (info_auto_load_libthread_db_compare): Return bool. Change
14562 argument types.
14563 (info_auto_load_libthread_db): Use std::vector, std::string.
14564 Remove cleanups.
14565
14566 2018-02-24 Tom Tromey <tom@tromey.com>
14567
14568 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
14569 std::string.
14570 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
14571 std::string*.
14572 * gdbarch.c: Rebuild.
14573 * gdbarch.h: Rebuild.
14574 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
14575 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
14576 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
14577 std::string*.
14578
14579 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
14580
14581 * gdbtypes.h (sect_offset): Change type to uint64_t.
14582 (sect_offset_str): New function.
14583 * dwarf2read.c (create_addrmap_from_aranges): Use
14584 sect_offset_str.
14585 (error_check_comp_unit_head): Likewise.
14586 (create_debug_type_hash_table): Likewise.
14587 (read_cutu_die_from_dwo): Likewise.
14588 (init_cutu_and_read_dies): Likewise.
14589 (init_cutu_and_read_dies_no_follow): Likewise.
14590 (process_psymtab_comp_unit_reader): Likewise.
14591 (partial_die_parent_scope): Likewise.
14592 (peek_die_abbrev): Likewise.
14593 (process_queue): Likewise.
14594 (dwarf2_physname): Likewise.
14595 (read_namespace_alias): Likewise.
14596 (read_import_statement): Likewise.
14597 (create_dwo_cu_reader): Likewise.
14598 (create_cus_hash_table): Likewise.
14599 (lookup_dwo_cutu): Likewise.
14600 (inherit_abstract_dies): Likewise.
14601 (read_func_scope): Likewise.
14602 (read_call_site_scope): Likewise.
14603 (dwarf2_add_member_fn): Likewise.
14604 (read_common_block): Likewise.
14605 (read_module_type): Likewise.
14606 (read_typedef): Likewise.
14607 (read_subrange_type): Likewise.
14608 (load_partial_dies): Likewise.
14609 (read_partial_die): Likewise.
14610 (find_partial_die): Likewise.
14611 (read_str_index): Likewise.
14612 (dwarf2_string_attr): Likewise.
14613 (build_error_marker_type): Likewise.
14614 (lookup_die_type): Likewise.
14615 (dump_die_shallow): Likewise.
14616 (follow_die_ref): Likewise.
14617 (dwarf2_fetch_die_loc_sect_off): Likewise.
14618 (dwarf2_fetch_constant_bytes): Likewise.
14619 (follow_die_sig): Likewise.
14620 (get_signatured_type): Likewise.
14621 (get_DW_AT_signature_type): Likewise.
14622 (dwarf2_find_containing_comp_unit): Likewise.
14623 (set_die_type): Likewise.
14624
14625 2018-02-21 John Baldwin <jhb@FreeBSD.org>
14626
14627 * arch/aarch64.c: Include "common-defs.h".
14628 * arch/amd64.c: Likewise.
14629 * arch/i386.c: Likewise.
14630
14631 2018-02-21 Tom Tromey <tom@tromey.com>
14632
14633 * value.h: (extract_field_op): Update.
14634 * eval.c (extract_field_op): Return a const char *.
14635 * expression.h (parse_expression_for_completion): Update.
14636 * completer.c (complete_expression): Update.
14637 (add_struct_fields): Make fieldname const.
14638 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
14639 (mark_completion_tag, parse_exp_in_context_1): Update.
14640 (parse_expression_for_completion): Change "name" to
14641 unique_xmalloc_ptr*.
14642
14643 2018-02-21 Tom Tromey <tom@tromey.com>
14644
14645 * infcall.c (call_function_by_hand_dummy): Use std::vector.
14646
14647 2018-02-21 Yao Qi <yao.qi@linaro.org>
14648
14649 * avr-tdep.c (avr_read_pc): Change parameter type to
14650 readable_regcache.
14651 * gdbarch.sh (read_pc): Likewise.
14652 * gdbarch.c: Re-generated.
14653 * gdbarch.h: Re-generated.
14654 * hppa-tdep.c (hppa_read_pc): Change parameter type to
14655 readable_regcache.
14656 * ia64-tdep.c (ia64_read_pc): Likewise.
14657 * mips-tdep.c (mips_read_pc): Likewise.
14658 * spu-tdep.c (spu_read_pc): Likewise.
14659
14660 2018-02-21 Yao Qi <yao.qi@linaro.org>
14661
14662 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
14663 * regcache-dump.c: New file.
14664 * regcache.c: Move register_dump to regcache-dump.c.
14665 (maintenance_print_registers): Likewise.
14666 (maintenance_print_raw_registers): Likewise.
14667 (maintenance_print_cooked_registers): Likewise.
14668 (maintenance_print_register_groups): Likewise.
14669 (maintenance_print_remote_registers): Likewise.
14670 (_initialize_regcache): Likewise.
14671 * regcache.h (register_dump): Moved from regcache.c.
14672
14673 2018-02-21 Yao Qi <yao.qi@linaro.org>
14674
14675 * regcache.c (regcache::regcache): Update.
14676 (regcache::invalidate): Move it to detached_regcache::invalidate.
14677 (get_thread_arch_aspace_regcache): Update.
14678 (regcache::raw_update): Update.
14679 (regcache::cooked_read): Remove some code.
14680 (regcache::cooked_read_value): Likewise.
14681 (regcache::raw_write): Remove assert on m_readonly_p.
14682 (regcache::raw_supply_integer): Move it to
14683 detached_regcache::raw_supply_integer.
14684 (regcache::raw_supply_zeroed): Likewise.
14685 * regcache.h (detached_regcache) <raw_supply_integer>: New
14686 declaration.
14687 <raw_supply_zeroed, invalidate>: Likewise.
14688 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
14689 <invalidate>: Likewise.
14690 <m_readonly_p>: Removed.
14691
14692 2018-02-21 Yao Qi <yao.qi@linaro.org>
14693
14694 * infcmd.c (get_return_value): Let stop_regs point to
14695 get_current_regcache.
14696 * regcache.c (regcache::regcache): Remove.
14697 (register_dump_reg_buffer): New class.
14698 (regcache_print): Adjust.
14699 * regcache.h (regcache): Remove constructors.
14700
14701 2018-02-21 Yao Qi <yao.qi@linaro.org>
14702
14703 * regcache.c (class register_dump): New class.
14704 (register_dump_regcache, register_dump_none): New class.
14705 (register_dump_remote, register_dump_groups): New class.
14706 (regcache_print): Update.
14707 * regcache.h (regcache_dump_what): Move it to regcache.c.
14708 (regcache) <dump>: Remove.
14709
14710 2018-02-21 Yao Qi <yao.qi@linaro.org>
14711
14712 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
14713 reg_buffer_rw *.
14714 (jit_unwind_reg_set_impl): Call raw_supply.
14715 (jit_frame_sniffer): Use reg_buffer_rw.
14716 * record-full.c (record_full_core_regbuf): Change its type.
14717 (record_full_core_open_1): Use reg_buffer_rw.
14718 (record_full_close): Likewise.
14719 (record_full_core_fetch_registers): Use regcache->raw_supply.
14720 (record_full_core_store_registers): Likewise.
14721 * regcache.c (regcache::get_register_status): Move it to
14722 reg_buffer.
14723 (regcache_raw_set_cached_value): Remove.
14724 (regcache::raw_set_cached_value): Remove.
14725 (regcache::raw_write): Call raw_supply.
14726 (regcache::raw_supply): Move it to reg_buffer_rw.
14727 * regcache.h (regcache_raw_set_cached_value): Remove.
14728 (reg_buffer_rw): New class.
14729
14730 2018-02-21 Yao Qi <yao.qi@linaro.org>
14731
14732 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
14733 readonly_detached_regcache.
14734 (dummy_frame_prev_register): Use regcache->cooked_read.
14735 * frame.c (frame_save_as_regcache): Change return type.
14736 (frame_pop): Update.
14737 * frame.h (frame_save_as_regcache): Update declaration.
14738 * inferior.h (get_infcall_suspend_state_regcache): Update
14739 declaration.
14740 * infrun.c (infcall_suspend_state) <registers>: use
14741 readonly_detached_regcache.
14742 (save_infcall_suspend_state): Don't use regcache_dup.
14743 (get_infcall_suspend_state_regcache): Change return type.
14744 * linux-fork.c (struct fork_info) <savedregs>: Change to
14745 readonly_detached_regcache.
14746 <pc>: New field.
14747 (fork_save_infrun_state): Don't use regcache_dup.
14748 (info_checkpoints_command): Adjust.
14749 * mi/mi-main.c (register_changed_p): Update declaration.
14750 (mi_cmd_data_list_changed_registers): Use
14751 readonly_detached_regcache.
14752 (register_changed_p): Change parameter type to
14753 readonly_detached_regcache.
14754 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
14755 readonly_detached_regcache.
14756 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
14757 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
14758 New.
14759 (regcache::save): Move it to reg_buffer.
14760 (regcache::restore): Change parameter type.
14761 (regcache_dup): Remove.
14762 * regcache.h (reg_buffer) <save>: New method.
14763 (readonly_detached_regcache): New class.
14764 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
14765 readonly_detached_regcache.
14766 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
14767
14768 2018-02-21 Yao Qi <yao.qi@linaro.org>
14769
14770 * frame.c (frame_save_as_regcache): Use regcache method save.
14771 (frame_pop): Use regcache method restore.
14772 * infrun.c (restore_infcall_suspend_state): Likewise.
14773 * linux-fork.c (fork_load_infrun_state): Likewise.
14774 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
14775 save.
14776 * regcache.c (regcache_save): Remove.
14777 (regcache::restore): More asserts.
14778 (regcache_cpy): Remove.
14779 * regcache.h (regcache_save): Remove the declaration.
14780 (regcache::restore): Move from private to public.
14781 Remove the friend declaration of regcache_cpy.
14782 (regcache_cpy): Remove declaration.
14783
14784 2018-02-21 Yao Qi <yao.qi@linaro.org>
14785
14786 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
14787 parameter type to 'readable_regcache *'.
14788 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
14789 * arm-tdep.c (arm_neon_quad_read): Likewise.
14790 (arm_pseudo_read): Likewise.
14791 * avr-tdep.c (avr_pseudo_register_read): Likewise.
14792 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
14793 * frv-tdep.c (frv_pseudo_register_read): Likewise.
14794 * gdbarch.c: Re-generated.
14795 * gdbarch.h: Re-generated.
14796 * gdbarch.sh (pseudo_register_read): Change parameter type to
14797 'readable_regcache *'.
14798 (pseudo_register_read_value): Likewise.
14799 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
14800 (h8300_pseudo_register_read): Likewise.
14801 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
14802 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
14803 (i386_pseudo_register_read_into_value): Likewise.
14804 (i386_pseudo_register_read_value): Likewise.
14805 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
14806 declaration.
14807 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
14808 * m32c-tdep.c (m32c_raw_read): Likewise.
14809 (m32c_read_flg): Likewise.
14810 (m32c_banked_register): Likewise.
14811 (m32c_banked_read): Likewise.
14812 (m32c_sb_read): Likewise.
14813 (m32c_part_read): Likewise.
14814 (m32c_cat_read): Likewise.
14815 (m32c_r3r2r1r0_read): Likewise.
14816 (m32c_pseudo_register_read): Likewise.
14817 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
14818 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
14819 (mep_pseudo_cr64_read): Likewise.
14820 (mep_pseudo_register_read): Likewise.
14821 * mips-tdep.c (mips_pseudo_register_read): Likewise.
14822 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
14823 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
14824 * regcache.c (regcache::raw_read): Move it to readable_regcache.
14825 (regcache::cooked_read): Likewise.
14826 (regcache::cooked_read_value): Likewise.
14827 (regcache_cooked_read_signed):
14828 (regcache::cooked_read): Likewise.
14829 * regcache.h (readable_regcache): New class.
14830 (regcache): Inherit readable_regcache. Move some methods to
14831 readable_regcache.
14832 * rl78-tdep.c (rl78_pseudo_register_read): Change
14833 parameter type to 'readable_regcache *'.
14834 * rs6000-tdep.c (do_regcache_raw_read): Remove.
14835 (e500_pseudo_register_read): Change parameter type to
14836 'readable_regcache *'.
14837 (dfp_pseudo_register_read): Likewise.
14838 (vsx_pseudo_register_read): Likewise.
14839 (efpr_pseudo_register_read): Likewise.
14840 * s390-tdep.c (s390_pseudo_register_read): Likewise.
14841 * sh-tdep.c (sh_pseudo_register_read): Likewise.
14842 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
14843 (sh64_pseudo_register_read): Likewise.
14844 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
14845 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
14846 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
14847 (spu_pseudo_register_read): Likewise.
14848 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
14849 (xtensa_pseudo_register_read): Likewise.
14850
14851 2018-02-21 Yao Qi <yao.qi@linaro.org>
14852
14853 * regcache.c (regcache::regcache): Call reg_buffer ctor.
14854 (regcache::arch): Move it to reg_buffer::arch.
14855 (regcache::register_buffer): Likewise.
14856 (regcache::assert_regnum): Likewise.
14857 (regcache::num_raw_registers): Likewise.
14858 * regcache.h (reg_buffer): New class.
14859 (regcache): Inherit reg_buffer.
14860
14861 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
14862
14863 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
14864 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
14865
14866 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
14867
14868 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
14869
14870 2018-02-19 Alan Hayward <alan.hayward@arm.com>
14871
14872 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
14873 (SFILES): Remove common/*.c files.
14874 (COMMON_OBS): Remove some *.o files built from common/*.c files.
14875 * common/common.host: Add common reference.
14876 * configure.ac: Likewise.
14877 * configure: Regenerate.
14878
14879 2018-02-16 Yao Qi <yao.qi@linaro.org>
14880
14881 * block.c (block_namespace_info): Inherit allocate_on_obstack.
14882 (block_initialize_namespace): Use new.
14883 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
14884 (dwarf2_free_objfile): Use delete.
14885 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
14886 (copy_type_recursive): Use new.
14887 * gdb_obstack.h (allocate_on_obstack): New.
14888
14889 2018-02-15 Yao Qi <yao.qi@linaro.org>
14890
14891 PR gdb/22849
14892 * inferior.c (exit_inferior_1): Reset inf->control.
14893
14894 2018-02-15 Joel Brobecker <brobecker@adacore.com>
14895
14896 * ada-lang.c (ada_to_fixed_value_create): Delete advance
14897 declaration.
14898
14899 2018-02-14 Pedro Alves <palves@redhat.com>
14900
14901 * frame-unwind.c (frame_unwind_try_unwinder): Always call
14902 frame_cleanup_after_sniffer on exception.
14903
14904 2018-02-14 Tom Tromey <tom@tromey.com>
14905
14906 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
14907 const.
14908 (solib_bfd_open): Make pathname const.
14909 * solib.c (solib_bfd_open): Make pathname const.
14910 * solib-spu.c (spu_bfd_fopen): Make name const.
14911 (spu_bfd_open): Make pathname const.
14912 * solib-darwin.c (darwin_bfd_open): Make pathname const.
14913 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
14914
14915 2018-02-14 Tom Tromey <tom@tromey.com>
14916
14917 * symfile.c (symfile_bfd_open): Update.
14918 * source.h (openp, source_full_path_of, find_and_open_source):
14919 Change argument type to unique_xmalloc_ptr.
14920 * source.c (openp): Take a unique_xmalloc_ptr.
14921 (source_full_path_of, find_and_open_source): Likewise.
14922 (open_source_file, symtab_to_fullname): Update.
14923 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
14924 unique_xmalloc_ptr.
14925 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
14926 (exec_file_find): Update.
14927 * psymtab.c (psymtab_to_fullname): Update.
14928 * nto-tdep.h (nto_find_and_open_solib): Update.
14929 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
14930 unique_xmalloc_ptr.
14931 * exec.c (exec_file_attach): Update.
14932 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
14933 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
14934
14935 2018-02-14 Tom Tromey <tom@tromey.com>
14936
14937 * solib.c: Include source.h.
14938 * nto-tdep.c: Include source.h.
14939 * mi/mi-cmd-env.c: Include source.h.
14940 * infcmd.c: Include source.h.
14941 * exec.c: Include source.h.
14942 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
14943 (add_path, directory_switch, source_path, init_source_path): Move
14944 declarations...
14945 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
14946 (add_path, directory_switch, source_path, init_source_path):
14947 ...here.
14948
14949 2018-02-14 Tom Tromey <tom@tromey.com>
14950
14951 * solist.h (exec_file_find, solib_find): Return
14952 unique_xmalloc_ptr.
14953 (solib_bfd_fopen): Take a const char *.
14954 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
14955 (exec_file_find, solib_find): Likewise.
14956 (solib_bfd_fopen): Do not take ownership of "pathname".
14957 (solib_bfd_open): Use unique_xmalloc_ptr.
14958 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
14959 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
14960 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
14961 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
14962
14963 2018-02-14 Joel Brobecker <brobecker@adacore.com>
14964
14965 * ada-lang.c (name_match_type_from_name): Remove reference to
14966 ada_name_for_lookup in function's documentation.
14967 * ada-lang.h (ada_name_for_lookup): Delete declaration.
14968
14969 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
14970
14971 * defs.h (enum openp_flags): New enum.
14972 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
14973 Move to enum openp_flags.
14974 (openp_flags): New enum flags.
14975 (openp): Change parameter type to openp_flags.
14976 * source.c (openp): Change parameter type to openp_flags.
14977 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
14978 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
14979
14980 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
14981
14982 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
14983 per-command.
14984
14985 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
14986
14987 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
14988 into...
14989 (class dwarf2_queue_guard): ...the destructor of this new class.
14990 (dw2_do_instantiate_symtab): Create instance of the new class
14991 dwarf2_queue_guard, remove cleanup.
14992
14993 2018-02-09 Tom Tromey <tom@tromey.com>
14994
14995 * source.c (find_source_lines): Don't reference past the end of
14996 the vector.
14997
14998 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
14999
15000 * remote.c (remote_btrace_maybe_reopen): Change error message.
15001 * btrace.c (btrace_enable): Likewise.
15002 (parse_xml_btrace): Likewise.
15003 (parse_xml_btrace_conf): Likewise.
15004
15005 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15006
15007 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
15008 (linux_enable_pt, linux_enable_bts): Call
15009 diagnose_perf_event_open_fail.
15010
15011 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15012
15013 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
15014 Remove parameter and change return type. Update callers. Move it.
15015 (linux_enable_bts, linux_enable_pt): Improve error message.
15016 (linux_enable_pt): Remove zero buffer size check.
15017 (linux_enable_btrace): Improve error messages. Remove NULL return
15018 check.
15019
15020 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15021
15022 * btrace.c (btrace_enable): Remove target_supports_btrace call.
15023 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
15024 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
15025 (linux_supports_pt, linux_supports_btrace): Remove.
15026 (linux_enable_bts): Call cpu_supports_bts.
15027 * nat/linux-btrace.h (linux_supports_btrace): Remove.
15028 * remote.c (remote_supports_btrace): Remove.
15029 (init_remote_ops): Remove remote_supports_btrace.
15030 * target-delegates.c: Regenerated.
15031 * target.c (target_supports_btrace): Remove.
15032 * target.h (target_ops) <to_supports_btrace>: Remove
15033 (target_supports_btrace): Remove.
15034 * x86-linux-nat.c (x86_linux_create_target): Remove
15035 linux_supports_btrace.
15036
15037 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15038
15039 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
15040 btrace failed.
15041 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
15042 exception and use message in own exception.
15043
15044 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15045
15046 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
15047 (perf_event_pt_event_type): Use gdb_file_up.
15048 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
15049 scoped_fd, and scoped_mmap.
15050
15051 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15052
15053 * common/scoped_mmap.h: New.
15054 * unittests/scoped_mmap-selftest.c: New.
15055 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
15056 unittests/scoped_mmap-selftest.c.
15057
15058 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15059
15060 * common/scoped_fd.h: New.
15061 * unittests/scoped_fd-selftest.c: New.
15062 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
15063 unittests/scoped_fd-selftest.c.
15064
15065 2018-02-09 Tom Tromey <tom@tromey.com>
15066
15067 * auto-load.c (auto_load_section_scripts): Use
15068 gdb::unique_xmalloc_ptr.
15069
15070 2018-02-09 Tom Tromey <tom@tromey.com>
15071
15072 * auto-load.c (execute_script_contents): Use std::string.
15073
15074 2018-02-09 Joel Brobecker <brobecker@adacore.com>
15075
15076 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
15077 Python function, rather than a new command.
15078
15079 2018-02-08 Tom Tromey <tom@tromey.com>
15080
15081 * solib.c (solib_find_1): Use std::string.
15082 (solib_bfd_fopen): Use unique_xmalloc_ptr.
15083
15084 2018-02-08 Tom Tromey <tom@tromey.com>
15085
15086 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
15087
15088 2018-02-08 Tom Tromey <tom@tromey.com>
15089
15090 * source.c (find_source_lines): Use gdb::def_vector.
15091
15092 2018-02-08 Tom Tromey <tom@tromey.com>
15093
15094 * macrocmd.c (struct temporary_macro_definition): New.
15095 (macro_define_command): Use temporary_macro_definition. Remove
15096 cleanups.
15097 (free_macro_definition_ptr): Remove.
15098
15099 2018-02-08 Tom Tromey <tom@tromey.com>
15100
15101 * macroexp.c (maybe_expand): Use std::string.
15102
15103 2018-02-08 Tom Tromey <tom@tromey.com>
15104
15105 * macroexp.c (struct macro_buffer): Add initializers for some
15106 members.
15107 (init_buffer, init_shared_buffer, free_buffer)
15108 (free_buffer_return_text): Remove.
15109 (macro_buffer): New constructors.
15110 (~macro_buffer): New destructor.
15111 (macro_buffer::set_shared): New method.
15112 (macro_buffer::resize_buffer, macro_buffer::appendc)
15113 (macro_buffer::appendmem): Now methods, not free functions.
15114 (set_token, append_tokens_without_splicing, stringify)
15115 (macro_stringify): Update.
15116 (gather_arguments): Change return type. Remove argc_p argument,
15117 add args_ptr argument. Use std::vector.
15118 (substitute_args): Remove argc argument. Accept std::vector.
15119 (expand): Update. Use std::vector.
15120 (scan, macro_expand, macro_expand_next): Update.
15121
15122 2018-02-08 Tom Tromey <tom@tromey.com>
15123
15124 * symtab.c (default_collect_symbol_completion_matches_break_on):
15125 Use unique_xmalloc_ptr.
15126 * macroscope.h: (sal_macro_scope, user_macro_scope)
15127 (default_macro_scope): Return unique_xmalloc_ptr.
15128 * macroscope.c (sal_macro_scope, user_macro_scope)
15129 (default_macro_scope): Return unique_xmalloc_ptr.
15130 * macroexp.h (macro_expand, macro_expand_once): Return
15131 unique_xmalloc_ptr.
15132 * macroexp.c (macro_expand, macro_expand_once): Return
15133 unique_xmalloc_ptr.
15134 * macrocmd.c (macro_expand_command, macro_expand_once_command)
15135 (info_macro_command, info_macros_command): Use
15136 unique_xmalloc_ptr.
15137 * compile/compile-c-support.c (write_macro_definitions): Use
15138 unique_xmalloc_ptr.
15139 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
15140
15141 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
15142
15143 * value.c (value_static_field): Assign field type instead of
15144 containing type when returning an optimized out value.
15145
15146 2018-02-06 Yao Qi <yao.qi@linaro.org>
15147
15148 * ft32-tdep.c (ft32_read_pc): Remove.
15149 (ft32_write_pc): Remove.
15150 (ft32_gdbarch_init): Update.
15151 * m32r-tdep.c (m32r_read_pc): Remove.
15152 (m32r_gdbarch_init): Update.
15153 * mep-tdep.c (mep_read_pc): Remove.
15154 (mep_gdbarch_init): Update.
15155 * microblaze-tdep.c (microblaze_write_pc): Remove.
15156 (microblaze_gdbarch_init): Update.
15157 * mn10300-tdep.c (mn10300_read_pc): Remove.
15158 (mn10300_write_pc): Remove.
15159 (mn10300_gdbarch_init): Update.
15160 * moxie-tdep.c (moxie_read_pc): Remove.
15161 (moxie_write_pc): Remove.
15162 (moxie_gdbarch_init): Update.
15163
15164 2018-02-06 Yao Qi <yao.qi@linaro.org>
15165
15166 * expprint.c (print_subexp_standard): Handle
15167 OP_F77_UNDETERMINED_ARGLIST.
15168 (dump_subexp_body_standard): Likewise.
15169
15170 2018-02-05 Alan Hayward <alan.hayward@arm.com>
15171
15172 * target-descriptions.c (tdesc_element_visitor) Add empty
15173 implementations.
15174 (tdesc_type): Move make_gdb_type from here.
15175 (tdesc_type_builtin): Likewise.
15176 (tdesc_type_vector): Likewise.
15177 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
15178 (make_gdb_type_struct): Move from tdesc_type_with_fields.
15179 (make_gdb_type_union): Likewise.
15180 (make_gdb_type_flags): Likewise.
15181 (make_gdb_type_enum): Likewise.
15182 (make_gdb_type): New function.
15183 (tdesc_register_type): Use static make_gdb_type.
15184
15185 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
15186
15187 * infcmd.c (default_print_one_register_info): Align natural-format
15188 column values consistently one under another.
15189 (pad_to_column): New function.
15190
15191 2018-02-05 Joel Brobecker <brobecker@adacore.com>
15192
15193 * dwarf2read.c (dwarf2_physname): Move commment.
15194
15195 2018-02-01 Leszek Swirski <leszeks@google.com>
15196
15197 * varobj.c (varobj_formatted_print_options): Allow recursive
15198 pretty printing if pretty printing is enabled.
15199
15200 2018-02-01 Leszek Swirski <leszeks@google.com>
15201
15202 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
15203 names after a structop as a filename.
15204
15205 2018-02-01 Yao Qi <yao.qi@linaro.org>
15206
15207 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
15208 (arm_record_coproc_data_proc): Likewise.
15209
15210 2018-02-01 Yao Qi <yao.qi@linaro.org>
15211
15212 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
15213
15214 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
15215
15216 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
15217 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
15218
15219 2018-01-31 Pedro Alves <palves@redhat.com>
15220
15221 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
15222 * inflow.c (child_terminal_save_inferior): Wrap reference to
15223 tcgetpgrp in HAVE_TERMIOS_H.
15224 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
15225 _WIN32.
15226 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
15227 always iterate over all inferiors.
15228 (gdbsim_cntrl_c): Adjust.
15229 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
15230
15231 2018-01-31 Joel Brobecker <brobecker@adacore.com>
15232
15233 * gdbtypes.c (lookup_array_range_type): Make sure the array's
15234 index type is objfile-owned if the element type is as well.
15235
15236 2018-01-31 Joel Brobecker <brobecker@adacore.com>
15237
15238 GDB 8.1 released.
15239
15240 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
15241
15242 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
15243 "features/s390x-linux64.c".
15244 (_initialize_s390_linux_tdep): Remove initialization of tdescs
15245 s390_linux32 and s390x_linux64.
15246 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
15247 default tdesc.
15248 * s390-tdep.c: Include "features/s390-linux32.c" and
15249 "features/s390x-linux64.c".
15250 (s390_tdesc_valid): Add check for tdesc_has_registers.
15251 (s390_gdbarch_init): Make sure there is always a valid tdesc.
15252 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
15253 tdesc_s390x_linux64.
15254 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
15255 tdesc_s390x_linux64 to...
15256 * s390-tdep.h: ...here.
15257
15258 2018-01-30 Pedro Alves <palves@redhat.com>
15259
15260 PR gdb/13211
15261 * config.in, configure: Regenerate.
15262 * configure.ac: Check for getpgid.
15263 * go32-nat.c (go32_pass_ctrlc): New.
15264 (go32_target): Install it.
15265 * inf-child.c (inf_child_target): Install
15266 child_terminal_save_inferior, child_pass_ctrlc and
15267 child_interrupt.
15268 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
15269 (inf_ptrace_target): No longer install it.
15270 * infcmd.c (interrupt_target_1): Adjust.
15271 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
15272 (child_interrupt): Declare.
15273 (inferior::terminal_state): New.
15274 * inflow.c (struct terminal_info): Update comments.
15275 (inferior_process_group): Delete.
15276 (terminal_is_ours): Delete.
15277 (gdb_tty_state): New.
15278 (child_terminal_init): Adjust.
15279 (is_gdb_terminal, sharing_input_terminal_1)
15280 (sharing_input_terminal): New functions.
15281 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
15282 Set the process's actual process group in the foreground if
15283 possible. Handle is_ours_for_output/is_ours distinction. Don't
15284 mark terminal as the inferior's if not sharing GDB's terminal.
15285 Don't check attach_flag.
15286 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
15287 pass down a target_terminal_state.
15288 (child_terminal_save_inferior): New, factored out from ...
15289 (child_terminal_ours_1): ... this. Handle
15290 target_terminal_state::is_ours_for_output.
15291 (child_interrupt, child_pass_ctrlc): New.
15292 (inflow_inferior_exit): Clear the inferior's terminal_state.
15293 (copy_terminal_info): Copy the inferior's terminal state.
15294 (_initialize_inflow): Remove reference to terminal_is_ours.
15295 * inflow.h (inferior_process_group): Delete.
15296 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
15297 * procfs.c (procfs_target): Don't install procfs_interrupt.
15298 (procfs_interrupt): Delete.
15299 * remote.c (remote_serial_quit_handler): Adjust.
15300 (remote_interrupt): Remove ptid parameter. Adjust.
15301 * target-delegates.c: Regenerate.
15302 * target.c: Include "terminal.h".
15303 (target_terminal::terminal_state): Rename to ...
15304 (target_terminal::m_terminal_state): ... this.
15305 (target_terminal::init): Adjust.
15306 (target_terminal::inferior): Adjust to per-inferior
15307 terminal_state.
15308 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
15309 (target_terminal::ours, target_terminal::ours_for_output): Use
15310 target_terminal_is_ours_kind.
15311 (target_interrupt): Remove ptid parameter. Adjust.
15312 (default_target_pass_ctrlc): Adjust.
15313 * target.h (target_ops::to_terminal_save_inferior): New field.
15314 (target_ops::to_interrupt): Remove ptid_t parameter.
15315 (target_interrupt): Remove ptid_t parameter. Update comment.
15316 (target_pass_ctrlc): Update comment.
15317 * target/target.h (target_terminal_state): New scoped enum,
15318 factored out of ...
15319 (target_terminal::terminal_state): ... here.
15320 (target_terminal::inferior): Update comments.
15321 (target_terminal::restore_inferior): New.
15322 (target_terminal::is_inferior, target_terminal::is_ours)
15323 (target_terminal::is_ours_for_output): Adjust.
15324 (target_terminal::scoped_restore_terminal_state): Adjust to
15325 rename, and call restore_inferior() instead of inferior().
15326 (target_terminal::scoped_restore_terminal_state::m_state): Change
15327 type.
15328 (target_terminal::terminal_state): Rename to ...
15329 (target_terminal::m_terminal_state): ... this and change type.
15330
15331 2018-01-30 Pedro Alves <palves@redhat.com>
15332
15333 * linux-nat.c (wait_for_signal): New function.
15334 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
15335 directly.
15336 (async_terminal_is_ours)
15337 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
15338 (linux_nat_add_target): Don't override
15339 to_terminal_inferior/to_terminal_ours.
15340
15341 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
15342
15343 * remote.c (remote_follow_fork): Don't call "detach_inferior".
15344
15345 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
15346
15347 * dwarf2read.c (free_dwo_files): Add forward-declaration.
15348 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
15349 dwarf2_per_objfile_free here.
15350 (dwarf2_per_objfile_free): Remove.
15351 (_initialize_dwarf2_read): Don't register
15352 dwarf2_per_objfile_free as a registry cleanup.
15353
15354 2018-01-27 Eli Zaretskii <eliz@gnu.org>
15355
15356 Avoid compilation errors in MinGW native builds
15357
15358 The error is triggered by including python-internal.h, and the
15359 error message is:
15360
15361 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
15362 from build-gnulib/import/math.h:27,
15363 from d:/usr/Python26/include/pyport.h:235,
15364 from d:/usr/Python26/include/Python.h:58,
15365 from python/python-internal.h:94,
15366 from python/py-arch.c:24:
15367 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
15368 using ::hypot;
15369 ^~~~~
15370
15371 This happens because Python headers define 'hypot' to expand t
15372 '_hypot' in the Windows builds.
15373 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
15374 'hypoth'. This avoids a compilation error.
15375
15376 2018-01-26 Alan Hayward <alan.hayward@arm.com>
15377
15378 * MAINTAINERS (Write After Approval): Fix ordering.
15379
15380 2018-01-26 Alan Hayward <alan.hayward@arm.com>
15381
15382 * MAINTAINERS (Write After Approval): Add Alan Hayward.
15383
15384 2018-01-26 Alan Modra <amodra@gmail.com>
15385
15386 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
15387 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
15388 Remove nop. Make const. Comment.
15389 (powerpc32_plt_stub_so_2): New.
15390 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
15391 Correct count. Update uses.
15392 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
15393 Move common code reading PLT entry word. Correct
15394 powerpc32_plt_stub PLT address calculation.
15395 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
15396 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
15397 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
15398 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
15399 (ppc64_standard_linkage8): Likewise.
15400 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
15401 Correct insns description.
15402 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
15403
15404 2018-01-24 Pedro Alves <palves@redhat.com>
15405
15406 GCC PR libstdc++/83906
15407 * gdbtypes.c (operator==(const dynamic_prop &,
15408 const dynamic_prop &)): New.
15409 (operator==(const range_bounds &, const range_bounds &)): New.
15410 (check_types_equal): Use them instead of memcmp.
15411 * gdbtypes.h (operator==(const dynamic_prop &,
15412 const dynamic_prop &)): Declare.
15413 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
15414 (operator==(const range_bounds &, const range_bounds &)): Declare.
15415 (operator!=(const range_bounds &, const range_bounds &)): Declare.
15416
15417 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15418
15419 * s390-linux-tdep.c (s390_record_address_mask)
15420 (s390_record_calc_disp_common, s390_record_calc_disp)
15421 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
15422 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
15423 (s390_process_record): Move to s390-tdep.c.
15424 (s390_linux_init_abi_any): Adjust.
15425 * s390-tdep.c (s390_record_address_mask)
15426 (s390_record_calc_disp_common, s390_record_calc_disp)
15427 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
15428 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
15429 (s390_process_record): Moved from s390-linux-tdep.c
15430 (s390_gdbarch_init): Adjust.
15431
15432 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15433
15434 * s390-linux-nat.c (s390-tdep.h): New include.
15435 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
15436 (HFILES_NO_SRCDIR): Add s390-tdep.h.
15437 (ALLDEPFILES): Add s390-tdep.c.
15438 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
15439 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
15440 * s390-tdep.h: ...this. New file.
15441 * s390-linux-tdep.c (s390-tdep.h): New include.
15442 (_initialize_s390_tdep): Rename to...
15443 (_initialize_s390_linux_tdep): ...this and adjust.
15444 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
15445 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
15446 s390-tdep.h.
15447 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
15448 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
15449 (s390_is_partial_instruction, s390_software_single_step)
15450 (is_non_branch_ril, s390_displaced_step_copy_insn)
15451 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
15452 (s390_prologue_data, s390_addr, s390_store, s390_load)
15453 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
15454 (s390_register_call_saved, s390_guess_tracepoint_registers)
15455 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
15456 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
15457 (s390_pseudo_register_name, s390_pseudo_register_type)
15458 (s390_pseudo_register_read, s390_pseudo_register_write)
15459 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
15460 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
15461 (s390_addr_bits_remove, s390_address_class_type_flags)
15462 (s390_address_class_type_flags_to_name)
15463 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
15464 (s390_function_arg_float, s390_function_arg_vector)
15465 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
15466 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
15467 (s390_frame_align, s390_register_return_value, s390_return_value)
15468 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
15469 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
15470 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
15471 (s390_trad_frame_prev_register, s390_unwind_cache)
15472 (s390_prologue_frame_unwind_cache)
15473 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
15474 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
15475 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
15476 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
15477 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
15478 (s390_frame_base_address, s390_local_base_address)
15479 (s390_frame_base, s390_gcc_target_options)
15480 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
15481 (s390_validate_reg_range, s390_tdesc_valid)
15482 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
15483 * s390-tdep.c: ...this. New file.
15484
15485 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15486
15487 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
15488 (s390_process_record, s390_gdbarch_tdep_alloc)
15489 (s390_linux_init_abi_any): Use/set new hook.
15490
15491 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15492
15493 * s390-linux-tdep.c (osabi.h): New include.
15494 (s390_linux_init_abi_31, s390_linux_init_abi_64)
15495 (s390_linux_init_abi_any): New functions.
15496 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
15497
15498 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15499
15500 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
15501 tdesc_has_registers check
15502
15503 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15504
15505 * s390-linux-tdep.c (s390_tdesc_valid): New function.
15506 (s390_validate_reg_range): New macro.
15507 (s390_gdbarch_init): Adjust.
15508
15509 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15510
15511 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
15512 (s390_gdbarch_tdep_alloc): Adjust.
15513 (s390_gdbarch_init): Adjust.
15514
15515 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15516
15517 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
15518 <have_tdb>: Change type to bool.
15519 (s390_gdbarch_tdep_alloc): Adjust.
15520 (s390_gdbarch_init): Adjust.
15521
15522 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15523
15524 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
15525 (gdbarch_tdep) <have_upper, have_vx>: New fields.
15526 (s390_gdbarch_tdep_alloc): New function.
15527 (s390_gdbarch_init): Allocate tdep at start and use its fields
15528 instead of separate variables.
15529
15530 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15531
15532 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
15533 when looking for cached gdbarch and add comment for remaining.
15534
15535 2018-01-22 Pedro Alves <palves@redhat.com>
15536 Sergio Durigan Junior <sergiodj@redhat.com>
15537
15538 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
15539 case.
15540
15541 2018-01-22 Maciej W. Rozycki <macro@mips.com>
15542
15543 * MAINTAINERS: Update my company e-mail address.
15544
15545 2018-01-22 Yao Qi <yao.qi@linaro.org>
15546
15547 * regcache.c (cooked_write_test): New function.
15548 (_initialize_regcache): Register the test.
15549
15550 2018-01-22 Yao Qi <yao.qi@linaro.org>
15551
15552 * ia64-tdep.c (ia64_pseudo_register_read): Call
15553 regcache->cooked_read instead of regcache_cooked_read_unsigned.
15554 * m32c-tdep.c (m32c_cat_read): Likewise.
15555 (m32c_r3r2r1r0_read): Likewise.
15556 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
15557 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
15558
15559 2018-01-22 Yao Qi <yao.qi@linaro.org>
15560
15561 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
15562 method raw_read instead of regcache_raw_read.
15563 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
15564 * arm-tdep.c (arm_neon_quad_read): Likewise.
15565 * avr-tdep.c (avr_pseudo_register_read): Likewise.
15566 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
15567 * frv-tdep.c (frv_pseudo_register_read): Likewise.
15568 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
15569 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
15570 (i386_pseudo_register_read_into_value): Likewise.
15571 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
15572 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
15573 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
15574 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
15575 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
15576 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
15577 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
15578 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
15579 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
15580
15581 2018-01-22 Yao Qi <yao.qi@linaro.org>
15582
15583 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
15584 * configure.tgt: Remove target mt.
15585 * mt-tdep.c: Remove.
15586 * regcache.c (cooked_read_test): Remove the check for mt.
15587
15588 2018-01-22 Yao Qi <yao.qi@linaro.org>
15589
15590 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
15591 instead of gdbarch_pseudo_register_read_value.
15592
15593 2018-01-22 Joel Brobecker <brobecker@adacore.com>
15594
15595 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
15596 language is Ada.
15597
15598 2018-01-22 Joel Brobecker <brobecker@adacore.com>
15599
15600 * linespec.c (create_sals_line_offset): Remove code that preserved
15601 the symtab_and_line's line number.
15602
15603 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15604
15605 * varobj.c (varobj_create): Don't set valid_block when creating a
15606 floating varobj.
15607
15608 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15609
15610 * varobj.c (varobj_create): Remove out of date comment.
15611
15612 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15613
15614 PR mi/20395
15615 * ada-exp.y (write_var_from_sym): Pass extra parameter when
15616 updating innermost block.
15617 * parse.c (innermost_block_tracker::update): Take extra type
15618 parameter, and check types match before updating innermost block.
15619 (write_dollar_variable): Update innermost block for registers.
15620 * parser-defs.h (enum innermost_block_tracker_type): New enum.
15621 (innermost_block_tracker::innermost_block_tracker): Initialise
15622 m_types member.
15623 (innermost_block_tracker::reset): Take type parameter.
15624 (innermost_block_tracker::update): Take type parameter, and pass
15625 type through as needed.
15626 (innermost_block_tracker::m_types): New member.
15627 * varobj.c (varobj_create): Pass type when reseting innermost
15628 block.
15629
15630 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15631
15632 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
15633 * ada-lang.c (resolve_subexp): Likewise.
15634 * breakpoint.c (set_breakpoint_condition) Likewise.
15635 (watch_command_1) Likewise.
15636 * c-exp.y (variable): Likewise.
15637 * d-exp.y (PrimaryExpression): Likewise.
15638 * f-exp.y (variable): Likewise.
15639 * go-exp.y (variable): Likewise.
15640 * m2-exp.y (variable): Likewise.
15641 * objfiles.c (objfile::~objfile): Likewise.
15642 * p-exp.y (variable): Likewise.
15643 * parse.c (innermost_block): Change type.
15644 * parser-defs.h (class innermost_block_tracker): New.
15645 (innermost_block): Change to innermost_block_tracker.
15646 * printcmd.c (display_command): Switch to innermost_block API.
15647 (do_one_display): Likewise.
15648 * rust-exp.y (do_one_display): Likewise.
15649 * symfile.c (clear_symtab_users): Likewise.
15650 * varobj.c (varobj_create): Switch to innermost_block API, replace
15651 use of innermost_block with block stored on varobj object.
15652
15653 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15654
15655 * expression.h (innermost_block): Remove declaration.
15656 * varobj.c: Add 'parser-defs.h' include.
15657
15658 2018-01-19 Tom Tromey <tom@tromey.com>
15659
15660 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
15661 symbols in the static and global blocks.
15662
15663 2018-01-19 James Clarke <jrtc27@jrtc27.com>
15664
15665 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
15666 gdb_ptrace.h, and move including gdb_wait.h ...
15667 * nat/linux-ptrace.h: ... to here.
15668
15669 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
15670
15671 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
15672 inf_ptrace_detach_success.
15673 (inf_ptrace_detach_success): Add inferior parameter, use it
15674 instead of inferior_ptid, pass it to detach_inferior.
15675 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
15676 parameter.
15677 * inferior.c (detach_inferior): Add overload that takes an
15678 inferior object.
15679 * inferior.h (detach_inferior): Likewise.
15680 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
15681 use inferior_ptid, adjust call to inf_ptrace_detach_success.
15682 * linux-thread-db.c (thread_db_detach): Use inf parameter.
15683
15684 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
15685
15686 * target.h (struct target_ops) <to_detach>: Add inferior
15687 parameter.
15688 (target_detach): Likewise.
15689 * target.c (dispose_inferior): Pass inferior down.
15690 (target_detach): Pass inferior down. Assert that it is equal to
15691 the current inferior.
15692 * aix-thread.c (aix_thread_detach): Pass inferior down.
15693 * corefile.c (core_file_command): Pass current_inferior() down.
15694 * corelow.c (core_detach): Add inferior parameter.
15695 * darwin-nat.c (darwin_detach): Likewise.
15696 * gnu-nat.c (gnu_detach): Likewise.
15697 * inf-ptrace.c (inf_ptrace_detach): Likewise.
15698 * infcmd.c (detach_command): Pass current_inferior() down to
15699 target_detach.
15700 * infrun.c (follow_fork_inferior): Pass parent_inf to
15701 target_detach.
15702 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
15703 target_detach.
15704 * linux-nat.c (linux_nat_detach): Add inferior parameter.
15705 * linux-thread-db.c (thread_db_detach): Likewise.
15706 * nto-procfs.c (procfs_detach): Likewise.
15707 * procfs.c (procfs_detach): Likewise.
15708 * record.c (record_detach): Likewise.
15709 * record.h (struct inferior): Forward-declare.
15710 (record_detach): Add inferior parameter.
15711 * remote-sim.c (gdbsim_detach): Likewise.
15712 * remote.c (remote_detach_1): Likewise.
15713 (remote_detach): Likewise.
15714 (extended_remote_detach): Likewise.
15715 * sol-thread.c (sol_thread_detach): Likewise.
15716 * target-debug.h (target_debug_print_inferior_p): New macro.
15717 * target-delegates.c: Re-generate.
15718 * top.c (kill_or_detach): Pass inferior down to target_detach.
15719 * windows-nat.c (windows_detach): Add inferior parameter.
15720
15721 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
15722
15723 * target.h (struct target_ops) <to_detach>: Remove args
15724 parameter.
15725 (target_detach): Likewise.
15726 * target.c (dispose_inferior): Adjust.
15727 (target_detach): Remove args parameter, adjust.
15728 * aix-thread.c (aix_thread_detach): Adjust.
15729 * corefile.c (core_file_command): Adjust.
15730 * corelow.c (core_detach): Adjust.
15731 * darwin-nat.c (darwin_detach): Adjust.
15732 * gnu-nat.c (gnu_detach): Adjust.
15733 * inf-ptrace.c (inf_ptrace_detach): Adjust.
15734 * infcmd.c (detach_command): Adjust
15735 * infrun.c (follow_fork_inferior): Adjust.
15736 (handle_vfork_child_exec_or_exit): Adjust.
15737 * linux-fork.c (linux_fork_detach): Remove args parameter.
15738 * linux-fork.h (linux_fork_detach): Likewise.
15739 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
15740 * linux-thread-db.c (thread_db_detach): Likewise.
15741 * nto-procfs.c (procfs_detach): Likewise.
15742 * procfs.c (procfs_detach): Likewise.
15743 (do_detach): Remove signo parameter.
15744 * record.c (record_detach): Remove args parameter.
15745 * record.h (record_detach): Likewise.
15746 * remote-sim.c (gdbsim_detach): Likewise.
15747 * remote.c (remote_detach_1): Likewise.
15748 (remote_detach): Likewise.
15749 (extended_remote_detach): Likewise.
15750 * sol-thread.c (sol_thread_detach): Likewise.
15751 * target-delegates.c: Re-generate.
15752 * top.c (struct qt_args) <args>: Remove field.
15753 (kill_or_detach): Don't pass args.
15754 (quit_force): Don't set args.
15755 * windows-nat.c (windows_detach): Remove args parameter.
15756
15757 2018-01-19 Yao Qi <yao.qi@linaro.org>
15758
15759 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
15760 (arm_linux_init_abi): Install it.
15761
15762 2018-01-19 Yao Qi <yao.qi@linaro.org>
15763
15764 * osabi.c (gdb_osabi_names): Extend the regexp for
15765 arm-linux-gnueabihf.
15766
15767 2018-01-18 Yao Qi <yao.qi@linaro.org>
15768
15769 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
15770 m_abbrevs.
15771 (abbrev_table::add_abbrev): Update.
15772 (abbrev_table::lookup_abbrev): Update.
15773
15774 2018-01-18 Yao Qi <yao.qi@linaro.org>
15775
15776 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
15777
15778 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
15779
15780 * compile/compile.c (compile_to_object): Convert "triplet_rx"
15781 to "std::string".
15782
15783 2018-01-17 Tom Tromey <tom@tromey.com>
15784
15785 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
15786
15787 2018-01-17 Tom Tromey <tom@tromey.com>
15788
15789 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
15790 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
15791 (create_array_type_with_stride): Update.
15792 * dwarf2read.c (set_die_type): Update.
15793
15794 2018-01-17 Tom Tromey <tom@tromey.com>
15795
15796 * dwarf2read.c (delayed_method_info): Remove typedef.
15797 (dwarf2_cu::method_info): Now a std::vector.
15798 (add_to_method_list): Update.
15799 (free_delayed_list): Remove.
15800 (compute_delayed_physnames): Update.
15801 (process_full_comp_unit, process_full_type_unit): Clear the method
15802 list. Remove cleanups.
15803 (psymtab_include_file_name): Add name_holder parameter. Use
15804 unique_xmalloc_ptr.
15805 (dwarf_decode_lines): Update.
15806
15807 2018-01-17 Tom Tromey <tom@tromey.com>
15808 Simon Marchi <simon.marchi@ericsson.com>
15809
15810 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
15811 (dwarf2_per_objfile::free_cached_comp_units)
15812 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
15813 (init_cutu_and_read_dies_no_follow): Update.
15814 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
15815 (dwarf2_cu::~dwarf2_cu): New.
15816 (free_heap_comp_unit, free_stack_comp_unit): Remove.
15817 (age_cached_comp_units, free_one_cached_comp_unit): Update.
15818
15819 2018-01-17 Tom Tromey <tom@tromey.com>
15820 Simon Marchi <simon.marchi@ericsson.com>
15821
15822 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
15823 (struct die_reader_specs) <abbrev_table>: New member.
15824 (struct abbrev_table): Add constructor.
15825 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
15826 <abbrev_obstack>: Now an auto_obstack.
15827 (abbrev_table_up): New typedef.
15828 (init_cu_die_reader): Add abbrev_table parameter.
15829 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
15830 Add result_dwo_abbrev_table.
15831 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
15832 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
15833 Update.
15834 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
15835 parameter.
15836 (skip_children): Update.
15837 (abbrev_table::alloc_abbrev): Rename from
15838 abbrev_table_alloc_abbrev.
15839 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
15840 (abbrev_table::lookup_abbrev): Rename from
15841 abbrev_table_lookup_abbrev.
15842 (abbrev_table_read_table): Return abbrev_table_up.
15843 (abbrev_table_free, abbrev_table_free_cleanup)
15844 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
15845 (load_partial_dies): Update.
15846
15847 2018-01-17 Tom Tromey <tom@tromey.com>
15848
15849 * dwarf2read.c (dwarf2_compute_name): Update comment.
15850 (read_func_scope, read_variable): Update.
15851 (new_symbol): Remove.
15852 (new_symbol_full): Rename to new_symbol.
15853
15854 2018-01-17 Mike Gulick <mgulick@mathworks.com>
15855
15856 PR gdb/16577
15857 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
15858 a warning instead of throwing an error, set section size to 0 and return
15859 NULL.
15860 * gdb_bfd.h (gdb_bfd_map_section): Update description.
15861
15862 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
15863
15864 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
15865 std::string.
15866 (linux_ptrace_attach_fail_reason_string): Likewise.
15867 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
15868 Likewise.
15869 (linux_ptrace_attach_fail_reason_string): Likewise.
15870 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
15871
15872 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
15873
15874 * linux-nat.c (linux_nat_attach): Remove xstrdup.
15875
15876 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
15877
15878 PR gdb/21559
15879 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
15880 checking for fs_base/gs_base fields in struct user_regs_struct.
15881 * configure: Regenerate.
15882
15883 2018-01-17 Yao Qi <yao.qi@linaro.org>
15884
15885 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
15886 function.
15887 (aarch64_linux_init_abi): Install it to gdbarch hook
15888 gcc_target_options.
15889
15890 2018-01-15 Pedro Alves <palves@redhat.com>
15891
15892 * common/signals-state-save-restore.c
15893 (save_original_signals_state): Fix typos.
15894
15895 2017-01-12 Tom Tromey <tom@tromey.com>
15896 Sergio Durigan Junior <sergiodj@redhat.com>
15897
15898 * Makefile.in (install-only): Install gdb-add-index.
15899
15900 2018-01-12 John Baldwin <jhb@FreeBSD.org>
15901
15902 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
15903
15904 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
15905
15906 * infrun.c (keep_going_pass_signal): Clear step-over info when
15907 insert_breakpoints fails.
15908
15909 2018-01-11 Pedro Alves <palves@redhat.com>
15910
15911 PR gdb/22583
15912 * infrun.c (resume): Rename to ...
15913 (resume_1): ... this.
15914 (resume): Reimplement as wrapper around resume_1.
15915
15916 2018-01-11 Pedro Alves <palves@redhat.com>
15917
15918 PR remote/22597
15919 * remote.c (remote_parse_stop_reply): Default to the last-set
15920 general thread instead of to 'magic_null_ptid'.
15921
15922 2018-01-10 Pedro Alves <palves@redhat.com>
15923
15924 * language.h (language_get_symbol_name_matcher): Rename ...
15925 (get_symbol_name_matcher): ... this.
15926 * language.c (language_get_symbol_name_matcher): Ditto.
15927 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
15928 callers adjusted.
15929
15930 2018-01-10 Pedro Alves <palves@redhat.com>
15931
15932 PR gdb/22670
15933 * dwarf2read.c
15934 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
15935 Adjust to use language_get_symbol_name_matcher instead of
15936 language_defn::la_get_symbol_name_matcher.
15937 * language.c (language_get_symbol_name_matcher): If in Ada mode
15938 and the lookup name is a verbatim match, return Ada's matcher.
15939 * language.h (language_get_symbol_name_matcher): Adjust comment.
15940 (ada_lookup_name_info::verbatim_p):: New method.
15941
15942 2018-01-10 Pedro Alves <palves@redhat.com>
15943
15944 PR gdb/22670
15945 * ada-lang.c (ada_collect_symbol_completion_matches): If the
15946 minsym's language is language_auto or language_cplus, pass down
15947 language_ada instead.
15948 * symtab.c (compare_symbol_name): Don't frob symbol language here.
15949
15950 2018-01-10 Pedro Alves <palves@redhat.com>
15951
15952 PR gdb/22670
15953 * minsyms.c (linkage_name_str): New function.
15954 (iterate_over_minimal_symbols): Use it.
15955
15956 2018-01-09 John Baldwin <jhb@FreeBSD.org>
15957
15958 * NEWS: Document that 'info proc' now works on FreeBSD.
15959
15960 2018-01-09 John Baldwin <jhb@FreeBSD.org>
15961
15962 * configure.ac: Check for kinfo_getfile in libutil.
15963 * configure: Regenerate.
15964 * config.in: Regenerate.
15965 * fbsd-nat.c: Include "fbsd-tdep.h".
15966 (fbsd_fetch_cmdline): New.
15967 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
15968 rather than calling error.
15969 (fbsd_info_proc): New.
15970 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
15971 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
15972 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
15973
15974 2018-01-09 John Baldwin <jhb@FreeBSD.org>
15975
15976 * fbsd-nat.c (struct free_deleter): Remove.
15977 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
15978
15979 2018-01-09 John Baldwin <jhb@FreeBSD.org>
15980
15981 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
15982 NULL for an empty pathname.
15983
15984 2018-01-09 John Baldwin <jhb@FreeBSD.org>
15985
15986 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
15987 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
15988 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
15989 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
15990 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
15991 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
15992 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
15993 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
15994 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
15995 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
15996 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
15997 (fbsd_core_fetch_timeval, fbsd_print_sigset)
15998 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
15999 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
16000 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
16001
16002 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
16003
16004 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
16005 (gnu_xfer_auxv): New function.
16006 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
16007 TARGET_OBJECT_AUXV.
16008
16009 2018-01-08 Yao Qi <yao.qi@linaro.org>
16010 Simon Marchi <simon.marchi@ericsson.com>
16011
16012 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
16013 common/selftest.c.
16014 (COMMON_OBS): Remove selftest.o.
16015 * configure.ac: Append selftest-arch.c and common/selftest.c to
16016 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
16017 * configure: Re-generated.
16018 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
16019 GDB_SELF_TEST.
16020 (maintenance_info_selftests): Likewise.
16021
16022 2018-01-08 Xavier Roirand <roirand@adacore.com>
16023
16024 * ada-valprint.c (val_print_packed_array_elements): Use
16025 proper number of elements when printing an array indexed
16026 by an enumeration type.
16027
16028 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16029
16030 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
16031 (dw2_get_file_names_reader): Adjust.
16032 (lookup_dwo_signatured_type): Adjust.
16033 (lookup_dwp_signatured_type): Adjust.
16034 (lookup_signatured_type): Adjust.
16035 (create_type_unit_group): Adjust.
16036 (get_type_unit_group): Adjust.
16037 (process_psymtab_comp_unit_reader): Adjust.
16038 (build_type_psymtabs_reader): Adjust.
16039 (scan_partial_symbols): Adjust.
16040 (add_partial_symbol): Adjust.
16041 (add_partial_subprogram): Adjust.
16042 (peek_die_abbrev): Adjust.
16043 (fixup_go_packaging): Adjust.
16044 (process_imported_unit_die): Adjust.
16045 (dwarf2_compute_name): Adjust.
16046 (dwarf2_physname): Adjust.
16047 (read_import_statement): Adjust.
16048 (handle_DW_AT_stmt_list): Adjust.
16049 (read_file_scope): Adjust.
16050 (read_func_scope): Adjust.
16051 (read_lexical_block_scope): Adjust.
16052 (read_call_site_scope): Adjust.
16053 (read_variable): Adjust.
16054 (dwarf2_rnglists_process): Adjust.
16055 (dwarf2_ranges_process): Adjust.
16056 (dwarf2_ranges_read): Adjust.
16057 (dwarf2_get_pc_bounds): Adjust.
16058 (dwarf2_record_block_ranges): Adjust.
16059 (dwarf2_add_field): Adjust.
16060 (dwarf2_add_member_fn): Adjust.
16061 (read_structure_type): Adjust.
16062 (process_structure_scope): Adjust.
16063 (read_enumeration_type): Adjust.
16064 (read_array_type): Adjust.
16065 (mark_common_block_symbol_computed): Adjust.
16066 (read_common_block): Adjust.
16067 (read_namespace_type): Adjust.
16068 (read_namespace): Adjust.
16069 (read_module_type): Adjust.
16070 (read_tag_pointer_type): Adjust.
16071 (read_tag_ptr_to_member_type): Adjust.
16072 (read_tag_string_type): Adjust.
16073 (read_subroutine_type): Adjust.
16074 (read_typedef): Adjust.
16075 (read_base_type): Adjust.
16076 (attr_to_dynamic_prop): Adjust.
16077 (read_subrange_type): Adjust.
16078 (read_unspecified_type): Adjust.
16079 (dwarf2_read_abbrevs): Adjust.
16080 (load_partial_dies): Adjust.
16081 (read_partial_die): Adjust.
16082 (find_partial_die): Adjust.
16083 (guess_partial_die_structure_name): Adjust.
16084 (fixup_partial_die): Adjust.
16085 (read_attribute_value): Adjust.
16086 (read_addr_index): Adjust.
16087 (read_addr_index_from_leb128): Adjust.
16088 (read_str_index): Adjust.
16089 (dwarf2_string_attr): Adjust.
16090 (get_debug_line_section): Adjust.
16091 (dwarf_decode_line_header): Adjust.
16092 (lnp_state_machine::check_line_address): Adjust.
16093 (dwarf_decode_lines_1): Adjust.
16094 (dwarf_decode_lines): Adjust.
16095 (dwarf2_start_symtab): Adjust.
16096 (var_decode_location): Adjust.
16097 (new_symbol_full): Adjust.
16098 (dwarf2_const_value_data): Adjust.
16099 (dwarf2_const_value_attr): Adjust.
16100 (dwarf2_const_value): Adjust.
16101 (die_type): Adjust.
16102 (die_containing_type): Adjust.
16103 (build_error_marker_type): Adjust.
16104 (lookup_die_type): Adjust.
16105 (guess_full_die_structure_name): Adjust.
16106 (anonymous_struct_prefix): Adjust.
16107 (determine_prefix): Adjust.
16108 (dwarf2_name): Adjust.
16109 (follow_die_ref_or_sig): Adjust.
16110 (follow_die_offset): Adjust.
16111 (follow_die_ref): Adjust.
16112 (follow_die_sig_1): Adjust.
16113 (follow_die_sig): Adjust.
16114 (get_signatured_type): Adjust.
16115 (get_DW_AT_signature_type): Adjust.
16116 (decode_locdesc): Adjust.
16117 (dwarf_decode_macros): Adjust.
16118 (cu_debug_loc_section): Adjust.
16119 (fill_in_loclist_baton): Adjust.
16120 (dwarf2_symbol_mark_computed): Adjust.
16121 (init_one_comp_unit): Don't assign
16122 dwarf2_cu::dwarf2_per_objfile.
16123 (set_die_type): Adjust.
16124
16125 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
16126
16127 * dwarf2read.c (struct mapped_debug_names): Add constructor.
16128 <dwarf2_per_objfile>: New field.
16129 (dwarf2_per_objfile): Remove global.
16130 (get_dwarf2_per_objfile): New function.
16131 (set_dwarf2_per_objfile): New function.
16132 (dwarf2_build_psymtabs_hard): Change objfile parameter to
16133 dwarf2_per_objfile.
16134 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
16135 (read_abbrev_offset): Likewise.
16136 (read_indirect_string): Likewise.
16137 (read_indirect_line_string): Likewise.
16138 (read_indirect_string_at_offset): Likewise.
16139 (read_indirect_string_from_dwz): Likewise.
16140 (dwarf2_find_containing_comp_unit): Change objfile parameter to
16141 dwarf2_per_objfile.
16142 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
16143 (create_all_comp_units): Change objfile parameter to
16144 dwarf2_per_objfile.
16145 (create_all_type_units): Likewise.
16146 (process_queue): Add dwarf2_per_objfile parameter.
16147 (read_and_check_comp_unit_head): Likewise.
16148 (lookup_dwo_unit_in_dwp): Likewise.
16149 (get_dwp_file): Likewise.
16150 (process_cu_includes): Likewise.
16151 (struct free_dwo_file_cleanup_data): New struct.
16152 (dwarf2_has_info): Use get_dwarf2_per_objfile and
16153 set_dwarf2_per_objfile.
16154 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
16155 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
16156 context, adjust calls.
16157 (dw2_instantiate_symtab): Likewise.
16158 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
16159 (dw2_get_cu): Likewise.
16160 (create_cu_from_index_list): Change objfile parameter to
16161 dwarf2_per_objfile.
16162 (create_cus_from_index_list): Get dwarf2_per_objfile from
16163 context, adjust calls.
16164 (create_cus_from_index): Likewise.
16165 (create_signatured_type_table_from_index): Change objfile
16166 parameter to dwarf2_per_objfile.
16167 (create_signatured_type_table_from_debug_names): Change objfile
16168 parameter to dwarf2_per_objfile.
16169 (create_addrmap_from_index): Likewise.
16170 (create_addrmap_from_aranges): Likewise.
16171 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
16172 (dw2_setup): Remove.
16173 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
16174 context.
16175 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
16176 get_dwarf2_per_objfile.
16177 (dw2_forget_cached_source_info): Likewise.
16178 (dw2_map_symtabs_matching_filename): Likewise.
16179 (struct dw2_symtab_iterator) <index>: Remove.
16180 <dwarf2_per_objfile>: New field.
16181 (dw2_symtab_iter_init): Replace index parameter with
16182 dwarf2_per_objfile.
16183 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
16184 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
16185 (dw2_print_stats): Likewise.
16186 (dw2_dump): Likewise.
16187 (dw2_expand_symtabs_for_function): Likewise.
16188 (dw2_expand_all_symtabs): Likewise.
16189 (dw2_expand_symtabs_with_fullname): Likewise.
16190 (dw2_expand_marked_cus): Replace index and objfile parameters
16191 with dwarf2_per_objfile.
16192 (dw_expand_symtabs_matching_file_matcher): Add
16193 dwarf2_per_objfile parameter and adjust calls.
16194 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
16195 adjust calls.
16196 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
16197 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
16198 adjust calls.
16199 (create_cus_from_debug_names_list): Replace objfile parameter
16200 with dwarf2_per_objfile and adjust calls.
16201 (create_cus_from_debug_names): Likewise.
16202 (dwarf2_read_debug_names): Likewise.
16203 (mapped_debug_names::namei_to_name): Adjust call.
16204 (dw2_debug_names_iterator::next): Likewise.
16205 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
16206 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
16207 (dw2_debug_names_dump): Likewise.
16208 (dw2_debug_names_expand_symtabs_for_function): Likewise.
16209 (dw2_debug_names_expand_symtabs_matching): Likewise.
16210 (dwarf2_initialize_objfile): Likewise.
16211 (dwarf2_build_psymtabs): Likewise.
16212 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
16213 this_cu.
16214 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
16215 (read_and_check_comp_unit_head): Likewise.
16216 (read_abbrev_offset): Likewise.
16217 (create_debug_type_hash_table): Likewise.
16218 (create_debug_types_hash_table): Likewise.
16219 (create_all_type_units): Replace objfile parameter with
16220 dwarf2_per_objfile.
16221 (add_type_unit): Add dwarf2_per_objfile parameter.
16222 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
16223 with dwarf2_per_objfile.
16224 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
16225 (lookup_dwp_signatured_type): Likewise.
16226 (lookup_signatured_type): Likewise.
16227 (read_cutu_die_from_dwo): Likewise.
16228 (init_tu_and_read_dwo_dies): Likewise.
16229 (init_cutu_and_read_dies): Likewise.
16230 (init_cutu_and_read_dies_no_follow): Likewise.
16231 (allocate_type_unit_groups_table): Add objfile parameter.
16232 (create_type_unit_group): Use dwarf2_per_objfile from cu.
16233 (get_type_unit_group): Likewise.
16234 (process_psymtab_comp_unit): Update call.
16235 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
16236 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
16237 (print_tu_stats): Likewise.
16238 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
16239 in void* parameter.
16240 (build_type_psymtabs): Change objfile parameter to
16241 dwarf2_per_objfile.
16242 (process_skeletonless_type_unit): Use dwarf2_per_objfile
16243 passed in void* parameter.
16244 (process_skeletonless_type_units): Change objfile parameter to
16245 dwarf2_per_objfile.
16246 (set_partial_user): Likewise.
16247 (dwarf2_build_psymtabs_hard): Likewise.
16248 (read_comp_units_from_section): Likewise.
16249 (create_all_comp_units): Likewise.
16250 (scan_partial_symbols): Update calls.
16251 (add_partial_symbol): Likewise.
16252 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
16253 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
16254 (process_queue): Add dwarf2_per_objfile parameter.
16255 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
16256 (compute_compunit_symtab_includes): Likewise.
16257 (process_cu_includes): Add dwarf2_per_objfile parameter.
16258 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
16259 (process_full_type_unit): Likewise.
16260 (process_imported_unit_die): Update call.
16261 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
16262 (read_file_scope): Likewise.
16263 (allocate_dwo_file_hash_table): Add objfile parameter.
16264 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
16265 (create_cus_hash_table): Likewise.
16266 (create_dwp_hash_table): Likewise.
16267 (create_dwo_unit_in_dwp_v1): Likewise.
16268 (create_dwp_v2_section): Likewise.
16269 (create_dwo_unit_in_dwp_v2): Likewise.
16270 (lookup_dwo_unit_in_dwp): Likewise.
16271 (try_open_dwop_file): Likewise.
16272 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
16273 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
16274 cleanup to include a reference to dwarf2_per_objfile.
16275 (open_dwp_file): Add dwarf2_per_objfile parameter.
16276 (open_and_init_dwp_file): Likewise.
16277 (get_dwp_file): Likewise.
16278 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
16279 (queue_and_load_all_dwo_tus): Update call.
16280 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
16281 data.
16282 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
16283 (dwarf2_ranges_process): Likewise.
16284 (dwarf2_get_pc_bounds): Likewise.
16285 (mark_common_block_symbol_computed): Likewise.
16286 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
16287 (dwarf2_read_abbrevs): Update call.
16288 (read_partial_die): Use dwarf2_per_objfile from cu.
16289 (find_partial_die): Likewise.
16290 (fixup_partial_die): Likewise.
16291 (read_attribute_value): Likewise.
16292 (read_indirect_string_at_offset_from): Add objfile parameter.
16293 (read_indirect_string_at_offset): Add dwarf2_per_objfile
16294 parameter.
16295 (read_indirect_string_from_dwz): Add objfile parameter.
16296 (read_indirect_string): Add objfile parameter.
16297 (read_addr_index_1): Add dwarf2_per_objfile parameter.
16298 (read_addr_index): Use dwarf2_per_objfile from cu.
16299 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
16300 call dw2_setup.
16301 (read_str_index): Use dwarf2_per_objfile from cu.
16302 (get_debug_line_section): Likewise.
16303 (read_formatted_entries): Add dwarf2_per_objfile parameter.
16304 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
16305 (new_symbol_full): Use dwarf2_per_objfile from cu.
16306 (build_error_marker_type): Likewise.
16307 (lookup_die_type): Likewise.
16308 (determine_prefix): Likewise.
16309 (follow_die_offset): Likewise.
16310 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
16311 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
16312 (dwarf2_fetch_die_type_sect_off): Likewise.
16313 (dwarf2_get_die_type): Likewise.
16314 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
16315 (get_signatured_type): Likewise.
16316 (get_DW_AT_signature_type): Likewise.
16317 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
16318 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
16319 (cu_debug_loc_section): Likewise.
16320 (fill_in_loclist_baton): Likewise.
16321 (dwarf2_symbol_mark_computed): Likewise.
16322 (dwarf2_find_containing_comp_unit): Change objfile parameter to
16323 dwarf2_per_objfile.
16324 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
16325 parameter.
16326 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
16327 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
16328 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
16329 (set_die_type): Use dwarf2_free_objfile from cu.
16330 (get_die_type_at_offset): Likewise.
16331 (dwarf2_per_objfile_free): Don't assign global variable.
16332 (debug_names) <constructor>: Add dwarf2_per_objfile
16333 parameter, update m_debugstrlookup construction.
16334 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
16335 parameter.
16336 <m_dwarf2_per_objfile>: New field.
16337 <lookup>: Use m_dwarf2_per_objfile.
16338 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
16339 (psyms_seen_size): Likewise.
16340 (write_gdbindex): Replace objfile parameter with
16341 dwarf2_per_objfile.
16342 (write_debug_names): Likewise.
16343 (write_psymtabs_to_index): Likewise.
16344 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
16345 calls.
16346
16347 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
16348
16349 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
16350 <dwarf2_per_objfile>: New field.
16351 (struct dwarf2_per_cu_data) <objfile>: Remove.
16352 <dwarf2_per_objfile>: New field.
16353 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
16354 of objfile.
16355 (create_signatured_type_table_from_index): Likewise.
16356 (create_debug_type_hash_table): Likewise.
16357 (fill_in_sig_entry_from_dwo_entry): Likewise.
16358 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
16359 (create_type_unit_group): Assign dwarf2_per_objfile instead of
16360 objfile.
16361 (create_partial_symtab): Access objfile through
16362 dwarf2_per_objfile.
16363 (process_psymtab_comp_unit_reader): Likewise.
16364 (read_comp_units_from_section): Likewise.
16365 (scan_partial_symbols): Likewise.
16366 (add_partial_symbol): Likewise.
16367 (add_partial_subprogram): Likewise.
16368 (peek_die_abbrev): Likewise.
16369 (fixup_go_packaging): Likewise.
16370 (process_full_comp_unit): Likewise.
16371 (process_full_type_unit): Likewise.
16372 (process_imported_unit_die): Likewise.
16373 (dwarf2_compute_name): Likewise.
16374 (dwarf2_physname): Likewise.
16375 (read_import_statement): Likewise.
16376 (create_cus_hash_table): Assign dwarf2_physname instead of
16377 objfile.
16378 (read_func_scope): Access objfile through dwarf2_per_objfile.
16379 (read_lexical_block_scope): Likewise.
16380 (read_call_site_scope): Likewise.
16381 (read_variable): Likewise.
16382 (dwarf2_rnglists_process): Likewise.
16383 (dwarf2_ranges_process): Likewise.
16384 (dwarf2_ranges_read): Likewise.
16385 (dwarf2_record_block_ranges): Likewise.
16386 (dwarf2_add_field): Likewise.
16387 (dwarf2_add_member_fn): Likewise.
16388 (read_structure_type): Likewise.
16389 (process_structure_scope): Likewise.
16390 (read_enumeration_type): Likewise.
16391 (read_array_type): Likewise.
16392 (read_common_block): Likewise.
16393 (read_namespace_type): Likewise.
16394 (read_namespace): Likewise.
16395 (read_module_type): Likewise.
16396 (read_tag_pointer_type): Likewise.
16397 (read_tag_ptr_to_member_type): Likewise.
16398 (read_tag_string_type): Likewise.
16399 (read_subroutine_type): Likewise.
16400 (read_typedef): Likewise.
16401 (read_base_type): Likewise.
16402 (attr_to_dynamic_prop): Likewise.
16403 (read_subrange_type): Likewise.
16404 (read_unspecified_type): Likewise.
16405 (load_partial_dies): Likewise.
16406 (read_partial_die): Likewise.
16407 (find_partial_die): Likewise.
16408 (guess_partial_die_structure_name): Likewise.
16409 (fixup_partial_die): Likewise.
16410 (read_attribute_value): Likewise.
16411 (read_addr_index_from_leb128): Likewise.
16412 (dwarf2_read_addr_index): Likewise.
16413 (dwarf2_string_attr): Likewise.
16414 (lnp_state_machine::check_line_address): Likewise.
16415 (dwarf_decode_lines_1): Likewise.
16416 (dwarf_decode_lines): Likewise.
16417 (dwarf2_start_symtab): Likewise.
16418 (var_decode_location): Likewise.
16419 (new_symbol_full): Likewise.
16420 (dwarf2_const_value_data): Likewise.
16421 (dwarf2_const_value_attr): Likewise.
16422 (dwarf2_const_value): Likewise.
16423 (die_type): Likewise.
16424 (die_containing_type): Likewise.
16425 (lookup_die_type): Likewise.
16426 (guess_full_die_structure_name): Likewise.
16427 (anonymous_struct_prefix): Likewise.
16428 (dwarf2_name): Likewise.
16429 (follow_die_ref_or_sig): Likewise.
16430 (follow_die_offset): Likewise.
16431 (follow_die_ref): Likewise.
16432 (dwarf2_fetch_die_loc_sect_off): Likewise.
16433 (dwarf2_fetch_constant_bytes): Likewise.
16434 (dwarf2_fetch_die_type_sect_off): Likewise.
16435 (dwarf2_get_die_type): Likewise.
16436 (follow_die_sig): Likewise.
16437 (decode_locdesc): Likewise.
16438 (dwarf2_per_cu_objfile): Likewise.
16439 (dwarf2_per_cu_text_offset): Likewise.
16440 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
16441 objfile.
16442 (set_die_type): Access objfile through
16443 dwarf2_per_objfile.
16444
16445 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
16446
16447 * valprint.c (converted_character_d): Remove typedef.
16448 (DEF_VEC_O (converted_character_d)): Remove.
16449 (count_next_character): Use std::vector.
16450 (print_converted_chars_to_obstack): Likewise.
16451 (generic_printstr): Likewise.
16452
16453 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16454
16455 * xml-support.h (struct gdb_xml_value): Add constructor.
16456 <value>: Change type to unique_xmalloc_ptr.
16457 (gdb_xml_value_s): Remove typedef.
16458 (DEF_VEC_O (gdb_xml_value_s)): Remove.
16459 (gdb_xml_element_start_handler): Change parameter type to
16460 std::vector.
16461 (xml_find_attribute): Likewise.
16462 * xml-support.c (xml_find_attribute): Change parameter type to
16463 std::vector and adjust.
16464 (gdb_xml_values_cleanup): Remove.
16465 (gdb_xml_parser::start_element): Adjust to std::vector.
16466 (xinclude_start_include): Change paraeter type to std::vector
16467 and adjust.
16468 * btrace.c (check_xml_btrace_version): Likewise.
16469 (parse_xml_btrace_block): Likewise.
16470 (parse_xml_btrace_pt_config_cpu): Likewise.
16471 (parse_xml_btrace_pt): Likewise.
16472 (parse_xml_btrace_conf_bts): Likewise.
16473 (parse_xml_btrace_conf_pt): Likewise.
16474 * memory-map.c (memory_map_start_memory): Likewise.
16475 (memory_map_start_property): Likewise.
16476 * osdata.c (osdata_start_osdata): Likewise.
16477 (osdata_start_item): Likewise.
16478 (osdata_start_column): Likewise.
16479 * remote.c (start_thread): Likewise.
16480 * solib-aix.c (library_list_start_library): Likewise.
16481 (library_list_start_list): Likewise.
16482 * solib-svr4.c (library_list_start_library): Likewise.
16483 (svr4_library_list_start_list): Likewise.
16484 * solib-target.c (library_list_start_segment): Likewise.
16485 (library_list_start_section): Likewise.
16486 (library_list_start_library): Likewise.
16487 (library_list_start_list): Likewise.
16488 * tracepoint.c (traceframe_info_start_memory): Likewise.
16489 (traceframe_info_start_tvar): Likewise.
16490 * xml-syscall.c (syscall_start_syscall): Likewise.
16491 * xml-tdesc.c (tdesc_start_target): Likewise.
16492 (tdesc_start_feature): Likewise.
16493 (tdesc_start_reg): Likewise.
16494 (tdesc_start_union): Likewise.
16495 (tdesc_start_struct): Likewise.
16496 (tdesc_start_flags): Likewise.
16497 (tdesc_start_enum): Likewise.
16498 (tdesc_start_field): Likewise.
16499 (tdesc_start_enum_value): Likewise.
16500 (tdesc_start_vector): Likewise.
16501
16502 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16503
16504 * extension.h (struct xmethod_worker) <clone>: Remove.
16505 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
16506 Remove.
16507 (python_xmethod_worker::clone): Remove.
16508 * valops.c (find_overload_match): Use std::move instead of
16509 clone.
16510
16511 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16512
16513 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
16514 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
16515 <free_xmethod_worker_data>: Remove.
16516 <get_matching_xmethod_workers>: Chance VEC to std::vector.
16517 <get_xmethod_arg_types>: Remove.
16518 <get_xmethod_result_type>: Remove.
16519 <invoke_xmethod>: Remove.
16520 * extension.c (new_xmethod_worker): Remove.
16521 (clone_xmethod_worker): Remove.
16522 (get_matching_xmethod_workers): Return void, pass std::vector by
16523 pointer.
16524 (get_xmethod_arg_types): Rename to...
16525 (xmethod_worker::get_arg_types): ... this, and adjust.
16526 (get_xmethod_result_type): Rename to...
16527 (xmethod_worker::get_result_type): ... this, and adjust.
16528 (invoke_xmethod): Remove.
16529 (free_xmethod_worker): Remove.
16530 (free_xmethod_worker_vec): Remove.
16531 * extension.h (enum ext_lang_rc): Move here from
16532 extension-priv.h.
16533 (struct xmethod_worker): Add constructor and destructor.
16534 <data>: Remove.
16535 <value>: Remove.
16536 <invoke, clone, do_get_result_type, do_get_arg_types>: New
16537 virtual pure methods.
16538 <get_arg_types, get_result_type>: New methods.
16539 (xmethod_worker_ptr): Remove typedef.
16540 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
16541 (xmethod_worker_vec): Remove typedef.
16542 (xmethod_worker_up): New typedef.
16543 (invoke_xmethod): Remove.
16544 (clone_xmethod_worker): Remove.
16545 (free_xmethod_worker): Remove.
16546 (free_xmethod_worker_vec): Remove.
16547 (get_xmethod_arg_types): Remove.
16548 (get_xmethod_result_type): Remove.
16549 * valops.c (find_method_list): Use std::vector, don't use
16550 intermediate vector.
16551 (value_find_oload_method_list): Use std::vector.
16552 (find_overload_match): Use std::vector.
16553 (find_oload_champ): Use std::vector.
16554 * value.c (value_free): Use operator delete.
16555 (value_of_xmethod): Rename to...
16556 (value_from_xmethod): ... this. Don't assign
16557 xmethod_worker::value, take rvalue-reference.
16558 (result_type_of_xmethod): Adjust.
16559 (call_xmethod): Adjust.
16560 * value.h: Include extension.h.
16561 (struct xmethod_worker): Don't forward-declare.
16562 (value_of_xmethod): Rename to...
16563 (value_from_xmethod): ... this, take rvalue-reference.
16564 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
16565 (struct python_xmethod_worker): ... this, add constructor and
16566 destructor.
16567 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
16568 (gdbpy_free_xmethod_worker_data): Rename to...
16569 (python_xmethod_worker::~python_xmethod_worker): ... this and
16570 adjust.
16571 (gdbpy_clone_xmethod_worker_data): Rename to...
16572 (python_xmethod_worker::clone): ... this and adjust.
16573 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
16574 temporary vector.
16575 (gdbpy_get_xmethod_arg_types): Rename to...
16576 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
16577 (gdbpy_get_xmethod_result_type): Rename to...
16578 (python_xmethod_worker::do_get_result_type): ... this and
16579 adjust.
16580 (gdbpy_invoke_xmethod): Rename to...
16581 (python_xmethod_worker::invoke): ... this and adjust.
16582 (new_python_xmethod_worker): Rename to...
16583 (python_xmethod_worker::python_xmethod_worker): ... this and
16584 adjust.
16585 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
16586 Remove.
16587 (gdbpy_free_xmethod_worker_data): Remove.
16588 (gdbpy_get_matching_xmethod_workers): Use std::vector.
16589 (gdbpy_get_xmethod_arg_types): Remove.
16590 (gdbpy_get_xmethod_result_type): Remove.
16591 (gdbpy_invoke_xmethod): Remove.
16592 * python/python.c (python_extension_ops): Remove obsolete
16593 callbacks.
16594
16595 2018-01-05 Pedro Alves <palves@redhat.com>
16596
16597 PR gdb/18653
16598 * common/signals-state-save-restore.c
16599 (save_original_signals_state): New parameter 'quiet'. Warn if we
16600 find a custom handler preinstalled, instead of internal erroring.
16601 But only warn if !quiet.
16602 * common/signals-state-save-restore.h
16603 (save_original_signals_state): New parameter 'quiet'.
16604 * main.c (captured_main_1): Move save_original_signals_state call
16605 after option handling, and pass QUIET.
16606
16607 2018-01-05 Pedro Alves <palves@redhat.com>
16608
16609 * spu-tdep.c (spu_catch_start): Pass
16610 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
16611
16612 2018-01-05 Pedro Alves <palves@redhat.com>
16613
16614 PR gdb/22670
16615 * ada-lang.c (literal_symbol_name_matcher): New function.
16616 (ada_get_symbol_name_matcher): Use it for
16617 symbol_name_match_type::SEARCH_NAME.
16618 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
16619 it down instead of assuming symbol_name_match_type::FULL.
16620 * block.h (block_lookup_symbol): New parameter 'match_type'.
16621 * c-valprint.c (print_unpacked_pointer): Use
16622 lookup_symbol_search_name instead of lookup_symbol.
16623 * compile/compile-object-load.c (get_out_value_type): Pass down
16624 symbol_name_match_type::SEARCH_NAME.
16625 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
16626 symbol_name_match_type::FULL.
16627 * cp-support.c (cp_get_symbol_name_matcher): Handle
16628 symbol_name_match_type::SEARCH_NAME.
16629 * infrun.c (insert_exception_resume_breakpoint): Use
16630 lookup_symbol_search_name.
16631 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
16632 * psymtab.c (maintenance_check_psymtabs): Use
16633 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
16634 * stack.c (print_frame_args): Use lookup_symbol_search_name and
16635 SYMBOL_SEARCH_NAME.
16636 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
16637 if symbol_name_match_type::SEARCH_NAME.
16638 (lookup_symbol_in_language): Pass down
16639 symbol_name_match_type::FULL.
16640 (lookup_symbol_search_name): New.
16641 (lookup_language_this): Pass down
16642 symbol_name_match_type::SEARCH_NAME.
16643 (lookup_symbol_aux, lookup_local_symbol): New parameter
16644 'match_type'. Pass it down.
16645 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
16646 (lookup_symbol_search_name): New declaration.
16647 (lookup_symbol_in_block): New 'match_type' parameter.
16648
16649 2018-01-05 Pedro Alves <palves@redhat.com>
16650
16651 PR gdb/22670
16652 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
16653 ada_lookup_symbol.
16654 (ada_lookup_symbol): Reimplement in terms of
16655 ada_lookup_symbol_list, bits factored out from
16656 ada_lookup_encoded_symbol.
16657
16658 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16659
16660 * ada-exp.y (write_object_renaming): When subscripting an array
16661 using a symbol as the index, pass the block in call to
16662 ada_lookup_encoded_symbol when looking that symbol up.
16663
16664 2018-01-05 Jerome Guitton <guitton@adacore.com>
16665
16666 * ada-lang.c (ada_array_length): Use ada_index_type instead of
16667 TYPE_INDEX_TYPE.
16668
16669 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16670
16671 * ada-lang.c (ada_to_fixed_value_create): Add handling of
16672 the case where VALUE_LVAL (val0) is not lval_memory.
16673
16674 2018-01-05 Xavier Roirand <roirand@adacore.com>
16675
16676 * ada-valprint.c (print_optional_low_bound): Handle
16677 character-indexed array printing like boolean-indexed array
16678 printing.
16679
16680 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16681
16682 * NEWS: Create a new section for the next release branch.
16683 Rename the section of the current branch, now that it has
16684 been cut.
16685
16686 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16687
16688 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
16689 * version.in: Bump version to 8.1.50.DATE-git.
16690
16691 2018-01-03 Xavier Roirand <roirand@adacore.com>
16692
16693 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
16694 Add field.
16695 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
16696 Add field.
16697 (default_exception_support_info) <catch_handlers_sym>: Add field.
16698 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
16699 (ada_exception_name_addr_1): Add "catch handlers" handling.
16700 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
16701 Update all callers.
16702 (create_excep_cond_exprs) <ex>: Add parameter.
16703 (re_set_exception): Update create_excep_cond_exprs call.
16704 (print_it_exception, print_one_exception, print_mention_exception)
16705 (print_recreate_exception): Add "catch handler" handling.
16706 (allocate_location_catch_handlers, re_set_catch_handlers)
16707 (check_status_catch_handlers, print_it_catch_handlers)
16708 (print_one_catch_handlers, print_mention_catch_handlers)
16709 (print_recreate_catch_handlers): New function.
16710 (catch_handlers_breakpoint_ops): New variable.
16711 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
16712 Add parameter. Add "catch handler" handling.
16713 (ada_exception_sym_name, ada_exception_breakpoint_ops):
16714 Add "catch handler" handling.
16715 (ada_exception_catchpoint_cond_string): Add "catch handler"
16716 handling.
16717 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
16718 call.
16719 (catch_ada_handlers_command): New function.
16720 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
16721 operations structure.
16722 (_initialize_ada_language): Add "catch handlers" command entry.
16723 * NEWS: Document "catch handlers" feature.
16724
16725 2018-01-02 Joel Brobecker <brobecker@adacore.com>
16726
16727 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
16728 account when creating the array type of the slice.
16729 (ada_value_slice): Likewise.
16730
16731 2018-01-02 Joel Brobecker <brobecker@adacore.com>
16732
16733 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
16734 New enum value.
16735 (create_array_type_with_stride): Add byte_stride_prop parameter.
16736 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
16737 New parameter. Update all callers in this file.
16738 (array_type_has_dynamic_stride): New function.
16739 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
16740 of arrays with dynamic byte strides.
16741 * dwarf2read.c (read_array_type): Add support for dynamic
16742 DW_AT_byte_stride attributes.
16743
16744 2018-01-02 Joel Brobecker <brobecker@adacore.com>
16745
16746 * dwarf2read.c (read_unspecified_type): Treat
16747 DW_TAG_enumeration_type DIEs from Ada units as stubs.
16748
16749 2018-01-01 Joel Brobecker <brobecker@adacore.com>
16750
16751 Update copyright year range in all GDB files.
16752
16753 2018-01-01, 18 Joel Brobecker <brobecker@adacore.com>
16754
16755 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
16756 and gdb/testsuite/gdb.base/step-line.c.
16757
16758 2018-01-01 Joel Brobecker <brobecker@adacore.com>
16759
16760 * copyright.py (main): Dump the contents of
16761 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
16762 even if BY_HAND is empty.
16763
16764 2018-01-01 Joel Brobecker <brobecker@adacore.com>
16765
16766 * top.c (print_gdb_version): Update Copyright year in version
16767 message.
16768
16769 2018-01-01 Joel Brobecker <brobecker@adacore.com>
16770
16771 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
16772
16773 For older changes see ChangeLog-2017.
16774 \f
16775 Local Variables:
16776 mode: change-log
16777 left-margin: 8
16778 fill-column: 74
16779 version-control: never
16780 coding: utf-8
16781 End:
This page took 0.561786 seconds and 3 git commands to generate.